diff --git a/.gitattributes b/.gitattributes index 00fb8eec1..f7eaaca30 100644 --- a/.gitattributes +++ b/.gitattributes @@ -7,3 +7,9 @@ native/tablespec/sources/** -text spec/domain-packs/medical*/sources/** -text spec/domain-packs/medical*/data/** -text spec/domain-packs/medical-terminology/sources/*.txt whitespace=cr-at-eol + +spec/domain-packs/medical-carrier/sources/cms-*.csv -text whitespace=cr-at-eol +spec/domain-packs/medical-imaging/sources/*.dcm binary + +# Generated bundles may contain literal trailing spaces in dependency strings. +docs/helix/05-deploy/microsite/dist/*.js whitespace=-blank-at-eol diff --git a/.github/workflows/microsite.yml b/.github/workflows/microsite.yml index bf60c8ac1..2da0cdb28 100644 --- a/.github/workflows/microsite.yml +++ b/.github/workflows/microsite.yml @@ -8,6 +8,12 @@ on: - 'docs/helix/05-deploy/microsite/**' - 'src/**' - 'spec/**' + - 'scripts/build-medical-subpacks.ts' + - 'scripts/domain-pack-family.ts' + - 'scripts/export-domain-family.ts' + - 'scripts/export-domain-pack.ts' + - 'scripts/domain-packs/ontology.ts' + - 'tests/domain-packs/**' - 'patches/**' - 'package.json' - 'bun.lock' @@ -19,6 +25,12 @@ on: - 'docs/helix/05-deploy/microsite/**' - 'src/**' - 'spec/**' + - 'scripts/build-medical-subpacks.ts' + - 'scripts/domain-pack-family.ts' + - 'scripts/export-domain-family.ts' + - 'scripts/export-domain-pack.ts' + - 'scripts/domain-packs/ontology.ts' + - 'tests/domain-packs/**' - 'patches/**' - 'package.json' - 'bun.lock' @@ -42,6 +54,10 @@ jobs: bun-version: '1.3.14' - name: Install dependencies run: bun install --frozen-lockfile + - name: Verify medical family artifacts + run: | + bun scripts/build-medical-subpacks.ts --check + bun test tests/domain-packs - name: Build browser playground run: bun build docs/helix/05-deploy/microsite/demo.ts --target browser --minify --outfile docs/helix/05-deploy/microsite/dist/demo.js - name: Build schema explorer and domain-pack catalog diff --git a/docs/helix/01-frame/features/FEAT-011-medical-domain-pack.md b/docs/helix/01-frame/features/FEAT-011-medical-domain-pack.md index 8c12a6db8..f0147383a 100644 --- a/docs/helix/01-frame/features/FEAT-011-medical-domain-pack.md +++ b/docs/helix/01-frame/features/FEAT-011-medical-domain-pack.md @@ -80,3 +80,13 @@ First clinical profile, terminology distribution terms and source separation; FH ## Out of Scope Clinical decision support, medical advice, and population-valid simulation. + +## Medical family integration + +Clinical, carrier, epidemiology, imaging and terminology packs must be discoverable +from one Medical overview. Preserve their independent versions and source namespaces. +Carrier samples include qualified public CSV claim/enrollment excerpts alongside +FHIR (Fast Healthcare Interoperability Resources) R4 originals. Imaging includes +a rights-qualified public DICOM (Digital Imaging and Communications in Medicine) +object alongside the synthetic private-tag control. Publish original-source and +CSV downloads, source limitations and matching ontology/table navigation. diff --git a/docs/helix/01-frame/user-stories/US-055-medical-subpacks.md b/docs/helix/01-frame/user-stories/US-055-medical-subpacks.md index 3377f43e2..7c02f0902 100644 --- a/docs/helix/01-frame/user-stories/US-055-medical-subpacks.md +++ b/docs/helix/01-frame/user-stories/US-055-medical-subpacks.md @@ -80,3 +80,14 @@ CONTRACT-001, CONTRACT-052, ADR-002, architecture, TD-055 and STP-055. Production carrier processing, clinical validation, patient identity matching, terminology equivalence, pixel codecs, live PACS and native graph-engine adoption. These retain separate FR-45 requirements and qualification gates. + +## Integrated family delivery + +Owner direction extends AC1/AC4/AC6 to qualified public samples and complete +family discovery/export. Medical's clinical overview links each independently +versioned subpack; each subpack links back. Exact public CMS CSV excerpts remain +historical synthetic claims, distinct from the FHIR examples. A selected TCIA +DICOM object keeps collection citation, rights and unchanged bytes. The explorer +offers local source and CSV downloads and all four subpack ontology views. +One explicit family export preserves separate pack directories and inventories; +composition never invents patient linkage or combines populations. diff --git a/docs/helix/01-frame/user-stories/US-062-medical-domain-pack.md b/docs/helix/01-frame/user-stories/US-062-medical-domain-pack.md index 2e52c40cb..0cdffd788 100644 --- a/docs/helix/01-frame/user-stories/US-062-medical-domain-pack.md +++ b/docs/helix/01-frame/user-stories/US-062-medical-domain-pack.md @@ -28,7 +28,7 @@ The pack's conceptual scope is Patients; organizations; practitioners; encounter ## Delivered Subset -The completed medical pack is an official fixed example corpus, not a longitudinal generator: 17 HL7 R4 resources, eight projections, exact originals/literals and explicit source provenance. [Evidence](../../04-build/evidence/medical-domain-pack.md) records typed ZIP and local Sail/Spark checks. Medication is a resource, not an inferred order/administration. Conditions, allergies, procedures, notes and claims remain desired expansions. CMS records are reference-only until selected bytes and reuse terms are established. AC4/AC5 apply to future generated supplementation; they must not force cloning published clinical records or be marked passed by fixed corpus ingestion. +The completed medical pack is an official fixed example corpus, not a longitudinal generator: 17 HL7 R4 resources, eight projections, exact originals/literals and explicit source provenance. [Evidence](../../04-build/evidence/medical-domain-pack.md) records typed ZIP and local Sail/Spark checks. Medication is a resource, not an inferred order/administration. Conditions, allergies, procedures and notes remain desired expansions. US-055 separately qualifies carrier FHIR/CSV examples and bounded CMS DE-SynPUF excerpts; these do not establish the longitudinal generated scenario in this story. Medical 1.1.0 links that independent carrier pack and the imaging, epidemiology and terminology packs while retaining the unchanged clinical sources. AC4/AC5 apply to future generated supplementation; they must not force cloning published clinical records or be marked passed by fixed corpus ingestion. ## Pilot Question diff --git a/docs/helix/02-design/contracts/CONTRACT-052-domain-packs.md b/docs/helix/02-design/contracts/CONTRACT-052-domain-packs.md index dd5a461a6..b9a74ccce 100644 --- a/docs/helix/02-design/contracts/CONTRACT-052-domain-packs.md +++ b/docs/helix/02-design/contracts/CONTRACT-052-domain-packs.md @@ -368,3 +368,41 @@ This selection MUST NOT mark rights cleared or permit redistributable source ZIP export. Mixed processing MUST generate only synthetic bindings through a trusted generator, ingest observed bindings unchanged and refuse unresolved bindings or cross-boundary references before target writes. + +## Medical family composition and public fixture delivery + +Optional `family` metadata is `{id,version,label}`. Optional `composition` is +`{version:"1.0.0",components:[{id,version,label,checksum:{algorithm:"sha256",value}}]}`. +Component IDs use lowercase letters, digits and hyphens, start with a letter and +contain no path separators. Identity is exact pack ID/version. Duplicate or self +components, malformed descriptors and unsupported composition versions refuse +admission. Unknown annotation fields remain retained. These additive metadata +fields use the existing extensible domain-pack 1.0.0 envelope. + +Composition resolves only caller-selected local sibling pack directories. Each +component's manifest hash, exact identity and matching `family` declaration must +agree. Components cannot themselves contain compositions. No implicit fetching, +patient matching or cross-source joins occur. `export-domain-family.ts --pack + --output [--include-sources] [--check]` exports the root +and components into independent ID/version directories using the shared exporter; +it preflights every component before publishing and writes `family.json` with +exact manifest hashes. Rights, hash and path errors refuse the whole preflight. + +Subpacks expose CONTRACT-053 fixed tabular and graph targets. Ontologies are +declared schema companions of their exact tables, not native graph-engine or +clinical-conformance evidence. CSV/FHIR/DICOM originals stay source authorities. + +The schema explorer resolves exact composition identities and hashes within its +built catalog, shows family links and publishes only checksum-verified local +sources with explicit allowed redistribution. Row bindings link a selected table +to its CSV; source cards identify format, origin, release and qualification. +Downloads preserve exact bytes; no remote metadata URL triggers retrieval. + +CMS DE-SynPUF excerpts preserve native columns and tokens, empty cells and ICD-9 +era semantics; they are published synthetic data, not real beneficiary records. +The selected TCIA LIDC-IDRI object retains original binary and separate pydicom +JSON metadata; pixel/file-meta representation differences remain explicit. +Collection-specific CC BY 3.0 attribution accompanies redistribution. Public +source selection and native inspection are development evidence; the portable +library performs no binary parsing or pixel decoding. Live PACS/DICOMweb and +production carrier processing retain their separate future designs. diff --git a/docs/helix/02-design/technical-designs/TD-055-medical-subpacks.md b/docs/helix/02-design/technical-designs/TD-055-medical-subpacks.md index 79cad3209..ae4cb20b1 100644 --- a/docs/helix/02-design/technical-designs/TD-055-medical-subpacks.md +++ b/docs/helix/02-design/technical-designs/TD-055-medical-subpacks.md @@ -97,3 +97,20 @@ slice; no persisted core migration or cross-repository port is required. Public examples may not agree financially or resolve references. Retain originals and unresolved relationships. Public code availability does not grant unrestricted terminology rights. Source-specific notices and local licensed bindings apply. + +## Family integration and public sources + +Follow CONTRACT-052 composition metadata and family export. The deterministic +builder adds fixed execution profiles and table-derived ontology schemas to +each subpack, then fingerprints component manifests from Medical's overview. +CMS native CSV excerpts get separate schemas and source lineage without FHIR +conversion or ICD crosswalks. A TCIA object gets a separate source namespace, +recursive metadata views and unchanged binary source. Source qualification is +checked in; regeneration and browser/catalog builds never download sources. + +The explorer links family overviews, table/ontology counterparts and pinned +local original/row downloads. Site asset construction uses shared rights/hash +checks. Export preserves one directory per pack and preflights before writes. +Bun rejects stale or escaping members; Chromium exercises direct links, downloads, +search and mobile layout. Independent TableSpec and pydicom checks verify public +CSV cells, local-only joins, recursive DICOM metadata and exact archived originals. diff --git a/docs/helix/03-test/acceptance-criteria-ledger.json b/docs/helix/03-test/acceptance-criteria-ledger.json index 657ad91b6..fc2c567e8 100644 --- a/docs/helix/03-test/acceptance-criteria-ledger.json +++ b/docs/helix/03-test/acceptance-criteria-ledger.json @@ -4091,6 +4091,7 @@ "story": "docs/helix/01-frame/user-stories/US-055-medical-subpacks.md", "status": "SATISFIED", "evidence": [ + "tests/domain-packs/medical-family.test.ts:11", "tests/domain-packs/medical-subpacks.test.ts:17" ], "rationale": "A live Bun test carries a canonical citation." @@ -4119,6 +4120,7 @@ "story": "docs/helix/01-frame/user-stories/US-055-medical-subpacks.md", "status": "SATISFIED", "evidence": [ + "tests/domain-packs/medical-family.test.ts:11", "tests/domain-packs/medical-subpacks.test.ts:66" ], "rationale": "A live Bun test carries a canonical citation." @@ -4128,6 +4130,7 @@ "story": "docs/helix/01-frame/user-stories/US-055-medical-subpacks.md", "status": "SATISFIED", "evidence": [ + "tests/domain-packs/medical-family.test.ts:24", "tests/domain-packs/medical-subpacks.test.ts:113", "tests/domain-packs/medical-subpacks.test.ts:81", "tests/domain-packs/medical-subpacks.test.ts:97" @@ -4139,6 +4142,8 @@ "story": "docs/helix/01-frame/user-stories/US-055-medical-subpacks.md", "status": "SATISFIED", "evidence": [ + "tests/domain-packs/medical-family.test.ts:11", + "tests/domain-packs/medical-family.test.ts:24", "tests/domain-packs/medical-subpacks.test.ts:113", "tests/domain-packs/medical-subpacks.test.ts:97" ], diff --git a/docs/helix/03-test/test-plans/STP-055-medical-subpacks.md b/docs/helix/03-test/test-plans/STP-055-medical-subpacks.md index abc2efc44..f202af647 100644 --- a/docs/helix/03-test/test-plans/STP-055-medical-subpacks.md +++ b/docs/helix/03-test/test-plans/STP-055-medical-subpacks.md @@ -63,3 +63,17 @@ suppression/zero/unknown, exact money and nested private DICOM content. Follow TD-055: source qualification, projections, pack artifacts, consumer checks. Done requires all six criteria to pass their named scoped checks, with versions and limits recorded. Full native equivalence and live services remain unclaimed. + +## Integrated public-source and family checks + +AC1: independently compare every selected CMS CSV cell and historical native +column against the retained excerpt; show its synthetic source separately from +FHIR. AC4: pydicom checks the selected TCIA UIDs, metadata, native sequences and +original bytes without treating the private-tag synthetic case as public evidence. +AC6: validate all five fixed profiles and ontologies; export/check all family +members; reject wrong hashes, versions, duplicates, traversal, missing members +and uncleared sources before output. Chromium follows Medical-to-subpack and +back links, every table/ontology pair, CSV/FHIR/DICOM downloads, search, direct +links and mobile containment. TableSpec ingests every tabular target and recovers +both schemas and original attachments. Historical broader obligations remain +separate from acceptance of this requested sample/integration slice. diff --git a/docs/helix/04-build/evidence/medical-subpacks.md b/docs/helix/04-build/evidence/medical-subpacks.md index ec7e88f8a..4fed85ea5 100644 --- a/docs/helix/04-build/evidence/medical-subpacks.md +++ b/docs/helix/04-build/evidence/medical-subpacks.md @@ -123,3 +123,73 @@ TypeScript checks, 61 extension-package and 349 JSON Schema audits, the browser build, 60 Chromium library checks, and all 19 explorer checks including every catalog schema and all eighteen medical subpack schemas. This supplements the source and native-oracle evidence above; it does not broaden native support. + +## Integrated medical family 1.1.0 — 2026-10-08 + +The requested sample integration is complete under US-055/TD-055/STP-055. Five +1.1.0 packs preserve the unchanged clinical originals, separately versioned +carrier/epidemiology/imaging/terminology content and source namespaces. There are +29 tables, five table-derived ontology schemas and 517 projected rows. The +Medical overview and each child/schema link the whole family; old 1.0.0 browser +bookmarks redirect to the qualified current subset. One preflighted family export +retains independent directories and an exact manifest inventory. Historical +1.0.0 archives and the earlier evidence above remain available. + +Public sources add three CMS DE-SynPUF beneficiaries, five inpatient claims and +five carrier claims as exact native CSV excerpts. These are published synthetic +2008/2008–2010 data. The selection excludes numeric CPT/Level I HCPCS carrier +rows, preserves every selected native column and ICD-9-era token, and retains +upstream/member/subset hashes and original record numbers. CMS rights qualification +is limited to this subset and does not grant dictionary redistribution. FHIR R4 +originals and separately authored eligibility/authorization/payment scenarios +remain independent; no CMS-to-FHIR clinical equivalence is claimed. + +Imaging adds one unchanged, publisher-deidentified TCIA LIDC-IDRI CT slice under +CC BY 3.0, DOI 10.7937/K9/TCIA.2015.LO9QL9SX. Collection attribution and selection +are supplied with the original binary and derived pydicom JSON. This is one of +133 series instances, not a full study. Its native DICOM edition and burned-in +annotation declaration are unavailable. Three private elements are retained and +recorded; no independent deidentification certification is asserted. Native DS/IS +spellings and file/pixel bytes remain in the binary; JSON numeric normalization +and local opaque pixel BulkDataURI are explicit projection differences. + +Executed integration gates: + +- Bun 1.4.2: 48 domain-pack/traceability tests, 3,146 assertions, zero failures. + Family version/hash/rights errors refuse before output; all source bytes recover. +- Both TypeScript configurations, browser ESM/declarations, 61 extension packages, + 349 canonical schemas, medical regeneration and acceptance inventory pass. +- Chromium 153.0.8010.12: 68 portable-library checks, including public DICOM + preservation; 24 explorer checks navigate all 24 packs/273 catalog entries. + Family links, four ontology/table pairs, exact CSV/FHIR/DICOM hashes and actual + downloads, old bookmarks, search and mobile containment pass. +- TableSpec installed metadata 0.0.6.post6.dev0+d2ee70a / Python 3.12.15: + all five fixed profiles ingest; 29 tables/517 rows, 96 original attachments, + every schema and typed archive row recover. Two archives per pack match bytes. + Independent Python CSV reads compare every CMS native cell to projected cells. +- pydicom 3.0.2 / Python 3.13.16: 24 native assertions pass across synthetic and + public objects, including UIDs, transfer syntax, private content and exact bytes. +- All five published HTML signatures remain valid; no HTML seal/key change is + needed. The publication workflow now checks medical regeneration and pack + regressions, then constructs allowed sample downloads with the shared exporter. + +The [machine record](../../../../fixtures/validation/medical-family-integration-evidence.json) +fingerprints source, schema, row, tooling, catalog and new archive files. +Reproduction: `bun scripts/build-medical-subpacks.ts --check`, +`bun test tests/domain-packs tests/traceability`, +`bun docs/helix/05-deploy/microsite/build-explorer.ts`, +`bun docs/helix/05-deploy/microsite/verify-explorer.ts` with the local preview, +`bun scripts/domain-pack-browser.ts` with the browser library build, and the +existing native oracle with `--dicom-only` or `--output fixtures/domain-packs`. +`collect-medical-public-samples.py --cache ` regenerates public selections +from the explicitly downloaded archives after verifying their pinned hashes. It +never fetches from browser/pack operations. + +Initial verification found a comma in the local DICOM tag fragment, a tooling +type error, stale browser version selectors and the expected traceability snapshot +change. These were corrected and the affected gates rerun. An intermediate browser +run also compared a loaded catalog with a concurrently regenerated manifest; the +final sequential catalog/browser run passes. Full repository/native replay, full +terminology dictionaries/maps, graph storage, live PACS/DICOMweb/X12 and production +carrier behavior remain separate obligations; this delivery completes the +requested public sample and browser/family integration slice. diff --git a/docs/helix/04-build/implementation-plan.md b/docs/helix/04-build/implementation-plan.md index 89e7e6d72..c49c9b9b3 100644 --- a/docs/helix/04-build/implementation-plan.md +++ b/docs/helix/04-build/implementation-plan.md @@ -5644,3 +5644,13 @@ input/output switching, YAML generation and existing explorer preservation and navigation checks; see the schema-explorer evidence. Public deployment is not performed. Changed playground HTML requires its Innsigle signature to be renewed before publication. Rollback restores the prior viewer and rebuilds bundles. + +### Integrated medical family and public samples + +Owner direction completes the sample integration under US-055/TD-055/STP-055: +qualify bounded public CMS CSV and TCIA DICOM sources, retain exact native meaning +and originals, add all subpack fixed profiles/ontology companions, link the +Medical family in the explorer and expose allowed original/row downloads. +Preflight and export the complete family in separate versioned directories; run +Bun, actual Chromium, independent TableSpec/pydicom and deployment gates before +merging. Live PACS and production carrier services remain separate future scope. diff --git a/docs/helix/05-deploy/microsite/.gitignore b/docs/helix/05-deploy/microsite/.gitignore index 54f39e4db..0dac90afd 100644 --- a/docs/helix/05-deploy/microsite/.gitignore +++ b/docs/helix/05-deploy/microsite/.gitignore @@ -2,3 +2,5 @@ !dist/** .sites-checkout/ .sites-checkout-*/ + +/dist/pack-assets/ diff --git a/docs/helix/05-deploy/microsite/README.md b/docs/helix/05-deploy/microsite/README.md index be23d3669..eacfb5d32 100644 --- a/docs/helix/05-deploy/microsite/README.md +++ b/docs/helix/05-deploy/microsite/README.md @@ -152,3 +152,25 @@ text and downloads retain their exact bytes. JSON Schema and OpenAPI generated files default to YAML with an explicit JSON option. Avro and Spark previews use YAML for reading; their native downloads and the interchange report bundle stay JSON. SQL, GraphQL and Protobuf keep their native syntax. + + +## Integrated medical sample family 1.1.0 + +The Medical overview and each medical-family schema link Clinical, Carrier, +Epidemiology, Imaging and Terminology. All five fixed profiles have ontology/table +companions; the family contains 29 tables/five ontologies. The catalog remains +24 packs and now has 273 entries. Legacy 1.0.0 medical bookmarks redirect to the +current 1.1.0 subset. Source namespaces are never merged or matched implicitly. + +Local source-inclusive export constructs `dist/pack-assets/` during every build. +Only checksum-verified local samples with allowed rights are published; source +metadata never causes a remote fetch. Overviews download original CSV/FHIR/DICOM +files and notices; selected table pages link their bound CSV. The public CMS +synthetic excerpts retain ICD-9 meanings; TCIA LIDC-IDRI contributes one +CC BY 3.0 native CT slice with separate metadata and explicit projection losses. +`Sample scope` exposes limits while composition/execution metadata stays available +in a collapsed source detail. Deployment regenerates assets rather than committing +duplicate originals. 24 Chromium explorer checks pass, including actual public +sample downloads/hash equality, all catalog entries, family navigation, ontology +links, old bookmarks and mobile containment. Detailed reproduction and native +checks are in `../../04-build/evidence/medical-subpacks.md`. diff --git a/docs/helix/05-deploy/microsite/build-explorer.ts b/docs/helix/05-deploy/microsite/build-explorer.ts index b6d7d2deb..9ceec4320 100644 --- a/docs/helix/05-deploy/microsite/build-explorer.ts +++ b/docs/helix/05-deploy/microsite/build-explorer.ts @@ -1,10 +1,12 @@ import {resolve,relative,join,dirname,isAbsolute} from 'node:path'; -import {readdir,realpath} from 'node:fs/promises'; +import {readdir,realpath,rm} from 'node:fs/promises'; +import {resolveDomainFamily} from '../../../../scripts/domain-pack-family'; import {requireDomainPackProfile} from '../../../../src/domain-packs/profile'; import {parseEntry,type Entry} from './explorer-model'; const repo=resolve(import.meta.dir,'../../../..'),dist=join(import.meta.dir,'dist'); const supplied=process.argv.slice(2),roots=supplied.length?supplied.map(p=>resolve(p)):[...['domain-packs','packs','spec/domain-packs','examples/domain-packs'].map(p=>join(repo,p)),join(import.meta.dir,'catalog-sources')]; async function files(root:string):Promise{try{const items=await readdir(root,{withFileTypes:true});return (await Promise.all(items.filter(i=>!i.name.startsWith('.')&&i.name!=='node_modules').map(i=>i.isDirectory()?files(join(root,i.name)):Promise.resolve(/\.(json|ya?ml)$/i.test(i.name)?[join(root,i.name)]:[])))).flat().sort();}catch(error:any){if(error.code==='ENOENT'&&!supplied.length)return [];throw error;}} +await rm(join(dist,'pack-assets'),{recursive:true,force:true}); const entries:Entry[]=[],seen=new Set(),owned=new Map(); for(const root of roots){const paths=await files(root); const manifestPaths:string[]=[];for(const candidate of paths.filter(p=>p.endsWith('.json'))){const data=JSON.parse(await Bun.file(candidate).text());if(data&&typeof data.id==='string'&&data.domain_types)manifestPaths.push(candidate);} @@ -12,19 +14,28 @@ for(const root of roots){const paths=await files(root); const text=await Bun.file(path).text(),pack=JSON.parse(text);requireDomainPackProfile(pack);parseEntry({id:path,title:pack.id,category:'domain',path,text,format:'json'}); if(typeof pack.version!=='string'||!pack.domain_types)throw new Error(`Incomplete pack manifest: ${path}`); const identity=`${pack.id}@${pack.version}`;if(seen.has(identity)){if(root===join(import.meta.dir,'catalog-sources'))continue;throw new Error(`Duplicate pack identity: ${identity}`);}seen.add(identity); - entries.push({id:`pack:${identity}`,title:pack.id,category:'domain',path:'domain-pack.json',pack:pack.id,packVersion:pack.version,text,format:'json',description:pack.description}); + const packEntry:Entry={id:`pack:${identity}`,title:pack.id,category:'domain',path:'domain-pack.json',pack:pack.id,packVersion:pack.version,text,format:'json',description:pack.description}; + if(pack.family?.id==='medical'){ + const child=Bun.spawn(['bun',join(repo,'scripts/export-domain-pack.ts'),'--pack',path,'--output',join(dist,'pack-assets',identity),'--include-sources'],{stdout:'pipe',stderr:'pipe'}); + const [code,stderr]=await Promise.all([child.exited,new Response(child.stderr).text(),new Response(child.stdout).text()]);if(code)throw Error(stderr); + packEntry.assets=Object.entries(pack.sources??{}).flatMap(([id,source]:[string,any])=>!source.reference?.includes(':')&&source.license?.redistribution==='allowed'?[{id,reference:source.reference,url:'pack-assets/'+encodeURIComponent(identity)+'/'+source.reference.split('/').map(encodeURIComponent).join('/'),format:source.format??'unknown',dataKind:source.data_kind,sha256:source.checksum.value,...(source.revision?{revision:source.revision}:{})}]:[]); + packEntry.aliases=[`pack:${pack.id}@1.0.0`]; + } + entries.push(packEntry); const schemaIds=new Set();for(const declaration of pack.schemas??[]){if(schemaIds.has(declaration.id))throw new Error(`Duplicate schema ID in ${identity}: ${declaration.id}`);schemaIds.add(declaration.id); if(typeof declaration.reference!=='string'||isAbsolute(declaration.reference))throw new Error(`Invalid local reference: ${declaration.reference}`); const source=resolve(dirname(path),declaration.reference),rel=relative(dirname(path),source);if(rel.startsWith('..')||isAbsolute(rel))throw new Error(`Pack reference escapes its directory: ${declaration.reference}`); const actual=await realpath(source),actualRoot=await realpath(dirname(path)),inside=relative(actualRoot,actual);if(inside==='..'||inside.startsWith('../')||isAbsolute(inside))throw new Error('Schema symlink escapes pack'); const format=/\.ya?ml$/i.test(source)?'yaml':'json',entry:Entry={id:`schema:${identity}:${declaration.id}`,title:declaration.id,category:'domain',path:declaration.reference,pack:pack.id,packVersion:pack.version,schemaFormat:declaration.format,text:await Bun.file(source).text(),format}; - const parsed=parseEntry(entry);if(parsed.document)entry.title=String(parsed.document.title??parsed.document.id);entry.aliases=[relative(repo,source)];owned.set(actual,entry);entries.push(entry); + const parsed=parseEntry(entry);if(parsed.document)entry.title=String(parsed.document.title??parsed.document.id);entry.aliases=[relative(repo,source),...(pack.family?.id==='medical'?[`schema:${pack.id}@1.0.0:${declaration.id}`]:[])];owned.set(actual,entry);entries.push(entry); } } for(const path of paths.filter(p=>!manifestPaths.includes(p))){if(owned.has(await realpath(path)))continue;const text=await Bun.file(path).text(),format=/\.ya?ml$/i.test(path)?'yaml':'json';if(format==='json'){const value=JSON.parse(text);if(!value||typeof value.umf!=='string'||!Array.isArray(value.modules))continue;}else if(!/^umf\s*:/m.test(text))continue; const source=relative(repo,path);if(seen.has(source))continue;seen.add(source);const entry:Entry={id:source,title:source,category:'domain',path:source,text,format};const parsed=parseEntry(entry);entry.title=String(parsed.document!.title??parsed.document!.id);entries.push(entry); } } +// Family closure and hashes must resolve before publishing a catalog. +for(const root of roots){for(const path of (await files(root)).filter(p=>p.endsWith('pack.json'))){const pack=await Bun.file(path).json();if(!pack.composition)continue;const members=await resolveDomainFamily(path);for(const member of members)if(!entries.some(e=>e.id===`pack:${member.pack.id}@${member.pack.version}`))throw Error('Family component missing from catalog');}} const path='fixtures/core/schema-properties.json',text=await Bun.file(join(repo,path)).text();entries.push({id:path,title:'Orders · core schema properties',category:'example',path,text,format:'json'}); await Bun.write(join(dist,'schema-catalog.json'),JSON.stringify({version:1,entries},null,2)+'\n'); const build=await Bun.build({entrypoints:[join(import.meta.dir,'explorer.ts')],outdir:dist,target:'browser',minify:true});if(!build.success)throw new Error(build.logs.join('\n')); diff --git a/docs/helix/05-deploy/microsite/dist/explorer.js b/docs/helix/05-deploy/microsite/dist/explorer.js index 8d70302cc..197f0bc57 100644 --- a/docs/helix/05-deploy/microsite/dist/explorer.js +++ b/docs/helix/05-deploy/microsite/dist/explorer.js @@ -1,38 +1,38 @@ -var zle=Object.create;var{getPrototypeOf:Wle,defineProperty:yh,getOwnPropertyNames:IC,getOwnPropertyDescriptor:Qle}=Object,_E=Object.prototype.hasOwnProperty;function AC(e){return this[e]}var Yle,Xle,Ar=(e,t,n)=>{var r=e!=null&&typeof e==="object";if(r){var i=t?Yle??=new WeakMap:Xle??=new WeakMap,s=i.get(e);if(s)return s}n=e!=null?zle(Wle(e)):{};let o=t||!e||!e.__esModule||!_E.call(e,"default")?yh(n,"default",{value:e,enumerable:!0}):n;if(e&&typeof e==="object"||typeof e==="function"){for(let a of IC(e))if(!_E.call(o,a))yh(o,a,{get:AC.bind(e,a),enumerable:!0})}if(r)i.set(e,o);return o},Ef=(e)=>{var t=($C??=new WeakMap).get(e),n;if(t)return t;if(t=yh({},"__esModule",{value:!0}),e&&typeof e==="object"||typeof e==="function"){for(var r of IC(e))if(!_E.call(t,r))yh(t,r,{get:AC.bind(e,r),enumerable:!(n=Qle(e,r))||n.enumerable})}return $C.set(e,t),t},$C,z=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var Zle=(e)=>e;function ece(e,t){this[e]=Zle.bind(null,t)}var kf=(e,t)=>{for(var n in t)yh(e,n,{get:t[n],enumerable:!0,configurable:!0,set:ece.bind(t,n)})};var q=(e,t,n)=>()=>{if(e)try{t=e(e=0)}catch(r){n=[r]}if(n)throw n[0];return t};var hh=(e)=>Promise.all(e);function ln(e){if(e&&typeof e==="object")switch(e[Vi]){case oa:case Rl:return!0}return!1}function Yt(e){if(e&&typeof e==="object")switch(e[Vi]){case w_:case oa:case Bs:case Rl:return!0}return!1}var w_,D_,oa,xE,Bs,Rl,Vi,Vs=(e)=>!!e&&typeof e==="object"&&e[Vi]===w_,fo=(e)=>!!e&&typeof e==="object"&&e[Vi]===D_,dr=(e)=>!!e&&typeof e==="object"&&e[Vi]===oa,Vt=(e)=>!!e&&typeof e==="object"&&e[Vi]===xE,ft=(e)=>!!e&&typeof e==="object"&&e[Vi]===Bs,Gr=(e)=>!!e&&typeof e==="object"&&e[Vi]===Rl,T_=(e)=>(ft(e)||ln(e))&&!!e.anchor;var rn=q(()=>{w_=Symbol.for("yaml.alias"),D_=Symbol.for("yaml.document"),oa=Symbol.for("yaml.map"),xE=Symbol.for("yaml.pair"),Bs=Symbol.for("yaml.scalar"),Rl=Symbol.for("yaml.seq"),Vi=Symbol.for("yaml.node.type")});function aa(e,t){let n=jC(t);if(fo(e)){if(Nf(null,e.contents,n,Object.freeze([e]))===Ba)e.contents=null}else Nf(null,e,n,Object.freeze([]))}function Nf(e,t,n,r){let i=FC(e,t,n,r);if(Yt(i)||Vt(i))return CC(e,r,i),Nf(e,i,n,r);if(typeof i!=="symbol"){if(ln(t)){r=Object.freeze(r.concat(t));for(let s=0;s{rn();ls=Symbol("break visit"),RC=Symbol("skip children"),Ba=Symbol("remove node");aa.BREAK=ls;aa.SKIP=RC;aa.REMOVE=Ba;S_.BREAK=ls;S_.SKIP=RC;S_.REMOVE=Ba});class si{constructor(e,t){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},si.defaultYaml,e),this.tags=Object.assign({},si.defaultTags,t)}clone(){let e=new si(this.yaml,this.tags);return e.docStart=this.docStart,e}atDocument(){let e=new si(this.yaml,this.tags);switch(this.yaml.version){case"1.1":this.atNextDocument=!0;break;case"1.2":this.atNextDocument=!1,this.yaml={explicit:si.defaultYaml.explicit,version:"1.2"},this.tags=Object.assign({},si.defaultTags);break}return e}add(e,t){if(this.atNextDocument)this.yaml={explicit:si.defaultYaml.explicit,version:"1.1"},this.tags=Object.assign({},si.defaultTags),this.atNextDocument=!1;let n=e.trim().split(/[ \t]+/),r=n.shift();switch(r){case"%TAG":{if(n.length!==2){if(t(0,"%TAG directive should contain exactly two parts"),n.length<2)return!1}let[i,s]=n;return this.tags[i]=s,!0}case"%YAML":{if(this.yaml.explicit=!0,n.length!==1)return t(0,"%YAML directive should contain exactly one part"),!1;let[i]=n;if(i==="1.1"||i==="1.2")return this.yaml.version=i,!0;else{let s=/^\d+\.\d+$/.test(i);return t(6,`Unsupported YAML version ${i}`,s),!1}}default:return t(0,`Unknown directive ${r}`,!0),!1}}tagName(e,t){if(e==="!")return"!";if(e[0]!=="!")return t(`Not a valid tag: ${e}`),null;if(e[1]==="<"){let s=e.slice(2,-1);if(s==="!"||s==="!!")return t(`Verbatim tags aren't resolved, so ${e} is invalid.`),null;if(e[e.length-1]!==">")t("Verbatim tags must end with a >");return s}let[,n,r]=e.match(/^(.*!)([^!]*)$/s);if(!r)t(`The ${e} tag has no suffix`);let i=this.tags[n];if(i)try{return i+decodeURIComponent(r)}catch(s){return t(String(s)),null}if(n==="!")return e;return t(`Could not resolve tag: ${e}`),null}tagString(e){for(let[t,n]of Object.entries(this.tags))if(e.startsWith(n))return t+nce(e.substring(n.length));return e[0]==="!"?e:`!<${e}>`}toString(e){let t=this.yaml.explicit?[`%YAML ${this.yaml.version||"1.2"}`]:[],n=Object.entries(this.tags),r;if(e&&n.length>0&&Yt(e.contents)){let i={};aa(e.contents,(s,o)=>{if(Yt(o)&&o.tag)i[o.tag]=!0}),r=Object.keys(i)}else r=[];for(let[i,s]of n){if(i==="!!"&&s==="tag:yaml.org,2002:")continue;if(!e||r.some((o)=>o.startsWith(s)))t.push(`%TAG ${i} ${s}`)}return t.join(` -`)}}var tce,nce=(e)=>e.replace(/[!,[\]{}]/g,(t)=>tce[t]);var wE=q(()=>{rn();gh();tce={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"};si.defaultYaml={explicit:!1,version:"1.2"};si.defaultTags={"!!":"tag:yaml.org,2002:"}});function E_(e){if(/[\x00-\x19\s,[\]{}]/.test(e)){let n=`Anchor must not contain whitespace or control characters: ${JSON.stringify(e)}`;throw Error(n)}return!0}function DE(e){let t=new Set;return aa(e,{Value(n,r){if(r.anchor)t.add(r.anchor)}}),t}function TE(e,t){for(let n=1;;++n){let r=`${e}${n}`;if(!t.has(r))return r}}function MC(e,t){let n=[],r=new Map,i=null;return{onAnchor:(s)=>{n.push(s),i??(i=DE(e));let o=TE(t,i);return i.add(o),o},setAnchors:()=>{for(let s of n){let o=r.get(s);if(typeof o==="object"&&o.anchor&&(ft(o.node)||ln(o.node)))o.node.anchor=o.anchor;else{let a=Error("Failed to resolve repeated object (this should not happen)");throw a.source=s,a}}},sourceObjects:r}}var k_=q(()=>{rn();gh()});function Yc(e,t,n,r){if(r&&typeof r==="object")if(Array.isArray(r))for(let i=0,s=r.length;i{};function vr(e,t,n){if(Array.isArray(e))return e.map((r,i)=>vr(r,String(i),n));if(e&&typeof e.toJSON==="function"){if(!n||!T_(e))return e.toJSON(t,n);let r={aliasCount:0,count:1,res:void 0};n.anchors.set(e,r),n.onCreate=(s)=>{r.res=s,delete n.onCreate};let i=e.toJSON(t,n);if(n.onCreate)n.onCreate(i);return i}if(typeof e==="bigint"&&!n?.keep)return Number(e);return e}var jl=q(()=>{rn()});class kp{constructor(e){Object.defineProperty(this,Vi,{value:e})}clone(){let e=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));if(this.range)e.range=this.range.slice();return e}toJS(e,{mapAsMap:t,maxAliasCount:n,onAnchor:r,reviver:i}={}){if(!fo(e))throw TypeError("A document argument is required");let s={anchors:new Map,doc:e,keep:!0,mapAsMap:t===!0,mapKeyWarned:!1,maxAliasCount:typeof n==="number"?n:100},o=vr(this,"",s);if(typeof r==="function")for(let{count:a,res:l}of s.anchors.values())r(l,a);return typeof i==="function"?Yc(i,{"":o},"",o):o}}var N_=q(()=>{SE();rn();jl()});function O_(e,t,n){if(Vs(t)){let r=t.resolve(e),i=n&&r&&n.get(r);return i?i.count*i.aliasCount:0}else if(ln(t)){let r=0;for(let i of t.items){let s=O_(e,i,n);if(s>r)r=s}return r}else if(Vt(t)){let r=O_(e,t.key,n),i=O_(e,t.value,n);return Math.max(r,i)}return 1}var Xc;var bh=q(()=>{k_();gh();rn();N_();jl();Xc=class Xc extends kp{constructor(e){super(w_);this.source=e,Object.defineProperty(this,"tag",{set(){throw Error("Alias nodes cannot have tags")}})}resolve(e,t){if(t?.maxAliasCount===0)throw ReferenceError("Alias resolution is disabled");let n;if(t?.aliasResolveCache)n=t.aliasResolveCache;else if(n=[],aa(e,{Node:(i,s)=>{if(Vs(s)||T_(s))n.push(s)}}),t)t.aliasResolveCache=n;let r=void 0;for(let i of n){if(i===this)break;if(i.anchor===this.source)r=i}if(r&&t){let{anchors:i,doc:s,maxAliasCount:o}=t,a=i.get(r);if(!a)vr(r,null,t),a=i.get(r);if(a?.res===void 0)throw ReferenceError("This should not happen: Alias anchor was not resolved?");if(o>=0){if(a.count+=1,a.aliasCount===0)a.aliasCount=O_(s,r,i);if(a.count*a.aliasCount>o)throw ReferenceError("Excessive alias count indicates a resource exhaustion attack")}}return r}toJSON(e,t){if(!t)return{source:this.source};let n=this.resolve(t.doc,t);if(!n){let r=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw ReferenceError(r)}return t.anchors.get(n).res}toString(e,t,n){let r=`*${this.source}`;if(e){if(E_(this.source),e.options.verifyAliasOrder&&!e.anchors.has(this.source)){let i=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw Error(i)}if(e.implicitKey)return`${r} `}return r}}});var P_=(e)=>!e||typeof e!=="function"&&typeof e!=="object",at;var _r=q(()=>{rn();N_();jl();at=class at extends kp{constructor(e){super(Bs);this.value=e}toJSON(e,t){return t?.keep?this.value:vr(this.value,e,t)}toString(){return String(this.value)}};at.BLOCK_FOLDED="BLOCK_FOLDED";at.BLOCK_LITERAL="BLOCK_LITERAL";at.PLAIN="PLAIN";at.QUOTE_DOUBLE="QUOTE_DOUBLE";at.QUOTE_SINGLE="QUOTE_SINGLE"});function ice(e,t,n){if(t){let r=n.filter((s)=>s.tag===t),i=r.find((s)=>!s.format)??r[0];if(!i)throw Error(`Tag ${t} not found`);return i}return n.find((r)=>r.identify?.(e)&&!r.format)}function Va(e,t,n){if(fo(e))e=e.contents;if(Yt(e))return e;if(Vt(e)){let p=n.schema[oa].createNode?.(n.schema,null,n);return p.items.push(e),p}if(e instanceof String||e instanceof Number||e instanceof Boolean||typeof BigInt<"u"&&e instanceof BigInt)e=e.valueOf();let{aliasDuplicateObjects:r,onAnchor:i,onTagObj:s,schema:o,sourceObjects:a}=n,l=void 0;if(r&&e&&typeof e==="object")if(l=a.get(e),l)return l.anchor??(l.anchor=i(e)),new Xc(l.anchor);else l={anchor:null,node:null},a.set(e,l);if(t?.startsWith("!!"))t=rce+t.slice(2);let c=ice(e,t,o.tags);if(!c){if(e&&typeof e.toJSON==="function")e=e.toJSON();if(!e||typeof e!=="object"){let p=new at(e);if(l)l.node=p;return p}c=e instanceof Map?o[oa]:(Symbol.iterator in Object(e))?o[Rl]:o[oa]}if(s)s(c),delete n.onTagObj;let u=c?.createNode?c.createNode(n.schema,e,n):typeof c?.nodeClass?.from==="function"?c.nodeClass.from(n.schema,e,n):new at(e);if(t)u.tag=t;else if(!c.default)u.tag=c.tag;if(l)l.node=u;return u}var rce="tag:yaml.org,2002:";var Pf=q(()=>{bh();rn();_r()});function vh(e,t,n){let r=n;for(let i=t.length-1;i>=0;--i){let s=t[i];if(typeof s==="number"&&Number.isInteger(s)&&s>=0){let o=[];o[s]=r,r=o}else r=new Map([[s,r]])}return Va(r,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw Error("This should not happen, please report a bug.")},schema:e,sourceObjects:new Map})}var $f=(e)=>e==null||typeof e==="object"&&!!e[Symbol.iterator]().next().done,_h;var $_=q(()=>{Pf();rn();N_();_h=class _h extends kp{constructor(e,t){super(e);Object.defineProperty(this,"schema",{value:t,configurable:!0,enumerable:!1,writable:!0})}clone(e){let t=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));if(e)t.schema=e;if(t.items=t.items.map((n)=>Yt(n)||Vt(n)?n.clone(e):n),this.range)t.range=this.range.slice();return t}addIn(e,t){if($f(e))this.add(t);else{let[n,...r]=e,i=this.get(n,!0);if(ln(i))i.addIn(r,t);else if(i===void 0&&this.schema)this.set(n,vh(this.schema,r,t));else throw Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}deleteIn(e){let[t,...n]=e;if(n.length===0)return this.delete(t);let r=this.get(t,!0);if(ln(r))return r.deleteIn(n);else throw Error(`Expected YAML collection at ${t}. Remaining path: ${n}`)}getIn(e,t){let[n,...r]=e,i=this.get(n,!0);if(r.length===0)return!t&&ft(i)?i.value:i;else return ln(i)?i.getIn(r,t):void 0}hasAllNullValues(e){return this.items.every((t)=>{if(!Vt(t))return!1;let n=t.value;return n==null||e&&ft(n)&&n.value==null&&!n.commentBefore&&!n.comment&&!n.tag})}hasIn(e){let[t,...n]=e;if(n.length===0)return this.has(t);let r=this.get(t,!0);return ln(r)?r.hasIn(n):!1}setIn(e,t){let[n,...r]=e;if(r.length===0)this.set(n,t);else{let i=this.get(n,!0);if(ln(i))i.setIn(r,t);else if(i===void 0&&this.schema)this.set(n,vh(this.schema,r,t));else throw Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}}});function mo(e,t){if(/^\n+$/.test(e))return e.substring(1);return t?e.replace(/^(?! *$)/gm,t):e}var LC=(e)=>e.replace(/^(?!$)(?: $)?/gm,"#"),Ka=(e,t,n)=>e.endsWith(` +var Wle=Object.create;var{getPrototypeOf:Qle,defineProperty:yh,getOwnPropertyNames:IC,getOwnPropertyDescriptor:Yle}=Object,_E=Object.prototype.hasOwnProperty;function AC(e){return this[e]}var Xle,Zle,Rr=(e,t,n)=>{var r=e!=null&&typeof e==="object";if(r){var i=t?Xle??=new WeakMap:Zle??=new WeakMap,s=i.get(e);if(s)return s}n=e!=null?Wle(Qle(e)):{};let o=t||!e||!e.__esModule||!_E.call(e,"default")?yh(n,"default",{value:e,enumerable:!0}):n;if(e&&typeof e==="object"||typeof e==="function"){for(let a of IC(e))if(!_E.call(o,a))yh(o,a,{get:AC.bind(e,a),enumerable:!0})}if(r)i.set(e,o);return o},Nf=(e)=>{var t=($C??=new WeakMap).get(e),n;if(t)return t;if(t=yh({},"__esModule",{value:!0}),e&&typeof e==="object"||typeof e==="function"){for(var r of IC(e))if(!_E.call(t,r))yh(t,r,{get:AC.bind(e,r),enumerable:!(n=Yle(e,r))||n.enumerable})}return $C.set(e,t),t},$C,z=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var ece=(e)=>e;function tce(e,t){this[e]=ece.bind(null,t)}var Of=(e,t)=>{for(var n in t)yh(e,n,{get:t[n],enumerable:!0,configurable:!0,set:tce.bind(t,n)})};var q=(e,t,n)=>()=>{if(e)try{t=e(e=0)}catch(r){n=[r]}if(n)throw n[0];return t};var hh=(e)=>Promise.all(e);function ln(e){if(e&&typeof e==="object")switch(e[Ki]){case oa:case Rl:return!0}return!1}function Yt(e){if(e&&typeof e==="object")switch(e[Ki]){case w_:case oa:case Vs:case Rl:return!0}return!1}var w_,D_,oa,xE,Vs,Rl,Ki,Ks=(e)=>!!e&&typeof e==="object"&&e[Ki]===w_,fo=(e)=>!!e&&typeof e==="object"&&e[Ki]===D_,dr=(e)=>!!e&&typeof e==="object"&&e[Ki]===oa,Vt=(e)=>!!e&&typeof e==="object"&&e[Ki]===xE,ft=(e)=>!!e&&typeof e==="object"&&e[Ki]===Vs,Hr=(e)=>!!e&&typeof e==="object"&&e[Ki]===Rl,T_=(e)=>(ft(e)||ln(e))&&!!e.anchor;var rn=q(()=>{w_=Symbol.for("yaml.alias"),D_=Symbol.for("yaml.document"),oa=Symbol.for("yaml.map"),xE=Symbol.for("yaml.pair"),Vs=Symbol.for("yaml.scalar"),Rl=Symbol.for("yaml.seq"),Ki=Symbol.for("yaml.node.type")});function aa(e,t){let n=jC(t);if(fo(e)){if(Pf(null,e.contents,n,Object.freeze([e]))===Ba)e.contents=null}else Pf(null,e,n,Object.freeze([]))}function Pf(e,t,n,r){let i=FC(e,t,n,r);if(Yt(i)||Vt(i))return CC(e,r,i),Pf(e,i,n,r);if(typeof i!=="symbol"){if(ln(t)){r=Object.freeze(r.concat(t));for(let s=0;s{rn();cs=Symbol("break visit"),RC=Symbol("skip children"),Ba=Symbol("remove node");aa.BREAK=cs;aa.SKIP=RC;aa.REMOVE=Ba;S_.BREAK=cs;S_.SKIP=RC;S_.REMOVE=Ba});class oi{constructor(e,t){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},oi.defaultYaml,e),this.tags=Object.assign({},oi.defaultTags,t)}clone(){let e=new oi(this.yaml,this.tags);return e.docStart=this.docStart,e}atDocument(){let e=new oi(this.yaml,this.tags);switch(this.yaml.version){case"1.1":this.atNextDocument=!0;break;case"1.2":this.atNextDocument=!1,this.yaml={explicit:oi.defaultYaml.explicit,version:"1.2"},this.tags=Object.assign({},oi.defaultTags);break}return e}add(e,t){if(this.atNextDocument)this.yaml={explicit:oi.defaultYaml.explicit,version:"1.1"},this.tags=Object.assign({},oi.defaultTags),this.atNextDocument=!1;let n=e.trim().split(/[ \t]+/),r=n.shift();switch(r){case"%TAG":{if(n.length!==2){if(t(0,"%TAG directive should contain exactly two parts"),n.length<2)return!1}let[i,s]=n;return this.tags[i]=s,!0}case"%YAML":{if(this.yaml.explicit=!0,n.length!==1)return t(0,"%YAML directive should contain exactly one part"),!1;let[i]=n;if(i==="1.1"||i==="1.2")return this.yaml.version=i,!0;else{let s=/^\d+\.\d+$/.test(i);return t(6,`Unsupported YAML version ${i}`,s),!1}}default:return t(0,`Unknown directive ${r}`,!0),!1}}tagName(e,t){if(e==="!")return"!";if(e[0]!=="!")return t(`Not a valid tag: ${e}`),null;if(e[1]==="<"){let s=e.slice(2,-1);if(s==="!"||s==="!!")return t(`Verbatim tags aren't resolved, so ${e} is invalid.`),null;if(e[e.length-1]!==">")t("Verbatim tags must end with a >");return s}let[,n,r]=e.match(/^(.*!)([^!]*)$/s);if(!r)t(`The ${e} tag has no suffix`);let i=this.tags[n];if(i)try{return i+decodeURIComponent(r)}catch(s){return t(String(s)),null}if(n==="!")return e;return t(`Could not resolve tag: ${e}`),null}tagString(e){for(let[t,n]of Object.entries(this.tags))if(e.startsWith(n))return t+rce(e.substring(n.length));return e[0]==="!"?e:`!<${e}>`}toString(e){let t=this.yaml.explicit?[`%YAML ${this.yaml.version||"1.2"}`]:[],n=Object.entries(this.tags),r;if(e&&n.length>0&&Yt(e.contents)){let i={};aa(e.contents,(s,o)=>{if(Yt(o)&&o.tag)i[o.tag]=!0}),r=Object.keys(i)}else r=[];for(let[i,s]of n){if(i==="!!"&&s==="tag:yaml.org,2002:")continue;if(!e||r.some((o)=>o.startsWith(s)))t.push(`%TAG ${i} ${s}`)}return t.join(` +`)}}var nce,rce=(e)=>e.replace(/[!,[\]{}]/g,(t)=>nce[t]);var wE=q(()=>{rn();gh();nce={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"};oi.defaultYaml={explicit:!1,version:"1.2"};oi.defaultTags={"!!":"tag:yaml.org,2002:"}});function E_(e){if(/[\x00-\x19\s,[\]{}]/.test(e)){let n=`Anchor must not contain whitespace or control characters: ${JSON.stringify(e)}`;throw Error(n)}return!0}function DE(e){let t=new Set;return aa(e,{Value(n,r){if(r.anchor)t.add(r.anchor)}}),t}function TE(e,t){for(let n=1;;++n){let r=`${e}${n}`;if(!t.has(r))return r}}function MC(e,t){let n=[],r=new Map,i=null;return{onAnchor:(s)=>{n.push(s),i??(i=DE(e));let o=TE(t,i);return i.add(o),o},setAnchors:()=>{for(let s of n){let o=r.get(s);if(typeof o==="object"&&o.anchor&&(ft(o.node)||ln(o.node)))o.node.anchor=o.anchor;else{let a=Error("Failed to resolve repeated object (this should not happen)");throw a.source=s,a}}},sourceObjects:r}}var k_=q(()=>{rn();gh()});function Xc(e,t,n,r){if(r&&typeof r==="object")if(Array.isArray(r))for(let i=0,s=r.length;i{};function _r(e,t,n){if(Array.isArray(e))return e.map((r,i)=>_r(r,String(i),n));if(e&&typeof e.toJSON==="function"){if(!n||!T_(e))return e.toJSON(t,n);let r={aliasCount:0,count:1,res:void 0};n.anchors.set(e,r),n.onCreate=(s)=>{r.res=s,delete n.onCreate};let i=e.toJSON(t,n);if(n.onCreate)n.onCreate(i);return i}if(typeof e==="bigint"&&!n?.keep)return Number(e);return e}var jl=q(()=>{rn()});class Op{constructor(e){Object.defineProperty(this,Ki,{value:e})}clone(){let e=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));if(this.range)e.range=this.range.slice();return e}toJS(e,{mapAsMap:t,maxAliasCount:n,onAnchor:r,reviver:i}={}){if(!fo(e))throw TypeError("A document argument is required");let s={anchors:new Map,doc:e,keep:!0,mapAsMap:t===!0,mapKeyWarned:!1,maxAliasCount:typeof n==="number"?n:100},o=_r(this,"",s);if(typeof r==="function")for(let{count:a,res:l}of s.anchors.values())r(l,a);return typeof i==="function"?Xc(i,{"":o},"",o):o}}var N_=q(()=>{SE();rn();jl()});function O_(e,t,n){if(Ks(t)){let r=t.resolve(e),i=n&&r&&n.get(r);return i?i.count*i.aliasCount:0}else if(ln(t)){let r=0;for(let i of t.items){let s=O_(e,i,n);if(s>r)r=s}return r}else if(Vt(t)){let r=O_(e,t.key,n),i=O_(e,t.value,n);return Math.max(r,i)}return 1}var Zc;var bh=q(()=>{k_();gh();rn();N_();jl();Zc=class Zc extends Op{constructor(e){super(w_);this.source=e,Object.defineProperty(this,"tag",{set(){throw Error("Alias nodes cannot have tags")}})}resolve(e,t){if(t?.maxAliasCount===0)throw ReferenceError("Alias resolution is disabled");let n;if(t?.aliasResolveCache)n=t.aliasResolveCache;else if(n=[],aa(e,{Node:(i,s)=>{if(Ks(s)||T_(s))n.push(s)}}),t)t.aliasResolveCache=n;let r=void 0;for(let i of n){if(i===this)break;if(i.anchor===this.source)r=i}if(r&&t){let{anchors:i,doc:s,maxAliasCount:o}=t,a=i.get(r);if(!a)_r(r,null,t),a=i.get(r);if(a?.res===void 0)throw ReferenceError("This should not happen: Alias anchor was not resolved?");if(o>=0){if(a.count+=1,a.aliasCount===0)a.aliasCount=O_(s,r,i);if(a.count*a.aliasCount>o)throw ReferenceError("Excessive alias count indicates a resource exhaustion attack")}}return r}toJSON(e,t){if(!t)return{source:this.source};let n=this.resolve(t.doc,t);if(!n){let r=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw ReferenceError(r)}return t.anchors.get(n).res}toString(e,t,n){let r=`*${this.source}`;if(e){if(E_(this.source),e.options.verifyAliasOrder&&!e.anchors.has(this.source)){let i=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw Error(i)}if(e.implicitKey)return`${r} `}return r}}});var P_=(e)=>!e||typeof e!=="function"&&typeof e!=="object",at;var xr=q(()=>{rn();N_();jl();at=class at extends Op{constructor(e){super(Vs);this.value=e}toJSON(e,t){return t?.keep?this.value:_r(this.value,e,t)}toString(){return String(this.value)}};at.BLOCK_FOLDED="BLOCK_FOLDED";at.BLOCK_LITERAL="BLOCK_LITERAL";at.PLAIN="PLAIN";at.QUOTE_DOUBLE="QUOTE_DOUBLE";at.QUOTE_SINGLE="QUOTE_SINGLE"});function sce(e,t,n){if(t){let r=n.filter((s)=>s.tag===t),i=r.find((s)=>!s.format)??r[0];if(!i)throw Error(`Tag ${t} not found`);return i}return n.find((r)=>r.identify?.(e)&&!r.format)}function Va(e,t,n){if(fo(e))e=e.contents;if(Yt(e))return e;if(Vt(e)){let p=n.schema[oa].createNode?.(n.schema,null,n);return p.items.push(e),p}if(e instanceof String||e instanceof Number||e instanceof Boolean||typeof BigInt<"u"&&e instanceof BigInt)e=e.valueOf();let{aliasDuplicateObjects:r,onAnchor:i,onTagObj:s,schema:o,sourceObjects:a}=n,l=void 0;if(r&&e&&typeof e==="object")if(l=a.get(e),l)return l.anchor??(l.anchor=i(e)),new Zc(l.anchor);else l={anchor:null,node:null},a.set(e,l);if(t?.startsWith("!!"))t=ice+t.slice(2);let c=sce(e,t,o.tags);if(!c){if(e&&typeof e.toJSON==="function")e=e.toJSON();if(!e||typeof e!=="object"){let p=new at(e);if(l)l.node=p;return p}c=e instanceof Map?o[oa]:(Symbol.iterator in Object(e))?o[Rl]:o[oa]}if(s)s(c),delete n.onTagObj;let u=c?.createNode?c.createNode(n.schema,e,n):typeof c?.nodeClass?.from==="function"?c.nodeClass.from(n.schema,e,n):new at(e);if(t)u.tag=t;else if(!c.default)u.tag=c.tag;if(l)l.node=u;return u}var ice="tag:yaml.org,2002:";var If=q(()=>{bh();rn();xr()});function vh(e,t,n){let r=n;for(let i=t.length-1;i>=0;--i){let s=t[i];if(typeof s==="number"&&Number.isInteger(s)&&s>=0){let o=[];o[s]=r,r=o}else r=new Map([[s,r]])}return Va(r,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw Error("This should not happen, please report a bug.")},schema:e,sourceObjects:new Map})}var Af=(e)=>e==null||typeof e==="object"&&!!e[Symbol.iterator]().next().done,_h;var $_=q(()=>{If();rn();N_();_h=class _h extends Op{constructor(e,t){super(e);Object.defineProperty(this,"schema",{value:t,configurable:!0,enumerable:!1,writable:!0})}clone(e){let t=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));if(e)t.schema=e;if(t.items=t.items.map((n)=>Yt(n)||Vt(n)?n.clone(e):n),this.range)t.range=this.range.slice();return t}addIn(e,t){if(Af(e))this.add(t);else{let[n,...r]=e,i=this.get(n,!0);if(ln(i))i.addIn(r,t);else if(i===void 0&&this.schema)this.set(n,vh(this.schema,r,t));else throw Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}deleteIn(e){let[t,...n]=e;if(n.length===0)return this.delete(t);let r=this.get(t,!0);if(ln(r))return r.deleteIn(n);else throw Error(`Expected YAML collection at ${t}. Remaining path: ${n}`)}getIn(e,t){let[n,...r]=e,i=this.get(n,!0);if(r.length===0)return!t&&ft(i)?i.value:i;else return ln(i)?i.getIn(r,t):void 0}hasAllNullValues(e){return this.items.every((t)=>{if(!Vt(t))return!1;let n=t.value;return n==null||e&&ft(n)&&n.value==null&&!n.commentBefore&&!n.comment&&!n.tag})}hasIn(e){let[t,...n]=e;if(n.length===0)return this.has(t);let r=this.get(t,!0);return ln(r)?r.hasIn(n):!1}setIn(e,t){let[n,...r]=e;if(r.length===0)this.set(n,t);else{let i=this.get(n,!0);if(ln(i))i.setIn(r,t);else if(i===void 0&&this.schema)this.set(n,vh(this.schema,r,t));else throw Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}}});function mo(e,t){if(/^\n+$/.test(e))return e.substring(1);return t?e.replace(/^(?! *$)/gm,t):e}var LC=(e)=>e.replace(/^(?!$)(?: $)?/gm,"#"),Ka=(e,t,n)=>e.endsWith(` `)?mo(n,t):n.includes(` `)?` -`+mo(n,t):(e.endsWith(" ")?"":" ")+n;var xh=()=>{};function If(e,t,n="flow",{indentAtStart:r,lineWidth:i=80,minContentWidth:s=20,onFold:o,onOverflow:a}={}){if(!i||i<0)return e;if(ii-Math.max(2,s))c.push(0);else p=i-r;let d=void 0,f=void 0,m=!1,y=-1,h=-1,b=-1;if(n==="block"){if(y=qC(e,y,t.length),y!==-1)p=y+l}for(let x;x=e[y+=1];){if(n==="quoted"&&x==="\\"){switch(h=y,e[y+1]){case"x":y+=3;break;case"u":y+=5;break;case"U":y+=9;break;default:y+=1}b=y}if(x===` +`+mo(n,t):(e.endsWith(" ")?"":" ")+n;var xh=()=>{};function Rf(e,t,n="flow",{indentAtStart:r,lineWidth:i=80,minContentWidth:s=20,onFold:o,onOverflow:a}={}){if(!i||i<0)return e;if(ii-Math.max(2,s))c.push(0);else p=i-r;let d=void 0,f=void 0,m=!1,y=-1,h=-1,b=-1;if(n==="block"){if(y=qC(e,y,t.length),y!==-1)p=y+l}for(let x;x=e[y+=1];){if(n==="quoted"&&x==="\\"){switch(h=y,e[y+1]){case"x":y+=3;break;case"u":y+=5;break;case"U":y+=9;break;default:y+=1}b=y}if(x===` `){if(n==="block")y=qC(e,y,t.length);p=y+t.length+l,d=void 0}else{if(x===" "&&f&&f!==" "&&f!==` `&&f!=="\t"){let v=e[y+1];if(v&&v!==" "&&v!==` `&&v!=="\t")d=y}if(y>=p)if(d)c.push(d),p=d+l,d=void 0;else if(n==="quoted"){while(f===" "||f==="\t")f=x,x=e[y+=1],m=!0;let v=y>b+1?y-2:h-1;if(u[v])return e;c.push(v),u[v]=!0,p=v+l,d=void 0}else m=!0}f=x}if(m&&a)a();if(c.length===0)return e;if(o)o();let g=e.slice(0,c[0]);for(let x=0;x{};function sce(e,t,n){if(!t||t<0)return!1;let r=t-n,i=e.length;if(i<=r)return!1;for(let s=0,o=0;s{};function oce(e,t,n){if(!t||t<0)return!1;let r=t-n,i=e.length;if(i<=r)return!1;for(let s=0,o=0;sr)return!0;if(o=s+1,i-o<=r)return!1}return!0}function wh(e,t){let n=JSON.stringify(e);if(t.options.doubleQuotedAsJSON)return n;let{implicitKey:r}=t,i=t.options.doubleQuotedMinMultiLineLength,s=t.indent||(R_(e)?" ":""),o="",a=0;for(let l=0,c=n[l];c;c=n[++l]){if(c===" "&&n[l+1]==="\\"&&n[l+2]==="n")o+=n.slice(a,l)+"\\ ",l+=1,a=l,c="\\";if(c==="\\")switch(n[l+1]){case"u":{o+=n.slice(a,l);let u=n.substr(l+2,4);switch(u){case"0000":o+="\\0";break;case"0007":o+="\\a";break;case"000b":o+="\\v";break;case"001b":o+="\\e";break;case"0085":o+="\\N";break;case"00a0":o+="\\_";break;case"2028":o+="\\L";break;case"2029":o+="\\P";break;default:if(u.substr(0,2)==="00")o+="\\x"+u.substr(2);else o+=n.substr(l,6)}l+=5,a=l+1}break;case"n":if(r||n[l+2]==='"'||n.length `;let p,d;for(d=n.length;d>0;--d){let D=n[d-1];if(D!==` `&&D!=="\t"&&D!==" ")break}let f=n.substring(d),m=f.indexOf(` `);if(m===-1)p="-";else if(n===f||m!==f.length-1){if(p="+",s)s()}else p="";if(f){if(n=n.slice(0,-f.length),f[f.length-1]===` `)f=f.slice(0,-1);f=f.replace(OE,`$&${c}`)}let y=!1,h,b=-1;for(h=0;h{T=!0};let O=If(`${g}${D}${f}`,c,UC,N);if(!T)return`>${v} +$&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,"$1$2").replace(/\n+/g,`$&${c}`),T=!1,N=A_(r,!0);if(o!=="folded"&&t!==at.BLOCK_FOLDED)N.onOverflow=()=>{T=!0};let O=Rf(`${g}${D}${f}`,c,UC,N);if(!T)return`>${v} ${c}${O}`}return n=n.replace(/\n+/g,`$&${c}`),`|${v} -${c}${g}${n}${f}`}function oce(e,t,n,r){let{type:i,value:s}=e,{actualString:o,implicitKey:a,indent:l,indentStep:c,inFlow:u}=t;if(a&&s.includes(` -`)||u&&/[[\]{},]/.test(s))return Af(s,t);if(/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(s))return a||u||!s.includes(` -`)?Af(s,t):I_(e,t,n,r);if(!a&&!u&&i!==at.PLAIN&&s.includes(` -`))return I_(e,t,n,r);if(R_(s)){if(l==="")return t.forceBlockIndent=!0,I_(e,t,n,r);else if(a&&l===c)return Af(s,t)}let p=s.replace(/\n+/g,`$& -${l}`);if(o){let d=(y)=>y.default&&y.tag!=="tag:yaml.org,2002:str"&&y.test?.test(p),{compat:f,tags:m}=t.doc.schema;if(m.some(d)||f?.some(d))return Af(s,t)}return a?p:If(p,l,EE,A_(t,!1))}function Zc(e,t,n,r){let{implicitKey:i,inFlow:s}=t,o=typeof e.value==="string"?e:Object.assign({},e,{value:String(e.value)}),{type:a}=e;if(a!==at.QUOTE_DOUBLE){if(/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value))a=at.QUOTE_DOUBLE}let l=(u)=>{switch(u){case at.BLOCK_FOLDED:case at.BLOCK_LITERAL:return i||s?Af(o.value,t):I_(o,t,n,r);case at.QUOTE_DOUBLE:return wh(o.value,t);case at.QUOTE_SINGLE:return NE(o.value,t);case at.PLAIN:return oce(o,t,n,r);default:return null}},c=l(a);if(c===null){let{defaultKeyType:u,defaultStringType:p}=t.options,d=i&&u||p;if(c=l(d),c===null)throw Error(`Unsupported default string type ${d}`)}return c}var A_=(e,t)=>({indentAtStart:t?e.indent.length:e.indentAtStart,lineWidth:e.options.lineWidth,minContentWidth:e.options.minContentWidth}),R_=(e)=>/^(%|---|\.\.\.)/m.test(e),OE;var Rf=q(()=>{_r();kE();try{OE=new RegExp(`(^|(?'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(s))return a||u||!s.includes(` +`)?jf(s,t):I_(e,t,n,r);if(!a&&!u&&i!==at.PLAIN&&s.includes(` +`))return I_(e,t,n,r);if(R_(s)){if(l==="")return t.forceBlockIndent=!0,I_(e,t,n,r);else if(a&&l===c)return jf(s,t)}let p=s.replace(/\n+/g,`$& +${l}`);if(o){let d=(y)=>y.default&&y.tag!=="tag:yaml.org,2002:str"&&y.test?.test(p),{compat:f,tags:m}=t.doc.schema;if(m.some(d)||f?.some(d))return jf(s,t)}return a?p:Rf(p,l,EE,A_(t,!1))}function eu(e,t,n,r){let{implicitKey:i,inFlow:s}=t,o=typeof e.value==="string"?e:Object.assign({},e,{value:String(e.value)}),{type:a}=e;if(a!==at.QUOTE_DOUBLE){if(/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value))a=at.QUOTE_DOUBLE}let l=(u)=>{switch(u){case at.BLOCK_FOLDED:case at.BLOCK_LITERAL:return i||s?jf(o.value,t):I_(o,t,n,r);case at.QUOTE_DOUBLE:return wh(o.value,t);case at.QUOTE_SINGLE:return NE(o.value,t);case at.PLAIN:return ace(o,t,n,r);default:return null}},c=l(a);if(c===null){let{defaultKeyType:u,defaultStringType:p}=t.options,d=i&&u||p;if(c=l(d),c===null)throw Error(`Unsupported default string type ${d}`)}return c}var A_=(e,t)=>({indentAtStart:t?e.indent.length:e.indentAtStart,lineWidth:e.options.lineWidth,minContentWidth:e.options.minContentWidth}),R_=(e)=>/^(%|---|\.\.\.)/m.test(e),OE;var Ff=q(()=>{xr();kE();try{OE=new RegExp(`(^|(?s.tag===t.tag);if(i.length>0)return i.find((s)=>s.format===t.format)??i[0]}let n=void 0,r;if(ft(t)){r=t.value;let i=e.filter((s)=>s.identify?.(r));if(i.length>1){let s=i.filter((o)=>o.test);if(s.length>0)i=s}n=i.find((s)=>s.format===t.format)??i.find((s)=>!s.format)}else r=t,n=e.find((i)=>i.nodeClass&&r instanceof i.nodeClass);if(!n){let i=r?.constructor?.name??(r===null?"null":typeof r);throw Error(`Tag not resolved for ${i} value`)}return n}function lce(e,t,{anchors:n,doc:r}){if(!r.directives)return"";let i=[],s=(ft(e)||ln(e))&&e.anchor;if(s&&E_(s))n.add(s),i.push(`&${s}`);let o=e.tag??(t.default?null:t.tag);if(o)i.push(r.directives.tagString(o));return i.join(" ")}function Fl(e,t,n,r){if(Vt(e))return e.toString(t,n,r);if(Vs(e)){if(t.doc.directives)return e.toString(t);if(t.resolvedAliases?.has(e))throw TypeError("Cannot stringify circular structure without alias nodes");else{if(t.resolvedAliases)t.resolvedAliases.add(e);else t.resolvedAliases=new Set([e]);e=e.resolve(t.doc)}}let i=void 0,s=Yt(e)?e:t.doc.createNode(e,{onTagObj:(l)=>i=l});i??(i=ace(t.doc.schema.tags,s));let o=lce(s,i,t);if(o.length>0)t.indentAtStart=(t.indentAtStart??0)+o.length+1;let a=typeof i.stringify==="function"?i.stringify(s,t,n,r):ft(s)?Zc(s,t,n,r):s.toString(t,n,r);if(!o)return a;return ft(s)||a[0]==="{"||a[0]==="["?`${o} ${a}`:`${o} -${t.indent}${a}`}var Dh=q(()=>{k_();rn();xh();Rf()});function VC({key:e,value:t},n,r,i){let{allNullValues:s,doc:o,indent:a,indentStep:l,options:{commentString:c,indentSeq:u,simpleKeys:p}}=n,d=Yt(e)&&e.comment||null;if(p){if(d)throw Error("With simple keys, key nodes cannot have comments");if(ln(e)||!Yt(e)&&typeof e==="object")throw Error("With simple keys, collection cannot be used as a key value")}let f=!p&&(!e||d&&t==null&&!n.inFlow||ln(e)||(ft(e)?e.type===at.BLOCK_FOLDED||e.type===at.BLOCK_LITERAL:typeof e==="object"));n=Object.assign({},n,{allNullValues:!1,implicitKey:!f&&(p||!s),indent:a+l});let m=!1,y=!1,h=Fl(e,n,()=>m=!0,()=>y=!0);if(!f&&!n.inFlow&&h.length>1024){if(p)throw Error("With simple keys, single line scalar must not span more than 1024 characters");f=!0}if(n.inFlow){if(s||t==null){if(m&&r)r();return h===""?"?":f?`? ${h}`:h}}else if(s&&!p||t==null&&f){if(h=`? ${h}`,d&&!m)h+=Ka(h,n.indent,c(d));else if(y&&i)i();return h}if(m)d=null;if(f){if(d)h+=Ka(h,n.indent,c(d));h=`? ${h} -${a}:`}else if(h=`${h}:`,d)h+=Ka(h,n.indent,c(d));let b,g,x;if(Yt(t))b=!!t.spaceBefore,g=t.commentBefore,x=t.comment;else if(b=!1,g=null,x=null,t&&typeof t==="object")t=o.createNode(t);if(n.implicitKey=!1,!f&&!d&&ft(t))n.indentAtStart=h.length+1;if(y=!1,!u&&l.length>=2&&!n.inFlow&&!f&&Gr(t)&&!t.flow&&!t.tag&&!t.anchor)n.indent=n.indent.substring(2);let v=!1,D=Fl(t,n,()=>v=!0,()=>y=!0),T=" ";if(d||b||g){if(T=b?` +|$)`,"g")}catch{OE=/\n+(?!\n|$)/g}});function j_(e,t){let n=Object.assign({blockQuote:!0,commentString:LC,defaultKeyType:null,defaultStringType:"PLAIN",directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:"false",flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:"null",simpleKeys:!1,singleQuote:null,trailingComma:!1,trueStr:"true",verifyAliasOrder:!0},e.schema.toStringOptions,t),r;switch(n.collectionStyle){case"block":r=!1;break;case"flow":r=!0;break;default:r=null}return{anchors:new Set,doc:e,flowCollectionPadding:n.flowCollectionPadding?" ":"",indent:"",indentStep:typeof n.indent==="number"?" ".repeat(n.indent):" ",inFlow:r,options:n}}function lce(e,t){if(t.tag){let i=e.filter((s)=>s.tag===t.tag);if(i.length>0)return i.find((s)=>s.format===t.format)??i[0]}let n=void 0,r;if(ft(t)){r=t.value;let i=e.filter((s)=>s.identify?.(r));if(i.length>1){let s=i.filter((o)=>o.test);if(s.length>0)i=s}n=i.find((s)=>s.format===t.format)??i.find((s)=>!s.format)}else r=t,n=e.find((i)=>i.nodeClass&&r instanceof i.nodeClass);if(!n){let i=r?.constructor?.name??(r===null?"null":typeof r);throw Error(`Tag not resolved for ${i} value`)}return n}function cce(e,t,{anchors:n,doc:r}){if(!r.directives)return"";let i=[],s=(ft(e)||ln(e))&&e.anchor;if(s&&E_(s))n.add(s),i.push(`&${s}`);let o=e.tag??(t.default?null:t.tag);if(o)i.push(r.directives.tagString(o));return i.join(" ")}function Fl(e,t,n,r){if(Vt(e))return e.toString(t,n,r);if(Ks(e)){if(t.doc.directives)return e.toString(t);if(t.resolvedAliases?.has(e))throw TypeError("Cannot stringify circular structure without alias nodes");else{if(t.resolvedAliases)t.resolvedAliases.add(e);else t.resolvedAliases=new Set([e]);e=e.resolve(t.doc)}}let i=void 0,s=Yt(e)?e:t.doc.createNode(e,{onTagObj:(l)=>i=l});i??(i=lce(t.doc.schema.tags,s));let o=cce(s,i,t);if(o.length>0)t.indentAtStart=(t.indentAtStart??0)+o.length+1;let a=typeof i.stringify==="function"?i.stringify(s,t,n,r):ft(s)?eu(s,t,n,r):s.toString(t,n,r);if(!o)return a;return ft(s)||a[0]==="{"||a[0]==="["?`${o} ${a}`:`${o} +${t.indent}${a}`}var Dh=q(()=>{k_();rn();xh();Ff()});function VC({key:e,value:t},n,r,i){let{allNullValues:s,doc:o,indent:a,indentStep:l,options:{commentString:c,indentSeq:u,simpleKeys:p}}=n,d=Yt(e)&&e.comment||null;if(p){if(d)throw Error("With simple keys, key nodes cannot have comments");if(ln(e)||!Yt(e)&&typeof e==="object")throw Error("With simple keys, collection cannot be used as a key value")}let f=!p&&(!e||d&&t==null&&!n.inFlow||ln(e)||(ft(e)?e.type===at.BLOCK_FOLDED||e.type===at.BLOCK_LITERAL:typeof e==="object"));n=Object.assign({},n,{allNullValues:!1,implicitKey:!f&&(p||!s),indent:a+l});let m=!1,y=!1,h=Fl(e,n,()=>m=!0,()=>y=!0);if(!f&&!n.inFlow&&h.length>1024){if(p)throw Error("With simple keys, single line scalar must not span more than 1024 characters");f=!0}if(n.inFlow){if(s||t==null){if(m&&r)r();return h===""?"?":f?`? ${h}`:h}}else if(s&&!p||t==null&&f){if(h=`? ${h}`,d&&!m)h+=Ka(h,n.indent,c(d));else if(y&&i)i();return h}if(m)d=null;if(f){if(d)h+=Ka(h,n.indent,c(d));h=`? ${h} +${a}:`}else if(h=`${h}:`,d)h+=Ka(h,n.indent,c(d));let b,g,x;if(Yt(t))b=!!t.spaceBefore,g=t.commentBefore,x=t.comment;else if(b=!1,g=null,x=null,t&&typeof t==="object")t=o.createNode(t);if(n.implicitKey=!1,!f&&!d&&ft(t))n.indentAtStart=h.length+1;if(y=!1,!u&&l.length>=2&&!n.inFlow&&!f&&Hr(t)&&!t.flow&&!t.tag&&!t.anchor)n.indent=n.indent.substring(2);let v=!1,D=Fl(t,n,()=>v=!0,()=>y=!0),T=" ";if(d||b||g){if(T=b?` `:"",g){let N=c(g);T+=` ${mo(N,n.indent)}`}if(D===""&&!n.inFlow){if(T===` `&&x)T=` @@ -41,32 +41,32 @@ ${mo(N,n.indent)}`}if(D===""&&!n.inFlow){if(T===` ${n.indent}`}else if(!f&&ln(t)){let N=D[0],O=D.indexOf(` `),C=O!==-1,X=n.inFlow??t.flow??t.items.length===0;if(C||!X){let te=!1;if(C&&(N==="&"||N==="!")){let L=D.indexOf(" ");if(N==="&"&&L!==-1&&L{rn();_r();Dh();xh()});function F_(e,t){if(e==="debug"||e==="warn")console.warn(t)}var C_=()=>{};function $E(e,t,n){let r=GC(e,n);if(Gr(r))for(let i of r.items)PE(e,t,i);else if(Array.isArray(r))for(let i of r)PE(e,t,i);else PE(e,t,r)}function PE(e,t,n){let r=GC(e,n);if(!dr(r))throw Error("Merge sources must be maps or map aliases");let i=r.toJSON(null,e,Map);for(let[s,o]of i)if(t instanceof Map){if(!t.has(s))t.set(s,o)}else if(t instanceof Set)t.add(s);else if(!Object.prototype.hasOwnProperty.call(t,s))Object.defineProperty(t,s,{value:o,writable:!0,enumerable:!0,configurable:!0});return t}function GC(e,t){return e&&Vs(t)?t.resolve(e.doc,e):t}var M_="<<",la,JC=(e,t)=>(la.identify(t)||ft(t)&&(!t.type||t.type===at.PLAIN)&&la.identify(t.value))&&e?.doc.schema.tags.some((n)=>n.tag===la.tag&&n.default);var L_=q(()=>{rn();_r();la={identify:(e)=>e===M_||typeof e==="symbol"&&e.description===M_,default:"key",tag:"tag:yaml.org,2002:merge",test:/^<<$/,resolve:()=>Object.assign(new at(Symbol(M_)),{addToJSMap:$E}),stringify:()=>M_}});function q_(e,t,{key:n,value:r}){if(Yt(n)&&n.addToJSMap)n.addToJSMap(e,t,r);else if(JC(e,n))$E(e,t,r);else{let i=vr(n,"",e);if(t instanceof Map)t.set(i,vr(r,i,e));else if(t instanceof Set)t.add(i);else{let s=cce(n,i,e),o=vr(r,s,e);if(s in t)Object.defineProperty(t,s,{value:o,writable:!0,enumerable:!0,configurable:!0});else t[s]=o}}return t}function cce(e,t,n){if(t===null)return"";if(typeof t!=="object")return String(t);if(Yt(e)&&n?.doc){let r=j_(n.doc,{});r.anchors=new Set;for(let s of n.anchors.keys())r.anchors.add(s.anchor);r.inFlow=!0,r.inStringifyKey=!0;let i=e.toString(r);if(!n.mapKeyWarned){let s=JSON.stringify(i);if(s.length>40)s=s.substring(0,36)+'..."';F_(n.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${s}. Set mapAsMap: true to use object keys.`),n.mapKeyWarned=!0}return i}return JSON.stringify(t)}var IE=q(()=>{C_();L_();Dh();rn();jl()});function Np(e,t,n){let r=Va(e,void 0,n),i=Va(t,void 0,n);return new lr(r,i)}class lr{constructor(e,t=null){Object.defineProperty(this,Vi,{value:xE}),this.key=e,this.value=t}clone(e){let{key:t,value:n}=this;if(Yt(t))t=t.clone(e);if(Yt(n))n=n.clone(e);return new lr(t,n)}toJSON(e,t){let n=t?.mapAsMap?new Map:{};return q_(t,n,this)}toString(e,t,n){return e?.doc?VC(this,e,t,n):JSON.stringify(this)}}var Cl=q(()=>{Pf();KC();IE();rn()});function B_(e,t,n){return(t.inFlow??e.flow?pce:uce)(e,t,n)}function uce({comment:e,items:t},n,{blockItemPrefix:r,flowChars:i,itemIndent:s,onChompKeep:o,onComment:a}){let{indent:l,options:{commentString:c}}=n,u=Object.assign({},n,{indent:s,type:null}),p=!1,d=[];for(let m=0;mh=null,()=>p=!0);if(h)b+=Ka(b,s,c(h));if(p&&h)p=!1;d.push(r+b)}let f;if(d.length===0)f=i.start+i.end;else{f=d[0];for(let m=1;m{rn();xr();Dh();xh()});function F_(e,t){if(e==="debug"||e==="warn")console.warn(t)}var C_=()=>{};function $E(e,t,n){let r=GC(e,n);if(Hr(r))for(let i of r.items)PE(e,t,i);else if(Array.isArray(r))for(let i of r)PE(e,t,i);else PE(e,t,r)}function PE(e,t,n){let r=GC(e,n);if(!dr(r))throw Error("Merge sources must be maps or map aliases");let i=r.toJSON(null,e,Map);for(let[s,o]of i)if(t instanceof Map){if(!t.has(s))t.set(s,o)}else if(t instanceof Set)t.add(s);else if(!Object.prototype.hasOwnProperty.call(t,s))Object.defineProperty(t,s,{value:o,writable:!0,enumerable:!0,configurable:!0});return t}function GC(e,t){return e&&Ks(t)?t.resolve(e.doc,e):t}var M_="<<",la,JC=(e,t)=>(la.identify(t)||ft(t)&&(!t.type||t.type===at.PLAIN)&&la.identify(t.value))&&e?.doc.schema.tags.some((n)=>n.tag===la.tag&&n.default);var L_=q(()=>{rn();xr();la={identify:(e)=>e===M_||typeof e==="symbol"&&e.description===M_,default:"key",tag:"tag:yaml.org,2002:merge",test:/^<<$/,resolve:()=>Object.assign(new at(Symbol(M_)),{addToJSMap:$E}),stringify:()=>M_}});function q_(e,t,{key:n,value:r}){if(Yt(n)&&n.addToJSMap)n.addToJSMap(e,t,r);else if(JC(e,n))$E(e,t,r);else{let i=_r(n,"",e);if(t instanceof Map)t.set(i,_r(r,i,e));else if(t instanceof Set)t.add(i);else{let s=uce(n,i,e),o=_r(r,s,e);if(s in t)Object.defineProperty(t,s,{value:o,writable:!0,enumerable:!0,configurable:!0});else t[s]=o}}return t}function uce(e,t,n){if(t===null)return"";if(typeof t!=="object")return String(t);if(Yt(e)&&n?.doc){let r=j_(n.doc,{});r.anchors=new Set;for(let s of n.anchors.keys())r.anchors.add(s.anchor);r.inFlow=!0,r.inStringifyKey=!0;let i=e.toString(r);if(!n.mapKeyWarned){let s=JSON.stringify(i);if(s.length>40)s=s.substring(0,36)+'..."';F_(n.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${s}. Set mapAsMap: true to use object keys.`),n.mapKeyWarned=!0}return i}return JSON.stringify(t)}var IE=q(()=>{C_();L_();Dh();rn();jl()});function Pp(e,t,n){let r=Va(e,void 0,n),i=Va(t,void 0,n);return new lr(r,i)}class lr{constructor(e,t=null){Object.defineProperty(this,Ki,{value:xE}),this.key=e,this.value=t}clone(e){let{key:t,value:n}=this;if(Yt(t))t=t.clone(e);if(Yt(n))n=n.clone(e);return new lr(t,n)}toJSON(e,t){let n=t?.mapAsMap?new Map:{};return q_(t,n,this)}toString(e,t,n){return e?.doc?VC(this,e,t,n):JSON.stringify(this)}}var Cl=q(()=>{If();KC();IE();rn()});function B_(e,t,n){return(t.inFlow??e.flow?dce:pce)(e,t,n)}function pce({comment:e,items:t},n,{blockItemPrefix:r,flowChars:i,itemIndent:s,onChompKeep:o,onComment:a}){let{indent:l,options:{commentString:c}}=n,u=Object.assign({},n,{indent:s,type:null}),p=!1,d=[];for(let m=0;mh=null,()=>p=!0);if(h)b+=Ka(b,s,c(h));if(p&&h)p=!1;d.push(r+b)}let f;if(d.length===0)f=i.start+i.end;else{f=d[0];for(let m=1;mh=null);if(c||(c=p.length>u||b.includes(` +`+mo(c(e),l),a)a()}else if(p&&o)o();return f}function dce({items:e},t,{flowChars:n,itemIndent:r}){let{indent:i,indentStep:s,flowCollectionPadding:o,options:{commentString:a}}=t;r+=s;let l=Object.assign({},t,{indent:r,inFlow:!0,type:null}),c=!1,u=0,p=[];for(let m=0;mh=null);if(c||(c=p.length>u||b.includes(` `)),m0)c||(c=p.reduce((g,x)=>g+x.length+2,2)+(b.length+2)>t.options.lineWidth);if(c)b+=","}if(h)b+=Ka(b,r,a(h));p.push(b),u=p.length}let{start:d,end:f}=n;if(p.length===0)return d+f;else{if(!c){let m=p.reduce((y,h)=>y+h.length+2,2);c=t.options.lineWidth>0&&m>t.options.lineWidth}if(c){let m=d;for(let y of p)m+=y?` ${s}${i}${y}`:` `;return`${m} -${i}${f}`}else return`${d}${o}${p.join(" ")}${o}${f}`}}function U_({indent:e,options:{commentString:t}},n,r,i){if(r&&i)r=r.replace(/^\n+/,"");if(r){let s=mo(t(r),e);n.push(s.trimStart())}}var AE=q(()=>{rn();Dh();xh()});function ca(e,t){let n=ft(t)?t.value:t;for(let r of e)if(Vt(r)){if(r.key===t||r.key===n)return r;if(ft(r.key)&&r.key.value===n)return r}return}var xr;var Ml=q(()=>{AE();IE();$_();rn();Cl();_r();xr=class xr extends _h{static get tagName(){return"tag:yaml.org,2002:map"}constructor(e){super(oa,e);this.items=[]}static from(e,t,n){let{keepUndefined:r,replacer:i}=n,s=new this(e),o=(a,l)=>{if(typeof i==="function")l=i.call(t,a,l);else if(Array.isArray(i)&&!i.includes(a))return;if(l!==void 0||r)s.items.push(Np(a,l,n))};if(t instanceof Map)for(let[a,l]of t)o(a,l);else if(t&&typeof t==="object")for(let a of Object.keys(t))o(a,t[a]);if(typeof e.sortMapEntries==="function")s.items.sort(e.sortMapEntries);return s}add(e,t){let n;if(Vt(e))n=e;else if(!e||typeof e!=="object"||!("key"in e))n=new lr(e,e?.value);else n=new lr(e.key,e.value);let r=ca(this.items,n.key),i=this.schema?.sortMapEntries;if(r){if(!t)throw Error(`Key ${n.key} already set`);if(ft(r.value)&&P_(n.value))r.value.value=n.value;else r.value=n.value}else if(i){let s=this.items.findIndex((o)=>i(n,o)<0);if(s===-1)this.items.push(n);else this.items.splice(s,0,n)}else this.items.push(n)}delete(e){let t=ca(this.items,e);if(!t)return!1;return this.items.splice(this.items.indexOf(t),1).length>0}get(e,t){let r=ca(this.items,e)?.value;return(!t&&ft(r)?r.value:r)??void 0}has(e){return!!ca(this.items,e)}set(e,t){this.add(new lr(e,t),!0)}toJSON(e,t,n){let r=n?new n:t?.mapAsMap?new Map:{};if(t?.onCreate)t.onCreate(r);for(let i of this.items)q_(t,r,i);return r}toString(e,t,n){if(!e)return JSON.stringify(this);for(let r of this.items)if(!Vt(r))throw Error(`Map items must all be pairs; found ${JSON.stringify(r)} instead`);if(!e.allNullValues&&this.hasAllNullValues(!1))e=Object.assign({},e,{allNullValues:!0});return B_(this,e,{blockItemPrefix:"",flowChars:{start:"{",end:"}"},itemIndent:e.indent||"",onChompKeep:n,onComment:t})}}});var yo;var Op=q(()=>{rn();Ml();yo={collection:"map",default:!0,nodeClass:xr,tag:"tag:yaml.org,2002:map",resolve(e,t){if(!dr(e))t("Expected a mapping for this tag");return e},createNode:(e,t,n)=>xr.from(e,t,n)}});function V_(e){let t=ft(e)?e.value:e;if(t&&typeof t==="string")t=Number(t);return typeof t==="number"&&Number.isInteger(t)&&t>=0?t:null}var Ki;var eu=q(()=>{Pf();AE();$_();rn();_r();jl();Ki=class Ki extends _h{static get tagName(){return"tag:yaml.org,2002:seq"}constructor(e){super(Rl,e);this.items=[]}add(e){this.items.push(e)}delete(e){let t=V_(e);if(typeof t!=="number")return!1;return this.items.splice(t,1).length>0}get(e,t){let n=V_(e);if(typeof n!=="number")return;let r=this.items[n];return!t&&ft(r)?r.value:r}has(e){let t=V_(e);return typeof t==="number"&&t{rn();eu();ho={collection:"seq",default:!0,nodeClass:Ki,tag:"tag:yaml.org,2002:seq",resolve(e,t){if(!Gr(e))t("Expected a sequence for this tag");return e},createNode:(e,t,n)=>Ki.from(e,t,n)}});var Ll;var jf=q(()=>{Rf();Ll={identify:(e)=>typeof e==="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:(e)=>e,stringify(e,t,n,r){return t=Object.assign({actualString:!0},t),Zc(e,t,n,r)}}});var $p;var K_=q(()=>{_r();$p={identify:(e)=>e==null,createNode:()=>new at(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new at(null),stringify:({source:e},t)=>typeof e==="string"&&$p.test.test(e)?e:t.options.nullStr}});var Th;var RE=q(()=>{_r();Th={identify:(e)=>typeof e==="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:(e)=>new at(e[0]==="t"||e[0]==="T"),stringify({source:e,value:t},n){if(e&&Th.test.test(e)){let r=e[0]==="t"||e[0]==="T";if(t===r)return e}return t?n.options.trueStr:n.options.falseStr}}});function oi({format:e,minFractionDigits:t,tag:n,value:r}){if(typeof r==="bigint")return String(r);let i=typeof r==="number"?r:Number(r);if(!isFinite(i))return isNaN(i)?".nan":i<0?"-.inf":".inf";let s=Object.is(r,-0)?"-0":JSON.stringify(r);if(!e&&t&&(!n||n==="tag:yaml.org,2002:float")&&/^-?\d/.test(s)&&!s.includes("e")){let o=s.indexOf(".");if(o<0)o=s.length,s+=".";let a=t-(s.length-o-1);while(a-- >0)s+="0"}return s}var Ip=()=>{};var J_,G_,H_;var jE=q(()=>{_r();Ip();J_={identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:(e)=>e.slice(-3).toLowerCase()==="nan"?NaN:e[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:oi},G_={identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:(e)=>parseFloat(e),stringify(e){let t=Number(e.value);return isFinite(t)?t.toExponential():oi(e)}},H_={identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve(e){let t=new at(parseFloat(e)),n=e.indexOf(".");if(n!==-1&&e[e.length-1]==="0")t.minFractionDigits=e.length-n-1;return t},stringify:oi}});function HC(e,t,n){let{value:r}=e;if(z_(r)&&r>=0)return n+r.toString(t);return oi(e)}var z_=(e)=>typeof e==="bigint"||Number.isInteger(e),FE=(e,t,n,{intAsBigInt:r})=>r?BigInt(e):parseInt(e.substring(t),n),W_,Q_,Y_;var CE=q(()=>{Ip();W_={identify:(e)=>z_(e)&&e>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^0o[0-7]+$/,resolve:(e,t,n)=>FE(e,2,8,n),stringify:(e)=>HC(e,8,"0o")},Q_={identify:z_,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9]+$/,resolve:(e,t,n)=>FE(e,0,10,n),stringify:oi},Y_={identify:(e)=>z_(e)&&e>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^0x[0-9a-fA-F]+$/,resolve:(e,t,n)=>FE(e,2,16,n),stringify:(e)=>HC(e,16,"0x")}});var zC;var WC=q(()=>{Op();K_();Pp();jf();RE();jE();CE();zC=[yo,ho,Ll,$p,Th,W_,Q_,Y_,J_,G_,H_]});function QC(e){return typeof e==="bigint"||Number.isInteger(e)}var X_=({value:e})=>JSON.stringify(e),dce,fce,YC;var XC=q(()=>{_r();Op();Pp();dce=[{identify:(e)=>typeof e==="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:(e)=>e,stringify:X_},{identify:(e)=>e==null,createNode:()=>new at(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^null$/,resolve:()=>null,stringify:X_},{identify:(e)=>typeof e==="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^true$|^false$/,resolve:(e)=>e==="true",stringify:X_},{identify:QC,default:!0,tag:"tag:yaml.org,2002:int",test:/^-?(?:0|[1-9][0-9]*)$/,resolve:(e,t,{intAsBigInt:n})=>n?BigInt(e):parseInt(e,10),stringify:({value:e})=>QC(e)?e.toString():JSON.stringify(e)},{identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:(e)=>parseFloat(e),stringify:X_}],fce={default:!0,tag:"",test:/^/,resolve(e,t){return t(`Unresolved plain scalar ${JSON.stringify(e)}`),e}},YC=[yo,ho].concat(dce,fce)});var Sh;var ME=q(()=>{_r();Rf();Sh={identify:(e)=>e instanceof Uint8Array,default:!1,tag:"tag:yaml.org,2002:binary",resolve(e,t){if(typeof atob==="function"){let n=atob(e.replace(/[\n\r]/g,"")),r=new Uint8Array(n.length);for(let i=0;i1)t("Each pair must have its own sequence indicator");let i=r.items[0]||new lr(new at(null));if(r.commentBefore)i.key.commentBefore=i.key.commentBefore?`${r.commentBefore} +${i}${f}`}else return`${d}${o}${p.join(" ")}${o}${f}`}}function U_({indent:e,options:{commentString:t}},n,r,i){if(r&&i)r=r.replace(/^\n+/,"");if(r){let s=mo(t(r),e);n.push(s.trimStart())}}var AE=q(()=>{rn();Dh();xh()});function ca(e,t){let n=ft(t)?t.value:t;for(let r of e)if(Vt(r)){if(r.key===t||r.key===n)return r;if(ft(r.key)&&r.key.value===n)return r}return}var wr;var Ml=q(()=>{AE();IE();$_();rn();Cl();xr();wr=class wr extends _h{static get tagName(){return"tag:yaml.org,2002:map"}constructor(e){super(oa,e);this.items=[]}static from(e,t,n){let{keepUndefined:r,replacer:i}=n,s=new this(e),o=(a,l)=>{if(typeof i==="function")l=i.call(t,a,l);else if(Array.isArray(i)&&!i.includes(a))return;if(l!==void 0||r)s.items.push(Pp(a,l,n))};if(t instanceof Map)for(let[a,l]of t)o(a,l);else if(t&&typeof t==="object")for(let a of Object.keys(t))o(a,t[a]);if(typeof e.sortMapEntries==="function")s.items.sort(e.sortMapEntries);return s}add(e,t){let n;if(Vt(e))n=e;else if(!e||typeof e!=="object"||!("key"in e))n=new lr(e,e?.value);else n=new lr(e.key,e.value);let r=ca(this.items,n.key),i=this.schema?.sortMapEntries;if(r){if(!t)throw Error(`Key ${n.key} already set`);if(ft(r.value)&&P_(n.value))r.value.value=n.value;else r.value=n.value}else if(i){let s=this.items.findIndex((o)=>i(n,o)<0);if(s===-1)this.items.push(n);else this.items.splice(s,0,n)}else this.items.push(n)}delete(e){let t=ca(this.items,e);if(!t)return!1;return this.items.splice(this.items.indexOf(t),1).length>0}get(e,t){let r=ca(this.items,e)?.value;return(!t&&ft(r)?r.value:r)??void 0}has(e){return!!ca(this.items,e)}set(e,t){this.add(new lr(e,t),!0)}toJSON(e,t,n){let r=n?new n:t?.mapAsMap?new Map:{};if(t?.onCreate)t.onCreate(r);for(let i of this.items)q_(t,r,i);return r}toString(e,t,n){if(!e)return JSON.stringify(this);for(let r of this.items)if(!Vt(r))throw Error(`Map items must all be pairs; found ${JSON.stringify(r)} instead`);if(!e.allNullValues&&this.hasAllNullValues(!1))e=Object.assign({},e,{allNullValues:!0});return B_(this,e,{blockItemPrefix:"",flowChars:{start:"{",end:"}"},itemIndent:e.indent||"",onChompKeep:n,onComment:t})}}});var yo;var $p=q(()=>{rn();Ml();yo={collection:"map",default:!0,nodeClass:wr,tag:"tag:yaml.org,2002:map",resolve(e,t){if(!dr(e))t("Expected a mapping for this tag");return e},createNode:(e,t,n)=>wr.from(e,t,n)}});function V_(e){let t=ft(e)?e.value:e;if(t&&typeof t==="string")t=Number(t);return typeof t==="number"&&Number.isInteger(t)&&t>=0?t:null}var Ji;var tu=q(()=>{If();AE();$_();rn();xr();jl();Ji=class Ji extends _h{static get tagName(){return"tag:yaml.org,2002:seq"}constructor(e){super(Rl,e);this.items=[]}add(e){this.items.push(e)}delete(e){let t=V_(e);if(typeof t!=="number")return!1;return this.items.splice(t,1).length>0}get(e,t){let n=V_(e);if(typeof n!=="number")return;let r=this.items[n];return!t&&ft(r)?r.value:r}has(e){let t=V_(e);return typeof t==="number"&&t{rn();tu();ho={collection:"seq",default:!0,nodeClass:Ji,tag:"tag:yaml.org,2002:seq",resolve(e,t){if(!Hr(e))t("Expected a sequence for this tag");return e},createNode:(e,t,n)=>Ji.from(e,t,n)}});var Ll;var Cf=q(()=>{Ff();Ll={identify:(e)=>typeof e==="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:(e)=>e,stringify(e,t,n,r){return t=Object.assign({actualString:!0},t),eu(e,t,n,r)}}});var Ap;var K_=q(()=>{xr();Ap={identify:(e)=>e==null,createNode:()=>new at(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new at(null),stringify:({source:e},t)=>typeof e==="string"&&Ap.test.test(e)?e:t.options.nullStr}});var Th;var RE=q(()=>{xr();Th={identify:(e)=>typeof e==="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:(e)=>new at(e[0]==="t"||e[0]==="T"),stringify({source:e,value:t},n){if(e&&Th.test.test(e)){let r=e[0]==="t"||e[0]==="T";if(t===r)return e}return t?n.options.trueStr:n.options.falseStr}}});function ai({format:e,minFractionDigits:t,tag:n,value:r}){if(typeof r==="bigint")return String(r);let i=typeof r==="number"?r:Number(r);if(!isFinite(i))return isNaN(i)?".nan":i<0?"-.inf":".inf";let s=Object.is(r,-0)?"-0":JSON.stringify(r);if(!e&&t&&(!n||n==="tag:yaml.org,2002:float")&&/^-?\d/.test(s)&&!s.includes("e")){let o=s.indexOf(".");if(o<0)o=s.length,s+=".";let a=t-(s.length-o-1);while(a-- >0)s+="0"}return s}var Rp=()=>{};var J_,G_,H_;var jE=q(()=>{xr();Rp();J_={identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:(e)=>e.slice(-3).toLowerCase()==="nan"?NaN:e[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:ai},G_={identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:(e)=>parseFloat(e),stringify(e){let t=Number(e.value);return isFinite(t)?t.toExponential():ai(e)}},H_={identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve(e){let t=new at(parseFloat(e)),n=e.indexOf(".");if(n!==-1&&e[e.length-1]==="0")t.minFractionDigits=e.length-n-1;return t},stringify:ai}});function HC(e,t,n){let{value:r}=e;if(z_(r)&&r>=0)return n+r.toString(t);return ai(e)}var z_=(e)=>typeof e==="bigint"||Number.isInteger(e),FE=(e,t,n,{intAsBigInt:r})=>r?BigInt(e):parseInt(e.substring(t),n),W_,Q_,Y_;var CE=q(()=>{Rp();W_={identify:(e)=>z_(e)&&e>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^0o[0-7]+$/,resolve:(e,t,n)=>FE(e,2,8,n),stringify:(e)=>HC(e,8,"0o")},Q_={identify:z_,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9]+$/,resolve:(e,t,n)=>FE(e,0,10,n),stringify:ai},Y_={identify:(e)=>z_(e)&&e>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^0x[0-9a-fA-F]+$/,resolve:(e,t,n)=>FE(e,2,16,n),stringify:(e)=>HC(e,16,"0x")}});var zC;var WC=q(()=>{$p();K_();Ip();Cf();RE();jE();CE();zC=[yo,ho,Ll,Ap,Th,W_,Q_,Y_,J_,G_,H_]});function QC(e){return typeof e==="bigint"||Number.isInteger(e)}var X_=({value:e})=>JSON.stringify(e),fce,mce,YC;var XC=q(()=>{xr();$p();Ip();fce=[{identify:(e)=>typeof e==="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:(e)=>e,stringify:X_},{identify:(e)=>e==null,createNode:()=>new at(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^null$/,resolve:()=>null,stringify:X_},{identify:(e)=>typeof e==="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^true$|^false$/,resolve:(e)=>e==="true",stringify:X_},{identify:QC,default:!0,tag:"tag:yaml.org,2002:int",test:/^-?(?:0|[1-9][0-9]*)$/,resolve:(e,t,{intAsBigInt:n})=>n?BigInt(e):parseInt(e,10),stringify:({value:e})=>QC(e)?e.toString():JSON.stringify(e)},{identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:(e)=>parseFloat(e),stringify:X_}],mce={default:!0,tag:"",test:/^/,resolve(e,t){return t(`Unresolved plain scalar ${JSON.stringify(e)}`),e}},YC=[yo,ho].concat(fce,mce)});var Sh;var ME=q(()=>{xr();Ff();Sh={identify:(e)=>e instanceof Uint8Array,default:!1,tag:"tag:yaml.org,2002:binary",resolve(e,t){if(typeof atob==="function"){let n=atob(e.replace(/[\n\r]/g,"")),r=new Uint8Array(n.length);for(let i=0;i1)t("Each pair must have its own sequence indicator");let i=r.items[0]||new lr(new at(null));if(r.commentBefore)i.key.commentBefore=i.key.commentBefore?`${r.commentBefore} ${i.key.commentBefore}`:r.commentBefore;if(r.comment){let s=i.value??i.key;s.comment=s.comment?`${r.comment} -${s.comment}`:r.comment}r=i}e.items[n]=Vt(r)?r:new lr(r)}else t("Expected a sequence for this tag");return e}function qE(e,t,n){let{replacer:r}=n,i=new Ki(e);i.tag="tag:yaml.org,2002:pairs";let s=0;if(t&&Symbol.iterator in Object(t))for(let o of t){if(typeof r==="function")o=r.call(t,String(s++),o);let a,l;if(Array.isArray(o))if(o.length===2)a=o[0],l=o[1];else throw TypeError(`Expected [key, value] tuple: ${o}`);else if(o&&o instanceof Object){let c=Object.keys(o);if(c.length===1)a=c[0],l=o[a];else throw TypeError(`Expected tuple with one key, not ${c.length} keys`)}else a=o;i.items.push(Np(a,l,n))}return i}var Eh;var Z_=q(()=>{rn();Cl();_r();eu();Eh={collection:"seq",default:!1,tag:"tag:yaml.org,2002:pairs",resolve:LE,createNode:qE}});var Ff,kh;var UE=q(()=>{rn();jl();Ml();eu();Z_();Ff=class Ff extends Ki{constructor(){super();this.add=xr.prototype.add.bind(this),this.delete=xr.prototype.delete.bind(this),this.get=xr.prototype.get.bind(this),this.has=xr.prototype.has.bind(this),this.set=xr.prototype.set.bind(this),this.tag=Ff.tag}toJSON(e,t){if(!t)return super.toJSON(e);let n=new Map;if(t?.onCreate)t.onCreate(n);for(let r of this.items){let i,s;if(Vt(r))i=vr(r.key,"",t),s=vr(r.value,i,t);else i=vr(r,"",t);if(n.has(i))throw Error("Ordered maps must not include duplicate keys");n.set(i,s)}return n}static from(e,t,n){let r=qE(e,t,n),i=new this;return i.items=r.items,i}};Ff.tag="tag:yaml.org,2002:omap";kh={collection:"seq",identify:(e)=>e instanceof Map,nodeClass:Ff,default:!1,tag:"tag:yaml.org,2002:omap",resolve(e,t){let n=LE(e,t),r=[];for(let{key:i}of n.items)if(ft(i))if(r.includes(i.value))t(`Ordered maps must not include duplicate keys: ${i.value}`);else r.push(i.value);return Object.assign(new Ff,n)},createNode:(e,t,n)=>Ff.from(e,t,n)}});function ZC({value:e,source:t},n){if(t&&(e?BE:VE).test.test(t))return t;return e?n.options.trueStr:n.options.falseStr}var BE,VE;var eM=q(()=>{_r();BE={identify:(e)=>e===!0,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new at(!0),stringify:ZC},VE={identify:(e)=>e===!1,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new at(!1),stringify:ZC}});var tM,nM,rM;var iM=q(()=>{_r();Ip();tM={identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:(e)=>e.slice(-3).toLowerCase()==="nan"?NaN:e[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:oi},nM={identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:(e)=>parseFloat(e.replace(/_/g,"")),stringify(e){let t=Number(e.value);return isFinite(t)?t.toExponential():oi(e)}},rM={identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve(e){let t=new at(parseFloat(e.replace(/_/g,""))),n=e.indexOf(".");if(n!==-1){let r=e.substring(n+1).replace(/_/g,"");if(r[r.length-1]==="0")t.minFractionDigits=r.length}return t},stringify:oi}});function ex(e,t,n,{intAsBigInt:r}){let i=e[0];if(i==="-"||i==="+")t+=1;if(e=e.substring(t).replace(/_/g,""),r){switch(n){case 2:e=`0b${e}`;break;case 8:e=`0o${e}`;break;case 16:e=`0x${e}`;break}let o=BigInt(e);return i==="-"?BigInt(-1)*o:o}let s=parseInt(e,n);return i==="-"?-1*s:s}function KE(e,t,n){let{value:r}=e;if(Nh(r)){let i=r.toString(t);return r<0?"-"+n+i.substr(1):n+i}return oi(e)}var Nh=(e)=>typeof e==="bigint"||Number.isInteger(e),sM,oM,aM,lM;var cM=q(()=>{Ip();sM={identify:Nh,default:!0,tag:"tag:yaml.org,2002:int",format:"BIN",test:/^[-+]?0b[0-1_]+$/,resolve:(e,t,n)=>ex(e,2,2,n),stringify:(e)=>KE(e,2,"0b")},oM={identify:Nh,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^[-+]?0[0-7_]+$/,resolve:(e,t,n)=>ex(e,1,8,n),stringify:(e)=>KE(e,8,"0")},aM={identify:Nh,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9][0-9_]*$/,resolve:(e,t,n)=>ex(e,0,10,n),stringify:oi},lM={identify:Nh,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:(e,t,n)=>ex(e,2,16,n),stringify:(e)=>KE(e,16,"0x")}});var Cf,Oh;var JE=q(()=>{rn();Cl();Ml();Cf=class Cf extends xr{constructor(e){super(e);this.tag=Cf.tag}add(e){let t;if(Vt(e))t=e;else if(e&&typeof e==="object"&&"key"in e&&"value"in e&&e.value===null)t=new lr(e.key,null);else t=new lr(e,null);if(!ca(this.items,t.key))this.items.push(t)}get(e,t){let n=ca(this.items,e);return!t&&Vt(n)?ft(n.key)?n.key.value:n.key:n}set(e,t){if(typeof t!=="boolean")throw Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof t}`);let n=ca(this.items,e);if(n&&!t)this.items.splice(this.items.indexOf(n),1);else if(!n&&t)this.items.push(new lr(e))}toJSON(e,t){return super.toJSON(e,t,Set)}toString(e,t,n){if(!e)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},e,{allNullValues:!0}),t,n);else throw Error("Set items must all have null values")}static from(e,t,n){let{replacer:r}=n,i=new this(e);if(t&&Symbol.iterator in Object(t))for(let s of t){if(typeof r==="function")s=r.call(t,s,s);i.items.push(Np(s,null,n))}return i}};Cf.tag="tag:yaml.org,2002:set";Oh={collection:"map",identify:(e)=>e instanceof Set,nodeClass:Cf,default:!1,tag:"tag:yaml.org,2002:set",createNode:(e,t,n)=>Cf.from(e,t,n),resolve(e,t){if(dr(e))if(e.hasAllNullValues(!0))return Object.assign(new Cf,e);else t("Set items must all have null values");else t("Expected a mapping for this tag");return e}}});function GE(e,t){let n=e[0],r=n==="-"||n==="+"?e.substring(1):e,i=(o)=>t?BigInt(o):Number(o),s=r.replace(/_/g,"").split(":").reduce((o,a)=>o*i(60)+i(a),i(0));return n==="-"?i(-1)*s:s}function uM(e){let{value:t}=e,n=(o)=>o;if(typeof t==="bigint")n=(o)=>BigInt(o);else if(isNaN(t)||!isFinite(t))return oi(e);let r="";if(t<0)r="-",t*=n(-1);let i=n(60),s=[t%i];if(t<60)s.unshift(0);else if(t=(t-s[0])/i,s.unshift(t%i),t>=60)t=(t-s[0])/i,s.unshift(t);return r+s.map((o)=>String(o).padStart(2,"0")).join(":").replace(/000000\d*$/,"")}var tx,nx,Mf;var HE=q(()=>{Ip();tx={identify:(e)=>typeof e==="bigint"||Number.isInteger(e),default:!0,tag:"tag:yaml.org,2002:int",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:(e,t,{intAsBigInt:n})=>GE(e,n),stringify:uM},nx={identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:(e)=>GE(e,!1),stringify:uM},Mf={identify:(e)=>e instanceof Date,default:!0,tag:"tag:yaml.org,2002:timestamp",test:RegExp("^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$"),resolve(e){let t=e.match(Mf.test);if(!t)throw Error("!!timestamp expects a date, starting with yyyy-mm-dd");let[,n,r,i,s,o,a]=t.map(Number),l=t[7]?Number((t[7]+"00").substr(1,3)):0,c=Date.UTC(n,r-1,i,s||0,o||0,a||0,l),u=t[8];if(u&&u!=="Z"){let p=GE(u,!1);if(Math.abs(p)<30)p*=60;c-=60000*p}return new Date(c)},stringify:({value:e})=>e?.toISOString().replace(/(T00:00:00)?\.000Z$/,"")??""}});var zE;var pM=q(()=>{Op();K_();Pp();jf();ME();eM();iM();cM();L_();UE();Z_();JE();HE();zE=[yo,ho,Ll,$p,BE,VE,sM,oM,aM,lM,tM,nM,rM,Sh,la,kh,Eh,Oh,tx,nx,Mf]});function rx(e,t,n){let r=dM.get(t);if(r&&!e)return n&&!r.includes(la)?r.concat(la):r.slice();let i=r;if(!i)if(Array.isArray(e))i=[];else{let s=Array.from(dM.keys()).filter((o)=>o!=="yaml11").map((o)=>JSON.stringify(o)).join(", ");throw Error(`Unknown schema "${t}"; use one of ${s} or define customTags array`)}if(Array.isArray(e))for(let s of e)i=i.concat(s);else if(typeof e==="function")i=e(i.slice());if(n)i=i.concat(la);return i.reduce((s,o)=>{let a=typeof o==="string"?fM[o]:o;if(!a){let l=JSON.stringify(o),c=Object.keys(fM).map((u)=>JSON.stringify(u)).join(", ");throw Error(`Unknown custom tag ${l}; use one of ${c}`)}if(!s.includes(a))s.push(a);return s},[])}var dM,fM,mM;var yM=q(()=>{Op();K_();Pp();jf();RE();jE();CE();WC();XC();ME();L_();UE();Z_();pM();JE();HE();dM=new Map([["core",zC],["failsafe",[yo,ho,Ll]],["json",YC],["yaml11",zE],["yaml-1.1",zE]]),fM={binary:Sh,bool:Th,float:H_,floatExp:G_,floatNaN:J_,floatTime:nx,int:Q_,intHex:Y_,intOct:W_,intTime:tx,map:yo,merge:la,null:$p,omap:kh,pairs:Eh,seq:ho,set:Oh,timestamp:Mf},mM={"tag:yaml.org,2002:binary":Sh,"tag:yaml.org,2002:merge":la,"tag:yaml.org,2002:omap":kh,"tag:yaml.org,2002:pairs":Eh,"tag:yaml.org,2002:set":Oh,"tag:yaml.org,2002:timestamp":Mf}});class Ph{constructor({compat:e,customTags:t,merge:n,resolveKnownTags:r,schema:i,sortMapEntries:s,toStringDefaults:o}){this.compat=Array.isArray(e)?rx(e,"compat"):e?rx(null,e):null,this.name=typeof i==="string"&&i||"core",this.knownTags=r?mM:{},this.tags=rx(t,this.name,n),this.toStringOptions=o??null,Object.defineProperty(this,oa,{value:yo}),Object.defineProperty(this,Bs,{value:Ll}),Object.defineProperty(this,Rl,{value:ho}),this.sortMapEntries=typeof s==="function"?s:s===!0?mce:null}clone(){let e=Object.create(Ph.prototype,Object.getOwnPropertyDescriptors(this));return e.tags=this.tags.slice(),e}}var mce=(e,t)=>e.keyt.key?1:0;var WE=q(()=>{rn();Op();Pp();jf();yM()});function hM(e,t){let n=[],r=t.directives===!0;if(t.directives!==!1&&e.directives){let l=e.directives.toString(e);if(l)n.push(l),r=!0;else if(e.directives.docStart)r=!0}if(r)n.push("---");let i=j_(e,t),{commentString:s}=i.options;if(e.commentBefore){if(n.length!==1)n.unshift("");let l=s(e.commentBefore);n.unshift(mo(l,""))}let o=!1,a=null;if(e.contents){if(Yt(e.contents)){if(e.contents.spaceBefore&&r)n.push("");if(e.contents.commentBefore){let u=s(e.contents.commentBefore);n.push(mo(u,""))}i.forceBlockIndent=!!e.comment,a=e.contents.comment}let l=a?void 0:()=>o=!0,c=Fl(e.contents,i,()=>a=null,l);if(a)c+=Ka(c,"",s(a));if((c[0]==="|"||c[0]===">")&&n[n.length-1]==="---")n[n.length-1]=`--- ${c}`;else n.push(c)}else n.push(Fl(e.contents,i));if(e.directives?.docEnd)if(e.comment){let l=s(e.comment);if(l.includes(` +${s.comment}`:r.comment}r=i}e.items[n]=Vt(r)?r:new lr(r)}else t("Expected a sequence for this tag");return e}function qE(e,t,n){let{replacer:r}=n,i=new Ji(e);i.tag="tag:yaml.org,2002:pairs";let s=0;if(t&&Symbol.iterator in Object(t))for(let o of t){if(typeof r==="function")o=r.call(t,String(s++),o);let a,l;if(Array.isArray(o))if(o.length===2)a=o[0],l=o[1];else throw TypeError(`Expected [key, value] tuple: ${o}`);else if(o&&o instanceof Object){let c=Object.keys(o);if(c.length===1)a=c[0],l=o[a];else throw TypeError(`Expected tuple with one key, not ${c.length} keys`)}else a=o;i.items.push(Pp(a,l,n))}return i}var Eh;var Z_=q(()=>{rn();Cl();xr();tu();Eh={collection:"seq",default:!1,tag:"tag:yaml.org,2002:pairs",resolve:LE,createNode:qE}});var Mf,kh;var UE=q(()=>{rn();jl();Ml();tu();Z_();Mf=class Mf extends Ji{constructor(){super();this.add=wr.prototype.add.bind(this),this.delete=wr.prototype.delete.bind(this),this.get=wr.prototype.get.bind(this),this.has=wr.prototype.has.bind(this),this.set=wr.prototype.set.bind(this),this.tag=Mf.tag}toJSON(e,t){if(!t)return super.toJSON(e);let n=new Map;if(t?.onCreate)t.onCreate(n);for(let r of this.items){let i,s;if(Vt(r))i=_r(r.key,"",t),s=_r(r.value,i,t);else i=_r(r,"",t);if(n.has(i))throw Error("Ordered maps must not include duplicate keys");n.set(i,s)}return n}static from(e,t,n){let r=qE(e,t,n),i=new this;return i.items=r.items,i}};Mf.tag="tag:yaml.org,2002:omap";kh={collection:"seq",identify:(e)=>e instanceof Map,nodeClass:Mf,default:!1,tag:"tag:yaml.org,2002:omap",resolve(e,t){let n=LE(e,t),r=[];for(let{key:i}of n.items)if(ft(i))if(r.includes(i.value))t(`Ordered maps must not include duplicate keys: ${i.value}`);else r.push(i.value);return Object.assign(new Mf,n)},createNode:(e,t,n)=>Mf.from(e,t,n)}});function ZC({value:e,source:t},n){if(t&&(e?BE:VE).test.test(t))return t;return e?n.options.trueStr:n.options.falseStr}var BE,VE;var eM=q(()=>{xr();BE={identify:(e)=>e===!0,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new at(!0),stringify:ZC},VE={identify:(e)=>e===!1,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new at(!1),stringify:ZC}});var tM,nM,rM;var iM=q(()=>{xr();Rp();tM={identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:(e)=>e.slice(-3).toLowerCase()==="nan"?NaN:e[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:ai},nM={identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:(e)=>parseFloat(e.replace(/_/g,"")),stringify(e){let t=Number(e.value);return isFinite(t)?t.toExponential():ai(e)}},rM={identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve(e){let t=new at(parseFloat(e.replace(/_/g,""))),n=e.indexOf(".");if(n!==-1){let r=e.substring(n+1).replace(/_/g,"");if(r[r.length-1]==="0")t.minFractionDigits=r.length}return t},stringify:ai}});function ex(e,t,n,{intAsBigInt:r}){let i=e[0];if(i==="-"||i==="+")t+=1;if(e=e.substring(t).replace(/_/g,""),r){switch(n){case 2:e=`0b${e}`;break;case 8:e=`0o${e}`;break;case 16:e=`0x${e}`;break}let o=BigInt(e);return i==="-"?BigInt(-1)*o:o}let s=parseInt(e,n);return i==="-"?-1*s:s}function KE(e,t,n){let{value:r}=e;if(Nh(r)){let i=r.toString(t);return r<0?"-"+n+i.substr(1):n+i}return ai(e)}var Nh=(e)=>typeof e==="bigint"||Number.isInteger(e),sM,oM,aM,lM;var cM=q(()=>{Rp();sM={identify:Nh,default:!0,tag:"tag:yaml.org,2002:int",format:"BIN",test:/^[-+]?0b[0-1_]+$/,resolve:(e,t,n)=>ex(e,2,2,n),stringify:(e)=>KE(e,2,"0b")},oM={identify:Nh,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^[-+]?0[0-7_]+$/,resolve:(e,t,n)=>ex(e,1,8,n),stringify:(e)=>KE(e,8,"0")},aM={identify:Nh,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9][0-9_]*$/,resolve:(e,t,n)=>ex(e,0,10,n),stringify:ai},lM={identify:Nh,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:(e,t,n)=>ex(e,2,16,n),stringify:(e)=>KE(e,16,"0x")}});var Lf,Oh;var JE=q(()=>{rn();Cl();Ml();Lf=class Lf extends wr{constructor(e){super(e);this.tag=Lf.tag}add(e){let t;if(Vt(e))t=e;else if(e&&typeof e==="object"&&"key"in e&&"value"in e&&e.value===null)t=new lr(e.key,null);else t=new lr(e,null);if(!ca(this.items,t.key))this.items.push(t)}get(e,t){let n=ca(this.items,e);return!t&&Vt(n)?ft(n.key)?n.key.value:n.key:n}set(e,t){if(typeof t!=="boolean")throw Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof t}`);let n=ca(this.items,e);if(n&&!t)this.items.splice(this.items.indexOf(n),1);else if(!n&&t)this.items.push(new lr(e))}toJSON(e,t){return super.toJSON(e,t,Set)}toString(e,t,n){if(!e)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},e,{allNullValues:!0}),t,n);else throw Error("Set items must all have null values")}static from(e,t,n){let{replacer:r}=n,i=new this(e);if(t&&Symbol.iterator in Object(t))for(let s of t){if(typeof r==="function")s=r.call(t,s,s);i.items.push(Pp(s,null,n))}return i}};Lf.tag="tag:yaml.org,2002:set";Oh={collection:"map",identify:(e)=>e instanceof Set,nodeClass:Lf,default:!1,tag:"tag:yaml.org,2002:set",createNode:(e,t,n)=>Lf.from(e,t,n),resolve(e,t){if(dr(e))if(e.hasAllNullValues(!0))return Object.assign(new Lf,e);else t("Set items must all have null values");else t("Expected a mapping for this tag");return e}}});function GE(e,t){let n=e[0],r=n==="-"||n==="+"?e.substring(1):e,i=(o)=>t?BigInt(o):Number(o),s=r.replace(/_/g,"").split(":").reduce((o,a)=>o*i(60)+i(a),i(0));return n==="-"?i(-1)*s:s}function uM(e){let{value:t}=e,n=(o)=>o;if(typeof t==="bigint")n=(o)=>BigInt(o);else if(isNaN(t)||!isFinite(t))return ai(e);let r="";if(t<0)r="-",t*=n(-1);let i=n(60),s=[t%i];if(t<60)s.unshift(0);else if(t=(t-s[0])/i,s.unshift(t%i),t>=60)t=(t-s[0])/i,s.unshift(t);return r+s.map((o)=>String(o).padStart(2,"0")).join(":").replace(/000000\d*$/,"")}var tx,nx,qf;var HE=q(()=>{Rp();tx={identify:(e)=>typeof e==="bigint"||Number.isInteger(e),default:!0,tag:"tag:yaml.org,2002:int",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:(e,t,{intAsBigInt:n})=>GE(e,n),stringify:uM},nx={identify:(e)=>typeof e==="number",default:!0,tag:"tag:yaml.org,2002:float",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:(e)=>GE(e,!1),stringify:uM},qf={identify:(e)=>e instanceof Date,default:!0,tag:"tag:yaml.org,2002:timestamp",test:RegExp("^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$"),resolve(e){let t=e.match(qf.test);if(!t)throw Error("!!timestamp expects a date, starting with yyyy-mm-dd");let[,n,r,i,s,o,a]=t.map(Number),l=t[7]?Number((t[7]+"00").substr(1,3)):0,c=Date.UTC(n,r-1,i,s||0,o||0,a||0,l),u=t[8];if(u&&u!=="Z"){let p=GE(u,!1);if(Math.abs(p)<30)p*=60;c-=60000*p}return new Date(c)},stringify:({value:e})=>e?.toISOString().replace(/(T00:00:00)?\.000Z$/,"")??""}});var zE;var pM=q(()=>{$p();K_();Ip();Cf();ME();eM();iM();cM();L_();UE();Z_();JE();HE();zE=[yo,ho,Ll,Ap,BE,VE,sM,oM,aM,lM,tM,nM,rM,Sh,la,kh,Eh,Oh,tx,nx,qf]});function rx(e,t,n){let r=dM.get(t);if(r&&!e)return n&&!r.includes(la)?r.concat(la):r.slice();let i=r;if(!i)if(Array.isArray(e))i=[];else{let s=Array.from(dM.keys()).filter((o)=>o!=="yaml11").map((o)=>JSON.stringify(o)).join(", ");throw Error(`Unknown schema "${t}"; use one of ${s} or define customTags array`)}if(Array.isArray(e))for(let s of e)i=i.concat(s);else if(typeof e==="function")i=e(i.slice());if(n)i=i.concat(la);return i.reduce((s,o)=>{let a=typeof o==="string"?fM[o]:o;if(!a){let l=JSON.stringify(o),c=Object.keys(fM).map((u)=>JSON.stringify(u)).join(", ");throw Error(`Unknown custom tag ${l}; use one of ${c}`)}if(!s.includes(a))s.push(a);return s},[])}var dM,fM,mM;var yM=q(()=>{$p();K_();Ip();Cf();RE();jE();CE();WC();XC();ME();L_();UE();Z_();pM();JE();HE();dM=new Map([["core",zC],["failsafe",[yo,ho,Ll]],["json",YC],["yaml11",zE],["yaml-1.1",zE]]),fM={binary:Sh,bool:Th,float:H_,floatExp:G_,floatNaN:J_,floatTime:nx,int:Q_,intHex:Y_,intOct:W_,intTime:tx,map:yo,merge:la,null:Ap,omap:kh,pairs:Eh,seq:ho,set:Oh,timestamp:qf},mM={"tag:yaml.org,2002:binary":Sh,"tag:yaml.org,2002:merge":la,"tag:yaml.org,2002:omap":kh,"tag:yaml.org,2002:pairs":Eh,"tag:yaml.org,2002:set":Oh,"tag:yaml.org,2002:timestamp":qf}});class Ph{constructor({compat:e,customTags:t,merge:n,resolveKnownTags:r,schema:i,sortMapEntries:s,toStringDefaults:o}){this.compat=Array.isArray(e)?rx(e,"compat"):e?rx(null,e):null,this.name=typeof i==="string"&&i||"core",this.knownTags=r?mM:{},this.tags=rx(t,this.name,n),this.toStringOptions=o??null,Object.defineProperty(this,oa,{value:yo}),Object.defineProperty(this,Vs,{value:Ll}),Object.defineProperty(this,Rl,{value:ho}),this.sortMapEntries=typeof s==="function"?s:s===!0?yce:null}clone(){let e=Object.create(Ph.prototype,Object.getOwnPropertyDescriptors(this));return e.tags=this.tags.slice(),e}}var yce=(e,t)=>e.keyt.key?1:0;var WE=q(()=>{rn();$p();Ip();Cf();yM()});function hM(e,t){let n=[],r=t.directives===!0;if(t.directives!==!1&&e.directives){let l=e.directives.toString(e);if(l)n.push(l),r=!0;else if(e.directives.docStart)r=!0}if(r)n.push("---");let i=j_(e,t),{commentString:s}=i.options;if(e.commentBefore){if(n.length!==1)n.unshift("");let l=s(e.commentBefore);n.unshift(mo(l,""))}let o=!1,a=null;if(e.contents){if(Yt(e.contents)){if(e.contents.spaceBefore&&r)n.push("");if(e.contents.commentBefore){let u=s(e.contents.commentBefore);n.push(mo(u,""))}i.forceBlockIndent=!!e.comment,a=e.contents.comment}let l=a?void 0:()=>o=!0,c=Fl(e.contents,i,()=>a=null,l);if(a)c+=Ka(c,"",s(a));if((c[0]==="|"||c[0]===">")&&n[n.length-1]==="---")n[n.length-1]=`--- ${c}`;else n.push(c)}else n.push(Fl(e.contents,i));if(e.directives?.docEnd)if(e.comment){let l=s(e.comment);if(l.includes(` `))n.push("..."),n.push(mo(l,""));else n.push(`... ${l}`)}else n.push("...");else{let l=e.comment;if(l&&o)l=l.replace(/^\n+/,"");if(l){if((!o||a)&&n[n.length-1]!=="")n.push("");n.push(mo(s(l),""))}}return n.join(` `)+` -`}var gM=q(()=>{rn();Dh();xh()});class ql{constructor(e,t,n){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,Vi,{value:D_});let r=null;if(typeof t==="function"||Array.isArray(t))r=t;else if(n===void 0&&t)n=t,t=void 0;let i=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:"warn",prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:"1.2"},n);this.options=i;let{version:s}=i;if(n?._directives){if(this.directives=n._directives.atDocument(),this.directives.yaml.explicit)s=this.directives.yaml.version}else this.directives=new si({version:s});this.setSchema(s,n),this.contents=e===void 0?null:this.createNode(e,r,n)}clone(){let e=Object.create(ql.prototype,{[Vi]:{value:D_}});if(e.commentBefore=this.commentBefore,e.comment=this.comment,e.errors=this.errors.slice(),e.warnings=this.warnings.slice(),e.options=Object.assign({},this.options),this.directives)e.directives=this.directives.clone();if(e.schema=this.schema.clone(),e.contents=Yt(this.contents)?this.contents.clone(e.schema):this.contents,this.range)e.range=this.range.slice();return e}add(e){if(Lf(this.contents))this.contents.add(e)}addIn(e,t){if(Lf(this.contents))this.contents.addIn(e,t)}createAlias(e,t){if(!e.anchor){let n=DE(this);e.anchor=!t||n.has(t)?TE(t||"a",n):t}return new Xc(e.anchor)}createNode(e,t,n){let r=void 0;if(typeof t==="function")e=t.call({"":e},"",e),r=t;else if(Array.isArray(t)){let y=(b)=>typeof b==="number"||b instanceof String||b instanceof Number,h=t.filter(y).map(String);if(h.length>0)t=t.concat(h);r=t}else if(n===void 0&&t)n=t,t=void 0;let{aliasDuplicateObjects:i,anchorPrefix:s,flow:o,keepUndefined:a,onTagObj:l,tag:c}=n??{},{onAnchor:u,setAnchors:p,sourceObjects:d}=MC(this,s||"a"),f={aliasDuplicateObjects:i??!0,keepUndefined:a??!1,onAnchor:u,onTagObj:l,replacer:r,schema:this.schema,sourceObjects:d},m=Va(e,c,f);if(o&&ln(m))m.flow=!0;return p(),m}createPair(e,t,n={}){let r=this.createNode(e,null,n),i=this.createNode(t,null,n);return new lr(r,i)}delete(e){return Lf(this.contents)?this.contents.delete(e):!1}deleteIn(e){if($f(e)){if(this.contents==null)return!1;return this.contents=null,!0}return Lf(this.contents)?this.contents.deleteIn(e):!1}get(e,t){return ln(this.contents)?this.contents.get(e,t):void 0}getIn(e,t){if($f(e))return!t&&ft(this.contents)?this.contents.value:this.contents;return ln(this.contents)?this.contents.getIn(e,t):void 0}has(e){return ln(this.contents)?this.contents.has(e):!1}hasIn(e){if($f(e))return this.contents!==void 0;return ln(this.contents)?this.contents.hasIn(e):!1}set(e,t){if(this.contents==null)this.contents=vh(this.schema,[e],t);else if(Lf(this.contents))this.contents.set(e,t)}setIn(e,t){if($f(e))this.contents=t;else if(this.contents==null)this.contents=vh(this.schema,Array.from(e),t);else if(Lf(this.contents))this.contents.setIn(e,t)}setSchema(e,t={}){if(typeof e==="number")e=String(e);let n;switch(e){case"1.1":if(this.directives)this.directives.yaml.version="1.1";else this.directives=new si({version:"1.1"});n={resolveKnownTags:!1,schema:"yaml-1.1"};break;case"1.2":case"next":if(this.directives)this.directives.yaml.version=e;else this.directives=new si({version:e});n={resolveKnownTags:!0,schema:"core"};break;case null:if(this.directives)delete this.directives;n=null;break;default:{let r=JSON.stringify(e);throw Error(`Expected '1.1', '1.2' or null as first argument, but found: ${r}`)}}if(t.schema instanceof Object)this.schema=t.schema;else if(n)this.schema=new Ph(Object.assign(n,t));else throw Error("With a null YAML version, the { schema: Schema } option is required")}toJS({json:e,jsonArg:t,mapAsMap:n,maxAliasCount:r,onAnchor:i,reviver:s}={}){let o={anchors:new Map,doc:this,keep:!e,mapAsMap:n===!0,mapKeyWarned:!1,maxAliasCount:typeof r==="number"?r:100},a=vr(this.contents,t??"",o);if(typeof i==="function")for(let{count:l,res:c}of o.anchors.values())i(c,l);return typeof s==="function"?Yc(s,{"":a},"",a):a}toJSON(e,t){return this.toJS({json:!0,jsonArg:e,mapAsMap:!1,onAnchor:t})}toString(e={}){if(this.errors.length>0)throw Error("Document with errors cannot be stringified");if("indent"in e&&(!Number.isInteger(e.indent)||Number(e.indent)<=0)){let t=JSON.stringify(e.indent);throw Error(`"indent" option must be a positive integer, not ${t}`)}return hM(this,e)}}function Lf(e){if(ln(e))return!0;throw Error("Expected a YAML collection as document contents")}var $h=q(()=>{bh();$_();rn();Cl();jl();WE();gM();k_();SE();Pf();wE()});var ix,Ja,sx,QE=(e,t)=>(n)=>{if(n.pos[0]===-1)return;n.linePos=n.pos.map((a)=>t.linePos(a));let{line:r,col:i}=n.linePos[0];n.message+=` at line ${r}, column ${i}`;let s=i-1,o=e.substring(t.lineStarts[r-1],t.lineStarts[r]).replace(/[\n\r]+$/,"");if(s>=60&&o.length>80){let a=Math.min(s-39,o.length-79);o="…"+o.substring(a),s-=a-1}if(o.length>80)o=o.substring(0,79)+"…";if(r>1&&/^ *$/.test(o.substring(0,s))){let a=e.substring(t.lineStarts[r-2],t.lineStarts[r-1]);if(a.length>80)a=a.substring(0,79)+`… +`}var gM=q(()=>{rn();Dh();xh()});class ql{constructor(e,t,n){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,Ki,{value:D_});let r=null;if(typeof t==="function"||Array.isArray(t))r=t;else if(n===void 0&&t)n=t,t=void 0;let i=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:"warn",prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:"1.2"},n);this.options=i;let{version:s}=i;if(n?._directives){if(this.directives=n._directives.atDocument(),this.directives.yaml.explicit)s=this.directives.yaml.version}else this.directives=new oi({version:s});this.setSchema(s,n),this.contents=e===void 0?null:this.createNode(e,r,n)}clone(){let e=Object.create(ql.prototype,{[Ki]:{value:D_}});if(e.commentBefore=this.commentBefore,e.comment=this.comment,e.errors=this.errors.slice(),e.warnings=this.warnings.slice(),e.options=Object.assign({},this.options),this.directives)e.directives=this.directives.clone();if(e.schema=this.schema.clone(),e.contents=Yt(this.contents)?this.contents.clone(e.schema):this.contents,this.range)e.range=this.range.slice();return e}add(e){if(Uf(this.contents))this.contents.add(e)}addIn(e,t){if(Uf(this.contents))this.contents.addIn(e,t)}createAlias(e,t){if(!e.anchor){let n=DE(this);e.anchor=!t||n.has(t)?TE(t||"a",n):t}return new Zc(e.anchor)}createNode(e,t,n){let r=void 0;if(typeof t==="function")e=t.call({"":e},"",e),r=t;else if(Array.isArray(t)){let y=(b)=>typeof b==="number"||b instanceof String||b instanceof Number,h=t.filter(y).map(String);if(h.length>0)t=t.concat(h);r=t}else if(n===void 0&&t)n=t,t=void 0;let{aliasDuplicateObjects:i,anchorPrefix:s,flow:o,keepUndefined:a,onTagObj:l,tag:c}=n??{},{onAnchor:u,setAnchors:p,sourceObjects:d}=MC(this,s||"a"),f={aliasDuplicateObjects:i??!0,keepUndefined:a??!1,onAnchor:u,onTagObj:l,replacer:r,schema:this.schema,sourceObjects:d},m=Va(e,c,f);if(o&&ln(m))m.flow=!0;return p(),m}createPair(e,t,n={}){let r=this.createNode(e,null,n),i=this.createNode(t,null,n);return new lr(r,i)}delete(e){return Uf(this.contents)?this.contents.delete(e):!1}deleteIn(e){if(Af(e)){if(this.contents==null)return!1;return this.contents=null,!0}return Uf(this.contents)?this.contents.deleteIn(e):!1}get(e,t){return ln(this.contents)?this.contents.get(e,t):void 0}getIn(e,t){if(Af(e))return!t&&ft(this.contents)?this.contents.value:this.contents;return ln(this.contents)?this.contents.getIn(e,t):void 0}has(e){return ln(this.contents)?this.contents.has(e):!1}hasIn(e){if(Af(e))return this.contents!==void 0;return ln(this.contents)?this.contents.hasIn(e):!1}set(e,t){if(this.contents==null)this.contents=vh(this.schema,[e],t);else if(Uf(this.contents))this.contents.set(e,t)}setIn(e,t){if(Af(e))this.contents=t;else if(this.contents==null)this.contents=vh(this.schema,Array.from(e),t);else if(Uf(this.contents))this.contents.setIn(e,t)}setSchema(e,t={}){if(typeof e==="number")e=String(e);let n;switch(e){case"1.1":if(this.directives)this.directives.yaml.version="1.1";else this.directives=new oi({version:"1.1"});n={resolveKnownTags:!1,schema:"yaml-1.1"};break;case"1.2":case"next":if(this.directives)this.directives.yaml.version=e;else this.directives=new oi({version:e});n={resolveKnownTags:!0,schema:"core"};break;case null:if(this.directives)delete this.directives;n=null;break;default:{let r=JSON.stringify(e);throw Error(`Expected '1.1', '1.2' or null as first argument, but found: ${r}`)}}if(t.schema instanceof Object)this.schema=t.schema;else if(n)this.schema=new Ph(Object.assign(n,t));else throw Error("With a null YAML version, the { schema: Schema } option is required")}toJS({json:e,jsonArg:t,mapAsMap:n,maxAliasCount:r,onAnchor:i,reviver:s}={}){let o={anchors:new Map,doc:this,keep:!e,mapAsMap:n===!0,mapKeyWarned:!1,maxAliasCount:typeof r==="number"?r:100},a=_r(this.contents,t??"",o);if(typeof i==="function")for(let{count:l,res:c}of o.anchors.values())i(c,l);return typeof s==="function"?Xc(s,{"":a},"",a):a}toJSON(e,t){return this.toJS({json:!0,jsonArg:e,mapAsMap:!1,onAnchor:t})}toString(e={}){if(this.errors.length>0)throw Error("Document with errors cannot be stringified");if("indent"in e&&(!Number.isInteger(e.indent)||Number(e.indent)<=0)){let t=JSON.stringify(e.indent);throw Error(`"indent" option must be a positive integer, not ${t}`)}return hM(this,e)}}function Uf(e){if(ln(e))return!0;throw Error("Expected a YAML collection as document contents")}var $h=q(()=>{bh();$_();rn();Cl();jl();WE();gM();k_();SE();If();wE()});var ix,Ja,sx,QE=(e,t)=>(n)=>{if(n.pos[0]===-1)return;n.linePos=n.pos.map((a)=>t.linePos(a));let{line:r,col:i}=n.linePos[0];n.message+=` at line ${r}, column ${i}`;let s=i-1,o=e.substring(t.lineStarts[r-1],t.lineStarts[r]).replace(/[\n\r]+$/,"");if(s>=60&&o.length>80){let a=Math.min(s-39,o.length-79);o="…"+o.substring(a),s-=a-1}if(o.length>80)o=o.substring(0,79)+"…";if(r>1&&/^ *$/.test(o.substring(0,s))){let a=e.substring(t.lineStarts[r-2],t.lineStarts[r-1]);if(a.length>80)a=a.substring(0,79)+`… `;o=a+o}if(/[^ ]/.test(o)){let a=1,l=n.linePos[1];if(l?.line===r&&l.col>i)a=Math.max(1,Math.min(l.col-i,80-s));let c=" ".repeat(s)+"^".repeat(a);n.message+=`: ${o} ${c} -`}};var Ih=q(()=>{ix=class ix extends Error{constructor(e,t,n,r){super();this.name=e,this.code=n,this.message=r,this.pos=t}};Ja=class Ja extends ix{constructor(e,t,n){super("YAMLParseError",e,t,n)}};sx=class sx extends ix{constructor(e,t,n){super("YAMLWarning",e,t,n)}}});function Ga(e,{flow:t,indicator:n,next:r,offset:i,onError:s,parentIndent:o,startOnNewline:a}){let l=!1,c=a,u=a,p="",d="",f=!1,m=!1,y=null,h=null,b=null,g=null,x=null,v=null,D=null;for(let O of e){if(m){if(O.type!=="space"&&O.type!=="newline"&&O.type!=="comma")s(O.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space");m=!1}if(y){if(c&&O.type!=="comment"&&O.type!=="newline")s(y,"TAB_AS_INDENT","Tabs are not allowed as indentation");y=null}switch(O.type){case"space":if(!t&&(n!=="doc-start"||r?.type!=="flow-collection")&&O.source.includes("\t"))y=O;u=!0;break;case"comment":{if(!u)s(O,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let C=O.source.substring(1)||" ";if(!p)p=C;else p+=d+C;d="",c=!1;break}case"newline":if(c){if(p)p+=O.source;else if(!v||n!=="seq-item-ind")l=!0}else d+=O.source;if(c=!0,f=!0,h||b)g=O;u=!0;break;case"anchor":if(h)s(O,"MULTIPLE_ANCHORS","A node can have at most one anchor");if(O.source.endsWith(":"))s(O.offset+O.source.length-1,"BAD_ALIAS","Anchor ending in : is ambiguous",!0);h=O,D??(D=O.offset),c=!1,u=!1,m=!0;break;case"tag":{if(b)s(O,"MULTIPLE_TAGS","A node can have at most one tag");b=O,D??(D=O.offset),c=!1,u=!1,m=!0;break}case n:if(h||b)s(O,"BAD_PROP_ORDER",`Anchors and tags must be after the ${O.source} indicator`);if(v)s(O,"UNEXPECTED_TOKEN",`Unexpected ${O.source} in ${t??"collection"}`);v=O,c=n==="seq-item-ind"||n==="explicit-key-ind",u=!1;break;case"comma":if(t){if(x)s(O,"UNEXPECTED_TOKEN",`Unexpected , in ${t}`);x=O,c=!1,u=!1;break}default:s(O,"UNEXPECTED_TOKEN",`Unexpected ${O.type} token`),c=!1,u=!1}}let T=e[e.length-1],N=T?T.offset+T.source.length:i;if(m&&r&&r.type!=="space"&&r.type!=="newline"&&r.type!=="comma"&&(r.type!=="scalar"||r.source!==""))s(r.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space");if(y&&(c&&y.indent<=o||r?.type==="block-map"||r?.type==="block-seq"))s(y,"TAB_AS_INDENT","Tabs are not allowed as indentation");return{comma:x,found:v,spaceBefore:l,comment:p,hasNewline:f,anchor:h,tag:b,newlineAfterProp:g,end:N,start:D??N}}var Ah=()=>{};function tu(e){if(!e)return null;switch(e.type){case"alias":case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":if(e.source.includes(` -`))return!0;if(e.end){for(let t of e.end)if(t.type==="newline")return!0}return!1;case"flow-collection":for(let t of e.items){for(let n of t.start)if(n.type==="newline")return!0;if(t.sep){for(let n of t.sep)if(n.type==="newline")return!0}if(tu(t.key)||tu(t.value))return!0}return!1;default:return!0}}var ox=()=>{};function Rh(e,t,n){if(t?.type==="flow-collection"){let r=t.end[0];if(r.indent===e&&(r.source==="]"||r.source==="}")&&tu(t))n(r,"BAD_INDENT","Flow end indicator should be more indented than parent",!0)}}var YE=q(()=>{ox()});function ax(e,t,n){let{uniqueKeys:r}=e.options;if(r===!1)return!1;let i=typeof r==="function"?r:(s,o)=>s===o||ft(s)&&ft(o)&&s.value===o.value;return t.some((s)=>i(s.key,n))}var XE=q(()=>{rn()});function vM({composeNode:e,composeEmptyNode:t},n,r,i,s){let a=new(s?.nodeClass??xr)(n.schema);if(n.atRoot)n.atRoot=!1;let l=r.offset,c=null;for(let u of r.items){let{start:p,key:d,sep:f,value:m}=u,y=Ga(p,{indicator:"explicit-key-ind",next:d??f?.[0],offset:l,onError:i,parentIndent:r.indent,startOnNewline:!0}),h=!y.found;if(h){if(d){if(d.type==="block-seq")i(l,"BLOCK_AS_IMPLICIT_KEY","A block sequence may not be used as an implicit map key");else if("indent"in d&&d.indent!==r.indent)i(l,"BAD_INDENT",bM)}if(!y.anchor&&!y.tag&&!f){if(c=y.end,y.comment)if(a.comment)a.comment+=` -`+y.comment;else a.comment=y.comment;continue}if(y.newlineAfterProp||tu(d))i(d??p[p.length-1],"MULTILINE_IMPLICIT_KEY","Implicit keys need to be on a single line")}else if(y.found?.indent!==r.indent)i(l,"BAD_INDENT",bM);n.atKey=!0;let b=y.end,g=d?e(n,d,y,i):t(n,b,p,null,y,i);if(n.schema.compat)Rh(r.indent,d,i);if(n.atKey=!1,ax(n,a.items,g))i(b,"DUPLICATE_KEY","Map keys must be unique");let x=Ga(f??[],{indicator:"map-value-ind",next:m,offset:g.range[2],onError:i,parentIndent:r.indent,startOnNewline:!d||d.type==="block-scalar"});if(l=x.end,x.found){if(h){if(m?.type==="block-map"&&!x.hasNewline)i(l,"BLOCK_AS_IMPLICIT_KEY","Nested mappings are not allowed in compact mappings");if(n.options.strict&&y.start{Cl();Ml();Ah();ox();YE();XE()});function xM({composeNode:e,composeEmptyNode:t},n,r,i,s){let a=new(s?.nodeClass??Ki)(n.schema);if(n.atRoot)n.atRoot=!1;if(n.atKey)n.atKey=!1;let l=r.offset,c=null;for(let{start:u,value:p}of r.items){let d=Ga(u,{indicator:"seq-item-ind",next:p,offset:l,onError:i,parentIndent:r.indent,startOnNewline:!0});if(!d.found)if(d.anchor||d.tag||p)if(p?.type==="block-seq")i(d.end,"BAD_INDENT","All sequence items must start at the same column");else i(l,"MISSING_CHAR","Sequence item without - indicator");else{if(c=d.end,d.comment)a.comment=d.comment;continue}let f=p?e(n,p,d,i):t(n,d.end,u,null,d,i);if(n.schema.compat)Rh(r.indent,p,i);l=f.range[2],a.items.push(f)}return a.range=[r.offset,l,c??l],a}var wM=q(()=>{eu();Ah();YE()});function Ha(e,t,n,r){let i="";if(e){let s=!1,o="";for(let a of e){let{source:l,type:c}=a;switch(c){case"space":s=!0;break;case"comment":{if(n&&!s)r(a,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let u=l.substring(1)||" ";if(!i)i=u;else i+=o+u;o="";break}case"newline":if(i)o+=l;s=!0;break;default:r(a,"UNEXPECTED_TOKEN",`Unexpected ${c} at node end`)}t+=l.length}}return{comment:i,offset:t}}var qf=()=>{};function DM({composeNode:e,composeEmptyNode:t},n,r,i,s){let o=r.start.source==="{",a=o?"flow map":"flow sequence",c=new(s?.nodeClass??(o?xr:Ki))(n.schema);c.flow=!0;let u=n.atRoot;if(u)n.atRoot=!1;if(n.atKey)n.atKey=!1;let p=r.offset+r.start.source.length;for(let h=0;h{ix=class ix extends Error{constructor(e,t,n,r){super();this.name=e,this.code=n,this.message=r,this.pos=t}};Ja=class Ja extends ix{constructor(e,t,n){super("YAMLParseError",e,t,n)}};sx=class sx extends ix{constructor(e,t,n){super("YAMLWarning",e,t,n)}}});function Ga(e,{flow:t,indicator:n,next:r,offset:i,onError:s,parentIndent:o,startOnNewline:a}){let l=!1,c=a,u=a,p="",d="",f=!1,m=!1,y=null,h=null,b=null,g=null,x=null,v=null,D=null;for(let O of e){if(m){if(O.type!=="space"&&O.type!=="newline"&&O.type!=="comma")s(O.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space");m=!1}if(y){if(c&&O.type!=="comment"&&O.type!=="newline")s(y,"TAB_AS_INDENT","Tabs are not allowed as indentation");y=null}switch(O.type){case"space":if(!t&&(n!=="doc-start"||r?.type!=="flow-collection")&&O.source.includes("\t"))y=O;u=!0;break;case"comment":{if(!u)s(O,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let C=O.source.substring(1)||" ";if(!p)p=C;else p+=d+C;d="",c=!1;break}case"newline":if(c){if(p)p+=O.source;else if(!v||n!=="seq-item-ind")l=!0}else d+=O.source;if(c=!0,f=!0,h||b)g=O;u=!0;break;case"anchor":if(h)s(O,"MULTIPLE_ANCHORS","A node can have at most one anchor");if(O.source.endsWith(":"))s(O.offset+O.source.length-1,"BAD_ALIAS","Anchor ending in : is ambiguous",!0);h=O,D??(D=O.offset),c=!1,u=!1,m=!0;break;case"tag":{if(b)s(O,"MULTIPLE_TAGS","A node can have at most one tag");b=O,D??(D=O.offset),c=!1,u=!1,m=!0;break}case n:if(h||b)s(O,"BAD_PROP_ORDER",`Anchors and tags must be after the ${O.source} indicator`);if(v)s(O,"UNEXPECTED_TOKEN",`Unexpected ${O.source} in ${t??"collection"}`);v=O,c=n==="seq-item-ind"||n==="explicit-key-ind",u=!1;break;case"comma":if(t){if(x)s(O,"UNEXPECTED_TOKEN",`Unexpected , in ${t}`);x=O,c=!1,u=!1;break}default:s(O,"UNEXPECTED_TOKEN",`Unexpected ${O.type} token`),c=!1,u=!1}}let T=e[e.length-1],N=T?T.offset+T.source.length:i;if(m&&r&&r.type!=="space"&&r.type!=="newline"&&r.type!=="comma"&&(r.type!=="scalar"||r.source!==""))s(r.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space");if(y&&(c&&y.indent<=o||r?.type==="block-map"||r?.type==="block-seq"))s(y,"TAB_AS_INDENT","Tabs are not allowed as indentation");return{comma:x,found:v,spaceBefore:l,comment:p,hasNewline:f,anchor:h,tag:b,newlineAfterProp:g,end:N,start:D??N}}var Ah=()=>{};function nu(e){if(!e)return null;switch(e.type){case"alias":case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":if(e.source.includes(` +`))return!0;if(e.end){for(let t of e.end)if(t.type==="newline")return!0}return!1;case"flow-collection":for(let t of e.items){for(let n of t.start)if(n.type==="newline")return!0;if(t.sep){for(let n of t.sep)if(n.type==="newline")return!0}if(nu(t.key)||nu(t.value))return!0}return!1;default:return!0}}var ox=()=>{};function Rh(e,t,n){if(t?.type==="flow-collection"){let r=t.end[0];if(r.indent===e&&(r.source==="]"||r.source==="}")&&nu(t))n(r,"BAD_INDENT","Flow end indicator should be more indented than parent",!0)}}var YE=q(()=>{ox()});function ax(e,t,n){let{uniqueKeys:r}=e.options;if(r===!1)return!1;let i=typeof r==="function"?r:(s,o)=>s===o||ft(s)&&ft(o)&&s.value===o.value;return t.some((s)=>i(s.key,n))}var XE=q(()=>{rn()});function vM({composeNode:e,composeEmptyNode:t},n,r,i,s){let a=new(s?.nodeClass??wr)(n.schema);if(n.atRoot)n.atRoot=!1;let l=r.offset,c=null;for(let u of r.items){let{start:p,key:d,sep:f,value:m}=u,y=Ga(p,{indicator:"explicit-key-ind",next:d??f?.[0],offset:l,onError:i,parentIndent:r.indent,startOnNewline:!0}),h=!y.found;if(h){if(d){if(d.type==="block-seq")i(l,"BLOCK_AS_IMPLICIT_KEY","A block sequence may not be used as an implicit map key");else if("indent"in d&&d.indent!==r.indent)i(l,"BAD_INDENT",bM)}if(!y.anchor&&!y.tag&&!f){if(c=y.end,y.comment)if(a.comment)a.comment+=` +`+y.comment;else a.comment=y.comment;continue}if(y.newlineAfterProp||nu(d))i(d??p[p.length-1],"MULTILINE_IMPLICIT_KEY","Implicit keys need to be on a single line")}else if(y.found?.indent!==r.indent)i(l,"BAD_INDENT",bM);n.atKey=!0;let b=y.end,g=d?e(n,d,y,i):t(n,b,p,null,y,i);if(n.schema.compat)Rh(r.indent,d,i);if(n.atKey=!1,ax(n,a.items,g))i(b,"DUPLICATE_KEY","Map keys must be unique");let x=Ga(f??[],{indicator:"map-value-ind",next:m,offset:g.range[2],onError:i,parentIndent:r.indent,startOnNewline:!d||d.type==="block-scalar"});if(l=x.end,x.found){if(h){if(m?.type==="block-map"&&!x.hasNewline)i(l,"BLOCK_AS_IMPLICIT_KEY","Nested mappings are not allowed in compact mappings");if(n.options.strict&&y.start{Cl();Ml();Ah();ox();YE();XE()});function xM({composeNode:e,composeEmptyNode:t},n,r,i,s){let a=new(s?.nodeClass??Ji)(n.schema);if(n.atRoot)n.atRoot=!1;if(n.atKey)n.atKey=!1;let l=r.offset,c=null;for(let{start:u,value:p}of r.items){let d=Ga(u,{indicator:"seq-item-ind",next:p,offset:l,onError:i,parentIndent:r.indent,startOnNewline:!0});if(!d.found)if(d.anchor||d.tag||p)if(p?.type==="block-seq")i(d.end,"BAD_INDENT","All sequence items must start at the same column");else i(l,"MISSING_CHAR","Sequence item without - indicator");else{if(c=d.end,d.comment)a.comment=d.comment;continue}let f=p?e(n,p,d,i):t(n,d.end,u,null,d,i);if(n.schema.compat)Rh(r.indent,p,i);l=f.range[2],a.items.push(f)}return a.range=[r.offset,l,c??l],a}var wM=q(()=>{tu();Ah();YE()});function Ha(e,t,n,r){let i="";if(e){let s=!1,o="";for(let a of e){let{source:l,type:c}=a;switch(c){case"space":s=!0;break;case"comment":{if(n&&!s)r(a,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let u=l.substring(1)||" ";if(!i)i=u;else i+=o+u;o="";break}case"newline":if(i)o+=l;s=!0;break;default:r(a,"UNEXPECTED_TOKEN",`Unexpected ${c} at node end`)}t+=l.length}}return{comment:i,offset:t}}var Bf=()=>{};function DM({composeNode:e,composeEmptyNode:t},n,r,i,s){let o=r.start.source==="{",a=o?"flow map":"flow sequence",c=new(s?.nodeClass??(o?wr:Ji))(n.schema);c.flow=!0;let u=n.atRoot;if(u)n.atRoot=!1;if(n.atKey)n.atKey=!1;let p=r.offset+r.start.source.length;for(let h=0;h0){let h=Ha(m,y,n.options.strict,i);if(h.comment)if(c.comment)c.comment+=` -`+h.comment;else c.comment=h.comment;c.range=[r.offset,y,h.offset]}else c.range=[r.offset,y,y];return c}var ZE="Block collections are not allowed within flow collections",ek=(e)=>e&&(e.type==="block-map"||e.type==="block-seq");var TM=q(()=>{rn();Cl();Ml();eu();qf();Ah();ox();XE()});function tk(e,t,n,r,i,s){let o=n.type==="block-map"?vM(e,t,n,r,s):n.type==="block-seq"?xM(e,t,n,r,s):DM(e,t,n,r,s),a=o.constructor;if(i==="!"||i===a.tagName)return o.tag=a.tagName,o;if(i)o.tag=i;return o}function SM(e,t,n,r,i){let s=r.tag,o=!s?null:t.directives.tagName(s.source,(d)=>i(s,"TAG_RESOLVE_FAILED",d));if(n.type==="block-seq"){let{anchor:d,newlineAfterProp:f}=r,m=d&&s?d.offset>s.offset?d:s:d??s;if(m&&(!f||f.offsetd.tag===o&&d.collection===a);if(!l){let d=t.schema.knownTags[o];if(d?.collection===a)t.schema.tags.push(Object.assign({},d,{default:!1})),l=d;else{if(d)i(s,"BAD_COLLECTION_TYPE",`${d.tag} used for ${a} collection, but expects ${d.collection??"scalar"}`,!0);else i(s,"TAG_RESOLVE_FAILED",`Unresolved tag: ${o}`,!0);return tk(e,t,n,i,o)}}let c=tk(e,t,n,i,o,l),u=l.resolve?.(c,(d)=>i(s,"TAG_RESOLVE_FAILED",d),t.options)??c,p=Yt(u)?u:new at(u);if(p.range=c.range,p.tag=o,l?.format)p.format=l.format;return p}var EM=q(()=>{rn();_r();Ml();eu();_M();wM();TM()});function nk(e,t,n){let r=t.offset,i=yce(t,e.options.strict,n);if(!i)return{value:"",type:null,comment:"",range:[r,r,r]};let s=i.mode===">"?at.BLOCK_FOLDED:at.BLOCK_LITERAL,o=t.source?hce(t.source):[],a=o.length;for(let y=o.length-1;y>=0;--y){let h=o[y][1];if(h===""||h==="\r")a=y;else break}if(a===0){let y=i.chomp==="+"&&o.length>0?` +`+C.comment;else O.comment=C.comment;let te=new lr(O,X);if(n.options.keepSourceTokens)te.srcToken=b;if(o){let L=c;if(ax(n,L.items,O))i(N,"DUPLICATE_KEY","Map keys must be unique");L.items.push(te)}else{let L=new wr(n.schema);L.flow=!0,L.items.push(te);let Y=(X??O).range;L.range=[O.range[0],Y[1],Y[2]],c.items.push(L)}p=X?X.range[2]:C.end}}let d=o?"}":"]",[f,...m]=r.end,y=p;if(f?.source===d)y=f.offset+f.source.length;else{let h=a[0].toUpperCase()+a.substring(1),b=u?`${h} must end with a ${d}`:`${h} in block collection must be sufficiently indented and end with a ${d}`;if(i(p,u?"MISSING_CHAR":"BAD_INDENT",b),f&&f.source.length!==1)m.unshift(f)}if(m.length>0){let h=Ha(m,y,n.options.strict,i);if(h.comment)if(c.comment)c.comment+=` +`+h.comment;else c.comment=h.comment;c.range=[r.offset,y,h.offset]}else c.range=[r.offset,y,y];return c}var ZE="Block collections are not allowed within flow collections",ek=(e)=>e&&(e.type==="block-map"||e.type==="block-seq");var TM=q(()=>{rn();Cl();Ml();tu();Bf();Ah();ox();XE()});function tk(e,t,n,r,i,s){let o=n.type==="block-map"?vM(e,t,n,r,s):n.type==="block-seq"?xM(e,t,n,r,s):DM(e,t,n,r,s),a=o.constructor;if(i==="!"||i===a.tagName)return o.tag=a.tagName,o;if(i)o.tag=i;return o}function SM(e,t,n,r,i){let s=r.tag,o=!s?null:t.directives.tagName(s.source,(d)=>i(s,"TAG_RESOLVE_FAILED",d));if(n.type==="block-seq"){let{anchor:d,newlineAfterProp:f}=r,m=d&&s?d.offset>s.offset?d:s:d??s;if(m&&(!f||f.offsetd.tag===o&&d.collection===a);if(!l){let d=t.schema.knownTags[o];if(d?.collection===a)t.schema.tags.push(Object.assign({},d,{default:!1})),l=d;else{if(d)i(s,"BAD_COLLECTION_TYPE",`${d.tag} used for ${a} collection, but expects ${d.collection??"scalar"}`,!0);else i(s,"TAG_RESOLVE_FAILED",`Unresolved tag: ${o}`,!0);return tk(e,t,n,i,o)}}let c=tk(e,t,n,i,o,l),u=l.resolve?.(c,(d)=>i(s,"TAG_RESOLVE_FAILED",d),t.options)??c,p=Yt(u)?u:new at(u);if(p.range=c.range,p.tag=o,l?.format)p.format=l.format;return p}var EM=q(()=>{rn();xr();Ml();tu();_M();wM();TM()});function nk(e,t,n){let r=t.offset,i=hce(t,e.options.strict,n);if(!i)return{value:"",type:null,comment:"",range:[r,r,r]};let s=i.mode===">"?at.BLOCK_FOLDED:at.BLOCK_LITERAL,o=t.source?gce(t.source):[],a=o.length;for(let y=o.length-1;y>=0;--y){let h=o[y][1];if(h===""||h==="\r")a=y;else break}if(a===0){let y=i.chomp==="+"&&o.length>0?` `.repeat(Math.max(1,o.length-1)):"",h=r+i.length;if(t.source)h+=t.source.length;return{value:y,type:s,comment:i.comment,range:[r,h,h]}}let l=t.indent+i.indent,c=t.offset+i.length,u=0;for(let y=0;yl)l=h.length}else{if(h.length=a;--y)if(o[y][0].length>l)a=y+1;let p="",d="",f=!1;for(let y=0;yl||b[0]==="\t"){if(d===" ")d=` @@ -81,27 +81,27 @@ ${c} `+o[y][0].slice(l);if(p[p.length-1]!==` `)p+=` `;break;default:p+=` -`}let m=r+i.length+t.source.length;return{value:p,type:s,comment:i.comment,range:[r,m,m]}}function yce({offset:e,props:t},n,r){if(t[0].type!=="block-scalar-header")return r(t[0],"IMPOSSIBLE","Block scalar header not found"),null;let{source:i}=t[0],s=i[0],o=0,a="",l=-1;for(let d=1;d{_r()});function ik(e,t,n){let{offset:r,type:i,source:s,end:o}=e,a,l,c=(d,f,m)=>n(r+d,f,m);switch(i){case"scalar":a=at.PLAIN,l=gce(s,c);break;case"single-quoted-scalar":a=at.QUOTE_SINGLE,l=bce(s,c);break;case"double-quoted-scalar":a=at.QUOTE_DOUBLE,l=vce(s,c);break;default:return n(e,"UNEXPECTED_TOKEN",`Expected a flow scalar value, but found: ${i}`),{value:"",type:null,comment:"",range:[r,r+s.length,r+s.length]}}let u=r+s.length,p=Ha(o,u,t,n);return{value:l,type:a,comment:p.comment,range:[r,u,p.offset]}}function gce(e,t){let n="";switch(e[0]){case"\t":n="a tab character";break;case",":n="flow indicator character ,";break;case"%":n="directive indicator character %";break;case"|":case">":{n=`block scalar indicator ${e[0]}`;break}case"@":case"`":{n=`reserved character ${e[0]}`;break}}if(n)t(0,"BAD_SCALAR_START",`Plain value cannot start with ${n}`);return kM(e)}function bce(e,t){if(e[e.length-1]!=="'"||e.length===1)t(e.length,"MISSING_CHAR","Missing closing 'quote");return kM(e.slice(1,-1)).replace(/''/g,"'")}function kM(e){let t=/(.*?)\r?\n/sy,n=t.exec(e);if(!n)return e;let r,i;try{r=new RegExp("(?{xr()});function ik(e,t,n){let{offset:r,type:i,source:s,end:o}=e,a,l,c=(d,f,m)=>n(r+d,f,m);switch(i){case"scalar":a=at.PLAIN,l=bce(s,c);break;case"single-quoted-scalar":a=at.QUOTE_SINGLE,l=vce(s,c);break;case"double-quoted-scalar":a=at.QUOTE_DOUBLE,l=_ce(s,c);break;default:return n(e,"UNEXPECTED_TOKEN",`Expected a flow scalar value, but found: ${i}`),{value:"",type:null,comment:"",range:[r,r+s.length,r+s.length]}}let u=r+s.length,p=Ha(o,u,t,n);return{value:l,type:a,comment:p.comment,range:[r,u,p.offset]}}function bce(e,t){let n="";switch(e[0]){case"\t":n="a tab character";break;case",":n="flow indicator character ,";break;case"%":n="directive indicator character %";break;case"|":case">":{n=`block scalar indicator ${e[0]}`;break}case"@":case"`":{n=`reserved character ${e[0]}`;break}}if(n)t(0,"BAD_SCALAR_START",`Plain value cannot start with ${n}`);return kM(e)}function vce(e,t){if(e[e.length-1]!=="'"||e.length===1)t(e.length,"MISSING_CHAR","Missing closing 'quote");return kM(e.slice(1,-1)).replace(/''/g,"'")}function kM(e){let t=/(.*?)\r?\n/sy,n=t.exec(e);if(!n)return e;let r,i;try{r=new RegExp("(?s?e.slice(s,r+1):i}else n+=i}if(e[e.length-1]!=='"'||e.length===1)t(e.length,"MISSING_CHAR",'Missing closing "quote');return n}function _ce(e,t){let n="",r=e[t+1];while(r===" "||r==="\t"||r===` +`))n+=r>s?e.slice(s,r+1):i}else n+=i}if(e[e.length-1]!=='"'||e.length===1)t(e.length,"MISSING_CHAR",'Missing closing "quote');return n}function xce(e,t){let n="",r=e[t+1];while(r===" "||r==="\t"||r===` `||r==="\r"){if(r==="\r"&&e[t+2]!==` `)break;if(r===` `)n+=` -`;t+=1,r=e[t+1]}if(!n)n=" ";return{fold:n,offset:t}}function wce(e,t,n,r){let i=e.substr(t,n),o=i.length===n&&/^[0-9a-fA-F]+$/.test(i)?parseInt(i,16):NaN;try{return String.fromCodePoint(o)}catch{let a=e.substr(t-2,n+2);return r(t-2,"BAD_DQ_ESCAPE",`Invalid escape sequence ${a}`),a}}var xce;var sk=q(()=>{_r();qf();xce={"0":"\x00",a:"\x07",b:"\b",e:"\x1B",f:"\f",n:` -`,r:"\r",t:"\t",v:"\v",N:"…",_:" ",L:"\u2028",P:"\u2029"," ":" ",'"':'"',"/":"/","\\":"\\","\t":"\t"}});function ok(e,t,n,r){let{value:i,type:s,comment:o,range:a}=t.type==="block-scalar"?nk(e,t,r):ik(t,e.options.strict,r),l=n?e.directives.tagName(n.source,(p)=>r(n,"TAG_RESOLVE_FAILED",p)):null,c;if(e.options.stringKeys&&e.atKey)c=e.schema[Bs];else if(l)c=Dce(e.schema,i,l,n,r);else if(t.type==="scalar")c=Tce(e,i,t,r);else c=e.schema[Bs];let u;try{let p=c.resolve(i,(d)=>r(n??t,"TAG_RESOLVE_FAILED",d),e.options);u=ft(p)?p:new at(p)}catch(p){let d=p instanceof Error?p.message:String(p);r(n??t,"TAG_RESOLVE_FAILED",d),u=new at(i)}if(u.range=a,u.source=i,s)u.type=s;if(l)u.tag=l;if(c.format)u.format=c.format;if(o)u.comment=o;return u}function Dce(e,t,n,r,i){if(n==="!")return e[Bs];let s=[];for(let a of e.tags)if(!a.collection&&a.tag===n)if(a.default&&a.test)s.push(a);else return a;for(let a of s)if(a.test?.test(t))return a;let o=e.knownTags[n];if(o&&!o.collection)return e.tags.push(Object.assign({},o,{default:!1,test:void 0})),o;return i(r,"TAG_RESOLVE_FAILED",`Unresolved tag: ${n}`,n!=="tag:yaml.org,2002:str"),e[Bs]}function Tce({atKey:e,directives:t,schema:n},r,i,s){let o=n.tags.find((a)=>(a.default===!0||e&&a.default==="key")&&a.test?.test(r))||n[Bs];if(n.compat){let a=n.compat.find((l)=>l.default&&l.test?.test(r))??n[Bs];if(o.tag!==a.tag){let l=t.tagString(o.tag),c=t.tagString(a.tag),u=`Value may be parsed as either ${l} or ${c}`;s(i,"TAG_RESOLVE_FAILED",u,!0)}}return o}var NM=q(()=>{rn();_r();rk();sk()});function OM(e,t,n){if(t){n??(n=t.length);for(let r=n-1;r>=0;--r){let i=t[r];switch(i.type){case"space":case"comment":case"newline":e-=i.source.length;continue}i=t[++r];while(i?.type==="space")e+=i.source.length,i=t[++r];break}}return e}var PM=()=>{};function ak(e,t,n,r){let i=e.atKey,{spaceBefore:s,comment:o,anchor:a,tag:l}=n,c,u=!0;switch(t.type){case"alias":if(c=Ece(e,t,r),a||l)r(t,"ALIAS_PROPS","An alias node must not specify any properties");break;case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"block-scalar":if(c=ok(e,t,l,r),a)c.anchor=a.source.substring(1);break;case"block-map":case"block-seq":case"flow-collection":try{if(c=SM(Sce,e,t,n,r),a)c.anchor=a.source.substring(1)}catch(p){let d=p instanceof Error?p.message:String(p);r(t,"RESOURCE_EXHAUSTION",d)}break;default:{let p=t.type==="error"?t.message:`Unsupported token (type: ${t.type})`;r(t,"UNEXPECTED_TOKEN",p),u=!1}}if(c??(c=lx(e,t.offset,void 0,null,n,r)),a&&c.anchor==="")r(a,"BAD_ALIAS","Anchor cannot be an empty string");if(i&&e.options.stringKeys&&(!ft(c)||typeof c.value!=="string"||c.tag&&c.tag!=="tag:yaml.org,2002:str"))r(l??t,"NON_STRING_KEY","With stringKeys, all keys must be strings");if(s)c.spaceBefore=!0;if(o)if(t.type==="scalar"&&t.source==="")c.comment=o;else c.commentBefore=o;if(e.options.keepSourceTokens&&u)c.srcToken=t;return c}function lx(e,t,n,r,{spaceBefore:i,comment:s,anchor:o,tag:a,end:l},c){let u={type:"scalar",offset:OM(t,n,r),indent:-1,source:""},p=ok(e,u,a,c);if(o){if(p.anchor=o.source.substring(1),p.anchor==="")c(o,"BAD_ALIAS","Anchor cannot be an empty string")}if(i)p.spaceBefore=!0;if(s)p.comment=s,p.range[2]=l;return p}function Ece({options:e},{offset:t,source:n,end:r},i){let s=new Xc(n.substring(1));if(s.source==="")i(t,"BAD_ALIAS","Alias cannot be an empty string");if(s.source.endsWith(":"))i(t+n.length-1,"BAD_ALIAS","Alias ending in : is ambiguous",!0);let o=t+n.length,a=Ha(r,o,e.strict,i);if(s.range=[t,o,a.offset],a.comment)s.comment=a.comment;return s}var Sce;var $M=q(()=>{bh();rn();EM();NM();qf();PM();Sce={composeNode:ak,composeEmptyNode:lx}});function IM(e,t,{offset:n,start:r,value:i,end:s},o){let a=Object.assign({_directives:t},e),l=new ql(void 0,a),c={atKey:!1,atRoot:!0,directives:l.directives,options:l.options,schema:l.schema},u=Ga(r,{indicator:"doc-start",next:i??s?.[0],offset:n,onError:o,parentIndent:0,startOnNewline:!0});if(u.found){if(l.directives.docStart=!0,i&&(i.type==="block-map"||i.type==="block-seq")&&!u.hasNewline)o(u.end,"MISSING_CHAR","Block collection cannot start on same line with directives-end marker")}l.contents=i?ak(c,i,u,o):lx(c,u.end,r,null,u,o);let p=l.contents.range[2],d=Ha(s,p,!1,o);if(d.comment)l.comment=d.comment;return l.range=[n,p,d.offset],l}var AM=q(()=>{$h();$M();qf();Ah()});function jh(e){if(typeof e==="number")return[e,e+1];if(Array.isArray(e))return e.length===2?e:[e[0],e[1]];let{offset:t,source:n}=e;return[t,t+(typeof n==="string"?n.length:1)]}function RM(e){let t="",n=!1,r=!1;for(let i=0;i{xr();Bf();wce={"0":"\x00",a:"\x07",b:"\b",e:"\x1B",f:"\f",n:` +`,r:"\r",t:"\t",v:"\v",N:"…",_:" ",L:"\u2028",P:"\u2029"," ":" ",'"':'"',"/":"/","\\":"\\","\t":"\t"}});function ok(e,t,n,r){let{value:i,type:s,comment:o,range:a}=t.type==="block-scalar"?nk(e,t,r):ik(t,e.options.strict,r),l=n?e.directives.tagName(n.source,(p)=>r(n,"TAG_RESOLVE_FAILED",p)):null,c;if(e.options.stringKeys&&e.atKey)c=e.schema[Vs];else if(l)c=Tce(e.schema,i,l,n,r);else if(t.type==="scalar")c=Sce(e,i,t,r);else c=e.schema[Vs];let u;try{let p=c.resolve(i,(d)=>r(n??t,"TAG_RESOLVE_FAILED",d),e.options);u=ft(p)?p:new at(p)}catch(p){let d=p instanceof Error?p.message:String(p);r(n??t,"TAG_RESOLVE_FAILED",d),u=new at(i)}if(u.range=a,u.source=i,s)u.type=s;if(l)u.tag=l;if(c.format)u.format=c.format;if(o)u.comment=o;return u}function Tce(e,t,n,r,i){if(n==="!")return e[Vs];let s=[];for(let a of e.tags)if(!a.collection&&a.tag===n)if(a.default&&a.test)s.push(a);else return a;for(let a of s)if(a.test?.test(t))return a;let o=e.knownTags[n];if(o&&!o.collection)return e.tags.push(Object.assign({},o,{default:!1,test:void 0})),o;return i(r,"TAG_RESOLVE_FAILED",`Unresolved tag: ${n}`,n!=="tag:yaml.org,2002:str"),e[Vs]}function Sce({atKey:e,directives:t,schema:n},r,i,s){let o=n.tags.find((a)=>(a.default===!0||e&&a.default==="key")&&a.test?.test(r))||n[Vs];if(n.compat){let a=n.compat.find((l)=>l.default&&l.test?.test(r))??n[Vs];if(o.tag!==a.tag){let l=t.tagString(o.tag),c=t.tagString(a.tag),u=`Value may be parsed as either ${l} or ${c}`;s(i,"TAG_RESOLVE_FAILED",u,!0)}}return o}var NM=q(()=>{rn();xr();rk();sk()});function OM(e,t,n){if(t){n??(n=t.length);for(let r=n-1;r>=0;--r){let i=t[r];switch(i.type){case"space":case"comment":case"newline":e-=i.source.length;continue}i=t[++r];while(i?.type==="space")e+=i.source.length,i=t[++r];break}}return e}var PM=()=>{};function ak(e,t,n,r){let i=e.atKey,{spaceBefore:s,comment:o,anchor:a,tag:l}=n,c,u=!0;switch(t.type){case"alias":if(c=kce(e,t,r),a||l)r(t,"ALIAS_PROPS","An alias node must not specify any properties");break;case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"block-scalar":if(c=ok(e,t,l,r),a)c.anchor=a.source.substring(1);break;case"block-map":case"block-seq":case"flow-collection":try{if(c=SM(Ece,e,t,n,r),a)c.anchor=a.source.substring(1)}catch(p){let d=p instanceof Error?p.message:String(p);r(t,"RESOURCE_EXHAUSTION",d)}break;default:{let p=t.type==="error"?t.message:`Unsupported token (type: ${t.type})`;r(t,"UNEXPECTED_TOKEN",p),u=!1}}if(c??(c=lx(e,t.offset,void 0,null,n,r)),a&&c.anchor==="")r(a,"BAD_ALIAS","Anchor cannot be an empty string");if(i&&e.options.stringKeys&&(!ft(c)||typeof c.value!=="string"||c.tag&&c.tag!=="tag:yaml.org,2002:str"))r(l??t,"NON_STRING_KEY","With stringKeys, all keys must be strings");if(s)c.spaceBefore=!0;if(o)if(t.type==="scalar"&&t.source==="")c.comment=o;else c.commentBefore=o;if(e.options.keepSourceTokens&&u)c.srcToken=t;return c}function lx(e,t,n,r,{spaceBefore:i,comment:s,anchor:o,tag:a,end:l},c){let u={type:"scalar",offset:OM(t,n,r),indent:-1,source:""},p=ok(e,u,a,c);if(o){if(p.anchor=o.source.substring(1),p.anchor==="")c(o,"BAD_ALIAS","Anchor cannot be an empty string")}if(i)p.spaceBefore=!0;if(s)p.comment=s,p.range[2]=l;return p}function kce({options:e},{offset:t,source:n,end:r},i){let s=new Zc(n.substring(1));if(s.source==="")i(t,"BAD_ALIAS","Alias cannot be an empty string");if(s.source.endsWith(":"))i(t+n.length-1,"BAD_ALIAS","Alias ending in : is ambiguous",!0);let o=t+n.length,a=Ha(r,o,e.strict,i);if(s.range=[t,o,a.offset],a.comment)s.comment=a.comment;return s}var Ece;var $M=q(()=>{bh();rn();EM();NM();Bf();PM();Ece={composeNode:ak,composeEmptyNode:lx}});function IM(e,t,{offset:n,start:r,value:i,end:s},o){let a=Object.assign({_directives:t},e),l=new ql(void 0,a),c={atKey:!1,atRoot:!0,directives:l.directives,options:l.options,schema:l.schema},u=Ga(r,{indicator:"doc-start",next:i??s?.[0],offset:n,onError:o,parentIndent:0,startOnNewline:!0});if(u.found){if(l.directives.docStart=!0,i&&(i.type==="block-map"||i.type==="block-seq")&&!u.hasNewline)o(u.end,"MISSING_CHAR","Block collection cannot start on same line with directives-end marker")}l.contents=i?ak(c,i,u,o):lx(c,u.end,r,null,u,o);let p=l.contents.range[2],d=Ha(s,p,!1,o);if(d.comment)l.comment=d.comment;return l.range=[n,p,d.offset],l}var AM=q(()=>{$h();$M();Bf();Ah()});function jh(e){if(typeof e==="number")return[e,e+1];if(Array.isArray(e))return e.length===2?e:[e[0],e[1]];let{offset:t,source:n}=e;return[t,t+(typeof n==="string"?n.length:1)]}function RM(e){let t="",n=!1,r=!1;for(let i=0;i{let s=jh(t);if(i)this.warnings.push(new sx(s,n,r));else this.errors.push(new Ja(s,n,r))},this.directives=new si({version:e.version||"1.2"}),this.options=e}decorate(e,t){let{comment:n,afterEmptyLine:r}=RM(this.prelude);if(n){let i=e.contents;if(t)e.comment=e.comment?`${e.comment} +`)+(s.substring(1)||" "),n=!0,r=!1;break;case"%":if(e[i+1]?.[0]!=="#")i+=1;n=!1;break;default:if(!n)r=!0;n=!1}}return{comment:t,afterEmptyLine:r}}class cx{constructor(e={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(t,n,r,i)=>{let s=jh(t);if(i)this.warnings.push(new sx(s,n,r));else this.errors.push(new Ja(s,n,r))},this.directives=new oi({version:e.version||"1.2"}),this.options=e}decorate(e,t){let{comment:n,afterEmptyLine:r}=RM(this.prelude);if(n){let i=e.contents;if(t)e.comment=e.comment?`${e.comment} ${n}`:n;else if(r||e.directives.docStart||!i)e.commentBefore=n;else if(ln(i)&&!i.flow&&i.items.length>0){let s=i.items[0];if(Vt(s))s=s.key;let o=s.commentBefore;s.commentBefore=o?`${n} ${o}`:n}else{let s=i.commentBefore;i.commentBefore=s?`${n} ${s}`:n}}if(t){for(let i=0;i{let i=jh(e);i[0]+=t,this.onError(i,"BAD_DIRECTIVE",n,r)}),this.prelude.push(e.source),this.atDirectives=!0;break;case"document":{let t=IM(this.options,this.directives,e,this.onError);if(this.atDirectives&&!t.directives.docStart)this.onError(e,"MISSING_CHAR","Missing directives-end/doc-start indicator line");if(this.decorate(t,!1),this.doc)yield this.doc;this.doc=t,this.atDirectives=!1;break}case"byte-order-mark":case"space":break;case"comment":case"newline":this.prelude.push(e.source);break;case"error":{let t=e.source?`${e.message}: ${JSON.stringify(e.source)}`:e.message,n=new Ja(jh(e),"UNEXPECTED_TOKEN",t);if(this.atDirectives||!this.doc)this.errors.push(n);else this.doc.errors.push(n);break}case"doc-end":{if(!this.doc){this.errors.push(new Ja(jh(e),"UNEXPECTED_TOKEN","Unexpected doc-end without preceding document"));break}this.doc.directives.docEnd=!0;let t=Ha(e.end,e.offset+e.source.length,this.doc.options.strict,this.onError);if(this.decorate(this.doc,!0),t.comment){let n=this.doc.comment;this.doc.comment=n?`${n} -${t.comment}`:t.comment}this.doc.range[2]=t.offset;break}default:this.errors.push(new Ja(jh(e),"UNEXPECTED_TOKEN",`Unsupported token ${e.type}`))}}*end(e=!1,t=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if(e){let n=Object.assign({_directives:this.directives},this.options),r=new ql(void 0,n);if(this.atDirectives)this.onError(t,"MISSING_CHAR","Missing directives-end indicator line");r.range=[0,t,t],this.decorate(r,!1),yield r}}}var lk=q(()=>{wE();$h();Ih();rn();AM();qf()});var jM=q(()=>{rk();sk();Ih();Rf()});var FM=()=>{};function Ap(e,t){if("type"in e&&e.type==="document")e={start:e.start,value:e.value};MM(Object.freeze([]),e,t)}function MM(e,t,n){let r=n(t,e);if(typeof r==="symbol")return r;for(let i of["key","value"]){let s=t[i];if(s&&"items"in s){for(let o=0;o{ck=Symbol("break visit"),kce=Symbol("skip children"),CM=Symbol("remove item");Ap.BREAK=ck;Ap.SKIP=kce;Ap.REMOVE=CM;Ap.itemAtPath=(e,t)=>{let n=e;for(let[r,i]of t){let s=n?.[r];if(s&&"items"in s)n=s.items[i];else return}return n};Ap.parentCollection=(e,t)=>{let n=Ap.itemAtPath(e,t.slice(0,-1)),r=t[t.length-1][0],i=n?.[r];if(i&&"items"in i)return i;throw Error("Parent collection not found")}});function qM(e){switch(e){case uk:return"byte-order-mark";case pk:return"doc-mode";case dk:return"flow-error-end";case ux:return"scalar";case"---":return"doc-start";case"...":return"doc-end";case"":case` +${t.comment}`:t.comment}this.doc.range[2]=t.offset;break}default:this.errors.push(new Ja(jh(e),"UNEXPECTED_TOKEN",`Unsupported token ${e.type}`))}}*end(e=!1,t=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if(e){let n=Object.assign({_directives:this.directives},this.options),r=new ql(void 0,n);if(this.atDirectives)this.onError(t,"MISSING_CHAR","Missing directives-end indicator line");r.range=[0,t,t],this.decorate(r,!1),yield r}}}var lk=q(()=>{wE();$h();Ih();rn();AM();Bf()});var jM=q(()=>{rk();sk();Ih();Ff()});var FM=()=>{};function jp(e,t){if("type"in e&&e.type==="document")e={start:e.start,value:e.value};MM(Object.freeze([]),e,t)}function MM(e,t,n){let r=n(t,e);if(typeof r==="symbol")return r;for(let i of["key","value"]){let s=t[i];if(s&&"items"in s){for(let o=0;o{ck=Symbol("break visit"),Nce=Symbol("skip children"),CM=Symbol("remove item");jp.BREAK=ck;jp.SKIP=Nce;jp.REMOVE=CM;jp.itemAtPath=(e,t)=>{let n=e;for(let[r,i]of t){let s=n?.[r];if(s&&"items"in s)n=s.items[i];else return}return n};jp.parentCollection=(e,t)=>{let n=jp.itemAtPath(e,t.slice(0,-1)),r=t[t.length-1][0],i=n?.[r];if(i&&"items"in i)return i;throw Error("Parent collection not found")}});function qM(e){switch(e){case uk:return"byte-order-mark";case pk:return"doc-mode";case dk:return"flow-error-end";case ux:return"scalar";case"---":return"doc-start";case"...":return"doc-end";case"":case` `:case`\r `:return"newline";case"-":return"seq-item-ind";case"?":return"explicit-key-ind";case":":return"map-value-ind";case"{":return"flow-map-start";case"}":return"flow-map-end";case"[":return"flow-seq-start";case"]":return"flow-seq-end";case",":return"comma"}switch(e[0]){case" ":case"\t":return"space";case"#":return"comment";case"%":return"directive-line";case"*":return"alias";case"&":return"anchor";case"!":return"tag";case"'":return"single-quoted-scalar";case'"':return"double-quoted-scalar";case"|":case">":return"block-scalar-header"}return null}var uk="\uFEFF",pk="\x02",dk="\x18",ux="\x1F";var px=q(()=>{jM();FM();LM()});function ua(e){switch(e){case void 0:case" ":case` `:case"\r":case"\t":return!0;default:return!1}}class fx{constructor(){this.atEnd=!1,this.blockScalarIndent=-1,this.blockScalarKeep=!1,this.buffer="",this.flowKey=!1,this.flowLevel=0,this.indentNext=0,this.indentValue=0,this.lineEndPos=null,this.next=null,this.pos=0}*lex(e,t=!1){if(e){if(typeof e!=="string")throw TypeError("source is not a string");this.buffer=this.buffer?this.buffer+e:e,this.lineEndPos=null}this.atEnd=!t;let n=this.next??"stream";while(n&&(t||this.hasChars(1)))n=yield*this.parseNext(n)}atLineEnd(){let e=this.pos,t=this.buffer[e];while(t===" "||t==="\t")t=this.buffer[++e];if(!t||t==="#"||t===` @@ -119,30 +119,30 @@ ${t.comment}`:t.comment}this.doc.range[2]=t.offset;break}default:this.errors.pus `&&i>=this.pos&&i+1+t>o)e=i;else break}while(!0);return yield ux,yield*this.pushToIndex(e+1,!0),yield*this.parseLineStart()}*parsePlainScalar(){let e=this.flowLevel>0,t=this.pos-1,n=this.pos-1,r;while(r=this.buffer[++n])if(r===":"){let i=this.buffer[n+1];if(ua(i)||e&&dx.has(i))break;t=n}else if(ua(r)){let i=this.buffer[n+1];if(r==="\r")if(i===` `)n+=1,r=` `,i=this.buffer[n+1];else t=n;if(i==="#"||e&&dx.has(i))break;if(r===` -`){let s=this.continueScalar(n+1);if(s===-1)break;n=Math.max(n,s-2)}}else{if(e&&dx.has(r))break;t=n}if(!r&&!this.atEnd)return this.setNext("plain-scalar");return yield ux,yield*this.pushToIndex(t+1,!0),e?"flow":"doc"}*pushCount(e){if(e>0)return yield this.buffer.substr(this.pos,e),this.pos+=e,e;return 0}*pushToIndex(e,t){let n=this.buffer.slice(this.pos,e);if(n)return yield n,this.pos+=n.length,n.length;else if(t)yield"";return 0}*pushIndicators(){let e=0;e:while(!0){switch(this.charAt(0)){case"!":e+=yield*this.pushTag(),e+=yield*this.pushSpaces(!0);continue e;case"&":e+=yield*this.pushUntil(fk),e+=yield*this.pushSpaces(!0);continue e;case"-":case"?":case":":{let t=this.flowLevel>0,n=this.charAt(1);if(ua(n)||t&&dx.has(n)){if(!t)this.indentNext=this.indentValue+1;else if(this.flowKey)this.flowKey=!1;e+=yield*this.pushCount(1),e+=yield*this.pushSpaces(!0);continue e}}}break e}return e}*pushTag(){if(this.charAt(1)==="<"){let e=this.pos+2,t=this.buffer[e];while(!ua(t)&&t!==">")t=this.buffer[++e];return yield*this.pushToIndex(t===">"?e+1:e,!1)}else{let e=this.pos+1,t=this.buffer[e];while(t)if(Oce.has(t))t=this.buffer[++e];else if(t==="%"&&UM.has(this.buffer[e+1])&&UM.has(this.buffer[e+2]))t=this.buffer[e+=3];else break;return yield*this.pushToIndex(e,!1)}}*pushNewline(){let e=this.buffer[this.pos];if(e===` +`){let s=this.continueScalar(n+1);if(s===-1)break;n=Math.max(n,s-2)}}else{if(e&&dx.has(r))break;t=n}if(!r&&!this.atEnd)return this.setNext("plain-scalar");return yield ux,yield*this.pushToIndex(t+1,!0),e?"flow":"doc"}*pushCount(e){if(e>0)return yield this.buffer.substr(this.pos,e),this.pos+=e,e;return 0}*pushToIndex(e,t){let n=this.buffer.slice(this.pos,e);if(n)return yield n,this.pos+=n.length,n.length;else if(t)yield"";return 0}*pushIndicators(){let e=0;e:while(!0){switch(this.charAt(0)){case"!":e+=yield*this.pushTag(),e+=yield*this.pushSpaces(!0);continue e;case"&":e+=yield*this.pushUntil(fk),e+=yield*this.pushSpaces(!0);continue e;case"-":case"?":case":":{let t=this.flowLevel>0,n=this.charAt(1);if(ua(n)||t&&dx.has(n)){if(!t)this.indentNext=this.indentValue+1;else if(this.flowKey)this.flowKey=!1;e+=yield*this.pushCount(1),e+=yield*this.pushSpaces(!0);continue e}}}break e}return e}*pushTag(){if(this.charAt(1)==="<"){let e=this.pos+2,t=this.buffer[e];while(!ua(t)&&t!==">")t=this.buffer[++e];return yield*this.pushToIndex(t===">"?e+1:e,!1)}else{let e=this.pos+1,t=this.buffer[e];while(t)if(Pce.has(t))t=this.buffer[++e];else if(t==="%"&&UM.has(this.buffer[e+1])&&UM.has(this.buffer[e+2]))t=this.buffer[e+=3];else break;return yield*this.pushToIndex(e,!1)}}*pushNewline(){let e=this.buffer[this.pos];if(e===` `)return yield*this.pushCount(1);else if(e==="\r"&&this.charAt(1)===` -`)return yield*this.pushCount(2);else return 0}*pushSpaces(e){let t=this.pos-1,n;do n=this.buffer[++t];while(n===" "||e&&n==="\t");let r=t-this.pos;if(r>0)yield this.buffer.substr(this.pos,r),this.pos=t;return r}*pushUntil(e){let t=this.pos,n=this.buffer[t];while(!e(n))n=this.buffer[++t];return yield*this.pushToIndex(t,!1)}}var UM,Oce,dx,Pce,fk=(e)=>!e||Pce.has(e);var mk=q(()=>{px();UM=new Set("0123456789ABCDEFabcdef"),Oce=new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"),dx=new Set(",[]{}"),Pce=new Set(` ,[]{} -\r `)});class mx{constructor(){this.lineStarts=[],this.addNewLine=(e)=>this.lineStarts.push(e),this.linePos=(e)=>{let t=0,n=this.lineStarts.length;while(t>1;if(this.lineStarts[i]{};function nu(e,t){for(let n=0;n=0)switch(e[t].type){case"doc-start":case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":case"newline":break e}while(e[++t]?.type==="space");return e.splice(t,e.length)}function hx(e,t){if(t.length<1e5)Array.prototype.push.apply(e,t);else for(let n=0;n0)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){let e=this.peek(1);if(this.type==="doc-end"&&e?.type!=="doc-end"){while(this.stack.length>0)yield*this.pop();this.stack.push({type:"doc-end",offset:this.offset,source:this.source});return}if(!e)return yield*this.stream();switch(e.type){case"document":return yield*this.document(e);case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return yield*this.scalar(e);case"block-scalar":return yield*this.blockScalar(e);case"block-map":return yield*this.blockMap(e);case"block-seq":return yield*this.blockSequence(e);case"flow-collection":return yield*this.flowCollection(e);case"doc-end":return yield*this.documentEnd(e)}yield*this.pop()}peek(e){return this.stack[this.stack.length-e]}*pop(e){let t=e??this.stack.pop();if(!t)yield{type:"error",offset:this.offset,source:"",message:"Tried to pop an empty stack"};else if(this.stack.length===0)yield t;else{let n=this.peek(1);if(t.type==="block-scalar")t.indent="indent"in n?n.indent:0;else if(t.type==="flow-collection"&&n.type==="document")t.indent=0;if(t.type==="flow-collection")VM(t);switch(n.type){case"document":n.value=t;break;case"block-scalar":n.props.push(t);break;case"block-map":{let r=n.items[n.items.length-1];if(r.value){n.items.push({start:[],key:t,sep:[]}),this.onKeyLine=!0;return}else if(r.sep)r.value=t;else{Object.assign(r,{key:t,sep:[]}),this.onKeyLine=!r.explicitKey;return}break}case"block-seq":{let r=n.items[n.items.length-1];if(r.value)n.items.push({start:[],value:t});else r.value=t;break}case"flow-collection":{let r=n.items[n.items.length-1];if(!r||r.value)n.items.push({start:[],key:t,sep:[]});else if(r.sep)r.value=t;else Object.assign(r,{key:t,sep:[]});return}default:yield*this.pop(),yield*this.pop(t)}if((n.type==="document"||n.type==="block-map"||n.type==="block-seq")&&(t.type==="block-map"||t.type==="block-seq")){let r=t.items[t.items.length-1];if(r&&!r.sep&&!r.value&&r.start.length>0&&BM(r.start)===-1&&(t.indent===0||r.start.every((i)=>i.type!=="comment"||i.indent0)yield this.buffer.substr(this.pos,r),this.pos=t;return r}*pushUntil(e){let t=this.pos,n=this.buffer[t];while(!e(n))n=this.buffer[++t];return yield*this.pushToIndex(t,!1)}}var UM,Pce,dx,$ce,fk=(e)=>!e||$ce.has(e);var mk=q(()=>{px();UM=new Set("0123456789ABCDEFabcdef"),Pce=new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"),dx=new Set(",[]{}"),$ce=new Set(` ,[]{} +\r `)});class mx{constructor(){this.lineStarts=[],this.addNewLine=(e)=>this.lineStarts.push(e),this.linePos=(e)=>{let t=0,n=this.lineStarts.length;while(t>1;if(this.lineStarts[i]{};function ru(e,t){for(let n=0;n=0)switch(e[t].type){case"doc-start":case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":case"newline":break e}while(e[++t]?.type==="space");return e.splice(t,e.length)}function hx(e,t){if(t.length<1e5)Array.prototype.push.apply(e,t);else for(let n=0;n0)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){let e=this.peek(1);if(this.type==="doc-end"&&e?.type!=="doc-end"){while(this.stack.length>0)yield*this.pop();this.stack.push({type:"doc-end",offset:this.offset,source:this.source});return}if(!e)return yield*this.stream();switch(e.type){case"document":return yield*this.document(e);case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return yield*this.scalar(e);case"block-scalar":return yield*this.blockScalar(e);case"block-map":return yield*this.blockMap(e);case"block-seq":return yield*this.blockSequence(e);case"flow-collection":return yield*this.flowCollection(e);case"doc-end":return yield*this.documentEnd(e)}yield*this.pop()}peek(e){return this.stack[this.stack.length-e]}*pop(e){let t=e??this.stack.pop();if(!t)yield{type:"error",offset:this.offset,source:"",message:"Tried to pop an empty stack"};else if(this.stack.length===0)yield t;else{let n=this.peek(1);if(t.type==="block-scalar")t.indent="indent"in n?n.indent:0;else if(t.type==="flow-collection"&&n.type==="document")t.indent=0;if(t.type==="flow-collection")VM(t);switch(n.type){case"document":n.value=t;break;case"block-scalar":n.props.push(t);break;case"block-map":{let r=n.items[n.items.length-1];if(r.value){n.items.push({start:[],key:t,sep:[]}),this.onKeyLine=!0;return}else if(r.sep)r.value=t;else{Object.assign(r,{key:t,sep:[]}),this.onKeyLine=!r.explicitKey;return}break}case"block-seq":{let r=n.items[n.items.length-1];if(r.value)n.items.push({start:[],value:t});else r.value=t;break}case"flow-collection":{let r=n.items[n.items.length-1];if(!r||r.value)n.items.push({start:[],key:t,sep:[]});else if(r.sep)r.value=t;else Object.assign(r,{key:t,sep:[]});return}default:yield*this.pop(),yield*this.pop(t)}if((n.type==="document"||n.type==="block-map"||n.type==="block-seq")&&(t.type==="block-map"||t.type==="block-seq")){let r=t.items[t.items.length-1];if(r&&!r.sep&&!r.value&&r.start.length>0&&BM(r.start)===-1&&(t.indent===0||r.start.every((i)=>i.type!=="comment"||i.indent=e.indent){let n=!this.onKeyLine&&this.indent===e.indent,r=n&&(t.sep||t.explicitKey)&&this.type!=="seq-item-ind",i=[];if(r&&t.sep&&!t.value){let s=[];for(let o=0;oe.indent)s.length=0;break;default:s.length=0}}if(s.length>=2)i=t.sep.splice(s[1])}switch(this.type){case"anchor":case"tag":if(r||t.value)i.push(this.sourceToken),e.items.push({start:i}),this.onKeyLine=!0;else if(t.sep)t.sep.push(this.sourceToken);else t.start.push(this.sourceToken);return;case"explicit-key-ind":if(!t.sep&&!t.explicitKey)t.start.push(this.sourceToken),t.explicitKey=!0;else if(r||t.value)i.push(this.sourceToken),e.items.push({start:i,explicitKey:!0});else this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]});this.onKeyLine=!0;return;case"map-value-ind":if(t.explicitKey)if(!t.sep)if(nu(t.start,"newline"))Object.assign(t,{key:null,sep:[this.sourceToken]});else{let s=Uf(t.start);this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:s,key:null,sep:[this.sourceToken]}]})}else if(t.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(nu(t.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:i,key:null,sep:[this.sourceToken]}]});else if(KM(t.key)&&!nu(t.sep,"newline")){let s=Uf(t.start),{key:o,sep:a}=t;a.push(this.sourceToken),delete t.key,delete t.sep,this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:s,key:o,sep:a}]})}else if(i.length>0)t.sep=t.sep.concat(i,this.sourceToken);else t.sep.push(this.sourceToken);else if(!t.sep)Object.assign(t,{key:null,sep:[this.sourceToken]});else if(t.value||r)e.items.push({start:i,key:null,sep:[this.sourceToken]});else if(nu(t.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]});else t.sep.push(this.sourceToken);this.onKeyLine=!0;return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let s=this.flowScalar(this.type);if(r||t.value)e.items.push({start:i,key:s,sep:[]}),this.onKeyLine=!0;else if(t.sep)this.stack.push(s);else Object.assign(t,{key:s,sep:[]}),this.onKeyLine=!0;return}default:{let s=this.startBlockValue(e);if(s){if(s.type==="block-seq"){if(!t.explicitKey&&t.sep&&!nu(t.sep,"newline")){yield*this.pop({type:"error",offset:this.offset,message:"Unexpected block-seq-ind on same line with key",source:this.source});return}}else if(n)e.items.push({start:i});this.stack.push(s);return}}}}yield*this.pop(),yield*this.step()}*blockSequence(e){let t=e.items[e.items.length-1];switch(this.type){case"newline":if(t.value){let n="end"in t.value?t.value.end:void 0;if((Array.isArray(n)?n[n.length-1]:void 0)?.type==="comment")n?.push(this.sourceToken);else e.items.push({start:[this.sourceToken]})}else t.start.push(this.sourceToken);return;case"space":case"comment":if(t.value)e.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(t.start,e.indent)){let r=e.items[e.items.length-2]?.value?.end;if(Array.isArray(r)){hx(r,t.start),r.push(this.sourceToken),e.items.pop();return}}t.start.push(this.sourceToken)}return;case"anchor":case"tag":if(t.value||this.indent<=e.indent)break;t.start.push(this.sourceToken);return;case"seq-item-ind":if(this.indent!==e.indent)break;if(t.value||nu(t.start,"seq-item-ind"))e.items.push({start:[this.sourceToken]});else t.start.push(this.sourceToken);return}if(this.indent>e.indent){let n=this.startBlockValue(e);if(n){this.stack.push(n);return}}yield*this.pop(),yield*this.step()}*flowCollection(e){let t=e.items[e.items.length-1];if(this.type==="flow-error-end"){let n;do yield*this.pop(),n=this.peek(1);while(n?.type==="flow-collection")}else if(e.end.length===0){switch(this.type){case"comma":case"explicit-key-ind":if(!t||t.sep)e.items.push({start:[this.sourceToken]});else t.start.push(this.sourceToken);return;case"map-value-ind":if(!t||t.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(t.sep)t.sep.push(this.sourceToken);else Object.assign(t,{key:null,sep:[this.sourceToken]});return;case"space":case"comment":case"newline":case"anchor":case"tag":if(!t||t.value)e.items.push({start:[this.sourceToken]});else if(t.sep)t.sep.push(this.sourceToken);else t.start.push(this.sourceToken);return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let r=this.flowScalar(this.type);if(!t||t.value)e.items.push({start:[],key:r,sep:[]});else if(t.sep)this.stack.push(r);else Object.assign(t,{key:r,sep:[]});return}case"flow-map-end":case"flow-seq-end":e.end.push(this.sourceToken);return}let n=this.startBlockValue(e);if(n)this.stack.push(n);else yield*this.pop(),yield*this.step()}else{let n=this.peek(2);if(n.type==="block-map"&&(this.type==="map-value-ind"&&n.indent===e.indent||this.type==="newline"&&!n.items[n.items.length-1].sep))yield*this.pop(),yield*this.step();else if(this.type==="map-value-ind"&&n.type!=="flow-collection"){let r=yx(n),i=Uf(r);VM(e);let s=e.end.splice(1,e.end.length);s.push(this.sourceToken);let o={type:"block-map",offset:e.offset,indent:e.indent,items:[{start:i,key:e,sep:s}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=o}else yield*this.lineEnd(e)}}flowScalar(e){if(this.onNewLine){let t=this.source.indexOf(` +`,t)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap(e){let t=e.items[e.items.length-1];switch(this.type){case"newline":if(this.onKeyLine=!1,t.value){let n="end"in t.value?t.value.end:void 0;if((Array.isArray(n)?n[n.length-1]:void 0)?.type==="comment")n?.push(this.sourceToken);else e.items.push({start:[this.sourceToken]})}else if(t.sep)t.sep.push(this.sourceToken);else t.start.push(this.sourceToken);return;case"space":case"comment":if(t.value)e.items.push({start:[this.sourceToken]});else if(t.sep)t.sep.push(this.sourceToken);else{if(this.atIndentedComment(t.start,e.indent)){let r=e.items[e.items.length-2]?.value?.end;if(Array.isArray(r)){hx(r,t.start),r.push(this.sourceToken),e.items.pop();return}}t.start.push(this.sourceToken)}return}if(this.indent>=e.indent){let n=!this.onKeyLine&&this.indent===e.indent,r=n&&(t.sep||t.explicitKey)&&this.type!=="seq-item-ind",i=[];if(r&&t.sep&&!t.value){let s=[];for(let o=0;oe.indent)s.length=0;break;default:s.length=0}}if(s.length>=2)i=t.sep.splice(s[1])}switch(this.type){case"anchor":case"tag":if(r||t.value)i.push(this.sourceToken),e.items.push({start:i}),this.onKeyLine=!0;else if(t.sep)t.sep.push(this.sourceToken);else t.start.push(this.sourceToken);return;case"explicit-key-ind":if(!t.sep&&!t.explicitKey)t.start.push(this.sourceToken),t.explicitKey=!0;else if(r||t.value)i.push(this.sourceToken),e.items.push({start:i,explicitKey:!0});else this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]});this.onKeyLine=!0;return;case"map-value-ind":if(t.explicitKey)if(!t.sep)if(ru(t.start,"newline"))Object.assign(t,{key:null,sep:[this.sourceToken]});else{let s=Vf(t.start);this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:s,key:null,sep:[this.sourceToken]}]})}else if(t.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(ru(t.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:i,key:null,sep:[this.sourceToken]}]});else if(KM(t.key)&&!ru(t.sep,"newline")){let s=Vf(t.start),{key:o,sep:a}=t;a.push(this.sourceToken),delete t.key,delete t.sep,this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:s,key:o,sep:a}]})}else if(i.length>0)t.sep=t.sep.concat(i,this.sourceToken);else t.sep.push(this.sourceToken);else if(!t.sep)Object.assign(t,{key:null,sep:[this.sourceToken]});else if(t.value||r)e.items.push({start:i,key:null,sep:[this.sourceToken]});else if(ru(t.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]});else t.sep.push(this.sourceToken);this.onKeyLine=!0;return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let s=this.flowScalar(this.type);if(r||t.value)e.items.push({start:i,key:s,sep:[]}),this.onKeyLine=!0;else if(t.sep)this.stack.push(s);else Object.assign(t,{key:s,sep:[]}),this.onKeyLine=!0;return}default:{let s=this.startBlockValue(e);if(s){if(s.type==="block-seq"){if(!t.explicitKey&&t.sep&&!ru(t.sep,"newline")){yield*this.pop({type:"error",offset:this.offset,message:"Unexpected block-seq-ind on same line with key",source:this.source});return}}else if(n)e.items.push({start:i});this.stack.push(s);return}}}}yield*this.pop(),yield*this.step()}*blockSequence(e){let t=e.items[e.items.length-1];switch(this.type){case"newline":if(t.value){let n="end"in t.value?t.value.end:void 0;if((Array.isArray(n)?n[n.length-1]:void 0)?.type==="comment")n?.push(this.sourceToken);else e.items.push({start:[this.sourceToken]})}else t.start.push(this.sourceToken);return;case"space":case"comment":if(t.value)e.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(t.start,e.indent)){let r=e.items[e.items.length-2]?.value?.end;if(Array.isArray(r)){hx(r,t.start),r.push(this.sourceToken),e.items.pop();return}}t.start.push(this.sourceToken)}return;case"anchor":case"tag":if(t.value||this.indent<=e.indent)break;t.start.push(this.sourceToken);return;case"seq-item-ind":if(this.indent!==e.indent)break;if(t.value||ru(t.start,"seq-item-ind"))e.items.push({start:[this.sourceToken]});else t.start.push(this.sourceToken);return}if(this.indent>e.indent){let n=this.startBlockValue(e);if(n){this.stack.push(n);return}}yield*this.pop(),yield*this.step()}*flowCollection(e){let t=e.items[e.items.length-1];if(this.type==="flow-error-end"){let n;do yield*this.pop(),n=this.peek(1);while(n?.type==="flow-collection")}else if(e.end.length===0){switch(this.type){case"comma":case"explicit-key-ind":if(!t||t.sep)e.items.push({start:[this.sourceToken]});else t.start.push(this.sourceToken);return;case"map-value-ind":if(!t||t.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(t.sep)t.sep.push(this.sourceToken);else Object.assign(t,{key:null,sep:[this.sourceToken]});return;case"space":case"comment":case"newline":case"anchor":case"tag":if(!t||t.value)e.items.push({start:[this.sourceToken]});else if(t.sep)t.sep.push(this.sourceToken);else t.start.push(this.sourceToken);return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let r=this.flowScalar(this.type);if(!t||t.value)e.items.push({start:[],key:r,sep:[]});else if(t.sep)this.stack.push(r);else Object.assign(t,{key:r,sep:[]});return}case"flow-map-end":case"flow-seq-end":e.end.push(this.sourceToken);return}let n=this.startBlockValue(e);if(n)this.stack.push(n);else yield*this.pop(),yield*this.step()}else{let n=this.peek(2);if(n.type==="block-map"&&(this.type==="map-value-ind"&&n.indent===e.indent||this.type==="newline"&&!n.items[n.items.length-1].sep))yield*this.pop(),yield*this.step();else if(this.type==="map-value-ind"&&n.type!=="flow-collection"){let r=yx(n),i=Vf(r);VM(e);let s=e.end.splice(1,e.end.length);s.push(this.sourceToken);let o={type:"block-map",offset:e.offset,indent:e.indent,items:[{start:i,key:e,sep:s}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=o}else yield*this.lineEnd(e)}}flowScalar(e){if(this.onNewLine){let t=this.source.indexOf(` `)+1;while(t!==0)this.onNewLine(this.offset+t),t=this.source.indexOf(` -`,t)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;let t=yx(e),n=Uf(t);return n.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:n,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;let t=yx(e),n=Uf(t);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:n,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,t){if(this.type!=="comment")return!1;if(this.indent<=t)return!1;return e.every((n)=>n.type==="newline"||n.type==="space")}*documentEnd(e){if(this.type!=="doc-mode"){if(e.end)e.end.push(this.sourceToken);else e.end=[this.sourceToken];if(this.type==="newline")yield*this.pop()}}*lineEnd(e){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;case"space":case"comment":default:if(e.end)e.end.push(this.sourceToken);else e.end=[this.sourceToken];if(this.type==="newline")yield*this.pop()}}}var hk=q(()=>{px();mk()});function $ce(e){let t=e.prettyErrors!==!1;return{lineCounter:e.lineCounter||t&&new mx||null,prettyErrors:t}}function go(e,t={}){let{lineCounter:n,prettyErrors:r}=$ce(t),i=new gx(n?.addNewLine),s=new cx(t),o=null;for(let a of s.compose(i.parse(e),!0,e.length))if(!o)o=a;else if(o.options.logLevel!=="silent"){o.errors.push(new Ja(a.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}if(r&&n)o.errors.forEach(QE(e,n)),o.warnings.forEach(QE(e,n));return o}function Ul(e,t,n){let r=null;if(typeof t==="function"||Array.isArray(t))r=t;else if(n===void 0&&t)n=t;if(typeof n==="string")n=n.length;if(typeof n==="number"){let i=Math.round(n);n=i<1?void 0:i>8?{indent:8}:{indent:i}}if(e===void 0){let{keepUndefined:i}=n??t??{};if(!i)return}if(fo(e)&&!r)return e.toString(n);return new ql(e,r,n).toString(n)}var JM=q(()=>{lk();$h();Ih();C_();rn();yk();hk()});var gk=q(()=>{lk();$h();WE();Ih();bh();rn();Cl();_r();Ml();eu();px();mk();yk();hk();JM();gh()});var bo=q(()=>{gk();gk()});var Ch=z(function(zM){Object.defineProperty(zM,"__esModule",{value:!0});zM.regexpCode=zM.getEsmExportName=zM.getProperty=zM.safeStringify=zM.stringify=zM.strConcat=zM.addCodeArg=zM.str=zM._=zM.nil=zM._Code=zM.Name=zM.IDENTIFIER=zM._CodeOrName=void 0;class bx{}zM._CodeOrName=bx;zM.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class Bf extends bx{constructor(e){super();if(!zM.IDENTIFIER.test(e))throw Error("CodeGen: name must be a valid identifier");this.str=e}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}zM.Name=Bf;class pa extends bx{constructor(e){super();this._items=typeof e==="string"?[e]:e}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let e=this._items[0];return e===""||e==='""'}get str(){var e;return(e=this._str)!==null&&e!==void 0?e:this._str=this._items.reduce((t,n)=>`${t}${n}`,"")}get names(){var e;return(e=this._names)!==null&&e!==void 0?e:this._names=this._items.reduce((t,n)=>{if(n instanceof Bf)t[n.str]=(t[n.str]||0)+1;return t},{})}}zM._Code=pa;zM.nil=new pa("");function GM(e,...t){let n=[e[0]],r=0;while(r{if(n.scopePath===void 0)throw Error(`CodeGen: name "${n}" has no value`);return cs._`${e}${n.scopePath}`})}scopeCode(e=this._values,t,n){return this._reduceValues(e,(r)=>{if(r.value===void 0)throw Error(`CodeGen: name "${r}" has no value`);return r.value.code},t,n)}_reduceValues(e,t,n={},r){let i=cs.nil;for(let s in e){let o=e[s];if(!o)continue;let a=n[s]=n[s]||new Map;o.forEach((l)=>{if(a.has(l))return;a.set(l,_x.Started);let c=t(l);if(c){let u=this.opts.es5?XM.varKinds.var:XM.varKinds.const;i=cs._`${i}${u} ${l} = ${c};${this.opts._n}`}else if(c=r===null||r===void 0?void 0:r(l))i=cs._`${i}${c}${this.opts._n}`;else throw new QM(l);a.set(l,_x.Completed)})}return i}}XM.ValueScope=YM});var Et=z(function(us){Object.defineProperty(us,"__esModule",{value:!0});us.or=us.and=us.not=us.CodeGen=us.operators=us.varKinds=us.ValueScopeName=us.ValueScope=us.Scope=us.Name=us.regexpCode=us.stringify=us.getProperty=us.nil=us.strConcat=us.str=us._=void 0;var Xt=Ch(),da=Dk(),ru=Ch();Object.defineProperty(us,"_",{enumerable:!0,get:function(){return ru._}});Object.defineProperty(us,"str",{enumerable:!0,get:function(){return ru.str}});Object.defineProperty(us,"strConcat",{enumerable:!0,get:function(){return ru.strConcat}});Object.defineProperty(us,"nil",{enumerable:!0,get:function(){return ru.nil}});Object.defineProperty(us,"getProperty",{enumerable:!0,get:function(){return ru.getProperty}});Object.defineProperty(us,"stringify",{enumerable:!0,get:function(){return ru.stringify}});Object.defineProperty(us,"regexpCode",{enumerable:!0,get:function(){return ru.regexpCode}});Object.defineProperty(us,"Name",{enumerable:!0,get:function(){return ru.Name}});var Ex=Dk();Object.defineProperty(us,"Scope",{enumerable:!0,get:function(){return Ex.Scope}});Object.defineProperty(us,"ValueScope",{enumerable:!0,get:function(){return Ex.ValueScope}});Object.defineProperty(us,"ValueScopeName",{enumerable:!0,get:function(){return Ex.ValueScopeName}});Object.defineProperty(us,"varKinds",{enumerable:!0,get:function(){return Ex.varKinds}});us.operators={GT:new Xt._Code(">"),GTE:new Xt._Code(">="),LT:new Xt._Code("<"),LTE:new Xt._Code("<="),EQ:new Xt._Code("==="),NEQ:new Xt._Code("!=="),NOT:new Xt._Code("!"),OR:new Xt._Code("||"),AND:new Xt._Code("&&"),ADD:new Xt._Code("+")};class iu{optimizeNodes(){return this}optimizeNames(e,t){return this}}class eL extends iu{constructor(e,t,n){super();this.varKind=e,this.name=t,this.rhs=n}render({es5:e,_n:t}){let n=e?da.varKinds.var:this.varKind,r=this.rhs===void 0?"":` = ${this.rhs}`;return`${n} ${this.name}${r};`+t}optimizeNames(e,t){if(!e[this.name.str])return;if(this.rhs)this.rhs=Kf(this.rhs,e,t);return this}get names(){return this.rhs instanceof Xt._CodeOrName?this.rhs.names:{}}}class Ek extends iu{constructor(e,t,n){super();this.lhs=e,this.rhs=t,this.sideEffects=n}render({_n:e}){return`${this.lhs} = ${this.rhs};`+e}optimizeNames(e,t){if(this.lhs instanceof Xt.Name&&!e[this.lhs.str]&&!this.sideEffects)return;return this.rhs=Kf(this.rhs,e,t),this}get names(){let e=this.lhs instanceof Xt.Name?{}:{...this.lhs.names};return Sx(e,this.rhs)}}class tL extends Ek{constructor(e,t,n,r){super(e,n,r);this.op=t}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}}class nL extends iu{constructor(e){super();this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}}class rL extends iu{constructor(e){super();this.label=e,this.names={}}render({_n:e}){return`break${this.label?` ${this.label}`:""};`+e}}class iL extends iu{constructor(e){super();this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}}class sL extends iu{constructor(e){super();this.code=e}render({_n:e}){return`${this.code};`+e}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(e,t){return this.code=Kf(this.code,e,t),this}get names(){return this.code instanceof Xt._CodeOrName?this.code.names:{}}}class kx extends iu{constructor(e=[]){super();this.nodes=e}render(e){return this.nodes.reduce((t,n)=>t+n.render(e),"")}optimizeNodes(){let{nodes:e}=this,t=e.length;while(t--){let n=e[t].optimizeNodes();if(Array.isArray(n))e.splice(t,1,...n);else if(n)e[t]=n;else e.splice(t,1)}return e.length>0?this:void 0}optimizeNames(e,t){let{nodes:n}=this,r=n.length;while(r--){let i=n[r];if(i.optimizeNames(e,t))continue;rue(e,i.names),n.splice(r,1)}return n.length>0?this:void 0}get names(){return this.nodes.reduce((e,t)=>Rp(e,t.names),{})}}class su extends kx{render(e){return"{"+e._n+super.render(e)+"}"+e._n}}class oL extends kx{}class Mh extends su{}Mh.kind="else";class Bl extends su{constructor(e,t){super(t);this.condition=e}render(e){let t=`if(${this.condition})`+super.render(e);if(this.else)t+="else "+this.else.render(e);return t}optimizeNodes(){super.optimizeNodes();let e=this.condition;if(e===!0)return this.nodes;let t=this.else;if(t){let n=t.optimizeNodes();t=this.else=Array.isArray(n)?new Mh(n):n}if(t){if(e===!1)return t instanceof Bl?t:t.nodes;if(this.nodes.length)return this;return new Bl(pL(e),t instanceof Bl?[t]:t.nodes)}if(e===!1||!this.nodes.length)return;return this}optimizeNames(e,t){var n;if(this.else=(n=this.else)===null||n===void 0?void 0:n.optimizeNames(e,t),!(super.optimizeNames(e,t)||this.else))return;return this.condition=Kf(this.condition,e,t),this}get names(){let e=super.names;if(Sx(e,this.condition),this.else)Rp(e,this.else.names);return e}}Bl.kind="if";class Vf extends su{}Vf.kind="for";class aL extends Vf{constructor(e){super();this.iteration=e}render(e){return`for(${this.iteration})`+super.render(e)}optimizeNames(e,t){if(!super.optimizeNames(e,t))return;return this.iteration=Kf(this.iteration,e,t),this}get names(){return Rp(super.names,this.iteration.names)}}class lL extends Vf{constructor(e,t,n,r){super();this.varKind=e,this.name=t,this.from=n,this.to=r}render(e){let t=e.es5?da.varKinds.var:this.varKind,{name:n,from:r,to:i}=this;return`for(${t} ${n}=${r}; ${n}<${i}; ${n}++)`+super.render(e)}get names(){let e=Sx(super.names,this.from);return Sx(e,this.to)}}class Tk extends Vf{constructor(e,t,n,r){super();this.loop=e,this.varKind=t,this.name=n,this.iterable=r}render(e){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(e)}optimizeNames(e,t){if(!super.optimizeNames(e,t))return;return this.iterable=Kf(this.iterable,e,t),this}get names(){return Rp(super.names,this.iterable.names)}}class xx extends su{constructor(e,t,n){super();this.name=e,this.args=t,this.async=n}render(e){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(e)}}xx.kind="func";class wx extends kx{render(e){return"return "+super.render(e)}}wx.kind="return";class cL extends su{render(e){let t="try"+super.render(e);if(this.catch)t+=this.catch.render(e);if(this.finally)t+=this.finally.render(e);return t}optimizeNodes(){var e,t;return super.optimizeNodes(),(e=this.catch)===null||e===void 0||e.optimizeNodes(),(t=this.finally)===null||t===void 0||t.optimizeNodes(),this}optimizeNames(e,t){var n,r;return super.optimizeNames(e,t),(n=this.catch)===null||n===void 0||n.optimizeNames(e,t),(r=this.finally)===null||r===void 0||r.optimizeNames(e,t),this}get names(){let e=super.names;if(this.catch)Rp(e,this.catch.names);if(this.finally)Rp(e,this.finally.names);return e}}class Dx extends su{constructor(e){super();this.error=e}render(e){return`catch(${this.error})`+super.render(e)}}Dx.kind="catch";class Tx extends su{render(e){return"finally"+super.render(e)}}Tx.kind="finally";class uL{constructor(e,t={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...t,_n:t.lines?` -`:""},this._extScope=e,this._scope=new da.Scope({parent:e}),this._nodes=[new oL]}toString(){return this._root.render(this.opts)}name(e){return this._scope.name(e)}scopeName(e){return this._extScope.name(e)}scopeValue(e,t){let n=this._extScope.value(e,t);return(this._values[n.prefix]||(this._values[n.prefix]=new Set)).add(n),n}getScopeValue(e,t){return this._extScope.getValue(e,t)}scopeRefs(e){return this._extScope.scopeRefs(e,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(e,t,n,r){let i=this._scope.toName(t);if(n!==void 0&&r)this._constants[i.str]=n;return this._leafNode(new eL(e,i,n)),i}const(e,t,n){return this._def(da.varKinds.const,e,t,n)}let(e,t,n){return this._def(da.varKinds.let,e,t,n)}var(e,t,n){return this._def(da.varKinds.var,e,t,n)}assign(e,t,n){return this._leafNode(new Ek(e,t,n))}add(e,t){return this._leafNode(new tL(e,us.operators.ADD,t))}code(e){if(typeof e=="function")e();else if(e!==Xt.nil)this._leafNode(new sL(e));return this}object(...e){let t=["{"];for(let[n,r]of e){if(t.length>1)t.push(",");if(t.push(n),n!==r||this.opts.es5)t.push(":"),Xt.addCodeArg(t,r)}return t.push("}"),new Xt._Code(t)}if(e,t,n){if(this._blockNode(new Bl(e)),t&&n)this.code(t).else().code(n).endIf();else if(t)this.code(t).endIf();else if(n)throw Error('CodeGen: "else" body without "then" body');return this}elseIf(e){return this._elseNode(new Bl(e))}else(){return this._elseNode(new Mh)}endIf(){return this._endBlockNode(Bl,Mh)}_for(e,t){if(this._blockNode(e),t)this.code(t).endFor();return this}for(e,t){return this._for(new aL(e),t)}forRange(e,t,n,r,i=this.opts.es5?da.varKinds.var:da.varKinds.let){let s=this._scope.toName(e);return this._for(new lL(i,s,t,n),()=>r(s))}forOf(e,t,n,r=da.varKinds.const){let i=this._scope.toName(e);if(this.opts.es5){let s=t instanceof Xt.Name?t:this.var("_arr",t);return this.forRange("_i",0,Xt._`${s}.length`,(o)=>{this.var(i,Xt._`${s}[${o}]`),n(i)})}return this._for(new Tk("of",r,i,t),()=>n(i))}forIn(e,t,n,r=this.opts.es5?da.varKinds.var:da.varKinds.const){if(this.opts.ownProperties)return this.forOf(e,Xt._`Object.keys(${t})`,n);let i=this._scope.toName(e);return this._for(new Tk("in",r,i,t),()=>n(i))}endFor(){return this._endBlockNode(Vf)}label(e){return this._leafNode(new nL(e))}break(e){return this._leafNode(new rL(e))}return(e){let t=new wx;if(this._blockNode(t),this.code(e),t.nodes.length!==1)throw Error('CodeGen: "return" should have one node');return this._endBlockNode(wx)}try(e,t,n){if(!t&&!n)throw Error('CodeGen: "try" without "catch" and "finally"');let r=new cL;if(this._blockNode(r),this.code(e),t){let i=this.name("e");this._currNode=r.catch=new Dx(i),t(i)}if(n)this._currNode=r.finally=new Tx,this.code(n);return this._endBlockNode(Dx,Tx)}throw(e){return this._leafNode(new iL(e))}block(e,t){if(this._blockStarts.push(this._nodes.length),e)this.code(e).endBlock(t);return this}endBlock(e){let t=this._blockStarts.pop();if(t===void 0)throw Error("CodeGen: not in self-balancing block");let n=this._nodes.length-t;if(n<0||e!==void 0&&n!==e)throw Error(`CodeGen: wrong number of nodes: ${n} vs ${e} expected`);return this._nodes.length=t,this}func(e,t=Xt.nil,n,r){if(this._blockNode(new xx(e,t,n)),r)this.code(r).endFunc();return this}endFunc(){return this._endBlockNode(xx)}optimize(e=1){while(e-- >0)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(e){return this._currNode.nodes.push(e),this}_blockNode(e){this._currNode.nodes.push(e),this._nodes.push(e)}_endBlockNode(e,t){let n=this._currNode;if(n instanceof e||t&&n instanceof t)return this._nodes.pop(),this;throw Error(`CodeGen: not in block "${t?`${e.kind}/${t.kind}`:e.kind}"`)}_elseNode(e){let t=this._currNode;if(!(t instanceof Bl))throw Error('CodeGen: "else" without "if"');return this._currNode=t.else=e,this}get _root(){return this._nodes[0]}get _currNode(){let e=this._nodes;return e[e.length-1]}set _currNode(e){let t=this._nodes;t[t.length-1]=e}}us.CodeGen=uL;function Rp(e,t){for(let n in t)e[n]=(e[n]||0)+(t[n]||0);return e}function Sx(e,t){return t instanceof Xt._CodeOrName?Rp(e,t.names):e}function Kf(e,t,n){if(e instanceof Xt.Name)return r(e);if(!i(e))return e;return new Xt._Code(e._items.reduce((s,o)=>{if(o instanceof Xt.Name)o=r(o);if(o instanceof Xt._Code)s.push(...o._items);else s.push(o);return s},[]));function r(s){let o=n[s.str];if(o===void 0||t[s.str]!==1)return s;return delete t[s.str],o}function i(s){return s instanceof Xt._Code&&s._items.some((o)=>o instanceof Xt.Name&&t[o.str]===1&&n[o.str]!==void 0)}}function rue(e,t){for(let n in t)e[n]=(e[n]||0)-(t[n]||0)}function pL(e){return typeof e=="boolean"||typeof e=="number"||e===null?!e:Xt._`!${Sk(e)}`}us.not=pL;var iue=dL(us.operators.AND);function sue(...e){return e.reduce(iue)}us.and=sue;var oue=dL(us.operators.OR);function aue(...e){return e.reduce(oue)}us.or=aue;function dL(e){return(t,n)=>t===Xt.nil?n:n===Xt.nil?t:Xt._`${Sk(t)} ${e} ${Sk(n)}`}function Sk(e){return e instanceof Xt.Name?e:Xt._`(${e})`}});var Kt=z(function(xL){Object.defineProperty(xL,"__esModule",{value:!0});xL.checkStrictMode=xL.getErrorPath=xL.Type=xL.useFunc=xL.setEvaluated=xL.evaluatedPropsToName=xL.mergeEvaluated=xL.eachItem=xL.unescapeJsonPointer=xL.escapeJsonPointer=xL.escapeFragment=xL.unescapeFragment=xL.schemaRefOrVal=xL.schemaHasRulesButRef=xL.schemaHasRules=xL.checkUnknownRules=xL.alwaysValidSchema=xL.toHash=void 0;var Fn=Et(),pue=Ch();function due(e){let t={};for(let n of e)t[n]=!0;return t}xL.toHash=due;function fue(e,t){if(typeof t=="boolean")return t;if(Object.keys(t).length===0)return!0;return hL(e,t),!gL(t,e.self.RULES.all)}xL.alwaysValidSchema=fue;function hL(e,t=e.schema){let{opts:n,self:r}=e;if(!n.strictSchema)return;if(typeof t==="boolean")return;let i=r.RULES.keywords;for(let s in t)if(!i[s])_L(e,`unknown keyword: "${s}"`)}xL.checkUnknownRules=hL;function gL(e,t){if(typeof e=="boolean")return!e;for(let n in e)if(t[n])return!0;return!1}xL.schemaHasRules=gL;function mue(e,t){if(typeof e=="boolean")return!e;for(let n in e)if(n!=="$ref"&&t.all[n])return!0;return!1}xL.schemaHasRulesButRef=mue;function yue({topSchemaRef:e,schemaPath:t},n,r,i){if(!i){if(typeof n=="number"||typeof n=="boolean")return n;if(typeof n=="string")return Fn._`${n}`}return Fn._`${e}${t}${Fn.getProperty(r)}`}xL.schemaRefOrVal=yue;function hue(e){return bL(decodeURIComponent(e))}xL.unescapeFragment=hue;function gue(e){return encodeURIComponent(Nk(e))}xL.escapeFragment=gue;function Nk(e){if(typeof e=="number")return`${e}`;return e.replace(/~/g,"~0").replace(/\//g,"~1")}xL.escapeJsonPointer=Nk;function bL(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}xL.unescapeJsonPointer=bL;function bue(e,t){if(Array.isArray(e))for(let n of e)t(n);else t(e)}xL.eachItem=bue;function mL({mergeNames:e,mergeToName:t,mergeValues:n,resultToName:r}){return(i,s,o,a)=>{let l=o===void 0?s:o instanceof Fn.Name?(s instanceof Fn.Name?e(i,s,o):t(i,s,o),o):s instanceof Fn.Name?(t(i,o,s),s):n(s,o);return a===Fn.Name&&!(l instanceof Fn.Name)?r(i,l):l}}xL.mergeEvaluated={props:mL({mergeNames:(e,t,n)=>e.if(Fn._`${n} !== true && ${t} !== undefined`,()=>{e.if(Fn._`${t} === true`,()=>e.assign(n,!0),()=>e.assign(n,Fn._`${n} || {}`).code(Fn._`Object.assign(${n}, ${t})`))}),mergeToName:(e,t,n)=>e.if(Fn._`${n} !== true`,()=>{if(t===!0)e.assign(n,!0);else e.assign(n,Fn._`${n} || {}`),Ok(e,n,t)}),mergeValues:(e,t)=>e===!0?!0:{...e,...t},resultToName:vL}),items:mL({mergeNames:(e,t,n)=>e.if(Fn._`${n} !== true && ${t} !== undefined`,()=>e.assign(n,Fn._`${t} === true ? true : ${n} > ${t} ? ${n} : ${t}`)),mergeToName:(e,t,n)=>e.if(Fn._`${n} !== true`,()=>e.assign(n,t===!0?!0:Fn._`${n} > ${t} ? ${n} : ${t}`)),mergeValues:(e,t)=>e===!0?!0:Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})};function vL(e,t){if(t===!0)return e.var("props",!0);let n=e.var("props",Fn._`{}`);if(t!==void 0)Ok(e,n,t);return n}xL.evaluatedPropsToName=vL;function Ok(e,t,n){Object.keys(n).forEach((r)=>e.assign(Fn._`${t}${Fn.getProperty(r)}`,!0))}xL.setEvaluated=Ok;var yL={};function vue(e,t){return e.scopeValue("func",{ref:t,code:yL[t.code]||(yL[t.code]=new pue._Code(t.code))})}xL.useFunc=vue;var kk;(function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"})(kk||(xL.Type=kk={}));function _ue(e,t,n){if(e instanceof Fn.Name){let r=t===kk.Num;return n?r?Fn._`"[" + ${e} + "]"`:Fn._`"['" + ${e} + "']"`:r?Fn._`"/" + ${e}`:Fn._`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return n?Fn.getProperty(e).toString():"/"+Nk(e)}xL.getErrorPath=_ue;function _L(e,t,n=e.opts.strictSchema){if(!n)return;if(t=`strict mode: ${t}`,n===!0)throw Error(t);e.self.logger.warn(t)}xL.checkStrictMode=_L});var vo=z(function(DL){Object.defineProperty(DL,"__esModule",{value:!0});var wi=Et(),Mue={data:new wi.Name("data"),valCxt:new wi.Name("valCxt"),instancePath:new wi.Name("instancePath"),parentData:new wi.Name("parentData"),parentDataProperty:new wi.Name("parentDataProperty"),rootData:new wi.Name("rootData"),dynamicAnchors:new wi.Name("dynamicAnchors"),vErrors:new wi.Name("vErrors"),errors:new wi.Name("errors"),this:new wi.Name("this"),self:new wi.Name("self"),scope:new wi.Name("scope"),json:new wi.Name("json"),jsonPos:new wi.Name("jsonPos"),jsonLen:new wi.Name("jsonLen"),jsonPart:new wi.Name("jsonPart")};DL.default=Mue});var Lh=z(function(kL){Object.defineProperty(kL,"__esModule",{value:!0});kL.extendErrors=kL.resetErrorsCount=kL.reportExtraError=kL.reportError=kL.keyword$DataError=kL.keywordError=void 0;var sn=Et(),Ox=Kt(),Ji=vo();kL.keywordError={message:({keyword:e})=>sn.str`must pass "${e}" keyword validation`};kL.keyword$DataError={message:({keyword:e,schemaType:t})=>t?sn.str`"${e}" keyword must be ${t} ($data)`:sn.str`"${e}" keyword is invalid ($data)`};function que(e,t=kL.keywordError,n,r){let{it:i}=e,{gen:s,compositeRule:o,allErrors:a}=i,l=EL(e,t,n);if(r!==null&&r!==void 0?r:o||a)TL(s,l);else SL(i,sn._`[${l}]`)}kL.reportError=que;function Uue(e,t=kL.keywordError,n){let{it:r}=e,{gen:i,compositeRule:s,allErrors:o}=r,a=EL(e,t,n);if(TL(i,a),!(s||o))SL(r,Ji.default.vErrors)}kL.reportExtraError=Uue;function Bue(e,t){e.assign(Ji.default.errors,t),e.if(sn._`${Ji.default.vErrors} !== null`,()=>e.if(t,()=>e.assign(sn._`${Ji.default.vErrors}.length`,t),()=>e.assign(Ji.default.vErrors,null)))}kL.resetErrorsCount=Bue;function Vue({gen:e,keyword:t,schemaValue:n,data:r,errsCount:i,it:s}){if(i===void 0)throw Error("ajv implementation error");let o=e.name("err");e.forRange("i",i,Ji.default.errors,(a)=>{if(e.const(o,sn._`${Ji.default.vErrors}[${a}]`),e.if(sn._`${o}.instancePath === undefined`,()=>e.assign(sn._`${o}.instancePath`,sn.strConcat(Ji.default.instancePath,s.errorPath))),e.assign(sn._`${o}.schemaPath`,sn.str`${s.errSchemaPath}/${t}`),s.opts.verbose)e.assign(sn._`${o}.schema`,n),e.assign(sn._`${o}.data`,r)})}kL.extendErrors=Vue;function TL(e,t){let n=e.const("err",t);e.if(sn._`${Ji.default.vErrors} === null`,()=>e.assign(Ji.default.vErrors,sn._`[${n}]`),sn._`${Ji.default.vErrors}.push(${n})`),e.code(sn._`${Ji.default.errors}++`)}function SL(e,t){let{gen:n,validateName:r,schemaEnv:i}=e;if(i.$async)n.throw(sn._`new ${e.ValidationError}(${t})`);else n.assign(sn._`${r}.errors`,t),n.return(!1)}var jp={keyword:new sn.Name("keyword"),schemaPath:new sn.Name("schemaPath"),params:new sn.Name("params"),propertyName:new sn.Name("propertyName"),message:new sn.Name("message"),schema:new sn.Name("schema"),parentSchema:new sn.Name("parentSchema")};function EL(e,t,n){let{createErrors:r}=e.it;if(r===!1)return sn._`{}`;return Kue(e,t,n)}function Kue(e,t,n={}){let{gen:r,it:i}=e,s=[Jue(i,n),Gue(e,n)];return Hue(e,t,s),r.object(...s)}function Jue({errorPath:e},{instancePath:t}){let n=t?sn.str`${e}${Ox.getErrorPath(t,Ox.Type.Str)}`:e;return[Ji.default.instancePath,sn.strConcat(Ji.default.instancePath,n)]}function Gue({keyword:e,it:{errSchemaPath:t}},{schemaPath:n,parentSchema:r}){let i=r?t:sn.str`${t}/${e}`;if(n)i=sn.str`${i}${Ox.getErrorPath(n,Ox.Type.Str)}`;return[jp.schemaPath,i]}function Hue(e,{params:t,message:n},r){let{keyword:i,data:s,schemaValue:o,it:a}=e,{opts:l,propertyName:c,topSchemaRef:u,schemaPath:p}=a;if(r.push([jp.keyword,i],[jp.params,typeof t=="function"?t(e):t||sn._`{}`]),l.messages)r.push([jp.message,typeof n=="function"?n(e):n]);if(l.verbose)r.push([jp.schema,o],[jp.parentSchema,sn._`${u}${p}`],[Ji.default.data,s]);if(c)r.push([jp.propertyName,c])}});var IL=z(function(PL){Object.defineProperty(PL,"__esModule",{value:!0});PL.boolOrEmptySchema=PL.topBoolOrEmptySchema=void 0;var Xue=Lh(),Zue=Et(),epe=vo(),tpe={message:"boolean schema is false"};function npe(e){let{gen:t,schema:n,validateName:r}=e;if(n===!1)OL(e,!1);else if(typeof n=="object"&&n.$async===!0)t.return(epe.default.data);else t.assign(Zue._`${r}.errors`,null),t.return(!0)}PL.topBoolOrEmptySchema=npe;function rpe(e,t){let{gen:n,schema:r}=e;if(r===!1)n.var(t,!1),OL(e);else n.var(t,!0)}PL.boolOrEmptySchema=rpe;function OL(e,t){let{gen:n,data:r}=e;Xue.reportError({gen:n,keyword:"false schema",data:r,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e},tpe,void 0,t)}});var $k=z(function(AL){Object.defineProperty(AL,"__esModule",{value:!0});AL.getRules=AL.isJSONType=void 0;var spe=["string","number","integer","boolean","null","object","array"],ope=new Set(spe);function ape(e){return typeof e=="string"&&ope.has(e)}AL.isJSONType=ape;function lpe(){let e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...e,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}AL.getRules=lpe});var Ik=z(function(CL){Object.defineProperty(CL,"__esModule",{value:!0});CL.shouldUseRule=CL.shouldUseGroup=CL.schemaHasRulesForType=void 0;function upe({schema:e,self:t},n){let r=t.RULES.types[n];return r&&r!==!0&&jL(e,r)}CL.schemaHasRulesForType=upe;function jL(e,t){return t.rules.some((n)=>FL(e,n))}CL.shouldUseGroup=jL;function FL(e,t){var n;return e[t.keyword]!==void 0||((n=t.definition.implements)===null||n===void 0?void 0:n.some((r)=>e[r]!==void 0))}CL.shouldUseRule=FL});var qh=z(function(BL){Object.defineProperty(BL,"__esModule",{value:!0});BL.reportTypeError=BL.checkDataTypes=BL.checkDataType=BL.coerceAndCheckDataType=BL.getJSONTypes=BL.getSchemaTypes=BL.DataType=void 0;var fpe=$k(),mpe=Ik(),ype=Lh(),Rt=Et(),LL=Kt(),Jf;(function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"})(Jf||(BL.DataType=Jf={}));function hpe(e){let t=qL(e.type);if(t.includes("null")){if(e.nullable===!1)throw Error("type: null contradicts nullable: false")}else{if(!t.length&&e.nullable!==void 0)throw Error('"nullable" cannot be used without "type"');if(e.nullable===!0)t.push("null")}return t}BL.getSchemaTypes=hpe;function qL(e){let t=Array.isArray(e)?e:e?[e]:[];if(t.every(fpe.isJSONType))return t;throw Error("type must be JSONType or JSONType[]: "+t.join(","))}BL.getJSONTypes=qL;function gpe(e,t){let{gen:n,data:r,opts:i}=e,s=bpe(t,i.coerceTypes),o=t.length>0&&!(s.length===0&&t.length===1&&mpe.schemaHasRulesForType(e,t[0]));if(o){let a=Rk(t,r,i.strictNumbers,Jf.Wrong);n.if(a,()=>{if(s.length)vpe(e,t,s);else jk(e)})}return o}BL.coerceAndCheckDataType=gpe;var UL=new Set(["string","number","integer","boolean","null"]);function bpe(e,t){return t?e.filter((n)=>UL.has(n)||t==="array"&&n==="array"):[]}function vpe(e,t,n){let{gen:r,data:i,opts:s}=e,o=r.let("dataType",Rt._`typeof ${i}`),a=r.let("coerced",Rt._`undefined`);if(s.coerceTypes==="array")r.if(Rt._`${o} == 'object' && Array.isArray(${i}) && ${i}.length == 1`,()=>r.assign(i,Rt._`${i}[0]`).assign(o,Rt._`typeof ${i}`).if(Rk(t,i,s.strictNumbers),()=>r.assign(a,i)));r.if(Rt._`${a} !== undefined`);for(let c of n)if(UL.has(c)||c==="array"&&s.coerceTypes==="array")l(c);r.else(),jk(e),r.endIf(),r.if(Rt._`${a} !== undefined`,()=>{r.assign(i,a),_pe(e,a)});function l(c){switch(c){case"string":r.elseIf(Rt._`${o} == "number" || ${o} == "boolean"`).assign(a,Rt._`"" + ${i}`).elseIf(Rt._`${i} === null`).assign(a,Rt._`""`);return;case"number":r.elseIf(Rt._`${o} == "boolean" || ${i} === null +`,t)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;let t=yx(e),n=Vf(t);return n.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:n,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;let t=yx(e),n=Vf(t);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:n,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,t){if(this.type!=="comment")return!1;if(this.indent<=t)return!1;return e.every((n)=>n.type==="newline"||n.type==="space")}*documentEnd(e){if(this.type!=="doc-mode"){if(e.end)e.end.push(this.sourceToken);else e.end=[this.sourceToken];if(this.type==="newline")yield*this.pop()}}*lineEnd(e){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;case"space":case"comment":default:if(e.end)e.end.push(this.sourceToken);else e.end=[this.sourceToken];if(this.type==="newline")yield*this.pop()}}}var hk=q(()=>{px();mk()});function Ice(e){let t=e.prettyErrors!==!1;return{lineCounter:e.lineCounter||t&&new mx||null,prettyErrors:t}}function go(e,t={}){let{lineCounter:n,prettyErrors:r}=Ice(t),i=new gx(n?.addNewLine),s=new cx(t),o=null;for(let a of s.compose(i.parse(e),!0,e.length))if(!o)o=a;else if(o.options.logLevel!=="silent"){o.errors.push(new Ja(a.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}if(r&&n)o.errors.forEach(QE(e,n)),o.warnings.forEach(QE(e,n));return o}function Ul(e,t,n){let r=null;if(typeof t==="function"||Array.isArray(t))r=t;else if(n===void 0&&t)n=t;if(typeof n==="string")n=n.length;if(typeof n==="number"){let i=Math.round(n);n=i<1?void 0:i>8?{indent:8}:{indent:i}}if(e===void 0){let{keepUndefined:i}=n??t??{};if(!i)return}if(fo(e)&&!r)return e.toString(n);return new ql(e,r,n).toString(n)}var JM=q(()=>{lk();$h();Ih();C_();rn();yk();hk()});var gk=q(()=>{lk();$h();WE();Ih();bh();rn();Cl();xr();Ml();tu();px();mk();yk();hk();JM();gh()});var bo=q(()=>{gk();gk()});var Ch=z(function(zM){Object.defineProperty(zM,"__esModule",{value:!0});zM.regexpCode=zM.getEsmExportName=zM.getProperty=zM.safeStringify=zM.stringify=zM.strConcat=zM.addCodeArg=zM.str=zM._=zM.nil=zM._Code=zM.Name=zM.IDENTIFIER=zM._CodeOrName=void 0;class bx{}zM._CodeOrName=bx;zM.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class Kf extends bx{constructor(e){super();if(!zM.IDENTIFIER.test(e))throw Error("CodeGen: name must be a valid identifier");this.str=e}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}zM.Name=Kf;class pa extends bx{constructor(e){super();this._items=typeof e==="string"?[e]:e}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let e=this._items[0];return e===""||e==='""'}get str(){var e;return(e=this._str)!==null&&e!==void 0?e:this._str=this._items.reduce((t,n)=>`${t}${n}`,"")}get names(){var e;return(e=this._names)!==null&&e!==void 0?e:this._names=this._items.reduce((t,n)=>{if(n instanceof Kf)t[n.str]=(t[n.str]||0)+1;return t},{})}}zM._Code=pa;zM.nil=new pa("");function GM(e,...t){let n=[e[0]],r=0;while(r{if(n.scopePath===void 0)throw Error(`CodeGen: name "${n}" has no value`);return us._`${e}${n.scopePath}`})}scopeCode(e=this._values,t,n){return this._reduceValues(e,(r)=>{if(r.value===void 0)throw Error(`CodeGen: name "${r}" has no value`);return r.value.code},t,n)}_reduceValues(e,t,n={},r){let i=us.nil;for(let s in e){let o=e[s];if(!o)continue;let a=n[s]=n[s]||new Map;o.forEach((l)=>{if(a.has(l))return;a.set(l,_x.Started);let c=t(l);if(c){let u=this.opts.es5?XM.varKinds.var:XM.varKinds.const;i=us._`${i}${u} ${l} = ${c};${this.opts._n}`}else if(c=r===null||r===void 0?void 0:r(l))i=us._`${i}${c}${this.opts._n}`;else throw new QM(l);a.set(l,_x.Completed)})}return i}}XM.ValueScope=YM});var kt=z(function(ps){Object.defineProperty(ps,"__esModule",{value:!0});ps.or=ps.and=ps.not=ps.CodeGen=ps.operators=ps.varKinds=ps.ValueScopeName=ps.ValueScope=ps.Scope=ps.Name=ps.regexpCode=ps.stringify=ps.getProperty=ps.nil=ps.strConcat=ps.str=ps._=void 0;var Xt=Ch(),da=Dk(),iu=Ch();Object.defineProperty(ps,"_",{enumerable:!0,get:function(){return iu._}});Object.defineProperty(ps,"str",{enumerable:!0,get:function(){return iu.str}});Object.defineProperty(ps,"strConcat",{enumerable:!0,get:function(){return iu.strConcat}});Object.defineProperty(ps,"nil",{enumerable:!0,get:function(){return iu.nil}});Object.defineProperty(ps,"getProperty",{enumerable:!0,get:function(){return iu.getProperty}});Object.defineProperty(ps,"stringify",{enumerable:!0,get:function(){return iu.stringify}});Object.defineProperty(ps,"regexpCode",{enumerable:!0,get:function(){return iu.regexpCode}});Object.defineProperty(ps,"Name",{enumerable:!0,get:function(){return iu.Name}});var Ex=Dk();Object.defineProperty(ps,"Scope",{enumerable:!0,get:function(){return Ex.Scope}});Object.defineProperty(ps,"ValueScope",{enumerable:!0,get:function(){return Ex.ValueScope}});Object.defineProperty(ps,"ValueScopeName",{enumerable:!0,get:function(){return Ex.ValueScopeName}});Object.defineProperty(ps,"varKinds",{enumerable:!0,get:function(){return Ex.varKinds}});ps.operators={GT:new Xt._Code(">"),GTE:new Xt._Code(">="),LT:new Xt._Code("<"),LTE:new Xt._Code("<="),EQ:new Xt._Code("==="),NEQ:new Xt._Code("!=="),NOT:new Xt._Code("!"),OR:new Xt._Code("||"),AND:new Xt._Code("&&"),ADD:new Xt._Code("+")};class su{optimizeNodes(){return this}optimizeNames(e,t){return this}}class eL extends su{constructor(e,t,n){super();this.varKind=e,this.name=t,this.rhs=n}render({es5:e,_n:t}){let n=e?da.varKinds.var:this.varKind,r=this.rhs===void 0?"":` = ${this.rhs}`;return`${n} ${this.name}${r};`+t}optimizeNames(e,t){if(!e[this.name.str])return;if(this.rhs)this.rhs=Gf(this.rhs,e,t);return this}get names(){return this.rhs instanceof Xt._CodeOrName?this.rhs.names:{}}}class Ek extends su{constructor(e,t,n){super();this.lhs=e,this.rhs=t,this.sideEffects=n}render({_n:e}){return`${this.lhs} = ${this.rhs};`+e}optimizeNames(e,t){if(this.lhs instanceof Xt.Name&&!e[this.lhs.str]&&!this.sideEffects)return;return this.rhs=Gf(this.rhs,e,t),this}get names(){let e=this.lhs instanceof Xt.Name?{}:{...this.lhs.names};return Sx(e,this.rhs)}}class tL extends Ek{constructor(e,t,n,r){super(e,n,r);this.op=t}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}}class nL extends su{constructor(e){super();this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}}class rL extends su{constructor(e){super();this.label=e,this.names={}}render({_n:e}){return`break${this.label?` ${this.label}`:""};`+e}}class iL extends su{constructor(e){super();this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}}class sL extends su{constructor(e){super();this.code=e}render({_n:e}){return`${this.code};`+e}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(e,t){return this.code=Gf(this.code,e,t),this}get names(){return this.code instanceof Xt._CodeOrName?this.code.names:{}}}class kx extends su{constructor(e=[]){super();this.nodes=e}render(e){return this.nodes.reduce((t,n)=>t+n.render(e),"")}optimizeNodes(){let{nodes:e}=this,t=e.length;while(t--){let n=e[t].optimizeNodes();if(Array.isArray(n))e.splice(t,1,...n);else if(n)e[t]=n;else e.splice(t,1)}return e.length>0?this:void 0}optimizeNames(e,t){let{nodes:n}=this,r=n.length;while(r--){let i=n[r];if(i.optimizeNames(e,t))continue;iue(e,i.names),n.splice(r,1)}return n.length>0?this:void 0}get names(){return this.nodes.reduce((e,t)=>Fp(e,t.names),{})}}class ou extends kx{render(e){return"{"+e._n+super.render(e)+"}"+e._n}}class oL extends kx{}class Mh extends ou{}Mh.kind="else";class Bl extends ou{constructor(e,t){super(t);this.condition=e}render(e){let t=`if(${this.condition})`+super.render(e);if(this.else)t+="else "+this.else.render(e);return t}optimizeNodes(){super.optimizeNodes();let e=this.condition;if(e===!0)return this.nodes;let t=this.else;if(t){let n=t.optimizeNodes();t=this.else=Array.isArray(n)?new Mh(n):n}if(t){if(e===!1)return t instanceof Bl?t:t.nodes;if(this.nodes.length)return this;return new Bl(pL(e),t instanceof Bl?[t]:t.nodes)}if(e===!1||!this.nodes.length)return;return this}optimizeNames(e,t){var n;if(this.else=(n=this.else)===null||n===void 0?void 0:n.optimizeNames(e,t),!(super.optimizeNames(e,t)||this.else))return;return this.condition=Gf(this.condition,e,t),this}get names(){let e=super.names;if(Sx(e,this.condition),this.else)Fp(e,this.else.names);return e}}Bl.kind="if";class Jf extends ou{}Jf.kind="for";class aL extends Jf{constructor(e){super();this.iteration=e}render(e){return`for(${this.iteration})`+super.render(e)}optimizeNames(e,t){if(!super.optimizeNames(e,t))return;return this.iteration=Gf(this.iteration,e,t),this}get names(){return Fp(super.names,this.iteration.names)}}class lL extends Jf{constructor(e,t,n,r){super();this.varKind=e,this.name=t,this.from=n,this.to=r}render(e){let t=e.es5?da.varKinds.var:this.varKind,{name:n,from:r,to:i}=this;return`for(${t} ${n}=${r}; ${n}<${i}; ${n}++)`+super.render(e)}get names(){let e=Sx(super.names,this.from);return Sx(e,this.to)}}class Tk extends Jf{constructor(e,t,n,r){super();this.loop=e,this.varKind=t,this.name=n,this.iterable=r}render(e){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(e)}optimizeNames(e,t){if(!super.optimizeNames(e,t))return;return this.iterable=Gf(this.iterable,e,t),this}get names(){return Fp(super.names,this.iterable.names)}}class xx extends ou{constructor(e,t,n){super();this.name=e,this.args=t,this.async=n}render(e){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(e)}}xx.kind="func";class wx extends kx{render(e){return"return "+super.render(e)}}wx.kind="return";class cL extends ou{render(e){let t="try"+super.render(e);if(this.catch)t+=this.catch.render(e);if(this.finally)t+=this.finally.render(e);return t}optimizeNodes(){var e,t;return super.optimizeNodes(),(e=this.catch)===null||e===void 0||e.optimizeNodes(),(t=this.finally)===null||t===void 0||t.optimizeNodes(),this}optimizeNames(e,t){var n,r;return super.optimizeNames(e,t),(n=this.catch)===null||n===void 0||n.optimizeNames(e,t),(r=this.finally)===null||r===void 0||r.optimizeNames(e,t),this}get names(){let e=super.names;if(this.catch)Fp(e,this.catch.names);if(this.finally)Fp(e,this.finally.names);return e}}class Dx extends ou{constructor(e){super();this.error=e}render(e){return`catch(${this.error})`+super.render(e)}}Dx.kind="catch";class Tx extends ou{render(e){return"finally"+super.render(e)}}Tx.kind="finally";class uL{constructor(e,t={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...t,_n:t.lines?` +`:""},this._extScope=e,this._scope=new da.Scope({parent:e}),this._nodes=[new oL]}toString(){return this._root.render(this.opts)}name(e){return this._scope.name(e)}scopeName(e){return this._extScope.name(e)}scopeValue(e,t){let n=this._extScope.value(e,t);return(this._values[n.prefix]||(this._values[n.prefix]=new Set)).add(n),n}getScopeValue(e,t){return this._extScope.getValue(e,t)}scopeRefs(e){return this._extScope.scopeRefs(e,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(e,t,n,r){let i=this._scope.toName(t);if(n!==void 0&&r)this._constants[i.str]=n;return this._leafNode(new eL(e,i,n)),i}const(e,t,n){return this._def(da.varKinds.const,e,t,n)}let(e,t,n){return this._def(da.varKinds.let,e,t,n)}var(e,t,n){return this._def(da.varKinds.var,e,t,n)}assign(e,t,n){return this._leafNode(new Ek(e,t,n))}add(e,t){return this._leafNode(new tL(e,ps.operators.ADD,t))}code(e){if(typeof e=="function")e();else if(e!==Xt.nil)this._leafNode(new sL(e));return this}object(...e){let t=["{"];for(let[n,r]of e){if(t.length>1)t.push(",");if(t.push(n),n!==r||this.opts.es5)t.push(":"),Xt.addCodeArg(t,r)}return t.push("}"),new Xt._Code(t)}if(e,t,n){if(this._blockNode(new Bl(e)),t&&n)this.code(t).else().code(n).endIf();else if(t)this.code(t).endIf();else if(n)throw Error('CodeGen: "else" body without "then" body');return this}elseIf(e){return this._elseNode(new Bl(e))}else(){return this._elseNode(new Mh)}endIf(){return this._endBlockNode(Bl,Mh)}_for(e,t){if(this._blockNode(e),t)this.code(t).endFor();return this}for(e,t){return this._for(new aL(e),t)}forRange(e,t,n,r,i=this.opts.es5?da.varKinds.var:da.varKinds.let){let s=this._scope.toName(e);return this._for(new lL(i,s,t,n),()=>r(s))}forOf(e,t,n,r=da.varKinds.const){let i=this._scope.toName(e);if(this.opts.es5){let s=t instanceof Xt.Name?t:this.var("_arr",t);return this.forRange("_i",0,Xt._`${s}.length`,(o)=>{this.var(i,Xt._`${s}[${o}]`),n(i)})}return this._for(new Tk("of",r,i,t),()=>n(i))}forIn(e,t,n,r=this.opts.es5?da.varKinds.var:da.varKinds.const){if(this.opts.ownProperties)return this.forOf(e,Xt._`Object.keys(${t})`,n);let i=this._scope.toName(e);return this._for(new Tk("in",r,i,t),()=>n(i))}endFor(){return this._endBlockNode(Jf)}label(e){return this._leafNode(new nL(e))}break(e){return this._leafNode(new rL(e))}return(e){let t=new wx;if(this._blockNode(t),this.code(e),t.nodes.length!==1)throw Error('CodeGen: "return" should have one node');return this._endBlockNode(wx)}try(e,t,n){if(!t&&!n)throw Error('CodeGen: "try" without "catch" and "finally"');let r=new cL;if(this._blockNode(r),this.code(e),t){let i=this.name("e");this._currNode=r.catch=new Dx(i),t(i)}if(n)this._currNode=r.finally=new Tx,this.code(n);return this._endBlockNode(Dx,Tx)}throw(e){return this._leafNode(new iL(e))}block(e,t){if(this._blockStarts.push(this._nodes.length),e)this.code(e).endBlock(t);return this}endBlock(e){let t=this._blockStarts.pop();if(t===void 0)throw Error("CodeGen: not in self-balancing block");let n=this._nodes.length-t;if(n<0||e!==void 0&&n!==e)throw Error(`CodeGen: wrong number of nodes: ${n} vs ${e} expected`);return this._nodes.length=t,this}func(e,t=Xt.nil,n,r){if(this._blockNode(new xx(e,t,n)),r)this.code(r).endFunc();return this}endFunc(){return this._endBlockNode(xx)}optimize(e=1){while(e-- >0)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(e){return this._currNode.nodes.push(e),this}_blockNode(e){this._currNode.nodes.push(e),this._nodes.push(e)}_endBlockNode(e,t){let n=this._currNode;if(n instanceof e||t&&n instanceof t)return this._nodes.pop(),this;throw Error(`CodeGen: not in block "${t?`${e.kind}/${t.kind}`:e.kind}"`)}_elseNode(e){let t=this._currNode;if(!(t instanceof Bl))throw Error('CodeGen: "else" without "if"');return this._currNode=t.else=e,this}get _root(){return this._nodes[0]}get _currNode(){let e=this._nodes;return e[e.length-1]}set _currNode(e){let t=this._nodes;t[t.length-1]=e}}ps.CodeGen=uL;function Fp(e,t){for(let n in t)e[n]=(e[n]||0)+(t[n]||0);return e}function Sx(e,t){return t instanceof Xt._CodeOrName?Fp(e,t.names):e}function Gf(e,t,n){if(e instanceof Xt.Name)return r(e);if(!i(e))return e;return new Xt._Code(e._items.reduce((s,o)=>{if(o instanceof Xt.Name)o=r(o);if(o instanceof Xt._Code)s.push(...o._items);else s.push(o);return s},[]));function r(s){let o=n[s.str];if(o===void 0||t[s.str]!==1)return s;return delete t[s.str],o}function i(s){return s instanceof Xt._Code&&s._items.some((o)=>o instanceof Xt.Name&&t[o.str]===1&&n[o.str]!==void 0)}}function iue(e,t){for(let n in t)e[n]=(e[n]||0)-(t[n]||0)}function pL(e){return typeof e=="boolean"||typeof e=="number"||e===null?!e:Xt._`!${Sk(e)}`}ps.not=pL;var sue=dL(ps.operators.AND);function oue(...e){return e.reduce(sue)}ps.and=oue;var aue=dL(ps.operators.OR);function lue(...e){return e.reduce(aue)}ps.or=lue;function dL(e){return(t,n)=>t===Xt.nil?n:n===Xt.nil?t:Xt._`${Sk(t)} ${e} ${Sk(n)}`}function Sk(e){return e instanceof Xt.Name?e:Xt._`(${e})`}});var Kt=z(function(xL){Object.defineProperty(xL,"__esModule",{value:!0});xL.checkStrictMode=xL.getErrorPath=xL.Type=xL.useFunc=xL.setEvaluated=xL.evaluatedPropsToName=xL.mergeEvaluated=xL.eachItem=xL.unescapeJsonPointer=xL.escapeJsonPointer=xL.escapeFragment=xL.unescapeFragment=xL.schemaRefOrVal=xL.schemaHasRulesButRef=xL.schemaHasRules=xL.checkUnknownRules=xL.alwaysValidSchema=xL.toHash=void 0;var Fn=kt(),due=Ch();function fue(e){let t={};for(let n of e)t[n]=!0;return t}xL.toHash=fue;function mue(e,t){if(typeof t=="boolean")return t;if(Object.keys(t).length===0)return!0;return hL(e,t),!gL(t,e.self.RULES.all)}xL.alwaysValidSchema=mue;function hL(e,t=e.schema){let{opts:n,self:r}=e;if(!n.strictSchema)return;if(typeof t==="boolean")return;let i=r.RULES.keywords;for(let s in t)if(!i[s])_L(e,`unknown keyword: "${s}"`)}xL.checkUnknownRules=hL;function gL(e,t){if(typeof e=="boolean")return!e;for(let n in e)if(t[n])return!0;return!1}xL.schemaHasRules=gL;function yue(e,t){if(typeof e=="boolean")return!e;for(let n in e)if(n!=="$ref"&&t.all[n])return!0;return!1}xL.schemaHasRulesButRef=yue;function hue({topSchemaRef:e,schemaPath:t},n,r,i){if(!i){if(typeof n=="number"||typeof n=="boolean")return n;if(typeof n=="string")return Fn._`${n}`}return Fn._`${e}${t}${Fn.getProperty(r)}`}xL.schemaRefOrVal=hue;function gue(e){return bL(decodeURIComponent(e))}xL.unescapeFragment=gue;function bue(e){return encodeURIComponent(Nk(e))}xL.escapeFragment=bue;function Nk(e){if(typeof e=="number")return`${e}`;return e.replace(/~/g,"~0").replace(/\//g,"~1")}xL.escapeJsonPointer=Nk;function bL(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}xL.unescapeJsonPointer=bL;function vue(e,t){if(Array.isArray(e))for(let n of e)t(n);else t(e)}xL.eachItem=vue;function mL({mergeNames:e,mergeToName:t,mergeValues:n,resultToName:r}){return(i,s,o,a)=>{let l=o===void 0?s:o instanceof Fn.Name?(s instanceof Fn.Name?e(i,s,o):t(i,s,o),o):s instanceof Fn.Name?(t(i,o,s),s):n(s,o);return a===Fn.Name&&!(l instanceof Fn.Name)?r(i,l):l}}xL.mergeEvaluated={props:mL({mergeNames:(e,t,n)=>e.if(Fn._`${n} !== true && ${t} !== undefined`,()=>{e.if(Fn._`${t} === true`,()=>e.assign(n,!0),()=>e.assign(n,Fn._`${n} || {}`).code(Fn._`Object.assign(${n}, ${t})`))}),mergeToName:(e,t,n)=>e.if(Fn._`${n} !== true`,()=>{if(t===!0)e.assign(n,!0);else e.assign(n,Fn._`${n} || {}`),Ok(e,n,t)}),mergeValues:(e,t)=>e===!0?!0:{...e,...t},resultToName:vL}),items:mL({mergeNames:(e,t,n)=>e.if(Fn._`${n} !== true && ${t} !== undefined`,()=>e.assign(n,Fn._`${t} === true ? true : ${n} > ${t} ? ${n} : ${t}`)),mergeToName:(e,t,n)=>e.if(Fn._`${n} !== true`,()=>e.assign(n,t===!0?!0:Fn._`${n} > ${t} ? ${n} : ${t}`)),mergeValues:(e,t)=>e===!0?!0:Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})};function vL(e,t){if(t===!0)return e.var("props",!0);let n=e.var("props",Fn._`{}`);if(t!==void 0)Ok(e,n,t);return n}xL.evaluatedPropsToName=vL;function Ok(e,t,n){Object.keys(n).forEach((r)=>e.assign(Fn._`${t}${Fn.getProperty(r)}`,!0))}xL.setEvaluated=Ok;var yL={};function _ue(e,t){return e.scopeValue("func",{ref:t,code:yL[t.code]||(yL[t.code]=new due._Code(t.code))})}xL.useFunc=_ue;var kk;(function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"})(kk||(xL.Type=kk={}));function xue(e,t,n){if(e instanceof Fn.Name){let r=t===kk.Num;return n?r?Fn._`"[" + ${e} + "]"`:Fn._`"['" + ${e} + "']"`:r?Fn._`"/" + ${e}`:Fn._`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return n?Fn.getProperty(e).toString():"/"+Nk(e)}xL.getErrorPath=xue;function _L(e,t,n=e.opts.strictSchema){if(!n)return;if(t=`strict mode: ${t}`,n===!0)throw Error(t);e.self.logger.warn(t)}xL.checkStrictMode=_L});var vo=z(function(DL){Object.defineProperty(DL,"__esModule",{value:!0});var wi=kt(),Lue={data:new wi.Name("data"),valCxt:new wi.Name("valCxt"),instancePath:new wi.Name("instancePath"),parentData:new wi.Name("parentData"),parentDataProperty:new wi.Name("parentDataProperty"),rootData:new wi.Name("rootData"),dynamicAnchors:new wi.Name("dynamicAnchors"),vErrors:new wi.Name("vErrors"),errors:new wi.Name("errors"),this:new wi.Name("this"),self:new wi.Name("self"),scope:new wi.Name("scope"),json:new wi.Name("json"),jsonPos:new wi.Name("jsonPos"),jsonLen:new wi.Name("jsonLen"),jsonPart:new wi.Name("jsonPart")};DL.default=Lue});var Lh=z(function(kL){Object.defineProperty(kL,"__esModule",{value:!0});kL.extendErrors=kL.resetErrorsCount=kL.reportExtraError=kL.reportError=kL.keyword$DataError=kL.keywordError=void 0;var sn=kt(),Ox=Kt(),Gi=vo();kL.keywordError={message:({keyword:e})=>sn.str`must pass "${e}" keyword validation`};kL.keyword$DataError={message:({keyword:e,schemaType:t})=>t?sn.str`"${e}" keyword must be ${t} ($data)`:sn.str`"${e}" keyword is invalid ($data)`};function Uue(e,t=kL.keywordError,n,r){let{it:i}=e,{gen:s,compositeRule:o,allErrors:a}=i,l=EL(e,t,n);if(r!==null&&r!==void 0?r:o||a)TL(s,l);else SL(i,sn._`[${l}]`)}kL.reportError=Uue;function Bue(e,t=kL.keywordError,n){let{it:r}=e,{gen:i,compositeRule:s,allErrors:o}=r,a=EL(e,t,n);if(TL(i,a),!(s||o))SL(r,Gi.default.vErrors)}kL.reportExtraError=Bue;function Vue(e,t){e.assign(Gi.default.errors,t),e.if(sn._`${Gi.default.vErrors} !== null`,()=>e.if(t,()=>e.assign(sn._`${Gi.default.vErrors}.length`,t),()=>e.assign(Gi.default.vErrors,null)))}kL.resetErrorsCount=Vue;function Kue({gen:e,keyword:t,schemaValue:n,data:r,errsCount:i,it:s}){if(i===void 0)throw Error("ajv implementation error");let o=e.name("err");e.forRange("i",i,Gi.default.errors,(a)=>{if(e.const(o,sn._`${Gi.default.vErrors}[${a}]`),e.if(sn._`${o}.instancePath === undefined`,()=>e.assign(sn._`${o}.instancePath`,sn.strConcat(Gi.default.instancePath,s.errorPath))),e.assign(sn._`${o}.schemaPath`,sn.str`${s.errSchemaPath}/${t}`),s.opts.verbose)e.assign(sn._`${o}.schema`,n),e.assign(sn._`${o}.data`,r)})}kL.extendErrors=Kue;function TL(e,t){let n=e.const("err",t);e.if(sn._`${Gi.default.vErrors} === null`,()=>e.assign(Gi.default.vErrors,sn._`[${n}]`),sn._`${Gi.default.vErrors}.push(${n})`),e.code(sn._`${Gi.default.errors}++`)}function SL(e,t){let{gen:n,validateName:r,schemaEnv:i}=e;if(i.$async)n.throw(sn._`new ${e.ValidationError}(${t})`);else n.assign(sn._`${r}.errors`,t),n.return(!1)}var Cp={keyword:new sn.Name("keyword"),schemaPath:new sn.Name("schemaPath"),params:new sn.Name("params"),propertyName:new sn.Name("propertyName"),message:new sn.Name("message"),schema:new sn.Name("schema"),parentSchema:new sn.Name("parentSchema")};function EL(e,t,n){let{createErrors:r}=e.it;if(r===!1)return sn._`{}`;return Jue(e,t,n)}function Jue(e,t,n={}){let{gen:r,it:i}=e,s=[Gue(i,n),Hue(e,n)];return zue(e,t,s),r.object(...s)}function Gue({errorPath:e},{instancePath:t}){let n=t?sn.str`${e}${Ox.getErrorPath(t,Ox.Type.Str)}`:e;return[Gi.default.instancePath,sn.strConcat(Gi.default.instancePath,n)]}function Hue({keyword:e,it:{errSchemaPath:t}},{schemaPath:n,parentSchema:r}){let i=r?t:sn.str`${t}/${e}`;if(n)i=sn.str`${i}${Ox.getErrorPath(n,Ox.Type.Str)}`;return[Cp.schemaPath,i]}function zue(e,{params:t,message:n},r){let{keyword:i,data:s,schemaValue:o,it:a}=e,{opts:l,propertyName:c,topSchemaRef:u,schemaPath:p}=a;if(r.push([Cp.keyword,i],[Cp.params,typeof t=="function"?t(e):t||sn._`{}`]),l.messages)r.push([Cp.message,typeof n=="function"?n(e):n]);if(l.verbose)r.push([Cp.schema,o],[Cp.parentSchema,sn._`${u}${p}`],[Gi.default.data,s]);if(c)r.push([Cp.propertyName,c])}});var IL=z(function(PL){Object.defineProperty(PL,"__esModule",{value:!0});PL.boolOrEmptySchema=PL.topBoolOrEmptySchema=void 0;var Zue=Lh(),epe=kt(),tpe=vo(),npe={message:"boolean schema is false"};function rpe(e){let{gen:t,schema:n,validateName:r}=e;if(n===!1)OL(e,!1);else if(typeof n=="object"&&n.$async===!0)t.return(tpe.default.data);else t.assign(epe._`${r}.errors`,null),t.return(!0)}PL.topBoolOrEmptySchema=rpe;function ipe(e,t){let{gen:n,schema:r}=e;if(r===!1)n.var(t,!1),OL(e);else n.var(t,!0)}PL.boolOrEmptySchema=ipe;function OL(e,t){let{gen:n,data:r}=e;Zue.reportError({gen:n,keyword:"false schema",data:r,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e},npe,void 0,t)}});var $k=z(function(AL){Object.defineProperty(AL,"__esModule",{value:!0});AL.getRules=AL.isJSONType=void 0;var ope=["string","number","integer","boolean","null","object","array"],ape=new Set(ope);function lpe(e){return typeof e=="string"&&ape.has(e)}AL.isJSONType=lpe;function cpe(){let e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...e,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}AL.getRules=cpe});var Ik=z(function(CL){Object.defineProperty(CL,"__esModule",{value:!0});CL.shouldUseRule=CL.shouldUseGroup=CL.schemaHasRulesForType=void 0;function ppe({schema:e,self:t},n){let r=t.RULES.types[n];return r&&r!==!0&&jL(e,r)}CL.schemaHasRulesForType=ppe;function jL(e,t){return t.rules.some((n)=>FL(e,n))}CL.shouldUseGroup=jL;function FL(e,t){var n;return e[t.keyword]!==void 0||((n=t.definition.implements)===null||n===void 0?void 0:n.some((r)=>e[r]!==void 0))}CL.shouldUseRule=FL});var qh=z(function(BL){Object.defineProperty(BL,"__esModule",{value:!0});BL.reportTypeError=BL.checkDataTypes=BL.checkDataType=BL.coerceAndCheckDataType=BL.getJSONTypes=BL.getSchemaTypes=BL.DataType=void 0;var mpe=$k(),ype=Ik(),hpe=Lh(),Rt=kt(),LL=Kt(),Hf;(function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"})(Hf||(BL.DataType=Hf={}));function gpe(e){let t=qL(e.type);if(t.includes("null")){if(e.nullable===!1)throw Error("type: null contradicts nullable: false")}else{if(!t.length&&e.nullable!==void 0)throw Error('"nullable" cannot be used without "type"');if(e.nullable===!0)t.push("null")}return t}BL.getSchemaTypes=gpe;function qL(e){let t=Array.isArray(e)?e:e?[e]:[];if(t.every(mpe.isJSONType))return t;throw Error("type must be JSONType or JSONType[]: "+t.join(","))}BL.getJSONTypes=qL;function bpe(e,t){let{gen:n,data:r,opts:i}=e,s=vpe(t,i.coerceTypes),o=t.length>0&&!(s.length===0&&t.length===1&&ype.schemaHasRulesForType(e,t[0]));if(o){let a=Rk(t,r,i.strictNumbers,Hf.Wrong);n.if(a,()=>{if(s.length)_pe(e,t,s);else jk(e)})}return o}BL.coerceAndCheckDataType=bpe;var UL=new Set(["string","number","integer","boolean","null"]);function vpe(e,t){return t?e.filter((n)=>UL.has(n)||t==="array"&&n==="array"):[]}function _pe(e,t,n){let{gen:r,data:i,opts:s}=e,o=r.let("dataType",Rt._`typeof ${i}`),a=r.let("coerced",Rt._`undefined`);if(s.coerceTypes==="array")r.if(Rt._`${o} == 'object' && Array.isArray(${i}) && ${i}.length == 1`,()=>r.assign(i,Rt._`${i}[0]`).assign(o,Rt._`typeof ${i}`).if(Rk(t,i,s.strictNumbers),()=>r.assign(a,i)));r.if(Rt._`${a} !== undefined`);for(let c of n)if(UL.has(c)||c==="array"&&s.coerceTypes==="array")l(c);r.else(),jk(e),r.endIf(),r.if(Rt._`${a} !== undefined`,()=>{r.assign(i,a),xpe(e,a)});function l(c){switch(c){case"string":r.elseIf(Rt._`${o} == "number" || ${o} == "boolean"`).assign(a,Rt._`"" + ${i}`).elseIf(Rt._`${i} === null`).assign(a,Rt._`""`);return;case"number":r.elseIf(Rt._`${o} == "boolean" || ${i} === null || (${o} == "string" && ${i} && ${i} == +${i})`).assign(a,Rt._`+${i}`);return;case"integer":r.elseIf(Rt._`${o} === "boolean" || ${i} === null || (${o} === "string" && ${i} && ${i} == +${i} && !(${i} % 1))`).assign(a,Rt._`+${i}`);return;case"boolean":r.elseIf(Rt._`${i} === "false" || ${i} === 0 || ${i} === null`).assign(a,!1).elseIf(Rt._`${i} === "true" || ${i} === 1`).assign(a,!0);return;case"null":r.elseIf(Rt._`${i} === "" || ${i} === 0 || ${i} === false`),r.assign(a,null);return;case"array":r.elseIf(Rt._`${o} === "string" || ${o} === "number" - || ${o} === "boolean" || ${i} === null`).assign(a,Rt._`[${i}]`)}}}function _pe({gen:e,parentData:t,parentDataProperty:n},r){e.if(Rt._`${t} !== undefined`,()=>e.assign(Rt._`${t}[${n}]`,r))}function Ak(e,t,n,r=Jf.Correct){let i=r===Jf.Correct?Rt.operators.EQ:Rt.operators.NEQ,s;switch(e){case"null":return Rt._`${t} ${i} null`;case"array":s=Rt._`Array.isArray(${t})`;break;case"object":s=Rt._`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":s=o(Rt._`!(${t} % 1) && !isNaN(${t})`);break;case"number":s=o();break;default:return Rt._`typeof ${t} ${i} ${e}`}return r===Jf.Correct?s:Rt.not(s);function o(a=Rt.nil){return Rt.and(Rt._`typeof ${t} == "number"`,a,n?Rt._`isFinite(${t})`:Rt.nil)}}BL.checkDataType=Ak;function Rk(e,t,n,r){if(e.length===1)return Ak(e[0],t,n,r);let i,s=LL.toHash(e);if(s.array&&s.object){let o=Rt._`typeof ${t} != "object"`;i=s.null?o:Rt._`!${t} || ${o}`,delete s.null,delete s.array,delete s.object}else i=Rt.nil;if(s.number)delete s.integer;for(let o in s)i=Rt.and(i,Ak(o,t,n,r));return i}BL.checkDataTypes=Rk;var xpe={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>typeof e=="string"?Rt._`{type: ${e}}`:Rt._`{type: ${t}}`};function jk(e){let t=wpe(e);ype.reportError(t,xpe)}BL.reportTypeError=jk;function wpe(e){let{gen:t,data:n,schema:r}=e,i=LL.schemaRefOrVal(e,r,"type");return{gen:t,keyword:"type",data:n,schema:r.type,schemaCode:i,schemaValue:i,parentSchema:r,params:{},it:e}}});var HL=z(function(JL){Object.defineProperty(JL,"__esModule",{value:!0});JL.assignDefaults=void 0;var Gf=Et(),Ope=Kt();function Ppe(e,t){let{properties:n,items:r}=e.schema;if(t==="object"&&n)for(let i in n)KL(e,i,n[i].default);else if(t==="array"&&Array.isArray(r))r.forEach((i,s)=>KL(e,s,i.default))}JL.assignDefaults=Ppe;function KL(e,t,n){let{gen:r,compositeRule:i,data:s,opts:o}=e;if(n===void 0)return;let a=Gf._`${s}${Gf.getProperty(t)}`;if(i){Ope.checkStrictMode(e,`default is ignored for: ${a}`);return}let l=Gf._`${a} === undefined`;if(o.useDefaults==="empty")l=Gf._`${l} || ${a} === null || ${a} === ""`;r.if(l,Gf._`${a} = ${Gf.stringify(n)}`)}});var _o=z(function(QL){Object.defineProperty(QL,"__esModule",{value:!0});QL.validateUnion=QL.validateArray=QL.usePattern=QL.callValidateCode=QL.schemaProperties=QL.allSchemaProperties=QL.noPropertyInData=QL.propertyInData=QL.isOwnProperty=QL.hasPropFunc=QL.reportMissingProp=QL.checkMissingProp=QL.checkReportMissingProp=void 0;var Bn=Et(),Fk=Kt(),ou=vo(),$pe=Kt();function Ipe(e,t){let{gen:n,data:r,it:i}=e;n.if(Mk(n,r,t,i.opts.ownProperties),()=>{e.setParams({missingProperty:Bn._`${t}`},!0),e.error()})}QL.checkReportMissingProp=Ipe;function Ape({gen:e,data:t,it:{opts:n}},r,i){return Bn.or(...r.map((s)=>Bn.and(Mk(e,t,s,n.ownProperties),Bn._`${i} = ${s}`)))}QL.checkMissingProp=Ape;function Rpe(e,t){e.setParams({missingProperty:t},!0),e.error()}QL.reportMissingProp=Rpe;function zL(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:Bn._`Object.prototype.hasOwnProperty`})}QL.hasPropFunc=zL;function Ck(e,t,n){return Bn._`${zL(e)}.call(${t}, ${n})`}QL.isOwnProperty=Ck;function jpe(e,t,n,r){let i=Bn._`${t}${Bn.getProperty(n)} !== undefined`;return r?Bn._`${i} && ${Ck(e,t,n)}`:i}QL.propertyInData=jpe;function Mk(e,t,n,r){let i=Bn._`${t}${Bn.getProperty(n)} === undefined`;return r?Bn.or(i,Bn.not(Ck(e,t,n))):i}QL.noPropertyInData=Mk;function WL(e){return e?Object.keys(e).filter((t)=>t!=="__proto__"):[]}QL.allSchemaProperties=WL;function Fpe(e,t){return WL(t).filter((n)=>!Fk.alwaysValidSchema(e,t[n]))}QL.schemaProperties=Fpe;function Cpe({schemaCode:e,data:t,it:{gen:n,topSchemaRef:r,schemaPath:i,errorPath:s},it:o},a,l,c){let u=c?Bn._`${e}, ${t}, ${r}${i}`:t,p=[[ou.default.instancePath,Bn.strConcat(ou.default.instancePath,s)],[ou.default.parentData,o.parentData],[ou.default.parentDataProperty,o.parentDataProperty],[ou.default.rootData,ou.default.rootData]];if(o.opts.dynamicRef)p.push([ou.default.dynamicAnchors,ou.default.dynamicAnchors]);let d=Bn._`${u}, ${n.object(...p)}`;return l!==Bn.nil?Bn._`${a}.call(${l}, ${d})`:Bn._`${a}(${d})`}QL.callValidateCode=Cpe;var Mpe=Bn._`new RegExp`;function Lpe({gen:e,it:{opts:t}},n){let r=t.unicodeRegExp?"u":"",{regExp:i}=t.code,s=i(n,r);return e.scopeValue("pattern",{key:s.toString(),ref:s,code:Bn._`${i.code==="new RegExp"?Mpe:$pe.useFunc(e,i)}(${n}, ${r})`})}QL.usePattern=Lpe;function qpe(e){let{gen:t,data:n,keyword:r,it:i}=e,s=t.name("valid");if(i.allErrors){let a=t.let("valid",!0);return o(()=>t.assign(a,!1)),a}return t.var(s,!0),o(()=>t.break()),s;function o(a){let l=t.const("len",Bn._`${n}.length`);t.forRange("i",0,l,(c)=>{e.subschema({keyword:r,dataProp:c,dataPropType:Fk.Type.Num},s),t.if(Bn.not(s),a)})}}QL.validateArray=qpe;function Upe(e){let{gen:t,schema:n,keyword:r,it:i}=e;if(!Array.isArray(n))throw Error("ajv implementation error");if(n.some((l)=>Fk.alwaysValidSchema(i,l))&&!i.opts.unevaluated)return;let o=t.let("valid",!1),a=t.name("_valid");t.block(()=>n.forEach((l,c)=>{let u=e.subschema({keyword:r,schemaProp:c,compositeRule:!0},a);if(t.assign(o,Bn._`${o} || ${a}`),!e.mergeValidEvaluated(u,a))t.if(Bn.not(o))})),e.result(o,()=>e.reset(),()=>e.error(!0))}QL.validateUnion=Upe});var n2=z(function(e2){Object.defineProperty(e2,"__esModule",{value:!0});e2.validateKeywordUsage=e2.validSchemaType=e2.funcKeywordCode=e2.macroKeywordCode=void 0;var Gi=Et(),Fp=vo(),ede=_o(),tde=Lh();function nde(e,t){let{gen:n,keyword:r,schema:i,parentSchema:s,it:o}=e,a=t.macro.call(o.self,i,s,o),l=ZL(n,r,a);if(o.opts.validateSchema!==!1)o.self.validateSchema(a,!0);let c=n.name("valid");e.subschema({schema:a,schemaPath:Gi.nil,errSchemaPath:`${o.errSchemaPath}/${r}`,topSchemaRef:l,compositeRule:!0},c),e.pass(c,()=>e.error(!0))}e2.macroKeywordCode=nde;function rde(e,t){var n;let{gen:r,keyword:i,schema:s,parentSchema:o,$data:a,it:l}=e;sde(l,t);let c=!a&&t.compile?t.compile.call(l.self,s,o,l):t.validate,u=ZL(r,i,c),p=r.let("valid");e.block$data(p,d),e.ok((n=t.valid)!==null&&n!==void 0?n:p);function d(){if(t.errors===!1){if(y(),t.modifying)XL(e);h(()=>e.error())}else{let b=t.async?f():m();if(t.modifying)XL(e);h(()=>ide(e,b))}}function f(){let b=r.let("ruleErrs",null);return r.try(()=>y(Gi._`await `),(g)=>r.assign(p,!1).if(Gi._`${g} instanceof ${l.ValidationError}`,()=>r.assign(b,Gi._`${g}.errors`),()=>r.throw(g))),b}function m(){let b=Gi._`${u}.errors`;return r.assign(b,null),y(Gi.nil),b}function y(b=t.async?Gi._`await `:Gi.nil){let g=l.opts.passContext?Fp.default.this:Fp.default.self,x=!(("compile"in t)&&!a||t.schema===!1);r.assign(p,Gi._`${b}${ede.callValidateCode(e,u,g,x)}`,t.modifying)}function h(b){var g;r.if(Gi.not((g=t.valid)!==null&&g!==void 0?g:p),b)}}e2.funcKeywordCode=rde;function XL(e){let{gen:t,data:n,it:r}=e;t.if(r.parentData,()=>t.assign(n,Gi._`${r.parentData}[${r.parentDataProperty}]`))}function ide(e,t){let{gen:n}=e;n.if(Gi._`Array.isArray(${t})`,()=>{n.assign(Fp.default.vErrors,Gi._`${Fp.default.vErrors} === null ? ${t} : ${Fp.default.vErrors}.concat(${t})`).assign(Fp.default.errors,Gi._`${Fp.default.vErrors}.length`),tde.extendErrors(e)},()=>e.error())}function sde({schemaEnv:e},t){if(t.async&&!e.$async)throw Error("async keyword in sync schema")}function ZL(e,t,n){if(n===void 0)throw Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof n=="function"?{ref:n}:{ref:n,code:Gi.stringify(n)})}function ode(e,t,n=!1){return!t.length||t.some((r)=>r==="array"?Array.isArray(e):r==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==r||n&&typeof e>"u")}e2.validSchemaType=ode;function ade({schema:e,opts:t,self:n,errSchemaPath:r},i,s){if(Array.isArray(i.keyword)?!i.keyword.includes(s):i.keyword!==s)throw Error("ajv implementation error");let o=i.dependencies;if(o===null||o===void 0?void 0:o.some((a)=>!Object.prototype.hasOwnProperty.call(e,a)))throw Error(`parent schema must have dependencies of ${s}: ${o.join(",")}`);if(i.validateSchema){if(!i.validateSchema(e[s])){let l=`keyword "${s}" value is invalid at path "${r}": `+n.errorsText(i.validateSchema.errors);if(t.validateSchema==="log")n.logger.error(l);else throw Error(l)}}}e2.validateKeywordUsage=ade});var o2=z(function(i2){Object.defineProperty(i2,"__esModule",{value:!0});i2.extendSubschemaMode=i2.extendSubschemaData=i2.getSubschema=void 0;var za=Et(),r2=Kt();function pde(e,{keyword:t,schemaProp:n,schema:r,schemaPath:i,errSchemaPath:s,topSchemaRef:o}){if(t!==void 0&&r!==void 0)throw Error('both "keyword" and "schema" passed, only one allowed');if(t!==void 0){let a=e.schema[t];return n===void 0?{schema:a,schemaPath:za._`${e.schemaPath}${za.getProperty(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:a[n],schemaPath:za._`${e.schemaPath}${za.getProperty(t)}${za.getProperty(n)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${r2.escapeFragment(n)}`}}if(r!==void 0){if(i===void 0||s===void 0||o===void 0)throw Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:r,schemaPath:i,topSchemaRef:o,errSchemaPath:s}}throw Error('either "keyword" or "schema" must be passed')}i2.getSubschema=pde;function dde(e,t,{dataProp:n,dataPropType:r,data:i,dataTypes:s,propertyName:o}){if(i!==void 0&&n!==void 0)throw Error('both "data" and "dataProp" passed, only one allowed');let{gen:a}=t;if(n!==void 0){let{errorPath:c,dataPathArr:u,opts:p}=t,d=a.let("data",za._`${t.data}${za.getProperty(n)}`,!0);l(d),e.errorPath=za.str`${c}${r2.getErrorPath(n,r,p.jsPropertySyntax)}`,e.parentDataProperty=za._`${n}`,e.dataPathArr=[...u,e.parentDataProperty]}if(i!==void 0){let c=i instanceof za.Name?i:a.let("data",i,!0);if(l(c),o!==void 0)e.propertyName=o}if(s)e.dataTypes=s;function l(c){e.data=c,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,c]}}i2.extendSubschemaData=dde;function fde(e,{jtdDiscriminator:t,jtdMetadata:n,compositeRule:r,createErrors:i,allErrors:s}){if(r!==void 0)e.compositeRule=r;if(i!==void 0)e.createErrors=i;if(s!==void 0)e.allErrors=s;e.jtdDiscriminator=t,e.jtdMetadata=n}i2.extendSubschemaMode=fde});var Lk=z(function(YJe,a2){a2.exports=function e(t,n){if(t===n)return!0;if(t&&n&&typeof t=="object"&&typeof n=="object"){if(t.constructor!==n.constructor)return!1;var r,i,s;if(Array.isArray(t)){if(r=t.length,r!=n.length)return!1;for(i=r;i--!==0;)if(!e(t[i],n[i]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if(s=Object.keys(t),r=s.length,r!==Object.keys(n).length)return!1;for(i=r;i--!==0;)if(!Object.prototype.hasOwnProperty.call(n,s[i]))return!1;for(i=r;i--!==0;){var o=s[i];if(!e(t[o],n[o]))return!1}return!0}return t!==t&&n!==n}});var c2=z(function(XJe,l2){var au=l2.exports=function(e,t,n){if(typeof t=="function")n=t,t={};n=t.cb||n;var r=typeof n=="function"?n:n.pre||function(){},i=n.post||function(){};Px(t,r,i,e,"",e)};au.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};au.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};au.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};au.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function Px(e,t,n,r,i,s,o,a,l,c){if(r&&typeof r=="object"&&!Array.isArray(r)){t(r,i,s,o,a,l,c);for(var u in r){var p=r[u];if(Array.isArray(p)){if(u in au.arrayKeywords)for(var d=0;dt+=u2(r));if(t===1/0)return 1/0}return t}function p2(e,t="",n){if(n!==!1)t=Hf(t);let r=e.parse(t);return d2(e,r)}f2.getFullPath=p2;function d2(e,t){return e.serialize(t).split("#")[0]+"#"}f2._getFullPath=d2;var Dde=/#\/?$/;function Hf(e){return e?e.replace(Dde,""):""}f2.normalizeId=Hf;function Tde(e,t,n){return n=Hf(n),e.resolve(t,n)}f2.resolveUrl=Tde;var Sde=/^[a-z_][-a-z0-9._]*$/i;function Ede(e,t){if(typeof e=="boolean")return{};let{schemaId:n,uriResolver:r}=this.opts,i=Hf(e[n]||t),s={"":i},o=p2(r,i,!1),a={},l=new Set;return vde(e,{allKeys:!0},(p,d,f,m)=>{if(m===void 0)return;let y=o+d,h=s[m];if(typeof p[n]=="string")h=b.call(this,p[n]);g.call(this,p.$anchor),g.call(this,p.$dynamicAnchor),s[d]=h;function b(x){let v=this.opts.uriResolver.resolve;if(x=Hf(h?v(h,x):x),l.has(x))throw u(x);l.add(x);let D=this.refs[x];if(typeof D=="string")D=this.refs[D];if(typeof D=="object")c(p,D.schema,x);else if(x!==Hf(y))if(x[0]==="#")c(p,a[x],x),a[x]=p;else this.refs[x]=y;return x}function g(x){if(typeof x=="string"){if(!Sde.test(x))throw Error(`invalid anchor "${x}"`);b.call(this,`#${x}`)}}}),a;function c(p,d,f){if(d!==void 0&&!bde(p,d))throw u(f)}function u(p){return Error(`reference "${p}" resolves to more than one schema`)}}f2.getSchemaRefs=Ede});var Cp=z(function(O2){Object.defineProperty(O2,"__esModule",{value:!0});O2.getData=O2.KeywordCxt=O2.validateFunctionCode=void 0;var b2=IL(),v2=qh(),Uk=Ik(),$x=qh(),Ide=HL(),Bh=n2(),Bk=o2(),pt=Et(),Dt=vo(),Ade=Uh(),Vl=Kt(),Vh=Lh();function Rde(e){if(w2(e)){if(D2(e),x2(e)){Cde(e);return}}_2(e,()=>b2.topBoolOrEmptySchema(e))}O2.validateFunctionCode=Rde;function _2({gen:e,validateName:t,schema:n,schemaEnv:r,opts:i},s){if(i.code.es5)e.func(t,pt._`${Dt.default.data}, ${Dt.default.valCxt}`,r.$async,()=>{e.code(pt._`"use strict"; ${y2(n,i)}`),Fde(e,i),e.code(s)});else e.func(t,pt._`${Dt.default.data}, ${jde(i)}`,r.$async,()=>e.code(y2(n,i)).code(s))}function jde(e){return pt._`{${Dt.default.instancePath}="", ${Dt.default.parentData}, ${Dt.default.parentDataProperty}, ${Dt.default.rootData}=${Dt.default.data}${e.dynamicRef?pt._`, ${Dt.default.dynamicAnchors}={}`:pt.nil}}={}`}function Fde(e,t){e.if(Dt.default.valCxt,()=>{if(e.var(Dt.default.instancePath,pt._`${Dt.default.valCxt}.${Dt.default.instancePath}`),e.var(Dt.default.parentData,pt._`${Dt.default.valCxt}.${Dt.default.parentData}`),e.var(Dt.default.parentDataProperty,pt._`${Dt.default.valCxt}.${Dt.default.parentDataProperty}`),e.var(Dt.default.rootData,pt._`${Dt.default.valCxt}.${Dt.default.rootData}`),t.dynamicRef)e.var(Dt.default.dynamicAnchors,pt._`${Dt.default.valCxt}.${Dt.default.dynamicAnchors}`)},()=>{if(e.var(Dt.default.instancePath,pt._`""`),e.var(Dt.default.parentData,pt._`undefined`),e.var(Dt.default.parentDataProperty,pt._`undefined`),e.var(Dt.default.rootData,Dt.default.data),t.dynamicRef)e.var(Dt.default.dynamicAnchors,pt._`{}`)})}function Cde(e){let{schema:t,opts:n,gen:r}=e;_2(e,()=>{if(n.$comment&&t.$comment)S2(e);if(Bde(e),r.let(Dt.default.vErrors,null),r.let(Dt.default.errors,0),n.unevaluated)Mde(e);T2(e),Jde(e)});return}function Mde(e){let{gen:t,validateName:n}=e;e.evaluated=t.const("evaluated",pt._`${n}.evaluated`),t.if(pt._`${e.evaluated}.dynamicProps`,()=>t.assign(pt._`${e.evaluated}.props`,pt._`undefined`)),t.if(pt._`${e.evaluated}.dynamicItems`,()=>t.assign(pt._`${e.evaluated}.items`,pt._`undefined`))}function y2(e,t){let n=typeof e=="object"&&e[t.schemaId];return n&&(t.code.source||t.code.process)?pt._`/*# sourceURL=${n} */`:pt.nil}function Lde(e,t){if(w2(e)){if(D2(e),x2(e)){qde(e,t);return}}b2.boolOrEmptySchema(e,t)}function x2({schema:e,self:t}){if(typeof e=="boolean")return!e;for(let n in e)if(t.RULES.all[n])return!0;return!1}function w2(e){return typeof e.schema!="boolean"}function qde(e,t){let{schema:n,gen:r,opts:i}=e;if(i.$comment&&n.$comment)S2(e);Vde(e),Kde(e);let s=r.const("_errs",Dt.default.errors);T2(e,s),r.var(t,pt._`${s} === ${Dt.default.errors}`)}function D2(e){Vl.checkUnknownRules(e),Ude(e)}function T2(e,t){if(e.opts.jtd)return h2(e,[],!1,t);let n=v2.getSchemaTypes(e.schema),r=v2.coerceAndCheckDataType(e,n);h2(e,n,!r,t)}function Ude(e){let{schema:t,errSchemaPath:n,opts:r,self:i}=e;if(t.$ref&&r.ignoreKeywordsWithRef&&Vl.schemaHasRulesButRef(t,i.RULES))i.logger.warn(`$ref: keywords ignored in schema at path "${n}"`)}function Bde(e){let{schema:t,opts:n}=e;if(t.default!==void 0&&n.useDefaults&&n.strictSchema)Vl.checkStrictMode(e,"default is ignored in the schema root")}function Vde(e){let t=e.schema[e.opts.schemaId];if(t)e.baseId=Ade.resolveUrl(e.opts.uriResolver,e.baseId,t)}function Kde(e){if(e.schema.$async&&!e.schemaEnv.$async)throw Error("async schema in sync schema")}function S2({gen:e,schemaEnv:t,schema:n,errSchemaPath:r,opts:i}){let s=n.$comment;if(i.$comment===!0)e.code(pt._`${Dt.default.self}.logger.log(${s})`);else if(typeof i.$comment=="function"){let o=pt.str`${r}/$comment`,a=e.scopeValue("root",{ref:t.root});e.code(pt._`${Dt.default.self}.opts.$comment(${s}, ${o}, ${a}.schema)`)}}function Jde(e){let{gen:t,schemaEnv:n,validateName:r,ValidationError:i,opts:s}=e;if(n.$async)t.if(pt._`${Dt.default.errors} === 0`,()=>t.return(Dt.default.data),()=>t.throw(pt._`new ${i}(${Dt.default.vErrors})`));else{if(t.assign(pt._`${r}.errors`,Dt.default.vErrors),s.unevaluated)Gde(e);t.return(pt._`${Dt.default.errors} === 0`)}}function Gde({gen:e,evaluated:t,props:n,items:r}){if(n instanceof pt.Name)e.assign(pt._`${t}.props`,n);if(r instanceof pt.Name)e.assign(pt._`${t}.items`,r)}function h2(e,t,n,r){let{gen:i,schema:s,data:o,allErrors:a,opts:l,self:c}=e,{RULES:u}=c;if(s.$ref&&(l.ignoreKeywordsWithRef||!Vl.schemaHasRulesButRef(s,u))){i.block(()=>k2(e,"$ref",u.all.$ref.definition));return}if(!l.jtd)Hde(e,t);i.block(()=>{for(let d of u.rules)p(d);p(u.post)});function p(d){if(!Uk.shouldUseGroup(s,d))return;if(d.type){if(i.if($x.checkDataType(d.type,o,l.strictNumbers)),g2(e,d),t.length===1&&t[0]===d.type&&n)i.else(),$x.reportTypeError(e);i.endIf()}else g2(e,d);if(!a)i.if(pt._`${Dt.default.errors} === ${r||0}`)}}function g2(e,t){let{gen:n,schema:r,opts:{useDefaults:i}}=e;if(i)Ide.assignDefaults(e,t.type);n.block(()=>{for(let s of t.rules)if(Uk.shouldUseRule(r,s))k2(e,s.keyword,s.definition,t.type)})}function Hde(e,t){if(e.schemaEnv.meta||!e.opts.strictTypes)return;if(zde(e,t),!e.opts.allowUnionTypes)Wde(e,t);Qde(e,e.dataTypes)}function zde(e,t){if(!t.length)return;if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach((n)=>{if(!E2(e.dataTypes,n))Vk(e,`type "${n}" not allowed by context "${e.dataTypes.join(",")}"`)}),Xde(e,t)}function Wde(e,t){if(t.length>1&&!(t.length===2&&t.includes("null")))Vk(e,"use allowUnionTypes to allow union type keyword")}function Qde(e,t){let n=e.self.RULES.all;for(let r in n){let i=n[r];if(typeof i=="object"&&Uk.shouldUseRule(e.schema,i)){let{type:s}=i.definition;if(s.length&&!s.some((o)=>Yde(t,o)))Vk(e,`missing type "${s.join(",")}" for keyword "${r}"`)}}}function Yde(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}function E2(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}function Xde(e,t){let n=[];for(let r of e.dataTypes)if(E2(t,r))n.push(r);else if(t.includes("integer")&&r==="number")n.push("integer");e.dataTypes=n}function Vk(e,t){let n=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${n}" (strictTypes)`,Vl.checkStrictMode(e,t,e.opts.strictTypes)}class Kk{constructor(e,t,n){if(Bh.validateKeywordUsage(e,t,n),this.gen=e.gen,this.allErrors=e.allErrors,this.keyword=n,this.data=e.data,this.schema=e.schema[n],this.$data=t.$data&&e.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=Vl.schemaRefOrVal(e,this.schema,n,this.$data),this.schemaType=t.schemaType,this.parentSchema=e.schema,this.params={},this.it=e,this.def=t,this.$data)this.schemaCode=e.gen.const("vSchema",N2(this.$data,e));else if(this.schemaCode=this.schemaValue,!Bh.validSchemaType(this.schema,t.schemaType,t.allowUndefined))throw Error(`${n} value must be ${JSON.stringify(t.schemaType)}`);if("code"in t?t.trackErrors:t.errors!==!1)this.errsCount=e.gen.const("_errs",Dt.default.errors)}result(e,t,n){this.failResult(pt.not(e),t,n)}failResult(e,t,n){if(this.gen.if(e),n)n();else this.error();if(t){if(this.gen.else(),t(),this.allErrors)this.gen.endIf()}else if(this.allErrors)this.gen.endIf();else this.gen.else()}pass(e,t){this.failResult(pt.not(e),void 0,t)}fail(e){if(e===void 0){if(this.error(),!this.allErrors)this.gen.if(!1);return}if(this.gen.if(e),this.error(),this.allErrors)this.gen.endIf();else this.gen.else()}fail$data(e){if(!this.$data)return this.fail(e);let{schemaCode:t}=this;this.fail(pt._`${t} !== undefined && (${pt.or(this.invalid$data(),e)})`)}error(e,t,n){if(t){this.setParams(t),this._error(e,n),this.setParams({});return}this._error(e,n)}_error(e,t){(e?Vh.reportExtraError:Vh.reportError)(this,this.def.error,t)}$dataError(){Vh.reportError(this,this.def.$dataError||Vh.keyword$DataError)}reset(){if(this.errsCount===void 0)throw Error('add "trackErrors" to keyword definition');Vh.resetErrorsCount(this.gen,this.errsCount)}ok(e){if(!this.allErrors)this.gen.if(e)}setParams(e,t){if(t)Object.assign(this.params,e);else this.params=e}block$data(e,t,n=pt.nil){this.gen.block(()=>{this.check$data(e,n),t()})}check$data(e=pt.nil,t=pt.nil){if(!this.$data)return;let{gen:n,schemaCode:r,schemaType:i,def:s}=this;if(n.if(pt.or(pt._`${r} === undefined`,t)),e!==pt.nil)n.assign(e,!0);if(i.length||s.validateSchema){if(n.elseIf(this.invalid$data()),this.$dataError(),e!==pt.nil)n.assign(e,!1)}n.else()}invalid$data(){let{gen:e,schemaCode:t,schemaType:n,def:r,it:i}=this;return pt.or(s(),o());function s(){if(n.length){if(!(t instanceof pt.Name))throw Error("ajv implementation error");let a=Array.isArray(n)?n:[n];return pt._`${$x.checkDataTypes(a,t,i.opts.strictNumbers,$x.DataType.Wrong)}`}return pt.nil}function o(){if(r.validateSchema){let a=e.scopeValue("validate$data",{ref:r.validateSchema});return pt._`!${a}(${t})`}return pt.nil}}subschema(e,t){let n=Bk.getSubschema(this.it,e);Bk.extendSubschemaData(n,this.it,e),Bk.extendSubschemaMode(n,e);let r={...this.it,...n,items:void 0,props:void 0};return Lde(r,t),r}mergeEvaluated(e,t){let{it:n,gen:r}=this;if(!n.opts.unevaluated)return;if(n.props!==!0&&e.props!==void 0)n.props=Vl.mergeEvaluated.props(r,e.props,n.props,t);if(n.items!==!0&&e.items!==void 0)n.items=Vl.mergeEvaluated.items(r,e.items,n.items,t)}mergeValidEvaluated(e,t){let{it:n,gen:r}=this;if(n.opts.unevaluated&&(n.props!==!0||n.items!==!0))return r.if(t,()=>this.mergeEvaluated(e,pt.Name)),!0}}O2.KeywordCxt=Kk;function k2(e,t,n,r){let i=new Kk(e,n,t);if("code"in n)n.code(i,r);else if(i.$data&&n.validate)Bh.funcKeywordCode(i,n);else if("macro"in n)Bh.macroKeywordCode(i,n);else if(n.compile||n.validate)Bh.funcKeywordCode(i,n)}var Zde=/^\/(?:[^~]|~0|~1)*$/,efe=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function N2(e,{dataLevel:t,dataNames:n,dataPathArr:r}){let i,s;if(e==="")return Dt.default.rootData;if(e[0]==="/"){if(!Zde.test(e))throw Error(`Invalid JSON-pointer: ${e}`);i=e,s=Dt.default.rootData}else{let c=efe.exec(e);if(!c)throw Error(`Invalid JSON-pointer: ${e}`);let u=+c[1];if(i=c[2],i==="#"){if(u>=t)throw Error(l("property/index",u));return r[t-u]}if(u>t)throw Error(l("data",u));if(s=n[t-u],!i)return s}let o=s,a=i.split("/");for(let c of a)if(c)s=pt._`${s}${pt.getProperty(Vl.unescapeJsonPointer(c))}`,o=pt._`${o} && ${s}`;return o;function l(c,u){return`Cannot access ${c} ${u} levels up, current level is ${t}`}}O2.getData=N2});var zf=z(function(I2){Object.defineProperty(I2,"__esModule",{value:!0});class $2 extends Error{constructor(e){super("validation failed");this.errors=e,this.ajv=this.validation=!0}}I2.default=$2});var Mp=z(function(R2){Object.defineProperty(R2,"__esModule",{value:!0});var Jk=Uh();class A2 extends Error{constructor(e,t,n,r){super(r||`can't resolve reference ${n} from id ${t}`);this.missingRef=Jk.resolveUrl(e,t,n),this.missingSchema=Jk.normalizeId(Jk.getFullPath(e,this.missingRef))}}R2.default=A2});var Jh=z(function(C2){Object.defineProperty(C2,"__esModule",{value:!0});C2.resolveSchema=C2.getCompilingSchema=C2.resolveRef=C2.compileSchema=C2.SchemaEnv=void 0;var fa=Et(),sfe=zf(),Lp=vo(),ma=Uh(),j2=Kt(),ofe=Cp();class Kh{constructor(e){var t;this.refs={},this.dynamicAnchors={};let n;if(typeof e.schema=="object")n=e.schema;this.schema=e.schema,this.schemaId=e.schemaId,this.root=e.root||this,this.baseId=(t=e.baseId)!==null&&t!==void 0?t:ma.normalizeId(n===null||n===void 0?void 0:n[e.schemaId||"$id"]),this.schemaPath=e.schemaPath,this.localRefs=e.localRefs,this.meta=e.meta,this.$async=n===null||n===void 0?void 0:n.$async,this.refs={}}}C2.SchemaEnv=Kh;function Hk(e){let t=F2.call(this,e);if(t)return t;let n=ma.getFullPath(this.opts.uriResolver,e.root.baseId),{es5:r,lines:i}=this.opts.code,{ownProperties:s}=this.opts,o=new fa.CodeGen(this.scope,{es5:r,lines:i,ownProperties:s}),a;if(e.$async)a=o.scopeValue("Error",{ref:sfe.default,code:fa._`require("ajv/dist/runtime/validation_error").default`});let l=o.scopeName("validate");e.validateName=l;let c={gen:o,allErrors:this.opts.allErrors,data:Lp.default.data,parentData:Lp.default.parentData,parentDataProperty:Lp.default.parentDataProperty,dataNames:[Lp.default.data],dataPathArr:[fa.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:o.scopeValue("schema",this.opts.code.source===!0?{ref:e.schema,code:fa.stringify(e.schema)}:{ref:e.schema}),validateName:l,ValidationError:a,schema:e.schema,schemaEnv:e,rootId:n,baseId:e.baseId||n,schemaPath:fa.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:fa._`""`,opts:this.opts,self:this},u;try{this._compilations.add(e),ofe.validateFunctionCode(c),o.optimize(this.opts.code.optimize);let p=o.toString();if(u=`${o.scopeRefs(Lp.default.scope)}return ${p}`,this.opts.code.process)u=this.opts.code.process(u,e);let f=Function(`${Lp.default.self}`,`${Lp.default.scope}`,u)(this,this.scope.get());if(this.scope.value(l,{ref:f}),f.errors=null,f.schema=e.schema,f.schemaEnv=e,e.$async)f.$async=!0;if(this.opts.code.source===!0)f.source={validateName:l,validateCode:p,scopeValues:o._values};if(this.opts.unevaluated){let{props:m,items:y}=c;if(f.evaluated={props:m instanceof fa.Name?void 0:m,items:y instanceof fa.Name?void 0:y,dynamicProps:m instanceof fa.Name,dynamicItems:y instanceof fa.Name},f.source)f.source.evaluated=fa.stringify(f.evaluated)}return e.validate=f,e}catch(p){if(delete e.validate,delete e.validateName,u)this.logger.error("Error compiling schema, function code:",u);throw p}finally{this._compilations.delete(e)}}C2.compileSchema=Hk;function afe(e,t,n){var r;n=ma.resolveUrl(this.opts.uriResolver,t,n);let i=e.refs[n];if(i)return i;let s=ufe.call(this,e,n);if(s===void 0){let o=(r=e.localRefs)===null||r===void 0?void 0:r[n],{schemaId:a}=this.opts;if(o)s=new Kh({schema:o,schemaId:a,root:e,baseId:t})}if(s===void 0)return;return e.refs[n]=lfe.call(this,s)}C2.resolveRef=afe;function lfe(e){if(ma.inlineRef(e.schema,this.opts.inlineRefs))return e.schema;return e.validate?e:Hk.call(this,e)}function F2(e){for(let t of this._compilations)if(cfe(t,e))return t}C2.getCompilingSchema=F2;function cfe(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function ufe(e,t){let n;while(typeof(n=this.refs[t])=="string")t=n;return n||this.schemas[t]||Ix.call(this,e,t)}function Ix(e,t){let n=this.opts.uriResolver.parse(t),r=ma._getFullPath(this.opts.uriResolver,n),i=ma.getFullPath(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&r===i)return Gk.call(this,n,e);let s=ma.normalizeId(r),o=this.refs[s]||this.schemas[s];if(typeof o=="string"){let a=Ix.call(this,e,o);if(typeof(a===null||a===void 0?void 0:a.schema)!=="object")return;return Gk.call(this,n,a)}if(typeof(o===null||o===void 0?void 0:o.schema)!=="object")return;if(!o.validate)Hk.call(this,o);if(s===ma.normalizeId(t)){let{schema:a}=o,{schemaId:l}=this.opts,c=a[l];if(c)i=ma.resolveUrl(this.opts.uriResolver,i,c);return new Kh({schema:a,schemaId:l,root:e,baseId:i})}return Gk.call(this,n,o)}C2.resolveSchema=Ix;var pfe=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function Gk(e,{baseId:t,schema:n,root:r}){var i;if(((i=e.fragment)===null||i===void 0?void 0:i[0])!=="/")return;for(let a of e.fragment.slice(1).split("/")){if(typeof n==="boolean")return;let l=n[j2.unescapeFragment(a)];if(l===void 0)return;n=l;let c=typeof n==="object"&&n[this.opts.schemaId];if(!pfe.has(a)&&c)t=ma.resolveUrl(this.opts.uriResolver,t,c)}let s;if(typeof n!="boolean"&&n.$ref&&!j2.schemaHasRulesButRef(n,this.RULES)){let a=ma.resolveUrl(this.opts.uriResolver,t,n.$ref);s=Ix.call(this,r,a)}let{schemaId:o}=this.opts;if(s=s||new Kh({schema:n,schemaId:o,root:r,baseId:t}),s.schema!==s.root.schema)return s;return}});var L2=z(function(iGe,hfe){hfe.exports={$id:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON AnySchema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:!1}});var Zk=z(function(sGe,G2){var gfe=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),Wk=RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u),bfe=RegExp.prototype.test.bind(/^\d*$/u),qp=RegExp.prototype.test.bind(/^[\da-f]{2}$/iu),Qk=RegExp.prototype.test.bind(/^[\da-z\-._~]$/iu),U2=RegExp.prototype.test.bind(/^[A-Za-z0-9\-._~!$&'()*+,;=:@/]$/u),Yk=RegExp.prototype.test.bind(/^[A-Za-z0-9\-._~!$&'()*+,;=:@/?]$/u),vfe=RegExp.prototype.test.bind(/^[A-Za-z0-9\-._~!$&'()*+,;=:]$/u),ps=Array(256);for(let t=0;t<256;t++)ps[t]="%"+"0123456789ABCDEF"[t>>4]+"0123456789ABCDEF"[t&15];function Di(e){if(e<2048)return ps[192|e>>6]+ps[128|e&63];if(e<65536)return ps[224|e>>12]+ps[128|e>>6&63]+ps[128|e&63];return ps[240|e>>18]+ps[128|e>>12&63]+ps[128|e>>6&63]+ps[128|e&63]}function _fe(e){let t="",n=0,r=0;for(r=0;r=48&&n<=57||n>=65&&n<=70||n>=97&&n<=102))return"";t+=e[r];break}for(r+=1;r=48&&n<=57||n>=65&&n<=70||n>=97&&n<=102))return"";t+=e[r]}return t}var xfe=RegExp.prototype.test.bind(/^[\dA-Fa-f]{1,4}$/),wfe=RegExp.prototype.test.bind(/^[vV][\dA-Fa-f]+\.[A-Za-z\d\-._~!$&'()*+,;=:]+$/),Dfe=RegExp.prototype.test.bind(/^[A-Za-z\d\-._~]$/),Tfe=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function Sfe(e){if(e.length===0)return!1;for(let t=0;tn)n=i,t=r}else r=-1,i=0;if(n<2)return e.join(":");let s=e.slice(0,t).join(":"),o=e.slice(t+n).join(":");return s+"::"+o}function Efe(e){let t=e.indexOf("::");if(t!==-1&&e.indexOf("::",t+1)!==-1)return;let n=t===-1?e.split(":"):e.slice(0,t).split(":"),r=t===-1?[]:e.slice(t+2).split(":");if(t!==-1){if(n.length===1&&n[0]==="")n.length=0;if(r.length===1&&r[0]==="")r.length=0}let i=n.concat(r),s=0;for(let a=0;a=8)return;let o=i.slice(0,n.length);for(let a=s;a<8;a++)o.push("0");for(let a=n.length;aOfe[r])}function V2(e,t=!1){if(e.indexOf("%")===-1)return e;let n="";for(let r=0;r57343)t+=Di(i);else if(i<=56319&&n+1=56320&&s<=57343)t+=Di(65536+(i-55296<<10)+(s-56320)),n++;else t+=Di(65533)}else t+=Di(65533)}}return t}function Afe(e,t=!1){let n="",r=t&&e[0]!=="/";for(let i=0;i57343)n+=Di(o);else if(o<=56319&&i+1=56320&&a<=57343)n+=Di(65536+(o-55296<<10)+(a-56320)),i++;else n+=Di(65533)}else n+=Di(65533)}}return n}function Xk(e,t){let n="";for(let r=0;r57343)n+=Di(s);else if(s<=56319&&r+1=56320&&o<=57343)n+=Di(65536+(s-55296<<10)+(o-56320)),r++;else n+=Di(65533)}else n+=Di(65533)}}return n}function K2(e){return Xk(e,vfe)}function Rfe(e){return Xk(e,Yk)}function jfe(e){return Xk(e,Yk)}function J2(e){return e>=48&&e<=57||e>=65&&e<=90||e>=97&&e<=122||e===42||e===43||e===45||e===46||e===47||e===64||e===95}function Ffe(e){let t="";for(let n=0;n57343)t+=Di(i);else if(i<=56319&&n+1=56320&&s<=57343)t+=Di(65536+(i-55296<<10)+(s-56320)),n++;else t+=Di(65533)}else t+=Di(65533)}}return t}function Cfe(e){let t="";for(let n=0;n65535))return"URI port is malformed.";return}function Gh(e){if(e===void 0)return!1;let t=e.indexOf("%");while(t!==-1){if(t+2>=e.length||!/^[\da-f]{2}$/iu.test(e.slice(t+1,t+3)))return!0;t=e.indexOf("%",t+3)}return!1}function i1(e){return e[0]==="["&&e[e.length-1]==="]"}function dme(e){let t=e[4];return Gh(e[3])||t!==void 0&&!i1(t)&&Gh(t)||Gh(e[6])||Gh(e[7])||Gh(e[8])}function aq(e,t,n,r){if(!t.unicodeSupport&&(!n||!n.unicodeSupport)&&e.host&&!i1(e.host)&&(t.domainHost||n&&n.domainHost)&&r===!1&&ime(e.host))try{e.host=new URL("http://"+e.host).hostname}catch(i){return e.error=e.error||"Host's domain name can not be converted to ASCII: "+i,!0}return!1}function jx(e,t){let n=Object.assign({},t),r={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},i=!1,s=!1,o=!1,a=!1,l=!1,c=!1,u=!1;if(n.reference==="suffix")if(n.scheme)e=n.scheme+":"+e;else e="//"+e;let p=e.match(cme);if(p!==null&&p[1].indexOf("\\")!==-1)r.error="URI authority must not contain a literal backslash.",i=!0;let d=e.match(ume);if(d!==null){let m=d[1],y=m.replace(/[\t\n\r]/g,"");if(y.length>=2){if(y.slice(0,2)!=="//")r.error=r.error||"URI authority must not contain a literal backslash.",i=!0;else if(m.length!==y.length)r.error=r.error||"URI authority introducer must not contain whitespace.",i=!0}}let f=e.match(lme);if(f){if(r.scheme=f[1],r.userinfo=f[3],r.host=f[4],r.port=parseInt(f[5],10),r.path=f[6]||"",r.query=f[7],r.fragment=f[8],r.scheme!==void 0){let h=unescape(r.scheme);if(sq.test(h))r.scheme=h.toLowerCase();else r.error=r.error||"URI scheme is malformed.",c=!0}if(s=dme(f),s)r.error=r.error||"URI contains malformed percent-encoding.";if(isNaN(r.port))r.port=f[5];let m=pme(r,f);if(m!==void 0)r.error=r.error||m,i=!0;if(r.host)if(rq(r.host)===!1){let b=i1(r.host),g=r.host.indexOf("[")!==-1||r.host.indexOf("]")!==-1,x=nq(r.host);if(u=x.isIPV6||x.isIPVFuture===!0,l=g&&(!b||x.error===!0),r.host=u?x.host:x.host.toLowerCase(),l)r.error=r.error||"URI host is malformed.",i=!0}else u=!0;if(r.scheme===void 0&&r.userinfo===void 0&&r.host===void 0&&r.port===void 0&&r.query===void 0&&!r.path)r.reference="same-document";else if(r.scheme===void 0)r.reference="relative";else if(r.fragment===void 0)r.reference="absolute";else r.reference="uri";if(n.reference&&n.reference!=="suffix"&&n.reference!==r.reference)r.error=r.error||"URI is not a "+n.reference+" reference.";let y=r1(n.scheme||r.scheme);if(!l)a=aq(r,n,y,u);if(e.indexOf("%")!==-1&&r.host!==void 0&&!l){let h=u?r.host:n1(r.host,!0);if(!u)h=n1(h.toLowerCase());r.host=rme(h,u)}if(!y||y&&!y.skipNormalize){if(r.path)r.path=eme(r.path);if(r.query)r.query=Z2(r.query);if(r.fragment)r.fragment=Z2(r.fragment)}if(y&&y.parse){if(y.parse(r,n),y===iq.urn&&r.nid===void 0)o=!0}}else r.error=r.error||"URI can not be parsed.";return{parsed:r,malformedAuthorityOrPort:i,malformedPercentEncoding:s,malformedSchemeSpecific:o,malformedHost:a,malformedScheme:c}}function Fx(e,t){return jx(e,t).parsed}function fme(e,t){return lq(e,t).normalized}function lq(e,t){let{parsed:n,malformedAuthorityOrPort:r,malformedPercentEncoding:i,malformedSchemeSpecific:s,malformedHost:o,malformedScheme:a}=jx(e,t);return{normalized:r||i||s||o||a?e:Up(n,t),malformedAuthorityOrPort:r,malformedPercentEncoding:i,malformedSchemeSpecific:s,malformedHost:o,malformedScheme:a}}function tq(e,t){if(typeof e!=="string"&&typeof e!=="object")return;let n;try{n=typeof e==="string"?e:Up(e,t)}catch{return}let{normalized:r,malformedAuthorityOrPort:i,malformedPercentEncoding:s,malformedSchemeSpecific:o,malformedHost:a,malformedScheme:l}=lq(n,t);return i||s||o||a||l?void 0:r}var s1={SCHEMES:iq,normalize:sme,resolve:ome,resolveComponent:oq,equal:ame,serialize:Up,parse:Fx};Cx.exports=s1;Cx.exports.default=s1;Cx.exports.fastUri=s1});var dq=z(function(pq){Object.defineProperty(pq,"__esModule",{value:!0});var uq=cq();uq.code='require("ajv/dist/runtime/uri").default';pq.default=uq});var lu=z(function(Kl){Object.defineProperty(Kl,"__esModule",{value:!0});Kl.CodeGen=Kl.Name=Kl.nil=Kl.stringify=Kl.str=Kl._=Kl.KeywordCxt=void 0;var yme=Cp();Object.defineProperty(Kl,"KeywordCxt",{enumerable:!0,get:function(){return yme.KeywordCxt}});var Wf=Et();Object.defineProperty(Kl,"_",{enumerable:!0,get:function(){return Wf._}});Object.defineProperty(Kl,"str",{enumerable:!0,get:function(){return Wf.str}});Object.defineProperty(Kl,"stringify",{enumerable:!0,get:function(){return Wf.stringify}});Object.defineProperty(Kl,"nil",{enumerable:!0,get:function(){return Wf.nil}});Object.defineProperty(Kl,"Name",{enumerable:!0,get:function(){return Wf.Name}});Object.defineProperty(Kl,"CodeGen",{enumerable:!0,get:function(){return Wf.CodeGen}});var hme=zf(),gq=Mp(),gme=$k(),Wh=Jh(),bme=Et(),zh=Uh(),Mx=qh(),a1=Kt(),fq=L2(),vme=dq(),bq=(e,t)=>new RegExp(e,t);bq.code="new RegExp";var _me=["removeAdditional","useDefaults","coerceTypes"],xme=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),wme={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},Dme={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},mq=200;function Tme(e){var t,n,r,i,s,o,a,l,c,u,p,d,f,m,y,h,b,g,x,v,D,T,N,O,C;let X=e.strict,te=(t=e.code)===null||t===void 0?void 0:t.optimize,L=te===!0||te===void 0?1:te||0,Y=(r=(n=e.code)===null||n===void 0?void 0:n.regExp)!==null&&r!==void 0?r:bq,me=(i=e.uriResolver)!==null&&i!==void 0?i:vme.default;return{strictSchema:(o=(s=e.strictSchema)!==null&&s!==void 0?s:X)!==null&&o!==void 0?o:!0,strictNumbers:(l=(a=e.strictNumbers)!==null&&a!==void 0?a:X)!==null&&l!==void 0?l:!0,strictTypes:(u=(c=e.strictTypes)!==null&&c!==void 0?c:X)!==null&&u!==void 0?u:"log",strictTuples:(d=(p=e.strictTuples)!==null&&p!==void 0?p:X)!==null&&d!==void 0?d:"log",strictRequired:(m=(f=e.strictRequired)!==null&&f!==void 0?f:X)!==null&&m!==void 0?m:!1,code:e.code?{...e.code,optimize:L,regExp:Y}:{optimize:L,regExp:Y},loopRequired:(y=e.loopRequired)!==null&&y!==void 0?y:mq,loopEnum:(h=e.loopEnum)!==null&&h!==void 0?h:mq,meta:(b=e.meta)!==null&&b!==void 0?b:!0,messages:(g=e.messages)!==null&&g!==void 0?g:!0,inlineRefs:(x=e.inlineRefs)!==null&&x!==void 0?x:!0,schemaId:(v=e.schemaId)!==null&&v!==void 0?v:"$id",addUsedSchema:(D=e.addUsedSchema)!==null&&D!==void 0?D:!0,validateSchema:(T=e.validateSchema)!==null&&T!==void 0?T:!0,validateFormats:(N=e.validateFormats)!==null&&N!==void 0?N:!0,unicodeRegExp:(O=e.unicodeRegExp)!==null&&O!==void 0?O:!0,int32range:(C=e.int32range)!==null&&C!==void 0?C:!0,uriResolver:me}}class Lx{constructor(e={}){this.schemas={},this.refs={},this.formats=Object.create(null),this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts={...e,...Tme(e)};let{es5:t,lines:n}=this.opts.code;this.scope=new bme.ValueScope({scope:{},prefixes:xme,es5:t,lines:n}),this.logger=Pme(e.logger);let r=e.validateFormats;if(e.validateFormats=!1,this.RULES=gme.getRules(),yq.call(this,wme,e,"NOT SUPPORTED"),yq.call(this,Dme,e,"DEPRECATED","warn"),this._metaOpts=Nme.call(this),e.formats)Eme.call(this);if(this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords)kme.call(this,e.keywords);if(typeof e.meta=="object")this.addMetaSchema(e.meta);Sme.call(this),e.validateFormats=r}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:e,meta:t,schemaId:n}=this.opts,r=fq;if(n==="id")r={...fq},r.id=r.$id,delete r.$id;if(t&&e)this.addMetaSchema(r,r[n],!1)}defaultMeta(){let{meta:e,schemaId:t}=this.opts;return this.opts.defaultMeta=typeof e=="object"?e[t]||e:void 0}validate(e,t){let n;if(typeof e=="string"){if(n=this.getSchema(e),!n)throw Error(`no schema with key or ref "${e}"`)}else n=this.compile(e);let r=n(t);if(!("$async"in n))this.errors=n.errors;return r}compile(e,t){let n=this._addSchema(e,t);return n.validate||this._compileSchemaEnv(n)}compileAsync(e,t){if(typeof this.opts.loadSchema!="function")throw Error("options.loadSchema should be a function");let{loadSchema:n}=this.opts;return r.call(this,e,t);async function r(c,u){await i.call(this,c.$schema);let p=this._addSchema(c,u);return p.validate||s.call(this,p)}async function i(c){if(c&&!this.getSchema(c))await r.call(this,{$ref:c},!0)}async function s(c){try{return this._compileSchemaEnv(c)}catch(u){if(!(u instanceof gq.default))throw u;return o.call(this,u),await a.call(this,u.missingSchema),s.call(this,c)}}function o({missingSchema:c,missingRef:u}){if(this.refs[c])throw Error(`AnySchema ${c} is loaded but ${u} cannot be resolved`)}async function a(c){let u=await l.call(this,c);if(!this.refs[c])await i.call(this,u.$schema);if(!this.refs[c])this.addSchema(u,c,t)}async function l(c){let u=this._loading[c];if(u)return u;try{return await(this._loading[c]=n(c))}finally{delete this._loading[c]}}}addSchema(e,t,n,r=this.opts.validateSchema){if(Array.isArray(e)){for(let s of e)this.addSchema(s,void 0,n,r);return this}let i;if(typeof e==="object"){let{schemaId:s}=this.opts;if(i=e[s],i!==void 0&&typeof i!="string")throw Error(`schema ${s} must be string`)}return t=zh.normalizeId(t||i),this._checkUnique(t),this.schemas[t]=this._addSchema(e,n,t,r,!0),this}addMetaSchema(e,t,n=this.opts.validateSchema){return this.addSchema(e,t,!0,n),this}validateSchema(e,t){if(typeof e=="boolean")return!0;let n;if(n=e.$schema,n!==void 0&&typeof n!="string")throw Error("$schema must be a string");if(n=n||this.opts.defaultMeta||this.defaultMeta(),!n)return this.logger.warn("meta-schema not available"),this.errors=null,!0;let r=this.validate(n,e);if(!r&&t){let i="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(i);else throw Error(i)}return r}getSchema(e){let t;while(typeof(t=hq.call(this,e))=="string")e=t;if(t===void 0){let{schemaId:n}=this.opts,r=new Wh.SchemaEnv({schema:{},schemaId:n});if(t=Wh.resolveSchema.call(this,r,e),!t)return;this.refs[e]=t}return t.validate||this._compileSchemaEnv(t)}removeSchema(e){if(e instanceof RegExp)return this._removeAllSchemas(this.schemas,e),this._removeAllSchemas(this.refs,e),this;switch(typeof e){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{let t=hq.call(this,e);if(typeof t=="object")this._cache.delete(t.schema);return delete this.schemas[e],delete this.refs[e],this}case"object":{let t=e;this._cache.delete(t);let n=e[this.opts.schemaId];if(n)n=zh.normalizeId(n),delete this.schemas[n],delete this.refs[n];return this}default:throw Error("ajv.removeSchema: invalid parameter")}}addVocabulary(e){for(let t of e)this.addKeyword(t);return this}addKeyword(e,t){let n;if(typeof e=="string"){if(n=e,typeof t=="object")this.logger.warn("these parameters are deprecated, see docs for addKeyword"),t.keyword=n}else if(typeof e=="object"&&t===void 0){if(t=e,n=t.keyword,Array.isArray(n)&&!n.length)throw Error("addKeywords: keyword must be string or non-empty array")}else throw Error("invalid addKeywords parameters");if(Ime.call(this,n,t),!t)return a1.eachItem(n,(i)=>o1.call(this,i)),this;Rme.call(this,t);let r={...t,type:Mx.getJSONTypes(t.type),schemaType:Mx.getJSONTypes(t.schemaType)};return a1.eachItem(n,r.type.length===0?(i)=>o1.call(this,i,r):(i)=>r.type.forEach((s)=>o1.call(this,i,r,s))),this}getKeyword(e){let t=this.RULES.all[e];return typeof t=="object"?t.definition:!!t}removeKeyword(e){let{RULES:t}=this;delete t.keywords[e],delete t.all[e];for(let n of t.rules){let r=n.rules.findIndex((i)=>i.keyword===e);if(r>=0)n.rules.splice(r,1)}return this}addFormat(e,t){if(typeof t=="string")t=new RegExp(t);return this.formats[e]=t,this}errorsText(e=this.errors,{separator:t=", ",dataVar:n="data"}={}){if(!e||e.length===0)return"No errors";return e.map((r)=>`${n}${r.instancePath} ${r.message}`).reduce((r,i)=>r+t+i)}$dataMetaSchema(e,t){let n=this.RULES.all;e=JSON.parse(JSON.stringify(e));for(let r of t){let i=r.split("/").slice(1),s=e;for(let o of i)s=s[o];for(let o in n){let a=n[o];if(typeof a!="object")continue;let{$data:l}=a.definition,c=s[o];if(l&&c)s[o]=vq(c)}}return e}_removeAllSchemas(e,t){for(let n in e){let r=e[n];if(!t||t.test(n)){if(typeof r=="string")delete e[n];else if(r&&!r.meta)this._cache.delete(r.schema),delete e[n]}}}_addSchema(e,t,n,r=this.opts.validateSchema,i=this.opts.addUsedSchema){let s,{schemaId:o}=this.opts;if(typeof e=="object")s=e[o];else if(this.opts.jtd)throw Error("schema must be object");else if(typeof e!="boolean")throw Error("schema must be object or boolean");let a=this._cache.get(e);if(a!==void 0)return a;n=zh.normalizeId(s||n);let l=zh.getSchemaRefs.call(this,e,n);if(a=new Wh.SchemaEnv({schema:e,schemaId:o,meta:t,baseId:n,localRefs:l}),this._cache.set(a.schema,a),i&&!n.startsWith("#")){if(n)this._checkUnique(n);this.refs[n]=a}if(r)this.validateSchema(e,!0);return a}_checkUnique(e){if(this.schemas[e]||this.refs[e])throw Error(`schema with key or id "${e}" already exists`)}_compileSchemaEnv(e){if(e.meta)this._compileMetaSchema(e);else Wh.compileSchema.call(this,e);if(!e.validate)throw Error("ajv implementation error");return e.validate}_compileMetaSchema(e){let t=this.opts;this.opts=this._metaOpts;try{Wh.compileSchema.call(this,e)}finally{this.opts=t}}}Lx.ValidationError=hme.default;Lx.MissingRefError=gq.default;Kl.default=Lx;function yq(e,t,n,r="error"){for(let i in e){let s=i;if(s in t)this.logger[r](`${n}: option ${i}. ${e[s]}`)}}function hq(e){return e=zh.normalizeId(e),this.schemas[e]||this.refs[e]}function Sme(){let e=this.opts.schemas;if(!e)return;if(Array.isArray(e))this.addSchema(e);else for(let t in e)this.addSchema(e[t],t)}function Eme(){for(let e in this.opts.formats){let t=this.opts.formats[e];if(t)this.addFormat(e,t)}}function kme(e){if(Array.isArray(e)){this.addVocabulary(e);return}this.logger.warn("keywords option as map is deprecated, pass array");for(let t in e){let n=e[t];if(!n.keyword)n.keyword=t;this.addKeyword(n)}}function Nme(){let e={...this.opts};for(let t of _me)delete e[t];return e}var Ome={log(){},warn(){},error(){}};function Pme(e){if(e===!1)return Ome;if(e===void 0)return console;if(e.log&&e.warn&&e.error)return e;throw Error("logger must implement log, warn and error methods")}var $me=/^[a-z_$][a-z0-9_$:-]*$/i;function Ime(e,t){let{RULES:n}=this;if(a1.eachItem(e,(r)=>{if(n.keywords[r])throw Error(`Keyword ${r} is already defined`);if(!$me.test(r))throw Error(`Keyword ${r} has invalid name`)}),!t)return;if(t.$data&&!(("code"in t)||("validate"in t)))throw Error('$data keyword must have "code" or "validate" function')}function o1(e,t,n){var r;let i=t===null||t===void 0?void 0:t.post;if(n&&i)throw Error('keyword with "post" flag cannot have "type"');let{RULES:s}=this,o=i?s.post:s.rules.find(({type:l})=>l===n);if(!o)o={type:n,rules:[]},s.rules.push(o);if(s.keywords[e]=!0,!t)return;let a={keyword:e,definition:{...t,type:Mx.getJSONTypes(t.type),schemaType:Mx.getJSONTypes(t.schemaType)}};if(t.before)Ame.call(this,o,a,t.before);else o.rules.push(a);s.all[e]=a,(r=t.implements)===null||r===void 0||r.forEach((l)=>this.addKeyword(l))}function Ame(e,t,n){let r=e.rules.findIndex((i)=>i.keyword===n);if(r>=0)e.rules.splice(r,0,t);else e.rules.push(t),this.logger.warn(`rule ${n} is not defined`)}function Rme(e){let{metaSchema:t}=e;if(t===void 0)return;if(e.$data&&this.opts.$data)t=vq(t);e.validateSchema=this.compile(t,!0)}var jme={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function vq(e){return{anyOf:[e,jme]}}});var xq=z(function(_q){Object.defineProperty(_q,"__esModule",{value:!0});var Mme={keyword:"id",code(){throw Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};_q.default=Mme});var Qh=z(function(Sq){Object.defineProperty(Sq,"__esModule",{value:!0});Sq.callRef=Sq.getValidate=void 0;var qme=Mp(),wq=_o(),ds=Et(),Qf=vo(),Dq=Jh(),qx=Kt(),Ume={keyword:"$ref",schemaType:"string",code(e){let{gen:t,schema:n,it:r}=e,{baseId:i,schemaEnv:s,validateName:o,opts:a,self:l}=r,{root:c}=s;if((n==="#"||n==="#/")&&i===c.baseId)return p();let u=Dq.resolveRef.call(l,c,i,n);if(u===void 0)throw new qme.default(r.opts.uriResolver,i,n);if(u instanceof Dq.SchemaEnv)return d(u);return f(u);function p(){if(s===c)return Ux(e,o,s,s.$async);let m=t.scopeValue("root",{ref:c});return Ux(e,ds._`${m}.validate`,c,c.$async)}function d(m){let y=Tq(e,m);Ux(e,y,m,m.$async)}function f(m){let y=t.scopeValue("schema",a.code.source===!0?{ref:m,code:ds.stringify(m)}:{ref:m}),h=t.name("valid"),b=e.subschema({schema:m,dataTypes:[],schemaPath:ds.nil,topSchemaRef:y,errSchemaPath:n},h);e.mergeEvaluated(b),e.ok(h)}}};function Tq(e,t){let{gen:n}=e;return t.validate?n.scopeValue("validate",{ref:t.validate}):ds._`${n.scopeValue("wrapper",{ref:t})}.validate`}Sq.getValidate=Tq;function Ux(e,t,n,r){let{gen:i,it:s}=e,{allErrors:o,schemaEnv:a,opts:l}=s,c=l.passContext?Qf.default.this:ds.nil;if(r)u();else p();function u(){if(!a.$async)throw Error("async schema referenced by sync schema");let m=i.let("valid");i.try(()=>{if(i.code(ds._`await ${wq.callValidateCode(e,t,c)}`),f(t),!o)i.assign(m,!0)},(y)=>{if(i.if(ds._`!(${y} instanceof ${s.ValidationError})`,()=>i.throw(y)),d(y),!o)i.assign(m,!1)}),e.ok(m)}function p(){e.result(wq.callValidateCode(e,t,c),()=>f(t),()=>d(t))}function d(m){let y=ds._`${m}.errors`;i.assign(Qf.default.vErrors,ds._`${Qf.default.vErrors} === null ? ${y} : ${Qf.default.vErrors}.concat(${y})`),i.assign(Qf.default.errors,ds._`${Qf.default.vErrors}.length`)}function f(m){var y;if(!s.opts.unevaluated)return;let h=(y=n===null||n===void 0?void 0:n.validate)===null||y===void 0?void 0:y.evaluated;if(s.props!==!0)if(h&&!h.dynamicProps){if(h.props!==void 0)s.props=qx.mergeEvaluated.props(i,h.props,s.props)}else{let b=i.var("props",ds._`${m}.evaluated.props`);s.props=qx.mergeEvaluated.props(i,b,s.props,ds.Name)}if(s.items!==!0)if(h&&!h.dynamicItems){if(h.items!==void 0)s.items=qx.mergeEvaluated.items(i,h.items,s.items)}else{let b=i.var("items",ds._`${m}.evaluated.items`);s.items=qx.mergeEvaluated.items(i,b,s.items,ds.Name)}}}Sq.callRef=Ux;Sq.default=Ume});var l1=z(function(kq){Object.defineProperty(kq,"__esModule",{value:!0});var Kme=xq(),Jme=Qh(),Gme=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",Kme.default,Jme.default];kq.default=Gme});var Oq=z(function(Nq){Object.defineProperty(Nq,"__esModule",{value:!0});var Vx=Et(),cu=Vx.operators,Bx={maximum:{okStr:"<=",ok:cu.LTE,fail:cu.GT},minimum:{okStr:">=",ok:cu.GTE,fail:cu.LT},exclusiveMaximum:{okStr:"<",ok:cu.LT,fail:cu.GTE},exclusiveMinimum:{okStr:">",ok:cu.GT,fail:cu.LTE}},zme={message:({keyword:e,schemaCode:t})=>Vx.str`must be ${Bx[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>Vx._`{comparison: ${Bx[e].okStr}, limit: ${t}}`},Wme={keyword:Object.keys(Bx),type:"number",schemaType:"number",$data:!0,error:zme,code(e){let{keyword:t,data:n,schemaCode:r}=e;e.fail$data(Vx._`${n} ${Bx[t].fail} ${r} || isNaN(${n})`)}};Nq.default=Wme});var c1=z(function(Pq){Object.defineProperty(Pq,"__esModule",{value:!0});var Yh=Et(),Yme={message:({schemaCode:e})=>Yh.str`must be multiple of ${e}`,params:({schemaCode:e})=>Yh._`{multipleOf: ${e}}`},Xme={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:Yme,code(e){let{gen:t,data:n,schemaCode:r,it:i}=e,s=i.opts.multipleOfPrecision,o=t.let("res"),a=s?Yh._`Math.abs(Math.round(${o}) - ${o}) > 1e-${s}`:Yh._`${o} !== parseInt(${o})`;e.fail$data(Yh._`(${r} === 0 || (${o} = ${n}/${r}, ${a}))`)}};Pq.default=Xme});var Aq=z(function(Iq){Object.defineProperty(Iq,"__esModule",{value:!0});function $q(e){let t=e.length,n=0,r=0,i;while(r=55296&&i<=56319&&rBp._`{limit: ${e}}`},iye={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:rye,code(e){let{keyword:t,data:n,schemaCode:r,it:i}=e,s=t==="maxLength"?Bp.operators.GT:Bp.operators.LT,o=i.opts.unicode===!1?Bp._`${n}.length`:Bp._`${tye.useFunc(e.gen,nye.default)}(${n})`;e.fail$data(Bp._`${o} ${s} ${r}`)}};Rq.default=iye});var p1=z(function(jq){Object.defineProperty(jq,"__esModule",{value:!0});var oye=_o(),aye=Kt(),Yf=Et(),lye={message:({schemaCode:e})=>Yf.str`must match pattern "${e}"`,params:({schemaCode:e})=>Yf._`{pattern: ${e}}`},cye={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:lye,code(e){let{gen:t,data:n,$data:r,schema:i,schemaCode:s,it:o}=e,a=o.opts.unicodeRegExp?"u":"";if(r){let{regExp:l}=o.opts.code,c=l.code==="new RegExp"?Yf._`new RegExp`:aye.useFunc(t,l),u=t.let("valid");t.try(()=>t.assign(u,Yf._`${c}(${s}, ${a}).test(${n})`),()=>t.assign(u,!1)),e.fail$data(Yf._`!${u}`)}else{let l=oye.usePattern(e,i);e.fail$data(Yf._`!${l}.test(${n})`)}}};jq.default=cye});var d1=z(function(Fq){Object.defineProperty(Fq,"__esModule",{value:!0});var Xh=Et(),pye={message({keyword:e,schemaCode:t}){return Xh.str`must NOT have ${e==="maxProperties"?"more":"fewer"} than ${t} properties`},params:({schemaCode:e})=>Xh._`{limit: ${e}}`},dye={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:pye,code(e){let{keyword:t,data:n,schemaCode:r}=e,i=t==="maxProperties"?Xh.operators.GT:Xh.operators.LT;e.fail$data(Xh._`Object.keys(${n}).length ${i} ${r}`)}};Fq.default=dye});var f1=z(function(Cq){Object.defineProperty(Cq,"__esModule",{value:!0});var eg=_o(),Zh=Et(),mye=Kt(),yye={message:({params:{missingProperty:e}})=>Zh.str`must have required property '${e}'`,params:({params:{missingProperty:e}})=>Zh._`{missingProperty: ${e}}`},hye={keyword:"required",type:"object",schemaType:"array",$data:!0,error:yye,code(e){let{gen:t,schema:n,schemaCode:r,data:i,$data:s,it:o}=e,{opts:a}=o;if(!s&&n.length===0)return;let l=n.length>=a.loopRequired;if(o.allErrors)c();else u();if(a.strictRequired){let f=e.parentSchema.properties,{definedProperties:m}=e.it;for(let y of n)if((f===null||f===void 0?void 0:f[y])===void 0&&!m.has(y)){let h=o.schemaEnv.baseId+o.errSchemaPath,b=`required property "${y}" is not defined at "${h}" (strictRequired)`;mye.checkStrictMode(o,b,o.opts.strictRequired)}}function c(){if(l||s)e.block$data(Zh.nil,p);else for(let f of n)eg.checkReportMissingProp(e,f)}function u(){let f=t.let("missing");if(l||s){let m=t.let("valid",!0);e.block$data(m,()=>d(f,m)),e.ok(m)}else t.if(eg.checkMissingProp(e,n,f)),eg.reportMissingProp(e,f),t.else()}function p(){t.forOf("prop",r,(f)=>{e.setParams({missingProperty:f}),t.if(eg.noPropertyInData(t,i,f,a.ownProperties),()=>e.error())})}function d(f,m){e.setParams({missingProperty:f}),t.forOf(f,r,()=>{t.assign(m,eg.propertyInData(t,i,f,a.ownProperties)),t.if(Zh.not(m),()=>{e.error(),t.break()})},Zh.nil)}}};Cq.default=hye});var m1=z(function(Mq){Object.defineProperty(Mq,"__esModule",{value:!0});var tg=Et(),bye={message({keyword:e,schemaCode:t}){return tg.str`must NOT have ${e==="maxItems"?"more":"fewer"} than ${t} items`},params:({schemaCode:e})=>tg._`{limit: ${e}}`},vye={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:bye,code(e){let{keyword:t,data:n,schemaCode:r}=e,i=t==="maxItems"?tg.operators.GT:tg.operators.LT;e.fail$data(tg._`${n}.length ${i} ${r}`)}};Mq.default=vye});var Kx=z(function(qq){Object.defineProperty(qq,"__esModule",{value:!0});var Lq=Lk();Lq.code='require("ajv/dist/runtime/equal").default';qq.default=Lq});var h1=z(function(Uq){Object.defineProperty(Uq,"__esModule",{value:!0});var y1=qh(),ai=Et(),wye=Kt(),Dye=Kx(),Tye={message:({params:{i:e,j:t}})=>ai.str`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>ai._`{i: ${e}, j: ${t}}`},Sye={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:Tye,code(e){let{gen:t,data:n,$data:r,schema:i,parentSchema:s,schemaCode:o,it:a}=e;if(!r&&!i)return;let l=t.let("valid"),c=s.items?y1.getSchemaTypes(s.items):[];e.block$data(l,u,ai._`${o} === false`),e.ok(l);function u(){let m=t.let("i",ai._`${n}.length`),y=t.let("j");e.setParams({i:m,j:y}),t.assign(l,!0),t.if(ai._`${m} > 1`,()=>(p()?d:f)(m,y))}function p(){return c.length>0&&!c.some((m)=>m==="object"||m==="array")}function d(m,y){let h=t.name("item"),b=y1.checkDataTypes(c,h,a.opts.strictNumbers,y1.DataType.Wrong),g=t.const("indices",ai._`{}`);t.for(ai._`;${m}--;`,()=>{if(t.let(h,ai._`${n}[${m}]`),t.if(b,ai._`continue`),c.length>1)t.if(ai._`typeof ${h} == "string"`,ai._`${h} += "_"`);t.if(ai._`typeof ${g}[${h}] == "number"`,()=>{t.assign(y,ai._`${g}[${h}]`),e.error(),t.assign(l,!1).break()}).code(ai._`${g}[${h}] = ${m}`)})}function f(m,y){let h=wye.useFunc(t,Dye.default),b=t.name("outer");t.label(b).for(ai._`;${m}--;`,()=>t.for(ai._`${y} = ${m}; ${y}--;`,()=>t.if(ai._`${h}(${n}[${m}], ${n}[${y}])`,()=>{e.error(),t.assign(l,!1).break(b)})))}}};Uq.default=Sye});var b1=z(function(Bq){Object.defineProperty(Bq,"__esModule",{value:!0});var g1=Et(),kye=Kt(),Nye=Kx(),Oye={message:"must be equal to constant",params:({schemaCode:e})=>g1._`{allowedValue: ${e}}`},Pye={keyword:"const",$data:!0,error:Oye,code(e){let{gen:t,data:n,$data:r,schemaCode:i,schema:s}=e;if(r||s&&typeof s=="object")e.fail$data(g1._`!${kye.useFunc(t,Nye.default)}(${n}, ${i})`);else e.fail(g1._`${s} !== ${n}`)}};Bq.default=Pye});var v1=z(function(Vq){Object.defineProperty(Vq,"__esModule",{value:!0});var ng=Et(),Iye=Kt(),Aye=Kx(),Rye={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>ng._`{allowedValues: ${e}}`},jye={keyword:"enum",schemaType:"array",$data:!0,error:Rye,code(e){let{gen:t,data:n,$data:r,schema:i,schemaCode:s,it:o}=e;if(!r&&i.length===0)throw Error("enum must have non-empty array");let a=i.length>=o.opts.loopEnum,l,c=()=>l!==null&&l!==void 0?l:l=Iye.useFunc(t,Aye.default),u;if(a||r)u=t.let("valid"),e.block$data(u,p);else{if(!Array.isArray(i))throw Error("ajv implementation error");let f=t.const("vSchema",s);u=ng.or(...i.map((m,y)=>d(f,y)))}e.pass(u);function p(){t.assign(u,!1),t.forOf("v",s,(f)=>t.if(ng._`${c()}(${n}, ${f})`,()=>t.assign(u,!0).break()))}function d(f,m){let y=i[m];return typeof y==="object"&&y!==null?ng._`${c()}(${n}, ${f}[${m}])`:ng._`${n} === ${y}`}}};Vq.default=jye});var _1=z(function(Kq){Object.defineProperty(Kq,"__esModule",{value:!0});var Cye=Oq(),Mye=c1(),Lye=u1(),qye=p1(),Uye=d1(),Bye=f1(),Vye=m1(),Kye=h1(),Jye=b1(),Gye=v1(),Hye=[Cye.default,Mye.default,Lye.default,qye.default,Uye.default,Bye.default,Vye.default,Kye.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},Jye.default,Gye.default];Kq.default=Hye});var w1=z(function(Gq){Object.defineProperty(Gq,"__esModule",{value:!0});Gq.validateAdditionalItems=void 0;var Vp=Et(),x1=Kt(),Wye={message:({params:{len:e}})=>Vp.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>Vp._`{limit: ${e}}`},Qye={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:Wye,code(e){let{parentSchema:t,it:n}=e,{items:r}=t;if(!Array.isArray(r)){x1.checkStrictMode(n,'"additionalItems" is ignored when "items" is not an array of schemas');return}Jq(e,r)}};function Jq(e,t){let{gen:n,schema:r,data:i,keyword:s,it:o}=e;o.items=!0;let a=n.const("len",Vp._`${i}.length`);if(r===!1)e.setParams({len:t.length}),e.pass(Vp._`${a} <= ${t.length}`);else if(typeof r=="object"&&!x1.alwaysValidSchema(o,r)){let c=n.var("valid",Vp._`${a} <= ${t.length}`);n.if(Vp.not(c),()=>l(c)),e.ok(c)}function l(c){n.forRange("i",t.length,a,(u)=>{if(e.subschema({keyword:s,dataProp:u,dataPropType:x1.Type.Num},c),!o.allErrors)n.if(Vp.not(c),()=>n.break())})}}Gq.validateAdditionalItems=Jq;Gq.default=Qye});var D1=z(function(Qq){Object.defineProperty(Qq,"__esModule",{value:!0});Qq.validateTuple=void 0;var zq=Et(),Jx=Kt(),Xye=_o(),Zye={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){let{schema:t,it:n}=e;if(Array.isArray(t))return Wq(e,"additionalItems",t);if(n.items=!0,Jx.alwaysValidSchema(n,t))return;e.ok(Xye.validateArray(e))}};function Wq(e,t,n=e.schema){let{gen:r,parentSchema:i,data:s,keyword:o,it:a}=e;if(u(i),a.opts.unevaluated&&n.length&&a.items!==!0)a.items=Jx.mergeEvaluated.items(r,n.length,a.items);let l=r.name("valid"),c=r.const("len",zq._`${s}.length`);n.forEach((p,d)=>{if(Jx.alwaysValidSchema(a,p))return;r.if(zq._`${c} > ${d}`,()=>e.subschema({keyword:o,schemaProp:d,dataProp:d},l)),e.ok(l)});function u(p){let{opts:d,errSchemaPath:f}=a,m=n.length,y=m===p.minItems&&(m===p.maxItems||p[t]===!1);if(d.strictTuples&&!y){let h=`"${o}" is ${m}-tuple, but minItems or maxItems/${t} are not specified or different at path "${f}"`;Jx.checkStrictMode(a,h,d.strictTuples)}}}Qq.validateTuple=Wq;Qq.default=Zye});var Zq=z(function(Xq){Object.defineProperty(Xq,"__esModule",{value:!0});var the=D1(),nhe={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:(e)=>the.validateTuple(e,"items")};Xq.default=nhe});var nU=z(function(tU){Object.defineProperty(tU,"__esModule",{value:!0});var eU=Et(),ihe=Kt(),she=_o(),ohe=w1(),ahe={message:({params:{len:e}})=>eU.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>eU._`{limit: ${e}}`},lhe={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:ahe,code(e){let{schema:t,parentSchema:n,it:r}=e,{prefixItems:i}=n;if(r.items=!0,ihe.alwaysValidSchema(r,t))return;if(i)ohe.validateAdditionalItems(e,i);else e.ok(she.validateArray(e))}};tU.default=lhe});var iU=z(function(rU){Object.defineProperty(rU,"__esModule",{value:!0});var xo=Et(),Gx=Kt(),uhe={message:({params:{min:e,max:t}})=>t===void 0?xo.str`must contain at least ${e} valid item(s)`:xo.str`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?xo._`{minContains: ${e}}`:xo._`{minContains: ${e}, maxContains: ${t}}`},phe={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:uhe,code(e){let{gen:t,schema:n,parentSchema:r,data:i,it:s}=e,o,a,{minContains:l,maxContains:c}=r;if(s.opts.next)o=l===void 0?1:l,a=c;else o=1;let u=t.const("len",xo._`${i}.length`);if(e.setParams({min:o,max:a}),a===void 0&&o===0){Gx.checkStrictMode(s,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(a!==void 0&&o>a){Gx.checkStrictMode(s,'"minContains" > "maxContains" is always invalid'),e.fail();return}if(Gx.alwaysValidSchema(s,n)){let y=xo._`${u} >= ${o}`;if(a!==void 0)y=xo._`${y} && ${u} <= ${a}`;e.pass(y);return}s.items=!0;let p=t.name("valid");if(a===void 0&&o===1)f(p,()=>t.if(p,()=>t.break()));else if(o===0){if(t.let(p,!0),a!==void 0)t.if(xo._`${i}.length > 0`,d)}else t.let(p,!1),d();e.result(p,()=>e.reset());function d(){let y=t.name("_valid"),h=t.let("count",0);f(y,()=>t.if(y,()=>m(h)))}function f(y,h){t.forRange("i",0,u,(b)=>{e.subschema({keyword:"contains",dataProp:b,dataPropType:Gx.Type.Num,compositeRule:!0},y),h()})}function m(y){if(t.code(xo._`${y}++`),a===void 0)t.if(xo._`${y} >= ${o}`,()=>t.assign(p,!0).break());else if(t.if(xo._`${y} > ${a}`,()=>t.assign(p,!1).break()),o===1)t.assign(p,!0);else t.if(xo._`${y} >= ${o}`,()=>t.assign(p,!0))}}};rU.default=phe});var Hx=z(function(aU){Object.defineProperty(aU,"__esModule",{value:!0});aU.validateSchemaDeps=aU.validatePropertyDeps=aU.error=void 0;var T1=Et(),fhe=Kt(),rg=_o();aU.error={message:({params:{property:e,depsCount:t,deps:n}})=>T1.str`must have ${t===1?"property":"properties"} ${n} when property ${e} is present`,params:({params:{property:e,depsCount:t,deps:n,missingProperty:r}})=>T1._`{property: ${e}, + || ${o} === "boolean" || ${i} === null`).assign(a,Rt._`[${i}]`)}}}function xpe({gen:e,parentData:t,parentDataProperty:n},r){e.if(Rt._`${t} !== undefined`,()=>e.assign(Rt._`${t}[${n}]`,r))}function Ak(e,t,n,r=Hf.Correct){let i=r===Hf.Correct?Rt.operators.EQ:Rt.operators.NEQ,s;switch(e){case"null":return Rt._`${t} ${i} null`;case"array":s=Rt._`Array.isArray(${t})`;break;case"object":s=Rt._`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":s=o(Rt._`!(${t} % 1) && !isNaN(${t})`);break;case"number":s=o();break;default:return Rt._`typeof ${t} ${i} ${e}`}return r===Hf.Correct?s:Rt.not(s);function o(a=Rt.nil){return Rt.and(Rt._`typeof ${t} == "number"`,a,n?Rt._`isFinite(${t})`:Rt.nil)}}BL.checkDataType=Ak;function Rk(e,t,n,r){if(e.length===1)return Ak(e[0],t,n,r);let i,s=LL.toHash(e);if(s.array&&s.object){let o=Rt._`typeof ${t} != "object"`;i=s.null?o:Rt._`!${t} || ${o}`,delete s.null,delete s.array,delete s.object}else i=Rt.nil;if(s.number)delete s.integer;for(let o in s)i=Rt.and(i,Ak(o,t,n,r));return i}BL.checkDataTypes=Rk;var wpe={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>typeof e=="string"?Rt._`{type: ${e}}`:Rt._`{type: ${t}}`};function jk(e){let t=Dpe(e);hpe.reportError(t,wpe)}BL.reportTypeError=jk;function Dpe(e){let{gen:t,data:n,schema:r}=e,i=LL.schemaRefOrVal(e,r,"type");return{gen:t,keyword:"type",data:n,schema:r.type,schemaCode:i,schemaValue:i,parentSchema:r,params:{},it:e}}});var HL=z(function(JL){Object.defineProperty(JL,"__esModule",{value:!0});JL.assignDefaults=void 0;var zf=kt(),Ppe=Kt();function $pe(e,t){let{properties:n,items:r}=e.schema;if(t==="object"&&n)for(let i in n)KL(e,i,n[i].default);else if(t==="array"&&Array.isArray(r))r.forEach((i,s)=>KL(e,s,i.default))}JL.assignDefaults=$pe;function KL(e,t,n){let{gen:r,compositeRule:i,data:s,opts:o}=e;if(n===void 0)return;let a=zf._`${s}${zf.getProperty(t)}`;if(i){Ppe.checkStrictMode(e,`default is ignored for: ${a}`);return}let l=zf._`${a} === undefined`;if(o.useDefaults==="empty")l=zf._`${l} || ${a} === null || ${a} === ""`;r.if(l,zf._`${a} = ${zf.stringify(n)}`)}});var _o=z(function(QL){Object.defineProperty(QL,"__esModule",{value:!0});QL.validateUnion=QL.validateArray=QL.usePattern=QL.callValidateCode=QL.schemaProperties=QL.allSchemaProperties=QL.noPropertyInData=QL.propertyInData=QL.isOwnProperty=QL.hasPropFunc=QL.reportMissingProp=QL.checkMissingProp=QL.checkReportMissingProp=void 0;var Bn=kt(),Fk=Kt(),au=vo(),Ipe=Kt();function Ape(e,t){let{gen:n,data:r,it:i}=e;n.if(Mk(n,r,t,i.opts.ownProperties),()=>{e.setParams({missingProperty:Bn._`${t}`},!0),e.error()})}QL.checkReportMissingProp=Ape;function Rpe({gen:e,data:t,it:{opts:n}},r,i){return Bn.or(...r.map((s)=>Bn.and(Mk(e,t,s,n.ownProperties),Bn._`${i} = ${s}`)))}QL.checkMissingProp=Rpe;function jpe(e,t){e.setParams({missingProperty:t},!0),e.error()}QL.reportMissingProp=jpe;function zL(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:Bn._`Object.prototype.hasOwnProperty`})}QL.hasPropFunc=zL;function Ck(e,t,n){return Bn._`${zL(e)}.call(${t}, ${n})`}QL.isOwnProperty=Ck;function Fpe(e,t,n,r){let i=Bn._`${t}${Bn.getProperty(n)} !== undefined`;return r?Bn._`${i} && ${Ck(e,t,n)}`:i}QL.propertyInData=Fpe;function Mk(e,t,n,r){let i=Bn._`${t}${Bn.getProperty(n)} === undefined`;return r?Bn.or(i,Bn.not(Ck(e,t,n))):i}QL.noPropertyInData=Mk;function WL(e){return e?Object.keys(e).filter((t)=>t!=="__proto__"):[]}QL.allSchemaProperties=WL;function Cpe(e,t){return WL(t).filter((n)=>!Fk.alwaysValidSchema(e,t[n]))}QL.schemaProperties=Cpe;function Mpe({schemaCode:e,data:t,it:{gen:n,topSchemaRef:r,schemaPath:i,errorPath:s},it:o},a,l,c){let u=c?Bn._`${e}, ${t}, ${r}${i}`:t,p=[[au.default.instancePath,Bn.strConcat(au.default.instancePath,s)],[au.default.parentData,o.parentData],[au.default.parentDataProperty,o.parentDataProperty],[au.default.rootData,au.default.rootData]];if(o.opts.dynamicRef)p.push([au.default.dynamicAnchors,au.default.dynamicAnchors]);let d=Bn._`${u}, ${n.object(...p)}`;return l!==Bn.nil?Bn._`${a}.call(${l}, ${d})`:Bn._`${a}(${d})`}QL.callValidateCode=Mpe;var Lpe=Bn._`new RegExp`;function qpe({gen:e,it:{opts:t}},n){let r=t.unicodeRegExp?"u":"",{regExp:i}=t.code,s=i(n,r);return e.scopeValue("pattern",{key:s.toString(),ref:s,code:Bn._`${i.code==="new RegExp"?Lpe:Ipe.useFunc(e,i)}(${n}, ${r})`})}QL.usePattern=qpe;function Upe(e){let{gen:t,data:n,keyword:r,it:i}=e,s=t.name("valid");if(i.allErrors){let a=t.let("valid",!0);return o(()=>t.assign(a,!1)),a}return t.var(s,!0),o(()=>t.break()),s;function o(a){let l=t.const("len",Bn._`${n}.length`);t.forRange("i",0,l,(c)=>{e.subschema({keyword:r,dataProp:c,dataPropType:Fk.Type.Num},s),t.if(Bn.not(s),a)})}}QL.validateArray=Upe;function Bpe(e){let{gen:t,schema:n,keyword:r,it:i}=e;if(!Array.isArray(n))throw Error("ajv implementation error");if(n.some((l)=>Fk.alwaysValidSchema(i,l))&&!i.opts.unevaluated)return;let o=t.let("valid",!1),a=t.name("_valid");t.block(()=>n.forEach((l,c)=>{let u=e.subschema({keyword:r,schemaProp:c,compositeRule:!0},a);if(t.assign(o,Bn._`${o} || ${a}`),!e.mergeValidEvaluated(u,a))t.if(Bn.not(o))})),e.result(o,()=>e.reset(),()=>e.error(!0))}QL.validateUnion=Bpe});var n2=z(function(e2){Object.defineProperty(e2,"__esModule",{value:!0});e2.validateKeywordUsage=e2.validSchemaType=e2.funcKeywordCode=e2.macroKeywordCode=void 0;var Hi=kt(),Mp=vo(),tde=_o(),nde=Lh();function rde(e,t){let{gen:n,keyword:r,schema:i,parentSchema:s,it:o}=e,a=t.macro.call(o.self,i,s,o),l=ZL(n,r,a);if(o.opts.validateSchema!==!1)o.self.validateSchema(a,!0);let c=n.name("valid");e.subschema({schema:a,schemaPath:Hi.nil,errSchemaPath:`${o.errSchemaPath}/${r}`,topSchemaRef:l,compositeRule:!0},c),e.pass(c,()=>e.error(!0))}e2.macroKeywordCode=rde;function ide(e,t){var n;let{gen:r,keyword:i,schema:s,parentSchema:o,$data:a,it:l}=e;ode(l,t);let c=!a&&t.compile?t.compile.call(l.self,s,o,l):t.validate,u=ZL(r,i,c),p=r.let("valid");e.block$data(p,d),e.ok((n=t.valid)!==null&&n!==void 0?n:p);function d(){if(t.errors===!1){if(y(),t.modifying)XL(e);h(()=>e.error())}else{let b=t.async?f():m();if(t.modifying)XL(e);h(()=>sde(e,b))}}function f(){let b=r.let("ruleErrs",null);return r.try(()=>y(Hi._`await `),(g)=>r.assign(p,!1).if(Hi._`${g} instanceof ${l.ValidationError}`,()=>r.assign(b,Hi._`${g}.errors`),()=>r.throw(g))),b}function m(){let b=Hi._`${u}.errors`;return r.assign(b,null),y(Hi.nil),b}function y(b=t.async?Hi._`await `:Hi.nil){let g=l.opts.passContext?Mp.default.this:Mp.default.self,x=!(("compile"in t)&&!a||t.schema===!1);r.assign(p,Hi._`${b}${tde.callValidateCode(e,u,g,x)}`,t.modifying)}function h(b){var g;r.if(Hi.not((g=t.valid)!==null&&g!==void 0?g:p),b)}}e2.funcKeywordCode=ide;function XL(e){let{gen:t,data:n,it:r}=e;t.if(r.parentData,()=>t.assign(n,Hi._`${r.parentData}[${r.parentDataProperty}]`))}function sde(e,t){let{gen:n}=e;n.if(Hi._`Array.isArray(${t})`,()=>{n.assign(Mp.default.vErrors,Hi._`${Mp.default.vErrors} === null ? ${t} : ${Mp.default.vErrors}.concat(${t})`).assign(Mp.default.errors,Hi._`${Mp.default.vErrors}.length`),nde.extendErrors(e)},()=>e.error())}function ode({schemaEnv:e},t){if(t.async&&!e.$async)throw Error("async keyword in sync schema")}function ZL(e,t,n){if(n===void 0)throw Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof n=="function"?{ref:n}:{ref:n,code:Hi.stringify(n)})}function ade(e,t,n=!1){return!t.length||t.some((r)=>r==="array"?Array.isArray(e):r==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==r||n&&typeof e>"u")}e2.validSchemaType=ade;function lde({schema:e,opts:t,self:n,errSchemaPath:r},i,s){if(Array.isArray(i.keyword)?!i.keyword.includes(s):i.keyword!==s)throw Error("ajv implementation error");let o=i.dependencies;if(o===null||o===void 0?void 0:o.some((a)=>!Object.prototype.hasOwnProperty.call(e,a)))throw Error(`parent schema must have dependencies of ${s}: ${o.join(",")}`);if(i.validateSchema){if(!i.validateSchema(e[s])){let l=`keyword "${s}" value is invalid at path "${r}": `+n.errorsText(i.validateSchema.errors);if(t.validateSchema==="log")n.logger.error(l);else throw Error(l)}}}e2.validateKeywordUsage=lde});var o2=z(function(i2){Object.defineProperty(i2,"__esModule",{value:!0});i2.extendSubschemaMode=i2.extendSubschemaData=i2.getSubschema=void 0;var za=kt(),r2=Kt();function dde(e,{keyword:t,schemaProp:n,schema:r,schemaPath:i,errSchemaPath:s,topSchemaRef:o}){if(t!==void 0&&r!==void 0)throw Error('both "keyword" and "schema" passed, only one allowed');if(t!==void 0){let a=e.schema[t];return n===void 0?{schema:a,schemaPath:za._`${e.schemaPath}${za.getProperty(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:a[n],schemaPath:za._`${e.schemaPath}${za.getProperty(t)}${za.getProperty(n)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${r2.escapeFragment(n)}`}}if(r!==void 0){if(i===void 0||s===void 0||o===void 0)throw Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:r,schemaPath:i,topSchemaRef:o,errSchemaPath:s}}throw Error('either "keyword" or "schema" must be passed')}i2.getSubschema=dde;function fde(e,t,{dataProp:n,dataPropType:r,data:i,dataTypes:s,propertyName:o}){if(i!==void 0&&n!==void 0)throw Error('both "data" and "dataProp" passed, only one allowed');let{gen:a}=t;if(n!==void 0){let{errorPath:c,dataPathArr:u,opts:p}=t,d=a.let("data",za._`${t.data}${za.getProperty(n)}`,!0);l(d),e.errorPath=za.str`${c}${r2.getErrorPath(n,r,p.jsPropertySyntax)}`,e.parentDataProperty=za._`${n}`,e.dataPathArr=[...u,e.parentDataProperty]}if(i!==void 0){let c=i instanceof za.Name?i:a.let("data",i,!0);if(l(c),o!==void 0)e.propertyName=o}if(s)e.dataTypes=s;function l(c){e.data=c,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,c]}}i2.extendSubschemaData=fde;function mde(e,{jtdDiscriminator:t,jtdMetadata:n,compositeRule:r,createErrors:i,allErrors:s}){if(r!==void 0)e.compositeRule=r;if(i!==void 0)e.createErrors=i;if(s!==void 0)e.allErrors=s;e.jtdDiscriminator=t,e.jtdMetadata=n}i2.extendSubschemaMode=mde});var Lk=z(function(ZJe,a2){a2.exports=function e(t,n){if(t===n)return!0;if(t&&n&&typeof t=="object"&&typeof n=="object"){if(t.constructor!==n.constructor)return!1;var r,i,s;if(Array.isArray(t)){if(r=t.length,r!=n.length)return!1;for(i=r;i--!==0;)if(!e(t[i],n[i]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if(s=Object.keys(t),r=s.length,r!==Object.keys(n).length)return!1;for(i=r;i--!==0;)if(!Object.prototype.hasOwnProperty.call(n,s[i]))return!1;for(i=r;i--!==0;){var o=s[i];if(!e(t[o],n[o]))return!1}return!0}return t!==t&&n!==n}});var c2=z(function(eGe,l2){var lu=l2.exports=function(e,t,n){if(typeof t=="function")n=t,t={};n=t.cb||n;var r=typeof n=="function"?n:n.pre||function(){},i=n.post||function(){};Px(t,r,i,e,"",e)};lu.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};lu.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};lu.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};lu.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function Px(e,t,n,r,i,s,o,a,l,c){if(r&&typeof r=="object"&&!Array.isArray(r)){t(r,i,s,o,a,l,c);for(var u in r){var p=r[u];if(Array.isArray(p)){if(u in lu.arrayKeywords)for(var d=0;dt+=u2(r));if(t===1/0)return 1/0}return t}function p2(e,t="",n){if(n!==!1)t=Wf(t);let r=e.parse(t);return d2(e,r)}f2.getFullPath=p2;function d2(e,t){return e.serialize(t).split("#")[0]+"#"}f2._getFullPath=d2;var Tde=/#\/?$/;function Wf(e){return e?e.replace(Tde,""):""}f2.normalizeId=Wf;function Sde(e,t,n){return n=Wf(n),e.resolve(t,n)}f2.resolveUrl=Sde;var Ede=/^[a-z_][-a-z0-9._]*$/i;function kde(e,t){if(typeof e=="boolean")return{};let{schemaId:n,uriResolver:r}=this.opts,i=Wf(e[n]||t),s={"":i},o=p2(r,i,!1),a={},l=new Set;return _de(e,{allKeys:!0},(p,d,f,m)=>{if(m===void 0)return;let y=o+d,h=s[m];if(typeof p[n]=="string")h=b.call(this,p[n]);g.call(this,p.$anchor),g.call(this,p.$dynamicAnchor),s[d]=h;function b(x){let v=this.opts.uriResolver.resolve;if(x=Wf(h?v(h,x):x),l.has(x))throw u(x);l.add(x);let D=this.refs[x];if(typeof D=="string")D=this.refs[D];if(typeof D=="object")c(p,D.schema,x);else if(x!==Wf(y))if(x[0]==="#")c(p,a[x],x),a[x]=p;else this.refs[x]=y;return x}function g(x){if(typeof x=="string"){if(!Ede.test(x))throw Error(`invalid anchor "${x}"`);b.call(this,`#${x}`)}}}),a;function c(p,d,f){if(d!==void 0&&!vde(p,d))throw u(f)}function u(p){return Error(`reference "${p}" resolves to more than one schema`)}}f2.getSchemaRefs=kde});var Lp=z(function(O2){Object.defineProperty(O2,"__esModule",{value:!0});O2.getData=O2.KeywordCxt=O2.validateFunctionCode=void 0;var b2=IL(),v2=qh(),Uk=Ik(),$x=qh(),Ade=HL(),Bh=n2(),Bk=o2(),pt=kt(),Tt=vo(),Rde=Uh(),Vl=Kt(),Vh=Lh();function jde(e){if(w2(e)){if(D2(e),x2(e)){Mde(e);return}}_2(e,()=>b2.topBoolOrEmptySchema(e))}O2.validateFunctionCode=jde;function _2({gen:e,validateName:t,schema:n,schemaEnv:r,opts:i},s){if(i.code.es5)e.func(t,pt._`${Tt.default.data}, ${Tt.default.valCxt}`,r.$async,()=>{e.code(pt._`"use strict"; ${y2(n,i)}`),Cde(e,i),e.code(s)});else e.func(t,pt._`${Tt.default.data}, ${Fde(i)}`,r.$async,()=>e.code(y2(n,i)).code(s))}function Fde(e){return pt._`{${Tt.default.instancePath}="", ${Tt.default.parentData}, ${Tt.default.parentDataProperty}, ${Tt.default.rootData}=${Tt.default.data}${e.dynamicRef?pt._`, ${Tt.default.dynamicAnchors}={}`:pt.nil}}={}`}function Cde(e,t){e.if(Tt.default.valCxt,()=>{if(e.var(Tt.default.instancePath,pt._`${Tt.default.valCxt}.${Tt.default.instancePath}`),e.var(Tt.default.parentData,pt._`${Tt.default.valCxt}.${Tt.default.parentData}`),e.var(Tt.default.parentDataProperty,pt._`${Tt.default.valCxt}.${Tt.default.parentDataProperty}`),e.var(Tt.default.rootData,pt._`${Tt.default.valCxt}.${Tt.default.rootData}`),t.dynamicRef)e.var(Tt.default.dynamicAnchors,pt._`${Tt.default.valCxt}.${Tt.default.dynamicAnchors}`)},()=>{if(e.var(Tt.default.instancePath,pt._`""`),e.var(Tt.default.parentData,pt._`undefined`),e.var(Tt.default.parentDataProperty,pt._`undefined`),e.var(Tt.default.rootData,Tt.default.data),t.dynamicRef)e.var(Tt.default.dynamicAnchors,pt._`{}`)})}function Mde(e){let{schema:t,opts:n,gen:r}=e;_2(e,()=>{if(n.$comment&&t.$comment)S2(e);if(Vde(e),r.let(Tt.default.vErrors,null),r.let(Tt.default.errors,0),n.unevaluated)Lde(e);T2(e),Gde(e)});return}function Lde(e){let{gen:t,validateName:n}=e;e.evaluated=t.const("evaluated",pt._`${n}.evaluated`),t.if(pt._`${e.evaluated}.dynamicProps`,()=>t.assign(pt._`${e.evaluated}.props`,pt._`undefined`)),t.if(pt._`${e.evaluated}.dynamicItems`,()=>t.assign(pt._`${e.evaluated}.items`,pt._`undefined`))}function y2(e,t){let n=typeof e=="object"&&e[t.schemaId];return n&&(t.code.source||t.code.process)?pt._`/*# sourceURL=${n} */`:pt.nil}function qde(e,t){if(w2(e)){if(D2(e),x2(e)){Ude(e,t);return}}b2.boolOrEmptySchema(e,t)}function x2({schema:e,self:t}){if(typeof e=="boolean")return!e;for(let n in e)if(t.RULES.all[n])return!0;return!1}function w2(e){return typeof e.schema!="boolean"}function Ude(e,t){let{schema:n,gen:r,opts:i}=e;if(i.$comment&&n.$comment)S2(e);Kde(e),Jde(e);let s=r.const("_errs",Tt.default.errors);T2(e,s),r.var(t,pt._`${s} === ${Tt.default.errors}`)}function D2(e){Vl.checkUnknownRules(e),Bde(e)}function T2(e,t){if(e.opts.jtd)return h2(e,[],!1,t);let n=v2.getSchemaTypes(e.schema),r=v2.coerceAndCheckDataType(e,n);h2(e,n,!r,t)}function Bde(e){let{schema:t,errSchemaPath:n,opts:r,self:i}=e;if(t.$ref&&r.ignoreKeywordsWithRef&&Vl.schemaHasRulesButRef(t,i.RULES))i.logger.warn(`$ref: keywords ignored in schema at path "${n}"`)}function Vde(e){let{schema:t,opts:n}=e;if(t.default!==void 0&&n.useDefaults&&n.strictSchema)Vl.checkStrictMode(e,"default is ignored in the schema root")}function Kde(e){let t=e.schema[e.opts.schemaId];if(t)e.baseId=Rde.resolveUrl(e.opts.uriResolver,e.baseId,t)}function Jde(e){if(e.schema.$async&&!e.schemaEnv.$async)throw Error("async schema in sync schema")}function S2({gen:e,schemaEnv:t,schema:n,errSchemaPath:r,opts:i}){let s=n.$comment;if(i.$comment===!0)e.code(pt._`${Tt.default.self}.logger.log(${s})`);else if(typeof i.$comment=="function"){let o=pt.str`${r}/$comment`,a=e.scopeValue("root",{ref:t.root});e.code(pt._`${Tt.default.self}.opts.$comment(${s}, ${o}, ${a}.schema)`)}}function Gde(e){let{gen:t,schemaEnv:n,validateName:r,ValidationError:i,opts:s}=e;if(n.$async)t.if(pt._`${Tt.default.errors} === 0`,()=>t.return(Tt.default.data),()=>t.throw(pt._`new ${i}(${Tt.default.vErrors})`));else{if(t.assign(pt._`${r}.errors`,Tt.default.vErrors),s.unevaluated)Hde(e);t.return(pt._`${Tt.default.errors} === 0`)}}function Hde({gen:e,evaluated:t,props:n,items:r}){if(n instanceof pt.Name)e.assign(pt._`${t}.props`,n);if(r instanceof pt.Name)e.assign(pt._`${t}.items`,r)}function h2(e,t,n,r){let{gen:i,schema:s,data:o,allErrors:a,opts:l,self:c}=e,{RULES:u}=c;if(s.$ref&&(l.ignoreKeywordsWithRef||!Vl.schemaHasRulesButRef(s,u))){i.block(()=>k2(e,"$ref",u.all.$ref.definition));return}if(!l.jtd)zde(e,t);i.block(()=>{for(let d of u.rules)p(d);p(u.post)});function p(d){if(!Uk.shouldUseGroup(s,d))return;if(d.type){if(i.if($x.checkDataType(d.type,o,l.strictNumbers)),g2(e,d),t.length===1&&t[0]===d.type&&n)i.else(),$x.reportTypeError(e);i.endIf()}else g2(e,d);if(!a)i.if(pt._`${Tt.default.errors} === ${r||0}`)}}function g2(e,t){let{gen:n,schema:r,opts:{useDefaults:i}}=e;if(i)Ade.assignDefaults(e,t.type);n.block(()=>{for(let s of t.rules)if(Uk.shouldUseRule(r,s))k2(e,s.keyword,s.definition,t.type)})}function zde(e,t){if(e.schemaEnv.meta||!e.opts.strictTypes)return;if(Wde(e,t),!e.opts.allowUnionTypes)Qde(e,t);Yde(e,e.dataTypes)}function Wde(e,t){if(!t.length)return;if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach((n)=>{if(!E2(e.dataTypes,n))Vk(e,`type "${n}" not allowed by context "${e.dataTypes.join(",")}"`)}),Zde(e,t)}function Qde(e,t){if(t.length>1&&!(t.length===2&&t.includes("null")))Vk(e,"use allowUnionTypes to allow union type keyword")}function Yde(e,t){let n=e.self.RULES.all;for(let r in n){let i=n[r];if(typeof i=="object"&&Uk.shouldUseRule(e.schema,i)){let{type:s}=i.definition;if(s.length&&!s.some((o)=>Xde(t,o)))Vk(e,`missing type "${s.join(",")}" for keyword "${r}"`)}}}function Xde(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}function E2(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}function Zde(e,t){let n=[];for(let r of e.dataTypes)if(E2(t,r))n.push(r);else if(t.includes("integer")&&r==="number")n.push("integer");e.dataTypes=n}function Vk(e,t){let n=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${n}" (strictTypes)`,Vl.checkStrictMode(e,t,e.opts.strictTypes)}class Kk{constructor(e,t,n){if(Bh.validateKeywordUsage(e,t,n),this.gen=e.gen,this.allErrors=e.allErrors,this.keyword=n,this.data=e.data,this.schema=e.schema[n],this.$data=t.$data&&e.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=Vl.schemaRefOrVal(e,this.schema,n,this.$data),this.schemaType=t.schemaType,this.parentSchema=e.schema,this.params={},this.it=e,this.def=t,this.$data)this.schemaCode=e.gen.const("vSchema",N2(this.$data,e));else if(this.schemaCode=this.schemaValue,!Bh.validSchemaType(this.schema,t.schemaType,t.allowUndefined))throw Error(`${n} value must be ${JSON.stringify(t.schemaType)}`);if("code"in t?t.trackErrors:t.errors!==!1)this.errsCount=e.gen.const("_errs",Tt.default.errors)}result(e,t,n){this.failResult(pt.not(e),t,n)}failResult(e,t,n){if(this.gen.if(e),n)n();else this.error();if(t){if(this.gen.else(),t(),this.allErrors)this.gen.endIf()}else if(this.allErrors)this.gen.endIf();else this.gen.else()}pass(e,t){this.failResult(pt.not(e),void 0,t)}fail(e){if(e===void 0){if(this.error(),!this.allErrors)this.gen.if(!1);return}if(this.gen.if(e),this.error(),this.allErrors)this.gen.endIf();else this.gen.else()}fail$data(e){if(!this.$data)return this.fail(e);let{schemaCode:t}=this;this.fail(pt._`${t} !== undefined && (${pt.or(this.invalid$data(),e)})`)}error(e,t,n){if(t){this.setParams(t),this._error(e,n),this.setParams({});return}this._error(e,n)}_error(e,t){(e?Vh.reportExtraError:Vh.reportError)(this,this.def.error,t)}$dataError(){Vh.reportError(this,this.def.$dataError||Vh.keyword$DataError)}reset(){if(this.errsCount===void 0)throw Error('add "trackErrors" to keyword definition');Vh.resetErrorsCount(this.gen,this.errsCount)}ok(e){if(!this.allErrors)this.gen.if(e)}setParams(e,t){if(t)Object.assign(this.params,e);else this.params=e}block$data(e,t,n=pt.nil){this.gen.block(()=>{this.check$data(e,n),t()})}check$data(e=pt.nil,t=pt.nil){if(!this.$data)return;let{gen:n,schemaCode:r,schemaType:i,def:s}=this;if(n.if(pt.or(pt._`${r} === undefined`,t)),e!==pt.nil)n.assign(e,!0);if(i.length||s.validateSchema){if(n.elseIf(this.invalid$data()),this.$dataError(),e!==pt.nil)n.assign(e,!1)}n.else()}invalid$data(){let{gen:e,schemaCode:t,schemaType:n,def:r,it:i}=this;return pt.or(s(),o());function s(){if(n.length){if(!(t instanceof pt.Name))throw Error("ajv implementation error");let a=Array.isArray(n)?n:[n];return pt._`${$x.checkDataTypes(a,t,i.opts.strictNumbers,$x.DataType.Wrong)}`}return pt.nil}function o(){if(r.validateSchema){let a=e.scopeValue("validate$data",{ref:r.validateSchema});return pt._`!${a}(${t})`}return pt.nil}}subschema(e,t){let n=Bk.getSubschema(this.it,e);Bk.extendSubschemaData(n,this.it,e),Bk.extendSubschemaMode(n,e);let r={...this.it,...n,items:void 0,props:void 0};return qde(r,t),r}mergeEvaluated(e,t){let{it:n,gen:r}=this;if(!n.opts.unevaluated)return;if(n.props!==!0&&e.props!==void 0)n.props=Vl.mergeEvaluated.props(r,e.props,n.props,t);if(n.items!==!0&&e.items!==void 0)n.items=Vl.mergeEvaluated.items(r,e.items,n.items,t)}mergeValidEvaluated(e,t){let{it:n,gen:r}=this;if(n.opts.unevaluated&&(n.props!==!0||n.items!==!0))return r.if(t,()=>this.mergeEvaluated(e,pt.Name)),!0}}O2.KeywordCxt=Kk;function k2(e,t,n,r){let i=new Kk(e,n,t);if("code"in n)n.code(i,r);else if(i.$data&&n.validate)Bh.funcKeywordCode(i,n);else if("macro"in n)Bh.macroKeywordCode(i,n);else if(n.compile||n.validate)Bh.funcKeywordCode(i,n)}var efe=/^\/(?:[^~]|~0|~1)*$/,tfe=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function N2(e,{dataLevel:t,dataNames:n,dataPathArr:r}){let i,s;if(e==="")return Tt.default.rootData;if(e[0]==="/"){if(!efe.test(e))throw Error(`Invalid JSON-pointer: ${e}`);i=e,s=Tt.default.rootData}else{let c=tfe.exec(e);if(!c)throw Error(`Invalid JSON-pointer: ${e}`);let u=+c[1];if(i=c[2],i==="#"){if(u>=t)throw Error(l("property/index",u));return r[t-u]}if(u>t)throw Error(l("data",u));if(s=n[t-u],!i)return s}let o=s,a=i.split("/");for(let c of a)if(c)s=pt._`${s}${pt.getProperty(Vl.unescapeJsonPointer(c))}`,o=pt._`${o} && ${s}`;return o;function l(c,u){return`Cannot access ${c} ${u} levels up, current level is ${t}`}}O2.getData=N2});var Qf=z(function(I2){Object.defineProperty(I2,"__esModule",{value:!0});class $2 extends Error{constructor(e){super("validation failed");this.errors=e,this.ajv=this.validation=!0}}I2.default=$2});var qp=z(function(R2){Object.defineProperty(R2,"__esModule",{value:!0});var Jk=Uh();class A2 extends Error{constructor(e,t,n,r){super(r||`can't resolve reference ${n} from id ${t}`);this.missingRef=Jk.resolveUrl(e,t,n),this.missingSchema=Jk.normalizeId(Jk.getFullPath(e,this.missingRef))}}R2.default=A2});var Jh=z(function(C2){Object.defineProperty(C2,"__esModule",{value:!0});C2.resolveSchema=C2.getCompilingSchema=C2.resolveRef=C2.compileSchema=C2.SchemaEnv=void 0;var fa=kt(),ofe=Qf(),Up=vo(),ma=Uh(),j2=Kt(),afe=Lp();class Kh{constructor(e){var t;this.refs={},this.dynamicAnchors={};let n;if(typeof e.schema=="object")n=e.schema;this.schema=e.schema,this.schemaId=e.schemaId,this.root=e.root||this,this.baseId=(t=e.baseId)!==null&&t!==void 0?t:ma.normalizeId(n===null||n===void 0?void 0:n[e.schemaId||"$id"]),this.schemaPath=e.schemaPath,this.localRefs=e.localRefs,this.meta=e.meta,this.$async=n===null||n===void 0?void 0:n.$async,this.refs={}}}C2.SchemaEnv=Kh;function Hk(e){let t=F2.call(this,e);if(t)return t;let n=ma.getFullPath(this.opts.uriResolver,e.root.baseId),{es5:r,lines:i}=this.opts.code,{ownProperties:s}=this.opts,o=new fa.CodeGen(this.scope,{es5:r,lines:i,ownProperties:s}),a;if(e.$async)a=o.scopeValue("Error",{ref:ofe.default,code:fa._`require("ajv/dist/runtime/validation_error").default`});let l=o.scopeName("validate");e.validateName=l;let c={gen:o,allErrors:this.opts.allErrors,data:Up.default.data,parentData:Up.default.parentData,parentDataProperty:Up.default.parentDataProperty,dataNames:[Up.default.data],dataPathArr:[fa.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:o.scopeValue("schema",this.opts.code.source===!0?{ref:e.schema,code:fa.stringify(e.schema)}:{ref:e.schema}),validateName:l,ValidationError:a,schema:e.schema,schemaEnv:e,rootId:n,baseId:e.baseId||n,schemaPath:fa.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:fa._`""`,opts:this.opts,self:this},u;try{this._compilations.add(e),afe.validateFunctionCode(c),o.optimize(this.opts.code.optimize);let p=o.toString();if(u=`${o.scopeRefs(Up.default.scope)}return ${p}`,this.opts.code.process)u=this.opts.code.process(u,e);let f=Function(`${Up.default.self}`,`${Up.default.scope}`,u)(this,this.scope.get());if(this.scope.value(l,{ref:f}),f.errors=null,f.schema=e.schema,f.schemaEnv=e,e.$async)f.$async=!0;if(this.opts.code.source===!0)f.source={validateName:l,validateCode:p,scopeValues:o._values};if(this.opts.unevaluated){let{props:m,items:y}=c;if(f.evaluated={props:m instanceof fa.Name?void 0:m,items:y instanceof fa.Name?void 0:y,dynamicProps:m instanceof fa.Name,dynamicItems:y instanceof fa.Name},f.source)f.source.evaluated=fa.stringify(f.evaluated)}return e.validate=f,e}catch(p){if(delete e.validate,delete e.validateName,u)this.logger.error("Error compiling schema, function code:",u);throw p}finally{this._compilations.delete(e)}}C2.compileSchema=Hk;function lfe(e,t,n){var r;n=ma.resolveUrl(this.opts.uriResolver,t,n);let i=e.refs[n];if(i)return i;let s=pfe.call(this,e,n);if(s===void 0){let o=(r=e.localRefs)===null||r===void 0?void 0:r[n],{schemaId:a}=this.opts;if(o)s=new Kh({schema:o,schemaId:a,root:e,baseId:t})}if(s===void 0)return;return e.refs[n]=cfe.call(this,s)}C2.resolveRef=lfe;function cfe(e){if(ma.inlineRef(e.schema,this.opts.inlineRefs))return e.schema;return e.validate?e:Hk.call(this,e)}function F2(e){for(let t of this._compilations)if(ufe(t,e))return t}C2.getCompilingSchema=F2;function ufe(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function pfe(e,t){let n;while(typeof(n=this.refs[t])=="string")t=n;return n||this.schemas[t]||Ix.call(this,e,t)}function Ix(e,t){let n=this.opts.uriResolver.parse(t),r=ma._getFullPath(this.opts.uriResolver,n),i=ma.getFullPath(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&r===i)return Gk.call(this,n,e);let s=ma.normalizeId(r),o=this.refs[s]||this.schemas[s];if(typeof o=="string"){let a=Ix.call(this,e,o);if(typeof(a===null||a===void 0?void 0:a.schema)!=="object")return;return Gk.call(this,n,a)}if(typeof(o===null||o===void 0?void 0:o.schema)!=="object")return;if(!o.validate)Hk.call(this,o);if(s===ma.normalizeId(t)){let{schema:a}=o,{schemaId:l}=this.opts,c=a[l];if(c)i=ma.resolveUrl(this.opts.uriResolver,i,c);return new Kh({schema:a,schemaId:l,root:e,baseId:i})}return Gk.call(this,n,o)}C2.resolveSchema=Ix;var dfe=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function Gk(e,{baseId:t,schema:n,root:r}){var i;if(((i=e.fragment)===null||i===void 0?void 0:i[0])!=="/")return;for(let a of e.fragment.slice(1).split("/")){if(typeof n==="boolean")return;let l=n[j2.unescapeFragment(a)];if(l===void 0)return;n=l;let c=typeof n==="object"&&n[this.opts.schemaId];if(!dfe.has(a)&&c)t=ma.resolveUrl(this.opts.uriResolver,t,c)}let s;if(typeof n!="boolean"&&n.$ref&&!j2.schemaHasRulesButRef(n,this.RULES)){let a=ma.resolveUrl(this.opts.uriResolver,t,n.$ref);s=Ix.call(this,r,a)}let{schemaId:o}=this.opts;if(s=s||new Kh({schema:n,schemaId:o,root:r,baseId:t}),s.schema!==s.root.schema)return s;return}});var L2=z(function(oGe,gfe){gfe.exports={$id:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON AnySchema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:!1}});var Zk=z(function(aGe,G2){var bfe=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),Wk=RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u),vfe=RegExp.prototype.test.bind(/^\d*$/u),Bp=RegExp.prototype.test.bind(/^[\da-f]{2}$/iu),Qk=RegExp.prototype.test.bind(/^[\da-z\-._~]$/iu),U2=RegExp.prototype.test.bind(/^[A-Za-z0-9\-._~!$&'()*+,;=:@/]$/u),Yk=RegExp.prototype.test.bind(/^[A-Za-z0-9\-._~!$&'()*+,;=:@/?]$/u),_fe=RegExp.prototype.test.bind(/^[A-Za-z0-9\-._~!$&'()*+,;=:]$/u),ds=Array(256);for(let t=0;t<256;t++)ds[t]="%"+"0123456789ABCDEF"[t>>4]+"0123456789ABCDEF"[t&15];function Di(e){if(e<2048)return ds[192|e>>6]+ds[128|e&63];if(e<65536)return ds[224|e>>12]+ds[128|e>>6&63]+ds[128|e&63];return ds[240|e>>18]+ds[128|e>>12&63]+ds[128|e>>6&63]+ds[128|e&63]}function xfe(e){let t="",n=0,r=0;for(r=0;r=48&&n<=57||n>=65&&n<=70||n>=97&&n<=102))return"";t+=e[r];break}for(r+=1;r=48&&n<=57||n>=65&&n<=70||n>=97&&n<=102))return"";t+=e[r]}return t}var wfe=RegExp.prototype.test.bind(/^[\dA-Fa-f]{1,4}$/),Dfe=RegExp.prototype.test.bind(/^[vV][\dA-Fa-f]+\.[A-Za-z\d\-._~!$&'()*+,;=:]+$/),Tfe=RegExp.prototype.test.bind(/^[A-Za-z\d\-._~]$/),Sfe=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function Efe(e){if(e.length===0)return!1;for(let t=0;tn)n=i,t=r}else r=-1,i=0;if(n<2)return e.join(":");let s=e.slice(0,t).join(":"),o=e.slice(t+n).join(":");return s+"::"+o}function kfe(e){let t=e.indexOf("::");if(t!==-1&&e.indexOf("::",t+1)!==-1)return;let n=t===-1?e.split(":"):e.slice(0,t).split(":"),r=t===-1?[]:e.slice(t+2).split(":");if(t!==-1){if(n.length===1&&n[0]==="")n.length=0;if(r.length===1&&r[0]==="")r.length=0}let i=n.concat(r),s=0;for(let a=0;a=8)return;let o=i.slice(0,n.length);for(let a=s;a<8;a++)o.push("0");for(let a=n.length;aPfe[r])}function V2(e,t=!1){if(e.indexOf("%")===-1)return e;let n="";for(let r=0;r57343)t+=Di(i);else if(i<=56319&&n+1=56320&&s<=57343)t+=Di(65536+(i-55296<<10)+(s-56320)),n++;else t+=Di(65533)}else t+=Di(65533)}}return t}function Rfe(e,t=!1){let n="",r=t&&e[0]!=="/";for(let i=0;i57343)n+=Di(o);else if(o<=56319&&i+1=56320&&a<=57343)n+=Di(65536+(o-55296<<10)+(a-56320)),i++;else n+=Di(65533)}else n+=Di(65533)}}return n}function Xk(e,t){let n="";for(let r=0;r57343)n+=Di(s);else if(s<=56319&&r+1=56320&&o<=57343)n+=Di(65536+(s-55296<<10)+(o-56320)),r++;else n+=Di(65533)}else n+=Di(65533)}}return n}function K2(e){return Xk(e,_fe)}function jfe(e){return Xk(e,Yk)}function Ffe(e){return Xk(e,Yk)}function J2(e){return e>=48&&e<=57||e>=65&&e<=90||e>=97&&e<=122||e===42||e===43||e===45||e===46||e===47||e===64||e===95}function Cfe(e){let t="";for(let n=0;n57343)t+=Di(i);else if(i<=56319&&n+1=56320&&s<=57343)t+=Di(65536+(i-55296<<10)+(s-56320)),n++;else t+=Di(65533)}else t+=Di(65533)}}return t}function Mfe(e){let t="";for(let n=0;n65535))return"URI port is malformed.";return}function Gh(e){if(e===void 0)return!1;let t=e.indexOf("%");while(t!==-1){if(t+2>=e.length||!/^[\da-f]{2}$/iu.test(e.slice(t+1,t+3)))return!0;t=e.indexOf("%",t+3)}return!1}function i1(e){return e[0]==="["&&e[e.length-1]==="]"}function fme(e){let t=e[4];return Gh(e[3])||t!==void 0&&!i1(t)&&Gh(t)||Gh(e[6])||Gh(e[7])||Gh(e[8])}function aq(e,t,n,r){if(!t.unicodeSupport&&(!n||!n.unicodeSupport)&&e.host&&!i1(e.host)&&(t.domainHost||n&&n.domainHost)&&r===!1&&sme(e.host))try{e.host=new URL("http://"+e.host).hostname}catch(i){return e.error=e.error||"Host's domain name can not be converted to ASCII: "+i,!0}return!1}function jx(e,t){let n=Object.assign({},t),r={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},i=!1,s=!1,o=!1,a=!1,l=!1,c=!1,u=!1;if(n.reference==="suffix")if(n.scheme)e=n.scheme+":"+e;else e="//"+e;let p=e.match(ume);if(p!==null&&p[1].indexOf("\\")!==-1)r.error="URI authority must not contain a literal backslash.",i=!0;let d=e.match(pme);if(d!==null){let m=d[1],y=m.replace(/[\t\n\r]/g,"");if(y.length>=2){if(y.slice(0,2)!=="//")r.error=r.error||"URI authority must not contain a literal backslash.",i=!0;else if(m.length!==y.length)r.error=r.error||"URI authority introducer must not contain whitespace.",i=!0}}let f=e.match(cme);if(f){if(r.scheme=f[1],r.userinfo=f[3],r.host=f[4],r.port=parseInt(f[5],10),r.path=f[6]||"",r.query=f[7],r.fragment=f[8],r.scheme!==void 0){let h=unescape(r.scheme);if(sq.test(h))r.scheme=h.toLowerCase();else r.error=r.error||"URI scheme is malformed.",c=!0}if(s=fme(f),s)r.error=r.error||"URI contains malformed percent-encoding.";if(isNaN(r.port))r.port=f[5];let m=dme(r,f);if(m!==void 0)r.error=r.error||m,i=!0;if(r.host)if(rq(r.host)===!1){let b=i1(r.host),g=r.host.indexOf("[")!==-1||r.host.indexOf("]")!==-1,x=nq(r.host);if(u=x.isIPV6||x.isIPVFuture===!0,l=g&&(!b||x.error===!0),r.host=u?x.host:x.host.toLowerCase(),l)r.error=r.error||"URI host is malformed.",i=!0}else u=!0;if(r.scheme===void 0&&r.userinfo===void 0&&r.host===void 0&&r.port===void 0&&r.query===void 0&&!r.path)r.reference="same-document";else if(r.scheme===void 0)r.reference="relative";else if(r.fragment===void 0)r.reference="absolute";else r.reference="uri";if(n.reference&&n.reference!=="suffix"&&n.reference!==r.reference)r.error=r.error||"URI is not a "+n.reference+" reference.";let y=r1(n.scheme||r.scheme);if(!l)a=aq(r,n,y,u);if(e.indexOf("%")!==-1&&r.host!==void 0&&!l){let h=u?r.host:n1(r.host,!0);if(!u)h=n1(h.toLowerCase());r.host=ime(h,u)}if(!y||y&&!y.skipNormalize){if(r.path)r.path=tme(r.path);if(r.query)r.query=Z2(r.query);if(r.fragment)r.fragment=Z2(r.fragment)}if(y&&y.parse){if(y.parse(r,n),y===iq.urn&&r.nid===void 0)o=!0}}else r.error=r.error||"URI can not be parsed.";return{parsed:r,malformedAuthorityOrPort:i,malformedPercentEncoding:s,malformedSchemeSpecific:o,malformedHost:a,malformedScheme:c}}function Fx(e,t){return jx(e,t).parsed}function mme(e,t){return lq(e,t).normalized}function lq(e,t){let{parsed:n,malformedAuthorityOrPort:r,malformedPercentEncoding:i,malformedSchemeSpecific:s,malformedHost:o,malformedScheme:a}=jx(e,t);return{normalized:r||i||s||o||a?e:Vp(n,t),malformedAuthorityOrPort:r,malformedPercentEncoding:i,malformedSchemeSpecific:s,malformedHost:o,malformedScheme:a}}function tq(e,t){if(typeof e!=="string"&&typeof e!=="object")return;let n;try{n=typeof e==="string"?e:Vp(e,t)}catch{return}let{normalized:r,malformedAuthorityOrPort:i,malformedPercentEncoding:s,malformedSchemeSpecific:o,malformedHost:a,malformedScheme:l}=lq(n,t);return i||s||o||a||l?void 0:r}var s1={SCHEMES:iq,normalize:ome,resolve:ame,resolveComponent:oq,equal:lme,serialize:Vp,parse:Fx};Cx.exports=s1;Cx.exports.default=s1;Cx.exports.fastUri=s1});var dq=z(function(pq){Object.defineProperty(pq,"__esModule",{value:!0});var uq=cq();uq.code='require("ajv/dist/runtime/uri").default';pq.default=uq});var cu=z(function(Kl){Object.defineProperty(Kl,"__esModule",{value:!0});Kl.CodeGen=Kl.Name=Kl.nil=Kl.stringify=Kl.str=Kl._=Kl.KeywordCxt=void 0;var hme=Lp();Object.defineProperty(Kl,"KeywordCxt",{enumerable:!0,get:function(){return hme.KeywordCxt}});var Yf=kt();Object.defineProperty(Kl,"_",{enumerable:!0,get:function(){return Yf._}});Object.defineProperty(Kl,"str",{enumerable:!0,get:function(){return Yf.str}});Object.defineProperty(Kl,"stringify",{enumerable:!0,get:function(){return Yf.stringify}});Object.defineProperty(Kl,"nil",{enumerable:!0,get:function(){return Yf.nil}});Object.defineProperty(Kl,"Name",{enumerable:!0,get:function(){return Yf.Name}});Object.defineProperty(Kl,"CodeGen",{enumerable:!0,get:function(){return Yf.CodeGen}});var gme=Qf(),gq=qp(),bme=$k(),Wh=Jh(),vme=kt(),zh=Uh(),Mx=qh(),a1=Kt(),fq=L2(),_me=dq(),bq=(e,t)=>new RegExp(e,t);bq.code="new RegExp";var xme=["removeAdditional","useDefaults","coerceTypes"],wme=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),Dme={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},Tme={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},mq=200;function Sme(e){var t,n,r,i,s,o,a,l,c,u,p,d,f,m,y,h,b,g,x,v,D,T,N,O,C;let X=e.strict,te=(t=e.code)===null||t===void 0?void 0:t.optimize,L=te===!0||te===void 0?1:te||0,Y=(r=(n=e.code)===null||n===void 0?void 0:n.regExp)!==null&&r!==void 0?r:bq,me=(i=e.uriResolver)!==null&&i!==void 0?i:_me.default;return{strictSchema:(o=(s=e.strictSchema)!==null&&s!==void 0?s:X)!==null&&o!==void 0?o:!0,strictNumbers:(l=(a=e.strictNumbers)!==null&&a!==void 0?a:X)!==null&&l!==void 0?l:!0,strictTypes:(u=(c=e.strictTypes)!==null&&c!==void 0?c:X)!==null&&u!==void 0?u:"log",strictTuples:(d=(p=e.strictTuples)!==null&&p!==void 0?p:X)!==null&&d!==void 0?d:"log",strictRequired:(m=(f=e.strictRequired)!==null&&f!==void 0?f:X)!==null&&m!==void 0?m:!1,code:e.code?{...e.code,optimize:L,regExp:Y}:{optimize:L,regExp:Y},loopRequired:(y=e.loopRequired)!==null&&y!==void 0?y:mq,loopEnum:(h=e.loopEnum)!==null&&h!==void 0?h:mq,meta:(b=e.meta)!==null&&b!==void 0?b:!0,messages:(g=e.messages)!==null&&g!==void 0?g:!0,inlineRefs:(x=e.inlineRefs)!==null&&x!==void 0?x:!0,schemaId:(v=e.schemaId)!==null&&v!==void 0?v:"$id",addUsedSchema:(D=e.addUsedSchema)!==null&&D!==void 0?D:!0,validateSchema:(T=e.validateSchema)!==null&&T!==void 0?T:!0,validateFormats:(N=e.validateFormats)!==null&&N!==void 0?N:!0,unicodeRegExp:(O=e.unicodeRegExp)!==null&&O!==void 0?O:!0,int32range:(C=e.int32range)!==null&&C!==void 0?C:!0,uriResolver:me}}class Lx{constructor(e={}){this.schemas={},this.refs={},this.formats=Object.create(null),this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts={...e,...Sme(e)};let{es5:t,lines:n}=this.opts.code;this.scope=new vme.ValueScope({scope:{},prefixes:wme,es5:t,lines:n}),this.logger=$me(e.logger);let r=e.validateFormats;if(e.validateFormats=!1,this.RULES=bme.getRules(),yq.call(this,Dme,e,"NOT SUPPORTED"),yq.call(this,Tme,e,"DEPRECATED","warn"),this._metaOpts=Ome.call(this),e.formats)kme.call(this);if(this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords)Nme.call(this,e.keywords);if(typeof e.meta=="object")this.addMetaSchema(e.meta);Eme.call(this),e.validateFormats=r}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:e,meta:t,schemaId:n}=this.opts,r=fq;if(n==="id")r={...fq},r.id=r.$id,delete r.$id;if(t&&e)this.addMetaSchema(r,r[n],!1)}defaultMeta(){let{meta:e,schemaId:t}=this.opts;return this.opts.defaultMeta=typeof e=="object"?e[t]||e:void 0}validate(e,t){let n;if(typeof e=="string"){if(n=this.getSchema(e),!n)throw Error(`no schema with key or ref "${e}"`)}else n=this.compile(e);let r=n(t);if(!("$async"in n))this.errors=n.errors;return r}compile(e,t){let n=this._addSchema(e,t);return n.validate||this._compileSchemaEnv(n)}compileAsync(e,t){if(typeof this.opts.loadSchema!="function")throw Error("options.loadSchema should be a function");let{loadSchema:n}=this.opts;return r.call(this,e,t);async function r(c,u){await i.call(this,c.$schema);let p=this._addSchema(c,u);return p.validate||s.call(this,p)}async function i(c){if(c&&!this.getSchema(c))await r.call(this,{$ref:c},!0)}async function s(c){try{return this._compileSchemaEnv(c)}catch(u){if(!(u instanceof gq.default))throw u;return o.call(this,u),await a.call(this,u.missingSchema),s.call(this,c)}}function o({missingSchema:c,missingRef:u}){if(this.refs[c])throw Error(`AnySchema ${c} is loaded but ${u} cannot be resolved`)}async function a(c){let u=await l.call(this,c);if(!this.refs[c])await i.call(this,u.$schema);if(!this.refs[c])this.addSchema(u,c,t)}async function l(c){let u=this._loading[c];if(u)return u;try{return await(this._loading[c]=n(c))}finally{delete this._loading[c]}}}addSchema(e,t,n,r=this.opts.validateSchema){if(Array.isArray(e)){for(let s of e)this.addSchema(s,void 0,n,r);return this}let i;if(typeof e==="object"){let{schemaId:s}=this.opts;if(i=e[s],i!==void 0&&typeof i!="string")throw Error(`schema ${s} must be string`)}return t=zh.normalizeId(t||i),this._checkUnique(t),this.schemas[t]=this._addSchema(e,n,t,r,!0),this}addMetaSchema(e,t,n=this.opts.validateSchema){return this.addSchema(e,t,!0,n),this}validateSchema(e,t){if(typeof e=="boolean")return!0;let n;if(n=e.$schema,n!==void 0&&typeof n!="string")throw Error("$schema must be a string");if(n=n||this.opts.defaultMeta||this.defaultMeta(),!n)return this.logger.warn("meta-schema not available"),this.errors=null,!0;let r=this.validate(n,e);if(!r&&t){let i="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(i);else throw Error(i)}return r}getSchema(e){let t;while(typeof(t=hq.call(this,e))=="string")e=t;if(t===void 0){let{schemaId:n}=this.opts,r=new Wh.SchemaEnv({schema:{},schemaId:n});if(t=Wh.resolveSchema.call(this,r,e),!t)return;this.refs[e]=t}return t.validate||this._compileSchemaEnv(t)}removeSchema(e){if(e instanceof RegExp)return this._removeAllSchemas(this.schemas,e),this._removeAllSchemas(this.refs,e),this;switch(typeof e){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{let t=hq.call(this,e);if(typeof t=="object")this._cache.delete(t.schema);return delete this.schemas[e],delete this.refs[e],this}case"object":{let t=e;this._cache.delete(t);let n=e[this.opts.schemaId];if(n)n=zh.normalizeId(n),delete this.schemas[n],delete this.refs[n];return this}default:throw Error("ajv.removeSchema: invalid parameter")}}addVocabulary(e){for(let t of e)this.addKeyword(t);return this}addKeyword(e,t){let n;if(typeof e=="string"){if(n=e,typeof t=="object")this.logger.warn("these parameters are deprecated, see docs for addKeyword"),t.keyword=n}else if(typeof e=="object"&&t===void 0){if(t=e,n=t.keyword,Array.isArray(n)&&!n.length)throw Error("addKeywords: keyword must be string or non-empty array")}else throw Error("invalid addKeywords parameters");if(Ame.call(this,n,t),!t)return a1.eachItem(n,(i)=>o1.call(this,i)),this;jme.call(this,t);let r={...t,type:Mx.getJSONTypes(t.type),schemaType:Mx.getJSONTypes(t.schemaType)};return a1.eachItem(n,r.type.length===0?(i)=>o1.call(this,i,r):(i)=>r.type.forEach((s)=>o1.call(this,i,r,s))),this}getKeyword(e){let t=this.RULES.all[e];return typeof t=="object"?t.definition:!!t}removeKeyword(e){let{RULES:t}=this;delete t.keywords[e],delete t.all[e];for(let n of t.rules){let r=n.rules.findIndex((i)=>i.keyword===e);if(r>=0)n.rules.splice(r,1)}return this}addFormat(e,t){if(typeof t=="string")t=new RegExp(t);return this.formats[e]=t,this}errorsText(e=this.errors,{separator:t=", ",dataVar:n="data"}={}){if(!e||e.length===0)return"No errors";return e.map((r)=>`${n}${r.instancePath} ${r.message}`).reduce((r,i)=>r+t+i)}$dataMetaSchema(e,t){let n=this.RULES.all;e=JSON.parse(JSON.stringify(e));for(let r of t){let i=r.split("/").slice(1),s=e;for(let o of i)s=s[o];for(let o in n){let a=n[o];if(typeof a!="object")continue;let{$data:l}=a.definition,c=s[o];if(l&&c)s[o]=vq(c)}}return e}_removeAllSchemas(e,t){for(let n in e){let r=e[n];if(!t||t.test(n)){if(typeof r=="string")delete e[n];else if(r&&!r.meta)this._cache.delete(r.schema),delete e[n]}}}_addSchema(e,t,n,r=this.opts.validateSchema,i=this.opts.addUsedSchema){let s,{schemaId:o}=this.opts;if(typeof e=="object")s=e[o];else if(this.opts.jtd)throw Error("schema must be object");else if(typeof e!="boolean")throw Error("schema must be object or boolean");let a=this._cache.get(e);if(a!==void 0)return a;n=zh.normalizeId(s||n);let l=zh.getSchemaRefs.call(this,e,n);if(a=new Wh.SchemaEnv({schema:e,schemaId:o,meta:t,baseId:n,localRefs:l}),this._cache.set(a.schema,a),i&&!n.startsWith("#")){if(n)this._checkUnique(n);this.refs[n]=a}if(r)this.validateSchema(e,!0);return a}_checkUnique(e){if(this.schemas[e]||this.refs[e])throw Error(`schema with key or id "${e}" already exists`)}_compileSchemaEnv(e){if(e.meta)this._compileMetaSchema(e);else Wh.compileSchema.call(this,e);if(!e.validate)throw Error("ajv implementation error");return e.validate}_compileMetaSchema(e){let t=this.opts;this.opts=this._metaOpts;try{Wh.compileSchema.call(this,e)}finally{this.opts=t}}}Lx.ValidationError=gme.default;Lx.MissingRefError=gq.default;Kl.default=Lx;function yq(e,t,n,r="error"){for(let i in e){let s=i;if(s in t)this.logger[r](`${n}: option ${i}. ${e[s]}`)}}function hq(e){return e=zh.normalizeId(e),this.schemas[e]||this.refs[e]}function Eme(){let e=this.opts.schemas;if(!e)return;if(Array.isArray(e))this.addSchema(e);else for(let t in e)this.addSchema(e[t],t)}function kme(){for(let e in this.opts.formats){let t=this.opts.formats[e];if(t)this.addFormat(e,t)}}function Nme(e){if(Array.isArray(e)){this.addVocabulary(e);return}this.logger.warn("keywords option as map is deprecated, pass array");for(let t in e){let n=e[t];if(!n.keyword)n.keyword=t;this.addKeyword(n)}}function Ome(){let e={...this.opts};for(let t of xme)delete e[t];return e}var Pme={log(){},warn(){},error(){}};function $me(e){if(e===!1)return Pme;if(e===void 0)return console;if(e.log&&e.warn&&e.error)return e;throw Error("logger must implement log, warn and error methods")}var Ime=/^[a-z_$][a-z0-9_$:-]*$/i;function Ame(e,t){let{RULES:n}=this;if(a1.eachItem(e,(r)=>{if(n.keywords[r])throw Error(`Keyword ${r} is already defined`);if(!Ime.test(r))throw Error(`Keyword ${r} has invalid name`)}),!t)return;if(t.$data&&!(("code"in t)||("validate"in t)))throw Error('$data keyword must have "code" or "validate" function')}function o1(e,t,n){var r;let i=t===null||t===void 0?void 0:t.post;if(n&&i)throw Error('keyword with "post" flag cannot have "type"');let{RULES:s}=this,o=i?s.post:s.rules.find(({type:l})=>l===n);if(!o)o={type:n,rules:[]},s.rules.push(o);if(s.keywords[e]=!0,!t)return;let a={keyword:e,definition:{...t,type:Mx.getJSONTypes(t.type),schemaType:Mx.getJSONTypes(t.schemaType)}};if(t.before)Rme.call(this,o,a,t.before);else o.rules.push(a);s.all[e]=a,(r=t.implements)===null||r===void 0||r.forEach((l)=>this.addKeyword(l))}function Rme(e,t,n){let r=e.rules.findIndex((i)=>i.keyword===n);if(r>=0)e.rules.splice(r,0,t);else e.rules.push(t),this.logger.warn(`rule ${n} is not defined`)}function jme(e){let{metaSchema:t}=e;if(t===void 0)return;if(e.$data&&this.opts.$data)t=vq(t);e.validateSchema=this.compile(t,!0)}var Fme={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function vq(e){return{anyOf:[e,Fme]}}});var xq=z(function(_q){Object.defineProperty(_q,"__esModule",{value:!0});var Lme={keyword:"id",code(){throw Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};_q.default=Lme});var Qh=z(function(Sq){Object.defineProperty(Sq,"__esModule",{value:!0});Sq.callRef=Sq.getValidate=void 0;var Ume=qp(),wq=_o(),fs=kt(),Xf=vo(),Dq=Jh(),qx=Kt(),Bme={keyword:"$ref",schemaType:"string",code(e){let{gen:t,schema:n,it:r}=e,{baseId:i,schemaEnv:s,validateName:o,opts:a,self:l}=r,{root:c}=s;if((n==="#"||n==="#/")&&i===c.baseId)return p();let u=Dq.resolveRef.call(l,c,i,n);if(u===void 0)throw new Ume.default(r.opts.uriResolver,i,n);if(u instanceof Dq.SchemaEnv)return d(u);return f(u);function p(){if(s===c)return Ux(e,o,s,s.$async);let m=t.scopeValue("root",{ref:c});return Ux(e,fs._`${m}.validate`,c,c.$async)}function d(m){let y=Tq(e,m);Ux(e,y,m,m.$async)}function f(m){let y=t.scopeValue("schema",a.code.source===!0?{ref:m,code:fs.stringify(m)}:{ref:m}),h=t.name("valid"),b=e.subschema({schema:m,dataTypes:[],schemaPath:fs.nil,topSchemaRef:y,errSchemaPath:n},h);e.mergeEvaluated(b),e.ok(h)}}};function Tq(e,t){let{gen:n}=e;return t.validate?n.scopeValue("validate",{ref:t.validate}):fs._`${n.scopeValue("wrapper",{ref:t})}.validate`}Sq.getValidate=Tq;function Ux(e,t,n,r){let{gen:i,it:s}=e,{allErrors:o,schemaEnv:a,opts:l}=s,c=l.passContext?Xf.default.this:fs.nil;if(r)u();else p();function u(){if(!a.$async)throw Error("async schema referenced by sync schema");let m=i.let("valid");i.try(()=>{if(i.code(fs._`await ${wq.callValidateCode(e,t,c)}`),f(t),!o)i.assign(m,!0)},(y)=>{if(i.if(fs._`!(${y} instanceof ${s.ValidationError})`,()=>i.throw(y)),d(y),!o)i.assign(m,!1)}),e.ok(m)}function p(){e.result(wq.callValidateCode(e,t,c),()=>f(t),()=>d(t))}function d(m){let y=fs._`${m}.errors`;i.assign(Xf.default.vErrors,fs._`${Xf.default.vErrors} === null ? ${y} : ${Xf.default.vErrors}.concat(${y})`),i.assign(Xf.default.errors,fs._`${Xf.default.vErrors}.length`)}function f(m){var y;if(!s.opts.unevaluated)return;let h=(y=n===null||n===void 0?void 0:n.validate)===null||y===void 0?void 0:y.evaluated;if(s.props!==!0)if(h&&!h.dynamicProps){if(h.props!==void 0)s.props=qx.mergeEvaluated.props(i,h.props,s.props)}else{let b=i.var("props",fs._`${m}.evaluated.props`);s.props=qx.mergeEvaluated.props(i,b,s.props,fs.Name)}if(s.items!==!0)if(h&&!h.dynamicItems){if(h.items!==void 0)s.items=qx.mergeEvaluated.items(i,h.items,s.items)}else{let b=i.var("items",fs._`${m}.evaluated.items`);s.items=qx.mergeEvaluated.items(i,b,s.items,fs.Name)}}}Sq.callRef=Ux;Sq.default=Bme});var l1=z(function(kq){Object.defineProperty(kq,"__esModule",{value:!0});var Jme=xq(),Gme=Qh(),Hme=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",Jme.default,Gme.default];kq.default=Hme});var Oq=z(function(Nq){Object.defineProperty(Nq,"__esModule",{value:!0});var Vx=kt(),uu=Vx.operators,Bx={maximum:{okStr:"<=",ok:uu.LTE,fail:uu.GT},minimum:{okStr:">=",ok:uu.GTE,fail:uu.LT},exclusiveMaximum:{okStr:"<",ok:uu.LT,fail:uu.GTE},exclusiveMinimum:{okStr:">",ok:uu.GT,fail:uu.LTE}},Wme={message:({keyword:e,schemaCode:t})=>Vx.str`must be ${Bx[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>Vx._`{comparison: ${Bx[e].okStr}, limit: ${t}}`},Qme={keyword:Object.keys(Bx),type:"number",schemaType:"number",$data:!0,error:Wme,code(e){let{keyword:t,data:n,schemaCode:r}=e;e.fail$data(Vx._`${n} ${Bx[t].fail} ${r} || isNaN(${n})`)}};Nq.default=Qme});var c1=z(function(Pq){Object.defineProperty(Pq,"__esModule",{value:!0});var Yh=kt(),Xme={message:({schemaCode:e})=>Yh.str`must be multiple of ${e}`,params:({schemaCode:e})=>Yh._`{multipleOf: ${e}}`},Zme={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:Xme,code(e){let{gen:t,data:n,schemaCode:r,it:i}=e,s=i.opts.multipleOfPrecision,o=t.let("res"),a=s?Yh._`Math.abs(Math.round(${o}) - ${o}) > 1e-${s}`:Yh._`${o} !== parseInt(${o})`;e.fail$data(Yh._`(${r} === 0 || (${o} = ${n}/${r}, ${a}))`)}};Pq.default=Zme});var Aq=z(function(Iq){Object.defineProperty(Iq,"__esModule",{value:!0});function $q(e){let t=e.length,n=0,r=0,i;while(r=55296&&i<=56319&&rKp._`{limit: ${e}}`},sye={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:iye,code(e){let{keyword:t,data:n,schemaCode:r,it:i}=e,s=t==="maxLength"?Kp.operators.GT:Kp.operators.LT,o=i.opts.unicode===!1?Kp._`${n}.length`:Kp._`${nye.useFunc(e.gen,rye.default)}(${n})`;e.fail$data(Kp._`${o} ${s} ${r}`)}};Rq.default=sye});var p1=z(function(jq){Object.defineProperty(jq,"__esModule",{value:!0});var aye=_o(),lye=Kt(),Zf=kt(),cye={message:({schemaCode:e})=>Zf.str`must match pattern "${e}"`,params:({schemaCode:e})=>Zf._`{pattern: ${e}}`},uye={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:cye,code(e){let{gen:t,data:n,$data:r,schema:i,schemaCode:s,it:o}=e,a=o.opts.unicodeRegExp?"u":"";if(r){let{regExp:l}=o.opts.code,c=l.code==="new RegExp"?Zf._`new RegExp`:lye.useFunc(t,l),u=t.let("valid");t.try(()=>t.assign(u,Zf._`${c}(${s}, ${a}).test(${n})`),()=>t.assign(u,!1)),e.fail$data(Zf._`!${u}`)}else{let l=aye.usePattern(e,i);e.fail$data(Zf._`!${l}.test(${n})`)}}};jq.default=uye});var d1=z(function(Fq){Object.defineProperty(Fq,"__esModule",{value:!0});var Xh=kt(),dye={message({keyword:e,schemaCode:t}){return Xh.str`must NOT have ${e==="maxProperties"?"more":"fewer"} than ${t} properties`},params:({schemaCode:e})=>Xh._`{limit: ${e}}`},fye={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:dye,code(e){let{keyword:t,data:n,schemaCode:r}=e,i=t==="maxProperties"?Xh.operators.GT:Xh.operators.LT;e.fail$data(Xh._`Object.keys(${n}).length ${i} ${r}`)}};Fq.default=fye});var f1=z(function(Cq){Object.defineProperty(Cq,"__esModule",{value:!0});var eg=_o(),Zh=kt(),yye=Kt(),hye={message:({params:{missingProperty:e}})=>Zh.str`must have required property '${e}'`,params:({params:{missingProperty:e}})=>Zh._`{missingProperty: ${e}}`},gye={keyword:"required",type:"object",schemaType:"array",$data:!0,error:hye,code(e){let{gen:t,schema:n,schemaCode:r,data:i,$data:s,it:o}=e,{opts:a}=o;if(!s&&n.length===0)return;let l=n.length>=a.loopRequired;if(o.allErrors)c();else u();if(a.strictRequired){let f=e.parentSchema.properties,{definedProperties:m}=e.it;for(let y of n)if((f===null||f===void 0?void 0:f[y])===void 0&&!m.has(y)){let h=o.schemaEnv.baseId+o.errSchemaPath,b=`required property "${y}" is not defined at "${h}" (strictRequired)`;yye.checkStrictMode(o,b,o.opts.strictRequired)}}function c(){if(l||s)e.block$data(Zh.nil,p);else for(let f of n)eg.checkReportMissingProp(e,f)}function u(){let f=t.let("missing");if(l||s){let m=t.let("valid",!0);e.block$data(m,()=>d(f,m)),e.ok(m)}else t.if(eg.checkMissingProp(e,n,f)),eg.reportMissingProp(e,f),t.else()}function p(){t.forOf("prop",r,(f)=>{e.setParams({missingProperty:f}),t.if(eg.noPropertyInData(t,i,f,a.ownProperties),()=>e.error())})}function d(f,m){e.setParams({missingProperty:f}),t.forOf(f,r,()=>{t.assign(m,eg.propertyInData(t,i,f,a.ownProperties)),t.if(Zh.not(m),()=>{e.error(),t.break()})},Zh.nil)}}};Cq.default=gye});var m1=z(function(Mq){Object.defineProperty(Mq,"__esModule",{value:!0});var tg=kt(),vye={message({keyword:e,schemaCode:t}){return tg.str`must NOT have ${e==="maxItems"?"more":"fewer"} than ${t} items`},params:({schemaCode:e})=>tg._`{limit: ${e}}`},_ye={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:vye,code(e){let{keyword:t,data:n,schemaCode:r}=e,i=t==="maxItems"?tg.operators.GT:tg.operators.LT;e.fail$data(tg._`${n}.length ${i} ${r}`)}};Mq.default=_ye});var Kx=z(function(qq){Object.defineProperty(qq,"__esModule",{value:!0});var Lq=Lk();Lq.code='require("ajv/dist/runtime/equal").default';qq.default=Lq});var h1=z(function(Uq){Object.defineProperty(Uq,"__esModule",{value:!0});var y1=qh(),li=kt(),Dye=Kt(),Tye=Kx(),Sye={message:({params:{i:e,j:t}})=>li.str`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>li._`{i: ${e}, j: ${t}}`},Eye={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:Sye,code(e){let{gen:t,data:n,$data:r,schema:i,parentSchema:s,schemaCode:o,it:a}=e;if(!r&&!i)return;let l=t.let("valid"),c=s.items?y1.getSchemaTypes(s.items):[];e.block$data(l,u,li._`${o} === false`),e.ok(l);function u(){let m=t.let("i",li._`${n}.length`),y=t.let("j");e.setParams({i:m,j:y}),t.assign(l,!0),t.if(li._`${m} > 1`,()=>(p()?d:f)(m,y))}function p(){return c.length>0&&!c.some((m)=>m==="object"||m==="array")}function d(m,y){let h=t.name("item"),b=y1.checkDataTypes(c,h,a.opts.strictNumbers,y1.DataType.Wrong),g=t.const("indices",li._`{}`);t.for(li._`;${m}--;`,()=>{if(t.let(h,li._`${n}[${m}]`),t.if(b,li._`continue`),c.length>1)t.if(li._`typeof ${h} == "string"`,li._`${h} += "_"`);t.if(li._`typeof ${g}[${h}] == "number"`,()=>{t.assign(y,li._`${g}[${h}]`),e.error(),t.assign(l,!1).break()}).code(li._`${g}[${h}] = ${m}`)})}function f(m,y){let h=Dye.useFunc(t,Tye.default),b=t.name("outer");t.label(b).for(li._`;${m}--;`,()=>t.for(li._`${y} = ${m}; ${y}--;`,()=>t.if(li._`${h}(${n}[${m}], ${n}[${y}])`,()=>{e.error(),t.assign(l,!1).break(b)})))}}};Uq.default=Eye});var b1=z(function(Bq){Object.defineProperty(Bq,"__esModule",{value:!0});var g1=kt(),Nye=Kt(),Oye=Kx(),Pye={message:"must be equal to constant",params:({schemaCode:e})=>g1._`{allowedValue: ${e}}`},$ye={keyword:"const",$data:!0,error:Pye,code(e){let{gen:t,data:n,$data:r,schemaCode:i,schema:s}=e;if(r||s&&typeof s=="object")e.fail$data(g1._`!${Nye.useFunc(t,Oye.default)}(${n}, ${i})`);else e.fail(g1._`${s} !== ${n}`)}};Bq.default=$ye});var v1=z(function(Vq){Object.defineProperty(Vq,"__esModule",{value:!0});var ng=kt(),Aye=Kt(),Rye=Kx(),jye={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>ng._`{allowedValues: ${e}}`},Fye={keyword:"enum",schemaType:"array",$data:!0,error:jye,code(e){let{gen:t,data:n,$data:r,schema:i,schemaCode:s,it:o}=e;if(!r&&i.length===0)throw Error("enum must have non-empty array");let a=i.length>=o.opts.loopEnum,l,c=()=>l!==null&&l!==void 0?l:l=Aye.useFunc(t,Rye.default),u;if(a||r)u=t.let("valid"),e.block$data(u,p);else{if(!Array.isArray(i))throw Error("ajv implementation error");let f=t.const("vSchema",s);u=ng.or(...i.map((m,y)=>d(f,y)))}e.pass(u);function p(){t.assign(u,!1),t.forOf("v",s,(f)=>t.if(ng._`${c()}(${n}, ${f})`,()=>t.assign(u,!0).break()))}function d(f,m){let y=i[m];return typeof y==="object"&&y!==null?ng._`${c()}(${n}, ${f}[${m}])`:ng._`${n} === ${y}`}}};Vq.default=Fye});var _1=z(function(Kq){Object.defineProperty(Kq,"__esModule",{value:!0});var Mye=Oq(),Lye=c1(),qye=u1(),Uye=p1(),Bye=d1(),Vye=f1(),Kye=m1(),Jye=h1(),Gye=b1(),Hye=v1(),zye=[Mye.default,Lye.default,qye.default,Uye.default,Bye.default,Vye.default,Kye.default,Jye.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},Gye.default,Hye.default];Kq.default=zye});var w1=z(function(Gq){Object.defineProperty(Gq,"__esModule",{value:!0});Gq.validateAdditionalItems=void 0;var Jp=kt(),x1=Kt(),Qye={message:({params:{len:e}})=>Jp.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>Jp._`{limit: ${e}}`},Yye={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:Qye,code(e){let{parentSchema:t,it:n}=e,{items:r}=t;if(!Array.isArray(r)){x1.checkStrictMode(n,'"additionalItems" is ignored when "items" is not an array of schemas');return}Jq(e,r)}};function Jq(e,t){let{gen:n,schema:r,data:i,keyword:s,it:o}=e;o.items=!0;let a=n.const("len",Jp._`${i}.length`);if(r===!1)e.setParams({len:t.length}),e.pass(Jp._`${a} <= ${t.length}`);else if(typeof r=="object"&&!x1.alwaysValidSchema(o,r)){let c=n.var("valid",Jp._`${a} <= ${t.length}`);n.if(Jp.not(c),()=>l(c)),e.ok(c)}function l(c){n.forRange("i",t.length,a,(u)=>{if(e.subschema({keyword:s,dataProp:u,dataPropType:x1.Type.Num},c),!o.allErrors)n.if(Jp.not(c),()=>n.break())})}}Gq.validateAdditionalItems=Jq;Gq.default=Yye});var D1=z(function(Qq){Object.defineProperty(Qq,"__esModule",{value:!0});Qq.validateTuple=void 0;var zq=kt(),Jx=Kt(),Zye=_o(),ehe={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){let{schema:t,it:n}=e;if(Array.isArray(t))return Wq(e,"additionalItems",t);if(n.items=!0,Jx.alwaysValidSchema(n,t))return;e.ok(Zye.validateArray(e))}};function Wq(e,t,n=e.schema){let{gen:r,parentSchema:i,data:s,keyword:o,it:a}=e;if(u(i),a.opts.unevaluated&&n.length&&a.items!==!0)a.items=Jx.mergeEvaluated.items(r,n.length,a.items);let l=r.name("valid"),c=r.const("len",zq._`${s}.length`);n.forEach((p,d)=>{if(Jx.alwaysValidSchema(a,p))return;r.if(zq._`${c} > ${d}`,()=>e.subschema({keyword:o,schemaProp:d,dataProp:d},l)),e.ok(l)});function u(p){let{opts:d,errSchemaPath:f}=a,m=n.length,y=m===p.minItems&&(m===p.maxItems||p[t]===!1);if(d.strictTuples&&!y){let h=`"${o}" is ${m}-tuple, but minItems or maxItems/${t} are not specified or different at path "${f}"`;Jx.checkStrictMode(a,h,d.strictTuples)}}}Qq.validateTuple=Wq;Qq.default=ehe});var Zq=z(function(Xq){Object.defineProperty(Xq,"__esModule",{value:!0});var nhe=D1(),rhe={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:(e)=>nhe.validateTuple(e,"items")};Xq.default=rhe});var nU=z(function(tU){Object.defineProperty(tU,"__esModule",{value:!0});var eU=kt(),she=Kt(),ohe=_o(),ahe=w1(),lhe={message:({params:{len:e}})=>eU.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>eU._`{limit: ${e}}`},che={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:lhe,code(e){let{schema:t,parentSchema:n,it:r}=e,{prefixItems:i}=n;if(r.items=!0,she.alwaysValidSchema(r,t))return;if(i)ahe.validateAdditionalItems(e,i);else e.ok(ohe.validateArray(e))}};tU.default=che});var iU=z(function(rU){Object.defineProperty(rU,"__esModule",{value:!0});var xo=kt(),Gx=Kt(),phe={message:({params:{min:e,max:t}})=>t===void 0?xo.str`must contain at least ${e} valid item(s)`:xo.str`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?xo._`{minContains: ${e}}`:xo._`{minContains: ${e}, maxContains: ${t}}`},dhe={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:phe,code(e){let{gen:t,schema:n,parentSchema:r,data:i,it:s}=e,o,a,{minContains:l,maxContains:c}=r;if(s.opts.next)o=l===void 0?1:l,a=c;else o=1;let u=t.const("len",xo._`${i}.length`);if(e.setParams({min:o,max:a}),a===void 0&&o===0){Gx.checkStrictMode(s,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(a!==void 0&&o>a){Gx.checkStrictMode(s,'"minContains" > "maxContains" is always invalid'),e.fail();return}if(Gx.alwaysValidSchema(s,n)){let y=xo._`${u} >= ${o}`;if(a!==void 0)y=xo._`${y} && ${u} <= ${a}`;e.pass(y);return}s.items=!0;let p=t.name("valid");if(a===void 0&&o===1)f(p,()=>t.if(p,()=>t.break()));else if(o===0){if(t.let(p,!0),a!==void 0)t.if(xo._`${i}.length > 0`,d)}else t.let(p,!1),d();e.result(p,()=>e.reset());function d(){let y=t.name("_valid"),h=t.let("count",0);f(y,()=>t.if(y,()=>m(h)))}function f(y,h){t.forRange("i",0,u,(b)=>{e.subschema({keyword:"contains",dataProp:b,dataPropType:Gx.Type.Num,compositeRule:!0},y),h()})}function m(y){if(t.code(xo._`${y}++`),a===void 0)t.if(xo._`${y} >= ${o}`,()=>t.assign(p,!0).break());else if(t.if(xo._`${y} > ${a}`,()=>t.assign(p,!1).break()),o===1)t.assign(p,!0);else t.if(xo._`${y} >= ${o}`,()=>t.assign(p,!0))}}};rU.default=dhe});var Hx=z(function(aU){Object.defineProperty(aU,"__esModule",{value:!0});aU.validateSchemaDeps=aU.validatePropertyDeps=aU.error=void 0;var T1=kt(),mhe=Kt(),rg=_o();aU.error={message:({params:{property:e,depsCount:t,deps:n}})=>T1.str`must have ${t===1?"property":"properties"} ${n} when property ${e} is present`,params:({params:{property:e,depsCount:t,deps:n,missingProperty:r}})=>T1._`{property: ${e}, missingProperty: ${r}, depsCount: ${t}, - deps: ${n}}`};var mhe={keyword:"dependencies",type:"object",schemaType:"object",error:aU.error,code(e){let[t,n]=yhe(e);sU(e,t),oU(e,n)}};function yhe({schema:e}){let t={},n={};for(let r in e){if(r==="__proto__")continue;let i=Array.isArray(e[r])?t:n;i[r]=e[r]}return[t,n]}function sU(e,t=e.schema){let{gen:n,data:r,it:i}=e;if(Object.keys(t).length===0)return;let s=n.let("missing");for(let o in t){let a=t[o];if(a.length===0)continue;let l=rg.propertyInData(n,r,o,i.opts.ownProperties);if(e.setParams({property:o,depsCount:a.length,deps:a.join(", ")}),i.allErrors)n.if(l,()=>{for(let c of a)rg.checkReportMissingProp(e,c)});else n.if(T1._`${l} && (${rg.checkMissingProp(e,a,s)})`),rg.reportMissingProp(e,s),n.else()}}aU.validatePropertyDeps=sU;function oU(e,t=e.schema){let{gen:n,data:r,keyword:i,it:s}=e,o=n.name("valid");for(let a in t){if(fhe.alwaysValidSchema(s,t[a]))continue;n.if(rg.propertyInData(n,r,a,s.opts.ownProperties),()=>{let l=e.subschema({keyword:i,schemaProp:a},o);e.mergeValidEvaluated(l,o)},()=>n.var(o,!0)),e.ok(o)}}aU.validateSchemaDeps=oU;aU.default=mhe});var dU=z(function(pU){Object.defineProperty(pU,"__esModule",{value:!0});var uU=Et(),bhe=Kt(),vhe={message:"property name must be valid",params:({params:e})=>uU._`{propertyName: ${e.propertyName}}`},_he={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:vhe,code(e){let{gen:t,schema:n,data:r,it:i}=e;if(bhe.alwaysValidSchema(i,n))return;let s=t.name("valid");t.forIn("key",r,(o)=>{e.setParams({propertyName:o}),e.subschema({keyword:"propertyNames",data:o,dataTypes:["string"],propertyName:o,compositeRule:!0},s),t.if(uU.not(s),()=>{if(e.error(!0),!i.allErrors)t.break()})}),e.ok(s)}};pU.default=_he});var S1=z(function(fU){Object.defineProperty(fU,"__esModule",{value:!0});var zx=_o(),ya=Et(),whe=vo(),Wx=Kt(),Dhe={message:"must NOT have additional properties",params:({params:e})=>ya._`{additionalProperty: ${e.additionalProperty}}`},The={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:Dhe,code(e){let{gen:t,schema:n,parentSchema:r,data:i,errsCount:s,it:o}=e;if(!s)throw Error("ajv implementation error");let{allErrors:a,opts:l}=o;if(o.props=!0,l.removeAdditional!=="all"&&Wx.alwaysValidSchema(o,n))return;let c=zx.allSchemaProperties(r.properties),u=zx.allSchemaProperties(r.patternProperties);p(),e.ok(ya._`${s} === ${whe.default.errors}`);function p(){t.forIn("key",i,(h)=>{if(!c.length&&!u.length)m(h);else t.if(d(h),()=>m(h))})}function d(h){let b;if(c.length>8){let g=Wx.schemaRefOrVal(o,r.properties,"properties");b=zx.isOwnProperty(t,g,h)}else if(c.length)b=ya.or(...c.map((g)=>ya._`${h} === ${g}`));else b=ya.nil;if(u.length)b=ya.or(b,...u.map((g)=>ya._`${zx.usePattern(e,g)}.test(${h})`));return ya.not(b)}function f(h){t.code(ya._`delete ${i}[${h}]`)}function m(h){if(l.removeAdditional==="all"||l.removeAdditional&&n===!1){f(h);return}if(n===!1){if(e.setParams({additionalProperty:h}),e.error(),!a)t.break();return}if(typeof n=="object"&&!Wx.alwaysValidSchema(o,n)){let b=t.name("valid");if(l.removeAdditional==="failing")y(h,b,!1),t.if(ya.not(b),()=>{e.reset(),f(h)});else if(y(h,b),!a)t.if(ya.not(b),()=>t.break())}}function y(h,b,g){let x={keyword:"additionalProperties",dataProp:h,dataPropType:Wx.Type.Str};if(g===!1)Object.assign(x,{compositeRule:!0,createErrors:!1,allErrors:!1});e.subschema(x,b)}}};fU.default=The});var gU=z(function(hU){Object.defineProperty(hU,"__esModule",{value:!0});var Ehe=Cp(),yU=_o(),E1=Kt(),mU=S1(),khe={keyword:"properties",type:"object",schemaType:"object",code(e){let{gen:t,schema:n,parentSchema:r,data:i,it:s}=e;if(s.opts.removeAdditional==="all"&&r.additionalProperties===void 0)mU.default.code(new Ehe.KeywordCxt(s,mU.default,"additionalProperties"));let o=yU.allSchemaProperties(n);for(let p of o)s.definedProperties.add(p);if(s.opts.unevaluated&&o.length&&s.props!==!0)s.props=E1.mergeEvaluated.props(t,E1.toHash(o),s.props);let a=o.filter((p)=>!E1.alwaysValidSchema(s,n[p]));if(a.length===0)return;let l=t.name("valid");for(let p of a){if(c(p))u(p);else{if(t.if(yU.propertyInData(t,i,p,s.opts.ownProperties)),u(p),!s.allErrors)t.else().var(l,!0);t.endIf()}e.it.definedProperties.add(p),e.ok(l)}function c(p){return s.opts.useDefaults&&!s.compositeRule&&n[p].default!==void 0}function u(p){e.subschema({keyword:"properties",schemaProp:p,dataProp:p},l)}}};hU.default=khe});var wU=z(function(xU){Object.defineProperty(xU,"__esModule",{value:!0});var bU=_o(),Qx=Et(),vU=Kt(),_U=Kt(),Ohe={keyword:"patternProperties",type:"object",schemaType:"object",code(e){let{gen:t,schema:n,data:r,parentSchema:i,it:s}=e,{opts:o}=s,a=bU.allSchemaProperties(n),l=a.filter((y)=>vU.alwaysValidSchema(s,n[y]));if(a.length===0||l.length===a.length&&(!s.opts.unevaluated||s.props===!0))return;let c=o.strictSchema&&!o.allowMatchingProperties&&i.properties,u=t.name("valid");if(s.props!==!0&&!(s.props instanceof Qx.Name))s.props=_U.evaluatedPropsToName(t,s.props);let{props:p}=s;d();function d(){for(let y of a){if(c)f(y);if(s.allErrors)m(y);else t.var(u,!0),m(y),t.if(u)}}function f(y){for(let h in c)if(new RegExp(y).test(h))vU.checkStrictMode(s,`property ${h} matches pattern ${y} (use allowMatchingProperties)`)}function m(y){t.forIn("key",r,(h)=>{t.if(Qx._`${bU.usePattern(e,y)}.test(${h})`,()=>{let b=l.includes(y);if(!b)e.subschema({keyword:"patternProperties",schemaProp:y,dataProp:h,dataPropType:_U.Type.Str},u);if(s.opts.unevaluated&&p!==!0)t.assign(Qx._`${p}[${h}]`,!0);else if(!b&&!s.allErrors)t.if(Qx.not(u),()=>t.break())})})}}};xU.default=Ohe});var TU=z(function(DU){Object.defineProperty(DU,"__esModule",{value:!0});var $he=Kt(),Ihe={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){let{gen:t,schema:n,it:r}=e;if($he.alwaysValidSchema(r,n)){e.fail();return}let i=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},i),e.failResult(i,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};DU.default=Ihe});var EU=z(function(SU){Object.defineProperty(SU,"__esModule",{value:!0});var Rhe=_o(),jhe={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:Rhe.validateUnion,error:{message:"must match a schema in anyOf"}};SU.default=jhe});var NU=z(function(kU){Object.defineProperty(kU,"__esModule",{value:!0});var Yx=Et(),Che=Kt(),Mhe={message:"must match exactly one schema in oneOf",params:({params:e})=>Yx._`{passingSchemas: ${e.passing}}`},Lhe={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:Mhe,code(e){let{gen:t,schema:n,parentSchema:r,it:i}=e;if(!Array.isArray(n))throw Error("ajv implementation error");if(i.opts.discriminator&&r.discriminator)return;let s=n,o=t.let("valid",!1),a=t.let("passing",null),l=t.name("_valid");e.setParams({passing:a}),t.block(c),e.result(o,()=>e.reset(),()=>e.error(!0));function c(){s.forEach((u,p)=>{let d;if(Che.alwaysValidSchema(i,u))t.var(l,!0);else d=e.subschema({keyword:"oneOf",schemaProp:p,compositeRule:!0},l);if(p>0)t.if(Yx._`${l} && ${o}`).assign(o,!1).assign(a,Yx._`[${a}, ${p}]`).else();t.if(l,()=>{if(t.assign(o,!0),t.assign(a,p),d)e.mergeEvaluated(d,Yx.Name)})})}}};kU.default=Lhe});var PU=z(function(OU){Object.defineProperty(OU,"__esModule",{value:!0});var Uhe=Kt(),Bhe={keyword:"allOf",schemaType:"array",code(e){let{gen:t,schema:n,it:r}=e;if(!Array.isArray(n))throw Error("ajv implementation error");let i=t.name("valid");n.forEach((s,o)=>{if(Uhe.alwaysValidSchema(r,s))return;let a=e.subschema({keyword:"allOf",schemaProp:o},i);e.ok(i),e.mergeEvaluated(a)})}};OU.default=Bhe});var RU=z(function(AU){Object.defineProperty(AU,"__esModule",{value:!0});var Xx=Et(),IU=Kt(),Khe={message:({params:e})=>Xx.str`must match "${e.ifClause}" schema`,params:({params:e})=>Xx._`{failingKeyword: ${e.ifClause}}`},Jhe={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:Khe,code(e){let{gen:t,parentSchema:n,it:r}=e;if(n.then===void 0&&n.else===void 0)IU.checkStrictMode(r,'"if" without "then" and "else" is ignored');let i=$U(r,"then"),s=$U(r,"else");if(!i&&!s)return;let o=t.let("valid",!0),a=t.name("_valid");if(l(),e.reset(),i&&s){let u=t.let("ifClause");e.setParams({ifClause:u}),t.if(a,c("then",u),c("else",u))}else if(i)t.if(a,c("then"));else t.if(Xx.not(a),c("else"));e.pass(o,()=>e.error(!0));function l(){let u=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},a);e.mergeEvaluated(u)}function c(u,p){return()=>{let d=e.subschema({keyword:u},a);if(t.assign(o,a),e.mergeValidEvaluated(d,o),p)t.assign(p,Xx._`${u}`);else e.setParams({ifClause:u})}}}};function $U(e,t){let n=e.schema[t];return n!==void 0&&!IU.alwaysValidSchema(e,n)}AU.default=Jhe});var FU=z(function(jU){Object.defineProperty(jU,"__esModule",{value:!0});var Hhe=Kt(),zhe={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:n}){if(t.if===void 0)Hhe.checkStrictMode(n,`"${e}" without "if" is ignored`)}};jU.default=zhe});var Zx=z(function(CU){Object.defineProperty(CU,"__esModule",{value:!0});var Qhe=w1(),Yhe=Zq(),Xhe=D1(),Zhe=nU(),ege=iU(),tge=Hx(),nge=dU(),rge=S1(),ige=gU(),sge=wU(),oge=TU(),age=EU(),lge=NU(),cge=PU(),uge=RU(),pge=FU();function dge(e=!1){let t=[oge.default,age.default,lge.default,cge.default,uge.default,pge.default,nge.default,rge.default,tge.default,ige.default,sge.default];if(e)t.push(Yhe.default,Zhe.default);else t.push(Qhe.default,Xhe.default);return t.push(ege.default),t}CU.default=dge});var N1=z(function(qU){Object.defineProperty(qU,"__esModule",{value:!0});qU.dynamicAnchor=void 0;var k1=Et(),mge=vo(),MU=Jh(),yge=Qh(),hge={keyword:"$dynamicAnchor",schemaType:"string",code:(e)=>LU(e,e.schema)};function LU(e,t){let{gen:n,it:r}=e;r.schemaEnv.root.dynamicAnchors[t]=!0;let i=k1._`${mge.default.dynamicAnchors}${k1.getProperty(t)}`,s=r.errSchemaPath==="#"?r.validateName:gge(e);n.if(k1._`!${i}`,()=>n.assign(i,s))}qU.dynamicAnchor=LU;function gge(e){let{schemaEnv:t,schema:n,self:r}=e.it,{root:i,baseId:s,localRefs:o,meta:a}=t.root,{schemaId:l}=r.opts,c=new MU.SchemaEnv({schema:n,schemaId:l,root:i,baseId:s,localRefs:o,meta:a});return MU.compileSchema.call(r,c),yge.getValidate(e,c)}qU.default=hge});var O1=z(function(JU){Object.defineProperty(JU,"__esModule",{value:!0});JU.dynamicRef=void 0;var VU=Et(),vge=vo(),BU=Qh(),_ge={keyword:"$dynamicRef",schemaType:"string",code:(e)=>KU(e,e.schema)};function KU(e,t){let{gen:n,keyword:r,it:i}=e;if(t[0]!=="#")throw Error(`"${r}" only supports hash fragment reference`);let s=t.slice(1);if(i.allErrors)o();else{let l=n.let("valid",!1);o(l),e.ok(l)}function o(l){if(i.schemaEnv.root.dynamicAnchors[s]){let c=n.let("_v",VU._`${vge.default.dynamicAnchors}${VU.getProperty(s)}`);n.if(c,a(c,l),a(i.validateName,l))}else a(i.validateName,l)()}function a(l,c){return c?()=>n.block(()=>{BU.callRef(e,l),n.let(c,!0)}):()=>BU.callRef(e,l)}}JU.dynamicRef=KU;JU.default=_ge});var zU=z(function(HU){Object.defineProperty(HU,"__esModule",{value:!0});var wge=N1(),Dge=Kt(),Tge={keyword:"$recursiveAnchor",schemaType:"boolean",code(e){if(e.schema)wge.dynamicAnchor(e,"");else Dge.checkStrictMode(e.it,"$recursiveAnchor: false is ignored")}};HU.default=Tge});var QU=z(function(WU){Object.defineProperty(WU,"__esModule",{value:!0});var Ege=O1(),kge={keyword:"$recursiveRef",schemaType:"string",code:(e)=>Ege.dynamicRef(e,e.schema)};WU.default=kge});var P1=z(function(YU){Object.defineProperty(YU,"__esModule",{value:!0});var Oge=N1(),Pge=O1(),$ge=zU(),Ige=QU(),Age=[Oge.default,Pge.default,$ge.default,Ige.default];YU.default=Age});var e3=z(function(ZU){Object.defineProperty(ZU,"__esModule",{value:!0});var XU=Hx(),jge={keyword:"dependentRequired",type:"object",schemaType:"object",error:XU.error,code:(e)=>XU.validatePropertyDeps(e)};ZU.default=jge});var n3=z(function(t3){Object.defineProperty(t3,"__esModule",{value:!0});var Cge=Hx(),Mge={keyword:"dependentSchemas",type:"object",schemaType:"object",code:(e)=>Cge.validateSchemaDeps(e)};t3.default=Mge});var i3=z(function(r3){Object.defineProperty(r3,"__esModule",{value:!0});var qge=Kt(),Uge={keyword:["maxContains","minContains"],type:"array",schemaType:"number",code({keyword:e,parentSchema:t,it:n}){if(t.contains===void 0)qge.checkStrictMode(n,`"${e}" without "contains" is ignored`)}};r3.default=Uge});var $1=z(function(s3){Object.defineProperty(s3,"__esModule",{value:!0});var Vge=e3(),Kge=n3(),Jge=i3(),Gge=[Vge.default,Kge.default,Jge.default];s3.default=Gge});var l3=z(function(a3){Object.defineProperty(a3,"__esModule",{value:!0});var uu=Et(),o3=Kt(),zge=vo(),Wge={message:"must NOT have unevaluated properties",params:({params:e})=>uu._`{unevaluatedProperty: ${e.unevaluatedProperty}}`},Qge={keyword:"unevaluatedProperties",type:"object",schemaType:["boolean","object"],trackErrors:!0,error:Wge,code(e){let{gen:t,schema:n,data:r,errsCount:i,it:s}=e;if(!i)throw Error("ajv implementation error");let{allErrors:o,props:a}=s;if(a instanceof uu.Name)t.if(uu._`${a} !== true`,()=>t.forIn("key",r,(p)=>t.if(c(a,p),()=>l(p))));else if(a!==!0)t.forIn("key",r,(p)=>a===void 0?l(p):t.if(u(a,p),()=>l(p)));s.props=!0,e.ok(uu._`${i} === ${zge.default.errors}`);function l(p){if(n===!1){if(e.setParams({unevaluatedProperty:p}),e.error(),!o)t.break();return}if(!o3.alwaysValidSchema(s,n)){let d=t.name("valid");if(e.subschema({keyword:"unevaluatedProperties",dataProp:p,dataPropType:o3.Type.Str},d),!o)t.if(uu.not(d),()=>t.break())}}function c(p,d){return uu._`!${p} || !${p}[${d}]`}function u(p,d){let f=[];for(let m in p)if(p[m]===!0)f.push(uu._`${d} !== ${m}`);return uu.and(...f)}}};a3.default=Qge});var p3=z(function(u3){Object.defineProperty(u3,"__esModule",{value:!0});var Kp=Et(),c3=Kt(),Xge={message:({params:{len:e}})=>Kp.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>Kp._`{limit: ${e}}`},Zge={keyword:"unevaluatedItems",type:"array",schemaType:["boolean","object"],error:Xge,code(e){let{gen:t,schema:n,data:r,it:i}=e,s=i.items||0;if(s===!0)return;let o=t.const("len",Kp._`${r}.length`);if(n===!1)e.setParams({len:s}),e.fail(Kp._`${o} > ${s}`);else if(typeof n=="object"&&!c3.alwaysValidSchema(i,n)){let l=t.var("valid",Kp._`${o} <= ${s}`);t.if(Kp.not(l),()=>a(l,s)),e.ok(l)}i.items=!0;function a(l,c){t.forRange("i",c,o,(u)=>{if(e.subschema({keyword:"unevaluatedItems",dataProp:u,dataPropType:c3.Type.Num},l),!i.allErrors)t.if(Kp.not(l),()=>t.break())})}}};u3.default=Zge});var I1=z(function(d3){Object.defineProperty(d3,"__esModule",{value:!0});var tbe=l3(),nbe=p3(),rbe=[tbe.default,nbe.default];d3.default=rbe});var m3=z(function(f3){Object.defineProperty(f3,"__esModule",{value:!0});var fr=Et(),sbe={message:({schemaCode:e})=>fr.str`must match format "${e}"`,params:({schemaCode:e})=>fr._`{format: ${e}}`},obe={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:sbe,code(e,t){let{gen:n,data:r,$data:i,schema:s,schemaCode:o,it:a}=e,{opts:l,errSchemaPath:c,schemaEnv:u,self:p}=a;if(!l.validateFormats)return;if(i)d();else f();function d(){let m=n.scopeValue("formats",{ref:p.formats,code:l.code.formats}),y=n.const("fDef",fr._`${m}[${o}]`),h=n.let("fType"),b=n.let("format");n.if(fr._`typeof ${y} == "object" && !(${y} instanceof RegExp)`,()=>n.assign(h,fr._`${y}.type || "string"`).assign(b,fr._`${y}.validate`),()=>n.assign(h,fr._`"string"`).assign(b,y)),e.fail$data(fr.or(g(),x()));function g(){if(l.strictSchema===!1)return fr.nil;return fr._`${o} && !${b}`}function x(){let v=u.$async?fr._`(${y}.async ? await ${b}(${r}) : ${b}(${r}))`:fr._`${b}(${r})`,D=fr._`(typeof ${b} == "function" ? ${v} : ${b}.test(${r}))`;return fr._`${b} && ${b} !== true && ${h} === ${t} && !${D}`}}function f(){let m=p.formats[s];if(!m){g();return}if(m===!0)return;let[y,h,b]=x(m);if(y===t)e.pass(v());function g(){if(l.strictSchema===!1){p.logger.warn(D());return}throw Error(D());function D(){return`unknown format "${s}" ignored in schema at path "${c}"`}}function x(D){let T=D instanceof RegExp?fr.regexpCode(D):l.code.formats?fr._`${l.code.formats}${fr.getProperty(s)}`:void 0,N=n.scopeValue("formats",{key:s,ref:D,code:T});if(typeof D=="object"&&!(D instanceof RegExp))return[D.type||"string",D.validate,fr._`${N}.validate`];return["string",D,N]}function v(){if(typeof m=="object"&&!(m instanceof RegExp)&&m.async){if(!u.$async)throw Error("async format in sync schema");return fr._`await ${b}(${r})`}return typeof h=="function"?fr._`${b}(${r})`:fr._`${b}.test(${r})`}}}};f3.default=obe});var e0=z(function(y3){Object.defineProperty(y3,"__esModule",{value:!0});var lbe=m3(),cbe=[lbe.default];y3.default=cbe});var A1=z(function(h3){Object.defineProperty(h3,"__esModule",{value:!0});h3.contentVocabulary=h3.metadataVocabulary=void 0;h3.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];h3.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var _3=z(function(v3){Object.defineProperty(v3,"__esModule",{value:!0});var dbe=l1(),fbe=_1(),mbe=Zx(),ybe=P1(),hbe=$1(),gbe=I1(),bbe=e0(),b3=A1(),vbe=[ybe.default,dbe.default,fbe.default,(0,mbe.default)(!0),bbe.default,b3.metadataVocabulary,b3.contentVocabulary,hbe.default,gbe.default];v3.default=vbe});var T3=z(function(w3){Object.defineProperty(w3,"__esModule",{value:!0});w3.DiscrError=void 0;var x3;(function(e){e.Tag="tag",e.Mapping="mapping"})(x3||(w3.DiscrError=x3={}))});var ig=z(function(E3){Object.defineProperty(E3,"__esModule",{value:!0});var Xf=Et(),R1=T3(),S3=Jh(),xbe=Mp(),wbe=Kt(),Dbe={message:({params:{discrError:e,tagName:t}})=>e===R1.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:n}})=>Xf._`{error: ${e}, tag: ${n}, tagValue: ${t}}`},Tbe={keyword:"discriminator",type:"object",schemaType:"object",error:Dbe,code(e){let{gen:t,data:n,schema:r,parentSchema:i,it:s}=e,{oneOf:o}=i;if(!s.opts.discriminator)throw Error("discriminator: requires discriminator option");let a=r.propertyName;if(typeof a!="string")throw Error("discriminator: requires propertyName");if(r.mapping)throw Error("discriminator: mapping is not supported");if(!o)throw Error("discriminator: requires oneOf keyword");let l=t.let("valid",!1),c=t.const("tag",Xf._`${n}${Xf.getProperty(a)}`);t.if(Xf._`typeof ${c} == "string"`,()=>u(),()=>e.error(!1,{discrError:R1.DiscrError.Tag,tag:c,tagName:a})),e.ok(l);function u(){let f=d();t.if(!1);for(let m in f)t.elseIf(Xf._`${c} === ${m}`),t.assign(l,p(f[m]));t.else(),e.error(!1,{discrError:R1.DiscrError.Mapping,tag:c,tagName:a}),t.endIf()}function p(f){let m=t.name("valid"),y=e.subschema({keyword:"oneOf",schemaProp:f},m);return e.mergeEvaluated(y,Xf.Name),m}function d(){var f;let m={},y=b(i),h=!0;for(let v=0;vthis.addMetaSchema(n,void 0,!1)),this;function t(n,r){return e?n.$dataMetaSchema(r,Bbe):r}}j3.default=Vbe});var og=z(function(fs,F1){Object.defineProperty(fs,"__esModule",{value:!0});fs.MissingRefError=fs.ValidationError=fs.CodeGen=fs.Name=fs.nil=fs.stringify=fs.str=fs._=fs.KeywordCxt=fs.Ajv2020=void 0;var Jbe=lu(),Gbe=_3(),Hbe=ig(),zbe=F3(),j1="https://json-schema.org/draft/2020-12/schema";class sg extends Jbe.default{constructor(e={}){super({...e,dynamicRef:!0,next:!0,unevaluated:!0})}_addVocabularies(){if(super._addVocabularies(),Gbe.default.forEach((e)=>this.addVocabulary(e)),this.opts.discriminator)this.addKeyword(Hbe.default)}_addDefaultMetaSchema(){super._addDefaultMetaSchema();let{$data:e,meta:t}=this.opts;if(!t)return;zbe.default.call(this,e),this.refs["http://json-schema.org/schema"]=j1}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(j1)?j1:void 0)}}fs.Ajv2020=sg;F1.exports=fs=sg;F1.exports.Ajv2020=sg;Object.defineProperty(fs,"__esModule",{value:!0});fs.default=sg;var Wbe=Cp();Object.defineProperty(fs,"KeywordCxt",{enumerable:!0,get:function(){return Wbe.KeywordCxt}});var Zf=Et();Object.defineProperty(fs,"_",{enumerable:!0,get:function(){return Zf._}});Object.defineProperty(fs,"str",{enumerable:!0,get:function(){return Zf.str}});Object.defineProperty(fs,"stringify",{enumerable:!0,get:function(){return Zf.stringify}});Object.defineProperty(fs,"nil",{enumerable:!0,get:function(){return Zf.nil}});Object.defineProperty(fs,"Name",{enumerable:!0,get:function(){return Zf.Name}});Object.defineProperty(fs,"CodeGen",{enumerable:!0,get:function(){return Zf.CodeGen}});var Qbe=zf();Object.defineProperty(fs,"ValidationError",{enumerable:!0,get:function(){return Qbe.default}});var Ybe=Mp();Object.defineProperty(fs,"MissingRefError",{enumerable:!0,get:function(){return Ybe.default}})});var u0={};kf(u0,{Blob:()=>Nve,Buffer:()=>xe,File:()=>kve,INSPECT_MAX_BYTES:()=>FB,atob:()=>Eve,btoa:()=>Sve,constants:()=>Ove,default:()=>s_e,isAscii:()=>r_e,isUtf8:()=>n_e,kMaxLength:()=>lg,kStringMaxLength:()=>CB,resolveObjectURL:()=>t_e,transcode:()=>i_e});function _ve(e){var t=e.length;if(t%4>0)throw Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");if(n===-1)n=t;var r=n===t?0:4-n%4;return[n,r]}function xve(e,t){return(e+t)*3/4-t}function wve(e){var t,n=_ve(e),r=n[0],i=n[1],s=new Uint8Array(xve(r,i)),o=0,a=i>0?r-4:r,l;for(l=0;l>16&255,s[o++]=t>>8&255,s[o++]=t&255;if(i===2)t=wo[e.charCodeAt(l)]<<2|wo[e.charCodeAt(l+1)]>>4,s[o++]=t&255;if(i===1)t=wo[e.charCodeAt(l)]<<10|wo[e.charCodeAt(l+1)]<<4|wo[e.charCodeAt(l+2)]>>2,s[o++]=t>>8&255,s[o++]=t&255;return s}function Dve(e){return Qa[e>>18&63]+Qa[e>>12&63]+Qa[e>>6&63]+Qa[e&63]}function Tve(e,t,n){var r,i=[];for(var s=t;sa?a:o+s));if(r===1)t=e[n-1],i.push(Qa[t>>2]+Qa[t<<4&63]+"==");else if(r===2)t=(e[n-2]<<8)+e[n-1],i.push(Qa[t>>10]+Qa[t>>4&63]+Qa[t<<2&63]+"=");return i.join("")}function l0(e,t,n,r,i){var s,o,a=i*8-r-1,l=(1<>1,u=-7,p=n?i-1:0,d=n?-1:1,f=e[t+p];p+=d,s=f&(1<<-u)-1,f>>=-u,u+=a;for(;u>0;s=s*256+e[t+p],p+=d,u-=8);o=s&(1<<-u)-1,s>>=-u,u+=r;for(;u>0;o=o*256+e[t+p],p+=d,u-=8);if(s===0)s=1-c;else if(s===l)return o?NaN:(f?-1:1)*(1/0);else o=o+Math.pow(2,r),s=s-c;return(f?-1:1)*o*Math.pow(2,s-r)}function jB(e,t,n,r,i,s){var o,a,l,c=s*8-i-1,u=(1<>1,d=i===23?Math.pow(2,-24)-Math.pow(2,-77):0,f=r?0:s-1,m=r?1:-1,y=t<0||t===0&&1/t<0?1:0;if(t=Math.abs(t),isNaN(t)||t===1/0)a=isNaN(t)?1:0,o=u;else{if(o=Math.floor(Math.log(t)/Math.LN2),t*(l=Math.pow(2,-o))<1)o--,l*=2;if(o+p>=1)t+=d/l;else t+=d*Math.pow(2,1-p);if(t*l>=2)o++,l/=2;if(o+p>=u)a=0,o=u;else if(o+p>=1)a=(t*l-1)*Math.pow(2,i),o=o+p;else a=t*Math.pow(2,p-1)*Math.pow(2,i),o=0}for(;i>=8;e[n+f]=a&255,f+=m,a/=256,i-=8);o=o<0;e[n+f]=o&255,f+=m,o/=256,c-=8);e[n+f-m]|=y*128}function Jl(e){if(e>lg)throw RangeError('The value "'+e+'" is invalid for option "size"');let t=new Uint8Array(e);return Object.setPrototypeOf(t,xe.prototype),t}function H1(e,t,n){return class extends n{constructor(){super();Object.defineProperty(this,"message",{value:t.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${e}]`,this.stack,delete this.name}get code(){return e}set code(r){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:r,writable:!0})}toString(){return`${this.name} [${e}]: ${this.message}`}}}function xe(e,t,n){if(typeof e==="number"){if(typeof t==="string")throw TypeError('The "string" argument must be of type string. Received type number');return z1(e)}return MB(e,t,n)}function MB(e,t,n){if(typeof e==="string")return Ave(e,t);if(ArrayBuffer.isView(e))return Rve(e);if(e==null)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(Ya(e,ArrayBuffer)||e&&Ya(e.buffer,ArrayBuffer))return J1(e,t,n);if(typeof SharedArrayBuffer<"u"&&(Ya(e,SharedArrayBuffer)||e&&Ya(e.buffer,SharedArrayBuffer)))return J1(e,t,n);if(typeof e==="number")throw TypeError('The "value" argument must not be of type number. Received type number');let r=e.valueOf&&e.valueOf();if(r!=null&&r!==e)return xe.from(r,t,n);let i=jve(e);if(i)return i;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof e[Symbol.toPrimitive]==="function")return xe.from(e[Symbol.toPrimitive]("string"),t,n);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function LB(e){if(typeof e!=="number")throw TypeError('"size" argument must be of type number');else if(e<0)throw RangeError('The value "'+e+'" is invalid for option "size"')}function Ive(e,t,n){if(LB(e),e<=0)return Jl(e);if(t!==void 0)return typeof n==="string"?Jl(e).fill(t,n):Jl(e).fill(t);return Jl(e)}function z1(e){return LB(e),Jl(e<0?0:W1(e)|0)}function Ave(e,t){if(typeof t!=="string"||t==="")t="utf8";if(!xe.isEncoding(t))throw TypeError("Unknown encoding: "+t);let n=qB(e,t)|0,r=Jl(n),i=r.write(e,t);if(i!==n)r=r.slice(0,i);return r}function K1(e){let t=e.length<0?0:W1(e.length)|0,n=Jl(t);for(let r=0;r=lg)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+lg.toString(16)+" bytes");return e|0}function qB(e,t){if(xe.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||Ya(e,ArrayBuffer))return e.byteLength;if(typeof e!=="string")throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);let n=e.length,r=arguments.length>2&&arguments[2]===!0;if(!r&&n===0)return 0;let i=!1;for(;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":return G1(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return n*2;case"hex":return n>>>1;case"base64":return WB(e).length;default:if(i)return r?-1:G1(e).length;t=(""+t).toLowerCase(),i=!0}}function Fve(e,t,n){let r=!1;if(t===void 0||t<0)t=0;if(t>this.length)return"";if(n===void 0||n>this.length)n=this.length;if(n<=0)return"";if(n>>>=0,t>>>=0,n<=t)return"";if(!e)e="utf8";while(!0)switch(e){case"hex":return Gve(this,t,n);case"utf8":case"utf-8":return BB(this,t,n);case"ascii":return Kve(this,t,n);case"latin1":case"binary":return Jve(this,t,n);case"base64":return Bve(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Hve(this,t,n);default:if(r)throw TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function Wp(e,t,n){let r=e[t];e[t]=e[n],e[n]=r}function UB(e,t,n,r,i){if(e.length===0)return-1;if(typeof n==="string")r=n,n=0;else if(n>2147483647)n=2147483647;else if(n<-2147483648)n=-2147483648;if(n=+n,Number.isNaN(n))n=i?0:e.length-1;if(n<0)n=e.length+n;if(n>=e.length)if(i)return-1;else n=e.length-1;else if(n<0)if(i)n=0;else return-1;if(typeof t==="string")t=xe.from(t,r);if(xe.isBuffer(t)){if(t.length===0)return-1;return IB(e,t,n,r,i)}else if(typeof t==="number"){if(t=t&255,typeof Uint8Array.prototype.indexOf==="function")if(i)return Uint8Array.prototype.indexOf.call(e,t,n);else return Uint8Array.prototype.lastIndexOf.call(e,t,n);return IB(e,[t],n,r,i)}throw TypeError("val must be string, number or Buffer")}function IB(e,t,n,r,i){let s=1,o=e.length,a=t.length;if(r!==void 0){if(r=String(r).toLowerCase(),r==="ucs2"||r==="ucs-2"||r==="utf16le"||r==="utf-16le"){if(e.length<2||t.length<2)return-1;s=2,o/=2,a/=2,n/=2}}function l(u,p){if(s===1)return u[p];else return u.readUInt16BE(p*s)}let c;if(i){let u=-1;for(c=n;co)n=o-a;for(c=n;c>=0;c--){let u=!0;for(let p=0;pi)r=i;let s=t.length;if(r>s/2)r=s/2;let o;for(o=0;o239?4:s>223?3:s>191?2:1;if(i+a<=n){let l,c,u,p;switch(a){case 1:if(s<128)o=s;break;case 2:if(l=e[i+1],(l&192)===128){if(p=(s&31)<<6|l&63,p>127)o=p}break;case 3:if(l=e[i+1],c=e[i+2],(l&192)===128&&(c&192)===128){if(p=(s&15)<<12|(l&63)<<6|c&63,p>2047&&(p<55296||p>57343))o=p}break;case 4:if(l=e[i+1],c=e[i+2],u=e[i+3],(l&192)===128&&(c&192)===128&&(u&192)===128){if(p=(s&15)<<18|(l&63)<<12|(c&63)<<6|u&63,p>65535&&p<1114112)o=p}}}if(o===null)o=65533,a=1;else if(o>65535)o-=65536,r.push(o>>>10&1023|55296),o=56320|o&1023;r.push(o),i+=a}return Vve(r)}function Vve(e){let t=e.length;if(t<=AB)return String.fromCharCode.apply(String,e);let n="",r=0;while(rr)n=r;let i="";for(let s=t;sn)throw RangeError("Trying to access beyond buffer length")}function ys(e,t,n,r,i,s){if(!xe.isBuffer(e))throw TypeError('"buffer" argument must be a Buffer instance');if(t>i||te.length)throw RangeError("Index out of range")}function VB(e,t,n,r,i){zB(t,r,i,e,n,7);let s=Number(t&BigInt(4294967295));e[n++]=s,s=s>>8,e[n++]=s,s=s>>8,e[n++]=s,s=s>>8,e[n++]=s;let o=Number(t>>BigInt(32)&BigInt(4294967295));return e[n++]=o,o=o>>8,e[n++]=o,o=o>>8,e[n++]=o,o=o>>8,e[n++]=o,n}function KB(e,t,n,r,i){zB(t,r,i,e,n,7);let s=Number(t&BigInt(4294967295));e[n+7]=s,s=s>>8,e[n+6]=s,s=s>>8,e[n+5]=s,s=s>>8,e[n+4]=s;let o=Number(t>>BigInt(32)&BigInt(4294967295));return e[n+3]=o,o=o>>8,e[n+2]=o,o=o>>8,e[n+1]=o,o=o>>8,e[n]=o,n+8}function JB(e,t,n,r,i,s){if(n+r>e.length)throw RangeError("Index out of range");if(n<0)throw RangeError("Index out of range")}function GB(e,t,n,r,i){if(t=+t,n=n>>>0,!i)JB(e,t,n,4,340282346638528860000000000000000000000,-340282346638528860000000000000000000000);return jB(e,t,n,r,23,4),n+4}function HB(e,t,n,r,i){if(t=+t,n=n>>>0,!i)JB(e,t,n,8,179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000,-179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000);return jB(e,t,n,r,52,8),n+8}function RB(e){let t="",n=e.length,r=e[0]==="-"?1:0;for(;n>=r+4;n-=3)t=`_${e.slice(n-3,n)}${t}`;return`${e.slice(0,n)}${t}`}function zve(e,t,n){if(nm(t,"offset"),e[t]===void 0||e[t+n]===void 0)cg(t,e.length-(n+1))}function zB(e,t,n,r,i,s){if(e>n||e3)if(t===0||t===BigInt(0))a=`>= 0${o} and < 2${o} ** ${(s+1)*8}${o}`;else a=`>= -(2${o} ** ${(s+1)*8-1}${o}) and < 2 ** ${(s+1)*8-1}${o}`;else a=`>= ${t}${o} and <= ${n}${o}`;throw new V1("value",a,e)}zve(r,i,s)}function nm(e,t){if(typeof e!=="number")throw new $ve(t,"number",e)}function cg(e,t,n){if(Math.floor(e)!==e)throw nm(e,n),new V1(n||"offset","an integer",e);if(t<0)throw new Pve;throw new V1(n||"offset",`>= ${n?1:0} and <= ${t}`,e)}function Qve(e){if(e=e.split("=")[0],e=e.trim().replace(Wve,""),e.length<2)return"";while(e.length%4!==0)e=e+"=";return e}function G1(e,t){t=t||1/0;let n,r=e.length,i=null,s=[];for(let o=0;o55295&&n<57344){if(!i){if(n>56319){if((t-=3)>-1)s.push(239,191,189);continue}else if(o+1===r){if((t-=3)>-1)s.push(239,191,189);continue}i=n;continue}if(n<56320){if((t-=3)>-1)s.push(239,191,189);i=n;continue}n=(i-55296<<10|n-56320)+65536}else if(i){if((t-=3)>-1)s.push(239,191,189)}if(i=null,n<128){if((t-=1)<0)break;s.push(n)}else if(n<2048){if((t-=2)<0)break;s.push(n>>6|192,n&63|128)}else if(n<65536){if((t-=3)<0)break;s.push(n>>12|224,n>>6&63|128,n&63|128)}else if(n<1114112){if((t-=4)<0)break;s.push(n>>18|240,n>>12&63|128,n>>6&63|128,n&63|128)}else throw Error("Invalid code point")}return s}function Yve(e){let t=[];for(let n=0;n>8,i=n%256,s.push(i),s.push(r)}return s}function WB(e){return wve(Qve(e))}function c0(e,t,n,r){let i;for(i=0;i=t.length||i>=e.length)break;t[i+n]=e[i]}return i}function Ya(e,t){return e instanceof t||e!=null&&e.constructor!=null&&e.constructor.name!=null&&e.constructor.name===t.name}function fu(e){return typeof BigInt>"u"?e_e:e}function e_e(){throw Error("BigInt not supported")}function Q1(e){return()=>{throw Error(e+" is not implemented for node:buffer browser polyfill")}}var Qa,wo,B1="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",zp,OB,$B,FB=50,lg=2147483647,CB=536870888,Sve,Eve,kve,Nve,Ove,Pve,$ve,V1,AB=4096,Wve,Zve,t_e,n_e,r_e=(e)=>{for(let t of e)if(t.charCodeAt(0)>127)return!1;return!0},i_e,s_e;var p0=q(()=>{Qa=[],wo=[];for(zp=0,OB=B1.length;zp4294967296)i=RB(String(n));else if(typeof n==="bigint"){if(i=String(n),n>BigInt(2)**BigInt(32)||n<-(BigInt(2)**BigInt(32)))i=RB(i);i+="n"}return r+=` It must be ${t}. Received ${i}`,r},RangeError);Object.defineProperty(xe.prototype,"parent",{enumerable:!0,get:function(){if(!xe.isBuffer(this))return;return this.buffer}});Object.defineProperty(xe.prototype,"offset",{enumerable:!0,get:function(){if(!xe.isBuffer(this))return;return this.byteOffset}});xe.poolSize=8192;xe.from=function(e,t,n){return MB(e,t,n)};Object.setPrototypeOf(xe.prototype,Uint8Array.prototype);Object.setPrototypeOf(xe,Uint8Array);xe.alloc=function(e,t,n){return Ive(e,t,n)};xe.allocUnsafe=function(e){return z1(e)};xe.allocUnsafeSlow=function(e){return z1(e)};xe.isBuffer=function(e){return e!=null&&e._isBuffer===!0&&e!==xe.prototype};xe.compare=function(e,t){if(Ya(e,Uint8Array))e=xe.from(e,e.offset,e.byteLength);if(Ya(t,Uint8Array))t=xe.from(t,t.offset,t.byteLength);if(!xe.isBuffer(e)||!xe.isBuffer(t))throw TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===t)return 0;let n=e.length,r=t.length;for(let i=0,s=Math.min(n,r);ir.length){if(!xe.isBuffer(s))s=xe.from(s);s.copy(r,i)}else Uint8Array.prototype.set.call(r,s,i);else if(!xe.isBuffer(s))throw TypeError('"list" argument must be an Array of Buffers');else s.copy(r,i);i+=s.length}return r};xe.byteLength=qB;xe.prototype._isBuffer=!0;xe.prototype.swap16=function(){let e=this.length;if(e%2!==0)throw RangeError("Buffer size must be a multiple of 16-bits");for(let t=0;tt)e+=" ... ";return""};if($B)xe.prototype[$B]=xe.prototype.inspect;xe.prototype.compare=function(e,t,n,r,i){if(Ya(e,Uint8Array))e=xe.from(e,e.offset,e.byteLength);if(!xe.isBuffer(e))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(t===void 0)t=0;if(n===void 0)n=e?e.length:0;if(r===void 0)r=0;if(i===void 0)i=this.length;if(t<0||n>e.length||r<0||i>this.length)throw RangeError("out of range index");if(r>=i&&t>=n)return 0;if(r>=i)return-1;if(t>=n)return 1;if(t>>>=0,n>>>=0,r>>>=0,i>>>=0,this===e)return 0;let s=i-r,o=n-t,a=Math.min(s,o),l=this.slice(r,i),c=e.slice(t,n);for(let u=0;u>>0,isFinite(n)){if(n=n>>>0,r===void 0)r="utf8"}else r=n,n=void 0;else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");let i=this.length-t;if(n===void 0||n>i)n=i;if(e.length>0&&(n<0||t<0)||t>this.length)throw RangeError("Attempt to write outside buffer bounds");if(!r)r="utf8";let s=!1;for(;;)switch(r){case"hex":return Cve(this,e,t,n);case"utf8":case"utf-8":return Mve(this,e,t,n);case"ascii":case"latin1":case"binary":return Lve(this,e,t,n);case"base64":return qve(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Uve(this,e,t,n);default:if(s)throw TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),s=!0}};xe.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};xe.prototype.slice=function(e,t){let n=this.length;if(e=~~e,t=t===void 0?n:~~t,e<0){if(e+=n,e<0)e=0}else if(e>n)e=n;if(t<0){if(t+=n,t<0)t=0}else if(t>n)t=n;if(t>>0,t=t>>>0,!n)Hr(e,t,this.length);let r=this[e],i=1,s=0;while(++s>>0,t=t>>>0,!n)Hr(e,t,this.length);let r=this[e+--t],i=1;while(t>0&&(i*=256))r+=this[e+--t]*i;return r};xe.prototype.readUint8=xe.prototype.readUInt8=function(e,t){if(e=e>>>0,!t)Hr(e,1,this.length);return this[e]};xe.prototype.readUint16LE=xe.prototype.readUInt16LE=function(e,t){if(e=e>>>0,!t)Hr(e,2,this.length);return this[e]|this[e+1]<<8};xe.prototype.readUint16BE=xe.prototype.readUInt16BE=function(e,t){if(e=e>>>0,!t)Hr(e,2,this.length);return this[e]<<8|this[e+1]};xe.prototype.readUint32LE=xe.prototype.readUInt32LE=function(e,t){if(e=e>>>0,!t)Hr(e,4,this.length);return(this[e]|this[e+1]<<8|this[e+2]<<16)+this[e+3]*16777216};xe.prototype.readUint32BE=xe.prototype.readUInt32BE=function(e,t){if(e=e>>>0,!t)Hr(e,4,this.length);return this[e]*16777216+(this[e+1]<<16|this[e+2]<<8|this[e+3])};xe.prototype.readBigUInt64LE=fu(function(e){e=e>>>0,nm(e,"offset");let t=this[e],n=this[e+7];if(t===void 0||n===void 0)cg(e,this.length-8);let r=t+this[++e]*256+this[++e]*65536+this[++e]*16777216,i=this[++e]+this[++e]*256+this[++e]*65536+n*16777216;return BigInt(r)+(BigInt(i)<>>0,nm(e,"offset");let t=this[e],n=this[e+7];if(t===void 0||n===void 0)cg(e,this.length-8);let r=t*16777216+this[++e]*65536+this[++e]*256+this[++e],i=this[++e]*16777216+this[++e]*65536+this[++e]*256+n;return(BigInt(r)<>>0,t=t>>>0,!n)Hr(e,t,this.length);let r=this[e],i=1,s=0;while(++s=i)r-=Math.pow(2,8*t);return r};xe.prototype.readIntBE=function(e,t,n){if(e=e>>>0,t=t>>>0,!n)Hr(e,t,this.length);let r=t,i=1,s=this[e+--r];while(r>0&&(i*=256))s+=this[e+--r]*i;if(i*=128,s>=i)s-=Math.pow(2,8*t);return s};xe.prototype.readInt8=function(e,t){if(e=e>>>0,!t)Hr(e,1,this.length);if(!(this[e]&128))return this[e];return(255-this[e]+1)*-1};xe.prototype.readInt16LE=function(e,t){if(e=e>>>0,!t)Hr(e,2,this.length);let n=this[e]|this[e+1]<<8;return n&32768?n|4294901760:n};xe.prototype.readInt16BE=function(e,t){if(e=e>>>0,!t)Hr(e,2,this.length);let n=this[e+1]|this[e]<<8;return n&32768?n|4294901760:n};xe.prototype.readInt32LE=function(e,t){if(e=e>>>0,!t)Hr(e,4,this.length);return this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24};xe.prototype.readInt32BE=function(e,t){if(e=e>>>0,!t)Hr(e,4,this.length);return this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]};xe.prototype.readBigInt64LE=fu(function(e){e=e>>>0,nm(e,"offset");let t=this[e],n=this[e+7];if(t===void 0||n===void 0)cg(e,this.length-8);let r=this[e+4]+this[e+5]*256+this[e+6]*65536+(n<<24);return(BigInt(r)<>>0,nm(e,"offset");let t=this[e],n=this[e+7];if(t===void 0||n===void 0)cg(e,this.length-8);let r=(t<<24)+this[++e]*65536+this[++e]*256+this[++e];return(BigInt(r)<>>0,!t)Hr(e,4,this.length);return l0(this,e,!0,23,4)};xe.prototype.readFloatBE=function(e,t){if(e=e>>>0,!t)Hr(e,4,this.length);return l0(this,e,!1,23,4)};xe.prototype.readDoubleLE=function(e,t){if(e=e>>>0,!t)Hr(e,8,this.length);return l0(this,e,!0,52,8)};xe.prototype.readDoubleBE=function(e,t){if(e=e>>>0,!t)Hr(e,8,this.length);return l0(this,e,!1,52,8)};xe.prototype.writeUintLE=xe.prototype.writeUIntLE=function(e,t,n,r){if(e=+e,t=t>>>0,n=n>>>0,!r){let o=Math.pow(2,8*n)-1;ys(this,e,t,n,o,0)}let i=1,s=0;this[t]=e&255;while(++s>>0,n=n>>>0,!r){let o=Math.pow(2,8*n)-1;ys(this,e,t,n,o,0)}let i=n-1,s=1;this[t+i]=e&255;while(--i>=0&&(s*=256))this[t+i]=e/s&255;return t+n};xe.prototype.writeUint8=xe.prototype.writeUInt8=function(e,t,n){if(e=+e,t=t>>>0,!n)ys(this,e,t,1,255,0);return this[t]=e&255,t+1};xe.prototype.writeUint16LE=xe.prototype.writeUInt16LE=function(e,t,n){if(e=+e,t=t>>>0,!n)ys(this,e,t,2,65535,0);return this[t]=e&255,this[t+1]=e>>>8,t+2};xe.prototype.writeUint16BE=xe.prototype.writeUInt16BE=function(e,t,n){if(e=+e,t=t>>>0,!n)ys(this,e,t,2,65535,0);return this[t]=e>>>8,this[t+1]=e&255,t+2};xe.prototype.writeUint32LE=xe.prototype.writeUInt32LE=function(e,t,n){if(e=+e,t=t>>>0,!n)ys(this,e,t,4,4294967295,0);return this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=e&255,t+4};xe.prototype.writeUint32BE=xe.prototype.writeUInt32BE=function(e,t,n){if(e=+e,t=t>>>0,!n)ys(this,e,t,4,4294967295,0);return this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=e&255,t+4};xe.prototype.writeBigUInt64LE=fu(function(e,t=0){return VB(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))});xe.prototype.writeBigUInt64BE=fu(function(e,t=0){return KB(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))});xe.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t=t>>>0,!r){let a=Math.pow(2,8*n-1);ys(this,e,t,n,a-1,-a)}let i=0,s=1,o=0;this[t]=e&255;while(++i>0)-o&255}return t+n};xe.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t=t>>>0,!r){let a=Math.pow(2,8*n-1);ys(this,e,t,n,a-1,-a)}let i=n-1,s=1,o=0;this[t+i]=e&255;while(--i>=0&&(s*=256)){if(e<0&&o===0&&this[t+i+1]!==0)o=1;this[t+i]=(e/s>>0)-o&255}return t+n};xe.prototype.writeInt8=function(e,t,n){if(e=+e,t=t>>>0,!n)ys(this,e,t,1,127,-128);if(e<0)e=255+e+1;return this[t]=e&255,t+1};xe.prototype.writeInt16LE=function(e,t,n){if(e=+e,t=t>>>0,!n)ys(this,e,t,2,32767,-32768);return this[t]=e&255,this[t+1]=e>>>8,t+2};xe.prototype.writeInt16BE=function(e,t,n){if(e=+e,t=t>>>0,!n)ys(this,e,t,2,32767,-32768);return this[t]=e>>>8,this[t+1]=e&255,t+2};xe.prototype.writeInt32LE=function(e,t,n){if(e=+e,t=t>>>0,!n)ys(this,e,t,4,2147483647,-2147483648);return this[t]=e&255,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4};xe.prototype.writeInt32BE=function(e,t,n){if(e=+e,t=t>>>0,!n)ys(this,e,t,4,2147483647,-2147483648);if(e<0)e=4294967295+e+1;return this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=e&255,t+4};xe.prototype.writeBigInt64LE=fu(function(e,t=0){return VB(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});xe.prototype.writeBigInt64BE=fu(function(e,t=0){return KB(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});xe.prototype.writeFloatLE=function(e,t,n){return GB(this,e,t,!0,n)};xe.prototype.writeFloatBE=function(e,t,n){return GB(this,e,t,!1,n)};xe.prototype.writeDoubleLE=function(e,t,n){return HB(this,e,t,!0,n)};xe.prototype.writeDoubleBE=function(e,t,n){return HB(this,e,t,!1,n)};xe.prototype.copy=function(e,t,n,r){if(!xe.isBuffer(e))throw TypeError("argument should be a Buffer");if(!n)n=0;if(!r&&r!==0)r=this.length;if(t>=e.length)t=e.length;if(!t)t=0;if(r>0&&r=this.length)throw RangeError("Index out of range");if(r<0)throw RangeError("sourceEnd out of bounds");if(r>this.length)r=this.length;if(e.length-t>>0,n=n===void 0?this.length:n>>>0,!e)e=0;let i;if(typeof e==="number")for(i=t;i>>32-i,n)}function Ti(e,t,n,r,i,s,o){return d0(t&n|~t&r,e,t,i,s,o)}function Si(e,t,n,r,i,s,o){return d0(t&r|n&~r,e,t,i,s,o)}function Ei(e,t,n,r,i,s,o){return d0(t^n^r,e,t,i,s,o)}function ki(e,t,n,r,i,s,o){return d0(n^(t|~r),e,t,i,s,o)}function l_e(e){var t=e.length,n=[1732584193,-271733879,-1732584194,271733878],r;for(r=64;r<=e.length;r+=64)X1(n,c_e(e.substring(r-64,r)));e=e.substring(r-64);var i=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];for(r=0;r>2]|=e.charCodeAt(r)<<(r%4<<3);if(i[r>>2]|=128<<(r%4<<3),r>55){X1(n,i);for(r=0;r<16;r++)i[r]=0}return i[14]=t*8,X1(n,i),n}function c_e(e){var t=[],n;for(n=0;n<64;n+=4)t[n>>2]=e.charCodeAt(n)+(e.charCodeAt(n+1)<<8)+(e.charCodeAt(n+2)<<16)+(e.charCodeAt(n+3)<<24);return t}function u_e(e){var t=l_e(e),n=Y1.alloc?Y1.alloc(16):new Y1(16),r;for(r=0;r<4;r++)n.writeIntLE(t[r],r*4,4);return n}function mu(e,t){return e+t&4294967295}QB.exports={createHash:a_e}});var cN={};kf(cN,{TextDecoder:()=>o8,TextEncoder:()=>s8,_extend:()=>aN,callbackify:()=>i8,callbackifyOnRejected:()=>lN,debuglog:()=>f_e,default:()=>k_e,deprecate:()=>d_e,format:()=>iN,inherits:()=>t8,inspect:()=>Qp,isArray:()=>XB,isBoolean:()=>sN,isBuffer:()=>T_e,isDate:()=>rN,isError:()=>m0,isFunction:()=>y0,isNull:()=>g0,isNullOrUndefined:()=>x_e,isNumber:()=>ZB,isObject:()=>im,isPrimitive:()=>D_e,isRegExp:()=>f0,isString:()=>b0,isSymbol:()=>w_e,isUndefined:()=>rm,log:()=>e8,promisify:()=>r8,types:()=>__e});function iN(e,...t){if(!b0(e)){var n=[e];for(var r=0;r=i)return a;switch(a){case"%s":return String(t[r++]);case"%d":return Number(t[r++]);case"%j":try{return JSON.stringify(t[r++])}catch(l){return"[Circular]"}default:return a}});for(var o=t[r];r"u"||process?.noDeprecation===!0)return e;var n=!1;function r(...i){if(!n){if(process.throwDeprecation)throw Error(t);else if(process.traceDeprecation)console.trace(t);else console.error(t);n=!0}return e.apply(this,...i)}return r}function m_e(e,t){var n=Qp.styles[t];if(n)return"\x1B["+Qp.colors[n][0]+"m"+e+"\x1B["+Qp.colors[n][1]+"m";else return e}function y_e(e,t){return e}function h_e(e){var t={};return e.forEach(function(n,r){t[n]=!0}),t}function h0(e,t,n){if(e.customInspect&&t&&y0(t.inspect)&&t.inspect!==Qp&&!(t.constructor&&t.constructor.prototype===t)){var r=t.inspect(n,e);if(!b0(r))r=h0(e,r,n);return r}var i=g_e(e,t);if(i)return i;var s=Object.keys(t),o=h_e(s);if(e.showHidden)s=Object.getOwnPropertyNames(t);if(m0(t)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return eN(t);if(s.length===0){if(y0(t)){var a=t.name?": "+t.name:"";return e.stylize("[Function"+a+"]","special")}if(f0(t))return e.stylize(RegExp.prototype.toString.call(t),"regexp");if(rN(t))return e.stylize(Date.prototype.toString.call(t),"date");if(m0(t))return eN(t)}var l="",c=!1,u=["{","}"];if(XB(t))c=!0,u=["[","]"];if(y0(t)){var p=t.name?": "+t.name:"";l=" [Function"+p+"]"}if(f0(t))l=" "+RegExp.prototype.toString.call(t);if(rN(t))l=" "+Date.prototype.toUTCString.call(t);if(m0(t))l=" "+eN(t);if(s.length===0&&(!c||t.length==0))return u[0]+l+u[1];if(n<0)if(f0(t))return e.stylize(RegExp.prototype.toString.call(t),"regexp");else return e.stylize("[Object]","special");e.seen.push(t);var d;if(c)d=b_e(e,t,n,o,s);else d=s.map(function(f){return nN(e,t,n,o,f,c)});return e.seen.pop(),v_e(d,l,u)}function g_e(e,t){if(rm(t))return e.stylize("undefined","undefined");if(b0(t)){var n="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(n,"string")}if(ZB(t))return e.stylize(""+t,"number");if(sN(t))return e.stylize(""+t,"boolean");if(g0(t))return e.stylize("null","null")}function eN(e){return"["+Error.prototype.toString.call(e)+"]"}function b_e(e,t,n,r,i){var s=[];for(var o=0,a=t.length;o{for(let c of a)rg.checkReportMissingProp(e,c)});else n.if(T1._`${l} && (${rg.checkMissingProp(e,a,s)})`),rg.reportMissingProp(e,s),n.else()}}aU.validatePropertyDeps=sU;function oU(e,t=e.schema){let{gen:n,data:r,keyword:i,it:s}=e,o=n.name("valid");for(let a in t){if(mhe.alwaysValidSchema(s,t[a]))continue;n.if(rg.propertyInData(n,r,a,s.opts.ownProperties),()=>{let l=e.subschema({keyword:i,schemaProp:a},o);e.mergeValidEvaluated(l,o)},()=>n.var(o,!0)),e.ok(o)}}aU.validateSchemaDeps=oU;aU.default=yhe});var dU=z(function(pU){Object.defineProperty(pU,"__esModule",{value:!0});var uU=kt(),vhe=Kt(),_he={message:"property name must be valid",params:({params:e})=>uU._`{propertyName: ${e.propertyName}}`},xhe={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:_he,code(e){let{gen:t,schema:n,data:r,it:i}=e;if(vhe.alwaysValidSchema(i,n))return;let s=t.name("valid");t.forIn("key",r,(o)=>{e.setParams({propertyName:o}),e.subschema({keyword:"propertyNames",data:o,dataTypes:["string"],propertyName:o,compositeRule:!0},s),t.if(uU.not(s),()=>{if(e.error(!0),!i.allErrors)t.break()})}),e.ok(s)}};pU.default=xhe});var S1=z(function(fU){Object.defineProperty(fU,"__esModule",{value:!0});var zx=_o(),ya=kt(),Dhe=vo(),Wx=Kt(),The={message:"must NOT have additional properties",params:({params:e})=>ya._`{additionalProperty: ${e.additionalProperty}}`},She={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:The,code(e){let{gen:t,schema:n,parentSchema:r,data:i,errsCount:s,it:o}=e;if(!s)throw Error("ajv implementation error");let{allErrors:a,opts:l}=o;if(o.props=!0,l.removeAdditional!=="all"&&Wx.alwaysValidSchema(o,n))return;let c=zx.allSchemaProperties(r.properties),u=zx.allSchemaProperties(r.patternProperties);p(),e.ok(ya._`${s} === ${Dhe.default.errors}`);function p(){t.forIn("key",i,(h)=>{if(!c.length&&!u.length)m(h);else t.if(d(h),()=>m(h))})}function d(h){let b;if(c.length>8){let g=Wx.schemaRefOrVal(o,r.properties,"properties");b=zx.isOwnProperty(t,g,h)}else if(c.length)b=ya.or(...c.map((g)=>ya._`${h} === ${g}`));else b=ya.nil;if(u.length)b=ya.or(b,...u.map((g)=>ya._`${zx.usePattern(e,g)}.test(${h})`));return ya.not(b)}function f(h){t.code(ya._`delete ${i}[${h}]`)}function m(h){if(l.removeAdditional==="all"||l.removeAdditional&&n===!1){f(h);return}if(n===!1){if(e.setParams({additionalProperty:h}),e.error(),!a)t.break();return}if(typeof n=="object"&&!Wx.alwaysValidSchema(o,n)){let b=t.name("valid");if(l.removeAdditional==="failing")y(h,b,!1),t.if(ya.not(b),()=>{e.reset(),f(h)});else if(y(h,b),!a)t.if(ya.not(b),()=>t.break())}}function y(h,b,g){let x={keyword:"additionalProperties",dataProp:h,dataPropType:Wx.Type.Str};if(g===!1)Object.assign(x,{compositeRule:!0,createErrors:!1,allErrors:!1});e.subschema(x,b)}}};fU.default=She});var gU=z(function(hU){Object.defineProperty(hU,"__esModule",{value:!0});var khe=Lp(),yU=_o(),E1=Kt(),mU=S1(),Nhe={keyword:"properties",type:"object",schemaType:"object",code(e){let{gen:t,schema:n,parentSchema:r,data:i,it:s}=e;if(s.opts.removeAdditional==="all"&&r.additionalProperties===void 0)mU.default.code(new khe.KeywordCxt(s,mU.default,"additionalProperties"));let o=yU.allSchemaProperties(n);for(let p of o)s.definedProperties.add(p);if(s.opts.unevaluated&&o.length&&s.props!==!0)s.props=E1.mergeEvaluated.props(t,E1.toHash(o),s.props);let a=o.filter((p)=>!E1.alwaysValidSchema(s,n[p]));if(a.length===0)return;let l=t.name("valid");for(let p of a){if(c(p))u(p);else{if(t.if(yU.propertyInData(t,i,p,s.opts.ownProperties)),u(p),!s.allErrors)t.else().var(l,!0);t.endIf()}e.it.definedProperties.add(p),e.ok(l)}function c(p){return s.opts.useDefaults&&!s.compositeRule&&n[p].default!==void 0}function u(p){e.subschema({keyword:"properties",schemaProp:p,dataProp:p},l)}}};hU.default=Nhe});var wU=z(function(xU){Object.defineProperty(xU,"__esModule",{value:!0});var bU=_o(),Qx=kt(),vU=Kt(),_U=Kt(),Phe={keyword:"patternProperties",type:"object",schemaType:"object",code(e){let{gen:t,schema:n,data:r,parentSchema:i,it:s}=e,{opts:o}=s,a=bU.allSchemaProperties(n),l=a.filter((y)=>vU.alwaysValidSchema(s,n[y]));if(a.length===0||l.length===a.length&&(!s.opts.unevaluated||s.props===!0))return;let c=o.strictSchema&&!o.allowMatchingProperties&&i.properties,u=t.name("valid");if(s.props!==!0&&!(s.props instanceof Qx.Name))s.props=_U.evaluatedPropsToName(t,s.props);let{props:p}=s;d();function d(){for(let y of a){if(c)f(y);if(s.allErrors)m(y);else t.var(u,!0),m(y),t.if(u)}}function f(y){for(let h in c)if(new RegExp(y).test(h))vU.checkStrictMode(s,`property ${h} matches pattern ${y} (use allowMatchingProperties)`)}function m(y){t.forIn("key",r,(h)=>{t.if(Qx._`${bU.usePattern(e,y)}.test(${h})`,()=>{let b=l.includes(y);if(!b)e.subschema({keyword:"patternProperties",schemaProp:y,dataProp:h,dataPropType:_U.Type.Str},u);if(s.opts.unevaluated&&p!==!0)t.assign(Qx._`${p}[${h}]`,!0);else if(!b&&!s.allErrors)t.if(Qx.not(u),()=>t.break())})})}}};xU.default=Phe});var TU=z(function(DU){Object.defineProperty(DU,"__esModule",{value:!0});var Ihe=Kt(),Ahe={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){let{gen:t,schema:n,it:r}=e;if(Ihe.alwaysValidSchema(r,n)){e.fail();return}let i=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},i),e.failResult(i,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};DU.default=Ahe});var EU=z(function(SU){Object.defineProperty(SU,"__esModule",{value:!0});var jhe=_o(),Fhe={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:jhe.validateUnion,error:{message:"must match a schema in anyOf"}};SU.default=Fhe});var NU=z(function(kU){Object.defineProperty(kU,"__esModule",{value:!0});var Yx=kt(),Mhe=Kt(),Lhe={message:"must match exactly one schema in oneOf",params:({params:e})=>Yx._`{passingSchemas: ${e.passing}}`},qhe={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:Lhe,code(e){let{gen:t,schema:n,parentSchema:r,it:i}=e;if(!Array.isArray(n))throw Error("ajv implementation error");if(i.opts.discriminator&&r.discriminator)return;let s=n,o=t.let("valid",!1),a=t.let("passing",null),l=t.name("_valid");e.setParams({passing:a}),t.block(c),e.result(o,()=>e.reset(),()=>e.error(!0));function c(){s.forEach((u,p)=>{let d;if(Mhe.alwaysValidSchema(i,u))t.var(l,!0);else d=e.subschema({keyword:"oneOf",schemaProp:p,compositeRule:!0},l);if(p>0)t.if(Yx._`${l} && ${o}`).assign(o,!1).assign(a,Yx._`[${a}, ${p}]`).else();t.if(l,()=>{if(t.assign(o,!0),t.assign(a,p),d)e.mergeEvaluated(d,Yx.Name)})})}}};kU.default=qhe});var PU=z(function(OU){Object.defineProperty(OU,"__esModule",{value:!0});var Bhe=Kt(),Vhe={keyword:"allOf",schemaType:"array",code(e){let{gen:t,schema:n,it:r}=e;if(!Array.isArray(n))throw Error("ajv implementation error");let i=t.name("valid");n.forEach((s,o)=>{if(Bhe.alwaysValidSchema(r,s))return;let a=e.subschema({keyword:"allOf",schemaProp:o},i);e.ok(i),e.mergeEvaluated(a)})}};OU.default=Vhe});var RU=z(function(AU){Object.defineProperty(AU,"__esModule",{value:!0});var Xx=kt(),IU=Kt(),Jhe={message:({params:e})=>Xx.str`must match "${e.ifClause}" schema`,params:({params:e})=>Xx._`{failingKeyword: ${e.ifClause}}`},Ghe={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:Jhe,code(e){let{gen:t,parentSchema:n,it:r}=e;if(n.then===void 0&&n.else===void 0)IU.checkStrictMode(r,'"if" without "then" and "else" is ignored');let i=$U(r,"then"),s=$U(r,"else");if(!i&&!s)return;let o=t.let("valid",!0),a=t.name("_valid");if(l(),e.reset(),i&&s){let u=t.let("ifClause");e.setParams({ifClause:u}),t.if(a,c("then",u),c("else",u))}else if(i)t.if(a,c("then"));else t.if(Xx.not(a),c("else"));e.pass(o,()=>e.error(!0));function l(){let u=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},a);e.mergeEvaluated(u)}function c(u,p){return()=>{let d=e.subschema({keyword:u},a);if(t.assign(o,a),e.mergeValidEvaluated(d,o),p)t.assign(p,Xx._`${u}`);else e.setParams({ifClause:u})}}}};function $U(e,t){let n=e.schema[t];return n!==void 0&&!IU.alwaysValidSchema(e,n)}AU.default=Ghe});var FU=z(function(jU){Object.defineProperty(jU,"__esModule",{value:!0});var zhe=Kt(),Whe={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:n}){if(t.if===void 0)zhe.checkStrictMode(n,`"${e}" without "if" is ignored`)}};jU.default=Whe});var Zx=z(function(CU){Object.defineProperty(CU,"__esModule",{value:!0});var Yhe=w1(),Xhe=Zq(),Zhe=D1(),ege=nU(),tge=iU(),nge=Hx(),rge=dU(),ige=S1(),sge=gU(),oge=wU(),age=TU(),lge=EU(),cge=NU(),uge=PU(),pge=RU(),dge=FU();function fge(e=!1){let t=[age.default,lge.default,cge.default,uge.default,pge.default,dge.default,rge.default,ige.default,nge.default,sge.default,oge.default];if(e)t.push(Xhe.default,ege.default);else t.push(Yhe.default,Zhe.default);return t.push(tge.default),t}CU.default=fge});var N1=z(function(qU){Object.defineProperty(qU,"__esModule",{value:!0});qU.dynamicAnchor=void 0;var k1=kt(),yge=vo(),MU=Jh(),hge=Qh(),gge={keyword:"$dynamicAnchor",schemaType:"string",code:(e)=>LU(e,e.schema)};function LU(e,t){let{gen:n,it:r}=e;r.schemaEnv.root.dynamicAnchors[t]=!0;let i=k1._`${yge.default.dynamicAnchors}${k1.getProperty(t)}`,s=r.errSchemaPath==="#"?r.validateName:bge(e);n.if(k1._`!${i}`,()=>n.assign(i,s))}qU.dynamicAnchor=LU;function bge(e){let{schemaEnv:t,schema:n,self:r}=e.it,{root:i,baseId:s,localRefs:o,meta:a}=t.root,{schemaId:l}=r.opts,c=new MU.SchemaEnv({schema:n,schemaId:l,root:i,baseId:s,localRefs:o,meta:a});return MU.compileSchema.call(r,c),hge.getValidate(e,c)}qU.default=gge});var O1=z(function(JU){Object.defineProperty(JU,"__esModule",{value:!0});JU.dynamicRef=void 0;var VU=kt(),_ge=vo(),BU=Qh(),xge={keyword:"$dynamicRef",schemaType:"string",code:(e)=>KU(e,e.schema)};function KU(e,t){let{gen:n,keyword:r,it:i}=e;if(t[0]!=="#")throw Error(`"${r}" only supports hash fragment reference`);let s=t.slice(1);if(i.allErrors)o();else{let l=n.let("valid",!1);o(l),e.ok(l)}function o(l){if(i.schemaEnv.root.dynamicAnchors[s]){let c=n.let("_v",VU._`${_ge.default.dynamicAnchors}${VU.getProperty(s)}`);n.if(c,a(c,l),a(i.validateName,l))}else a(i.validateName,l)()}function a(l,c){return c?()=>n.block(()=>{BU.callRef(e,l),n.let(c,!0)}):()=>BU.callRef(e,l)}}JU.dynamicRef=KU;JU.default=xge});var zU=z(function(HU){Object.defineProperty(HU,"__esModule",{value:!0});var Dge=N1(),Tge=Kt(),Sge={keyword:"$recursiveAnchor",schemaType:"boolean",code(e){if(e.schema)Dge.dynamicAnchor(e,"");else Tge.checkStrictMode(e.it,"$recursiveAnchor: false is ignored")}};HU.default=Sge});var QU=z(function(WU){Object.defineProperty(WU,"__esModule",{value:!0});var kge=O1(),Nge={keyword:"$recursiveRef",schemaType:"string",code:(e)=>kge.dynamicRef(e,e.schema)};WU.default=Nge});var P1=z(function(YU){Object.defineProperty(YU,"__esModule",{value:!0});var Pge=N1(),$ge=O1(),Ige=zU(),Age=QU(),Rge=[Pge.default,$ge.default,Ige.default,Age.default];YU.default=Rge});var e3=z(function(ZU){Object.defineProperty(ZU,"__esModule",{value:!0});var XU=Hx(),Fge={keyword:"dependentRequired",type:"object",schemaType:"object",error:XU.error,code:(e)=>XU.validatePropertyDeps(e)};ZU.default=Fge});var n3=z(function(t3){Object.defineProperty(t3,"__esModule",{value:!0});var Mge=Hx(),Lge={keyword:"dependentSchemas",type:"object",schemaType:"object",code:(e)=>Mge.validateSchemaDeps(e)};t3.default=Lge});var i3=z(function(r3){Object.defineProperty(r3,"__esModule",{value:!0});var Uge=Kt(),Bge={keyword:["maxContains","minContains"],type:"array",schemaType:"number",code({keyword:e,parentSchema:t,it:n}){if(t.contains===void 0)Uge.checkStrictMode(n,`"${e}" without "contains" is ignored`)}};r3.default=Bge});var $1=z(function(s3){Object.defineProperty(s3,"__esModule",{value:!0});var Kge=e3(),Jge=n3(),Gge=i3(),Hge=[Kge.default,Jge.default,Gge.default];s3.default=Hge});var l3=z(function(a3){Object.defineProperty(a3,"__esModule",{value:!0});var pu=kt(),o3=Kt(),Wge=vo(),Qge={message:"must NOT have unevaluated properties",params:({params:e})=>pu._`{unevaluatedProperty: ${e.unevaluatedProperty}}`},Yge={keyword:"unevaluatedProperties",type:"object",schemaType:["boolean","object"],trackErrors:!0,error:Qge,code(e){let{gen:t,schema:n,data:r,errsCount:i,it:s}=e;if(!i)throw Error("ajv implementation error");let{allErrors:o,props:a}=s;if(a instanceof pu.Name)t.if(pu._`${a} !== true`,()=>t.forIn("key",r,(p)=>t.if(c(a,p),()=>l(p))));else if(a!==!0)t.forIn("key",r,(p)=>a===void 0?l(p):t.if(u(a,p),()=>l(p)));s.props=!0,e.ok(pu._`${i} === ${Wge.default.errors}`);function l(p){if(n===!1){if(e.setParams({unevaluatedProperty:p}),e.error(),!o)t.break();return}if(!o3.alwaysValidSchema(s,n)){let d=t.name("valid");if(e.subschema({keyword:"unevaluatedProperties",dataProp:p,dataPropType:o3.Type.Str},d),!o)t.if(pu.not(d),()=>t.break())}}function c(p,d){return pu._`!${p} || !${p}[${d}]`}function u(p,d){let f=[];for(let m in p)if(p[m]===!0)f.push(pu._`${d} !== ${m}`);return pu.and(...f)}}};a3.default=Yge});var p3=z(function(u3){Object.defineProperty(u3,"__esModule",{value:!0});var Gp=kt(),c3=Kt(),Zge={message:({params:{len:e}})=>Gp.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>Gp._`{limit: ${e}}`},ebe={keyword:"unevaluatedItems",type:"array",schemaType:["boolean","object"],error:Zge,code(e){let{gen:t,schema:n,data:r,it:i}=e,s=i.items||0;if(s===!0)return;let o=t.const("len",Gp._`${r}.length`);if(n===!1)e.setParams({len:s}),e.fail(Gp._`${o} > ${s}`);else if(typeof n=="object"&&!c3.alwaysValidSchema(i,n)){let l=t.var("valid",Gp._`${o} <= ${s}`);t.if(Gp.not(l),()=>a(l,s)),e.ok(l)}i.items=!0;function a(l,c){t.forRange("i",c,o,(u)=>{if(e.subschema({keyword:"unevaluatedItems",dataProp:u,dataPropType:c3.Type.Num},l),!i.allErrors)t.if(Gp.not(l),()=>t.break())})}}};u3.default=ebe});var I1=z(function(d3){Object.defineProperty(d3,"__esModule",{value:!0});var nbe=l3(),rbe=p3(),ibe=[nbe.default,rbe.default];d3.default=ibe});var m3=z(function(f3){Object.defineProperty(f3,"__esModule",{value:!0});var fr=kt(),obe={message:({schemaCode:e})=>fr.str`must match format "${e}"`,params:({schemaCode:e})=>fr._`{format: ${e}}`},abe={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:obe,code(e,t){let{gen:n,data:r,$data:i,schema:s,schemaCode:o,it:a}=e,{opts:l,errSchemaPath:c,schemaEnv:u,self:p}=a;if(!l.validateFormats)return;if(i)d();else f();function d(){let m=n.scopeValue("formats",{ref:p.formats,code:l.code.formats}),y=n.const("fDef",fr._`${m}[${o}]`),h=n.let("fType"),b=n.let("format");n.if(fr._`typeof ${y} == "object" && !(${y} instanceof RegExp)`,()=>n.assign(h,fr._`${y}.type || "string"`).assign(b,fr._`${y}.validate`),()=>n.assign(h,fr._`"string"`).assign(b,y)),e.fail$data(fr.or(g(),x()));function g(){if(l.strictSchema===!1)return fr.nil;return fr._`${o} && !${b}`}function x(){let v=u.$async?fr._`(${y}.async ? await ${b}(${r}) : ${b}(${r}))`:fr._`${b}(${r})`,D=fr._`(typeof ${b} == "function" ? ${v} : ${b}.test(${r}))`;return fr._`${b} && ${b} !== true && ${h} === ${t} && !${D}`}}function f(){let m=p.formats[s];if(!m){g();return}if(m===!0)return;let[y,h,b]=x(m);if(y===t)e.pass(v());function g(){if(l.strictSchema===!1){p.logger.warn(D());return}throw Error(D());function D(){return`unknown format "${s}" ignored in schema at path "${c}"`}}function x(D){let T=D instanceof RegExp?fr.regexpCode(D):l.code.formats?fr._`${l.code.formats}${fr.getProperty(s)}`:void 0,N=n.scopeValue("formats",{key:s,ref:D,code:T});if(typeof D=="object"&&!(D instanceof RegExp))return[D.type||"string",D.validate,fr._`${N}.validate`];return["string",D,N]}function v(){if(typeof m=="object"&&!(m instanceof RegExp)&&m.async){if(!u.$async)throw Error("async format in sync schema");return fr._`await ${b}(${r})`}return typeof h=="function"?fr._`${b}(${r})`:fr._`${b}.test(${r})`}}}};f3.default=abe});var e0=z(function(y3){Object.defineProperty(y3,"__esModule",{value:!0});var cbe=m3(),ube=[cbe.default];y3.default=ube});var A1=z(function(h3){Object.defineProperty(h3,"__esModule",{value:!0});h3.contentVocabulary=h3.metadataVocabulary=void 0;h3.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];h3.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var _3=z(function(v3){Object.defineProperty(v3,"__esModule",{value:!0});var fbe=l1(),mbe=_1(),ybe=Zx(),hbe=P1(),gbe=$1(),bbe=I1(),vbe=e0(),b3=A1(),_be=[hbe.default,fbe.default,mbe.default,(0,ybe.default)(!0),vbe.default,b3.metadataVocabulary,b3.contentVocabulary,gbe.default,bbe.default];v3.default=_be});var T3=z(function(w3){Object.defineProperty(w3,"__esModule",{value:!0});w3.DiscrError=void 0;var x3;(function(e){e.Tag="tag",e.Mapping="mapping"})(x3||(w3.DiscrError=x3={}))});var ig=z(function(E3){Object.defineProperty(E3,"__esModule",{value:!0});var em=kt(),R1=T3(),S3=Jh(),wbe=qp(),Dbe=Kt(),Tbe={message:({params:{discrError:e,tagName:t}})=>e===R1.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:n}})=>em._`{error: ${e}, tag: ${n}, tagValue: ${t}}`},Sbe={keyword:"discriminator",type:"object",schemaType:"object",error:Tbe,code(e){let{gen:t,data:n,schema:r,parentSchema:i,it:s}=e,{oneOf:o}=i;if(!s.opts.discriminator)throw Error("discriminator: requires discriminator option");let a=r.propertyName;if(typeof a!="string")throw Error("discriminator: requires propertyName");if(r.mapping)throw Error("discriminator: mapping is not supported");if(!o)throw Error("discriminator: requires oneOf keyword");let l=t.let("valid",!1),c=t.const("tag",em._`${n}${em.getProperty(a)}`);t.if(em._`typeof ${c} == "string"`,()=>u(),()=>e.error(!1,{discrError:R1.DiscrError.Tag,tag:c,tagName:a})),e.ok(l);function u(){let f=d();t.if(!1);for(let m in f)t.elseIf(em._`${c} === ${m}`),t.assign(l,p(f[m]));t.else(),e.error(!1,{discrError:R1.DiscrError.Mapping,tag:c,tagName:a}),t.endIf()}function p(f){let m=t.name("valid"),y=e.subschema({keyword:"oneOf",schemaProp:f},m);return e.mergeEvaluated(y,em.Name),m}function d(){var f;let m={},y=b(i),h=!0;for(let v=0;vthis.addMetaSchema(n,void 0,!1)),this;function t(n,r){return e?n.$dataMetaSchema(r,Vbe):r}}j3.default=Kbe});var og=z(function(ms,F1){Object.defineProperty(ms,"__esModule",{value:!0});ms.MissingRefError=ms.ValidationError=ms.CodeGen=ms.Name=ms.nil=ms.stringify=ms.str=ms._=ms.KeywordCxt=ms.Ajv2020=void 0;var Gbe=cu(),Hbe=_3(),zbe=ig(),Wbe=F3(),j1="https://json-schema.org/draft/2020-12/schema";class sg extends Gbe.default{constructor(e={}){super({...e,dynamicRef:!0,next:!0,unevaluated:!0})}_addVocabularies(){if(super._addVocabularies(),Hbe.default.forEach((e)=>this.addVocabulary(e)),this.opts.discriminator)this.addKeyword(zbe.default)}_addDefaultMetaSchema(){super._addDefaultMetaSchema();let{$data:e,meta:t}=this.opts;if(!t)return;Wbe.default.call(this,e),this.refs["http://json-schema.org/schema"]=j1}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(j1)?j1:void 0)}}ms.Ajv2020=sg;F1.exports=ms=sg;F1.exports.Ajv2020=sg;Object.defineProperty(ms,"__esModule",{value:!0});ms.default=sg;var Qbe=Lp();Object.defineProperty(ms,"KeywordCxt",{enumerable:!0,get:function(){return Qbe.KeywordCxt}});var tm=kt();Object.defineProperty(ms,"_",{enumerable:!0,get:function(){return tm._}});Object.defineProperty(ms,"str",{enumerable:!0,get:function(){return tm.str}});Object.defineProperty(ms,"stringify",{enumerable:!0,get:function(){return tm.stringify}});Object.defineProperty(ms,"nil",{enumerable:!0,get:function(){return tm.nil}});Object.defineProperty(ms,"Name",{enumerable:!0,get:function(){return tm.Name}});Object.defineProperty(ms,"CodeGen",{enumerable:!0,get:function(){return tm.CodeGen}});var Ybe=Qf();Object.defineProperty(ms,"ValidationError",{enumerable:!0,get:function(){return Ybe.default}});var Xbe=qp();Object.defineProperty(ms,"MissingRefError",{enumerable:!0,get:function(){return Xbe.default}})});var u0={};Of(u0,{Blob:()=>Ove,Buffer:()=>xe,File:()=>Nve,INSPECT_MAX_BYTES:()=>FB,atob:()=>kve,btoa:()=>Eve,constants:()=>Pve,default:()=>o_e,isAscii:()=>i_e,isUtf8:()=>r_e,kMaxLength:()=>lg,kStringMaxLength:()=>CB,resolveObjectURL:()=>n_e,transcode:()=>s_e});function xve(e){var t=e.length;if(t%4>0)throw Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");if(n===-1)n=t;var r=n===t?0:4-n%4;return[n,r]}function wve(e,t){return(e+t)*3/4-t}function Dve(e){var t,n=xve(e),r=n[0],i=n[1],s=new Uint8Array(wve(r,i)),o=0,a=i>0?r-4:r,l;for(l=0;l>16&255,s[o++]=t>>8&255,s[o++]=t&255;if(i===2)t=wo[e.charCodeAt(l)]<<2|wo[e.charCodeAt(l+1)]>>4,s[o++]=t&255;if(i===1)t=wo[e.charCodeAt(l)]<<10|wo[e.charCodeAt(l+1)]<<4|wo[e.charCodeAt(l+2)]>>2,s[o++]=t>>8&255,s[o++]=t&255;return s}function Tve(e){return Qa[e>>18&63]+Qa[e>>12&63]+Qa[e>>6&63]+Qa[e&63]}function Sve(e,t,n){var r,i=[];for(var s=t;sa?a:o+s));if(r===1)t=e[n-1],i.push(Qa[t>>2]+Qa[t<<4&63]+"==");else if(r===2)t=(e[n-2]<<8)+e[n-1],i.push(Qa[t>>10]+Qa[t>>4&63]+Qa[t<<2&63]+"=");return i.join("")}function l0(e,t,n,r,i){var s,o,a=i*8-r-1,l=(1<>1,u=-7,p=n?i-1:0,d=n?-1:1,f=e[t+p];p+=d,s=f&(1<<-u)-1,f>>=-u,u+=a;for(;u>0;s=s*256+e[t+p],p+=d,u-=8);o=s&(1<<-u)-1,s>>=-u,u+=r;for(;u>0;o=o*256+e[t+p],p+=d,u-=8);if(s===0)s=1-c;else if(s===l)return o?NaN:(f?-1:1)*(1/0);else o=o+Math.pow(2,r),s=s-c;return(f?-1:1)*o*Math.pow(2,s-r)}function jB(e,t,n,r,i,s){var o,a,l,c=s*8-i-1,u=(1<>1,d=i===23?Math.pow(2,-24)-Math.pow(2,-77):0,f=r?0:s-1,m=r?1:-1,y=t<0||t===0&&1/t<0?1:0;if(t=Math.abs(t),isNaN(t)||t===1/0)a=isNaN(t)?1:0,o=u;else{if(o=Math.floor(Math.log(t)/Math.LN2),t*(l=Math.pow(2,-o))<1)o--,l*=2;if(o+p>=1)t+=d/l;else t+=d*Math.pow(2,1-p);if(t*l>=2)o++,l/=2;if(o+p>=u)a=0,o=u;else if(o+p>=1)a=(t*l-1)*Math.pow(2,i),o=o+p;else a=t*Math.pow(2,p-1)*Math.pow(2,i),o=0}for(;i>=8;e[n+f]=a&255,f+=m,a/=256,i-=8);o=o<0;e[n+f]=o&255,f+=m,o/=256,c-=8);e[n+f-m]|=y*128}function Jl(e){if(e>lg)throw RangeError('The value "'+e+'" is invalid for option "size"');let t=new Uint8Array(e);return Object.setPrototypeOf(t,xe.prototype),t}function H1(e,t,n){return class extends n{constructor(){super();Object.defineProperty(this,"message",{value:t.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${e}]`,this.stack,delete this.name}get code(){return e}set code(r){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:r,writable:!0})}toString(){return`${this.name} [${e}]: ${this.message}`}}}function xe(e,t,n){if(typeof e==="number"){if(typeof t==="string")throw TypeError('The "string" argument must be of type string. Received type number');return z1(e)}return MB(e,t,n)}function MB(e,t,n){if(typeof e==="string")return Rve(e,t);if(ArrayBuffer.isView(e))return jve(e);if(e==null)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(Ya(e,ArrayBuffer)||e&&Ya(e.buffer,ArrayBuffer))return J1(e,t,n);if(typeof SharedArrayBuffer<"u"&&(Ya(e,SharedArrayBuffer)||e&&Ya(e.buffer,SharedArrayBuffer)))return J1(e,t,n);if(typeof e==="number")throw TypeError('The "value" argument must not be of type number. Received type number');let r=e.valueOf&&e.valueOf();if(r!=null&&r!==e)return xe.from(r,t,n);let i=Fve(e);if(i)return i;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof e[Symbol.toPrimitive]==="function")return xe.from(e[Symbol.toPrimitive]("string"),t,n);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function LB(e){if(typeof e!=="number")throw TypeError('"size" argument must be of type number');else if(e<0)throw RangeError('The value "'+e+'" is invalid for option "size"')}function Ave(e,t,n){if(LB(e),e<=0)return Jl(e);if(t!==void 0)return typeof n==="string"?Jl(e).fill(t,n):Jl(e).fill(t);return Jl(e)}function z1(e){return LB(e),Jl(e<0?0:W1(e)|0)}function Rve(e,t){if(typeof t!=="string"||t==="")t="utf8";if(!xe.isEncoding(t))throw TypeError("Unknown encoding: "+t);let n=qB(e,t)|0,r=Jl(n),i=r.write(e,t);if(i!==n)r=r.slice(0,i);return r}function K1(e){let t=e.length<0?0:W1(e.length)|0,n=Jl(t);for(let r=0;r=lg)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+lg.toString(16)+" bytes");return e|0}function qB(e,t){if(xe.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||Ya(e,ArrayBuffer))return e.byteLength;if(typeof e!=="string")throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);let n=e.length,r=arguments.length>2&&arguments[2]===!0;if(!r&&n===0)return 0;let i=!1;for(;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":return G1(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return n*2;case"hex":return n>>>1;case"base64":return WB(e).length;default:if(i)return r?-1:G1(e).length;t=(""+t).toLowerCase(),i=!0}}function Cve(e,t,n){let r=!1;if(t===void 0||t<0)t=0;if(t>this.length)return"";if(n===void 0||n>this.length)n=this.length;if(n<=0)return"";if(n>>>=0,t>>>=0,n<=t)return"";if(!e)e="utf8";while(!0)switch(e){case"hex":return Hve(this,t,n);case"utf8":case"utf-8":return BB(this,t,n);case"ascii":return Jve(this,t,n);case"latin1":case"binary":return Gve(this,t,n);case"base64":return Vve(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return zve(this,t,n);default:if(r)throw TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function Yp(e,t,n){let r=e[t];e[t]=e[n],e[n]=r}function UB(e,t,n,r,i){if(e.length===0)return-1;if(typeof n==="string")r=n,n=0;else if(n>2147483647)n=2147483647;else if(n<-2147483648)n=-2147483648;if(n=+n,Number.isNaN(n))n=i?0:e.length-1;if(n<0)n=e.length+n;if(n>=e.length)if(i)return-1;else n=e.length-1;else if(n<0)if(i)n=0;else return-1;if(typeof t==="string")t=xe.from(t,r);if(xe.isBuffer(t)){if(t.length===0)return-1;return IB(e,t,n,r,i)}else if(typeof t==="number"){if(t=t&255,typeof Uint8Array.prototype.indexOf==="function")if(i)return Uint8Array.prototype.indexOf.call(e,t,n);else return Uint8Array.prototype.lastIndexOf.call(e,t,n);return IB(e,[t],n,r,i)}throw TypeError("val must be string, number or Buffer")}function IB(e,t,n,r,i){let s=1,o=e.length,a=t.length;if(r!==void 0){if(r=String(r).toLowerCase(),r==="ucs2"||r==="ucs-2"||r==="utf16le"||r==="utf-16le"){if(e.length<2||t.length<2)return-1;s=2,o/=2,a/=2,n/=2}}function l(u,p){if(s===1)return u[p];else return u.readUInt16BE(p*s)}let c;if(i){let u=-1;for(c=n;co)n=o-a;for(c=n;c>=0;c--){let u=!0;for(let p=0;pi)r=i;let s=t.length;if(r>s/2)r=s/2;let o;for(o=0;o239?4:s>223?3:s>191?2:1;if(i+a<=n){let l,c,u,p;switch(a){case 1:if(s<128)o=s;break;case 2:if(l=e[i+1],(l&192)===128){if(p=(s&31)<<6|l&63,p>127)o=p}break;case 3:if(l=e[i+1],c=e[i+2],(l&192)===128&&(c&192)===128){if(p=(s&15)<<12|(l&63)<<6|c&63,p>2047&&(p<55296||p>57343))o=p}break;case 4:if(l=e[i+1],c=e[i+2],u=e[i+3],(l&192)===128&&(c&192)===128&&(u&192)===128){if(p=(s&15)<<18|(l&63)<<12|(c&63)<<6|u&63,p>65535&&p<1114112)o=p}}}if(o===null)o=65533,a=1;else if(o>65535)o-=65536,r.push(o>>>10&1023|55296),o=56320|o&1023;r.push(o),i+=a}return Kve(r)}function Kve(e){let t=e.length;if(t<=AB)return String.fromCharCode.apply(String,e);let n="",r=0;while(rr)n=r;let i="";for(let s=t;sn)throw RangeError("Trying to access beyond buffer length")}function hs(e,t,n,r,i,s){if(!xe.isBuffer(e))throw TypeError('"buffer" argument must be a Buffer instance');if(t>i||te.length)throw RangeError("Index out of range")}function VB(e,t,n,r,i){zB(t,r,i,e,n,7);let s=Number(t&BigInt(4294967295));e[n++]=s,s=s>>8,e[n++]=s,s=s>>8,e[n++]=s,s=s>>8,e[n++]=s;let o=Number(t>>BigInt(32)&BigInt(4294967295));return e[n++]=o,o=o>>8,e[n++]=o,o=o>>8,e[n++]=o,o=o>>8,e[n++]=o,n}function KB(e,t,n,r,i){zB(t,r,i,e,n,7);let s=Number(t&BigInt(4294967295));e[n+7]=s,s=s>>8,e[n+6]=s,s=s>>8,e[n+5]=s,s=s>>8,e[n+4]=s;let o=Number(t>>BigInt(32)&BigInt(4294967295));return e[n+3]=o,o=o>>8,e[n+2]=o,o=o>>8,e[n+1]=o,o=o>>8,e[n]=o,n+8}function JB(e,t,n,r,i,s){if(n+r>e.length)throw RangeError("Index out of range");if(n<0)throw RangeError("Index out of range")}function GB(e,t,n,r,i){if(t=+t,n=n>>>0,!i)JB(e,t,n,4,340282346638528860000000000000000000000,-340282346638528860000000000000000000000);return jB(e,t,n,r,23,4),n+4}function HB(e,t,n,r,i){if(t=+t,n=n>>>0,!i)JB(e,t,n,8,179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000,-179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000);return jB(e,t,n,r,52,8),n+8}function RB(e){let t="",n=e.length,r=e[0]==="-"?1:0;for(;n>=r+4;n-=3)t=`_${e.slice(n-3,n)}${t}`;return`${e.slice(0,n)}${t}`}function Wve(e,t,n){if(im(t,"offset"),e[t]===void 0||e[t+n]===void 0)cg(t,e.length-(n+1))}function zB(e,t,n,r,i,s){if(e>n||e3)if(t===0||t===BigInt(0))a=`>= 0${o} and < 2${o} ** ${(s+1)*8}${o}`;else a=`>= -(2${o} ** ${(s+1)*8-1}${o}) and < 2 ** ${(s+1)*8-1}${o}`;else a=`>= ${t}${o} and <= ${n}${o}`;throw new V1("value",a,e)}Wve(r,i,s)}function im(e,t){if(typeof e!=="number")throw new Ive(t,"number",e)}function cg(e,t,n){if(Math.floor(e)!==e)throw im(e,n),new V1(n||"offset","an integer",e);if(t<0)throw new $ve;throw new V1(n||"offset",`>= ${n?1:0} and <= ${t}`,e)}function Yve(e){if(e=e.split("=")[0],e=e.trim().replace(Qve,""),e.length<2)return"";while(e.length%4!==0)e=e+"=";return e}function G1(e,t){t=t||1/0;let n,r=e.length,i=null,s=[];for(let o=0;o55295&&n<57344){if(!i){if(n>56319){if((t-=3)>-1)s.push(239,191,189);continue}else if(o+1===r){if((t-=3)>-1)s.push(239,191,189);continue}i=n;continue}if(n<56320){if((t-=3)>-1)s.push(239,191,189);i=n;continue}n=(i-55296<<10|n-56320)+65536}else if(i){if((t-=3)>-1)s.push(239,191,189)}if(i=null,n<128){if((t-=1)<0)break;s.push(n)}else if(n<2048){if((t-=2)<0)break;s.push(n>>6|192,n&63|128)}else if(n<65536){if((t-=3)<0)break;s.push(n>>12|224,n>>6&63|128,n&63|128)}else if(n<1114112){if((t-=4)<0)break;s.push(n>>18|240,n>>12&63|128,n>>6&63|128,n&63|128)}else throw Error("Invalid code point")}return s}function Xve(e){let t=[];for(let n=0;n>8,i=n%256,s.push(i),s.push(r)}return s}function WB(e){return Dve(Yve(e))}function c0(e,t,n,r){let i;for(i=0;i=t.length||i>=e.length)break;t[i+n]=e[i]}return i}function Ya(e,t){return e instanceof t||e!=null&&e.constructor!=null&&e.constructor.name!=null&&e.constructor.name===t.name}function mu(e){return typeof BigInt>"u"?t_e:e}function t_e(){throw Error("BigInt not supported")}function Q1(e){return()=>{throw Error(e+" is not implemented for node:buffer browser polyfill")}}var Qa,wo,B1="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Qp,OB,$B,FB=50,lg=2147483647,CB=536870888,Eve,kve,Nve,Ove,Pve,$ve,Ive,V1,AB=4096,Qve,e_e,n_e,r_e,i_e=(e)=>{for(let t of e)if(t.charCodeAt(0)>127)return!1;return!0},s_e,o_e;var p0=q(()=>{Qa=[],wo=[];for(Qp=0,OB=B1.length;Qp4294967296)i=RB(String(n));else if(typeof n==="bigint"){if(i=String(n),n>BigInt(2)**BigInt(32)||n<-(BigInt(2)**BigInt(32)))i=RB(i);i+="n"}return r+=` It must be ${t}. Received ${i}`,r},RangeError);Object.defineProperty(xe.prototype,"parent",{enumerable:!0,get:function(){if(!xe.isBuffer(this))return;return this.buffer}});Object.defineProperty(xe.prototype,"offset",{enumerable:!0,get:function(){if(!xe.isBuffer(this))return;return this.byteOffset}});xe.poolSize=8192;xe.from=function(e,t,n){return MB(e,t,n)};Object.setPrototypeOf(xe.prototype,Uint8Array.prototype);Object.setPrototypeOf(xe,Uint8Array);xe.alloc=function(e,t,n){return Ave(e,t,n)};xe.allocUnsafe=function(e){return z1(e)};xe.allocUnsafeSlow=function(e){return z1(e)};xe.isBuffer=function(e){return e!=null&&e._isBuffer===!0&&e!==xe.prototype};xe.compare=function(e,t){if(Ya(e,Uint8Array))e=xe.from(e,e.offset,e.byteLength);if(Ya(t,Uint8Array))t=xe.from(t,t.offset,t.byteLength);if(!xe.isBuffer(e)||!xe.isBuffer(t))throw TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===t)return 0;let n=e.length,r=t.length;for(let i=0,s=Math.min(n,r);ir.length){if(!xe.isBuffer(s))s=xe.from(s);s.copy(r,i)}else Uint8Array.prototype.set.call(r,s,i);else if(!xe.isBuffer(s))throw TypeError('"list" argument must be an Array of Buffers');else s.copy(r,i);i+=s.length}return r};xe.byteLength=qB;xe.prototype._isBuffer=!0;xe.prototype.swap16=function(){let e=this.length;if(e%2!==0)throw RangeError("Buffer size must be a multiple of 16-bits");for(let t=0;tt)e+=" ... ";return""};if($B)xe.prototype[$B]=xe.prototype.inspect;xe.prototype.compare=function(e,t,n,r,i){if(Ya(e,Uint8Array))e=xe.from(e,e.offset,e.byteLength);if(!xe.isBuffer(e))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(t===void 0)t=0;if(n===void 0)n=e?e.length:0;if(r===void 0)r=0;if(i===void 0)i=this.length;if(t<0||n>e.length||r<0||i>this.length)throw RangeError("out of range index");if(r>=i&&t>=n)return 0;if(r>=i)return-1;if(t>=n)return 1;if(t>>>=0,n>>>=0,r>>>=0,i>>>=0,this===e)return 0;let s=i-r,o=n-t,a=Math.min(s,o),l=this.slice(r,i),c=e.slice(t,n);for(let u=0;u>>0,isFinite(n)){if(n=n>>>0,r===void 0)r="utf8"}else r=n,n=void 0;else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");let i=this.length-t;if(n===void 0||n>i)n=i;if(e.length>0&&(n<0||t<0)||t>this.length)throw RangeError("Attempt to write outside buffer bounds");if(!r)r="utf8";let s=!1;for(;;)switch(r){case"hex":return Mve(this,e,t,n);case"utf8":case"utf-8":return Lve(this,e,t,n);case"ascii":case"latin1":case"binary":return qve(this,e,t,n);case"base64":return Uve(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Bve(this,e,t,n);default:if(s)throw TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),s=!0}};xe.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};xe.prototype.slice=function(e,t){let n=this.length;if(e=~~e,t=t===void 0?n:~~t,e<0){if(e+=n,e<0)e=0}else if(e>n)e=n;if(t<0){if(t+=n,t<0)t=0}else if(t>n)t=n;if(t>>0,t=t>>>0,!n)zr(e,t,this.length);let r=this[e],i=1,s=0;while(++s>>0,t=t>>>0,!n)zr(e,t,this.length);let r=this[e+--t],i=1;while(t>0&&(i*=256))r+=this[e+--t]*i;return r};xe.prototype.readUint8=xe.prototype.readUInt8=function(e,t){if(e=e>>>0,!t)zr(e,1,this.length);return this[e]};xe.prototype.readUint16LE=xe.prototype.readUInt16LE=function(e,t){if(e=e>>>0,!t)zr(e,2,this.length);return this[e]|this[e+1]<<8};xe.prototype.readUint16BE=xe.prototype.readUInt16BE=function(e,t){if(e=e>>>0,!t)zr(e,2,this.length);return this[e]<<8|this[e+1]};xe.prototype.readUint32LE=xe.prototype.readUInt32LE=function(e,t){if(e=e>>>0,!t)zr(e,4,this.length);return(this[e]|this[e+1]<<8|this[e+2]<<16)+this[e+3]*16777216};xe.prototype.readUint32BE=xe.prototype.readUInt32BE=function(e,t){if(e=e>>>0,!t)zr(e,4,this.length);return this[e]*16777216+(this[e+1]<<16|this[e+2]<<8|this[e+3])};xe.prototype.readBigUInt64LE=mu(function(e){e=e>>>0,im(e,"offset");let t=this[e],n=this[e+7];if(t===void 0||n===void 0)cg(e,this.length-8);let r=t+this[++e]*256+this[++e]*65536+this[++e]*16777216,i=this[++e]+this[++e]*256+this[++e]*65536+n*16777216;return BigInt(r)+(BigInt(i)<>>0,im(e,"offset");let t=this[e],n=this[e+7];if(t===void 0||n===void 0)cg(e,this.length-8);let r=t*16777216+this[++e]*65536+this[++e]*256+this[++e],i=this[++e]*16777216+this[++e]*65536+this[++e]*256+n;return(BigInt(r)<>>0,t=t>>>0,!n)zr(e,t,this.length);let r=this[e],i=1,s=0;while(++s=i)r-=Math.pow(2,8*t);return r};xe.prototype.readIntBE=function(e,t,n){if(e=e>>>0,t=t>>>0,!n)zr(e,t,this.length);let r=t,i=1,s=this[e+--r];while(r>0&&(i*=256))s+=this[e+--r]*i;if(i*=128,s>=i)s-=Math.pow(2,8*t);return s};xe.prototype.readInt8=function(e,t){if(e=e>>>0,!t)zr(e,1,this.length);if(!(this[e]&128))return this[e];return(255-this[e]+1)*-1};xe.prototype.readInt16LE=function(e,t){if(e=e>>>0,!t)zr(e,2,this.length);let n=this[e]|this[e+1]<<8;return n&32768?n|4294901760:n};xe.prototype.readInt16BE=function(e,t){if(e=e>>>0,!t)zr(e,2,this.length);let n=this[e+1]|this[e]<<8;return n&32768?n|4294901760:n};xe.prototype.readInt32LE=function(e,t){if(e=e>>>0,!t)zr(e,4,this.length);return this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24};xe.prototype.readInt32BE=function(e,t){if(e=e>>>0,!t)zr(e,4,this.length);return this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]};xe.prototype.readBigInt64LE=mu(function(e){e=e>>>0,im(e,"offset");let t=this[e],n=this[e+7];if(t===void 0||n===void 0)cg(e,this.length-8);let r=this[e+4]+this[e+5]*256+this[e+6]*65536+(n<<24);return(BigInt(r)<>>0,im(e,"offset");let t=this[e],n=this[e+7];if(t===void 0||n===void 0)cg(e,this.length-8);let r=(t<<24)+this[++e]*65536+this[++e]*256+this[++e];return(BigInt(r)<>>0,!t)zr(e,4,this.length);return l0(this,e,!0,23,4)};xe.prototype.readFloatBE=function(e,t){if(e=e>>>0,!t)zr(e,4,this.length);return l0(this,e,!1,23,4)};xe.prototype.readDoubleLE=function(e,t){if(e=e>>>0,!t)zr(e,8,this.length);return l0(this,e,!0,52,8)};xe.prototype.readDoubleBE=function(e,t){if(e=e>>>0,!t)zr(e,8,this.length);return l0(this,e,!1,52,8)};xe.prototype.writeUintLE=xe.prototype.writeUIntLE=function(e,t,n,r){if(e=+e,t=t>>>0,n=n>>>0,!r){let o=Math.pow(2,8*n)-1;hs(this,e,t,n,o,0)}let i=1,s=0;this[t]=e&255;while(++s>>0,n=n>>>0,!r){let o=Math.pow(2,8*n)-1;hs(this,e,t,n,o,0)}let i=n-1,s=1;this[t+i]=e&255;while(--i>=0&&(s*=256))this[t+i]=e/s&255;return t+n};xe.prototype.writeUint8=xe.prototype.writeUInt8=function(e,t,n){if(e=+e,t=t>>>0,!n)hs(this,e,t,1,255,0);return this[t]=e&255,t+1};xe.prototype.writeUint16LE=xe.prototype.writeUInt16LE=function(e,t,n){if(e=+e,t=t>>>0,!n)hs(this,e,t,2,65535,0);return this[t]=e&255,this[t+1]=e>>>8,t+2};xe.prototype.writeUint16BE=xe.prototype.writeUInt16BE=function(e,t,n){if(e=+e,t=t>>>0,!n)hs(this,e,t,2,65535,0);return this[t]=e>>>8,this[t+1]=e&255,t+2};xe.prototype.writeUint32LE=xe.prototype.writeUInt32LE=function(e,t,n){if(e=+e,t=t>>>0,!n)hs(this,e,t,4,4294967295,0);return this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=e&255,t+4};xe.prototype.writeUint32BE=xe.prototype.writeUInt32BE=function(e,t,n){if(e=+e,t=t>>>0,!n)hs(this,e,t,4,4294967295,0);return this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=e&255,t+4};xe.prototype.writeBigUInt64LE=mu(function(e,t=0){return VB(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))});xe.prototype.writeBigUInt64BE=mu(function(e,t=0){return KB(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))});xe.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t=t>>>0,!r){let a=Math.pow(2,8*n-1);hs(this,e,t,n,a-1,-a)}let i=0,s=1,o=0;this[t]=e&255;while(++i>0)-o&255}return t+n};xe.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t=t>>>0,!r){let a=Math.pow(2,8*n-1);hs(this,e,t,n,a-1,-a)}let i=n-1,s=1,o=0;this[t+i]=e&255;while(--i>=0&&(s*=256)){if(e<0&&o===0&&this[t+i+1]!==0)o=1;this[t+i]=(e/s>>0)-o&255}return t+n};xe.prototype.writeInt8=function(e,t,n){if(e=+e,t=t>>>0,!n)hs(this,e,t,1,127,-128);if(e<0)e=255+e+1;return this[t]=e&255,t+1};xe.prototype.writeInt16LE=function(e,t,n){if(e=+e,t=t>>>0,!n)hs(this,e,t,2,32767,-32768);return this[t]=e&255,this[t+1]=e>>>8,t+2};xe.prototype.writeInt16BE=function(e,t,n){if(e=+e,t=t>>>0,!n)hs(this,e,t,2,32767,-32768);return this[t]=e>>>8,this[t+1]=e&255,t+2};xe.prototype.writeInt32LE=function(e,t,n){if(e=+e,t=t>>>0,!n)hs(this,e,t,4,2147483647,-2147483648);return this[t]=e&255,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4};xe.prototype.writeInt32BE=function(e,t,n){if(e=+e,t=t>>>0,!n)hs(this,e,t,4,2147483647,-2147483648);if(e<0)e=4294967295+e+1;return this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=e&255,t+4};xe.prototype.writeBigInt64LE=mu(function(e,t=0){return VB(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});xe.prototype.writeBigInt64BE=mu(function(e,t=0){return KB(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});xe.prototype.writeFloatLE=function(e,t,n){return GB(this,e,t,!0,n)};xe.prototype.writeFloatBE=function(e,t,n){return GB(this,e,t,!1,n)};xe.prototype.writeDoubleLE=function(e,t,n){return HB(this,e,t,!0,n)};xe.prototype.writeDoubleBE=function(e,t,n){return HB(this,e,t,!1,n)};xe.prototype.copy=function(e,t,n,r){if(!xe.isBuffer(e))throw TypeError("argument should be a Buffer");if(!n)n=0;if(!r&&r!==0)r=this.length;if(t>=e.length)t=e.length;if(!t)t=0;if(r>0&&r=this.length)throw RangeError("Index out of range");if(r<0)throw RangeError("sourceEnd out of bounds");if(r>this.length)r=this.length;if(e.length-t>>0,n=n===void 0?this.length:n>>>0,!e)e=0;let i;if(typeof e==="number")for(i=t;i>>32-i,n)}function Ti(e,t,n,r,i,s,o){return d0(t&n|~t&r,e,t,i,s,o)}function Si(e,t,n,r,i,s,o){return d0(t&r|n&~r,e,t,i,s,o)}function Ei(e,t,n,r,i,s,o){return d0(t^n^r,e,t,i,s,o)}function ki(e,t,n,r,i,s,o){return d0(n^(t|~r),e,t,i,s,o)}function c_e(e){var t=e.length,n=[1732584193,-271733879,-1732584194,271733878],r;for(r=64;r<=e.length;r+=64)X1(n,u_e(e.substring(r-64,r)));e=e.substring(r-64);var i=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];for(r=0;r>2]|=e.charCodeAt(r)<<(r%4<<3);if(i[r>>2]|=128<<(r%4<<3),r>55){X1(n,i);for(r=0;r<16;r++)i[r]=0}return i[14]=t*8,X1(n,i),n}function u_e(e){var t=[],n;for(n=0;n<64;n+=4)t[n>>2]=e.charCodeAt(n)+(e.charCodeAt(n+1)<<8)+(e.charCodeAt(n+2)<<16)+(e.charCodeAt(n+3)<<24);return t}function p_e(e){var t=c_e(e),n=Y1.alloc?Y1.alloc(16):new Y1(16),r;for(r=0;r<4;r++)n.writeIntLE(t[r],r*4,4);return n}function yu(e,t){return e+t&4294967295}QB.exports={createHash:l_e}});var cN={};Of(cN,{TextDecoder:()=>o8,TextEncoder:()=>s8,_extend:()=>aN,callbackify:()=>i8,callbackifyOnRejected:()=>lN,debuglog:()=>m_e,default:()=>N_e,deprecate:()=>f_e,format:()=>iN,inherits:()=>t8,inspect:()=>Xp,isArray:()=>XB,isBoolean:()=>sN,isBuffer:()=>S_e,isDate:()=>rN,isError:()=>m0,isFunction:()=>y0,isNull:()=>g0,isNullOrUndefined:()=>w_e,isNumber:()=>ZB,isObject:()=>om,isPrimitive:()=>T_e,isRegExp:()=>f0,isString:()=>b0,isSymbol:()=>D_e,isUndefined:()=>sm,log:()=>e8,promisify:()=>r8,types:()=>x_e});function iN(e,...t){if(!b0(e)){var n=[e];for(var r=0;r=i)return a;switch(a){case"%s":return String(t[r++]);case"%d":return Number(t[r++]);case"%j":try{return JSON.stringify(t[r++])}catch(l){return"[Circular]"}default:return a}});for(var o=t[r];r"u"||process?.noDeprecation===!0)return e;var n=!1;function r(...i){if(!n){if(process.throwDeprecation)throw Error(t);else if(process.traceDeprecation)console.trace(t);else console.error(t);n=!0}return e.apply(this,...i)}return r}function y_e(e,t){var n=Xp.styles[t];if(n)return"\x1B["+Xp.colors[n][0]+"m"+e+"\x1B["+Xp.colors[n][1]+"m";else return e}function h_e(e,t){return e}function g_e(e){var t={};return e.forEach(function(n,r){t[n]=!0}),t}function h0(e,t,n){if(e.customInspect&&t&&y0(t.inspect)&&t.inspect!==Xp&&!(t.constructor&&t.constructor.prototype===t)){var r=t.inspect(n,e);if(!b0(r))r=h0(e,r,n);return r}var i=b_e(e,t);if(i)return i;var s=Object.keys(t),o=g_e(s);if(e.showHidden)s=Object.getOwnPropertyNames(t);if(m0(t)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return eN(t);if(s.length===0){if(y0(t)){var a=t.name?": "+t.name:"";return e.stylize("[Function"+a+"]","special")}if(f0(t))return e.stylize(RegExp.prototype.toString.call(t),"regexp");if(rN(t))return e.stylize(Date.prototype.toString.call(t),"date");if(m0(t))return eN(t)}var l="",c=!1,u=["{","}"];if(XB(t))c=!0,u=["[","]"];if(y0(t)){var p=t.name?": "+t.name:"";l=" [Function"+p+"]"}if(f0(t))l=" "+RegExp.prototype.toString.call(t);if(rN(t))l=" "+Date.prototype.toUTCString.call(t);if(m0(t))l=" "+eN(t);if(s.length===0&&(!c||t.length==0))return u[0]+l+u[1];if(n<0)if(f0(t))return e.stylize(RegExp.prototype.toString.call(t),"regexp");else return e.stylize("[Object]","special");e.seen.push(t);var d;if(c)d=v_e(e,t,n,o,s);else d=s.map(function(f){return nN(e,t,n,o,f,c)});return e.seen.pop(),__e(d,l,u)}function b_e(e,t){if(sm(t))return e.stylize("undefined","undefined");if(b0(t)){var n="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(n,"string")}if(ZB(t))return e.stylize(""+t,"number");if(sN(t))return e.stylize(""+t,"boolean");if(g0(t))return e.stylize("null","null")}function eN(e){return"["+Error.prototype.toString.call(e)+"]"}function v_e(e,t,n,r,i){var s=[];for(var o=0,a=t.length;o-1)if(s)a=a.split(` `).map(function(c){return" "+c}).join(` `).slice(2);else a=` `+a.split(` `).map(function(c){return" "+c}).join(` -`)}else a=e.stylize("[Circular]","special");if(rm(o)){if(s&&i.match(/^\d+$/))return a;if(o=JSON.stringify(""+i),o.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/))o=o.slice(1,-1),o=e.stylize(o,"name");else o=o.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),o=e.stylize(o,"string")}return o+": "+a}function v_e(e,t,n){var r=0,i=e.reduce(function(s,o){if(r++,o.indexOf(` +`)}else a=e.stylize("[Circular]","special");if(sm(o)){if(s&&i.match(/^\d+$/))return a;if(o=JSON.stringify(""+i),o.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/))o=o.slice(1,-1),o=e.stylize(o,"name");else o=o.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),o=e.stylize(o,"string")}return o+": "+a}function __e(e,t,n){var r=0,i=e.reduce(function(s,o){if(r++,o.indexOf(` `)>=0)r++;return s+o.replace(/\u001b\[\d\d?m/g,"").length+1},0);if(i>60)return n[0]+(t===""?"":t+` `)+" "+e.join(`, - `)+" "+n[1];return n[0]+t+" "+e.join(", ")+" "+n[1]}function XB(e){return Array.isArray(e)}function sN(e){return typeof e==="boolean"}function g0(e){return e===null}function x_e(e){return e==null}function ZB(e){return typeof e==="number"}function b0(e){return typeof e==="string"}function w_e(e){return typeof e==="symbol"}function rm(e){return e===void 0}function f0(e){return im(e)&&oN(e)==="[object RegExp]"}function im(e){return typeof e==="object"&&e!==null}function rN(e){return im(e)&&oN(e)==="[object Date]"}function m0(e){return im(e)&&(oN(e)==="[object Error]"||e instanceof Error)}function y0(e){return typeof e==="function"}function D_e(e){return e===null||typeof e==="boolean"||typeof e==="number"||typeof e==="string"||typeof e==="symbol"||typeof e>"u"}function T_e(e){return e instanceof Buffer}function oN(e){return Object.prototype.toString.call(e)}function tN(e){return e<10?"0"+e.toString(10):e.toString(10)}function E_e(){var e=new Date,t=[tN(e.getHours()),tN(e.getMinutes()),tN(e.getSeconds())].join(":");return[e.getDate(),S_e[e.getMonth()],t].join(" ")}function e8(...e){console.log("%s - %s",E_e(),iN.apply(null,e))}function t8(e,t){if(t)e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}function aN(e,t){if(!t||!im(t))return e;var n=Object.keys(t),r=n.length;while(r--)e[n[r]]=t[n[r]];return e}function n8(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function lN(e,t){if(!e){var n=Error("Promise was rejected with a falsy value");n.reason=e,e=n}return t(e)}function i8(e){if(typeof e!=="function")throw TypeError('The "original" argument must be of type Function');function t(...n){var r=n.pop();if(typeof r!=="function")throw TypeError("The last argument must be of type Function");var i=this,s=function(...o){return r.apply(i,...o)};e.apply(this,n).then(function(o){process.nextTick(s.bind(null,null,o))},function(o){process.nextTick(lN.bind(null,o,s))})}return Object.setPrototypeOf(t,Object.getPrototypeOf(e)),Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)),t}var p_e,f_e,Qp,__e=()=>{},S_e,r8,s8,o8,k_e;var uN=q(()=>{p_e=/%[sdj%]/g;f_e=((e={},t={},n)=>((n=typeof process<"u"&&!1)&&(n=n.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase()),t=new RegExp("^"+n+"$","i"),(r)=>{if(r=r.toUpperCase(),!e[r])if(t.test(r))e[r]=function(...i){console.error("%s: %s",r,pid,iN.apply(null,...i))};else e[r]=function(){};return e[r]}))(),Qp=((e)=>(e.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},e.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},e.custom=Symbol.for("nodejs.util.inspect.custom"),e))(function(e,t,...n){var r={seen:[],stylize:y_e};if(n.length>=1)r.depth=n[0];if(n.length>=2)r.colors=n[1];if(sN(t))r.showHidden=t;else if(t)aN(r,t);if(rm(r.showHidden))r.showHidden=!1;if(rm(r.depth))r.depth=2;if(rm(r.colors))r.colors=!1;if(r.colors)r.stylize=m_e;return h0(r,e,r.depth)});S_e=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];r8=((e)=>(e.custom=Symbol.for("nodejs.util.promisify.custom"),e))(function(e){if(typeof e!=="function")throw TypeError('The "original" argument must be of type Function');if(kCustomPromisifiedSymbol&&e[kCustomPromisifiedSymbol]){var t=e[kCustomPromisifiedSymbol];if(typeof t!=="function")throw TypeError('The "nodejs.util.promisify.custom" argument must be of type Function');return Object.defineProperty(t,kCustomPromisifiedSymbol,{value:t,enumerable:!1,writable:!1,configurable:!0}),t}function t(...n){var r,i,s=new Promise(function(o,a){r=o,i=a});n.push(function(o,a){if(o)i(o);else r(a)});try{e.apply(this,n)}catch(o){i(o)}return s}if(Object.setPrototypeOf(t,Object.getPrototypeOf(e)),kCustomPromisifiedSymbol)Object.defineProperty(t,kCustomPromisifiedSymbol,{value:t,enumerable:!1,writable:!1,configurable:!0});return Object.defineProperties(t,Object.getOwnPropertyDescriptors(e))});({TextEncoder:s8,TextDecoder:o8}=globalThis),k_e={TextEncoder:s8,TextDecoder:o8,promisify:r8,log:e8,inherits:t8,_extend:aN,callbackifyOnRejected:lN,callbackify:i8}});var f8=z(function(vWe,d8){var a8=(p0(),Ef(u0)),N_e=YB(),l8=(uN(),Ef(cN)),Ks=a8.Buffer,O_e=new dN(4096),P_e=/^[A-Za-z_][A-Za-z0-9_]*$/,$_e=l8.format;function ug(e){if(typeof Ks.alloc=="function")return Ks.alloc(e);else return new Ks(e)}function I_e(e){if(typeof Ks.allocUnsafeSlow=="function")return Ks.allocUnsafeSlow(e);else return new a8.SlowBuffer(e)}function c8(e,t){if(typeof Ks.from=="function")return Ks.from(e,t);else return new Ks(e,t)}function u8(e){return e.charAt(0).toUpperCase()+e.slice(1)}function A_e(e,t){return e===t?0:e=0)return-2;n=r}return n}function C_e(e,t){var n={},r,i;for(r=0;rt)return ug(e);if(this._pos+e>t)this._slab=ug(t),this._pos=0;return this._slab.slice(this._pos,this._pos+=e)};function Yp(e){var t=1103515245,n=12345,r=Math.pow(2,31),i=Math.floor(e||Math.random()*(r-1));this._max=r,this._nextInt=function(){return i=(t*i+n)%r}}Yp.prototype.nextBoolean=function(){return!!(this._nextInt()%2)};Yp.prototype.nextInt=function(e,t){if(t===void 0)t=e,e=0;return t=t===void 0?this._max:t,e+Math.floor(this.nextFloat()*(t-e))};Yp.prototype.nextFloat=function(e,t){if(t===void 0)t=e,e=0;return t=t===void 0?1:t,e+(t-e)*this._nextInt()/this._max};Yp.prototype.nextString=function(e,t){e|=0,t=t||"aA";var n="";if(t.indexOf("a")>-1)n+="abcdefghijklmnopqrstuvwxyz";if(t.indexOf("A")>-1)n+="ABCDEFGHIJKLMNOPQRSTUVWXYZ";if(t.indexOf("#")>-1)n+="0123456789";if(t.indexOf("!")>-1)n+="~`!@#$%^&*()_+-={}[]:\";'<>?,./|\\";var r=[];for(var i=0;i0&&t[n].index>1].index)e=t[n],t[n]=t[r],t[r]=e,n=r};fN.prototype.pop=function(){var e=this._items,t=e.length-1|0,n=e[0];if(!n||n.index>this._index)return null;if(this._index++,!t)return e.pop(),n;e[0]=e.pop();var r=t>>1,i=0,s,o,a,l,c,u,p;while(i=l.index)break;e[a]=l,e[i]=c,i=a}return n};function jt(e,t){if(this.buf=e,this.pos=t|0,this.pos<0)throw Error("negative offset")}jt.prototype.isValid=function(){return this.pos<=this.buf.length};jt.prototype._invalidate=function(){this.pos=this.buf.length+1};jt.prototype.readBoolean=function(){return!!this.buf[this.pos++]};jt.prototype.skipBoolean=function(){this.pos++};jt.prototype.writeBoolean=function(e){this.buf[this.pos++]=!!e};jt.prototype.readInt=jt.prototype.readLong=function(){var e=0,t=0,n=this.buf,r,i,s,o;do r=n[this.pos++],i=r&128,e|=(r&127)<>1^-(e&1)};jt.prototype.skipInt=jt.prototype.skipLong=function(){var e=this.buf;while(e[this.pos++]&128);};jt.prototype.writeInt=jt.prototype.writeLong=function(e){var t=this.buf,n,r;if(e>=-1073741824&&e<1073741824){r=e>=0?e<<1:~e<<1|1;do t[this.pos]=r&127,r>>=7;while(r&&(t[this.pos++]|=128))}else{n=e>=0?e*2:-e*2-1;do t[this.pos]=n&127,n/=128;while(n>=1&&(t[this.pos++]|=128))}this.pos++};jt.prototype.readFloat=function(){var e=this.buf,t=this.pos;if(this.pos+=4,this.pos>e.length)return 0;return this.buf.readFloatLE(t)};jt.prototype.skipFloat=function(){this.pos+=4};jt.prototype.writeFloat=function(e){var t=this.buf,n=this.pos;if(this.pos+=4,this.pos>t.length)return;return this.buf.writeFloatLE(e,n)};jt.prototype.readDouble=function(){var e=this.buf,t=this.pos;if(this.pos+=8,this.pos>e.length)return 0;return this.buf.readDoubleLE(t)};jt.prototype.skipDouble=function(){this.pos+=8};jt.prototype.writeDouble=function(e){var t=this.buf,n=this.pos;if(this.pos+=8,this.pos>t.length)return;return this.buf.writeDoubleLE(e,n)};jt.prototype.readFixed=function(e){var t=this.pos;if(this.pos+=e,this.pos>this.buf.length)return;var n=O_e.alloc(e);return this.buf.copy(n,0,t,t+e),n};jt.prototype.skipFixed=function(e){this.pos+=e};jt.prototype.writeFixed=function(e,t){t=t||e.length;var n=this.pos;if(this.pos+=t,this.pos>this.buf.length)return;e.copy(this.buf,n,0,t)};jt.prototype.readBytes=function(){var e=this.readLong();if(e<0){this._invalidate();return}return this.readFixed(e)};jt.prototype.skipBytes=function(){var e=this.readLong();if(e<0){this._invalidate();return}this.pos+=e};jt.prototype.writeBytes=function(e){var t=e.length;this.writeLong(t),this.writeFixed(e,t)};if(typeof Ks.prototype.utf8Slice=="function")jt.prototype.readString=function(){var e=this.readLong();if(e<0)return this._invalidate(),"";var t=this.pos,n=this.buf;if(this.pos+=e,this.pos>n.length)return;return this.buf.utf8Slice(t,t+e)};else jt.prototype.readString=function(){var e=this.readLong();if(e<0)return this._invalidate(),"";var t=this.pos,n=this.buf;if(this.pos+=e,this.pos>n.length)return;return this.buf.slice(t,t+e).toString()};jt.prototype.skipString=function(){var e=this.readLong();if(e<0){this._invalidate();return}this.pos+=e};jt.prototype.writeString=function(e){var t=Ks.byteLength(e),n=this.buf;this.writeLong(t);var r=this.pos;if(this.pos+=t,this.pos>n.length)return;if(t>64&&typeof Ks.prototype.utf8Write=="function")n.utf8Write(e,r,t);else{var i,s,o,a;for(i=0,s=t;i>6|192,n[r++]=o&63|128;else if((o&64512)===55296&&((a=e.charCodeAt(i+1))&64512)===56320)o=65536+((o&1023)<<10)+(a&1023),i++,n[r++]=o>>18|240,n[r++]=o>>12&63|128,n[r++]=o>>6&63|128,n[r++]=o&63|128;else n[r++]=o>>12|224,n[r++]=o>>6&63|128,n[r++]=o&63|128}};if(typeof Ks.prototype.latin1Write=="function")jt.prototype.writeBinary=function(e,t){var n=this.pos;if(this.pos+=t,this.pos>this.buf.length)return;this.buf.latin1Write(e,n,t)};else if(typeof Ks.prototype.binaryWrite=="function")jt.prototype.writeBinary=function(e,t){var n=this.pos;if(this.pos+=t,this.pos>this.buf.length)return;this.buf.binaryWrite(e,n,t)};else jt.prototype.writeBinary=function(e,t){var n=this.pos;if(this.pos+=t,this.pos>this.buf.length)return;this.buf.write(e,n,t,"binary")};jt.prototype.matchBoolean=function(e){return this.buf[this.pos++]-e.buf[e.pos++]};jt.prototype.matchInt=jt.prototype.matchLong=function(e){var t=this.readLong(),n=e.readLong();return t===n?0:t>1;while(s&128)if(s=i[this.pos++],t|=(s&127)<=8)r-=8,e[n++]=t,t>>=8;if(e[n]=t,o)pN(e,8);return e};jt.prototype.packLongBytes=function(e){var t=(e[7]&128)>>7,n=this.buf,r=1,i=0,s=3,o;if(t)pN(e,8),o=1;else o=0;var a=[e.readUIntLE(0,3),e.readUIntLE(3,3),e.readUIntLE(6,2)];while(s&&!a[--s]);while(i7)n[this.pos++]=o&127|128,o>>=7,r-=7}o|=a[s]<>=7;while(o&&(n[this.pos++]|=128));if(this.pos++,t)pN(e,8)};function pN(e,t){while(t--)e[t]=~e[t]}d8.exports={abstractFunction:J_e,addDeprecatedGetters:G_e,bufferFrom:c8,capitalize:u8,copyOwnProperties:q_e,getHash:j_e,compare:A_e,getOption:R_e,impliedNamespace:V_e,isValidName:p8,jsonEnd:K_e,newBuffer:ug,newSlowBuffer:I_e,objectValues:M_e,qualify:U_e,toMap:C_e,singleIndexOf:F_e,hasDuplicates:L_e,unqualify:B_e,BufferPool:dN,Lcg:Yp,OrderedQueue:fN,Tap:jt}});var _8=z(function(_We,v8){var bt=f8(),H_e=(p0(),Ef(u0)),ur=(uN(),Ef(cN)),yu=H_e.Buffer,Zp=bt.Tap,mN=ur.debuglog("avsc:types"),Lt=ur.format,v0={array:vs,boolean:Hl,bytes:Gs,double:Za,enum:gs,error:cr,fixed:bs,float:Xa,int:zl,long:Js,map:Hi,null:Do,record:cr,string:ga},li=new bt.Lcg,Xp=new Zp(bt.newSlowBuffer(1024)),ha=null,sm=[];function Ee(e,t){var n;if(ha)n=ha,sm.push([ha,this]),ha=null;else n=this;if(this._hash=new z_e,this.name=void 0,this.aliases=void 0,this.doc=e&&e.doc?""+e.doc:void 0,e){var r=e.name,i=e.namespace===void 0?t&&t.namespace:e.namespace;if(r!==void 0){if(r=hN(r,i),om(r))throw Error(Lt("cannot rename primitive type: %j",r));var s=t&&t.registry;if(s){if(s[r]!==void 0)throw Error(Lt("duplicate type name: %s",r));s[r]=n}}else if(t&&t.noAnonymousTypes)throw Error(Lt("missing name property in schema: %j",e));this.name=r,this.aliases=e.aliases?e.aliases.map(function(o){return hN(o,i)}):[]}}Ee.forSchema=function(e,t){t=t||{},t.registry=t.registry||{};var n=function(c){if(c===!0)c="always";else if(c===!1)c="never";else if(c===void 0)c="auto";else if(typeof c=="string")c=c.toLowerCase();switch(c){case"always":return To;case"never":return hs;case"auto":return;default:throw Error(Lt("invalid wrap unions option: %j",c))}}(t.wrapUnions);if(e===null)throw Error('invalid type: null (did you mean "null"?)');if(Ee.isType(e))return e;var r;if(t.typeHook&&(r=t.typeHook(e,t))){if(!Ee.isType(r))throw Error(Lt("invalid typehook return value: %j",r));return r}if(typeof e=="string"){if(e=hN(e,t.namespace),r=t.registry[e],r)return r;if(om(e))return t.registry[e]=Ee.forSchema({type:e},t);throw Error(Lt("undefined type name: %s",e))}if(e.logicalType&&t.logicalTypes&&!ha){var i=t.logicalTypes[e.logicalType];if(i){var s=t.namespace,o={};Object.keys(t.registry).forEach(function(c){o[c]=t.registry[c]});try{return mN("instantiating logical type for %s",e.logicalType),new i(e,t)}catch(c){if(mN("failed to instantiate logical type for %s",e.logicalType),t.assertLogicalTypes)throw c;ha=null,t.namespace=s,t.registry=o}}}if(Array.isArray(e)){var a=ha;ha=null;var l=e.map(function(c){return Ee.forSchema(c,t)});if(!n)n=W_e(l)?To:hs;ha=a,r=new n(l,t)}else r=function(c){var u=v0[c];if(u===void 0)throw Error(Lt("unknown type: %j",c));return new u(e,t)}(e.type);return r};Ee.forValue=function(e,t){if(t=t||{},t.emptyArrayType=t.emptyArrayType||Ee.forSchema({type:"array",items:"null"}),t.valueHook){var n=t.valueHook(e,t);if(n!==void 0){if(!Ee.isType(n))throw Error(Lt("invalid value hook return value: %j",n));return n}}switch(typeof e){case"string":return Ee.forSchema("string",t);case"boolean":return Ee.forSchema("boolean",t);case"number":if((e|0)===e)return Ee.forSchema("int",t);else if(Math.abs(e)<9007199254740991)return Ee.forSchema("float",t);return Ee.forSchema("double",t);case"object":if(e===null)return Ee.forSchema("null",t);else if(Array.isArray(e)){if(!e.length)return t.emptyArrayType;return Ee.forSchema({type:"array",items:Ee.forTypes(e.map(function(i){return Ee.forValue(i,t)}),t)},t)}else if(yu.isBuffer(e))return Ee.forSchema("bytes",t);var r=Object.keys(e);if(r.some(function(i){return!bt.isValidName(i)}))return Ee.forSchema({type:"map",values:Ee.forTypes(r.map(function(i){return Ee.forValue(e[i],t)}),t)},t);return Ee.forSchema({type:"record",fields:r.map(function(i){return{name:i,type:Ee.forValue(e[i],t)}})},t);default:throw Error(Lt("cannot infer type from: %j",e))}};Ee.forTypes=function(e,t){if(!e.length)throw Error("no types to combine");if(e.length===1)return e[0];t=t||{};var n=[],r=0,i=!0;if(e.forEach(function(p){switch(p.typeName){case"union:unwrapped":i=!1,n=n.concat(p.types);break;case"union:wrapped":r++,n=n.concat(p.types);break;case"null":n.push(p);break;default:i=!1,n.push(p)}}),r){if(!i)throw Error("cannot combine wrapped union");var s={};n.forEach(function(p){var d=p.branchName,f=s[d];if(!f)s[d]=p;else if(!p.equals(f))throw Error("inconsistent branch type")});var o=t.wrapUnions,a;t.wrapUnions=!0;try{a=Ee.forSchema(Object.keys(s).map(function(p){return s[p]}),t)}catch(p){throw t.wrapUnions=o,p}return t.wrapUnions=o,a}var l={};n.forEach(function(p){var d=_0(p),f=l[d];if(!f)l[d]=f=[];f.push(p)});var c=Object.keys(l),u=c.map(function(p){var d=l[p];if(d.length===1)return d[0];else switch(p){case"null":case"boolean":return d[0];case"number":return Q_e(d);case"string":return Y_e(d,t);case"buffer":return X_e(d,t);case"array":if(d=d.filter(function(f){return f!==t.emptyArrayType}),!d.length)return t.emptyArrayType;return Ee.forSchema({type:"array",items:Ee.forTypes(d.map(function(f){return f.itemsType}),t)},t);default:return Z_e(d,t)}});if(u.length===1)return u[0];else return Ee.forSchema(u,t)};Ee.isType=function(){var e=arguments.length;if(!e)return!1;var t=arguments[0];if(!t||typeof t._update!="function"||typeof t.fingerprint!="function")return!1;if(e===1)return!0;var n=t.typeName,r;for(r=1;r",t);else{var n=this.schema({exportAttrs:!0,noDeref:!0});if(typeof n=="object"&&!Ee.isType(this,"logical"))n.type=void 0;return Lt("<%s %j>",t,n)}};Ee.prototype.isValid=function(e,t){var n=(t&&t.noUndeclaredFields)|0,r=t&&t.errorHook,i,s;if(r)s=[],i=function(o,a){r.call(this,s.slice(),o,a,e)};return this._check(e,n,i,s)};Ee.prototype.random=bt.abstractFunction;Ee.prototype.schema=function(e){return this._attrs({exportAttrs:!!(e&&e.exportAttrs),noDeref:!!(e&&e.noDeref)})};Ee.prototype.toBuffer=function(e){Xp.pos=0,this._write(Xp,e);var t=bt.newBuffer(Xp.pos);if(Xp.isValid())Xp.buf.copy(t,0,0,Xp.pos);else this._write(new Zp(t),e);return t};Ee.prototype.toJSON=function(){return this.schema({exportAttrs:!0})};Ee.prototype.toString=function(e){if(e===void 0)return JSON.stringify(this.schema({noDeref:!0}));return JSON.stringify(this._copy(e,{coerce:3}))};Ee.prototype.wrap=function(e){var t=this._branchConstructor;return t===null?null:new t(e)};Ee.prototype._attrs=function(e){e.derefed=e.derefed||{};var t=this.name;if(t!==void 0){if(e.noDeref||e.derefed[t])return t;e.derefed[t]=!0}var n={};if(this.name!==void 0)n.name=t;n.type=this.typeName;var r=this._deref(n,e);if(r!==void 0)n=r;if(e.exportAttrs){if(this.aliases&&this.aliases.length)n.aliases=this.aliases;if(this.doc!==void 0)n.doc=this.doc}return n};Ee.prototype._createBranchConstructor=function(){var e=this.branchName;if(e==="null")return null;var t=~e.indexOf(".")?"this['"+e+"']":"this."+e,n="return function Branch$(val) { "+t+" = val; };",r=Function(n)();return r.type=this,r.prototype.unwrap=Function("return "+t+";"),r.prototype.unwrapped=r.prototype.unwrap,r};Ee.prototype._peek=function(e){var t=e.pos,n=this._read(e);return e.pos=t,n};Ee.prototype._check=bt.abstractFunction;Ee.prototype._copy=bt.abstractFunction;Ee.prototype._deref=bt.abstractFunction;Ee.prototype._match=bt.abstractFunction;Ee.prototype._read=bt.abstractFunction;Ee.prototype._skip=bt.abstractFunction;Ee.prototype._update=bt.abstractFunction;Ee.prototype._write=bt.abstractFunction;Ee.prototype.getAliases=function(){return this.aliases};Ee.prototype.getFingerprint=Ee.prototype.fingerprint;Ee.prototype.getName=function(e){return this.name||!e?this.name:this.branchName};Ee.prototype.getSchema=Ee.prototype.schema;Ee.prototype.getTypeName=function(){return this.typeName};function er(e){if(Ee.call(this),this._branchConstructor=this._createBranchConstructor(),!e)Object.freeze(this)}ur.inherits(er,Ee);er.prototype._update=function(e,t){if(t.typeName===this.typeName)e._read=this._read};er.prototype._copy=function(e){return this._check(e,void 0,On),e};er.prototype._deref=function(){return this.typeName};er.prototype.compare=bt.compare;function Do(){er.call(this)}ur.inherits(Do,er);Do.prototype._check=function(e,t,n){var r=e===null;if(!r&&n)n(e,this);return r};Do.prototype._read=function(){return null};Do.prototype._skip=function(){};Do.prototype._write=function(e,t){if(t!==null)On(t,this)};Do.prototype._match=function(){return 0};Do.prototype.compare=Do.prototype._match;Do.prototype.typeName="null";Do.prototype.random=Do.prototype._read;function Hl(){er.call(this)}ur.inherits(Hl,er);Hl.prototype._check=function(e,t,n){var r=typeof e=="boolean";if(!r&&n)n(e,this);return r};Hl.prototype._read=function(e){return e.readBoolean()};Hl.prototype._skip=function(e){e.skipBoolean()};Hl.prototype._write=function(e,t){if(typeof t!="boolean")On(t,this);e.writeBoolean(t)};Hl.prototype._match=function(e,t){return e.matchBoolean(t)};Hl.prototype.typeName="boolean";Hl.prototype.random=function(){return li.nextBoolean()};function zl(){er.call(this)}ur.inherits(zl,er);zl.prototype._check=function(e,t,n){var r=e===(e|0);if(!r&&n)n(e,this);return r};zl.prototype._read=function(e){return e.readInt()};zl.prototype._skip=function(e){e.skipInt()};zl.prototype._write=function(e,t){if(t!==(t|0))On(t,this);e.writeInt(t)};zl.prototype._match=function(e,t){return e.matchInt(t)};zl.prototype.typeName="int";zl.prototype.random=function(){return li.nextInt(1000)|0};function Js(){er.call(this)}ur.inherits(Js,er);Js.prototype._check=function(e,t,n){var r=typeof e=="number"&&e%1===0&&vN(e);if(!r&&n)n(e,this);return r};Js.prototype._read=function(e){var t=e.readLong();if(!vN(t))throw Error("potential precision loss");return t};Js.prototype._skip=function(e){e.skipLong()};Js.prototype._write=function(e,t){if(typeof t!="number"||t%1||!vN(t))On(t,this);e.writeLong(t)};Js.prototype._match=function(e,t){return e.matchLong(t)};Js.prototype._update=function(e,t){switch(t.typeName){case"int":e._read=t._read;break;case"abstract:long":case"long":e._read=this._read}};Js.prototype.typeName="long";Js.prototype.random=function(){return li.nextInt()};Js.__with=function(e,t){e=e||{};var n={toBuffer:"_toBuffer",fromBuffer:"_fromBuffer",fromJSON:"_fromJSON",toJSON:"_toJSON",isValid:"_isValid",compare:"compare"},r=new Ni(t);return Object.keys(n).forEach(function(i){if(e[i]===void 0)throw Error(Lt("missing method implementation: %s",i));r[n[i]]=e[i]}),Object.freeze(r)};function Xa(){er.call(this)}ur.inherits(Xa,er);Xa.prototype._check=function(e,t,n){var r=typeof e=="number";if(!r&&n)n(e,this);return r};Xa.prototype._read=function(e){return e.readFloat()};Xa.prototype._skip=function(e){e.skipFloat()};Xa.prototype._write=function(e,t){if(typeof t!="number")On(t,this);e.writeFloat(t)};Xa.prototype._match=function(e,t){return e.matchFloat(t)};Xa.prototype._update=function(e,t){switch(t.typeName){case"float":case"int":e._read=t._read;break;case"abstract:long":case"long":e._read=function(n){return n.readLong()}}};Xa.prototype.typeName="float";Xa.prototype.random=function(){return li.nextFloat(1000)};function Za(){er.call(this)}ur.inherits(Za,er);Za.prototype._check=function(e,t,n){var r=typeof e=="number";if(!r&&n)n(e,this);return r};Za.prototype._read=function(e){return e.readDouble()};Za.prototype._skip=function(e){e.skipDouble()};Za.prototype._write=function(e,t){if(typeof t!="number")On(t,this);e.writeDouble(t)};Za.prototype._match=function(e,t){return e.matchDouble(t)};Za.prototype._update=function(e,t){switch(t.typeName){case"double":case"float":case"int":e._read=t._read;break;case"abstract:long":case"long":e._read=function(n){return n.readLong()}}};Za.prototype.typeName="double";Za.prototype.random=function(){return li.nextFloat()};function ga(){er.call(this)}ur.inherits(ga,er);ga.prototype._check=function(e,t,n){var r=typeof e=="string";if(!r&&n)n(e,this);return r};ga.prototype._read=function(e){return e.readString()};ga.prototype._skip=function(e){e.skipString()};ga.prototype._write=function(e,t){if(typeof t!="string")On(t,this);e.writeString(t)};ga.prototype._match=function(e,t){return e.matchString(t)};ga.prototype._update=function(e,t){switch(t.typeName){case"bytes":case"string":e._read=this._read}};ga.prototype.typeName="string";ga.prototype.random=function(){return li.nextString(li.nextInt(32))};function Gs(){er.call(this)}ur.inherits(Gs,er);Gs.prototype._check=function(e,t,n){var r=yu.isBuffer(e);if(!r&&n)n(e,this);return r};Gs.prototype._read=function(e){return e.readBytes()};Gs.prototype._skip=function(e){e.skipBytes()};Gs.prototype._write=function(e,t){if(!yu.isBuffer(t))On(t,this);e.writeBytes(t)};Gs.prototype._match=function(e,t){return e.matchBytes(t)};Gs.prototype._update=ga.prototype._update;Gs.prototype._copy=function(e,t){var n;switch((t&&t.coerce)|0){case 3:return this._check(e,void 0,On),e.toString("binary");case 2:if(typeof e!="string")throw Error(Lt("cannot coerce to buffer: %j",e));return n=bt.bufferFrom(e,"binary"),this._check(n,void 0,On),n;case 1:if(!g8(e))throw Error(Lt("cannot coerce to buffer: %j",e));return n=bt.bufferFrom(e.data),this._check(n,void 0,On),n;default:return this._check(e,void 0,On),bt.bufferFrom(e)}};Gs.prototype.compare=yu.compare;Gs.prototype.typeName="bytes";Gs.prototype.random=function(){return li.nextBuffer(li.nextInt(32))};function el(e,t){if(Ee.call(this),!Array.isArray(e))throw Error(Lt("non-array union schema: %j",e));if(!e.length)throw Error("empty union");this.types=Object.freeze(e.map(function(n){return Ee.forSchema(n,t)})),this._branchIndices={},this.types.forEach(function(n,r){if(Ee.isType(n,"union"))throw Error("unions cannot be directly nested");var i=n.branchName;if(this._branchIndices[i]!==void 0)throw Error(Lt("duplicate union branch name: %j",i));this._branchIndices[i]=r},this)}ur.inherits(el,Ee);el.prototype._branchConstructor=function(){throw Error("unions cannot be directly wrapped")};el.prototype._skip=function(e){this.types[e.readLong()]._skip(e)};el.prototype._match=function(e,t){var n=e.readLong(),r=t.readLong();if(n===r)return this.types[n]._match(e,t);else return n"u"}function S_e(e){return e instanceof Buffer}function oN(e){return Object.prototype.toString.call(e)}function tN(e){return e<10?"0"+e.toString(10):e.toString(10)}function k_e(){var e=new Date,t=[tN(e.getHours()),tN(e.getMinutes()),tN(e.getSeconds())].join(":");return[e.getDate(),E_e[e.getMonth()],t].join(" ")}function e8(...e){console.log("%s - %s",k_e(),iN.apply(null,e))}function t8(e,t){if(t)e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}function aN(e,t){if(!t||!om(t))return e;var n=Object.keys(t),r=n.length;while(r--)e[n[r]]=t[n[r]];return e}function n8(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function lN(e,t){if(!e){var n=Error("Promise was rejected with a falsy value");n.reason=e,e=n}return t(e)}function i8(e){if(typeof e!=="function")throw TypeError('The "original" argument must be of type Function');function t(...n){var r=n.pop();if(typeof r!=="function")throw TypeError("The last argument must be of type Function");var i=this,s=function(...o){return r.apply(i,...o)};e.apply(this,n).then(function(o){process.nextTick(s.bind(null,null,o))},function(o){process.nextTick(lN.bind(null,o,s))})}return Object.setPrototypeOf(t,Object.getPrototypeOf(e)),Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)),t}var d_e,m_e,Xp,x_e=()=>{},E_e,r8,s8,o8,N_e;var uN=q(()=>{d_e=/%[sdj%]/g;m_e=((e={},t={},n)=>((n=typeof process<"u"&&!1)&&(n=n.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase()),t=new RegExp("^"+n+"$","i"),(r)=>{if(r=r.toUpperCase(),!e[r])if(t.test(r))e[r]=function(...i){console.error("%s: %s",r,pid,iN.apply(null,...i))};else e[r]=function(){};return e[r]}))(),Xp=((e)=>(e.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},e.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},e.custom=Symbol.for("nodejs.util.inspect.custom"),e))(function(e,t,...n){var r={seen:[],stylize:h_e};if(n.length>=1)r.depth=n[0];if(n.length>=2)r.colors=n[1];if(sN(t))r.showHidden=t;else if(t)aN(r,t);if(sm(r.showHidden))r.showHidden=!1;if(sm(r.depth))r.depth=2;if(sm(r.colors))r.colors=!1;if(r.colors)r.stylize=y_e;return h0(r,e,r.depth)});E_e=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];r8=((e)=>(e.custom=Symbol.for("nodejs.util.promisify.custom"),e))(function(e){if(typeof e!=="function")throw TypeError('The "original" argument must be of type Function');if(kCustomPromisifiedSymbol&&e[kCustomPromisifiedSymbol]){var t=e[kCustomPromisifiedSymbol];if(typeof t!=="function")throw TypeError('The "nodejs.util.promisify.custom" argument must be of type Function');return Object.defineProperty(t,kCustomPromisifiedSymbol,{value:t,enumerable:!1,writable:!1,configurable:!0}),t}function t(...n){var r,i,s=new Promise(function(o,a){r=o,i=a});n.push(function(o,a){if(o)i(o);else r(a)});try{e.apply(this,n)}catch(o){i(o)}return s}if(Object.setPrototypeOf(t,Object.getPrototypeOf(e)),kCustomPromisifiedSymbol)Object.defineProperty(t,kCustomPromisifiedSymbol,{value:t,enumerable:!1,writable:!1,configurable:!0});return Object.defineProperties(t,Object.getOwnPropertyDescriptors(e))});({TextEncoder:s8,TextDecoder:o8}=globalThis),N_e={TextEncoder:s8,TextDecoder:o8,promisify:r8,log:e8,inherits:t8,_extend:aN,callbackifyOnRejected:lN,callbackify:i8}});var f8=z(function(xWe,d8){var a8=(p0(),Nf(u0)),O_e=YB(),l8=(uN(),Nf(cN)),Js=a8.Buffer,P_e=new dN(4096),$_e=/^[A-Za-z_][A-Za-z0-9_]*$/,I_e=l8.format;function ug(e){if(typeof Js.alloc=="function")return Js.alloc(e);else return new Js(e)}function A_e(e){if(typeof Js.allocUnsafeSlow=="function")return Js.allocUnsafeSlow(e);else return new a8.SlowBuffer(e)}function c8(e,t){if(typeof Js.from=="function")return Js.from(e,t);else return new Js(e,t)}function u8(e){return e.charAt(0).toUpperCase()+e.slice(1)}function R_e(e,t){return e===t?0:e=0)return-2;n=r}return n}function M_e(e,t){var n={},r,i;for(r=0;rt)return ug(e);if(this._pos+e>t)this._slab=ug(t),this._pos=0;return this._slab.slice(this._pos,this._pos+=e)};function Zp(e){var t=1103515245,n=12345,r=Math.pow(2,31),i=Math.floor(e||Math.random()*(r-1));this._max=r,this._nextInt=function(){return i=(t*i+n)%r}}Zp.prototype.nextBoolean=function(){return!!(this._nextInt()%2)};Zp.prototype.nextInt=function(e,t){if(t===void 0)t=e,e=0;return t=t===void 0?this._max:t,e+Math.floor(this.nextFloat()*(t-e))};Zp.prototype.nextFloat=function(e,t){if(t===void 0)t=e,e=0;return t=t===void 0?1:t,e+(t-e)*this._nextInt()/this._max};Zp.prototype.nextString=function(e,t){e|=0,t=t||"aA";var n="";if(t.indexOf("a")>-1)n+="abcdefghijklmnopqrstuvwxyz";if(t.indexOf("A")>-1)n+="ABCDEFGHIJKLMNOPQRSTUVWXYZ";if(t.indexOf("#")>-1)n+="0123456789";if(t.indexOf("!")>-1)n+="~`!@#$%^&*()_+-={}[]:\";'<>?,./|\\";var r=[];for(var i=0;i0&&t[n].index>1].index)e=t[n],t[n]=t[r],t[r]=e,n=r};fN.prototype.pop=function(){var e=this._items,t=e.length-1|0,n=e[0];if(!n||n.index>this._index)return null;if(this._index++,!t)return e.pop(),n;e[0]=e.pop();var r=t>>1,i=0,s,o,a,l,c,u,p;while(i=l.index)break;e[a]=l,e[i]=c,i=a}return n};function jt(e,t){if(this.buf=e,this.pos=t|0,this.pos<0)throw Error("negative offset")}jt.prototype.isValid=function(){return this.pos<=this.buf.length};jt.prototype._invalidate=function(){this.pos=this.buf.length+1};jt.prototype.readBoolean=function(){return!!this.buf[this.pos++]};jt.prototype.skipBoolean=function(){this.pos++};jt.prototype.writeBoolean=function(e){this.buf[this.pos++]=!!e};jt.prototype.readInt=jt.prototype.readLong=function(){var e=0,t=0,n=this.buf,r,i,s,o;do r=n[this.pos++],i=r&128,e|=(r&127)<>1^-(e&1)};jt.prototype.skipInt=jt.prototype.skipLong=function(){var e=this.buf;while(e[this.pos++]&128);};jt.prototype.writeInt=jt.prototype.writeLong=function(e){var t=this.buf,n,r;if(e>=-1073741824&&e<1073741824){r=e>=0?e<<1:~e<<1|1;do t[this.pos]=r&127,r>>=7;while(r&&(t[this.pos++]|=128))}else{n=e>=0?e*2:-e*2-1;do t[this.pos]=n&127,n/=128;while(n>=1&&(t[this.pos++]|=128))}this.pos++};jt.prototype.readFloat=function(){var e=this.buf,t=this.pos;if(this.pos+=4,this.pos>e.length)return 0;return this.buf.readFloatLE(t)};jt.prototype.skipFloat=function(){this.pos+=4};jt.prototype.writeFloat=function(e){var t=this.buf,n=this.pos;if(this.pos+=4,this.pos>t.length)return;return this.buf.writeFloatLE(e,n)};jt.prototype.readDouble=function(){var e=this.buf,t=this.pos;if(this.pos+=8,this.pos>e.length)return 0;return this.buf.readDoubleLE(t)};jt.prototype.skipDouble=function(){this.pos+=8};jt.prototype.writeDouble=function(e){var t=this.buf,n=this.pos;if(this.pos+=8,this.pos>t.length)return;return this.buf.writeDoubleLE(e,n)};jt.prototype.readFixed=function(e){var t=this.pos;if(this.pos+=e,this.pos>this.buf.length)return;var n=P_e.alloc(e);return this.buf.copy(n,0,t,t+e),n};jt.prototype.skipFixed=function(e){this.pos+=e};jt.prototype.writeFixed=function(e,t){t=t||e.length;var n=this.pos;if(this.pos+=t,this.pos>this.buf.length)return;e.copy(this.buf,n,0,t)};jt.prototype.readBytes=function(){var e=this.readLong();if(e<0){this._invalidate();return}return this.readFixed(e)};jt.prototype.skipBytes=function(){var e=this.readLong();if(e<0){this._invalidate();return}this.pos+=e};jt.prototype.writeBytes=function(e){var t=e.length;this.writeLong(t),this.writeFixed(e,t)};if(typeof Js.prototype.utf8Slice=="function")jt.prototype.readString=function(){var e=this.readLong();if(e<0)return this._invalidate(),"";var t=this.pos,n=this.buf;if(this.pos+=e,this.pos>n.length)return;return this.buf.utf8Slice(t,t+e)};else jt.prototype.readString=function(){var e=this.readLong();if(e<0)return this._invalidate(),"";var t=this.pos,n=this.buf;if(this.pos+=e,this.pos>n.length)return;return this.buf.slice(t,t+e).toString()};jt.prototype.skipString=function(){var e=this.readLong();if(e<0){this._invalidate();return}this.pos+=e};jt.prototype.writeString=function(e){var t=Js.byteLength(e),n=this.buf;this.writeLong(t);var r=this.pos;if(this.pos+=t,this.pos>n.length)return;if(t>64&&typeof Js.prototype.utf8Write=="function")n.utf8Write(e,r,t);else{var i,s,o,a;for(i=0,s=t;i>6|192,n[r++]=o&63|128;else if((o&64512)===55296&&((a=e.charCodeAt(i+1))&64512)===56320)o=65536+((o&1023)<<10)+(a&1023),i++,n[r++]=o>>18|240,n[r++]=o>>12&63|128,n[r++]=o>>6&63|128,n[r++]=o&63|128;else n[r++]=o>>12|224,n[r++]=o>>6&63|128,n[r++]=o&63|128}};if(typeof Js.prototype.latin1Write=="function")jt.prototype.writeBinary=function(e,t){var n=this.pos;if(this.pos+=t,this.pos>this.buf.length)return;this.buf.latin1Write(e,n,t)};else if(typeof Js.prototype.binaryWrite=="function")jt.prototype.writeBinary=function(e,t){var n=this.pos;if(this.pos+=t,this.pos>this.buf.length)return;this.buf.binaryWrite(e,n,t)};else jt.prototype.writeBinary=function(e,t){var n=this.pos;if(this.pos+=t,this.pos>this.buf.length)return;this.buf.write(e,n,t,"binary")};jt.prototype.matchBoolean=function(e){return this.buf[this.pos++]-e.buf[e.pos++]};jt.prototype.matchInt=jt.prototype.matchLong=function(e){var t=this.readLong(),n=e.readLong();return t===n?0:t>1;while(s&128)if(s=i[this.pos++],t|=(s&127)<=8)r-=8,e[n++]=t,t>>=8;if(e[n]=t,o)pN(e,8);return e};jt.prototype.packLongBytes=function(e){var t=(e[7]&128)>>7,n=this.buf,r=1,i=0,s=3,o;if(t)pN(e,8),o=1;else o=0;var a=[e.readUIntLE(0,3),e.readUIntLE(3,3),e.readUIntLE(6,2)];while(s&&!a[--s]);while(i7)n[this.pos++]=o&127|128,o>>=7,r-=7}o|=a[s]<>=7;while(o&&(n[this.pos++]|=128));if(this.pos++,t)pN(e,8)};function pN(e,t){while(t--)e[t]=~e[t]}d8.exports={abstractFunction:G_e,addDeprecatedGetters:H_e,bufferFrom:c8,capitalize:u8,copyOwnProperties:U_e,getHash:F_e,compare:R_e,getOption:j_e,impliedNamespace:K_e,isValidName:p8,jsonEnd:J_e,newBuffer:ug,newSlowBuffer:A_e,objectValues:L_e,qualify:B_e,toMap:M_e,singleIndexOf:C_e,hasDuplicates:q_e,unqualify:V_e,BufferPool:dN,Lcg:Zp,OrderedQueue:fN,Tap:jt}});var _8=z(function(wWe,v8){var vt=f8(),z_e=(p0(),Nf(u0)),ur=(uN(),Nf(cN)),hu=z_e.Buffer,td=vt.Tap,mN=ur.debuglog("avsc:types"),Lt=ur.format,v0={array:_s,boolean:Hl,bytes:Hs,double:Za,enum:bs,error:cr,fixed:vs,float:Xa,int:zl,long:Gs,map:zi,null:Do,record:cr,string:ga},ci=new vt.Lcg,ed=new td(vt.newSlowBuffer(1024)),ha=null,am=[];function Ee(e,t){var n;if(ha)n=ha,am.push([ha,this]),ha=null;else n=this;if(this._hash=new W_e,this.name=void 0,this.aliases=void 0,this.doc=e&&e.doc?""+e.doc:void 0,e){var r=e.name,i=e.namespace===void 0?t&&t.namespace:e.namespace;if(r!==void 0){if(r=hN(r,i),lm(r))throw Error(Lt("cannot rename primitive type: %j",r));var s=t&&t.registry;if(s){if(s[r]!==void 0)throw Error(Lt("duplicate type name: %s",r));s[r]=n}}else if(t&&t.noAnonymousTypes)throw Error(Lt("missing name property in schema: %j",e));this.name=r,this.aliases=e.aliases?e.aliases.map(function(o){return hN(o,i)}):[]}}Ee.forSchema=function(e,t){t=t||{},t.registry=t.registry||{};var n=function(c){if(c===!0)c="always";else if(c===!1)c="never";else if(c===void 0)c="auto";else if(typeof c=="string")c=c.toLowerCase();switch(c){case"always":return To;case"never":return gs;case"auto":return;default:throw Error(Lt("invalid wrap unions option: %j",c))}}(t.wrapUnions);if(e===null)throw Error('invalid type: null (did you mean "null"?)');if(Ee.isType(e))return e;var r;if(t.typeHook&&(r=t.typeHook(e,t))){if(!Ee.isType(r))throw Error(Lt("invalid typehook return value: %j",r));return r}if(typeof e=="string"){if(e=hN(e,t.namespace),r=t.registry[e],r)return r;if(lm(e))return t.registry[e]=Ee.forSchema({type:e},t);throw Error(Lt("undefined type name: %s",e))}if(e.logicalType&&t.logicalTypes&&!ha){var i=t.logicalTypes[e.logicalType];if(i){var s=t.namespace,o={};Object.keys(t.registry).forEach(function(c){o[c]=t.registry[c]});try{return mN("instantiating logical type for %s",e.logicalType),new i(e,t)}catch(c){if(mN("failed to instantiate logical type for %s",e.logicalType),t.assertLogicalTypes)throw c;ha=null,t.namespace=s,t.registry=o}}}if(Array.isArray(e)){var a=ha;ha=null;var l=e.map(function(c){return Ee.forSchema(c,t)});if(!n)n=Q_e(l)?To:gs;ha=a,r=new n(l,t)}else r=function(c){var u=v0[c];if(u===void 0)throw Error(Lt("unknown type: %j",c));return new u(e,t)}(e.type);return r};Ee.forValue=function(e,t){if(t=t||{},t.emptyArrayType=t.emptyArrayType||Ee.forSchema({type:"array",items:"null"}),t.valueHook){var n=t.valueHook(e,t);if(n!==void 0){if(!Ee.isType(n))throw Error(Lt("invalid value hook return value: %j",n));return n}}switch(typeof e){case"string":return Ee.forSchema("string",t);case"boolean":return Ee.forSchema("boolean",t);case"number":if((e|0)===e)return Ee.forSchema("int",t);else if(Math.abs(e)<9007199254740991)return Ee.forSchema("float",t);return Ee.forSchema("double",t);case"object":if(e===null)return Ee.forSchema("null",t);else if(Array.isArray(e)){if(!e.length)return t.emptyArrayType;return Ee.forSchema({type:"array",items:Ee.forTypes(e.map(function(i){return Ee.forValue(i,t)}),t)},t)}else if(hu.isBuffer(e))return Ee.forSchema("bytes",t);var r=Object.keys(e);if(r.some(function(i){return!vt.isValidName(i)}))return Ee.forSchema({type:"map",values:Ee.forTypes(r.map(function(i){return Ee.forValue(e[i],t)}),t)},t);return Ee.forSchema({type:"record",fields:r.map(function(i){return{name:i,type:Ee.forValue(e[i],t)}})},t);default:throw Error(Lt("cannot infer type from: %j",e))}};Ee.forTypes=function(e,t){if(!e.length)throw Error("no types to combine");if(e.length===1)return e[0];t=t||{};var n=[],r=0,i=!0;if(e.forEach(function(p){switch(p.typeName){case"union:unwrapped":i=!1,n=n.concat(p.types);break;case"union:wrapped":r++,n=n.concat(p.types);break;case"null":n.push(p);break;default:i=!1,n.push(p)}}),r){if(!i)throw Error("cannot combine wrapped union");var s={};n.forEach(function(p){var d=p.branchName,f=s[d];if(!f)s[d]=p;else if(!p.equals(f))throw Error("inconsistent branch type")});var o=t.wrapUnions,a;t.wrapUnions=!0;try{a=Ee.forSchema(Object.keys(s).map(function(p){return s[p]}),t)}catch(p){throw t.wrapUnions=o,p}return t.wrapUnions=o,a}var l={};n.forEach(function(p){var d=_0(p),f=l[d];if(!f)l[d]=f=[];f.push(p)});var c=Object.keys(l),u=c.map(function(p){var d=l[p];if(d.length===1)return d[0];else switch(p){case"null":case"boolean":return d[0];case"number":return Y_e(d);case"string":return X_e(d,t);case"buffer":return Z_e(d,t);case"array":if(d=d.filter(function(f){return f!==t.emptyArrayType}),!d.length)return t.emptyArrayType;return Ee.forSchema({type:"array",items:Ee.forTypes(d.map(function(f){return f.itemsType}),t)},t);default:return exe(d,t)}});if(u.length===1)return u[0];else return Ee.forSchema(u,t)};Ee.isType=function(){var e=arguments.length;if(!e)return!1;var t=arguments[0];if(!t||typeof t._update!="function"||typeof t.fingerprint!="function")return!1;if(e===1)return!0;var n=t.typeName,r;for(r=1;r",t);else{var n=this.schema({exportAttrs:!0,noDeref:!0});if(typeof n=="object"&&!Ee.isType(this,"logical"))n.type=void 0;return Lt("<%s %j>",t,n)}};Ee.prototype.isValid=function(e,t){var n=(t&&t.noUndeclaredFields)|0,r=t&&t.errorHook,i,s;if(r)s=[],i=function(o,a){r.call(this,s.slice(),o,a,e)};return this._check(e,n,i,s)};Ee.prototype.random=vt.abstractFunction;Ee.prototype.schema=function(e){return this._attrs({exportAttrs:!!(e&&e.exportAttrs),noDeref:!!(e&&e.noDeref)})};Ee.prototype.toBuffer=function(e){ed.pos=0,this._write(ed,e);var t=vt.newBuffer(ed.pos);if(ed.isValid())ed.buf.copy(t,0,0,ed.pos);else this._write(new td(t),e);return t};Ee.prototype.toJSON=function(){return this.schema({exportAttrs:!0})};Ee.prototype.toString=function(e){if(e===void 0)return JSON.stringify(this.schema({noDeref:!0}));return JSON.stringify(this._copy(e,{coerce:3}))};Ee.prototype.wrap=function(e){var t=this._branchConstructor;return t===null?null:new t(e)};Ee.prototype._attrs=function(e){e.derefed=e.derefed||{};var t=this.name;if(t!==void 0){if(e.noDeref||e.derefed[t])return t;e.derefed[t]=!0}var n={};if(this.name!==void 0)n.name=t;n.type=this.typeName;var r=this._deref(n,e);if(r!==void 0)n=r;if(e.exportAttrs){if(this.aliases&&this.aliases.length)n.aliases=this.aliases;if(this.doc!==void 0)n.doc=this.doc}return n};Ee.prototype._createBranchConstructor=function(){var e=this.branchName;if(e==="null")return null;var t=~e.indexOf(".")?"this['"+e+"']":"this."+e,n="return function Branch$(val) { "+t+" = val; };",r=Function(n)();return r.type=this,r.prototype.unwrap=Function("return "+t+";"),r.prototype.unwrapped=r.prototype.unwrap,r};Ee.prototype._peek=function(e){var t=e.pos,n=this._read(e);return e.pos=t,n};Ee.prototype._check=vt.abstractFunction;Ee.prototype._copy=vt.abstractFunction;Ee.prototype._deref=vt.abstractFunction;Ee.prototype._match=vt.abstractFunction;Ee.prototype._read=vt.abstractFunction;Ee.prototype._skip=vt.abstractFunction;Ee.prototype._update=vt.abstractFunction;Ee.prototype._write=vt.abstractFunction;Ee.prototype.getAliases=function(){return this.aliases};Ee.prototype.getFingerprint=Ee.prototype.fingerprint;Ee.prototype.getName=function(e){return this.name||!e?this.name:this.branchName};Ee.prototype.getSchema=Ee.prototype.schema;Ee.prototype.getTypeName=function(){return this.typeName};function er(e){if(Ee.call(this),this._branchConstructor=this._createBranchConstructor(),!e)Object.freeze(this)}ur.inherits(er,Ee);er.prototype._update=function(e,t){if(t.typeName===this.typeName)e._read=this._read};er.prototype._copy=function(e){return this._check(e,void 0,On),e};er.prototype._deref=function(){return this.typeName};er.prototype.compare=vt.compare;function Do(){er.call(this)}ur.inherits(Do,er);Do.prototype._check=function(e,t,n){var r=e===null;if(!r&&n)n(e,this);return r};Do.prototype._read=function(){return null};Do.prototype._skip=function(){};Do.prototype._write=function(e,t){if(t!==null)On(t,this)};Do.prototype._match=function(){return 0};Do.prototype.compare=Do.prototype._match;Do.prototype.typeName="null";Do.prototype.random=Do.prototype._read;function Hl(){er.call(this)}ur.inherits(Hl,er);Hl.prototype._check=function(e,t,n){var r=typeof e=="boolean";if(!r&&n)n(e,this);return r};Hl.prototype._read=function(e){return e.readBoolean()};Hl.prototype._skip=function(e){e.skipBoolean()};Hl.prototype._write=function(e,t){if(typeof t!="boolean")On(t,this);e.writeBoolean(t)};Hl.prototype._match=function(e,t){return e.matchBoolean(t)};Hl.prototype.typeName="boolean";Hl.prototype.random=function(){return ci.nextBoolean()};function zl(){er.call(this)}ur.inherits(zl,er);zl.prototype._check=function(e,t,n){var r=e===(e|0);if(!r&&n)n(e,this);return r};zl.prototype._read=function(e){return e.readInt()};zl.prototype._skip=function(e){e.skipInt()};zl.prototype._write=function(e,t){if(t!==(t|0))On(t,this);e.writeInt(t)};zl.prototype._match=function(e,t){return e.matchInt(t)};zl.prototype.typeName="int";zl.prototype.random=function(){return ci.nextInt(1000)|0};function Gs(){er.call(this)}ur.inherits(Gs,er);Gs.prototype._check=function(e,t,n){var r=typeof e=="number"&&e%1===0&&vN(e);if(!r&&n)n(e,this);return r};Gs.prototype._read=function(e){var t=e.readLong();if(!vN(t))throw Error("potential precision loss");return t};Gs.prototype._skip=function(e){e.skipLong()};Gs.prototype._write=function(e,t){if(typeof t!="number"||t%1||!vN(t))On(t,this);e.writeLong(t)};Gs.prototype._match=function(e,t){return e.matchLong(t)};Gs.prototype._update=function(e,t){switch(t.typeName){case"int":e._read=t._read;break;case"abstract:long":case"long":e._read=this._read}};Gs.prototype.typeName="long";Gs.prototype.random=function(){return ci.nextInt()};Gs.__with=function(e,t){e=e||{};var n={toBuffer:"_toBuffer",fromBuffer:"_fromBuffer",fromJSON:"_fromJSON",toJSON:"_toJSON",isValid:"_isValid",compare:"compare"},r=new Ni(t);return Object.keys(n).forEach(function(i){if(e[i]===void 0)throw Error(Lt("missing method implementation: %s",i));r[n[i]]=e[i]}),Object.freeze(r)};function Xa(){er.call(this)}ur.inherits(Xa,er);Xa.prototype._check=function(e,t,n){var r=typeof e=="number";if(!r&&n)n(e,this);return r};Xa.prototype._read=function(e){return e.readFloat()};Xa.prototype._skip=function(e){e.skipFloat()};Xa.prototype._write=function(e,t){if(typeof t!="number")On(t,this);e.writeFloat(t)};Xa.prototype._match=function(e,t){return e.matchFloat(t)};Xa.prototype._update=function(e,t){switch(t.typeName){case"float":case"int":e._read=t._read;break;case"abstract:long":case"long":e._read=function(n){return n.readLong()}}};Xa.prototype.typeName="float";Xa.prototype.random=function(){return ci.nextFloat(1000)};function Za(){er.call(this)}ur.inherits(Za,er);Za.prototype._check=function(e,t,n){var r=typeof e=="number";if(!r&&n)n(e,this);return r};Za.prototype._read=function(e){return e.readDouble()};Za.prototype._skip=function(e){e.skipDouble()};Za.prototype._write=function(e,t){if(typeof t!="number")On(t,this);e.writeDouble(t)};Za.prototype._match=function(e,t){return e.matchDouble(t)};Za.prototype._update=function(e,t){switch(t.typeName){case"double":case"float":case"int":e._read=t._read;break;case"abstract:long":case"long":e._read=function(n){return n.readLong()}}};Za.prototype.typeName="double";Za.prototype.random=function(){return ci.nextFloat()};function ga(){er.call(this)}ur.inherits(ga,er);ga.prototype._check=function(e,t,n){var r=typeof e=="string";if(!r&&n)n(e,this);return r};ga.prototype._read=function(e){return e.readString()};ga.prototype._skip=function(e){e.skipString()};ga.prototype._write=function(e,t){if(typeof t!="string")On(t,this);e.writeString(t)};ga.prototype._match=function(e,t){return e.matchString(t)};ga.prototype._update=function(e,t){switch(t.typeName){case"bytes":case"string":e._read=this._read}};ga.prototype.typeName="string";ga.prototype.random=function(){return ci.nextString(ci.nextInt(32))};function Hs(){er.call(this)}ur.inherits(Hs,er);Hs.prototype._check=function(e,t,n){var r=hu.isBuffer(e);if(!r&&n)n(e,this);return r};Hs.prototype._read=function(e){return e.readBytes()};Hs.prototype._skip=function(e){e.skipBytes()};Hs.prototype._write=function(e,t){if(!hu.isBuffer(t))On(t,this);e.writeBytes(t)};Hs.prototype._match=function(e,t){return e.matchBytes(t)};Hs.prototype._update=ga.prototype._update;Hs.prototype._copy=function(e,t){var n;switch((t&&t.coerce)|0){case 3:return this._check(e,void 0,On),e.toString("binary");case 2:if(typeof e!="string")throw Error(Lt("cannot coerce to buffer: %j",e));return n=vt.bufferFrom(e,"binary"),this._check(n,void 0,On),n;case 1:if(!g8(e))throw Error(Lt("cannot coerce to buffer: %j",e));return n=vt.bufferFrom(e.data),this._check(n,void 0,On),n;default:return this._check(e,void 0,On),vt.bufferFrom(e)}};Hs.prototype.compare=hu.compare;Hs.prototype.typeName="bytes";Hs.prototype.random=function(){return ci.nextBuffer(ci.nextInt(32))};function el(e,t){if(Ee.call(this),!Array.isArray(e))throw Error(Lt("non-array union schema: %j",e));if(!e.length)throw Error("empty union");this.types=Object.freeze(e.map(function(n){return Ee.forSchema(n,t)})),this._branchIndices={},this.types.forEach(function(n,r){if(Ee.isType(n,"union"))throw Error("unions cannot be directly nested");var i=n.branchName;if(this._branchIndices[i]!==void 0)throw Error(Lt("duplicate union branch name: %j",i));this._branchIndices[i]=r},this)}ur.inherits(el,Ee);el.prototype._branchConstructor=function(){throw Error("unions cannot be directly wrapped")};el.prototype._skip=function(e){this.types[e.readLong()]._skip(e)};el.prototype._match=function(e,t){var n=e.readLong(),r=t.readLong();if(n===r)return this.types[n]._match(e,t);else return n1)throw Error(Lt("ambiguous aliasing for %s.%s (%s)",t.name,u.name,f));if(!f.length){if(u.defaultValue()===void 0)throw Error(Lt("no matching field for default-less %s.%s",t.name,u.name));o.push("undefined")}else{if(p=f[0],m={resolver:u.type.createResolver(s[p].type,n),name:"_"+u.name},!a[p])a[p]=[m];else a[p].push(m);o.push(m.name)}}var y=-1;l=i.length;while(l&&a[i[--l].name]===void 0)y=l;var h=this._getConstructorName(),b=[h],g=[this.recordConstructor],x=" return function read"+h+`(t, b) { +`;return n+="}",Function(e.join(),n).apply(void 0,r)};cr.prototype._update=function(e,t,n){if(!bN(this,t,!n.ignoreNamespaces))throw Error(Lt("no alias found for %s",t.name));var r=this.fields,i=t.fields,s=vt.toMap(i,function(v){return v.name}),o=[],a={},l,c,u,p,d,f,m;for(l=0;l1)throw Error(Lt("ambiguous aliasing for %s.%s (%s)",t.name,u.name,f));if(!f.length){if(u.defaultValue()===void 0)throw Error(Lt("no matching field for default-less %s.%s",t.name,u.name));o.push("undefined")}else{if(p=f[0],m={resolver:u.type.createResolver(s[p].type,n),name:"_"+u.name},!a[p])a[p]=[m];else a[p].push(m);o.push(m.name)}}var y=-1;l=i.length;while(l&&a[i[--l].name]===void 0)y=l;var h=this._getConstructorName(),b=[h],g=[this.recordConstructor],x=" return function read"+h+`(t, b) { `;for(l=0;l=y?" ":" ",b.push("r"+l),g.push(u.type),x+="r"+l+`._skip(t); `;else{c=a[p].length;while(c--)x+=~y&&l>=y?" ":" ",b.push("r"+l+"f"+c),m=a[p][c],g.push(m.resolver),x+="var "+m.name+" = ",x+="r"+l+"f"+c+"._"+(c?"peek":"read")+`(t); `}}if(~y)x+=` } `;x+=" return new "+h+"("+o.join()+`); -};`,e._read=Function(b.join(),x).apply(void 0,g)};cr.prototype._match=function(e,t){var n=this.fields,r,i,s,o,a;for(r=0,i=n.length;r"};function z_e(){this.str=void 0}function m8(e,t,n,r){if(n){if(n._readerType!==e)throw Error("invalid resolver");return n._read(t,r)}else return e._read(t)}function y8(e){var t={};if(e.name)t[e.name]=!0;var n=e.aliases,r,i;for(r=0,i=n.length;r=-9007199254740990&&e<=9007199254740990}function g8(e){return e&&e.type==="Buffer"&&Array.isArray(e.data)}function On(e,t){throw Error(Lt("invalid %j: %j",t.schema(),e))}function hN(e,t){var n=bt.unqualify(e);return om(n)?n:bt.qualify(e,t)}function _0(e){var t=e.typeName;switch(t){case"double":case"float":case"int":case"long":return"number";case"bytes":case"fixed":return"buffer";case"enum":return"string";case"map":case"error":case"record":return"object";default:return t}}function b8(e){if(e===null)return"null";var t=typeof e;if(t==="object"){if(Array.isArray(e))return"array";else if(yu.isBuffer(e))return"buffer"}return t}function W_e(e){var t={},n,r,i,s;for(n=0,r=e.length;nn)n=a,r=o;return r}function Y_e(e,t){var n={},r,i,s,o;for(r=0,i=e.length;r0){var O=D[0];D[0]=D[T],D[T]=O,x=Ee.forSchema(D,t)}}return{name:g,type:x,default:i[g]}})};else b={type:"map",values:Ee.forTypes(n,t)};return Ee.forSchema(b,t)}v8.exports={Type:Ee,getTypeBucket:_0,getValueBucket:b8,isPrimitive:om,builtins:function(){var e={LogicalType:zr,UnwrappedUnionType:hs,WrappedUnionType:To},t=Object.keys(v0),n,r,i;for(n=0,r=t.length;n=",ok:Ru.GTE,fail:Ru.LT},{okStr:">",ok:Ru.GT,fail:Ru.LTE}]}},rwe={message:(e)=>kO.str`must be ${EO(e).okStr} ${e.schemaCode}`,params:(e)=>kO._`{comparison: ${EO(e).okStr}, limit: ${e.schemaCode}}`},iwe={keyword:Object.keys(SO),type:"number",schemaType:"number",$data:!0,error:rwe,code(e){let{data:t,schemaCode:n}=e;e.fail$data(kO._`${t} ${EO(e).fail} ${n} || isNaN(${t})`)}};function EO(e){var t;let n=e.keyword,r=((t=e.parentSchema)===null||t===void 0?void 0:t[SO[n].exclusive])?1:0;return SO[n].ops[r]}i4.default=iwe});var l4=z(function(a4){Object.defineProperty(a4,"__esModule",{value:!0});var o4={exclusiveMaximum:"maximum",exclusiveMinimum:"minimum"},owe={keyword:Object.keys(o4),type:"number",schemaType:"boolean",code({keyword:e,parentSchema:t}){let n=o4[e];if(t[n]===void 0)throw Error(`${e} can only be used with ${n}`)}};a4.default=owe});var u4=z(function(c4){Object.defineProperty(c4,"__esModule",{value:!0});var lwe=s4(),cwe=l4(),uwe=c1(),pwe=u1(),dwe=p1(),fwe=d1(),mwe=f1(),ywe=m1(),hwe=h1(),gwe=b1(),bwe=v1(),vwe=[lwe.default,cwe.default,uwe.default,pwe.default,dwe.default,fwe.default,mwe.default,ywe.default,hwe.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},gwe.default,bwe.default];c4.default=vwe});var d4=z(function(p4){Object.defineProperty(p4,"__esModule",{value:!0});var xwe=r4(),wwe=u4(),Dwe=Zx(),Twe=e0(),Swe=["title","description","default"],Ewe=[xwe.default,wwe.default,Dwe.default(),Twe.default,Swe];p4.default=Ewe});var f4=z(function(oot,Nwe){Nwe.exports={id:"http://json-schema.org/draft-04/schema#",$schema:"http://json-schema.org/draft-04/schema#",description:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},positiveInteger:{type:"integer",minimum:0},positiveIntegerDefault0:{allOf:[{$ref:"#/definitions/positiveInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0}},type:"object",properties:{id:{type:"string",format:"uri"},$schema:{type:"string",format:"uri"},title:{type:"string"},description:{type:"string"},default:{},multipleOf:{type:"number",minimum:0,exclusiveMinimum:!0},maximum:{type:"number"},exclusiveMaximum:{type:"boolean",default:!1},minimum:{type:"number"},exclusiveMinimum:{type:"boolean",default:!1},maxLength:{$ref:"#/definitions/positiveInteger"},minLength:{$ref:"#/definitions/positiveIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{anyOf:[{type:"boolean"},{$ref:"#"}],default:{}},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:{}},maxItems:{$ref:"#/definitions/positiveInteger"},minItems:{$ref:"#/definitions/positiveIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},maxProperties:{$ref:"#/definitions/positiveInteger"},minProperties:{$ref:"#/definitions/positiveIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{anyOf:[{type:"boolean"},{$ref:"#"}],default:{}},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},enum:{type:"array",minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},dependencies:{exclusiveMaximum:["maximum"],exclusiveMinimum:["minimum"]},default:{}}});var h4=z(function(jo,y4){Object.defineProperty(jo,"__esModule",{value:!0});jo.CodeGen=jo.Name=jo.nil=jo.stringify=jo.str=jo._=jo.KeywordCxt=void 0;var Owe=lu(),Pwe=d4(),$we=ig(),m4=f4(),Iwe=["/properties"],sw="http://json-schema.org/draft-04/schema";class NO extends Owe.default{constructor(e={}){super({...e,schemaId:"id"})}_addVocabularies(){if(super._addVocabularies(),Pwe.default.forEach((e)=>this.addVocabulary(e)),this.opts.discriminator)this.addKeyword($we.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let e=this.opts.$data?this.$dataMetaSchema(m4,Iwe):m4;this.addMetaSchema(e,sw,!1),this.refs["http://json-schema.org/schema"]=sw}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(sw)?sw:void 0)}}y4.exports=jo=NO;Object.defineProperty(jo,"__esModule",{value:!0});jo.default=NO;var Awe=lu();Object.defineProperty(jo,"KeywordCxt",{enumerable:!0,get:function(){return Awe.KeywordCxt}});var xm=lu();Object.defineProperty(jo,"_",{enumerable:!0,get:function(){return xm._}});Object.defineProperty(jo,"str",{enumerable:!0,get:function(){return xm.str}});Object.defineProperty(jo,"stringify",{enumerable:!0,get:function(){return xm.stringify}});Object.defineProperty(jo,"nil",{enumerable:!0,get:function(){return xm.nil}});Object.defineProperty(jo,"Name",{enumerable:!0,get:function(){return xm.Name}});Object.defineProperty(jo,"CodeGen",{enumerable:!0,get:function(){return xm.CodeGen}})});function Kg(e){return IDe(e)!==0}function f9(e){return e>=Qr.a&&e<=Qr.z||e>=Qr.A&&e<=Qr.Z}function $De(e,t){let n=e.charCodeAt(t);if(n===Qr.colon)return t+1;if(n===Qr.percent&&e.charCodeAt(t+1)===Qr._3){let r=e.charCodeAt(t+2);if(r===Qr.a||r===Qr.A)return t+3}return-1}function IDe(e){if(!e)return 0;let t=e.charCodeAt(0);if(t===Qr.slash||t===Qr.backslash){if(e.charCodeAt(1)!==t)return 1;let r=e.indexOf(t===Qr.slash?"/":"\\",2);if(r<0)return e.length;return r+1}if(f9(t)&&e.charCodeAt(1)===Qr.colon){let r=e.charCodeAt(2);if(r===Qr.slash||r===Qr.backslash)return 3;if(e.length===2)return 2}let n=e.indexOf("://");if(n!==-1){let r=n+3,i=e.indexOf("/",r);if(i!==-1){let s=e.slice(0,n),o=e.slice(r,i);if(s==="file"&&(o===""||o==="localhost")&&f9(e.charCodeAt(i+1))){let a=$De(e,i+2);if(a!==-1){if(e.charCodeAt(a)===Qr.slash)return~(a+1);if(a===e.length)return~a}}return~(i+1)}return~e.length}return 0}var Qr;var mn=q(()=>{(function(e){e[e.nullCharacter=0]="nullCharacter",e[e.maxAsciiCharacter=127]="maxAsciiCharacter",e[e.lineFeed=10]="lineFeed",e[e.carriageReturn=13]="carriageReturn",e[e.lineSeparator=8232]="lineSeparator",e[e.paragraphSeparator=8233]="paragraphSeparator",e[e.nextLine=133]="nextLine",e[e.space=32]="space",e[e.nonBreakingSpace=160]="nonBreakingSpace",e[e.enQuad=8192]="enQuad",e[e.emQuad=8193]="emQuad",e[e.enSpace=8194]="enSpace",e[e.emSpace=8195]="emSpace",e[e.threePerEmSpace=8196]="threePerEmSpace",e[e.fourPerEmSpace=8197]="fourPerEmSpace",e[e.sixPerEmSpace=8198]="sixPerEmSpace",e[e.figureSpace=8199]="figureSpace",e[e.punctuationSpace=8200]="punctuationSpace",e[e.thinSpace=8201]="thinSpace",e[e.hairSpace=8202]="hairSpace",e[e.zeroWidthSpace=8203]="zeroWidthSpace",e[e.narrowNoBreakSpace=8239]="narrowNoBreakSpace",e[e.ideographicSpace=12288]="ideographicSpace",e[e.mathematicalSpace=8287]="mathematicalSpace",e[e.ogham=5760]="ogham",e[e._=95]="_",e[e.$=36]="$",e[e._0=48]="_0",e[e._1=49]="_1",e[e._2=50]="_2",e[e._3=51]="_3",e[e._4=52]="_4",e[e._5=53]="_5",e[e._6=54]="_6",e[e._7=55]="_7",e[e._8=56]="_8",e[e._9=57]="_9",e[e.a=97]="a",e[e.b=98]="b",e[e.c=99]="c",e[e.d=100]="d",e[e.e=101]="e",e[e.f=102]="f",e[e.g=103]="g",e[e.h=104]="h",e[e.i=105]="i",e[e.j=106]="j",e[e.k=107]="k",e[e.l=108]="l",e[e.m=109]="m",e[e.n=110]="n",e[e.o=111]="o",e[e.p=112]="p",e[e.q=113]="q",e[e.r=114]="r",e[e.s=115]="s",e[e.t=116]="t",e[e.u=117]="u",e[e.v=118]="v",e[e.w=119]="w",e[e.x=120]="x",e[e.y=121]="y",e[e.z=122]="z",e[e.A=65]="A",e[e.B=66]="B",e[e.C=67]="C",e[e.D=68]="D",e[e.E=69]="E",e[e.F=70]="F",e[e.G=71]="G",e[e.H=72]="H",e[e.I=73]="I",e[e.J=74]="J",e[e.K=75]="K",e[e.L=76]="L",e[e.M=77]="M",e[e.N=78]="N",e[e.O=79]="O",e[e.P=80]="P",e[e.Q=81]="Q",e[e.R=82]="R",e[e.S=83]="S",e[e.T=84]="T",e[e.U=85]="U",e[e.V=86]="V",e[e.W=87]="W",e[e.X=88]="X",e[e.Y=89]="Y",e[e.Z=90]="Z",e[e.ampersand=38]="ampersand",e[e.asterisk=42]="asterisk",e[e.at=64]="at",e[e.backslash=92]="backslash",e[e.backtick=96]="backtick",e[e.bar=124]="bar",e[e.caret=94]="caret",e[e.closeBrace=125]="closeBrace",e[e.closeBracket=93]="closeBracket",e[e.closeParen=41]="closeParen",e[e.colon=58]="colon",e[e.comma=44]="comma",e[e.dot=46]="dot",e[e.doubleQuote=34]="doubleQuote",e[e.equals=61]="equals",e[e.exclamation=33]="exclamation",e[e.greaterThan=62]="greaterThan",e[e.hash=35]="hash",e[e.lessThan=60]="lessThan",e[e.minus=45]="minus",e[e.openBrace=123]="openBrace",e[e.openBracket=91]="openBracket",e[e.openParen=40]="openParen",e[e.percent=37]="percent",e[e.plus=43]="plus",e[e.question=63]="question",e[e.semicolon=59]="semicolon",e[e.singleQuote=39]="singleQuote",e[e.slash=47]="slash",e[e.tilde=126]="tilde",e[e.backspace=8]="backspace",e[e.formFeed=12]="formFeed",e[e.byteOrderMark=65279]="byteOrderMark",e[e.tab=9]="tab",e[e.verticalTab=11]="verticalTab"})(Qr||(Qr={}))});function pw(e){if(Array.isArray(e))e.forEach(pw);else if(typeof e==="object")for(let t in e)pw(e[t]);return Object.freeze(e)}function wm(e){return Array.isArray(e)}function Ed(e){return e!==void 0}function Tn(e){return e}function il(e){return new m9(e)}function y9(e,t){if(typeof process<"u")return process?.env?.[e]??t;return t}var m9;var Gt=q(()=>{mn();m9=class m9{#e=new Map;#t=new Map;constructor(e){if(e)for(let[t,n]of e)this.set(t,n)}clear(){this.#e.clear(),this.#t.clear()}delete(e){let t=this.#e.get(e);if(t)return this.#e.delete(e),this.#t.delete(t);return!1}forEach(e,t){this.#t.forEach((n,r)=>{e(n,r.key,this)},t)}get(e){let t=this.#e.get(e);return t?this.#t.get(t):void 0}has(e){return this.#e.has(e)}set(e,t){let n=this.#e.get(e);if(!n)n={key:e},this.#e.set(e,n);return this.#t.set(n,t),this}get size(){return this.#t.size}*entries(){for(let[e,t]of this.#t)yield[e.key,t]}*keys(){for(let e of this.#t.keys())yield e.key}values(){return this.#t.values()}[Symbol.iterator](){return this.entries()}[Symbol.toStringTag]="RekeyableMap";rekey(e,t){let n=this.#e.get(e);if(!n)return!1;this.#e.delete(e);let r=this.#e.get(t);if(r)this.#t.delete(r);return n.key=t,this.#e.set(t,n),!0}}});function dw(e,t){let n=t?`It must match one of the code defined in the library '${t}'`:"It must match one of the code defined in the compiler.";function r(s){let o=e[s.code];if(!o){let u=Object.keys(e).map((d)=>` - ${d}`).join(` +};`,e._read=Function(b.join(),x).apply(void 0,g)};cr.prototype._match=function(e,t){var n=this.fields,r,i,s,o,a;for(r=0,i=n.length;r"};function W_e(){this.str=void 0}function m8(e,t,n,r){if(n){if(n._readerType!==e)throw Error("invalid resolver");return n._read(t,r)}else return e._read(t)}function y8(e){var t={};if(e.name)t[e.name]=!0;var n=e.aliases,r,i;for(r=0,i=n.length;r=-9007199254740990&&e<=9007199254740990}function g8(e){return e&&e.type==="Buffer"&&Array.isArray(e.data)}function On(e,t){throw Error(Lt("invalid %j: %j",t.schema(),e))}function hN(e,t){var n=vt.unqualify(e);return lm(n)?n:vt.qualify(e,t)}function _0(e){var t=e.typeName;switch(t){case"double":case"float":case"int":case"long":return"number";case"bytes":case"fixed":return"buffer";case"enum":return"string";case"map":case"error":case"record":return"object";default:return t}}function b8(e){if(e===null)return"null";var t=typeof e;if(t==="object"){if(Array.isArray(e))return"array";else if(hu.isBuffer(e))return"buffer"}return t}function Q_e(e){var t={},n,r,i,s;for(n=0,r=e.length;nn)n=a,r=o;return r}function X_e(e,t){var n={},r,i,s,o;for(r=0,i=e.length;r0){var O=D[0];D[0]=D[T],D[T]=O,x=Ee.forSchema(D,t)}}return{name:g,type:x,default:i[g]}})};else b={type:"map",values:Ee.forTypes(n,t)};return Ee.forSchema(b,t)}v8.exports={Type:Ee,getTypeBucket:_0,getValueBucket:b8,isPrimitive:lm,builtins:function(){var e={LogicalType:Wr,UnwrappedUnionType:gs,WrappedUnionType:To},t=Object.keys(v0),n,r,i;for(n=0,r=t.length;n=",ok:ju.GTE,fail:ju.LT},{okStr:">",ok:ju.GT,fail:ju.LTE}]}},iwe={message:(e)=>kO.str`must be ${EO(e).okStr} ${e.schemaCode}`,params:(e)=>kO._`{comparison: ${EO(e).okStr}, limit: ${e.schemaCode}}`},swe={keyword:Object.keys(SO),type:"number",schemaType:"number",$data:!0,error:iwe,code(e){let{data:t,schemaCode:n}=e;e.fail$data(kO._`${t} ${EO(e).fail} ${n} || isNaN(${t})`)}};function EO(e){var t;let n=e.keyword,r=((t=e.parentSchema)===null||t===void 0?void 0:t[SO[n].exclusive])?1:0;return SO[n].ops[r]}i4.default=swe});var l4=z(function(a4){Object.defineProperty(a4,"__esModule",{value:!0});var o4={exclusiveMaximum:"maximum",exclusiveMinimum:"minimum"},awe={keyword:Object.keys(o4),type:"number",schemaType:"boolean",code({keyword:e,parentSchema:t}){let n=o4[e];if(t[n]===void 0)throw Error(`${e} can only be used with ${n}`)}};a4.default=awe});var u4=z(function(c4){Object.defineProperty(c4,"__esModule",{value:!0});var cwe=s4(),uwe=l4(),pwe=c1(),dwe=u1(),fwe=p1(),mwe=d1(),ywe=f1(),hwe=m1(),gwe=h1(),bwe=b1(),vwe=v1(),_we=[cwe.default,uwe.default,pwe.default,dwe.default,fwe.default,mwe.default,ywe.default,hwe.default,gwe.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},bwe.default,vwe.default];c4.default=_we});var d4=z(function(p4){Object.defineProperty(p4,"__esModule",{value:!0});var wwe=r4(),Dwe=u4(),Twe=Zx(),Swe=e0(),Ewe=["title","description","default"],kwe=[wwe.default,Dwe.default,Twe.default(),Swe.default,Ewe];p4.default=kwe});var f4=z(function(lot,Owe){Owe.exports={id:"http://json-schema.org/draft-04/schema#",$schema:"http://json-schema.org/draft-04/schema#",description:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},positiveInteger:{type:"integer",minimum:0},positiveIntegerDefault0:{allOf:[{$ref:"#/definitions/positiveInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0}},type:"object",properties:{id:{type:"string",format:"uri"},$schema:{type:"string",format:"uri"},title:{type:"string"},description:{type:"string"},default:{},multipleOf:{type:"number",minimum:0,exclusiveMinimum:!0},maximum:{type:"number"},exclusiveMaximum:{type:"boolean",default:!1},minimum:{type:"number"},exclusiveMinimum:{type:"boolean",default:!1},maxLength:{$ref:"#/definitions/positiveInteger"},minLength:{$ref:"#/definitions/positiveIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{anyOf:[{type:"boolean"},{$ref:"#"}],default:{}},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:{}},maxItems:{$ref:"#/definitions/positiveInteger"},minItems:{$ref:"#/definitions/positiveIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},maxProperties:{$ref:"#/definitions/positiveInteger"},minProperties:{$ref:"#/definitions/positiveIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{anyOf:[{type:"boolean"},{$ref:"#"}],default:{}},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},enum:{type:"array",minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},dependencies:{exclusiveMaximum:["maximum"],exclusiveMinimum:["minimum"]},default:{}}});var h4=z(function(jo,y4){Object.defineProperty(jo,"__esModule",{value:!0});jo.CodeGen=jo.Name=jo.nil=jo.stringify=jo.str=jo._=jo.KeywordCxt=void 0;var Pwe=cu(),$we=d4(),Iwe=ig(),m4=f4(),Awe=["/properties"],sw="http://json-schema.org/draft-04/schema";class NO extends Pwe.default{constructor(e={}){super({...e,schemaId:"id"})}_addVocabularies(){if(super._addVocabularies(),$we.default.forEach((e)=>this.addVocabulary(e)),this.opts.discriminator)this.addKeyword(Iwe.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let e=this.opts.$data?this.$dataMetaSchema(m4,Awe):m4;this.addMetaSchema(e,sw,!1),this.refs["http://json-schema.org/schema"]=sw}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(sw)?sw:void 0)}}y4.exports=jo=NO;Object.defineProperty(jo,"__esModule",{value:!0});jo.default=NO;var Rwe=cu();Object.defineProperty(jo,"KeywordCxt",{enumerable:!0,get:function(){return Rwe.KeywordCxt}});var Dm=cu();Object.defineProperty(jo,"_",{enumerable:!0,get:function(){return Dm._}});Object.defineProperty(jo,"str",{enumerable:!0,get:function(){return Dm.str}});Object.defineProperty(jo,"stringify",{enumerable:!0,get:function(){return Dm.stringify}});Object.defineProperty(jo,"nil",{enumerable:!0,get:function(){return Dm.nil}});Object.defineProperty(jo,"Name",{enumerable:!0,get:function(){return Dm.Name}});Object.defineProperty(jo,"CodeGen",{enumerable:!0,get:function(){return Dm.CodeGen}})});function Kg(e){return ADe(e)!==0}function f9(e){return e>=Yr.a&&e<=Yr.z||e>=Yr.A&&e<=Yr.Z}function IDe(e,t){let n=e.charCodeAt(t);if(n===Yr.colon)return t+1;if(n===Yr.percent&&e.charCodeAt(t+1)===Yr._3){let r=e.charCodeAt(t+2);if(r===Yr.a||r===Yr.A)return t+3}return-1}function ADe(e){if(!e)return 0;let t=e.charCodeAt(0);if(t===Yr.slash||t===Yr.backslash){if(e.charCodeAt(1)!==t)return 1;let r=e.indexOf(t===Yr.slash?"/":"\\",2);if(r<0)return e.length;return r+1}if(f9(t)&&e.charCodeAt(1)===Yr.colon){let r=e.charCodeAt(2);if(r===Yr.slash||r===Yr.backslash)return 3;if(e.length===2)return 2}let n=e.indexOf("://");if(n!==-1){let r=n+3,i=e.indexOf("/",r);if(i!==-1){let s=e.slice(0,n),o=e.slice(r,i);if(s==="file"&&(o===""||o==="localhost")&&f9(e.charCodeAt(i+1))){let a=IDe(e,i+2);if(a!==-1){if(e.charCodeAt(a)===Yr.slash)return~(a+1);if(a===e.length)return~a}}return~(i+1)}return~e.length}return 0}var Yr;var mn=q(()=>{(function(e){e[e.nullCharacter=0]="nullCharacter",e[e.maxAsciiCharacter=127]="maxAsciiCharacter",e[e.lineFeed=10]="lineFeed",e[e.carriageReturn=13]="carriageReturn",e[e.lineSeparator=8232]="lineSeparator",e[e.paragraphSeparator=8233]="paragraphSeparator",e[e.nextLine=133]="nextLine",e[e.space=32]="space",e[e.nonBreakingSpace=160]="nonBreakingSpace",e[e.enQuad=8192]="enQuad",e[e.emQuad=8193]="emQuad",e[e.enSpace=8194]="enSpace",e[e.emSpace=8195]="emSpace",e[e.threePerEmSpace=8196]="threePerEmSpace",e[e.fourPerEmSpace=8197]="fourPerEmSpace",e[e.sixPerEmSpace=8198]="sixPerEmSpace",e[e.figureSpace=8199]="figureSpace",e[e.punctuationSpace=8200]="punctuationSpace",e[e.thinSpace=8201]="thinSpace",e[e.hairSpace=8202]="hairSpace",e[e.zeroWidthSpace=8203]="zeroWidthSpace",e[e.narrowNoBreakSpace=8239]="narrowNoBreakSpace",e[e.ideographicSpace=12288]="ideographicSpace",e[e.mathematicalSpace=8287]="mathematicalSpace",e[e.ogham=5760]="ogham",e[e._=95]="_",e[e.$=36]="$",e[e._0=48]="_0",e[e._1=49]="_1",e[e._2=50]="_2",e[e._3=51]="_3",e[e._4=52]="_4",e[e._5=53]="_5",e[e._6=54]="_6",e[e._7=55]="_7",e[e._8=56]="_8",e[e._9=57]="_9",e[e.a=97]="a",e[e.b=98]="b",e[e.c=99]="c",e[e.d=100]="d",e[e.e=101]="e",e[e.f=102]="f",e[e.g=103]="g",e[e.h=104]="h",e[e.i=105]="i",e[e.j=106]="j",e[e.k=107]="k",e[e.l=108]="l",e[e.m=109]="m",e[e.n=110]="n",e[e.o=111]="o",e[e.p=112]="p",e[e.q=113]="q",e[e.r=114]="r",e[e.s=115]="s",e[e.t=116]="t",e[e.u=117]="u",e[e.v=118]="v",e[e.w=119]="w",e[e.x=120]="x",e[e.y=121]="y",e[e.z=122]="z",e[e.A=65]="A",e[e.B=66]="B",e[e.C=67]="C",e[e.D=68]="D",e[e.E=69]="E",e[e.F=70]="F",e[e.G=71]="G",e[e.H=72]="H",e[e.I=73]="I",e[e.J=74]="J",e[e.K=75]="K",e[e.L=76]="L",e[e.M=77]="M",e[e.N=78]="N",e[e.O=79]="O",e[e.P=80]="P",e[e.Q=81]="Q",e[e.R=82]="R",e[e.S=83]="S",e[e.T=84]="T",e[e.U=85]="U",e[e.V=86]="V",e[e.W=87]="W",e[e.X=88]="X",e[e.Y=89]="Y",e[e.Z=90]="Z",e[e.ampersand=38]="ampersand",e[e.asterisk=42]="asterisk",e[e.at=64]="at",e[e.backslash=92]="backslash",e[e.backtick=96]="backtick",e[e.bar=124]="bar",e[e.caret=94]="caret",e[e.closeBrace=125]="closeBrace",e[e.closeBracket=93]="closeBracket",e[e.closeParen=41]="closeParen",e[e.colon=58]="colon",e[e.comma=44]="comma",e[e.dot=46]="dot",e[e.doubleQuote=34]="doubleQuote",e[e.equals=61]="equals",e[e.exclamation=33]="exclamation",e[e.greaterThan=62]="greaterThan",e[e.hash=35]="hash",e[e.lessThan=60]="lessThan",e[e.minus=45]="minus",e[e.openBrace=123]="openBrace",e[e.openBracket=91]="openBracket",e[e.openParen=40]="openParen",e[e.percent=37]="percent",e[e.plus=43]="plus",e[e.question=63]="question",e[e.semicolon=59]="semicolon",e[e.singleQuote=39]="singleQuote",e[e.slash=47]="slash",e[e.tilde=126]="tilde",e[e.backspace=8]="backspace",e[e.formFeed=12]="formFeed",e[e.byteOrderMark=65279]="byteOrderMark",e[e.tab=9]="tab",e[e.verticalTab=11]="verticalTab"})(Yr||(Yr={}))});function pw(e){if(Array.isArray(e))e.forEach(pw);else if(typeof e==="object")for(let t in e)pw(e[t]);return Object.freeze(e)}function Tm(e){return Array.isArray(e)}function Nd(e){return e!==void 0}function Tn(e){return e}function il(e){return new m9(e)}function y9(e,t){if(typeof process<"u")return process?.env?.[e]??t;return t}var m9;var Gt=q(()=>{mn();m9=class m9{#e=new Map;#t=new Map;constructor(e){if(e)for(let[t,n]of e)this.set(t,n)}clear(){this.#e.clear(),this.#t.clear()}delete(e){let t=this.#e.get(e);if(t)return this.#e.delete(e),this.#t.delete(t);return!1}forEach(e,t){this.#t.forEach((n,r)=>{e(n,r.key,this)},t)}get(e){let t=this.#e.get(e);return t?this.#t.get(t):void 0}has(e){return this.#e.has(e)}set(e,t){let n=this.#e.get(e);if(!n)n={key:e},this.#e.set(e,n);return this.#t.set(n,t),this}get size(){return this.#t.size}*entries(){for(let[e,t]of this.#t)yield[e.key,t]}*keys(){for(let e of this.#t.keys())yield e.key}values(){return this.#t.values()}[Symbol.iterator](){return this.entries()}[Symbol.toStringTag]="RekeyableMap";rekey(e,t){let n=this.#e.get(e);if(!n)return!1;this.#e.delete(e);let r=this.#e.get(t);if(r)this.#t.delete(r);return n.key=t,this.#e.set(t,n),!0}}});function dw(e,t){let n=t?`It must match one of the code defined in the library '${t}'`:"It must match one of the code defined in the compiler.";function r(s){let o=e[s.code];if(!o){let u=Object.keys(e).map((d)=>` - ${d}`).join(` `),p=String(s.code);throw Error(`Unexpected diagnostic code '${p}'. ${n}. Defined codes: ${u}`)}let a=o.messages[s.messageId??"default"];if(!a){let u=Object.keys(o.messages).map((f)=>` - ${f}`).join(` `),p=String(s.messageId),d=String(s.code);throw Error(`Unexpected message id '${p}'. ${n} for code '${d}'. Defined codes: -${u}`)}let l=typeof a==="string"?a:a(s.format),c={code:t?`${t}/${String(s.code)}`:s.code.toString(),severity:o.severity,message:l,target:s.target};if(o.url)Tn(c).url=o.url;if(s.codefixes)Tn(c).codefixes=s.codefixes;return c}function i(s,o){let a=r(o);s.reportDiagnostic(a)}return{diagnostics:e,createDiagnostic:r,reportDiagnostic:i}}var FO=q(()=>{Gt()});function M(e,...t){let n=(r)=>{let i=[e[0]];return t.forEach((s,o)=>{let a=r[s];if(a!==void 0)i.push(a);i.push(e[o+1])}),i.join("")};return n.keys=t,n}var h9,RDe,tn,gn;var Yn=q(()=>{FO();h9={"digit-expected":{severity:"error",messages:{default:"Digit expected."}},"hex-digit-expected":{severity:"error",messages:{default:"Hexadecimal digit expected."}},"binary-digit-expected":{severity:"error",messages:{default:"Binary digit expected."}},unterminated:{severity:"error",messages:{default:M`Unterminated ${"token"}.`}},"creating-file":{severity:"error",messages:{default:M`Error creating single file: ${"filename"}, ${"error"}`}},"invalid-escape-sequence":{severity:"error",messages:{default:"Invalid escape sequence."}},"no-new-line-start-triple-quote":{severity:"error",messages:{default:"String content in triple quotes must begin on a new line."}},"no-new-line-end-triple-quote":{severity:"error",messages:{default:"Closing triple quotes must begin on a new line."}},"triple-quote-indent":{severity:"error",description:"Report when a triple-quoted string has lines with less indentation as the closing triple quotes.",url:"https://typespec.io/docs/standard-library/diags/triple-quote-indent",messages:{default:"All lines in triple-quoted string lines must have the same indentation as closing triple quotes."}},"invalid-character":{severity:"error",messages:{default:"Invalid character."}},"file-not-found":{severity:"error",messages:{default:M`File ${"path"} not found.`}},"file-load":{severity:"error",messages:{default:M`${"message"}`}},"init-template-invalid-json":{severity:"error",messages:{default:M`Unable to parse ${"url"}: ${"message"}. Check that the template URL is correct.`}},"init-template-download-failed":{severity:"error",messages:{default:M`Failed to download template from ${"url"}: ${"message"}. Check that the template URL is correct.`}},"multiple-blockless-namespace":{severity:"error",messages:{default:"Cannot use multiple blockless namespaces."}},"blockless-namespace-first":{severity:"error",messages:{default:"Blockless namespaces can't follow other declarations.",topLevel:"Blockless namespace can only be top-level."}},"import-first":{severity:"error",messages:{default:"Imports must come prior to namespaces or other declarations.",topLevel:"Imports must be top-level and come prior to namespaces or other declarations."}},"duplicate-import":{severity:"warning",messages:{default:M`Duplicate import of "${"importPath"}"`}},"self-import":{severity:"warning",messages:{default:"A file cannot import itself."}},"token-expected":{severity:"error",messages:{default:M`${"token"} expected.`,unexpected:M`Unexpected token ${"token"}`,numericOrStringLiteral:"Expected numeric or string literal.",identifier:"Identifier expected.",expression:"Expression expected.",statement:"Statement expected.",property:"Property expected.",enumMember:"Enum member expected.",typeofTarget:"Typeof expects a value literal or value reference."}},"unknown-directive":{severity:"error",messages:{default:M`Unknown directive '#${"id"}'`}},"augment-decorator-target":{severity:"error",messages:{default:"Augment decorator first argument must be a type reference.",noInstance:"Cannot reference template instances.",noModelExpression:"Cannot augment model expressions.",noUnionExpression:"Cannot augment union expressions."}},"duplicate-decorator":{severity:"warning",messages:{default:M`Decorator ${"decoratorName"} cannot be used twice on the same declaration.`}},"decorator-conflict":{severity:"warning",messages:{default:M`Decorator ${"decoratorName"} cannot be used with decorator ${"otherDecoratorName"} on the same declaration.`}},"reserved-identifier":{severity:"error",messages:{default:"Keyword cannot be used as identifier.",future:M`${"name"} is a reserved keyword`}},"invalid-directive-location":{severity:"error",messages:{default:M`Cannot place directive on ${"nodeName"}.`}},"invalid-decorator-location":{severity:"error",messages:{default:M`Cannot decorate ${"nodeName"}.`}},"default-required":{severity:"error",messages:{default:"Required template parameters must not follow optional template parameters"}},"invalid-template-argument-name":{severity:"error",messages:{default:"Template parameter argument names must be valid, bare identifiers."}},"invalid-template-default":{severity:"error",messages:{default:"Template parameter defaults can only reference previously declared type parameters."}},"required-parameter-first":{severity:"error",messages:{default:"A required parameter cannot follow an optional parameter."}},"rest-parameter-last":{severity:"error",messages:{default:"A rest parameter must be last in a parameter list."}},"rest-parameter-required":{severity:"error",messages:{default:"A rest parameter cannot be optional."}},"doc-invalid-identifier":{severity:"warning",messages:{default:"Invalid identifier.",tag:"Invalid tag name. Use backticks around code if this was not meant to be a tag.",param:"Invalid parameter name.",prop:"Invalid property name.",templateParam:"Invalid template parameter name."}},"experimental-feature":{severity:"warning",messages:{default:M`${"feature"} is an experimental feature. It may change in the future or be removed. Use with caution and consider providing feedback on this feature.`,functionDeclarations:"Function declarations are an experimental feature that may change in the future. Use with caution and consider providing feedback to the TypeSpec team."}},"union-extends-disabled":{severity:"error",messages:{default:"Union `extends` clauses require the 'union-extends' feature to be enabled. Add 'union-extends' to the 'features' list in your tspconfig.yaml."}},"auto-decorator-disabled":{severity:"error",messages:{default:"Auto decorator declarations require the 'auto-decorators' feature to be enabled. Add 'auto-decorators' to the 'features' list in your tspconfig.yaml."}},"using-invalid-ref":{severity:"error",messages:{default:"Using must refer to a namespace"}},"invalid-type-ref":{severity:"error",messages:{default:"Invalid type reference",decorator:"Can't put a decorator in a type",function:"Can't use a function as a type"}},"invalid-template-args":{severity:"error",messages:{default:"Invalid template arguments.",notTemplate:"Can't pass template arguments to non-templated type",tooMany:"Too many template arguments provided.",unknownName:M`No parameter named '${"name"}' exists in the target template.`,positionalAfterNamed:"Positional template arguments cannot follow named arguments in the same argument list.",missing:M`Template argument '${"name"}' is required and not specified.`,specifiedAgain:M`Cannot specify template argument '${"name"}' again.`}},"intersect-non-model":{severity:"error",messages:{default:"Cannot intersect non-model types (including union types)."}},"intersect-invalid-index":{severity:"error",messages:{default:"Cannot intersect incompatible models.",never:"Cannot intersect a model that cannot hold properties.",array:"Cannot intersect an array model."}},"incompatible-indexer":{severity:"error",messages:{default:M`Property is incompatible with indexer:\n${"message"}`}},"no-array-properties":{severity:"error",messages:{default:"Array models cannot have any properties."}},"intersect-duplicate-property":{severity:"error",messages:{default:M`Intersection contains duplicate property definitions for ${"propName"}`}},"invalid-decorator":{severity:"error",messages:{default:M`${"id"} is not a decorator`}},"invalid-ref":{severity:"error",messages:{default:M`Cannot resolve ${"id"}`,identifier:M`Unknown identifier ${"id"}`,decorator:M`Unknown decorator @${"id"}`,inDecorator:M`Cannot resolve ${"id"} in decorator`,underNamespace:M`Namespace ${"namespace"} doesn't have member ${"id"}`,member:M`${"kind"} doesn't have member ${"id"}`,metaProperty:M`${"kind"} doesn't have meta property ${"id"}`,node:M`Cannot resolve '${"id"}' in node ${"nodeName"} since it has no members. Did you mean to use "::" instead of "."?`,internal:M`Symbol '${"id"}' is internal and can only be accessed from within its declaring package.`}},"duplicate-property":{severity:"error",messages:{default:M`Model already has a property named ${"propName"}`,withModel:M`Model ${"modelName"} already has a property named ${"propName"}`}},"override-property-mismatch":{severity:"error",messages:{default:M`Model has an inherited property named ${"propName"} of type ${"propType"} which cannot override type ${"parentType"}`,disallowedOptionalOverride:M`Model has a required inherited property named ${"propName"} which cannot be overridden as optional`}},"extend-scalar":{severity:"error",messages:{default:"Scalar must extend other scalars."}},"extend-model":{severity:"error",messages:{default:"Models must extend other models.",modelExpression:"Models cannot extend model expressions."}},"extend-union":{severity:"error",messages:{default:"Union `extends` must specify a model, scalar, enum, or union.",modelExpression:"Unions cannot extend model expressions."}},"is-model":{severity:"error",messages:{default:"Model `is` must specify another model.",modelExpression:"Model `is` cannot specify a model expression."}},"is-operation":{severity:"error",messages:{default:"Operation can only reuse the signature of another operation."}},"spread-model":{severity:"error",messages:{default:"Cannot spread properties of non-model type.",neverIndex:"Cannot spread type because it cannot hold properties.",selfSpread:"Cannot spread type within its own declaration."}},"unsupported-default":{severity:"error",messages:{default:M`Default must be have a value type but has type '${"type"}'.`}},"spread-object":{severity:"error",messages:{default:"Cannot spread properties of non-object type."}},"expect-value":{severity:"error",messages:{default:M`${"name"} refers to a type, but is being used as a value here.`,model:M`${"name"} refers to a model type, but is being used as a value here. Use #{} to create an object value.`,modelExpression:"Is a model expression type, but is being used as a value here. Use #{} to create an object value.",tuple:"Is a tuple type, but is being used as a value here. Use #[] to create an array value.",templateConstraint:M`${"name"} template parameter can be a type but is being used as a value here.`,functionReturn:M`Function returned a type, but a value was expected.`}},"non-callable":{severity:"error",messages:{default:M`Type ${"type"} is not is not callable.`,templateParameter:M`Template parameter '${"name"} extends ${"constraint"}' is not callable. Ensure it is constrained to a function value or callable type (scalar or scalar constructor).`}},"named-init-required":{severity:"error",messages:{default:M`Only scalar deriving from 'string', 'numeric' or 'boolean' can be instantited without a named constructor.`}},"invalid-primitive-init":{severity:"error",messages:{default:"Instantiating scalar deriving from 'string', 'numeric' or 'boolean' can only take a single argument.",invalidArg:M`Expected a single argument of type ${"expected"} but got ${"actual"}.`}},"ambiguous-scalar-type":{severity:"error",messages:{default:M`Value ${"value"} type is ambiguous between ${"types"}. To resolve be explicit when instantiating this value(e.g. '${"example"}(${"value"})').`}},unassignable:{severity:"error",messages:{default:M`Type '${"sourceType"}' is not assignable to type '${"targetType"}'`}},"property-unassignable":{severity:"error",messages:{default:M`Types of property '${"propName"}' are incompatible`}},"property-required":{severity:"error",messages:{default:M`Property '${"propName"}' is required in type '${"targetType"}' but here is optional.`}},"parameter-required":{severity:"error",messages:{default:M`Parameter '${"paramName"}' is required, but optional in the target function.`,missing:M`Parameter '${"paramName"}' is required, but missing in the target function.`,"rest-to-required":M`Parameter '${"paramName"}' is required and not satisfied by a rest parameter, as rest parameters are effectively optional.`}},"value-in-type":{severity:"error",messages:{default:"A value cannot be used as a type.",referenceTemplate:"Template parameter can be passed values but is used as a type.",noTemplateConstraint:"Template parameter has no constraint but a value is passed. Add `extends valueof unknown` to accept any value."}},"no-prop":{severity:"error",messages:{default:M`Property '${"propName"}' cannot be defined because model cannot hold properties.`}},"missing-index":{severity:"error",messages:{default:M`Index signature for type '${"indexType"}' is missing in type '${"sourceType"}'.`}},"missing-property":{severity:"error",messages:{default:M`Property '${"propertyName"}' is missing on type '${"sourceType"}' but required in '${"targetType"}'`}},"unexpected-property":{severity:"error",messages:{default:M`Object value may only specify known properties, and '${"propertyName"}' does not exist in type '${"type"}'.`}},"extends-interface":{severity:"error",messages:{default:"Interfaces can only extend other interfaces"}},"extends-interface-duplicate":{severity:"error",messages:{default:M`Interface extends cannot have duplicate members. The duplicate member is named ${"name"}`}},"interface-duplicate":{severity:"error",messages:{default:M`Interface already has a member named ${"name"}`}},"union-duplicate":{severity:"error",messages:{default:M`Union already has a variant named ${"name"}`}},"enum-member-duplicate":{severity:"error",messages:{default:M`Enum already has a member named ${"name"}`}},"constructor-duplicate":{severity:"error",messages:{default:M`A constructor already exists with name ${"name"}`}},"spread-enum":{severity:"error",messages:{default:"Cannot spread members of non-enum type."}},"decorator-fail":{severity:"error",messages:{default:M`Decorator ${"decoratorName"} failed!\n\n${"error"}`}},"rest-parameter-array":{severity:"error",messages:{default:"A rest parameter must be of an array type."}},"invalid-modifier":{severity:"error",messages:{default:M`Modifier '${"modifier"}' is invalid.`,"missing-required":M`Declaration of type '${"nodeKind"}' is missing required modifier '${"modifier"}'.`,"missing-required-one-of":M`Declaration of type '${"nodeKind"}' is missing one of the required modifiers: ${"modifiers"}.`,"mutually-exclusive":M`Modifiers '${"modifierA"}' and '${"modifierB"}' cannot be used together.`,"not-allowed":M`Modifier '${"modifier"}' cannot be used on declarations of type '${"nodeKind"}'.`}},"function-return":{severity:"error",messages:{default:"Function implementation returned an invalid result.","invalid-value":M`Function implementation returned invalid JS value '${"value"}'.`,unassignable:M`Implementation of '${"name"}' returned ${"entityKind"} '${"return"}', which is not assignable to the declared return type '${"type"}'.`}},"fn-in-union-expression":{severity:"error",messages:{default:"Function types in anonymous union expressions must be parenthesized."}},"missing-implementation":{severity:"error",messages:{default:"Extern declaration must have an implementation in JS file."}},"missing-extern-declaration":{severity:"error",description:"Report when a function is registered in $functions in a JS file but has no corresponding `extern fn` declaration in TypeSpec.",url:"https://typespec.io/docs/standard-library/diags/missing-extern-declaration",messages:{default:M`Function implementation "${"name"}" is exported in JS via $functions but has no corresponding 'extern fn' declaration in TypeSpec.`}},"overload-same-parent":{severity:"error",messages:{default:"Overload must be in the same interface or namespace."}},shadow:{severity:"warning",messages:{default:M`Shadowing parent template parameter with the same name "${"name"}"`}},"invalid-deprecation-argument":{severity:"error",messages:{default:M`#deprecation directive is expecting a string literal as the message but got a "${"kind"}"`,missing:"#deprecation directive is expecting a message argument but none was provided."}},"duplicate-deprecation":{severity:"warning",messages:{default:"The #deprecated directive cannot be used more than once on the same declaration."}},"config-invalid-argument":{severity:"error",messages:{default:M`Argument "${"name"}" is not defined as a parameter in the config.`}},"config-circular-variable":{severity:"error",messages:{default:M`There is a circular reference to variable "${"name"}" in the cli configuration or arguments.`}},"config-path-absolute":{severity:"error",messages:{default:M`Path "${"path"}" cannot be relative. Use {cwd} or {project-root} to specify what the path should be relative to.`}},"config-invalid-name":{severity:"error",messages:{default:M`The configuration name "${"name"}" is invalid because it contains a dot ("."). Using a dot will conflict with using nested configuration values.`}},"path-unix-style":{severity:"warning",messages:{default:M`Path should use unix style separators. Use "/" instead of "\\".`}},"config-path-not-found":{severity:"error",messages:{default:M`No configuration file found at config path "${"path"}".`}},"config-project-kind-filename":{severity:"error",messages:{default:M`Config with \`kind: project\` must be named "tspconfig.yaml". Found in "${"filename"}".`}},"config-project-only-option":{severity:"error",messages:{default:M`Property "${"option"}" can only be used in a project config (with \`kind: project\`).`}},"config-unknown-feature":{severity:"error",messages:{default:M`Unknown compiler feature "${"feature"}".`}},"config-project-not-as-cli-config":{severity:"error",messages:{default:"`--config` cannot point to a project config (with `kind: project`). Use a non-project build config that `extends` the project config instead."}},"dynamic-import":{severity:"error",messages:{default:"Dynamically generated TypeSpec cannot have imports"}},"invalid-import":{severity:"error",messages:{default:"Import paths must reference either a directory, a .tsp file, or .js file"}},"invalid-main":{severity:"error",messages:{default:"Main file must either be a .tsp file or a .js file."}},"import-not-found":{severity:"error",messages:{default:M`Couldn't resolve import "${"path"}"`}},"library-invalid":{severity:"error",messages:{default:M`Library "${"path"}" is invalid: ${"message"}`}},"incompatible-library":{severity:"warning",messages:{default:M`Multiple versions of "${"name"}" library were loaded:\n${"versionMap"}`}},"compiler-version-mismatch":{severity:"warning",messages:{default:M`Current TypeSpec compiler conflicts with local version of @typespec/compiler referenced in ${"basedir"}. \nIf this warning occurs on the command line, try running \`typespec\` with a working directory of ${"basedir"}. \nIf this warning occurs in the IDE, try configuring the \`tsp-server\` path to ${"betterTypeSpecServerPath"}.\n Expected: ${"expected"}\n Resolved: ${"actual"}`}},"duplicate-symbol":{severity:"error",messages:{default:M`Duplicate name: "${"name"}"`}},"duplicate-suppression":{severity:"warning",messages:{default:M`Diagnostic "${"code"}" is already suppressed on this node.`}},"ambiguous-short-name":{severity:"warning",messages:{default:M`Short name "${"shortName"}" is ambiguous. It could refer to ${"candidates"}. Use the full name instead.`}},"decorator-decl-target":{severity:"error",messages:{default:"dec must have at least one parameter.",required:"dec first parameter must be required."}},"mixed-string-template":{severity:"error",messages:{default:"String template is interpolating values and types. It must be either all values to produce a string value or or all types for string template type."}},"non-literal-string-template":{severity:"error",messages:{default:"Value interpolated in this string template cannot be converted to a string. Only literal types can be automatically interpolated."}},"ambiguous-symbol":{severity:"error",messages:{default:M`"${"name"}" is an ambiguous name between ${"duplicateNames"}. Try using fully qualified name instead: ${"duplicateNames"}`}},"duplicate-using":{severity:"error",messages:{default:M`duplicate using of "${"usingName"}" namespace`}},"on-validate-fail":{severity:"error",messages:{default:M`onValidate failed with errors. ${"error"}`}},"emitter-not-found":{severity:"error",messages:{default:M`Emitter "${"emitterPackage"}" not found. Make sure to install it with \`npm install ${"emitterPackage"}\`.`}},"invalid-emitter":{severity:"error",messages:{default:M`Requested emitter package ${"emitterPackage"} does not provide an "$onEmit" function.`}},"js-error":{severity:"error",messages:{default:M`Failed to load ${"specifier"} due to the following JS error: ${"error"}`}},"missing-import":{severity:"error",messages:{default:M`Emitter '${"emitterName"}' requires '${"requiredImport"}' to be imported. Add 'import "${"requiredImport"}".`}},"invalid-rule-ref":{severity:"error",messages:{default:M`Reference "${"ref"}" is not a valid reference to a rule or ruleset. It must be in the following format: ":"`}},"unknown-rule":{severity:"error",messages:{default:M`Rule "${"ruleName"}" is not found in library "${"libraryName"}"`}},"unknown-rule-set":{severity:"error",messages:{default:M`Rule set "${"ruleSetName"}" is not found in library "${"libraryName"}"`}},"rule-enabled-disabled":{severity:"error",messages:{default:M`Rule "${"ruleName"}" has been enabled and disabled in the same ruleset.`}},"invalid-rule-options":{severity:"error",messages:{default:M`Invalid options for rule "${"ruleName"}": ${"details"}`}},"circular-ruleset-file":{severity:"error",messages:{default:M`Linter ruleset file "${"path"}" is extending itself, either directly or indirectly.`}},"ruleset-file-in-library":{severity:"error",messages:{default:M`Ruleset "${"ruleSetName"}" is defined in a library and cannot extend the ruleset file "${"ref"}". "file:" references can only be used in "tspconfig.yaml" or in another ruleset file.`}},"format-failed":{severity:"error",messages:{default:M`File '${"file"}' failed to format. ${"details"}`}},"invalid-pattern-regex":{severity:"warning",messages:{default:"@pattern decorator expects a valid regular expression pattern."}},"decorator-wrong-target":{severity:"error",messages:{default:M`Cannot apply ${"decorator"} decorator to ${"to"}`,withExpected:M`Cannot apply ${"decorator"} decorator to ${"to"} since it is not assignable to ${"expected"}`}},"invalid-argument":{severity:"error",messages:{default:M`Argument of type '${"value"}' is not assignable to parameter of type '${"expected"}'`}},"invalid-argument-count":{severity:"error",messages:{default:M`Expected ${"expected"} arguments, but got ${"actual"}.`,atLeast:M`Expected at least ${"expected"} arguments, but got ${"actual"}.`}},"known-values-invalid-enum":{severity:"error",messages:{default:M`Enum cannot be used on this type. Member ${"member"} is not assignable to type ${"type"}.`}},"invalid-value":{severity:"error",messages:{default:M`Type '${"kind"}' is not a value type.`,atPath:M`Type '${"kind"}' of '${"path"}' is not a value type.`}},deprecated:{severity:"warning",messages:{default:M`Deprecated: ${"message"}`}},"no-optional-key":{severity:"error",messages:{default:M`Property '${"propertyName"}' marked as key cannot be optional.`}},"invalid-discriminated-union":{severity:"error",messages:{default:"",noAnonVariants:"Unions with anonymous variants cannot be discriminated"}},"invalid-discriminated-union-variant":{severity:"error",messages:{default:M`Union variant "${"name"}" must be a model type.`,noEnvelopeModel:M`Union variant "${"name"}" must be a model type when the union has envelope: none.`,discriminantMismatch:M`Variant "${"name"}" explicitly defines the discriminator property "${"discriminant"}" but the value "${"propertyValue"}" do not match the variant name "${"variantName"}".`,duplicateDefaultVariant:M`Discriminated union ${"unionName"} only allow a single default variant(Without a variant name).`,noDiscriminant:M`Variant "${"name"}" type is missing the discriminant property "${"discriminant"}".`,wrongDiscriminantType:M`Variant "${"name"}" type's discriminant property "${"discriminant"}" must be a string literal or string enum member.`}},"missing-discriminator-property":{severity:"error",messages:{default:M`Each derived model of a discriminated model type should have set the discriminator property("${"discriminator"}") or have a derived model which has. Add \`${"discriminator"}: ""\``}},"invalid-discriminator-value":{severity:"error",messages:{default:M`Discriminator value should be a string, union of string or string enum but was ${"kind"}.`,required:"The discriminator property must be a required property.",duplicate:M`Discriminator value "${"discriminator"}" is already used in another variant.`}},"invalid-encode":{severity:"error",messages:{default:"Invalid encoding",wrongType:M`Encoding '${"encoding"}' cannot be used on type '${"type"}'. Expected: ${"expected"}.`,wrongEncodingType:M`Encoding '${"encoding"}' on type '${"type"}' is expected to be serialized as '${"expected"}' but got '${"actual"}'.`,wrongNumericEncodingType:M`Encoding '${"encoding"}' on type '${"type"}' is expected to be serialized as '${"expected"}' but got '${"actual"}'. Set '@encode' 2nd parameter to be of type ${"expected"}. e.g. '@encode("${"encoding"}", int32)'`,firstArg:'First argument of "@encode" must be the encoding name or the string type when encoding numeric or boolean types.'}},"invalid-mime-type":{severity:"error",messages:{default:M`Invalid mime type '${"mimeType"}'`}},"no-mime-type-suffix":{severity:"error",messages:{default:M`Cannot use mime type '${"mimeType"}' with suffix '${"suffix"}'. Use a simple mime \`type/subtype\` instead.`}},"encoded-name-conflict":{severity:"error",messages:{default:M`Encoded name '${"name"}' conflicts with existing member name for mime type '${"mimeType"}'`,duplicate:M`Same encoded name '${"name"}' is used for 2 members '${"mimeType"}'`}},"incompatible-paging-props":{severity:"error",messages:{default:M`Paging property has multiple types: '${"kinds"}'`}},"invalid-paging-prop":{severity:"error",messages:{default:M`Paging property '${"kind"}' is not valid in this context.`,input:M`Paging property '${"kind"}' cannot be used in the parameters of an operation.`,output:M`Paging property '${"kind"}' cannot be used in the return type of an operation.`}},"duplicate-paging-prop":{severity:"error",messages:{default:M`Duplicate property paging '${"kind"}' for operation ${"operationName"}.`}},"missing-paging-items":{severity:"error",messages:{default:M`Paged operation '${"operationName"}' return type must have a property annotated with @pageItems.`}},"service-decorator-duplicate":{severity:"error",messages:{default:"@service can only be set once per TypeSpec document."}},"list-type-not-model":{severity:"error",messages:{default:"@list decorator's parameter must be a model type."}},"invalid-range":{severity:"error",messages:{default:M`Range "${"start"}..${"end"}" is invalid.`}},"add-response":{severity:"error",messages:{default:"Cannot add a response to anything except an operation statement."}},"add-parameter":{severity:"error",messages:{default:"Cannot add a parameter to anything except an operation statement."}},"add-model-property":{severity:"error",messages:{default:"Cannot add a model property to anything except a model statement."}},"add-model-property-fail":{severity:"error",messages:{default:M`Could not add property/parameter "${"propertyName"}" of type "${"propertyTypeName"}"`}},"add-response-type":{severity:"error",messages:{default:M`Could not add response type "${"responseTypeName"}" to operation ${"operationName"}"`}},"circular-base-type":{severity:"error",messages:{default:M`Type '${"typeName"}' recursively references itself as a base type.`}},"circular-constraint":{severity:"error",messages:{default:M`Type parameter '${"typeName"}' has a circular constraint.`}},"circular-op-signature":{severity:"error",messages:{default:M`Operation '${"typeName"}' recursively references itself.`}},"circular-alias-type":{severity:"error",messages:{default:M`Alias type '${"typeName"}' recursively references itself.`}},"circular-const":{severity:"error",messages:{default:M`const '${"name"}' recursively references itself.`}},"circular-prop":{severity:"error",messages:{default:M`Property '${"propName"}' recursively references itself.`}},"conflict-marker":{severity:"error",messages:{default:"Conflict marker encountered."}},"visibility-sealed":{severity:"error",messages:{default:M`Visibility of property '${"propName"}' is sealed and cannot be changed.`}},"default-visibility-not-member":{severity:"error",messages:{default:"The default visibility modifiers of a class must be members of the class enum."}},"operation-visibility-constraint-empty":{severity:"error",messages:{default:"Operation visibility constraints with no arguments are not allowed.",returnType:"Return type visibility constraints with no arguments are not allowed.",parameter:"Parameter visibility constraints with no arguments are not allowed. To disable effective PATCH optionality, use @patch(#{ implicitOptionality: false }) instead."}},"no-compatible-vs-installed":{severity:"error",messages:{default:"No compatible version of Visual Studio found."}},"vs-extension-windows-only":{severity:"error",messages:{default:"Visual Studio extension is not supported on non-Windows."}},"vsix-download-failed":{severity:"error",messages:{default:M`Failed to download extension "${"id"}" from the marketplace: ${"message"}.`}},"vscode-in-path":{severity:"error",messages:{default:"Couldn't find VS Code 'code' command in PATH. Make sure you have the VS Code executable added to the system PATH.",osx:`Couldn't find VS Code 'code' command in PATH. Make sure you have the VS Code executable added to the system PATH. -See instruction for Mac OS here https://code.visualstudio.com/docs/setup/mac`}},"invalid-option-flag":{severity:"error",messages:{default:M`The --option parameter value "${"value"}" must be in the format: .some-options=value`}},"cli-command-deprecated":{severity:"warning",messages:{default:M`The "${"command"}" command is deprecated. Install and manage the extension directly from the marketplace instead. See ${"docsUrl"} for details.`}}},RDe=new Set(Object.keys(h9)),{createDiagnostic:tn,reportDiagnostic:gn}=dw(h9)});var g9;var b9=q(()=>{g9=[160,887,890,895,900,906,908,908,910,929,931,1327,1329,1366,1369,1418,1421,1423,1425,1479,1488,1514,1519,1524,1536,1805,1807,1866,1869,1969,1984,2042,2045,2093,2096,2110,2112,2139,2142,2142,2144,2154,2160,2190,2192,2193,2200,2435,2437,2444,2447,2448,2451,2472,2474,2480,2482,2482,2486,2489,2492,2500,2503,2504,2507,2510,2519,2519,2524,2525,2527,2531,2534,2558,2561,2563,2565,2570,2575,2576,2579,2600,2602,2608,2610,2611,2613,2614,2616,2617,2620,2620,2622,2626,2631,2632,2635,2637,2641,2641,2649,2652,2654,2654,2662,2678,2689,2691,2693,2701,2703,2705,2707,2728,2730,2736,2738,2739,2741,2745,2748,2757,2759,2761,2763,2765,2768,2768,2784,2787,2790,2801,2809,2815,2817,2819,2821,2828,2831,2832,2835,2856,2858,2864,2866,2867,2869,2873,2876,2884,2887,2888,2891,2893,2901,2903,2908,2909,2911,2915,2918,2935,2946,2947,2949,2954,2958,2960,2962,2965,2969,2970,2972,2972,2974,2975,2979,2980,2984,2986,2990,3001,3006,3010,3014,3016,3018,3021,3024,3024,3031,3031,3046,3066,3072,3084,3086,3088,3090,3112,3114,3129,3132,3140,3142,3144,3146,3149,3157,3158,3160,3162,3165,3165,3168,3171,3174,3183,3191,3212,3214,3216,3218,3240,3242,3251,3253,3257,3260,3268,3270,3272,3274,3277,3285,3286,3293,3294,3296,3299,3302,3311,3313,3315,3328,3340,3342,3344,3346,3396,3398,3400,3402,3407,3412,3427,3430,3455,3457,3459,3461,3478,3482,3505,3507,3515,3517,3517,3520,3526,3530,3530,3535,3540,3542,3542,3544,3551,3558,3567,3570,3572,3585,3642,3647,3675,3713,3714,3716,3716,3718,3722,3724,3747,3749,3749,3751,3773,3776,3780,3782,3782,3784,3790,3792,3801,3804,3807,3840,3911,3913,3948,3953,3991,3993,4028,4030,4044,4046,4058,4096,4293,4295,4295,4301,4301,4304,4680,4682,4685,4688,4694,4696,4696,4698,4701,4704,4744,4746,4749,4752,4784,4786,4789,4792,4798,4800,4800,4802,4805,4808,4822,4824,4880,4882,4885,4888,4954,4957,4988,4992,5017,5024,5109,5112,5117,5120,5788,5792,5880,5888,5909,5919,5942,5952,5971,5984,5996,5998,6000,6002,6003,6016,6109,6112,6121,6128,6137,6144,6169,6176,6264,6272,6314,6320,6389,6400,6430,6432,6443,6448,6459,6464,6464,6468,6509,6512,6516,6528,6571,6576,6601,6608,6618,6622,6683,6686,6750,6752,6780,6783,6793,6800,6809,6816,6829,6832,6862,6912,6988,6992,7038,7040,7155,7164,7223,7227,7241,7245,7304,7312,7354,7357,7367,7376,7418,7424,7957,7960,7965,7968,8005,8008,8013,8016,8023,8025,8025,8027,8027,8029,8029,8031,8061,8064,8116,8118,8132,8134,8147,8150,8155,8157,8175,8178,8180,8182,8190,8192,8205,8208,8231,8234,8292,8294,8305,8308,8334,8336,8348,8352,8384,8400,8432,8448,8587,8592,9254,9280,9290,9312,11123,11126,11157,11159,11507,11513,11557,11559,11559,11565,11565,11568,11623,11631,11632,11647,11670,11680,11686,11688,11694,11696,11702,11704,11710,11712,11718,11720,11726,11728,11734,11736,11742,11744,11869,11904,11929,11931,12019,12032,12245,12272,12283,12288,12351,12353,12438,12441,12543,12549,12591,12593,12686,12688,12771,12784,12830,12832,42124,42128,42182,42192,42539,42560,42743,42752,42954,42960,42961,42963,42963,42965,42969,42994,43052,43056,43065,43072,43127,43136,43205,43214,43225,43232,43347,43359,43388,43392,43469,43471,43481,43486,43518,43520,43574,43584,43597,43600,43609,43612,43714,43739,43766,43777,43782,43785,43790,43793,43798,43808,43814,43816,43822,43824,43883,43888,44013,44016,44025,44032,55203,55216,55238,55243,55291,63744,64109,64112,64217,64256,64262,64275,64279,64285,64310,64312,64316,64318,64318,64320,64321,64323,64324,64326,64450,64467,64911,64914,64967,64975,64975,65008,65049,65056,65106,65108,65126,65128,65131,65136,65140,65142,65276,65279,65279,65281,65470,65474,65479,65482,65487,65490,65495,65498,65500,65504,65510,65512,65518,65529,65532,65536,65547,65549,65574,65576,65594,65596,65597,65599,65613,65616,65629,65664,65786,65792,65794,65799,65843,65847,65934,65936,65948,65952,65952,66000,66045,66176,66204,66208,66256,66272,66299,66304,66339,66349,66378,66384,66426,66432,66461,66463,66499,66504,66517,66560,66717,66720,66729,66736,66771,66776,66811,66816,66855,66864,66915,66927,66938,66940,66954,66956,66962,66964,66965,66967,66977,66979,66993,66995,67001,67003,67004,67072,67382,67392,67413,67424,67431,67456,67461,67463,67504,67506,67514,67584,67589,67592,67592,67594,67637,67639,67640,67644,67644,67647,67669,67671,67742,67751,67759,67808,67826,67828,67829,67835,67867,67871,67897,67903,67903,67968,68023,68028,68047,68050,68099,68101,68102,68108,68115,68117,68119,68121,68149,68152,68154,68159,68168,68176,68184,68192,68255,68288,68326,68331,68342,68352,68405,68409,68437,68440,68466,68472,68497,68505,68508,68521,68527,68608,68680,68736,68786,68800,68850,68858,68903,68912,68921,69216,69246,69248,69289,69291,69293,69296,69297,69373,69415,69424,69465,69488,69513,69552,69579,69600,69622,69632,69709,69714,69749,69759,69826,69837,69837,69840,69864,69872,69881,69888,69940,69942,69959,69968,70006,70016,70111,70113,70132,70144,70161,70163,70209,70272,70278,70280,70280,70282,70285,70287,70301,70303,70313,70320,70378,70384,70393,70400,70403,70405,70412,70415,70416,70419,70440,70442,70448,70450,70451,70453,70457,70459,70468,70471,70472,70475,70477,70480,70480,70487,70487,70493,70499,70502,70508,70512,70516,70656,70747,70749,70753,70784,70855,70864,70873,71040,71093,71096,71133,71168,71236,71248,71257,71264,71276,71296,71353,71360,71369,71424,71450,71453,71467,71472,71494,71680,71739,71840,71922,71935,71942,71945,71945,71948,71955,71957,71958,71960,71989,71991,71992,71995,72006,72016,72025,72096,72103,72106,72151,72154,72164,72192,72263,72272,72354,72368,72440,72448,72457,72704,72712,72714,72758,72760,72773,72784,72812,72816,72847,72850,72871,72873,72886,72960,72966,72968,72969,72971,73014,73018,73018,73020,73021,73023,73031,73040,73049,73056,73061,73063,73064,73066,73102,73104,73105,73107,73112,73120,73129,73440,73464,73472,73488,73490,73530,73534,73561,73648,73648,73664,73713,73727,74649,74752,74862,74864,74868,74880,75075,77712,77810,77824,78933,82944,83526,92160,92728,92736,92766,92768,92777,92782,92862,92864,92873,92880,92909,92912,92917,92928,92997,93008,93017,93019,93025,93027,93047,93053,93071,93760,93850,93952,94026,94031,94087,94095,94111,94176,94180,94192,94193,94208,100343,100352,101589,101632,101640,110576,110579,110581,110587,110589,110590,110592,110882,110898,110898,110928,110930,110933,110933,110948,110951,110960,111355,113664,113770,113776,113788,113792,113800,113808,113817,113820,113827,118528,118573,118576,118598,118608,118723,118784,119029,119040,119078,119081,119274,119296,119365,119488,119507,119520,119539,119552,119638,119648,119672,119808,119892,119894,119964,119966,119967,119970,119970,119973,119974,119977,119980,119982,119993,119995,119995,119997,120003,120005,120069,120071,120074,120077,120084,120086,120092,120094,120121,120123,120126,120128,120132,120134,120134,120138,120144,120146,120485,120488,120779,120782,121483,121499,121503,121505,121519,122624,122654,122661,122666,122880,122886,122888,122904,122907,122913,122915,122916,122918,122922,122928,122989,123023,123023,123136,123180,123184,123197,123200,123209,123214,123215,123536,123566,123584,123641,123647,123647,124112,124153,124896,124902,124904,124907,124909,124910,124912,124926,124928,125124,125127,125142,125184,125259,125264,125273,125278,125279,126065,126132,126209,126269,126464,126467,126469,126495,126497,126498,126500,126500,126503,126503,126505,126514,126516,126519,126521,126521,126523,126523,126530,126530,126535,126535,126537,126537,126539,126539,126541,126543,126545,126546,126548,126548,126551,126551,126553,126553,126555,126555,126557,126557,126559,126559,126561,126562,126564,126564,126567,126570,126572,126578,126580,126583,126585,126588,126590,126590,126592,126601,126603,126619,126625,126627,126629,126633,126635,126651,126704,126705,126976,127019,127024,127123,127136,127150,127153,127167,127169,127183,127185,127221,127232,127405,127462,127490,127504,127547,127552,127560,127568,127569,127584,127589,127744,128727,128732,128748,128752,128764,128768,128886,128891,128985,128992,129003,129008,129008,129024,129035,129040,129095,129104,129113,129120,129159,129168,129197,129200,129201,129280,129619,129632,129645,129648,129660,129664,129672,129680,129725,129727,129733,129742,129755,129760,129768,129776,129784,129792,129938,129940,129994,130032,130041,131072,173791,173824,177977,177984,178205,178208,183969,183984,191456,194560,195101,196608,201546,201552,205743,917505,917505,917536,917631,917760,917999]});function Jg(e){return e>=65536?2:1}function sl(e){return e===ne.LineFeed||e===ne.CarriageReturn}function jDe(e){return e===ne.Space||e===ne.Tab||e===ne.VerticalTab||e===ne.FormFeed}function CO(e){return e===ne.NextLine||e===ne.LeftToRightMark||e===ne.RightToLeftMark||e===ne.LineSeparator||e===ne.ParagraphSeparator}function kd(e){return ju(e)||sl(e)}function ju(e){return jDe(e)||e>ne.MaxAscii&&CO(e)}function v9(e){let t=0,n=e.length-1;if(!kd(e.charCodeAt(t))&&!kd(e.charCodeAt(n)))return e;while(kd(e.charCodeAt(t)))t++;while(kd(e.charCodeAt(n)))n--;return e.substring(t,n+1)}function Dm(e){return e>=ne._0&&e<=ne._9}function MO(e){return Dm(e)||e>=ne.A&&e<=ne.F||e>=ne.a&&e<=ne.f}function LO(e){return e===ne._0||e===ne._1}function qO(e){return e>=ne.a&&e<=ne.z}function fw(e){return e>=ne.A&&e<=ne.Z||e>=ne.a&&e<=ne.z||e===ne.$||e===ne._}function mw(e){return e>=ne.A&&e<=ne.Z||e>=ne.a&&e<=ne.z||e>=ne._0&&e<=ne._9||e===ne.$||e===ne._}function yw(e){return fw(e)||e>ne.MaxAscii&&Tm(e)}function Gg(e){return mw(e)||e>ne.MaxAscii&&Tm(e)}function Tm(e){return FDe(e,g9)}function FDe(e,t){let n=0,r=t.length,i;while(n+1{b9();(function(e){e[e.Null=0]="Null",e[e.MaxAscii=127]="MaxAscii",e[e.ByteOrderMark=65279]="ByteOrderMark",e[e.LineFeed=10]="LineFeed",e[e.CarriageReturn=13]="CarriageReturn",e[e.Space=32]="Space",e[e.Tab=9]="Tab",e[e.VerticalTab=11]="VerticalTab",e[e.FormFeed=12]="FormFeed",e[e.NextLine=133]="NextLine",e[e.LeftToRightMark=8206]="LeftToRightMark",e[e.RightToLeftMark=8207]="RightToLeftMark",e[e.LineSeparator=8232]="LineSeparator",e[e.ParagraphSeparator=8233]="ParagraphSeparator",e[e._0=48]="_0",e[e._1=49]="_1",e[e._2=50]="_2",e[e._3=51]="_3",e[e._4=52]="_4",e[e._5=53]="_5",e[e._6=54]="_6",e[e._7=55]="_7",e[e._8=56]="_8",e[e._9=57]="_9",e[e.a=97]="a",e[e.b=98]="b",e[e.c=99]="c",e[e.d=100]="d",e[e.e=101]="e",e[e.f=102]="f",e[e.g=103]="g",e[e.h=104]="h",e[e.i=105]="i",e[e.j=106]="j",e[e.k=107]="k",e[e.l=108]="l",e[e.m=109]="m",e[e.n=110]="n",e[e.o=111]="o",e[e.p=112]="p",e[e.q=113]="q",e[e.r=114]="r",e[e.s=115]="s",e[e.t=116]="t",e[e.u=117]="u",e[e.v=118]="v",e[e.w=119]="w",e[e.x=120]="x",e[e.y=121]="y",e[e.z=122]="z",e[e.A=65]="A",e[e.B=66]="B",e[e.C=67]="C",e[e.D=68]="D",e[e.E=69]="E",e[e.F=70]="F",e[e.G=71]="G",e[e.H=72]="H",e[e.I=73]="I",e[e.J=74]="J",e[e.K=75]="K",e[e.L=76]="L",e[e.M=77]="M",e[e.N=78]="N",e[e.O=79]="O",e[e.P=80]="P",e[e.Q=81]="Q",e[e.R=82]="R",e[e.S=83]="S",e[e.T=84]="T",e[e.U=85]="U",e[e.V=86]="V",e[e.W=87]="W",e[e.X=88]="X",e[e.Y=89]="Y",e[e.Z=90]="Z",e[e._=95]="_",e[e.$=36]="$",e[e.Ampersand=38]="Ampersand",e[e.Asterisk=42]="Asterisk",e[e.At=64]="At",e[e.Backslash=92]="Backslash",e[e.Backtick=96]="Backtick",e[e.Bar=124]="Bar",e[e.Caret=94]="Caret",e[e.CloseBrace=125]="CloseBrace",e[e.CloseBracket=93]="CloseBracket",e[e.CloseParen=41]="CloseParen",e[e.Colon=58]="Colon",e[e.Comma=44]="Comma",e[e.Dot=46]="Dot",e[e.DoubleQuote=34]="DoubleQuote",e[e.Equals=61]="Equals",e[e.Exclamation=33]="Exclamation",e[e.GreaterThan=62]="GreaterThan",e[e.Hash=35]="Hash",e[e.LessThan=60]="LessThan",e[e.Minus=45]="Minus",e[e.OpenBrace=123]="OpenBrace",e[e.OpenBracket=91]="OpenBracket",e[e.OpenParen=40]="OpenParen",e[e.Percent=37]="Percent",e[e.Plus=43]="Plus",e[e.Question=63]="Question",e[e.Semicolon=59]="Semicolon",e[e.SingleQuote=39]="SingleQuote",e[e.Slash=47]="Slash",e[e.Tilde=126]="Tilde"})(ne||(ne={}))});function Fo(e,t){let n=void 0;return{text:e,path:t,getLineStarts:r,getLineAndCharacterOfPosition:i};function r(){return n=n??CDe(e)}function i(s){let o=r(),a=MDe(o,s);if(a<0)a=~a-1;return{line:a,character:s-o[a]}}}function CDe(e){let t=[],n=0,r=0;while(r>1),s=e[i];if(st)r=i-1;else return i}return~n}var ol=q(()=>{rc();mn()});var hw,Ta,re,Xi,Vn,gw,qr,Lr;var It=q(()=>{(function(e){e[e.None=0]="None",e[e.Resolved=2]="Resolved",e[e.Unknown=4]="Unknown",e[e.Ambiguous=8]="Ambiguous",e[e.NotFound=16]="NotFound",e[e.ResolutionFailed=28]="ResolutionFailed"})(hw||(hw={}));(function(e){e[e.None=0]="None",e[e.Model=2]="Model",e[e.Scalar=4]="Scalar",e[e.Operation=8]="Operation",e[e.Enum=16]="Enum",e[e.Interface=32]="Interface",e[e.Union=64]="Union",e[e.Alias=128]="Alias",e[e.Namespace=256]="Namespace",e[e.Decorator=512]="Decorator",e[e.TemplateParameter=1024]="TemplateParameter",e[e.Function=2048]="Function",e[e.FunctionParameter=4096]="FunctionParameter",e[e.Using=8192]="Using",e[e.DuplicateUsing=16384]="DuplicateUsing",e[e.SourceFile=32768]="SourceFile",e[e.Member=65536]="Member",e[e.Const=131072]="Const",e[e.Declaration=1048576]="Declaration",e[e.Implementation=2097152]="Implementation",e[e.LateBound=4194304]="LateBound",e[e.Internal=8388608]="Internal",e[e.ExportContainer=33024]="ExportContainer",e[e.MemberContainer=118]="MemberContainer"})(Ta||(Ta={}));(function(e){e[e.TypeSpecScript=0]="TypeSpecScript",e[e.JsSourceFile=1]="JsSourceFile",e[e.ImportStatement=2]="ImportStatement",e[e.Identifier=3]="Identifier",e[e.AugmentDecoratorStatement=4]="AugmentDecoratorStatement",e[e.DecoratorExpression=5]="DecoratorExpression",e[e.DirectiveExpression=6]="DirectiveExpression",e[e.MemberExpression=7]="MemberExpression",e[e.NamespaceStatement=8]="NamespaceStatement",e[e.UsingStatement=9]="UsingStatement",e[e.OperationStatement=10]="OperationStatement",e[e.OperationSignatureDeclaration=11]="OperationSignatureDeclaration",e[e.OperationSignatureReference=12]="OperationSignatureReference",e[e.ModelStatement=13]="ModelStatement",e[e.ModelExpression=14]="ModelExpression",e[e.ModelProperty=15]="ModelProperty",e[e.ModelSpreadProperty=16]="ModelSpreadProperty",e[e.ScalarStatement=17]="ScalarStatement",e[e.InterfaceStatement=18]="InterfaceStatement",e[e.UnionStatement=19]="UnionStatement",e[e.UnionVariant=20]="UnionVariant",e[e.EnumStatement=21]="EnumStatement",e[e.EnumMember=22]="EnumMember",e[e.EnumSpreadMember=23]="EnumSpreadMember",e[e.AliasStatement=24]="AliasStatement",e[e.DecoratorDeclarationStatement=25]="DecoratorDeclarationStatement",e[e.FunctionDeclarationStatement=26]="FunctionDeclarationStatement",e[e.FunctionParameter=27]="FunctionParameter",e[e.UnionExpression=28]="UnionExpression",e[e.IntersectionExpression=29]="IntersectionExpression",e[e.TupleExpression=30]="TupleExpression",e[e.ArrayExpression=31]="ArrayExpression",e[e.StringLiteral=32]="StringLiteral",e[e.NumericLiteral=33]="NumericLiteral",e[e.BooleanLiteral=34]="BooleanLiteral",e[e.StringTemplateExpression=35]="StringTemplateExpression",e[e.StringTemplateHead=36]="StringTemplateHead",e[e.StringTemplateMiddle=37]="StringTemplateMiddle",e[e.StringTemplateTail=38]="StringTemplateTail",e[e.StringTemplateSpan=39]="StringTemplateSpan",e[e.ExternKeyword=40]="ExternKeyword",e[e.VoidKeyword=41]="VoidKeyword",e[e.NeverKeyword=42]="NeverKeyword",e[e.UnknownKeyword=43]="UnknownKeyword",e[e.ValueOfExpression=44]="ValueOfExpression",e[e.TypeReference=45]="TypeReference",e[e.TemplateParameterDeclaration=46]="TemplateParameterDeclaration",e[e.EmptyStatement=47]="EmptyStatement",e[e.InvalidStatement=48]="InvalidStatement",e[e.LineComment=49]="LineComment",e[e.BlockComment=50]="BlockComment",e[e.Doc=51]="Doc",e[e.DocText=52]="DocText",e[e.DocParamTag=53]="DocParamTag",e[e.DocPropTag=54]="DocPropTag",e[e.DocReturnsTag=55]="DocReturnsTag",e[e.DocErrorsTag=56]="DocErrorsTag",e[e.DocTemplateTag=57]="DocTemplateTag",e[e.DocUnknownTag=58]="DocUnknownTag",e[e.Return=59]="Return",e[e.JsNamespaceDeclaration=60]="JsNamespaceDeclaration",e[e.TemplateArgument=61]="TemplateArgument",e[e.TypeOfExpression=62]="TypeOfExpression",e[e.ObjectLiteral=63]="ObjectLiteral",e[e.ObjectLiteralProperty=64]="ObjectLiteralProperty",e[e.ObjectLiteralSpreadProperty=65]="ObjectLiteralSpreadProperty",e[e.ArrayLiteral=66]="ArrayLiteral",e[e.ConstStatement=67]="ConstStatement",e[e.CallExpression=68]="CallExpression",e[e.ScalarConstructor=69]="ScalarConstructor",e[e.InternalKeyword=70]="InternalKeyword",e[e.AutoKeyword=71]="AutoKeyword",e[e.FunctionTypeExpression=72]="FunctionTypeExpression"})(re||(re={}));(function(e){e[e.None=0]="None",e[e.DescendantErrorsExamined=1]="DescendantErrorsExamined",e[e.ThisNodeHasError=2]="ThisNodeHasError",e[e.DescendantHasError=4]="DescendantHasError",e[e.Synthetic=8]="Synthetic"})(Xi||(Xi={}));(function(e){e[e.None=0]="None",e[e.Extern=2]="Extern",e[e.Internal=4]="Internal",e[e.Auto=8]="Auto",e[e.All=14]="All"})(Vn||(Vn={}));(function(e){e[e.TypeReference=0]="TypeReference",e[e.TemplateArgument=1]="TemplateArgument",e[e.Decorator=2]="Decorator",e[e.Function=3]="Function",e[e.Using=4]="Using",e[e.Declaration=5]="Declaration",e[e.ModelExpressionProperty=6]="ModelExpressionProperty",e[e.ModelStatementProperty=7]="ModelStatementProperty",e[e.ObjectLiteralProperty=8]="ObjectLiteralProperty",e[e.Other=9]="Other"})(gw||(gw={}));qr=Symbol.for("NoTarget");(function(e){e[e.NoRecursion=1]="NoRecursion"})(Lr||(Lr={}))});function BO(e){if(!("kind"in e)&&!("entityKind"in e)){if(!("declarations"in e))return e.node;if(e.flags&Ta.Using)e=e.symbolSource;return e.declarations[0]}else if("entityKind"in e)switch(e.entityKind){case"Type":return e.node;case"Value":return LDe(e)??e.type.node;case"MixedParameterConstraint":return e.node??e.type?.node??e.valueType?.node;case"Indeterminate":return e.type.node;default:return}else if("kind"in e&&typeof e.kind==="number")return e;else return e.node}function LDe(e){switch(e.valueKind){case"ObjectValue":case"ArrayValue":case"Function":return e.node;default:return}}function Ur(e,t={}){if(e===qr||e===void 0)return;if("file"in e)return e;let n=BO(e);return n?qDe(n,t):_9()}function _9(e=""){return{file:Fo("",e),pos:0,end:0,isSynthetic:!0}}function qDe(e,t){let n=e;while(n.parent!==void 0)n=n.parent;if(n.kind!==re.TypeSpecScript&&n.kind!==re.JsSourceFile)return _9(e.flags&Xi.Synthetic?void 0:"");if(t.locateId&&"id"in e&&e.id!==void 0)e=e.id;return{file:n.file,pos:e.pos,end:e.end}}function Qe(e,t,n){if(e)return;if(n){let r;try{r=Ur(n)}catch(i){}if(r){let i=r.file.getLineAndCharacterOfPosition(r.pos),s=r.file.path,o=i.line+1,a=i.character+1;t+=` -Occurred while compiling code in ${s} near line ${o}, column ${a}`}}throw Error(t)}function Ct(){let e=[];return{diagnostics:e,add:t,pipe:n,wrap:r,join:i};function t(s){e.push(s)}function n(s){let[o,a]=s;for(let l of a)e.push(l);return o}function r(s){return[s,e]}function i(s){let[o,a]=s;for(let l of a)e.push(l);return[o,e]}}function Ts(e){return e[0]}function al(e){return e}var vt=q(()=>{Yn();ol();It()});function Co(e,t){let n=Ur(t);if(n.isSynthetic)return{type:"synthetic"};return e.getSourceFileLocationContext(n.file)}var ic=q(()=>{vt()});var x9,w9,$lt;var Hg=q(()=>{ic();x9={"function-declarations":{description:"Allows use of function declarations without experimental warnings in project code."},"auto-decorators":{description:"Allows use of auto decorator declarations without experimental warnings in project code."},"type-info-provider":{description:"Enables the experimental `$provideTypeInfo` provider allowing libraries to contribute extra information about types to IDE hover and tooling (queried via `program.getTypeInfo`)."},"union-extends":{description:"Enables experimental union `extends` clauses in project code."}},w9=Object.keys(x9),$lt=new Set(w9)});var sc=q(()=>{Yn();mn();ol();It()});var zg=q(()=>{bo();vt();ol()});var VO=z(function(T9){Object.defineProperty(T9,"__esModule",{value:!0});var UDe=l1(),BDe=_1(),VDe=Zx(),KDe=e0(),D9=A1(),JDe=[UDe.default,BDe.default,(0,VDe.default)(),KDe.default,D9.metadataVocabulary,D9.contentVocabulary];T9.default=JDe});var S9=z(function(Vlt,HDe){HDe.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"http://json-schema.org/draft-07/schema#",title:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},default:!0}});var k9=z(function(Es,KO){Object.defineProperty(Es,"__esModule",{value:!0});Es.MissingRefError=Es.ValidationError=Es.CodeGen=Es.Name=Es.nil=Es.stringify=Es.str=Es._=Es.KeywordCxt=Es.Ajv=void 0;var zDe=lu(),WDe=VO(),QDe=ig(),E9=S9(),YDe=["/properties"],bw="http://json-schema.org/draft-07/schema";class Wg extends zDe.default{_addVocabularies(){if(super._addVocabularies(),WDe.default.forEach((e)=>this.addVocabulary(e)),this.opts.discriminator)this.addKeyword(QDe.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let e=this.opts.$data?this.$dataMetaSchema(E9,YDe):E9;this.addMetaSchema(e,bw,!1),this.refs["http://json-schema.org/schema"]=bw}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(bw)?bw:void 0)}}Es.Ajv=Wg;KO.exports=Es=Wg;KO.exports.Ajv=Wg;Object.defineProperty(Es,"__esModule",{value:!0});Es.default=Wg;var XDe=Cp();Object.defineProperty(Es,"KeywordCxt",{enumerable:!0,get:function(){return XDe.KeywordCxt}});var Sm=Et();Object.defineProperty(Es,"_",{enumerable:!0,get:function(){return Sm._}});Object.defineProperty(Es,"str",{enumerable:!0,get:function(){return Sm.str}});Object.defineProperty(Es,"stringify",{enumerable:!0,get:function(){return Sm.stringify}});Object.defineProperty(Es,"nil",{enumerable:!0,get:function(){return Sm.nil}});Object.defineProperty(Es,"Name",{enumerable:!0,get:function(){return Sm.Name}});Object.defineProperty(Es,"CodeGen",{enumerable:!0,get:function(){return Sm.CodeGen}});var ZDe=zf();Object.defineProperty(Es,"ValidationError",{enumerable:!0,get:function(){return ZDe.default}});var eTe=Mp();Object.defineProperty(Es,"MissingRefError",{enumerable:!0,get:function(){return eTe.default}})});var N9=q(()=>{Pf();C_();Cl();jl();Ml();Op();Pp();jf();kE();Ip();Rf()});function Em(e,t,n="value"){let r=rTe(e,t,n);return{file:e.file,pos:r?.range?.[0]??0,end:r?.range?.[1]??0}}function rTe(e,t,n="value"){let r=e.doc.contents;for(let i=0;ift(a)))return r.items.find((l)=>l.source&&l.source===s)??r.get(s,!0);else return r.get(s,!0);else{let a=ca(r.items,s);if(n==="key")return a?.key;else return a}else r=r.get(s,!0);else continue}return r??void 0}var Qg=q(()=>{bo();N9()});function iTe(e){if(e.startsWith(".")||!Kg(e))return"not-absolute";return"valid"}function Fu(e,t={strict:!0}){let n=new O9.Ajv({strict:t.strict,coerceTypes:t.coerceTypes,allowUnionTypes:!0,allErrors:!0});return n.addFormat("absolute-path",{type:"string",validate:(i)=>iTe(i)==="valid"}),{validate:r};function r(i,s){let o=n.compile(e),a=o(i);Qe(!a||!o.errors,"There should be errors reported if the schema is not valid.");let l=[];for(let c of o.errors??[]){let u=oTe(i,c,s);l.push(u)}return l}}function oTe(e,t,n){let r=aTe(t,n);if(t.params.format==="absolute-path"){let o=lTe(e,t);return tn({code:"config-path-absolute",format:{path:o},target:r})}let i=[`Schema violation: ${t.message} (${t.instancePath||"/"})`];for(let[o,a]of Object.entries(t.params).filter(([l])=>!sTe.has(l))){let l=Array.isArray(a)?[...new Set(a)].join(", "):a;i.push(` ${o}: ${l}`)}return{code:"invalid-schema",message:i.join(` -`),severity:"error",target:r}}function aTe(e,t){if(t===qr)return qr;if(!("kind"in t))return{file:t,pos:0,end:0};switch(t.kind){case"yaml-script":return Em(t,JO(e),"key");case"path-target":return Em(t.script,[...t.path,...JO(e)],"key")}}function JO(e){let t=cTe(e.instancePath);switch(e.keyword){case"additionalProperties":return[...t,e.params.additionalProperty];default:return t}}function lTe(e,t){let n=JO(t),r=e;for(let i of n)r=r[i];return r}function cTe(e){if(e==="")return[];if(e.charAt(0)!=="/")Qe(!1,`Invalid JSON pointer: "${e}"`);return e.substring(1).split(/\//).map(uTe)}function uTe(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}var O9,sTe;var km=q(()=>{Qg();vt();Yn();mn();It();O9=Ar(k9(),1);sTe=new Set(["type","errors"])});var pTe,Tct;var GO=q(()=>{sc();zg();km();It();pTe={type:"object",additionalProperties:!1,required:[],properties:{extends:{type:"array",nullable:!0,items:{type:"string"}},enable:{type:"object",required:[],nullable:!0,additionalProperties:{oneOf:[{type:"boolean"},{type:"object"}]}},disable:{type:"object",required:[],nullable:!0,additionalProperties:{type:"string"}}}},Tct=Fu(pTe)});var $9=q(()=>{Qg();zg()});var I9,Xg;var vw=q(()=>{I9={type:"object",additionalProperties:!0,required:[],properties:{"emitter-output-dir":{type:"string",nullable:!0}}},Xg={type:"object",additionalProperties:!1,properties:{extends:{type:"string",nullable:!0},kind:{type:"string",enum:["project"],nullable:!0},entrypoint:{type:"string",nullable:!0},features:{type:"array",nullable:!0,items:{type:"string"}},"environment-variables":{type:"object",nullable:!0,required:[],additionalProperties:{type:"object",properties:{default:{type:"string"}},required:["default"],additionalProperties:!1}},parameters:{type:"object",nullable:!0,required:[],additionalProperties:{type:"object",properties:{default:{type:"string"}},required:["default"],additionalProperties:!1}},"output-dir":{type:"string",nullable:!0},"warn-as-error":{type:"boolean",nullable:!0},trace:{oneOf:[{type:"string"},{type:"array",items:{type:"string"}}]},imports:{type:"array",nullable:!0,items:{type:"string"}},emit:{type:"array",nullable:!0,items:{type:"string"}},options:{type:"object",nullable:!0,required:[],additionalProperties:I9},linter:{type:"object",nullable:!0,required:[],additionalProperties:!1,properties:{extends:{type:"array",nullable:!0,items:{type:"string"}},enable:{type:"object",required:[],nullable:!0,additionalProperties:{oneOf:[{type:"boolean"},{type:"object"}]}},disable:{type:"object",required:[],nullable:!0,additionalProperties:{type:"string"}}}}}}});var mTe,Vct;var Nd=q(()=>{Hg();GO();Yn();mn();km();ol();It();sc();Gt();$9();zg();vw();mTe=pw({outputDir:"{cwd}/tsp-output",diagnostics:[]}),Vct=Fu(Xg)});var A9=q(()=>{vt();Yn();It()});var zO=q(()=>{vt();Yn();mn();It();sc();Gt();A9();Nd()});var R9=q(()=>{zO();Nd()});function j9(e,t,n,r){if(!C9(t,r))return gn(e.program,{code:"decorator-wrong-target",format:{decorator:n,to:t.kind},target:e.decoratorTarget}),!1;return!0}function F9(e,t,n){return Ts(e.checker.isTypeAssignableTo(t,e.checker.getStdType(n),t))}function C9(e,t){let n=hTe(e);if(n===void 0)return!1;return typeof t==="string"?t==="Any"||n===t:t.includes("Any")||t.includes(n)}function hTe(e){switch(typeof e){case"object":return e.kind;case"string":return"String";case"number":return"Number";case"boolean":return"Boolean";default:return}}function xw(e,t){if(typeof e!=="object")return[e,[]];return WO(e,t,[])}function WO(e,t,n){switch(e.kind){case"String":case"Boolean":case"Number":return[e.value,[]];case"EnumMember":return[e.value??e.name,[]];case"Tuple":{let i=[];for(let[s,o]of e.values.entries()){let[a,l]=WO(o,t,[...n,s.toString()]);if(l.length>0)return[void 0,l];i.push(a)}return[i,[]]}case"Model":{let i={};for(let[s,o]of e.properties.entries()){let[a,l]=WO(o.type,t,[...n,s.toString()]);if(l.length>0)return[void 0,l];i[s]=a}return[i,[]]}case"StringTemplate":if(e.stringValue)return[e.stringValue,[]];default:return[void 0,[n.length===0?tn({code:"invalid-value",format:{kind:e.kind},target:t}):tn({code:"invalid-value",messageId:"atPath",format:{kind:e.kind,path:n.join(".")},target:t})]]}}function bn(e,t,n){if(Qe("decorators"in t,"Type should have decorators"),t.decorators.filter((i)=>i.decorator===n&&i.node?.kind===re.DecoratorExpression&&i.node?.parent===t.node).length>1)return gn(e.program,{code:"duplicate-decorator",format:{decoratorName:"@"+n.name.slice(1)},target:e.decoratorTarget}),!1;return!0}function Nm(e,t,n,r){Qe("decorators"in t,"Type should have decorators");let i=[],s=t;while(s)i.push(...s.decorators),s=o(s);for(let a of i)if(a.decorator===n)return gn(e.program,{code:"decorator-conflict",format:{decoratorName:"@"+n.name.slice(1),otherDecoratorName:"@"+r.name.slice(1)},target:e.decoratorTarget}),!1;return!0;function o(a){if(a.kind==="Model")return a.baseModel;else if(a.kind==="Scalar")return a.baseScalar;else return}}function Om(e){if(e.kind==="ModelProperty")return e.type;else return e}var Od=q(()=>{vt();Yn();It()});function Pm(e){return"kind"in e&&e.kind==="Intrinsic"&&e.name==="void"}function ww(e){return"kind"in e&&e.kind==="Intrinsic"&&e.name==="never"}function Zg(e){return"kind"in e&&e.kind==="Intrinsic"&&e.name==="null"}function Mo(e){return e.entityKind==="Type"}function Sa(e){return e.entityKind==="Value"}function ks(e,t){let n=t??e;return Boolean(n.indexer&&n.indexer.key.name==="integer")}function QO(e,t){let n=t??e;return Boolean(n.indexer&&n.indexer.key.name==="string")}function Lo(e){let t=e;return t.templateMapper!==void 0&&!t.templateMapper.partial&&t.isFinished}function oc(e){if(e.node===void 0)return!1;let t=e.node;return t.templateParameters&&t.templateParameters.length>0&&e.templateMapper===void 0}function Dw(e){if(e.node===void 0)return!1;let t=e.node;return t.templateParameters&&t.templateParameters.length>0}var yr=q(()=>{It()});var YO=q(()=>{Od();yr()});function nn(e){for(let[t,n]of Object.entries(e)){let r=n;if(eb[t]!==void 0)r={...eb[t],...n};if(typeof r==="object"&&r!==null)Object.defineProperty(r,gTe,{value:!0,enumerable:!1,configurable:!1});eb[t]=r}}var eb,gTe;var Nr=q(()=>{eb={},gTe=Symbol.for("TypekitNamespace")});function L9(e){let t=Object.create(eb),n={get(i,s,o){if(s==="program")return e.program;if(s==="realm")return e;let a=Reflect.get(i,s,o);if(typeof a==="function"){let l=function(...c){return a.apply(r,c)};for(let c of Object.keys(a)){let u=a[c];if(typeof u==="function")l[c]=function(...p){return u.apply(r,p)};else Reflect.defineProperty(l,c,Reflect.getOwnPropertyDescriptor(a,c))}return l}if(typeof a==="object"&&a!==null&&!Reflect.getOwnPropertyDescriptor(i,s)?.get)return new Proxy(a,n);return a}},r=new Proxy(t,n);return r}var q9=q(()=>{Nr()});function bTe(e,t){let n=Symbol.for(e);if(!globalThis[n])globalThis[n]=t();return globalThis[n]}var XO,U9,zs;var Pd=q(()=>{vt();q9();U9=class U9{#e;#t;#n;constructor(e,t,n){this.#e=e,this.#t=n,this.#n=t}has(e){return this.#r(e).has(e)??!1}set(e,t){return this.#r(e).set(e,t),this}get(e){return this.#r(e).get(e)}delete(e){return this.#r(e).delete(e)}forEach(e,t){for(let n of this.entries())e.call(t,n[1],n[0],this);return this}get size(){return this.#n.size+this.#t.size}clear(){this.#n.clear()}*entries(){for(let e of this.#n)yield e;for(let e of this.#t)yield e;return}*values(){for(let e of this.entries())yield e[1];return}*keys(){for(let e of this.entries())yield e[0];return}[Symbol.iterator](){return this.entries()}[Symbol.toStringTag]="StateMap";#r(e){if(this.#e.hasType(e))return this.#n;return this.#t}};zs=class zs{#e;#t=new Set;#n=new WeakSet;#r=new Map;key;constructor(e,t){this.key=Symbol(t),this.#e=e}#i;get typekit(){return this.#i??=L9(this)}get program(){return this.#e}stateMap(e){let t=this.#r.get(e);if(!t)t=new Map,this.#r.set(e,t);return new U9(this,t,this.#e.stateMap(e))}clone(e){Qe(e,"Undefined type passed to clone");let t=this.#s(e);return this.typekit.type.finishType(t),t}remove(e){this.#n.add(e)}hasType(e){return this.#t.has(e)}addType(e){this.#t.add(e),XO.realmForType.set(e,this)}#s(e){let t=this.typekit.type.clone(e);return this.#t.add(t),XO.realmForType.set(t,this),t}get types(){return this.#t}static realmForType=bTe("Realm.realmForType",()=>new WeakMap)};XO=zs});function $m(e,t){for(let[n,r]of e.properties)if(!t(r))e.properties.delete(n)}function Pt(e){return Symbol.for(`TypeSpec.${e}`)}function Im(e,t){if(t.kind==="TemplateParameter")return e;return e.replace(/{(\w+)}/g,(n,r)=>t[r])}function ze(e){return[(i,s)=>i.stateMap(e).get(s),(i,s,o)=>i.stateMap(e).set(s,o),(i)=>i.stateMap(e)]}function hr(e){return[(r,i)=>r.stateSet(e).has(i),(r,i)=>r.stateSet(e).add(i)]}function qo(e){return typeof e==="object"&&e!==null&&Xr in e}function kn(e){if(new.target)throw Error("Numeric is not a constructor");let t=_Te(e),n=t.d===0,r={[Xr]:t,isInteger:n},i=vTe(r,V9);return Object.freeze(i)}function vTe(e,t){return Object.setPrototypeOf(e,t),e}function _Te(e){let t=e,n=0,r=1,i,s,o=void 0;if(t[0]==="-")n=1,r=-1;let a=t[n+1]?.toLowerCase();if(t[n]==="0"&&(a==="b"||a==="x"||a==="o"))try{i=BigInt(t.slice(n)),s=i.toString().length,o=0}catch{throw new ZO(`Invalid numeric value: ${e}`)}else{while(t[n]==="0")n++;let l=t.indexOf("."),c=l-n;if(l!==-1)s=c,t=t.replace(".","");let u;if((u=t.search(/e/i))>0){if(s===void 0)s=u-n;s+=Number(t.slice(u+1)),t=t.slice(n,u),o=Math.max(t.length-s,0)}else if(s===void 0)s=t.length-n,t=t.slice(n);else t=t.slice(n);let p=t.length;while(t[p-1]==="0"&&p>c)p--;if(n===c+1){let d=c;while(t[d]==="0"&&de.n===t.n&&e.e===t.e,Tw=(e,t)=>{if(e.st.s)return 1;let n=e.s;if(e.et.e)return 1*n;let r=e.n,i=t.n;if(e.di)return 1*n;return 0},V9;var ac=q(()=>{ZO=class ZO extends Error{code="InvalidNumeric"};Xr=Symbol.for("NumericInternalData");V9={toString:function(){return eP(this[Xr])},asNumber:function(){let e=Number(eP(this[Xr]));return B9(this[Xr],kn(e.toString())[Xr])?e:null},asBigInt:function(){if(!this.isInteger)return null;let{s:e,n:t}=this[Xr];return BigInt(e)*t},equals:function(e){return B9(this[Xr],e[Xr])},lt:function(e){return Tw(this[Xr],e[Xr])===-1},lte:function(e){return Tw(this[Xr],e[Xr])<=0},gt:function(e){return Tw(this[Xr],e[Xr])===1},gte:function(e){return Tw(this[Xr],e[Xr])>=0}};V9.toString=function(){return eP(this[Xr])}});function Am(e,t){let n=xTe(e,t);return qo(n)?n:void 0}function Rm(e,t){return Am(e,t)?.asNumber()??void 0}function jm(e,t){let n=wTe(e,t);return qo(n)?n:void 0}function Fm(e,t){return jm(e,t)?.asNumber()??void 0}function Cm(e,t){let n=DTe(e,t);return qo(n)?n:void 0}function Sw(e,t){return Cm(e,t)?.asNumber()??void 0}function Mm(e,t){let n=TTe(e,t);return qo(n)?n:void 0}function Ew(e,t){return Mm(e,t)?.asNumber()??void 0}function z9(e,t,n){e.stateMap(di.minLength).set(t,n)}function kw(e,t){return e.stateMap(di.minLength).get(t)}function tb(e,t){return kw(e,t)?.asNumber()??void 0}function W9(e,t,n){e.stateMap(di.maxLength).set(t,n)}function Nw(e,t){return e.stateMap(di.maxLength).get(t)}function nb(e,t){return Nw(e,t)?.asNumber()??void 0}function Q9(e,t,n){e.stateMap(di.minItems).set(t,n)}function Ow(e,t){return e.stateMap(di.minItems).get(t)}function rb(e,t){return Ow(e,t)?.asNumber()??void 0}function Y9(e,t,n){e.stateMap(di.maxItems).set(t,n)}function Pw(e,t){return e.stateMap(di.maxItems).get(t)}function ib(e,t){return Pw(e,t)?.asNumber()??void 0}function Lm(e,t,n,r){e.stateMap(X9(n)).set(t,r)}function X9(e){switch(e){case"self":return di.docs;case"returns":return di.returnDocs;case"errors":return di.errorsDocs}}function $w(e,t,n){return e.stateMap(X9(n)).get(t)}function Z9(e,t,n){e.stateMap(di.discriminator).set(t,n)}function $d(e,t){return e.stateMap(di.discriminator).get(t)}var di,xTe,K9,wTe,J9,DTe,G9,TTe,H9,e7,t7;var lc=q(()=>{ac();di={minValues:Pt("minValues"),maxValues:Pt("maxValues"),minValueExclusive:Pt("minValueExclusive"),maxValueExclusive:Pt("maxValueExclusive"),minLength:Pt("minLengthValues"),maxLength:Pt("maxLengthValues"),minItems:Pt("minItems"),maxItems:Pt("maxItems"),docs:Pt("docs"),returnDocs:Pt("returnsDocs"),errorsDocs:Pt("errorDocs"),discriminator:Pt("discriminator")},[xTe,K9]=ze(di.minValues);[wTe,J9]=ze(di.maxValues);[DTe,G9]=ze(di.minValueExclusive);[TTe,H9]=ze(di.maxValueExclusive);[e7,t7]=ze(Pt("discriminated"))});function r7(e,t){e.program.stateMap(ETe).set(t,!0)}var STe,n7=(e,t,n,r)=>{let i={key:n,value:r};e.program.stateMap(STe).set(t,i)},tP=(e,t,n,r)=>{Lm(e.program,t,n,{value:r,source:"comment"})},ETe;var nP=q(()=>{lc();STe=Symbol.for("TypeSpec.index"),ETe=Symbol.for("TypeSpec.Prototypes.getter")});function fi(e){function t(...n){return Ts(e.apply(this,n))}return t.withDiagnostics=e,t}var Cu=q(()=>{vt()});var i7=q(()=>{yr();Nr();nn({array:{is(e){return e.entityKind==="Type"&&e.kind==="Model"&&ks(e)&&e.properties.size===0},getElementType(e){if(!this.array.is(e))throw Error("Type is not an array.");return e.indexer.value},create(e){return this.model.create({name:"Array",properties:{},indexer:{key:this.builtin.integer,value:e}})}}})});var s7=q(()=>{Nr();nn({builtin:{get string(){return this.program.checker.getStdType("string")},get boolean(){return this.program.checker.getStdType("boolean")},get bytes(){return this.program.checker.getStdType("bytes")},get decimal(){return this.program.checker.getStdType("decimal")},get decimal128(){return this.program.checker.getStdType("decimal128")},get duration(){return this.program.checker.getStdType("duration")},get float(){return this.program.checker.getStdType("float")},get float32(){return this.program.checker.getStdType("float32")},get float64(){return this.program.checker.getStdType("float64")},get int8(){return this.program.checker.getStdType("int8")},get int16(){return this.program.checker.getStdType("int16")},get int32(){return this.program.checker.getStdType("int32")},get int64(){return this.program.checker.getStdType("int64")},get integer(){return this.program.checker.getStdType("integer")},get offsetDateTime(){return this.program.checker.getStdType("offsetDateTime")},get plainDate(){return this.program.checker.getStdType("plainDate")},get plainTime(){return this.program.checker.getStdType("plainTime")},get safeInt(){return this.program.checker.getStdType("safeint")},get uint8(){return this.program.checker.getStdType("uint8")},get uint16(){return this.program.checker.getStdType("uint16")},get uint32(){return this.program.checker.getStdType("uint32")},get uint64(){return this.program.checker.getStdType("uint64")},get url(){return this.program.checker.getStdType("url")},get utcDateTime(){return this.program.checker.getStdType("utcDateTime")},get numeric(){return this.program.checker.getStdType("numeric")}}})});var o7=q(()=>{Cu();Nr();nn({entity:{isAssignableTo:fi(function(e,t,n){return this.program.checker.isTypeAssignableTo(e,t,n??e)}),resolve:fi(function(e){return this.program.resolveTypeOrValueReference(e)})}})});function Ii(e){return il(e.entries())}function ll(e,t){return t?.map((n)=>{let[r,i]=Array.isArray(n)?[n[0],n.slice(1)]:[n,[]];return{decorator:r,args:i.map((s)=>({value:typeof s==="object"&&s!==null?s:e.literal.create(s),jsValue:s}))}})??[]}var Id=q(()=>{Gt()});var a7=q(()=>{Nr();Id();nn({enumMember:{create(e){let t=this.program.checker.createType({kind:"EnumMember",name:e.name,value:e.value,decorators:ll(this,e.decorators),enum:e.enum});return this.program.checker.finishType(t),t},is(e){return e.entityKind==="Type"&&e.kind==="EnumMember"}}})});var Gut;var sb=q(()=>{It();Gut=Pt("deprecated")});class Ws{#e=new Map;track(e,t){let n=this.#e.get(e);if(n===void 0)this.#e.set(e,[t]);else n.push(t)}*entries(){for(let[e,t]of this.#e.entries())if(t.length>1)yield[e,t]}}function Ad(e,t){return NTe(e,t)}function NTe(e,t){let n=e7(e,t),r=[];if(n===void 0)return[void 0,[]];let i=new Map,s;for(let o of t.variants.values()){if(typeof o.name!=="string"){if(s)r.push(tn({code:"invalid-discriminated-union-variant",messageId:"duplicateDefaultVariant",format:{unionName:t.name??"(anonymous)"},target:o}));else s=o.type;continue}if(i.set(o.name,o.type),n.envelope==="none"){if(o.type.kind!=="Model"){r.push(tn({code:"invalid-discriminated-union-variant",messageId:"noEnvelopeModel",format:{name:o.name.toString()},target:o}));continue}let a=o.type.properties.get(n.discriminatorPropertyName);if(a!==void 0){let l=ITe(a.type);if(l!==o.name)r.push(tn({code:"invalid-discriminated-union-variant",messageId:"discriminantMismatch",format:{name:o.name.toString(),discriminant:n.discriminatorPropertyName,propertyValue:l,variantName:String(o.name)},target:o.type}))}}}return[{type:t,options:n,variants:i,defaultVariant:s},r]}function Iw(e,t){let n=new Map,r=[],i=new Ws;function s(a){for(let l of a.derivedModels){if(Dw(l))continue;let c=$Te(l,t,r);if(c===void 0)if(l.derivedModels.length===0)r.push(tn({code:"missing-discriminator-property",format:{discriminator:t.propertyName},target:l}));else s(l);else for(let u of c)i.track(u,l),n.set(u,l)}}return s(e),OTe(i,r),[{kind:"legacy",propertyName:t.propertyName,variants:n},r]}function OTe(e,t){for(let[n,r]of e.entries())for(let i of r)t.push(tn({code:"invalid-discriminator-value",messageId:"duplicate",format:{discriminator:n},target:i}))}function PTe(e,t,n){let r=e.properties.get(t.propertyName);if(r&&r.optional)n.push(tn({code:"invalid-discriminator-value",messageId:"required",target:r}));return r}function $Te(e,t,n){let r=PTe(e,t,n);if(!r)return;let i=rP(r.type);if(i.length===0)n.push(tn({code:"invalid-discriminator-value",format:{kind:r.type.kind},target:r}));return i}function rP(e){switch(e.kind){case"String":return[e.value];case"Union":return[...e.variants.values()].flatMap((t)=>rP(t.type)).filter(Ed);case"EnumMember":return typeof e.value!=="number"?[e.value??e.name]:[];case"UnionVariant":return rP(e.type);default:return[]}}function ITe(e){switch(e.kind){case"String":return e.value;case"EnumMember":return typeof e.value!=="number"?e.value??e.name:void 0;default:return}}var qm=q(()=>{Gt();lc();Yn();yr()});function Aw(e){return ATe.get(e)}var ATe;var Rw=q(()=>{It();ATe=new WeakMap});function jw(e){return al({id:"triple-quote-indent",label:"Format triple-quote-indent",fix:(t)=>{let s=e.file.text.slice(e.pos+3,e.end-3),o=iP(s);if(o.length===0)return;if(o.length===1){let f=d(o[0]),m=" ".repeat(f);return t.replaceText(e,['"""',o[0],`${m}"""`].join(` +${u}`)}let l=typeof a==="string"?a:a(s.format),c={code:t?`${t}/${String(s.code)}`:s.code.toString(),severity:o.severity,message:l,target:s.target};if(o.url)Tn(c).url=o.url;if(s.codefixes)Tn(c).codefixes=s.codefixes;return c}function i(s,o){let a=r(o);s.reportDiagnostic(a)}return{diagnostics:e,createDiagnostic:r,reportDiagnostic:i}}var FO=q(()=>{Gt()});function M(e,...t){let n=(r)=>{let i=[e[0]];return t.forEach((s,o)=>{let a=r[s];if(a!==void 0)i.push(a);i.push(e[o+1])}),i.join("")};return n.keys=t,n}var h9,jDe,tn,gn;var Yn=q(()=>{FO();h9={"digit-expected":{severity:"error",messages:{default:"Digit expected."}},"hex-digit-expected":{severity:"error",messages:{default:"Hexadecimal digit expected."}},"binary-digit-expected":{severity:"error",messages:{default:"Binary digit expected."}},unterminated:{severity:"error",messages:{default:M`Unterminated ${"token"}.`}},"creating-file":{severity:"error",messages:{default:M`Error creating single file: ${"filename"}, ${"error"}`}},"invalid-escape-sequence":{severity:"error",messages:{default:"Invalid escape sequence."}},"no-new-line-start-triple-quote":{severity:"error",messages:{default:"String content in triple quotes must begin on a new line."}},"no-new-line-end-triple-quote":{severity:"error",messages:{default:"Closing triple quotes must begin on a new line."}},"triple-quote-indent":{severity:"error",description:"Report when a triple-quoted string has lines with less indentation as the closing triple quotes.",url:"https://typespec.io/docs/standard-library/diags/triple-quote-indent",messages:{default:"All lines in triple-quoted string lines must have the same indentation as closing triple quotes."}},"invalid-character":{severity:"error",messages:{default:"Invalid character."}},"file-not-found":{severity:"error",messages:{default:M`File ${"path"} not found.`}},"file-load":{severity:"error",messages:{default:M`${"message"}`}},"init-template-invalid-json":{severity:"error",messages:{default:M`Unable to parse ${"url"}: ${"message"}. Check that the template URL is correct.`}},"init-template-download-failed":{severity:"error",messages:{default:M`Failed to download template from ${"url"}: ${"message"}. Check that the template URL is correct.`}},"multiple-blockless-namespace":{severity:"error",messages:{default:"Cannot use multiple blockless namespaces."}},"blockless-namespace-first":{severity:"error",messages:{default:"Blockless namespaces can't follow other declarations.",topLevel:"Blockless namespace can only be top-level."}},"import-first":{severity:"error",messages:{default:"Imports must come prior to namespaces or other declarations.",topLevel:"Imports must be top-level and come prior to namespaces or other declarations."}},"duplicate-import":{severity:"warning",messages:{default:M`Duplicate import of "${"importPath"}"`}},"self-import":{severity:"warning",messages:{default:"A file cannot import itself."}},"token-expected":{severity:"error",messages:{default:M`${"token"} expected.`,unexpected:M`Unexpected token ${"token"}`,numericOrStringLiteral:"Expected numeric or string literal.",identifier:"Identifier expected.",expression:"Expression expected.",statement:"Statement expected.",property:"Property expected.",enumMember:"Enum member expected.",typeofTarget:"Typeof expects a value literal or value reference."}},"unknown-directive":{severity:"error",messages:{default:M`Unknown directive '#${"id"}'`}},"augment-decorator-target":{severity:"error",messages:{default:"Augment decorator first argument must be a type reference.",noInstance:"Cannot reference template instances.",noModelExpression:"Cannot augment model expressions.",noUnionExpression:"Cannot augment union expressions."}},"duplicate-decorator":{severity:"warning",messages:{default:M`Decorator ${"decoratorName"} cannot be used twice on the same declaration.`}},"decorator-conflict":{severity:"warning",messages:{default:M`Decorator ${"decoratorName"} cannot be used with decorator ${"otherDecoratorName"} on the same declaration.`}},"reserved-identifier":{severity:"error",messages:{default:"Keyword cannot be used as identifier.",future:M`${"name"} is a reserved keyword`}},"invalid-directive-location":{severity:"error",messages:{default:M`Cannot place directive on ${"nodeName"}.`}},"invalid-decorator-location":{severity:"error",messages:{default:M`Cannot decorate ${"nodeName"}.`}},"default-required":{severity:"error",messages:{default:"Required template parameters must not follow optional template parameters"}},"invalid-template-argument-name":{severity:"error",messages:{default:"Template parameter argument names must be valid, bare identifiers."}},"invalid-template-default":{severity:"error",messages:{default:"Template parameter defaults can only reference previously declared type parameters."}},"required-parameter-first":{severity:"error",messages:{default:"A required parameter cannot follow an optional parameter."}},"rest-parameter-last":{severity:"error",messages:{default:"A rest parameter must be last in a parameter list."}},"rest-parameter-required":{severity:"error",messages:{default:"A rest parameter cannot be optional."}},"doc-invalid-identifier":{severity:"warning",messages:{default:"Invalid identifier.",tag:"Invalid tag name. Use backticks around code if this was not meant to be a tag.",param:"Invalid parameter name.",prop:"Invalid property name.",templateParam:"Invalid template parameter name."}},"experimental-feature":{severity:"warning",messages:{default:M`${"feature"} is an experimental feature. It may change in the future or be removed. Use with caution and consider providing feedback on this feature.`,functionDeclarations:"Function declarations are an experimental feature that may change in the future. Use with caution and consider providing feedback to the TypeSpec team."}},"union-extends-disabled":{severity:"error",messages:{default:"Union `extends` clauses require the 'union-extends' feature to be enabled. Add 'union-extends' to the 'features' list in your tspconfig.yaml."}},"auto-decorator-disabled":{severity:"error",messages:{default:"Auto decorator declarations require the 'auto-decorators' feature to be enabled. Add 'auto-decorators' to the 'features' list in your tspconfig.yaml."}},"using-invalid-ref":{severity:"error",messages:{default:"Using must refer to a namespace"}},"invalid-type-ref":{severity:"error",messages:{default:"Invalid type reference",decorator:"Can't put a decorator in a type",function:"Can't use a function as a type"}},"invalid-template-args":{severity:"error",messages:{default:"Invalid template arguments.",notTemplate:"Can't pass template arguments to non-templated type",tooMany:"Too many template arguments provided.",unknownName:M`No parameter named '${"name"}' exists in the target template.`,positionalAfterNamed:"Positional template arguments cannot follow named arguments in the same argument list.",missing:M`Template argument '${"name"}' is required and not specified.`,specifiedAgain:M`Cannot specify template argument '${"name"}' again.`}},"intersect-non-model":{severity:"error",messages:{default:"Cannot intersect non-model types (including union types)."}},"intersect-invalid-index":{severity:"error",messages:{default:"Cannot intersect incompatible models.",never:"Cannot intersect a model that cannot hold properties.",array:"Cannot intersect an array model."}},"incompatible-indexer":{severity:"error",messages:{default:M`Property is incompatible with indexer:\n${"message"}`}},"no-array-properties":{severity:"error",messages:{default:"Array models cannot have any properties."}},"intersect-duplicate-property":{severity:"error",messages:{default:M`Intersection contains duplicate property definitions for ${"propName"}`}},"invalid-decorator":{severity:"error",messages:{default:M`${"id"} is not a decorator`}},"invalid-ref":{severity:"error",messages:{default:M`Cannot resolve ${"id"}`,identifier:M`Unknown identifier ${"id"}`,decorator:M`Unknown decorator @${"id"}`,inDecorator:M`Cannot resolve ${"id"} in decorator`,underNamespace:M`Namespace ${"namespace"} doesn't have member ${"id"}`,member:M`${"kind"} doesn't have member ${"id"}`,metaProperty:M`${"kind"} doesn't have meta property ${"id"}`,node:M`Cannot resolve '${"id"}' in node ${"nodeName"} since it has no members. Did you mean to use "::" instead of "."?`,internal:M`Symbol '${"id"}' is internal and can only be accessed from within its declaring package.`}},"duplicate-property":{severity:"error",messages:{default:M`Model already has a property named ${"propName"}`,withModel:M`Model ${"modelName"} already has a property named ${"propName"}`}},"override-property-mismatch":{severity:"error",messages:{default:M`Model has an inherited property named ${"propName"} of type ${"propType"} which cannot override type ${"parentType"}`,disallowedOptionalOverride:M`Model has a required inherited property named ${"propName"} which cannot be overridden as optional`}},"extend-scalar":{severity:"error",messages:{default:"Scalar must extend other scalars."}},"extend-model":{severity:"error",messages:{default:"Models must extend other models.",modelExpression:"Models cannot extend model expressions."}},"extend-union":{severity:"error",messages:{default:"Union `extends` must specify a model, scalar, enum, or union.",modelExpression:"Unions cannot extend model expressions."}},"is-model":{severity:"error",messages:{default:"Model `is` must specify another model.",modelExpression:"Model `is` cannot specify a model expression."}},"is-operation":{severity:"error",messages:{default:"Operation can only reuse the signature of another operation."}},"spread-model":{severity:"error",messages:{default:"Cannot spread properties of non-model type.",neverIndex:"Cannot spread type because it cannot hold properties.",selfSpread:"Cannot spread type within its own declaration."}},"unsupported-default":{severity:"error",messages:{default:M`Default must be have a value type but has type '${"type"}'.`}},"spread-object":{severity:"error",messages:{default:"Cannot spread properties of non-object type."}},"expect-value":{severity:"error",messages:{default:M`${"name"} refers to a type, but is being used as a value here.`,model:M`${"name"} refers to a model type, but is being used as a value here. Use #{} to create an object value.`,modelExpression:"Is a model expression type, but is being used as a value here. Use #{} to create an object value.",tuple:"Is a tuple type, but is being used as a value here. Use #[] to create an array value.",templateConstraint:M`${"name"} template parameter can be a type but is being used as a value here.`,functionReturn:M`Function returned a type, but a value was expected.`}},"non-callable":{severity:"error",messages:{default:M`Type ${"type"} is not is not callable.`,templateParameter:M`Template parameter '${"name"} extends ${"constraint"}' is not callable. Ensure it is constrained to a function value or callable type (scalar or scalar constructor).`}},"named-init-required":{severity:"error",messages:{default:M`Only scalar deriving from 'string', 'numeric' or 'boolean' can be instantited without a named constructor.`}},"invalid-primitive-init":{severity:"error",messages:{default:"Instantiating scalar deriving from 'string', 'numeric' or 'boolean' can only take a single argument.",invalidArg:M`Expected a single argument of type ${"expected"} but got ${"actual"}.`}},"ambiguous-scalar-type":{severity:"error",messages:{default:M`Value ${"value"} type is ambiguous between ${"types"}. To resolve be explicit when instantiating this value(e.g. '${"example"}(${"value"})').`}},unassignable:{severity:"error",messages:{default:M`Type '${"sourceType"}' is not assignable to type '${"targetType"}'`}},"property-unassignable":{severity:"error",messages:{default:M`Types of property '${"propName"}' are incompatible`}},"property-required":{severity:"error",messages:{default:M`Property '${"propName"}' is required in type '${"targetType"}' but here is optional.`}},"parameter-required":{severity:"error",messages:{default:M`Parameter '${"paramName"}' is required, but optional in the target function.`,missing:M`Parameter '${"paramName"}' is required, but missing in the target function.`,"rest-to-required":M`Parameter '${"paramName"}' is required and not satisfied by a rest parameter, as rest parameters are effectively optional.`}},"value-in-type":{severity:"error",messages:{default:"A value cannot be used as a type.",referenceTemplate:"Template parameter can be passed values but is used as a type.",noTemplateConstraint:"Template parameter has no constraint but a value is passed. Add `extends valueof unknown` to accept any value."}},"no-prop":{severity:"error",messages:{default:M`Property '${"propName"}' cannot be defined because model cannot hold properties.`}},"missing-index":{severity:"error",messages:{default:M`Index signature for type '${"indexType"}' is missing in type '${"sourceType"}'.`}},"missing-property":{severity:"error",messages:{default:M`Property '${"propertyName"}' is missing on type '${"sourceType"}' but required in '${"targetType"}'`}},"unexpected-property":{severity:"error",messages:{default:M`Object value may only specify known properties, and '${"propertyName"}' does not exist in type '${"type"}'.`}},"extends-interface":{severity:"error",messages:{default:"Interfaces can only extend other interfaces"}},"extends-interface-duplicate":{severity:"error",messages:{default:M`Interface extends cannot have duplicate members. The duplicate member is named ${"name"}`}},"interface-duplicate":{severity:"error",messages:{default:M`Interface already has a member named ${"name"}`}},"union-duplicate":{severity:"error",messages:{default:M`Union already has a variant named ${"name"}`}},"enum-member-duplicate":{severity:"error",messages:{default:M`Enum already has a member named ${"name"}`}},"constructor-duplicate":{severity:"error",messages:{default:M`A constructor already exists with name ${"name"}`}},"spread-enum":{severity:"error",messages:{default:"Cannot spread members of non-enum type."}},"decorator-fail":{severity:"error",messages:{default:M`Decorator ${"decoratorName"} failed!\n\n${"error"}`}},"rest-parameter-array":{severity:"error",messages:{default:"A rest parameter must be of an array type."}},"invalid-modifier":{severity:"error",messages:{default:M`Modifier '${"modifier"}' is invalid.`,"missing-required":M`Declaration of type '${"nodeKind"}' is missing required modifier '${"modifier"}'.`,"missing-required-one-of":M`Declaration of type '${"nodeKind"}' is missing one of the required modifiers: ${"modifiers"}.`,"mutually-exclusive":M`Modifiers '${"modifierA"}' and '${"modifierB"}' cannot be used together.`,"not-allowed":M`Modifier '${"modifier"}' cannot be used on declarations of type '${"nodeKind"}'.`}},"function-return":{severity:"error",messages:{default:"Function implementation returned an invalid result.","invalid-value":M`Function implementation returned invalid JS value '${"value"}'.`,unassignable:M`Implementation of '${"name"}' returned ${"entityKind"} '${"return"}', which is not assignable to the declared return type '${"type"}'.`}},"fn-in-union-expression":{severity:"error",messages:{default:"Function types in anonymous union expressions must be parenthesized."}},"missing-implementation":{severity:"error",messages:{default:"Extern declaration must have an implementation in JS file."}},"missing-extern-declaration":{severity:"error",description:"Report when a function is registered in $functions in a JS file but has no corresponding `extern fn` declaration in TypeSpec.",url:"https://typespec.io/docs/standard-library/diags/missing-extern-declaration",messages:{default:M`Function implementation "${"name"}" is exported in JS via $functions but has no corresponding 'extern fn' declaration in TypeSpec.`}},"overload-same-parent":{severity:"error",messages:{default:"Overload must be in the same interface or namespace."}},shadow:{severity:"warning",messages:{default:M`Shadowing parent template parameter with the same name "${"name"}"`}},"invalid-deprecation-argument":{severity:"error",messages:{default:M`#deprecation directive is expecting a string literal as the message but got a "${"kind"}"`,missing:"#deprecation directive is expecting a message argument but none was provided."}},"duplicate-deprecation":{severity:"warning",messages:{default:"The #deprecated directive cannot be used more than once on the same declaration."}},"config-invalid-argument":{severity:"error",messages:{default:M`Argument "${"name"}" is not defined as a parameter in the config.`}},"config-circular-variable":{severity:"error",messages:{default:M`There is a circular reference to variable "${"name"}" in the cli configuration or arguments.`}},"config-path-absolute":{severity:"error",messages:{default:M`Path "${"path"}" cannot be relative. Use {cwd} or {project-root} to specify what the path should be relative to.`}},"config-invalid-name":{severity:"error",messages:{default:M`The configuration name "${"name"}" is invalid because it contains a dot ("."). Using a dot will conflict with using nested configuration values.`}},"path-unix-style":{severity:"warning",messages:{default:M`Path should use unix style separators. Use "/" instead of "\\".`}},"config-path-not-found":{severity:"error",messages:{default:M`No configuration file found at config path "${"path"}".`}},"config-project-kind-filename":{severity:"error",messages:{default:M`Config with \`kind: project\` must be named "tspconfig.yaml". Found in "${"filename"}".`}},"config-project-only-option":{severity:"error",messages:{default:M`Property "${"option"}" can only be used in a project config (with \`kind: project\`).`}},"config-unknown-feature":{severity:"error",messages:{default:M`Unknown compiler feature "${"feature"}".`}},"config-project-not-as-cli-config":{severity:"error",messages:{default:"`--config` cannot point to a project config (with `kind: project`). Use a non-project build config that `extends` the project config instead."}},"dynamic-import":{severity:"error",messages:{default:"Dynamically generated TypeSpec cannot have imports"}},"invalid-import":{severity:"error",messages:{default:"Import paths must reference either a directory, a .tsp file, or .js file"}},"invalid-main":{severity:"error",messages:{default:"Main file must either be a .tsp file or a .js file."}},"import-not-found":{severity:"error",messages:{default:M`Couldn't resolve import "${"path"}"`}},"library-invalid":{severity:"error",messages:{default:M`Library "${"path"}" is invalid: ${"message"}`}},"incompatible-library":{severity:"warning",messages:{default:M`Multiple versions of "${"name"}" library were loaded:\n${"versionMap"}`}},"compiler-version-mismatch":{severity:"warning",messages:{default:M`Current TypeSpec compiler conflicts with local version of @typespec/compiler referenced in ${"basedir"}. \nIf this warning occurs on the command line, try running \`typespec\` with a working directory of ${"basedir"}. \nIf this warning occurs in the IDE, try configuring the \`tsp-server\` path to ${"betterTypeSpecServerPath"}.\n Expected: ${"expected"}\n Resolved: ${"actual"}`}},"duplicate-symbol":{severity:"error",messages:{default:M`Duplicate name: "${"name"}"`}},"duplicate-suppression":{severity:"warning",messages:{default:M`Diagnostic "${"code"}" is already suppressed on this node.`}},"ambiguous-short-name":{severity:"warning",messages:{default:M`Short name "${"shortName"}" is ambiguous. It could refer to ${"candidates"}. Use the full name instead.`}},"decorator-decl-target":{severity:"error",messages:{default:"dec must have at least one parameter.",required:"dec first parameter must be required."}},"mixed-string-template":{severity:"error",messages:{default:"String template is interpolating values and types. It must be either all values to produce a string value or or all types for string template type."}},"non-literal-string-template":{severity:"error",messages:{default:"Value interpolated in this string template cannot be converted to a string. Only literal types can be automatically interpolated."}},"ambiguous-symbol":{severity:"error",messages:{default:M`"${"name"}" is an ambiguous name between ${"duplicateNames"}. Try using fully qualified name instead: ${"duplicateNames"}`}},"duplicate-using":{severity:"error",messages:{default:M`duplicate using of "${"usingName"}" namespace`}},"on-validate-fail":{severity:"error",messages:{default:M`onValidate failed with errors. ${"error"}`}},"emitter-not-found":{severity:"error",messages:{default:M`Emitter "${"emitterPackage"}" not found. Make sure to install it with \`npm install ${"emitterPackage"}\`.`}},"invalid-emitter":{severity:"error",messages:{default:M`Requested emitter package ${"emitterPackage"} does not provide an "$onEmit" function.`}},"js-error":{severity:"error",messages:{default:M`Failed to load ${"specifier"} due to the following JS error: ${"error"}`}},"missing-import":{severity:"error",messages:{default:M`Emitter '${"emitterName"}' requires '${"requiredImport"}' to be imported. Add 'import "${"requiredImport"}".`}},"invalid-rule-ref":{severity:"error",messages:{default:M`Reference "${"ref"}" is not a valid reference to a rule or ruleset. It must be in the following format: ":"`}},"unknown-rule":{severity:"error",messages:{default:M`Rule "${"ruleName"}" is not found in library "${"libraryName"}"`}},"unknown-rule-set":{severity:"error",messages:{default:M`Rule set "${"ruleSetName"}" is not found in library "${"libraryName"}"`}},"rule-enabled-disabled":{severity:"error",messages:{default:M`Rule "${"ruleName"}" has been enabled and disabled in the same ruleset.`}},"invalid-rule-options":{severity:"error",messages:{default:M`Invalid options for rule "${"ruleName"}": ${"details"}`}},"circular-ruleset-file":{severity:"error",messages:{default:M`Linter ruleset file "${"path"}" is extending itself, either directly or indirectly.`}},"ruleset-file-in-library":{severity:"error",messages:{default:M`Ruleset "${"ruleSetName"}" is defined in a library and cannot extend the ruleset file "${"ref"}". "file:" references can only be used in "tspconfig.yaml" or in another ruleset file.`}},"format-failed":{severity:"error",messages:{default:M`File '${"file"}' failed to format. ${"details"}`}},"invalid-pattern-regex":{severity:"warning",messages:{default:"@pattern decorator expects a valid regular expression pattern."}},"decorator-wrong-target":{severity:"error",messages:{default:M`Cannot apply ${"decorator"} decorator to ${"to"}`,withExpected:M`Cannot apply ${"decorator"} decorator to ${"to"} since it is not assignable to ${"expected"}`}},"invalid-argument":{severity:"error",messages:{default:M`Argument of type '${"value"}' is not assignable to parameter of type '${"expected"}'`}},"invalid-argument-count":{severity:"error",messages:{default:M`Expected ${"expected"} arguments, but got ${"actual"}.`,atLeast:M`Expected at least ${"expected"} arguments, but got ${"actual"}.`}},"known-values-invalid-enum":{severity:"error",messages:{default:M`Enum cannot be used on this type. Member ${"member"} is not assignable to type ${"type"}.`}},"invalid-value":{severity:"error",messages:{default:M`Type '${"kind"}' is not a value type.`,atPath:M`Type '${"kind"}' of '${"path"}' is not a value type.`}},deprecated:{severity:"warning",messages:{default:M`Deprecated: ${"message"}`}},"no-optional-key":{severity:"error",messages:{default:M`Property '${"propertyName"}' marked as key cannot be optional.`}},"invalid-discriminated-union":{severity:"error",messages:{default:"",noAnonVariants:"Unions with anonymous variants cannot be discriminated"}},"invalid-discriminated-union-variant":{severity:"error",messages:{default:M`Union variant "${"name"}" must be a model type.`,noEnvelopeModel:M`Union variant "${"name"}" must be a model type when the union has envelope: none.`,discriminantMismatch:M`Variant "${"name"}" explicitly defines the discriminator property "${"discriminant"}" but the value "${"propertyValue"}" do not match the variant name "${"variantName"}".`,duplicateDefaultVariant:M`Discriminated union ${"unionName"} only allow a single default variant(Without a variant name).`,noDiscriminant:M`Variant "${"name"}" type is missing the discriminant property "${"discriminant"}".`,wrongDiscriminantType:M`Variant "${"name"}" type's discriminant property "${"discriminant"}" must be a string literal or string enum member.`}},"missing-discriminator-property":{severity:"error",messages:{default:M`Each derived model of a discriminated model type should have set the discriminator property("${"discriminator"}") or have a derived model which has. Add \`${"discriminator"}: ""\``}},"invalid-discriminator-value":{severity:"error",messages:{default:M`Discriminator value should be a string, union of string or string enum but was ${"kind"}.`,required:"The discriminator property must be a required property.",duplicate:M`Discriminator value "${"discriminator"}" is already used in another variant.`}},"invalid-encode":{severity:"error",messages:{default:"Invalid encoding",wrongType:M`Encoding '${"encoding"}' cannot be used on type '${"type"}'. Expected: ${"expected"}.`,wrongEncodingType:M`Encoding '${"encoding"}' on type '${"type"}' is expected to be serialized as '${"expected"}' but got '${"actual"}'.`,wrongNumericEncodingType:M`Encoding '${"encoding"}' on type '${"type"}' is expected to be serialized as '${"expected"}' but got '${"actual"}'. Set '@encode' 2nd parameter to be of type ${"expected"}. e.g. '@encode("${"encoding"}", int32)'`,firstArg:'First argument of "@encode" must be the encoding name or the string type when encoding numeric or boolean types.'}},"invalid-mime-type":{severity:"error",messages:{default:M`Invalid mime type '${"mimeType"}'`}},"no-mime-type-suffix":{severity:"error",messages:{default:M`Cannot use mime type '${"mimeType"}' with suffix '${"suffix"}'. Use a simple mime \`type/subtype\` instead.`}},"encoded-name-conflict":{severity:"error",messages:{default:M`Encoded name '${"name"}' conflicts with existing member name for mime type '${"mimeType"}'`,duplicate:M`Same encoded name '${"name"}' is used for 2 members '${"mimeType"}'`}},"incompatible-paging-props":{severity:"error",messages:{default:M`Paging property has multiple types: '${"kinds"}'`}},"invalid-paging-prop":{severity:"error",messages:{default:M`Paging property '${"kind"}' is not valid in this context.`,input:M`Paging property '${"kind"}' cannot be used in the parameters of an operation.`,output:M`Paging property '${"kind"}' cannot be used in the return type of an operation.`}},"duplicate-paging-prop":{severity:"error",messages:{default:M`Duplicate property paging '${"kind"}' for operation ${"operationName"}.`}},"missing-paging-items":{severity:"error",messages:{default:M`Paged operation '${"operationName"}' return type must have a property annotated with @pageItems.`}},"service-decorator-duplicate":{severity:"error",messages:{default:"@service can only be set once per TypeSpec document."}},"list-type-not-model":{severity:"error",messages:{default:"@list decorator's parameter must be a model type."}},"invalid-range":{severity:"error",messages:{default:M`Range "${"start"}..${"end"}" is invalid.`}},"add-response":{severity:"error",messages:{default:"Cannot add a response to anything except an operation statement."}},"add-parameter":{severity:"error",messages:{default:"Cannot add a parameter to anything except an operation statement."}},"add-model-property":{severity:"error",messages:{default:"Cannot add a model property to anything except a model statement."}},"add-model-property-fail":{severity:"error",messages:{default:M`Could not add property/parameter "${"propertyName"}" of type "${"propertyTypeName"}"`}},"add-response-type":{severity:"error",messages:{default:M`Could not add response type "${"responseTypeName"}" to operation ${"operationName"}"`}},"circular-base-type":{severity:"error",messages:{default:M`Type '${"typeName"}' recursively references itself as a base type.`}},"circular-constraint":{severity:"error",messages:{default:M`Type parameter '${"typeName"}' has a circular constraint.`}},"circular-op-signature":{severity:"error",messages:{default:M`Operation '${"typeName"}' recursively references itself.`}},"circular-alias-type":{severity:"error",messages:{default:M`Alias type '${"typeName"}' recursively references itself.`}},"circular-const":{severity:"error",messages:{default:M`const '${"name"}' recursively references itself.`}},"circular-prop":{severity:"error",messages:{default:M`Property '${"propName"}' recursively references itself.`}},"conflict-marker":{severity:"error",messages:{default:"Conflict marker encountered."}},"visibility-sealed":{severity:"error",messages:{default:M`Visibility of property '${"propName"}' is sealed and cannot be changed.`}},"default-visibility-not-member":{severity:"error",messages:{default:"The default visibility modifiers of a class must be members of the class enum."}},"operation-visibility-constraint-empty":{severity:"error",messages:{default:"Operation visibility constraints with no arguments are not allowed.",returnType:"Return type visibility constraints with no arguments are not allowed.",parameter:"Parameter visibility constraints with no arguments are not allowed. To disable effective PATCH optionality, use @patch(#{ implicitOptionality: false }) instead."}},"no-compatible-vs-installed":{severity:"error",messages:{default:"No compatible version of Visual Studio found."}},"vs-extension-windows-only":{severity:"error",messages:{default:"Visual Studio extension is not supported on non-Windows."}},"vsix-download-failed":{severity:"error",messages:{default:M`Failed to download extension "${"id"}" from the marketplace: ${"message"}.`}},"vscode-in-path":{severity:"error",messages:{default:"Couldn't find VS Code 'code' command in PATH. Make sure you have the VS Code executable added to the system PATH.",osx:`Couldn't find VS Code 'code' command in PATH. Make sure you have the VS Code executable added to the system PATH. +See instruction for Mac OS here https://code.visualstudio.com/docs/setup/mac`}},"invalid-option-flag":{severity:"error",messages:{default:M`The --option parameter value "${"value"}" must be in the format: .some-options=value`}},"cli-command-deprecated":{severity:"warning",messages:{default:M`The "${"command"}" command is deprecated. Install and manage the extension directly from the marketplace instead. See ${"docsUrl"} for details.`}}},jDe=new Set(Object.keys(h9)),{createDiagnostic:tn,reportDiagnostic:gn}=dw(h9)});var g9;var b9=q(()=>{g9=[160,887,890,895,900,906,908,908,910,929,931,1327,1329,1366,1369,1418,1421,1423,1425,1479,1488,1514,1519,1524,1536,1805,1807,1866,1869,1969,1984,2042,2045,2093,2096,2110,2112,2139,2142,2142,2144,2154,2160,2190,2192,2193,2200,2435,2437,2444,2447,2448,2451,2472,2474,2480,2482,2482,2486,2489,2492,2500,2503,2504,2507,2510,2519,2519,2524,2525,2527,2531,2534,2558,2561,2563,2565,2570,2575,2576,2579,2600,2602,2608,2610,2611,2613,2614,2616,2617,2620,2620,2622,2626,2631,2632,2635,2637,2641,2641,2649,2652,2654,2654,2662,2678,2689,2691,2693,2701,2703,2705,2707,2728,2730,2736,2738,2739,2741,2745,2748,2757,2759,2761,2763,2765,2768,2768,2784,2787,2790,2801,2809,2815,2817,2819,2821,2828,2831,2832,2835,2856,2858,2864,2866,2867,2869,2873,2876,2884,2887,2888,2891,2893,2901,2903,2908,2909,2911,2915,2918,2935,2946,2947,2949,2954,2958,2960,2962,2965,2969,2970,2972,2972,2974,2975,2979,2980,2984,2986,2990,3001,3006,3010,3014,3016,3018,3021,3024,3024,3031,3031,3046,3066,3072,3084,3086,3088,3090,3112,3114,3129,3132,3140,3142,3144,3146,3149,3157,3158,3160,3162,3165,3165,3168,3171,3174,3183,3191,3212,3214,3216,3218,3240,3242,3251,3253,3257,3260,3268,3270,3272,3274,3277,3285,3286,3293,3294,3296,3299,3302,3311,3313,3315,3328,3340,3342,3344,3346,3396,3398,3400,3402,3407,3412,3427,3430,3455,3457,3459,3461,3478,3482,3505,3507,3515,3517,3517,3520,3526,3530,3530,3535,3540,3542,3542,3544,3551,3558,3567,3570,3572,3585,3642,3647,3675,3713,3714,3716,3716,3718,3722,3724,3747,3749,3749,3751,3773,3776,3780,3782,3782,3784,3790,3792,3801,3804,3807,3840,3911,3913,3948,3953,3991,3993,4028,4030,4044,4046,4058,4096,4293,4295,4295,4301,4301,4304,4680,4682,4685,4688,4694,4696,4696,4698,4701,4704,4744,4746,4749,4752,4784,4786,4789,4792,4798,4800,4800,4802,4805,4808,4822,4824,4880,4882,4885,4888,4954,4957,4988,4992,5017,5024,5109,5112,5117,5120,5788,5792,5880,5888,5909,5919,5942,5952,5971,5984,5996,5998,6000,6002,6003,6016,6109,6112,6121,6128,6137,6144,6169,6176,6264,6272,6314,6320,6389,6400,6430,6432,6443,6448,6459,6464,6464,6468,6509,6512,6516,6528,6571,6576,6601,6608,6618,6622,6683,6686,6750,6752,6780,6783,6793,6800,6809,6816,6829,6832,6862,6912,6988,6992,7038,7040,7155,7164,7223,7227,7241,7245,7304,7312,7354,7357,7367,7376,7418,7424,7957,7960,7965,7968,8005,8008,8013,8016,8023,8025,8025,8027,8027,8029,8029,8031,8061,8064,8116,8118,8132,8134,8147,8150,8155,8157,8175,8178,8180,8182,8190,8192,8205,8208,8231,8234,8292,8294,8305,8308,8334,8336,8348,8352,8384,8400,8432,8448,8587,8592,9254,9280,9290,9312,11123,11126,11157,11159,11507,11513,11557,11559,11559,11565,11565,11568,11623,11631,11632,11647,11670,11680,11686,11688,11694,11696,11702,11704,11710,11712,11718,11720,11726,11728,11734,11736,11742,11744,11869,11904,11929,11931,12019,12032,12245,12272,12283,12288,12351,12353,12438,12441,12543,12549,12591,12593,12686,12688,12771,12784,12830,12832,42124,42128,42182,42192,42539,42560,42743,42752,42954,42960,42961,42963,42963,42965,42969,42994,43052,43056,43065,43072,43127,43136,43205,43214,43225,43232,43347,43359,43388,43392,43469,43471,43481,43486,43518,43520,43574,43584,43597,43600,43609,43612,43714,43739,43766,43777,43782,43785,43790,43793,43798,43808,43814,43816,43822,43824,43883,43888,44013,44016,44025,44032,55203,55216,55238,55243,55291,63744,64109,64112,64217,64256,64262,64275,64279,64285,64310,64312,64316,64318,64318,64320,64321,64323,64324,64326,64450,64467,64911,64914,64967,64975,64975,65008,65049,65056,65106,65108,65126,65128,65131,65136,65140,65142,65276,65279,65279,65281,65470,65474,65479,65482,65487,65490,65495,65498,65500,65504,65510,65512,65518,65529,65532,65536,65547,65549,65574,65576,65594,65596,65597,65599,65613,65616,65629,65664,65786,65792,65794,65799,65843,65847,65934,65936,65948,65952,65952,66000,66045,66176,66204,66208,66256,66272,66299,66304,66339,66349,66378,66384,66426,66432,66461,66463,66499,66504,66517,66560,66717,66720,66729,66736,66771,66776,66811,66816,66855,66864,66915,66927,66938,66940,66954,66956,66962,66964,66965,66967,66977,66979,66993,66995,67001,67003,67004,67072,67382,67392,67413,67424,67431,67456,67461,67463,67504,67506,67514,67584,67589,67592,67592,67594,67637,67639,67640,67644,67644,67647,67669,67671,67742,67751,67759,67808,67826,67828,67829,67835,67867,67871,67897,67903,67903,67968,68023,68028,68047,68050,68099,68101,68102,68108,68115,68117,68119,68121,68149,68152,68154,68159,68168,68176,68184,68192,68255,68288,68326,68331,68342,68352,68405,68409,68437,68440,68466,68472,68497,68505,68508,68521,68527,68608,68680,68736,68786,68800,68850,68858,68903,68912,68921,69216,69246,69248,69289,69291,69293,69296,69297,69373,69415,69424,69465,69488,69513,69552,69579,69600,69622,69632,69709,69714,69749,69759,69826,69837,69837,69840,69864,69872,69881,69888,69940,69942,69959,69968,70006,70016,70111,70113,70132,70144,70161,70163,70209,70272,70278,70280,70280,70282,70285,70287,70301,70303,70313,70320,70378,70384,70393,70400,70403,70405,70412,70415,70416,70419,70440,70442,70448,70450,70451,70453,70457,70459,70468,70471,70472,70475,70477,70480,70480,70487,70487,70493,70499,70502,70508,70512,70516,70656,70747,70749,70753,70784,70855,70864,70873,71040,71093,71096,71133,71168,71236,71248,71257,71264,71276,71296,71353,71360,71369,71424,71450,71453,71467,71472,71494,71680,71739,71840,71922,71935,71942,71945,71945,71948,71955,71957,71958,71960,71989,71991,71992,71995,72006,72016,72025,72096,72103,72106,72151,72154,72164,72192,72263,72272,72354,72368,72440,72448,72457,72704,72712,72714,72758,72760,72773,72784,72812,72816,72847,72850,72871,72873,72886,72960,72966,72968,72969,72971,73014,73018,73018,73020,73021,73023,73031,73040,73049,73056,73061,73063,73064,73066,73102,73104,73105,73107,73112,73120,73129,73440,73464,73472,73488,73490,73530,73534,73561,73648,73648,73664,73713,73727,74649,74752,74862,74864,74868,74880,75075,77712,77810,77824,78933,82944,83526,92160,92728,92736,92766,92768,92777,92782,92862,92864,92873,92880,92909,92912,92917,92928,92997,93008,93017,93019,93025,93027,93047,93053,93071,93760,93850,93952,94026,94031,94087,94095,94111,94176,94180,94192,94193,94208,100343,100352,101589,101632,101640,110576,110579,110581,110587,110589,110590,110592,110882,110898,110898,110928,110930,110933,110933,110948,110951,110960,111355,113664,113770,113776,113788,113792,113800,113808,113817,113820,113827,118528,118573,118576,118598,118608,118723,118784,119029,119040,119078,119081,119274,119296,119365,119488,119507,119520,119539,119552,119638,119648,119672,119808,119892,119894,119964,119966,119967,119970,119970,119973,119974,119977,119980,119982,119993,119995,119995,119997,120003,120005,120069,120071,120074,120077,120084,120086,120092,120094,120121,120123,120126,120128,120132,120134,120134,120138,120144,120146,120485,120488,120779,120782,121483,121499,121503,121505,121519,122624,122654,122661,122666,122880,122886,122888,122904,122907,122913,122915,122916,122918,122922,122928,122989,123023,123023,123136,123180,123184,123197,123200,123209,123214,123215,123536,123566,123584,123641,123647,123647,124112,124153,124896,124902,124904,124907,124909,124910,124912,124926,124928,125124,125127,125142,125184,125259,125264,125273,125278,125279,126065,126132,126209,126269,126464,126467,126469,126495,126497,126498,126500,126500,126503,126503,126505,126514,126516,126519,126521,126521,126523,126523,126530,126530,126535,126535,126537,126537,126539,126539,126541,126543,126545,126546,126548,126548,126551,126551,126553,126553,126555,126555,126557,126557,126559,126559,126561,126562,126564,126564,126567,126570,126572,126578,126580,126583,126585,126588,126590,126590,126592,126601,126603,126619,126625,126627,126629,126633,126635,126651,126704,126705,126976,127019,127024,127123,127136,127150,127153,127167,127169,127183,127185,127221,127232,127405,127462,127490,127504,127547,127552,127560,127568,127569,127584,127589,127744,128727,128732,128748,128752,128764,128768,128886,128891,128985,128992,129003,129008,129008,129024,129035,129040,129095,129104,129113,129120,129159,129168,129197,129200,129201,129280,129619,129632,129645,129648,129660,129664,129672,129680,129725,129727,129733,129742,129755,129760,129768,129776,129784,129792,129938,129940,129994,130032,130041,131072,173791,173824,177977,177984,178205,178208,183969,183984,191456,194560,195101,196608,201546,201552,205743,917505,917505,917536,917631,917760,917999]});function Jg(e){return e>=65536?2:1}function sl(e){return e===ne.LineFeed||e===ne.CarriageReturn}function FDe(e){return e===ne.Space||e===ne.Tab||e===ne.VerticalTab||e===ne.FormFeed}function CO(e){return e===ne.NextLine||e===ne.LeftToRightMark||e===ne.RightToLeftMark||e===ne.LineSeparator||e===ne.ParagraphSeparator}function Od(e){return Fu(e)||sl(e)}function Fu(e){return FDe(e)||e>ne.MaxAscii&&CO(e)}function v9(e){let t=0,n=e.length-1;if(!Od(e.charCodeAt(t))&&!Od(e.charCodeAt(n)))return e;while(Od(e.charCodeAt(t)))t++;while(Od(e.charCodeAt(n)))n--;return e.substring(t,n+1)}function Sm(e){return e>=ne._0&&e<=ne._9}function MO(e){return Sm(e)||e>=ne.A&&e<=ne.F||e>=ne.a&&e<=ne.f}function LO(e){return e===ne._0||e===ne._1}function qO(e){return e>=ne.a&&e<=ne.z}function fw(e){return e>=ne.A&&e<=ne.Z||e>=ne.a&&e<=ne.z||e===ne.$||e===ne._}function mw(e){return e>=ne.A&&e<=ne.Z||e>=ne.a&&e<=ne.z||e>=ne._0&&e<=ne._9||e===ne.$||e===ne._}function yw(e){return fw(e)||e>ne.MaxAscii&&Em(e)}function Gg(e){return mw(e)||e>ne.MaxAscii&&Em(e)}function Em(e){return CDe(e,g9)}function CDe(e,t){let n=0,r=t.length,i;while(n+1{b9();(function(e){e[e.Null=0]="Null",e[e.MaxAscii=127]="MaxAscii",e[e.ByteOrderMark=65279]="ByteOrderMark",e[e.LineFeed=10]="LineFeed",e[e.CarriageReturn=13]="CarriageReturn",e[e.Space=32]="Space",e[e.Tab=9]="Tab",e[e.VerticalTab=11]="VerticalTab",e[e.FormFeed=12]="FormFeed",e[e.NextLine=133]="NextLine",e[e.LeftToRightMark=8206]="LeftToRightMark",e[e.RightToLeftMark=8207]="RightToLeftMark",e[e.LineSeparator=8232]="LineSeparator",e[e.ParagraphSeparator=8233]="ParagraphSeparator",e[e._0=48]="_0",e[e._1=49]="_1",e[e._2=50]="_2",e[e._3=51]="_3",e[e._4=52]="_4",e[e._5=53]="_5",e[e._6=54]="_6",e[e._7=55]="_7",e[e._8=56]="_8",e[e._9=57]="_9",e[e.a=97]="a",e[e.b=98]="b",e[e.c=99]="c",e[e.d=100]="d",e[e.e=101]="e",e[e.f=102]="f",e[e.g=103]="g",e[e.h=104]="h",e[e.i=105]="i",e[e.j=106]="j",e[e.k=107]="k",e[e.l=108]="l",e[e.m=109]="m",e[e.n=110]="n",e[e.o=111]="o",e[e.p=112]="p",e[e.q=113]="q",e[e.r=114]="r",e[e.s=115]="s",e[e.t=116]="t",e[e.u=117]="u",e[e.v=118]="v",e[e.w=119]="w",e[e.x=120]="x",e[e.y=121]="y",e[e.z=122]="z",e[e.A=65]="A",e[e.B=66]="B",e[e.C=67]="C",e[e.D=68]="D",e[e.E=69]="E",e[e.F=70]="F",e[e.G=71]="G",e[e.H=72]="H",e[e.I=73]="I",e[e.J=74]="J",e[e.K=75]="K",e[e.L=76]="L",e[e.M=77]="M",e[e.N=78]="N",e[e.O=79]="O",e[e.P=80]="P",e[e.Q=81]="Q",e[e.R=82]="R",e[e.S=83]="S",e[e.T=84]="T",e[e.U=85]="U",e[e.V=86]="V",e[e.W=87]="W",e[e.X=88]="X",e[e.Y=89]="Y",e[e.Z=90]="Z",e[e._=95]="_",e[e.$=36]="$",e[e.Ampersand=38]="Ampersand",e[e.Asterisk=42]="Asterisk",e[e.At=64]="At",e[e.Backslash=92]="Backslash",e[e.Backtick=96]="Backtick",e[e.Bar=124]="Bar",e[e.Caret=94]="Caret",e[e.CloseBrace=125]="CloseBrace",e[e.CloseBracket=93]="CloseBracket",e[e.CloseParen=41]="CloseParen",e[e.Colon=58]="Colon",e[e.Comma=44]="Comma",e[e.Dot=46]="Dot",e[e.DoubleQuote=34]="DoubleQuote",e[e.Equals=61]="Equals",e[e.Exclamation=33]="Exclamation",e[e.GreaterThan=62]="GreaterThan",e[e.Hash=35]="Hash",e[e.LessThan=60]="LessThan",e[e.Minus=45]="Minus",e[e.OpenBrace=123]="OpenBrace",e[e.OpenBracket=91]="OpenBracket",e[e.OpenParen=40]="OpenParen",e[e.Percent=37]="Percent",e[e.Plus=43]="Plus",e[e.Question=63]="Question",e[e.Semicolon=59]="Semicolon",e[e.SingleQuote=39]="SingleQuote",e[e.Slash=47]="Slash",e[e.Tilde=126]="Tilde"})(ne||(ne={}))});function Fo(e,t){let n=void 0;return{text:e,path:t,getLineStarts:r,getLineAndCharacterOfPosition:i};function r(){return n=n??MDe(e)}function i(s){let o=r(),a=LDe(o,s);if(a<0)a=~a-1;return{line:a,character:s-o[a]}}}function MDe(e){let t=[],n=0,r=0;while(r>1),s=e[i];if(st)r=i-1;else return i}return~n}var ol=q(()=>{rc();mn()});var hw,Ta,re,Zi,Vn,gw,Ur,qr;var It=q(()=>{(function(e){e[e.None=0]="None",e[e.Resolved=2]="Resolved",e[e.Unknown=4]="Unknown",e[e.Ambiguous=8]="Ambiguous",e[e.NotFound=16]="NotFound",e[e.ResolutionFailed=28]="ResolutionFailed"})(hw||(hw={}));(function(e){e[e.None=0]="None",e[e.Model=2]="Model",e[e.Scalar=4]="Scalar",e[e.Operation=8]="Operation",e[e.Enum=16]="Enum",e[e.Interface=32]="Interface",e[e.Union=64]="Union",e[e.Alias=128]="Alias",e[e.Namespace=256]="Namespace",e[e.Decorator=512]="Decorator",e[e.TemplateParameter=1024]="TemplateParameter",e[e.Function=2048]="Function",e[e.FunctionParameter=4096]="FunctionParameter",e[e.Using=8192]="Using",e[e.DuplicateUsing=16384]="DuplicateUsing",e[e.SourceFile=32768]="SourceFile",e[e.Member=65536]="Member",e[e.Const=131072]="Const",e[e.Declaration=1048576]="Declaration",e[e.Implementation=2097152]="Implementation",e[e.LateBound=4194304]="LateBound",e[e.Internal=8388608]="Internal",e[e.ExportContainer=33024]="ExportContainer",e[e.MemberContainer=118]="MemberContainer"})(Ta||(Ta={}));(function(e){e[e.TypeSpecScript=0]="TypeSpecScript",e[e.JsSourceFile=1]="JsSourceFile",e[e.ImportStatement=2]="ImportStatement",e[e.Identifier=3]="Identifier",e[e.AugmentDecoratorStatement=4]="AugmentDecoratorStatement",e[e.DecoratorExpression=5]="DecoratorExpression",e[e.DirectiveExpression=6]="DirectiveExpression",e[e.MemberExpression=7]="MemberExpression",e[e.NamespaceStatement=8]="NamespaceStatement",e[e.UsingStatement=9]="UsingStatement",e[e.OperationStatement=10]="OperationStatement",e[e.OperationSignatureDeclaration=11]="OperationSignatureDeclaration",e[e.OperationSignatureReference=12]="OperationSignatureReference",e[e.ModelStatement=13]="ModelStatement",e[e.ModelExpression=14]="ModelExpression",e[e.ModelProperty=15]="ModelProperty",e[e.ModelSpreadProperty=16]="ModelSpreadProperty",e[e.ScalarStatement=17]="ScalarStatement",e[e.InterfaceStatement=18]="InterfaceStatement",e[e.UnionStatement=19]="UnionStatement",e[e.UnionVariant=20]="UnionVariant",e[e.EnumStatement=21]="EnumStatement",e[e.EnumMember=22]="EnumMember",e[e.EnumSpreadMember=23]="EnumSpreadMember",e[e.AliasStatement=24]="AliasStatement",e[e.DecoratorDeclarationStatement=25]="DecoratorDeclarationStatement",e[e.FunctionDeclarationStatement=26]="FunctionDeclarationStatement",e[e.FunctionParameter=27]="FunctionParameter",e[e.UnionExpression=28]="UnionExpression",e[e.IntersectionExpression=29]="IntersectionExpression",e[e.TupleExpression=30]="TupleExpression",e[e.ArrayExpression=31]="ArrayExpression",e[e.StringLiteral=32]="StringLiteral",e[e.NumericLiteral=33]="NumericLiteral",e[e.BooleanLiteral=34]="BooleanLiteral",e[e.StringTemplateExpression=35]="StringTemplateExpression",e[e.StringTemplateHead=36]="StringTemplateHead",e[e.StringTemplateMiddle=37]="StringTemplateMiddle",e[e.StringTemplateTail=38]="StringTemplateTail",e[e.StringTemplateSpan=39]="StringTemplateSpan",e[e.ExternKeyword=40]="ExternKeyword",e[e.VoidKeyword=41]="VoidKeyword",e[e.NeverKeyword=42]="NeverKeyword",e[e.UnknownKeyword=43]="UnknownKeyword",e[e.ValueOfExpression=44]="ValueOfExpression",e[e.TypeReference=45]="TypeReference",e[e.TemplateParameterDeclaration=46]="TemplateParameterDeclaration",e[e.EmptyStatement=47]="EmptyStatement",e[e.InvalidStatement=48]="InvalidStatement",e[e.LineComment=49]="LineComment",e[e.BlockComment=50]="BlockComment",e[e.Doc=51]="Doc",e[e.DocText=52]="DocText",e[e.DocParamTag=53]="DocParamTag",e[e.DocPropTag=54]="DocPropTag",e[e.DocReturnsTag=55]="DocReturnsTag",e[e.DocErrorsTag=56]="DocErrorsTag",e[e.DocTemplateTag=57]="DocTemplateTag",e[e.DocUnknownTag=58]="DocUnknownTag",e[e.Return=59]="Return",e[e.JsNamespaceDeclaration=60]="JsNamespaceDeclaration",e[e.TemplateArgument=61]="TemplateArgument",e[e.TypeOfExpression=62]="TypeOfExpression",e[e.ObjectLiteral=63]="ObjectLiteral",e[e.ObjectLiteralProperty=64]="ObjectLiteralProperty",e[e.ObjectLiteralSpreadProperty=65]="ObjectLiteralSpreadProperty",e[e.ArrayLiteral=66]="ArrayLiteral",e[e.ConstStatement=67]="ConstStatement",e[e.CallExpression=68]="CallExpression",e[e.ScalarConstructor=69]="ScalarConstructor",e[e.InternalKeyword=70]="InternalKeyword",e[e.AutoKeyword=71]="AutoKeyword",e[e.FunctionTypeExpression=72]="FunctionTypeExpression"})(re||(re={}));(function(e){e[e.None=0]="None",e[e.DescendantErrorsExamined=1]="DescendantErrorsExamined",e[e.ThisNodeHasError=2]="ThisNodeHasError",e[e.DescendantHasError=4]="DescendantHasError",e[e.Synthetic=8]="Synthetic"})(Zi||(Zi={}));(function(e){e[e.None=0]="None",e[e.Extern=2]="Extern",e[e.Internal=4]="Internal",e[e.Auto=8]="Auto",e[e.All=14]="All"})(Vn||(Vn={}));(function(e){e[e.TypeReference=0]="TypeReference",e[e.TemplateArgument=1]="TemplateArgument",e[e.Decorator=2]="Decorator",e[e.Function=3]="Function",e[e.Using=4]="Using",e[e.Declaration=5]="Declaration",e[e.ModelExpressionProperty=6]="ModelExpressionProperty",e[e.ModelStatementProperty=7]="ModelStatementProperty",e[e.ObjectLiteralProperty=8]="ObjectLiteralProperty",e[e.Other=9]="Other"})(gw||(gw={}));Ur=Symbol.for("NoTarget");(function(e){e[e.NoRecursion=1]="NoRecursion"})(qr||(qr={}))});function BO(e){if(!("kind"in e)&&!("entityKind"in e)){if(!("declarations"in e))return e.node;if(e.flags&Ta.Using)e=e.symbolSource;return e.declarations[0]}else if("entityKind"in e)switch(e.entityKind){case"Type":return e.node;case"Value":return qDe(e)??e.type.node;case"MixedParameterConstraint":return e.node??e.type?.node??e.valueType?.node;case"Indeterminate":return e.type.node;default:return}else if("kind"in e&&typeof e.kind==="number")return e;else return e.node}function qDe(e){switch(e.valueKind){case"ObjectValue":case"ArrayValue":case"Function":return e.node;default:return}}function Br(e,t={}){if(e===Ur||e===void 0)return;if("file"in e)return e;let n=BO(e);return n?UDe(n,t):_9()}function _9(e=""){return{file:Fo("",e),pos:0,end:0,isSynthetic:!0}}function UDe(e,t){let n=e;while(n.parent!==void 0)n=n.parent;if(n.kind!==re.TypeSpecScript&&n.kind!==re.JsSourceFile)return _9(e.flags&Zi.Synthetic?void 0:"");if(t.locateId&&"id"in e&&e.id!==void 0)e=e.id;return{file:n.file,pos:e.pos,end:e.end}}function Qe(e,t,n){if(e)return;if(n){let r;try{r=Br(n)}catch(i){}if(r){let i=r.file.getLineAndCharacterOfPosition(r.pos),s=r.file.path,o=i.line+1,a=i.character+1;t+=` +Occurred while compiling code in ${s} near line ${o}, column ${a}`}}throw Error(t)}function Ct(){let e=[];return{diagnostics:e,add:t,pipe:n,wrap:r,join:i};function t(s){e.push(s)}function n(s){let[o,a]=s;for(let l of a)e.push(l);return o}function r(s){return[s,e]}function i(s){let[o,a]=s;for(let l of a)e.push(l);return[o,e]}}function Ss(e){return e[0]}function al(e){return e}var _t=q(()=>{Yn();ol();It()});function Co(e,t){let n=Br(t);if(n.isSynthetic)return{type:"synthetic"};return e.getSourceFileLocationContext(n.file)}var ic=q(()=>{_t()});var x9,w9,Alt;var Hg=q(()=>{ic();x9={"function-declarations":{description:"Allows use of function declarations without experimental warnings in project code."},"auto-decorators":{description:"Allows use of auto decorator declarations without experimental warnings in project code."},"type-info-provider":{description:"Enables the experimental `$provideTypeInfo` provider allowing libraries to contribute extra information about types to IDE hover and tooling (queried via `program.getTypeInfo`)."},"union-extends":{description:"Enables experimental union `extends` clauses in project code."}},w9=Object.keys(x9),Alt=new Set(w9)});var sc=q(()=>{Yn();mn();ol();It()});var zg=q(()=>{bo();_t();ol()});var VO=z(function(T9){Object.defineProperty(T9,"__esModule",{value:!0});var BDe=l1(),VDe=_1(),KDe=Zx(),JDe=e0(),D9=A1(),GDe=[BDe.default,VDe.default,(0,KDe.default)(),JDe.default,D9.metadataVocabulary,D9.contentVocabulary];T9.default=GDe});var S9=z(function(Jlt,zDe){zDe.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"http://json-schema.org/draft-07/schema#",title:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},default:!0}});var k9=z(function(ks,KO){Object.defineProperty(ks,"__esModule",{value:!0});ks.MissingRefError=ks.ValidationError=ks.CodeGen=ks.Name=ks.nil=ks.stringify=ks.str=ks._=ks.KeywordCxt=ks.Ajv=void 0;var WDe=cu(),QDe=VO(),YDe=ig(),E9=S9(),XDe=["/properties"],bw="http://json-schema.org/draft-07/schema";class Wg extends WDe.default{_addVocabularies(){if(super._addVocabularies(),QDe.default.forEach((e)=>this.addVocabulary(e)),this.opts.discriminator)this.addKeyword(YDe.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let e=this.opts.$data?this.$dataMetaSchema(E9,XDe):E9;this.addMetaSchema(e,bw,!1),this.refs["http://json-schema.org/schema"]=bw}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(bw)?bw:void 0)}}ks.Ajv=Wg;KO.exports=ks=Wg;KO.exports.Ajv=Wg;Object.defineProperty(ks,"__esModule",{value:!0});ks.default=Wg;var ZDe=Lp();Object.defineProperty(ks,"KeywordCxt",{enumerable:!0,get:function(){return ZDe.KeywordCxt}});var km=kt();Object.defineProperty(ks,"_",{enumerable:!0,get:function(){return km._}});Object.defineProperty(ks,"str",{enumerable:!0,get:function(){return km.str}});Object.defineProperty(ks,"stringify",{enumerable:!0,get:function(){return km.stringify}});Object.defineProperty(ks,"nil",{enumerable:!0,get:function(){return km.nil}});Object.defineProperty(ks,"Name",{enumerable:!0,get:function(){return km.Name}});Object.defineProperty(ks,"CodeGen",{enumerable:!0,get:function(){return km.CodeGen}});var eTe=Qf();Object.defineProperty(ks,"ValidationError",{enumerable:!0,get:function(){return eTe.default}});var tTe=qp();Object.defineProperty(ks,"MissingRefError",{enumerable:!0,get:function(){return tTe.default}})});var N9=q(()=>{If();C_();Cl();jl();Ml();$p();Ip();Cf();kE();Rp();Ff()});function Nm(e,t,n="value"){let r=iTe(e,t,n);return{file:e.file,pos:r?.range?.[0]??0,end:r?.range?.[1]??0}}function iTe(e,t,n="value"){let r=e.doc.contents;for(let i=0;ift(a)))return r.items.find((l)=>l.source&&l.source===s)??r.get(s,!0);else return r.get(s,!0);else{let a=ca(r.items,s);if(n==="key")return a?.key;else return a}else r=r.get(s,!0);else continue}return r??void 0}var Qg=q(()=>{bo();N9()});function sTe(e){if(e.startsWith(".")||!Kg(e))return"not-absolute";return"valid"}function Cu(e,t={strict:!0}){let n=new O9.Ajv({strict:t.strict,coerceTypes:t.coerceTypes,allowUnionTypes:!0,allErrors:!0});return n.addFormat("absolute-path",{type:"string",validate:(i)=>sTe(i)==="valid"}),{validate:r};function r(i,s){let o=n.compile(e),a=o(i);Qe(!a||!o.errors,"There should be errors reported if the schema is not valid.");let l=[];for(let c of o.errors??[]){let u=aTe(i,c,s);l.push(u)}return l}}function aTe(e,t,n){let r=lTe(t,n);if(t.params.format==="absolute-path"){let o=cTe(e,t);return tn({code:"config-path-absolute",format:{path:o},target:r})}let i=[`Schema violation: ${t.message} (${t.instancePath||"/"})`];for(let[o,a]of Object.entries(t.params).filter(([l])=>!oTe.has(l))){let l=Array.isArray(a)?[...new Set(a)].join(", "):a;i.push(` ${o}: ${l}`)}return{code:"invalid-schema",message:i.join(` +`),severity:"error",target:r}}function lTe(e,t){if(t===Ur)return Ur;if(!("kind"in t))return{file:t,pos:0,end:0};switch(t.kind){case"yaml-script":return Nm(t,JO(e),"key");case"path-target":return Nm(t.script,[...t.path,...JO(e)],"key")}}function JO(e){let t=uTe(e.instancePath);switch(e.keyword){case"additionalProperties":return[...t,e.params.additionalProperty];default:return t}}function cTe(e,t){let n=JO(t),r=e;for(let i of n)r=r[i];return r}function uTe(e){if(e==="")return[];if(e.charAt(0)!=="/")Qe(!1,`Invalid JSON pointer: "${e}"`);return e.substring(1).split(/\//).map(pTe)}function pTe(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}var O9,oTe;var Om=q(()=>{Qg();_t();Yn();mn();It();O9=Rr(k9(),1);oTe=new Set(["type","errors"])});var dTe,Ect;var GO=q(()=>{sc();zg();Om();It();dTe={type:"object",additionalProperties:!1,required:[],properties:{extends:{type:"array",nullable:!0,items:{type:"string"}},enable:{type:"object",required:[],nullable:!0,additionalProperties:{oneOf:[{type:"boolean"},{type:"object"}]}},disable:{type:"object",required:[],nullable:!0,additionalProperties:{type:"string"}}}},Ect=Cu(dTe)});var $9=q(()=>{Qg();zg()});var I9,Xg;var vw=q(()=>{I9={type:"object",additionalProperties:!0,required:[],properties:{"emitter-output-dir":{type:"string",nullable:!0}}},Xg={type:"object",additionalProperties:!1,properties:{extends:{type:"string",nullable:!0},kind:{type:"string",enum:["project"],nullable:!0},entrypoint:{type:"string",nullable:!0},features:{type:"array",nullable:!0,items:{type:"string"}},"environment-variables":{type:"object",nullable:!0,required:[],additionalProperties:{type:"object",properties:{default:{type:"string"}},required:["default"],additionalProperties:!1}},parameters:{type:"object",nullable:!0,required:[],additionalProperties:{type:"object",properties:{default:{type:"string"}},required:["default"],additionalProperties:!1}},"output-dir":{type:"string",nullable:!0},"warn-as-error":{type:"boolean",nullable:!0},trace:{oneOf:[{type:"string"},{type:"array",items:{type:"string"}}]},imports:{type:"array",nullable:!0,items:{type:"string"}},emit:{type:"array",nullable:!0,items:{type:"string"}},options:{type:"object",nullable:!0,required:[],additionalProperties:I9},linter:{type:"object",nullable:!0,required:[],additionalProperties:!1,properties:{extends:{type:"array",nullable:!0,items:{type:"string"}},enable:{type:"object",required:[],nullable:!0,additionalProperties:{oneOf:[{type:"boolean"},{type:"object"}]}},disable:{type:"object",required:[],nullable:!0,additionalProperties:{type:"string"}}}}}}});var yTe,Jct;var Pd=q(()=>{Hg();GO();Yn();mn();Om();ol();It();sc();Gt();$9();zg();vw();yTe=pw({outputDir:"{cwd}/tsp-output",diagnostics:[]}),Jct=Cu(Xg)});var A9=q(()=>{_t();Yn();It()});var zO=q(()=>{_t();Yn();mn();It();sc();Gt();A9();Pd()});var R9=q(()=>{zO();Pd()});function j9(e,t,n,r){if(!C9(t,r))return gn(e.program,{code:"decorator-wrong-target",format:{decorator:n,to:t.kind},target:e.decoratorTarget}),!1;return!0}function F9(e,t,n){return Ss(e.checker.isTypeAssignableTo(t,e.checker.getStdType(n),t))}function C9(e,t){let n=gTe(e);if(n===void 0)return!1;return typeof t==="string"?t==="Any"||n===t:t.includes("Any")||t.includes(n)}function gTe(e){switch(typeof e){case"object":return e.kind;case"string":return"String";case"number":return"Number";case"boolean":return"Boolean";default:return}}function xw(e,t){if(typeof e!=="object")return[e,[]];return WO(e,t,[])}function WO(e,t,n){switch(e.kind){case"String":case"Boolean":case"Number":return[e.value,[]];case"EnumMember":return[e.value??e.name,[]];case"Tuple":{let i=[];for(let[s,o]of e.values.entries()){let[a,l]=WO(o,t,[...n,s.toString()]);if(l.length>0)return[void 0,l];i.push(a)}return[i,[]]}case"Model":{let i={};for(let[s,o]of e.properties.entries()){let[a,l]=WO(o.type,t,[...n,s.toString()]);if(l.length>0)return[void 0,l];i[s]=a}return[i,[]]}case"StringTemplate":if(e.stringValue)return[e.stringValue,[]];default:return[void 0,[n.length===0?tn({code:"invalid-value",format:{kind:e.kind},target:t}):tn({code:"invalid-value",messageId:"atPath",format:{kind:e.kind,path:n.join(".")},target:t})]]}}function bn(e,t,n){if(Qe("decorators"in t,"Type should have decorators"),t.decorators.filter((i)=>i.decorator===n&&i.node?.kind===re.DecoratorExpression&&i.node?.parent===t.node).length>1)return gn(e.program,{code:"duplicate-decorator",format:{decoratorName:"@"+n.name.slice(1)},target:e.decoratorTarget}),!1;return!0}function Pm(e,t,n,r){Qe("decorators"in t,"Type should have decorators");let i=[],s=t;while(s)i.push(...s.decorators),s=o(s);for(let a of i)if(a.decorator===n)return gn(e.program,{code:"decorator-conflict",format:{decoratorName:"@"+n.name.slice(1),otherDecoratorName:"@"+r.name.slice(1)},target:e.decoratorTarget}),!1;return!0;function o(a){if(a.kind==="Model")return a.baseModel;else if(a.kind==="Scalar")return a.baseScalar;else return}}function $m(e){if(e.kind==="ModelProperty")return e.type;else return e}var $d=q(()=>{_t();Yn();It()});function Im(e){return"kind"in e&&e.kind==="Intrinsic"&&e.name==="void"}function ww(e){return"kind"in e&&e.kind==="Intrinsic"&&e.name==="never"}function Zg(e){return"kind"in e&&e.kind==="Intrinsic"&&e.name==="null"}function Mo(e){return e.entityKind==="Type"}function Sa(e){return e.entityKind==="Value"}function Ns(e,t){let n=t??e;return Boolean(n.indexer&&n.indexer.key.name==="integer")}function QO(e,t){let n=t??e;return Boolean(n.indexer&&n.indexer.key.name==="string")}function Lo(e){let t=e;return t.templateMapper!==void 0&&!t.templateMapper.partial&&t.isFinished}function oc(e){if(e.node===void 0)return!1;let t=e.node;return t.templateParameters&&t.templateParameters.length>0&&e.templateMapper===void 0}function Dw(e){if(e.node===void 0)return!1;let t=e.node;return t.templateParameters&&t.templateParameters.length>0}var yr=q(()=>{It()});var YO=q(()=>{$d();yr()});function nn(e){for(let[t,n]of Object.entries(e)){let r=n;if(eb[t]!==void 0)r={...eb[t],...n};if(typeof r==="object"&&r!==null)Object.defineProperty(r,bTe,{value:!0,enumerable:!1,configurable:!1});eb[t]=r}}var eb,bTe;var Or=q(()=>{eb={},bTe=Symbol.for("TypekitNamespace")});function L9(e){let t=Object.create(eb),n={get(i,s,o){if(s==="program")return e.program;if(s==="realm")return e;let a=Reflect.get(i,s,o);if(typeof a==="function"){let l=function(...c){return a.apply(r,c)};for(let c of Object.keys(a)){let u=a[c];if(typeof u==="function")l[c]=function(...p){return u.apply(r,p)};else Reflect.defineProperty(l,c,Reflect.getOwnPropertyDescriptor(a,c))}return l}if(typeof a==="object"&&a!==null&&!Reflect.getOwnPropertyDescriptor(i,s)?.get)return new Proxy(a,n);return a}},r=new Proxy(t,n);return r}var q9=q(()=>{Or()});function vTe(e,t){let n=Symbol.for(e);if(!globalThis[n])globalThis[n]=t();return globalThis[n]}var XO,U9,Ws;var Id=q(()=>{_t();q9();U9=class U9{#e;#t;#n;constructor(e,t,n){this.#e=e,this.#t=n,this.#n=t}has(e){return this.#r(e).has(e)??!1}set(e,t){return this.#r(e).set(e,t),this}get(e){return this.#r(e).get(e)}delete(e){return this.#r(e).delete(e)}forEach(e,t){for(let n of this.entries())e.call(t,n[1],n[0],this);return this}get size(){return this.#n.size+this.#t.size}clear(){this.#n.clear()}*entries(){for(let e of this.#n)yield e;for(let e of this.#t)yield e;return}*values(){for(let e of this.entries())yield e[1];return}*keys(){for(let e of this.entries())yield e[0];return}[Symbol.iterator](){return this.entries()}[Symbol.toStringTag]="StateMap";#r(e){if(this.#e.hasType(e))return this.#n;return this.#t}};Ws=class Ws{#e;#t=new Set;#n=new WeakSet;#r=new Map;key;constructor(e,t){this.key=Symbol(t),this.#e=e}#i;get typekit(){return this.#i??=L9(this)}get program(){return this.#e}stateMap(e){let t=this.#r.get(e);if(!t)t=new Map,this.#r.set(e,t);return new U9(this,t,this.#e.stateMap(e))}clone(e){Qe(e,"Undefined type passed to clone");let t=this.#s(e);return this.typekit.type.finishType(t),t}remove(e){this.#n.add(e)}hasType(e){return this.#t.has(e)}addType(e){this.#t.add(e),XO.realmForType.set(e,this)}#s(e){let t=this.typekit.type.clone(e);return this.#t.add(t),XO.realmForType.set(t,this),t}get types(){return this.#t}static realmForType=vTe("Realm.realmForType",()=>new WeakMap)};XO=Ws});function Am(e,t){for(let[n,r]of e.properties)if(!t(r))e.properties.delete(n)}function Pt(e){return Symbol.for(`TypeSpec.${e}`)}function Rm(e,t){if(t.kind==="TemplateParameter")return e;return e.replace(/{(\w+)}/g,(n,r)=>t[r])}function ze(e){return[(i,s)=>i.stateMap(e).get(s),(i,s,o)=>i.stateMap(e).set(s,o),(i)=>i.stateMap(e)]}function hr(e){return[(r,i)=>r.stateSet(e).has(i),(r,i)=>r.stateSet(e).add(i)]}function qo(e){return typeof e==="object"&&e!==null&&Zr in e}function kn(e){if(new.target)throw Error("Numeric is not a constructor");let t=xTe(e),n=t.d===0,r={[Zr]:t,isInteger:n},i=_Te(r,V9);return Object.freeze(i)}function _Te(e,t){return Object.setPrototypeOf(e,t),e}function xTe(e){let t=e,n=0,r=1,i,s,o=void 0;if(t[0]==="-")n=1,r=-1;let a=t[n+1]?.toLowerCase();if(t[n]==="0"&&(a==="b"||a==="x"||a==="o"))try{i=BigInt(t.slice(n)),s=i.toString().length,o=0}catch{throw new ZO(`Invalid numeric value: ${e}`)}else{while(t[n]==="0")n++;let l=t.indexOf("."),c=l-n;if(l!==-1)s=c,t=t.replace(".","");let u;if((u=t.search(/e/i))>0){if(s===void 0)s=u-n;s+=Number(t.slice(u+1)),t=t.slice(n,u),o=Math.max(t.length-s,0)}else if(s===void 0)s=t.length-n,t=t.slice(n);else t=t.slice(n);let p=t.length;while(t[p-1]==="0"&&p>c)p--;if(n===c+1){let d=c;while(t[d]==="0"&&de.n===t.n&&e.e===t.e,Tw=(e,t)=>{if(e.st.s)return 1;let n=e.s;if(e.et.e)return 1*n;let r=e.n,i=t.n;if(e.di)return 1*n;return 0},V9;var ac=q(()=>{ZO=class ZO extends Error{code="InvalidNumeric"};Zr=Symbol.for("NumericInternalData");V9={toString:function(){return eP(this[Zr])},asNumber:function(){let e=Number(eP(this[Zr]));return B9(this[Zr],kn(e.toString())[Zr])?e:null},asBigInt:function(){if(!this.isInteger)return null;let{s:e,n:t}=this[Zr];return BigInt(e)*t},equals:function(e){return B9(this[Zr],e[Zr])},lt:function(e){return Tw(this[Zr],e[Zr])===-1},lte:function(e){return Tw(this[Zr],e[Zr])<=0},gt:function(e){return Tw(this[Zr],e[Zr])===1},gte:function(e){return Tw(this[Zr],e[Zr])>=0}};V9.toString=function(){return eP(this[Zr])}});function jm(e,t){let n=wTe(e,t);return qo(n)?n:void 0}function Fm(e,t){return jm(e,t)?.asNumber()??void 0}function Cm(e,t){let n=DTe(e,t);return qo(n)?n:void 0}function Mm(e,t){return Cm(e,t)?.asNumber()??void 0}function Lm(e,t){let n=TTe(e,t);return qo(n)?n:void 0}function Sw(e,t){return Lm(e,t)?.asNumber()??void 0}function qm(e,t){let n=STe(e,t);return qo(n)?n:void 0}function Ew(e,t){return qm(e,t)?.asNumber()??void 0}function z9(e,t,n){e.stateMap(fi.minLength).set(t,n)}function kw(e,t){return e.stateMap(fi.minLength).get(t)}function tb(e,t){return kw(e,t)?.asNumber()??void 0}function W9(e,t,n){e.stateMap(fi.maxLength).set(t,n)}function Nw(e,t){return e.stateMap(fi.maxLength).get(t)}function nb(e,t){return Nw(e,t)?.asNumber()??void 0}function Q9(e,t,n){e.stateMap(fi.minItems).set(t,n)}function Ow(e,t){return e.stateMap(fi.minItems).get(t)}function rb(e,t){return Ow(e,t)?.asNumber()??void 0}function Y9(e,t,n){e.stateMap(fi.maxItems).set(t,n)}function Pw(e,t){return e.stateMap(fi.maxItems).get(t)}function ib(e,t){return Pw(e,t)?.asNumber()??void 0}function Um(e,t,n,r){e.stateMap(X9(n)).set(t,r)}function X9(e){switch(e){case"self":return fi.docs;case"returns":return fi.returnDocs;case"errors":return fi.errorsDocs}}function $w(e,t,n){return e.stateMap(X9(n)).get(t)}function Z9(e,t,n){e.stateMap(fi.discriminator).set(t,n)}function Ad(e,t){return e.stateMap(fi.discriminator).get(t)}var fi,wTe,K9,DTe,J9,TTe,G9,STe,H9,e7,t7;var lc=q(()=>{ac();fi={minValues:Pt("minValues"),maxValues:Pt("maxValues"),minValueExclusive:Pt("minValueExclusive"),maxValueExclusive:Pt("maxValueExclusive"),minLength:Pt("minLengthValues"),maxLength:Pt("maxLengthValues"),minItems:Pt("minItems"),maxItems:Pt("maxItems"),docs:Pt("docs"),returnDocs:Pt("returnsDocs"),errorsDocs:Pt("errorDocs"),discriminator:Pt("discriminator")},[wTe,K9]=ze(fi.minValues);[DTe,J9]=ze(fi.maxValues);[TTe,G9]=ze(fi.minValueExclusive);[STe,H9]=ze(fi.maxValueExclusive);[e7,t7]=ze(Pt("discriminated"))});function r7(e,t){e.program.stateMap(kTe).set(t,!0)}var ETe,n7=(e,t,n,r)=>{let i={key:n,value:r};e.program.stateMap(ETe).set(t,i)},tP=(e,t,n,r)=>{Um(e.program,t,n,{value:r,source:"comment"})},kTe;var nP=q(()=>{lc();ETe=Symbol.for("TypeSpec.index"),kTe=Symbol.for("TypeSpec.Prototypes.getter")});function mi(e){function t(...n){return Ss(e.apply(this,n))}return t.withDiagnostics=e,t}var Mu=q(()=>{_t()});var i7=q(()=>{yr();Or();nn({array:{is(e){return e.entityKind==="Type"&&e.kind==="Model"&&Ns(e)&&e.properties.size===0},getElementType(e){if(!this.array.is(e))throw Error("Type is not an array.");return e.indexer.value},create(e){return this.model.create({name:"Array",properties:{},indexer:{key:this.builtin.integer,value:e}})}}})});var s7=q(()=>{Or();nn({builtin:{get string(){return this.program.checker.getStdType("string")},get boolean(){return this.program.checker.getStdType("boolean")},get bytes(){return this.program.checker.getStdType("bytes")},get decimal(){return this.program.checker.getStdType("decimal")},get decimal128(){return this.program.checker.getStdType("decimal128")},get duration(){return this.program.checker.getStdType("duration")},get float(){return this.program.checker.getStdType("float")},get float32(){return this.program.checker.getStdType("float32")},get float64(){return this.program.checker.getStdType("float64")},get int8(){return this.program.checker.getStdType("int8")},get int16(){return this.program.checker.getStdType("int16")},get int32(){return this.program.checker.getStdType("int32")},get int64(){return this.program.checker.getStdType("int64")},get integer(){return this.program.checker.getStdType("integer")},get offsetDateTime(){return this.program.checker.getStdType("offsetDateTime")},get plainDate(){return this.program.checker.getStdType("plainDate")},get plainTime(){return this.program.checker.getStdType("plainTime")},get safeInt(){return this.program.checker.getStdType("safeint")},get uint8(){return this.program.checker.getStdType("uint8")},get uint16(){return this.program.checker.getStdType("uint16")},get uint32(){return this.program.checker.getStdType("uint32")},get uint64(){return this.program.checker.getStdType("uint64")},get url(){return this.program.checker.getStdType("url")},get utcDateTime(){return this.program.checker.getStdType("utcDateTime")},get numeric(){return this.program.checker.getStdType("numeric")}}})});var o7=q(()=>{Mu();Or();nn({entity:{isAssignableTo:mi(function(e,t,n){return this.program.checker.isTypeAssignableTo(e,t,n??e)}),resolve:mi(function(e){return this.program.resolveTypeOrValueReference(e)})}})});function Ii(e){return il(e.entries())}function ll(e,t){return t?.map((n)=>{let[r,i]=Array.isArray(n)?[n[0],n.slice(1)]:[n,[]];return{decorator:r,args:i.map((s)=>({value:typeof s==="object"&&s!==null?s:e.literal.create(s),jsValue:s}))}})??[]}var Rd=q(()=>{Gt()});var a7=q(()=>{Or();Rd();nn({enumMember:{create(e){let t=this.program.checker.createType({kind:"EnumMember",name:e.name,value:e.value,decorators:ll(this,e.decorators),enum:e.enum});return this.program.checker.finishType(t),t},is(e){return e.entityKind==="Type"&&e.kind==="EnumMember"}}})});var zut;var sb=q(()=>{It();zut=Pt("deprecated")});class Qs{#e=new Map;track(e,t){let n=this.#e.get(e);if(n===void 0)this.#e.set(e,[t]);else n.push(t)}*entries(){for(let[e,t]of this.#e.entries())if(t.length>1)yield[e,t]}}function jd(e,t){return OTe(e,t)}function OTe(e,t){let n=e7(e,t),r=[];if(n===void 0)return[void 0,[]];let i=new Map,s;for(let o of t.variants.values()){if(typeof o.name!=="string"){if(s)r.push(tn({code:"invalid-discriminated-union-variant",messageId:"duplicateDefaultVariant",format:{unionName:t.name??"(anonymous)"},target:o}));else s=o.type;continue}if(i.set(o.name,o.type),n.envelope==="none"){if(o.type.kind!=="Model"){r.push(tn({code:"invalid-discriminated-union-variant",messageId:"noEnvelopeModel",format:{name:o.name.toString()},target:o}));continue}let a=o.type.properties.get(n.discriminatorPropertyName);if(a!==void 0){let l=ATe(a.type);if(l!==o.name)r.push(tn({code:"invalid-discriminated-union-variant",messageId:"discriminantMismatch",format:{name:o.name.toString(),discriminant:n.discriminatorPropertyName,propertyValue:l,variantName:String(o.name)},target:o.type}))}}}return[{type:t,options:n,variants:i,defaultVariant:s},r]}function Iw(e,t){let n=new Map,r=[],i=new Qs;function s(a){for(let l of a.derivedModels){if(Dw(l))continue;let c=ITe(l,t,r);if(c===void 0)if(l.derivedModels.length===0)r.push(tn({code:"missing-discriminator-property",format:{discriminator:t.propertyName},target:l}));else s(l);else for(let u of c)i.track(u,l),n.set(u,l)}}return s(e),PTe(i,r),[{kind:"legacy",propertyName:t.propertyName,variants:n},r]}function PTe(e,t){for(let[n,r]of e.entries())for(let i of r)t.push(tn({code:"invalid-discriminator-value",messageId:"duplicate",format:{discriminator:n},target:i}))}function $Te(e,t,n){let r=e.properties.get(t.propertyName);if(r&&r.optional)n.push(tn({code:"invalid-discriminator-value",messageId:"required",target:r}));return r}function ITe(e,t,n){let r=$Te(e,t,n);if(!r)return;let i=rP(r.type);if(i.length===0)n.push(tn({code:"invalid-discriminator-value",format:{kind:r.type.kind},target:r}));return i}function rP(e){switch(e.kind){case"String":return[e.value];case"Union":return[...e.variants.values()].flatMap((t)=>rP(t.type)).filter(Nd);case"EnumMember":return typeof e.value!=="number"?[e.value??e.name]:[];case"UnionVariant":return rP(e.type);default:return[]}}function ATe(e){switch(e.kind){case"String":return e.value;case"EnumMember":return typeof e.value!=="number"?e.value??e.name:void 0;default:return}}var Bm=q(()=>{Gt();lc();Yn();yr()});function Aw(e){return RTe.get(e)}var RTe;var Rw=q(()=>{It();RTe=new WeakMap});function jw(e){return al({id:"triple-quote-indent",label:"Format triple-quote-indent",fix:(t)=>{let s=e.file.text.slice(e.pos+3,e.end-3),o=iP(s);if(o.length===0)return;if(o.length===1){let f=d(o[0]),m=" ".repeat(f);return t.replaceText(e,['"""',o[0],`${m}"""`].join(` `))}if(o[0].trim()==="")o.shift();let a=o[o.length-1];if(a.trim()==="")o.pop();let l="",c=Math.min(...o.map((f)=>d(f))),u=d(a);if(c`${l}${f}`).join(` `);return t.replaceText(e,`""" ${p} -${" ".repeat(u)}"""`);function d(f){let m=0;while(m{rc();vt();Mu()});var Fw=q(()=>{rc()});function p7(e){return e>=w.__StartTrivia&&e=w.__StartKeyword&&e=w.__StartReservedKeyword&&e=w.__StartPunctuation&&e=w.__StartModifierKeyword&&e=w.__StartStatementKeyword&&e"):e,r=n.text,i=0,s=r.length,o=w.None,a=-1,l=qt.None;if(i=s}function u(){return r.substring(a,i)}function p(){switch(o){case w.StringLiteral:case w.StringTemplateHead:case w.StringTemplateMiddle:case w.StringTemplateTail:return J(o,l);case w.Identifier:return _e();case w.DocText:return ue();default:return u()}}function d(j){let H=i+j;if(H>=s)return Number.NaN;return r.charCodeAt(H)}function f(){if(a=i,l=qt.None,!c()){let j=r.charCodeAt(i);switch(j){case ne.CarriageReturn:if(d(1)===ne.LineFeed)i++;case ne.LineFeed:return b(w.NewLine);case ne.Space:case ne.Tab:case ne.VerticalTab:case ne.FormFeed:return N();case ne.OpenParen:return b(w.OpenParen);case ne.CloseParen:return b(w.CloseParen);case ne.Comma:return b(w.Comma);case ne.Colon:return d(1)===ne.Colon?b(w.ColonColon,2):b(w.Colon);case ne.Semicolon:return b(w.Semicolon);case ne.OpenBracket:return b(w.OpenBracket);case ne.CloseBracket:return b(w.CloseBracket);case ne.OpenBrace:return b(w.OpenBrace);case ne.CloseBrace:return b(w.CloseBrace);case ne.At:return d(1)===ne.At?b(w.AtAt,2):b(w.At);case ne.Hash:switch(d(1)){case ne.OpenBrace:return b(w.HashBrace,2);case ne.OpenBracket:return b(w.HashBracket,2);default:return b(w.Hash)}case ne.Plus:return Dm(d(1))?O():b(w.Plus);case ne.Minus:return Dm(d(1))?O():b(w.Hyphen);case ne.Asterisk:return b(w.Star);case ne.Question:return b(w.Question);case ne.Ampersand:return d(1)===ne.Ampersand?b(w.AmpsersandAmpersand,2):b(w.Ampersand);case ne.Dot:return d(1)===ne.Dot&&d(2)===ne.Dot?b(w.Ellipsis,3):b(w.Dot);case ne.Slash:switch(d(1)){case ne.Slash:return me();case ne.Asterisk:return I()}return b(w.ForwardSlash);case ne._0:switch(d(1)){case ne.x:return L();case ne.b:return Y()}case ne._1:case ne._2:case ne._3:case ne._4:case ne._5:case ne._6:case ne._7:case ne._8:case ne._9:return C();case ne.LessThan:if(G())return V();return d(1)===ne.Equals?b(w.LessThanEquals,2):b(w.LessThan);case ne.GreaterThan:if(G())return V();return d(1)===ne.Equals?b(w.GreaterThanEquals,2):b(w.GreaterThan);case ne.Equals:if(G())return V();switch(d(1)){case ne.Equals:return b(w.EqualsEquals,2);case ne.GreaterThan:return b(w.EqualsGreaterThan,2)}return b(w.Equals);case ne.Bar:if(G())return V();return d(1)===ne.Bar?b(w.BarBar,2):b(w.Bar);case ne.DoubleQuote:return d(1)===ne.DoubleQuote&&d(2)===ne.DoubleQuote?pe(qt.TripleQuoted):pe(qt.None);case ne.Exclamation:return d(1)===ne.Equals?b(w.ExclamationEquals,2):b(w.Exclamation);case ne.Backtick:return Re();default:if(qO(j))return he();if(fw(j))return ke();if(j<=ne.MaxAscii)return v();return x()}}return o=w.EndOfFile}function m(){if(a=i,l=qt.None,!c()){let j=r.charCodeAt(i);switch(j){case ne.CarriageReturn:if(d(1)===ne.LineFeed)i++;case ne.LineFeed:return b(w.NewLine);case ne.Backslash:if(d(1)===ne.At)return l|=qt.Escaped,b(w.DocText,2);return b(w.DocText);case ne.Space:case ne.Tab:case ne.VerticalTab:case ne.FormFeed:return N();case ne.CloseBrace:return b(w.CloseBrace);case ne.At:return b(w.At);case ne.Asterisk:return b(w.Star);case ne.Backtick:return d(1)===ne.Backtick&&d(2)===ne.Backtick?b(w.DocCodeFenceDelimiter,3):Z();case ne.LessThan:case ne.GreaterThan:case ne.Equals:case ne.Bar:if(G())return V();return b(w.DocText);case ne.Minus:return b(w.Hyphen)}if(fw(j))return ke();if(j<=ne.MaxAscii)return b(w.DocText);let H=r.codePointAt(i);if(yw(H))return Ne(H);return D(w.DocText)}return o=w.EndOfFile}function y(j){return i=a,l=qt.None,de(j)}function h(j,H){let ge=i,fe=s,W=o,ye=a,Oe=l;i=j.pos,s=j.end,o=w.None,a=-1,l=qt.None;let Se=H();return i=ge,s=fe,o=W,a=ye,l=Oe,Se}function b(j,H=1){return i+=H,o=j}function g(j){return l|=qt.Unterminated,T({code:"unterminated",format:{token:ab[j]}}),o=j}function x(){l|=qt.NonAscii;let j=r.charCodeAt(i);if(CO(j))return N();let H=r.codePointAt(i);if(Tm(H))return Ne(H);return v()}function v(){return o=D(w.Invalid),T({code:"invalid-character"}),o}function D(j){let H=r.codePointAt(i);return o=b(j,Jg(H))}function T(j,H,ge){let fe=tn({...j,target:{file:n,pos:H??a,end:ge??i}});t(fe)}function N(){do i++;while(!c()&&ju(r.charCodeAt(i)));return o=w.Whitespace}function O(){return i++,C()}function C(){if(X(),!c()&&r.charCodeAt(i)===ne.Dot)i++,te();if(!c()&&r.charCodeAt(i)===ne.e){i++;let j=r.charCodeAt(i);if(j===ne.Plus||j===ne.Minus)i++;te()}return o=w.NumericLiteral}function X(){do i++;while(!c()&&Dm(r.charCodeAt(i)))}function te(){if(c()||!Dm(r.charCodeAt(i))){T({code:"digit-expected"});return}X()}function L(){if(i+=2,c()||!MO(r.charCodeAt(i)))return T({code:"hex-digit-expected"}),o=w.NumericLiteral;do i++;while(!c()&&MO(r.charCodeAt(i)));return o=w.NumericLiteral}function Y(){if(i+=2,c()||!LO(r.charCodeAt(i)))return T({code:"binary-digit-expected"}),o=w.NumericLiteral;do i++;while(!c()&&LO(r.charCodeAt(i)));return o=w.NumericLiteral}function me(){return i=jTe(r,i,s),o=w.SingleLineComment}function I(){if(o=w.MultiLineComment,d(2)===ne.Asterisk)l|=qt.DocComment;let[j,H]=FTe(r,i);return i=j,H?o:g(o)}function Z(){i++;e:for(;!c();i++)switch(r.charCodeAt(i)){case ne.Backtick:return i++,o=w.DocCodeSpan;case ne.CarriageReturn:case ne.LineFeed:break e}return g(w.DocCodeSpan)}function pe(j){if(j&qt.TripleQuoted)i+=3;else i++;return je(j,w.StringTemplateHead,w.StringLiteral)}function de(j){return i++,je(j,w.StringTemplateMiddle,w.StringTemplateTail)}function je(j,H,ge){let fe=j&qt.TripleQuoted;l=j;e:for(;!c();i++)switch(r.charCodeAt(i)){case ne.Backslash:if(l|=qt.Escaped,i++,c())break e;continue;case ne.DoubleQuote:if(fe)if(d(1)===ne.DoubleQuote&&d(2)===ne.DoubleQuote)return i+=3,o=ge,ge;else continue;else return i++,o=ge,ge;case ne.$:if(d(1)===ne.OpenBrace)return i+=2,o=H,H;continue;case ne.CarriageReturn:case ne.LineFeed:if(fe)continue;else break e}return g(ge)}function be(j,H){switch(j){case w.StringLiteral:case w.StringTemplateHead:return H&qt.TripleQuoted?3:1;default:return 1}}function Ie(j,H){switch(j){case w.StringLiteral:case w.StringTemplateTail:return H&qt.TripleQuoted?3:1;default:return 2}}function J(j,H){if(H&qt.TripleQuoted){let Oe=a,Se=i,[Ce,Bt]=ce(Oe,Se);return Le(Oe,Se,Ce,Bt,j,H)}let ge=be(j,H),fe=Ie(j,H),W=a+ge,ye=H&qt.Unterminated?i:i-fe;if(H&qt.Escaped)return lt(W,ye);return r.substring(W,ye)}function _e(){let j=l&qt.Backticked?a+1:a,H=l&qt.Backticked&&!(l&qt.Unterminated)?i-1:i,ge=l&qt.Escaped?lt(j,H):r.substring(j,H);if(l&qt.NonAscii)return ge.normalize("NFC");return ge}function ue(){if(l&qt.Escaped){let j=a,H=i,ge="",fe=j;while(fej&&ju(r.charCodeAt(H-1)))H--;let fe=H;if(sl(r.charCodeAt(H-1))){if(Ke(H-2,0,H))H--;H--}return[fe,ge]}function Le(j,H,ge,fe,W,ye){let Oe=be(W,ye),Se=Ie(W,ye);if(j=j+Oe,H=ye&qt.Unterminated?H:H-Se,W===w.StringLiteral||W===w.StringTemplateHead){while(jj&&ju(r.charCodeAt(H-1)))H--;if(sl(r.charCodeAt(H-1))){if(Ke(H-2,j,H))H--;H--}else T({code:"no-new-line-end-triple-quote",codefixes:[jw({file:n,pos:a,end:i})]})}let Ce=!1;if(W===w.StringTemplateMiddle||W===w.StringTemplateTail)Ce=!0;let Bt="",_=j;while(_{rc();_t();Lu()});var Fw=q(()=>{rc()});function p7(e){return e>=w.__StartTrivia&&e=w.__StartKeyword&&e=w.__StartReservedKeyword&&e=w.__StartPunctuation&&e=w.__StartModifierKeyword&&e=w.__StartStatementKeyword&&e"):e,r=n.text,i=0,s=r.length,o=w.None,a=-1,l=qt.None;if(i=s}function u(){return r.substring(a,i)}function p(){switch(o){case w.StringLiteral:case w.StringTemplateHead:case w.StringTemplateMiddle:case w.StringTemplateTail:return J(o,l);case w.Identifier:return _e();case w.DocText:return ue();default:return u()}}function d(j){let H=i+j;if(H>=s)return Number.NaN;return r.charCodeAt(H)}function f(){if(a=i,l=qt.None,!c()){let j=r.charCodeAt(i);switch(j){case ne.CarriageReturn:if(d(1)===ne.LineFeed)i++;case ne.LineFeed:return b(w.NewLine);case ne.Space:case ne.Tab:case ne.VerticalTab:case ne.FormFeed:return N();case ne.OpenParen:return b(w.OpenParen);case ne.CloseParen:return b(w.CloseParen);case ne.Comma:return b(w.Comma);case ne.Colon:return d(1)===ne.Colon?b(w.ColonColon,2):b(w.Colon);case ne.Semicolon:return b(w.Semicolon);case ne.OpenBracket:return b(w.OpenBracket);case ne.CloseBracket:return b(w.CloseBracket);case ne.OpenBrace:return b(w.OpenBrace);case ne.CloseBrace:return b(w.CloseBrace);case ne.At:return d(1)===ne.At?b(w.AtAt,2):b(w.At);case ne.Hash:switch(d(1)){case ne.OpenBrace:return b(w.HashBrace,2);case ne.OpenBracket:return b(w.HashBracket,2);default:return b(w.Hash)}case ne.Plus:return Sm(d(1))?O():b(w.Plus);case ne.Minus:return Sm(d(1))?O():b(w.Hyphen);case ne.Asterisk:return b(w.Star);case ne.Question:return b(w.Question);case ne.Ampersand:return d(1)===ne.Ampersand?b(w.AmpsersandAmpersand,2):b(w.Ampersand);case ne.Dot:return d(1)===ne.Dot&&d(2)===ne.Dot?b(w.Ellipsis,3):b(w.Dot);case ne.Slash:switch(d(1)){case ne.Slash:return me();case ne.Asterisk:return I()}return b(w.ForwardSlash);case ne._0:switch(d(1)){case ne.x:return L();case ne.b:return Y()}case ne._1:case ne._2:case ne._3:case ne._4:case ne._5:case ne._6:case ne._7:case ne._8:case ne._9:return C();case ne.LessThan:if(G())return V();return d(1)===ne.Equals?b(w.LessThanEquals,2):b(w.LessThan);case ne.GreaterThan:if(G())return V();return d(1)===ne.Equals?b(w.GreaterThanEquals,2):b(w.GreaterThan);case ne.Equals:if(G())return V();switch(d(1)){case ne.Equals:return b(w.EqualsEquals,2);case ne.GreaterThan:return b(w.EqualsGreaterThan,2)}return b(w.Equals);case ne.Bar:if(G())return V();return d(1)===ne.Bar?b(w.BarBar,2):b(w.Bar);case ne.DoubleQuote:return d(1)===ne.DoubleQuote&&d(2)===ne.DoubleQuote?pe(qt.TripleQuoted):pe(qt.None);case ne.Exclamation:return d(1)===ne.Equals?b(w.ExclamationEquals,2):b(w.Exclamation);case ne.Backtick:return Re();default:if(qO(j))return he();if(fw(j))return Ne();if(j<=ne.MaxAscii)return v();return x()}}return o=w.EndOfFile}function m(){if(a=i,l=qt.None,!c()){let j=r.charCodeAt(i);switch(j){case ne.CarriageReturn:if(d(1)===ne.LineFeed)i++;case ne.LineFeed:return b(w.NewLine);case ne.Backslash:if(d(1)===ne.At)return l|=qt.Escaped,b(w.DocText,2);return b(w.DocText);case ne.Space:case ne.Tab:case ne.VerticalTab:case ne.FormFeed:return N();case ne.CloseBrace:return b(w.CloseBrace);case ne.At:return b(w.At);case ne.Asterisk:return b(w.Star);case ne.Backtick:return d(1)===ne.Backtick&&d(2)===ne.Backtick?b(w.DocCodeFenceDelimiter,3):Z();case ne.LessThan:case ne.GreaterThan:case ne.Equals:case ne.Bar:if(G())return V();return b(w.DocText);case ne.Minus:return b(w.Hyphen)}if(fw(j))return Ne();if(j<=ne.MaxAscii)return b(w.DocText);let H=r.codePointAt(i);if(yw(H))return Oe(H);return D(w.DocText)}return o=w.EndOfFile}function y(j){return i=a,l=qt.None,de(j)}function h(j,H){let ge=i,fe=s,W=o,ye=a,Pe=l;i=j.pos,s=j.end,o=w.None,a=-1,l=qt.None;let Se=H();return i=ge,s=fe,o=W,a=ye,l=Pe,Se}function b(j,H=1){return i+=H,o=j}function g(j){return l|=qt.Unterminated,T({code:"unterminated",format:{token:ab[j]}}),o=j}function x(){l|=qt.NonAscii;let j=r.charCodeAt(i);if(CO(j))return N();let H=r.codePointAt(i);if(Em(H))return Oe(H);return v()}function v(){return o=D(w.Invalid),T({code:"invalid-character"}),o}function D(j){let H=r.codePointAt(i);return o=b(j,Jg(H))}function T(j,H,ge){let fe=tn({...j,target:{file:n,pos:H??a,end:ge??i}});t(fe)}function N(){do i++;while(!c()&&Fu(r.charCodeAt(i)));return o=w.Whitespace}function O(){return i++,C()}function C(){if(X(),!c()&&r.charCodeAt(i)===ne.Dot)i++,te();if(!c()&&r.charCodeAt(i)===ne.e){i++;let j=r.charCodeAt(i);if(j===ne.Plus||j===ne.Minus)i++;te()}return o=w.NumericLiteral}function X(){do i++;while(!c()&&Sm(r.charCodeAt(i)))}function te(){if(c()||!Sm(r.charCodeAt(i))){T({code:"digit-expected"});return}X()}function L(){if(i+=2,c()||!MO(r.charCodeAt(i)))return T({code:"hex-digit-expected"}),o=w.NumericLiteral;do i++;while(!c()&&MO(r.charCodeAt(i)));return o=w.NumericLiteral}function Y(){if(i+=2,c()||!LO(r.charCodeAt(i)))return T({code:"binary-digit-expected"}),o=w.NumericLiteral;do i++;while(!c()&&LO(r.charCodeAt(i)));return o=w.NumericLiteral}function me(){return i=FTe(r,i,s),o=w.SingleLineComment}function I(){if(o=w.MultiLineComment,d(2)===ne.Asterisk)l|=qt.DocComment;let[j,H]=CTe(r,i);return i=j,H?o:g(o)}function Z(){i++;e:for(;!c();i++)switch(r.charCodeAt(i)){case ne.Backtick:return i++,o=w.DocCodeSpan;case ne.CarriageReturn:case ne.LineFeed:break e}return g(w.DocCodeSpan)}function pe(j){if(j&qt.TripleQuoted)i+=3;else i++;return je(j,w.StringTemplateHead,w.StringLiteral)}function de(j){return i++,je(j,w.StringTemplateMiddle,w.StringTemplateTail)}function je(j,H,ge){let fe=j&qt.TripleQuoted;l=j;e:for(;!c();i++)switch(r.charCodeAt(i)){case ne.Backslash:if(l|=qt.Escaped,i++,c())break e;continue;case ne.DoubleQuote:if(fe)if(d(1)===ne.DoubleQuote&&d(2)===ne.DoubleQuote)return i+=3,o=ge,ge;else continue;else return i++,o=ge,ge;case ne.$:if(d(1)===ne.OpenBrace)return i+=2,o=H,H;continue;case ne.CarriageReturn:case ne.LineFeed:if(fe)continue;else break e}return g(ge)}function be(j,H){switch(j){case w.StringLiteral:case w.StringTemplateHead:return H&qt.TripleQuoted?3:1;default:return 1}}function Ie(j,H){switch(j){case w.StringLiteral:case w.StringTemplateTail:return H&qt.TripleQuoted?3:1;default:return 2}}function J(j,H){if(H&qt.TripleQuoted){let Pe=a,Se=i,[Ce,Bt]=ce(Pe,Se);return Le(Pe,Se,Ce,Bt,j,H)}let ge=be(j,H),fe=Ie(j,H),W=a+ge,ye=H&qt.Unterminated?i:i-fe;if(H&qt.Escaped)return lt(W,ye);return r.substring(W,ye)}function _e(){let j=l&qt.Backticked?a+1:a,H=l&qt.Backticked&&!(l&qt.Unterminated)?i-1:i,ge=l&qt.Escaped?lt(j,H):r.substring(j,H);if(l&qt.NonAscii)return ge.normalize("NFC");return ge}function ue(){if(l&qt.Escaped){let j=a,H=i,ge="",fe=j;while(fej&&Fu(r.charCodeAt(H-1)))H--;let fe=H;if(sl(r.charCodeAt(H-1))){if(Ke(H-2,0,H))H--;H--}return[fe,ge]}function Le(j,H,ge,fe,W,ye){let Pe=be(W,ye),Se=Ie(W,ye);if(j=j+Pe,H=ye&qt.Unterminated?H:H-Se,W===w.StringLiteral||W===w.StringTemplateHead){while(jj&&Fu(r.charCodeAt(H-1)))H--;if(sl(r.charCodeAt(H-1))){if(Ke(H-2,j,H))H--;H--}else T({code:"no-new-line-end-triple-quote",codefixes:[jw({file:n,pos:a,end:i})]})}let Ce=!1;if(W===w.StringTemplateMiddle||W===w.StringTemplateTail)Ce=!0;let Bt="",_=j;while(_=H&&jne.MaxAscii){let ge=r.codePointAt(i);if(Tm(ge))return Ne(ge)}break}if(j>=ob.MinLength&&j<=ob.MaxLength){let H=Mw.get(u());if(H)return o=H}return o=w.Identifier}function ke(){let j;do if(i++,c())return o=w.Identifier;while(mw(j=r.charCodeAt(i)));if(j>ne.MaxAscii){let H=r.codePointAt(i);if(Tm(H))return Ne(H)}return o=w.Identifier}function Re(){i++,l|=qt.Backticked;e:for(;!c();i++){let j=r.charCodeAt(i);switch(j){case ne.Backslash:i++,l|=qt.Escaped;continue;case ne.Backtick:return i++,o=w.Identifier;case ne.CarriageReturn:case ne.LineFeed:break e;default:if(j>ne.MaxAscii)l|=qt.NonAscii}}return g(w.Identifier)}function Ne(j){l|=qt.NonAscii;let H=j;do i+=Jg(H);while(!c()&&Gg(H=r.codePointAt(i)));return o=w.Identifier}function G(){return c7(r,i,s)}function V(){let j=r.charCodeAt(i);if(i+=Cw,T({code:"conflict-marker"}),j===ne.LessThan||j===ne.GreaterThan)while(i=0&&n{rc();l7();vt();Yn();Fw();ol();(function(e){e[e.None=0]="None",e[e.Invalid=1]="Invalid",e[e.EndOfFile=2]="EndOfFile",e[e.Identifier=3]="Identifier",e[e.NumericLiteral=4]="NumericLiteral",e[e.StringLiteral=5]="StringLiteral",e[e.StringTemplateHead=6]="StringTemplateHead",e[e.StringTemplateMiddle=7]="StringTemplateMiddle",e[e.StringTemplateTail=8]="StringTemplateTail",e[e.__StartTrivia=9]="__StartTrivia",e[e.SingleLineComment=9]="SingleLineComment",e[e.MultiLineComment=10]="MultiLineComment",e[e.NewLine=11]="NewLine",e[e.Whitespace=12]="Whitespace",e[e.ConflictMarker=13]="ConflictMarker",e[e.__EndTrivia=14]="__EndTrivia",e[e.__StartDocComment=14]="__StartDocComment",e[e.DocText=14]="DocText",e[e.DocCodeSpan=15]="DocCodeSpan",e[e.DocCodeFenceDelimiter=16]="DocCodeFenceDelimiter",e[e.__EndDocComment=17]="__EndDocComment",e[e.__StartPunctuation=17]="__StartPunctuation",e[e.OpenBrace=17]="OpenBrace",e[e.CloseBrace=18]="CloseBrace",e[e.OpenParen=19]="OpenParen",e[e.CloseParen=20]="CloseParen",e[e.OpenBracket=21]="OpenBracket",e[e.CloseBracket=22]="CloseBracket",e[e.Dot=23]="Dot",e[e.Ellipsis=24]="Ellipsis",e[e.Semicolon=25]="Semicolon",e[e.Comma=26]="Comma",e[e.LessThan=27]="LessThan",e[e.GreaterThan=28]="GreaterThan",e[e.Equals=29]="Equals",e[e.Ampersand=30]="Ampersand",e[e.Bar=31]="Bar",e[e.Question=32]="Question",e[e.Colon=33]="Colon",e[e.ColonColon=34]="ColonColon",e[e.At=35]="At",e[e.AtAt=36]="AtAt",e[e.Hash=37]="Hash",e[e.HashBrace=38]="HashBrace",e[e.HashBracket=39]="HashBracket",e[e.Star=40]="Star",e[e.ForwardSlash=41]="ForwardSlash",e[e.Plus=42]="Plus",e[e.Hyphen=43]="Hyphen",e[e.Exclamation=44]="Exclamation",e[e.LessThanEquals=45]="LessThanEquals",e[e.GreaterThanEquals=46]="GreaterThanEquals",e[e.AmpsersandAmpersand=47]="AmpsersandAmpersand",e[e.BarBar=48]="BarBar",e[e.EqualsEquals=49]="EqualsEquals",e[e.ExclamationEquals=50]="ExclamationEquals",e[e.EqualsGreaterThan=51]="EqualsGreaterThan",e[e.__EndPunctuation=52]="__EndPunctuation",e[e.__StartKeyword=52]="__StartKeyword",e[e.__StartStatementKeyword=52]="__StartStatementKeyword",e[e.ImportKeyword=52]="ImportKeyword",e[e.ModelKeyword=53]="ModelKeyword",e[e.ScalarKeyword=54]="ScalarKeyword",e[e.NamespaceKeyword=55]="NamespaceKeyword",e[e.UsingKeyword=56]="UsingKeyword",e[e.OpKeyword=57]="OpKeyword",e[e.EnumKeyword=58]="EnumKeyword",e[e.AliasKeyword=59]="AliasKeyword",e[e.IsKeyword=60]="IsKeyword",e[e.InterfaceKeyword=61]="InterfaceKeyword",e[e.UnionKeyword=62]="UnionKeyword",e[e.ProjectionKeyword=63]="ProjectionKeyword",e[e.ElseKeyword=64]="ElseKeyword",e[e.IfKeyword=65]="IfKeyword",e[e.DecKeyword=66]="DecKeyword",e[e.ConstKeyword=67]="ConstKeyword",e[e.InitKeyword=68]="InitKeyword",e[e.__EndStatementKeyword=69]="__EndStatementKeyword",e[e.__StartModifierKeyword=69]="__StartModifierKeyword",e[e.ExternKeyword=69]="ExternKeyword",e[e.InternalKeyword=70]="InternalKeyword",e[e.AutoKeyword=71]="AutoKeyword",e[e.__EndModifierKeyword=72]="__EndModifierKeyword",e[e.ExtendsKeyword=72]="ExtendsKeyword",e[e.FnKeyword=73]="FnKeyword",e[e.TrueKeyword=74]="TrueKeyword",e[e.FalseKeyword=75]="FalseKeyword",e[e.ReturnKeyword=76]="ReturnKeyword",e[e.VoidKeyword=77]="VoidKeyword",e[e.NeverKeyword=78]="NeverKeyword",e[e.UnknownKeyword=79]="UnknownKeyword",e[e.ValueOfKeyword=80]="ValueOfKeyword",e[e.TypeOfKeyword=81]="TypeOfKeyword",e[e.__EndKeyword=82]="__EndKeyword",e[e.__StartReservedKeyword=82]="__StartReservedKeyword",e[e.StatemachineKeyword=82]="StatemachineKeyword",e[e.MacroKeyword=83]="MacroKeyword",e[e.PackageKeyword=84]="PackageKeyword",e[e.MetadataKeyword=85]="MetadataKeyword",e[e.EnvKeyword=86]="EnvKeyword",e[e.ArgKeyword=87]="ArgKeyword",e[e.DeclareKeyword=88]="DeclareKeyword",e[e.ArrayKeyword=89]="ArrayKeyword",e[e.StructKeyword=90]="StructKeyword",e[e.RecordKeyword=91]="RecordKeyword",e[e.ModuleKeyword=92]="ModuleKeyword",e[e.ModKeyword=93]="ModKeyword",e[e.SymKeyword=94]="SymKeyword",e[e.ContextKeyword=95]="ContextKeyword",e[e.PropKeyword=96]="PropKeyword",e[e.PropertyKeyword=97]="PropertyKeyword",e[e.ScenarioKeyword=98]="ScenarioKeyword",e[e.PubKeyword=99]="PubKeyword",e[e.SubKeyword=100]="SubKeyword",e[e.TypeRefKeyword=101]="TypeRefKeyword",e[e.TraitKeyword=102]="TraitKeyword",e[e.ThisKeyword=103]="ThisKeyword",e[e.SelfKeyword=104]="SelfKeyword",e[e.SuperKeyword=105]="SuperKeyword",e[e.KeyofKeyword=106]="KeyofKeyword",e[e.WithKeyword=107]="WithKeyword",e[e.ImplementsKeyword=108]="ImplementsKeyword",e[e.ImplKeyword=109]="ImplKeyword",e[e.SatisfiesKeyword=110]="SatisfiesKeyword",e[e.FlagKeyword=111]="FlagKeyword",e[e.PartialKeyword=112]="PartialKeyword",e[e.PrivateKeyword=113]="PrivateKeyword",e[e.PublicKeyword=114]="PublicKeyword",e[e.ProtectedKeyword=115]="ProtectedKeyword",e[e.SealedKeyword=116]="SealedKeyword",e[e.LocalKeyword=117]="LocalKeyword",e[e.AsyncKeyword=118]="AsyncKeyword",e[e.__EndReservedKeyword=119]="__EndReservedKeyword",e[e.__Count=119]="__Count"})(w||(w={}));ab=CTe([[w.None,"none"],[w.Invalid,"invalid"],[w.EndOfFile,"end of file"],[w.SingleLineComment,"single-line comment"],[w.MultiLineComment,"multi-line comment"],[w.ConflictMarker,"conflict marker"],[w.NumericLiteral,"numeric literal"],[w.StringLiteral,"string literal"],[w.StringTemplateHead,"string template head"],[w.StringTemplateMiddle,"string template middle"],[w.StringTemplateTail,"string template tail"],[w.NewLine,"newline"],[w.Whitespace,"whitespace"],[w.DocCodeFenceDelimiter,"doc code fence delimiter"],[w.DocCodeSpan,"doc code span"],[w.DocText,"doc text"],[w.OpenBrace,"'{'"],[w.CloseBrace,"'}'"],[w.OpenParen,"'('"],[w.CloseParen,"')'"],[w.OpenBracket,"'['"],[w.CloseBracket,"']'"],[w.Dot,"'.'"],[w.Ellipsis,"'...'"],[w.Semicolon,"';'"],[w.Comma,"','"],[w.LessThan,"'<'"],[w.GreaterThan,"'>'"],[w.Equals,"'='"],[w.Ampersand,"'&'"],[w.Bar,"'|'"],[w.Question,"'?'"],[w.Colon,"':'"],[w.ColonColon,"'::'"],[w.At,"'@'"],[w.AtAt,"'@@'"],[w.Hash,"'#'"],[w.HashBrace,"'#{'"],[w.HashBracket,"'#['"],[w.Star,"'*'"],[w.ForwardSlash,"'/'"],[w.Plus,"'+'"],[w.Hyphen,"'-'"],[w.Exclamation,"'!'"],[w.LessThanEquals,"'<='"],[w.GreaterThanEquals,"'>='"],[w.AmpsersandAmpersand,"'&&'"],[w.BarBar,"'||'"],[w.EqualsEquals,"'=='"],[w.ExclamationEquals,"'!='"],[w.EqualsGreaterThan,"'=>'"],[w.Identifier,"identifier"],[w.ImportKeyword,"'import'"],[w.ModelKeyword,"'model'"],[w.ScalarKeyword,"'scalar'"],[w.NamespaceKeyword,"'namespace'"],[w.UsingKeyword,"'using'"],[w.OpKeyword,"'op'"],[w.EnumKeyword,"'enum'"],[w.AliasKeyword,"'alias'"],[w.IsKeyword,"'is'"],[w.InterfaceKeyword,"'interface'"],[w.UnionKeyword,"'union'"],[w.ProjectionKeyword,"'projection'"],[w.ElseKeyword,"'else'"],[w.IfKeyword,"'if'"],[w.DecKeyword,"'dec'"],[w.FnKeyword,"'fn'"],[w.ValueOfKeyword,"'valueof'"],[w.TypeOfKeyword,"'typeof'"],[w.ConstKeyword,"'const'"],[w.InitKeyword,"'init'"],[w.ExtendsKeyword,"'extends'"],[w.TrueKeyword,"'true'"],[w.FalseKeyword,"'false'"],[w.ReturnKeyword,"'return'"],[w.VoidKeyword,"'void'"],[w.NeverKeyword,"'never'"],[w.UnknownKeyword,"'unknown'"],[w.ExternKeyword,"'extern'"],[w.AutoKeyword,"'auto'"],[w.StatemachineKeyword,"'statemachine'"],[w.MacroKeyword,"'macro'"],[w.PackageKeyword,"'package'"],[w.MetadataKeyword,"'metadata'"],[w.EnvKeyword,"'env'"],[w.ArgKeyword,"'arg'"],[w.DeclareKeyword,"'declare'"],[w.ArrayKeyword,"'array'"],[w.StructKeyword,"'struct'"],[w.RecordKeyword,"'record'"],[w.ModuleKeyword,"'module'"],[w.ModKeyword,"'mod'"],[w.SymKeyword,"'sym'"],[w.ContextKeyword,"'context'"],[w.PropKeyword,"'prop'"],[w.PropertyKeyword,"'property'"],[w.ScenarioKeyword,"'scenario'"],[w.PubKeyword,"'pub'"],[w.SubKeyword,"'sub'"],[w.TypeRefKeyword,"'typeref'"],[w.TraitKeyword,"'trait'"],[w.ThisKeyword,"'this'"],[w.SelfKeyword,"'self'"],[w.SuperKeyword,"'super'"],[w.KeyofKeyword,"'keyof'"],[w.WithKeyword,"'with'"],[w.ImplementsKeyword,"'implements'"],[w.ImplKeyword,"'impl'"],[w.SatisfiesKeyword,"'satisfies'"],[w.FlagKeyword,"'flag'"],[w.PartialKeyword,"'partial'"],[w.PrivateKeyword,"'private'"],[w.PublicKeyword,"'public'"],[w.ProtectedKeyword,"'protected'"],[w.InternalKeyword,"'internal'"],[w.SealedKeyword,"'sealed'"],[w.LocalKeyword,"'local'"],[w.AsyncKeyword,"'async'"]]),Mw=new Map([["import",w.ImportKeyword],["model",w.ModelKeyword],["scalar",w.ScalarKeyword],["namespace",w.NamespaceKeyword],["interface",w.InterfaceKeyword],["union",w.UnionKeyword],["if",w.IfKeyword],["else",w.ElseKeyword],["projection",w.ProjectionKeyword],["using",w.UsingKeyword],["op",w.OpKeyword],["extends",w.ExtendsKeyword],["is",w.IsKeyword],["enum",w.EnumKeyword],["alias",w.AliasKeyword],["dec",w.DecKeyword],["fn",w.FnKeyword],["valueof",w.ValueOfKeyword],["typeof",w.TypeOfKeyword],["const",w.ConstKeyword],["init",w.InitKeyword],["true",w.TrueKeyword],["false",w.FalseKeyword],["return",w.ReturnKeyword],["void",w.VoidKeyword],["never",w.NeverKeyword],["unknown",w.UnknownKeyword],["extern",w.ExternKeyword],["auto",w.AutoKeyword],["internal",w.InternalKeyword],["statemachine",w.StatemachineKeyword],["macro",w.MacroKeyword],["package",w.PackageKeyword],["metadata",w.MetadataKeyword],["env",w.EnvKeyword],["arg",w.ArgKeyword],["declare",w.DeclareKeyword],["array",w.ArrayKeyword],["struct",w.StructKeyword],["record",w.RecordKeyword],["module",w.ModuleKeyword],["mod",w.ModKeyword],["sym",w.SymKeyword],["context",w.ContextKeyword],["prop",w.PropKeyword],["property",w.PropertyKeyword],["scenario",w.ScenarioKeyword],["pub",w.PubKeyword],["sub",w.SubKeyword],["typeref",w.TypeRefKeyword],["trait",w.TraitKeyword],["this",w.ThisKeyword],["self",w.SelfKeyword],["super",w.SuperKeyword],["keyof",w.KeyofKeyword],["with",w.WithKeyword],["implements",w.ImplementsKeyword],["impl",w.ImplKeyword],["satisfies",w.SatisfiesKeyword],["flag",w.FlagKeyword],["partial",w.PartialKeyword],["private",w.PrivateKeyword],["public",w.PublicKeyword],["protected",w.ProtectedKeyword],["sealed",w.SealedKeyword],["local",w.LocalKeyword],["async",w.AsyncKeyword]]),u7=new Map([["statemachine",w.StatemachineKeyword],["macro",w.MacroKeyword],["package",w.PackageKeyword],["metadata",w.MetadataKeyword],["env",w.EnvKeyword],["arg",w.ArgKeyword],["declare",w.DeclareKeyword],["array",w.ArrayKeyword],["struct",w.StructKeyword],["record",w.RecordKeyword],["module",w.ModuleKeyword],["mod",w.ModuleKeyword],["sym",w.SymKeyword],["context",w.ContextKeyword],["prop",w.PropKeyword],["property",w.PropertyKeyword],["scenario",w.ScenarioKeyword],["trait",w.TraitKeyword],["this",w.ThisKeyword],["self",w.SelfKeyword],["super",w.SuperKeyword],["keyof",w.KeyofKeyword],["with",w.WithKeyword],["implements",w.ImplementsKeyword],["impl",w.ImplKeyword],["satisfies",w.SatisfiesKeyword],["flag",w.FlagKeyword],["partial",w.PartialKeyword],["private",w.PrivateKeyword],["public",w.PublicKeyword],["protected",w.ProtectedKeyword],["sealed",w.SealedKeyword],["local",w.LocalKeyword],["async",w.AsyncKeyword]]);(function(e){e[e.MinLength=2]="MinLength",e[e.MaxLength=12]="MaxLength"})(ob||(ob={}));(function(e){e[e.None=0]="None",e[e.Escaped=1]="Escaped",e[e.TripleQuoted=2]="TripleQuoted",e[e.Unterminated=4]="Unterminated",e[e.NonAscii=8]="NonAscii",e[e.DocComment=16]="DocComment",e[e.Backticked=32]="Backticked"})(qt||(qt={}))});function cl(e,t="disallow-reserved"){if(MTe(e,t))return`\`${e.replace(/\\/g,"\\\\").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\t/g,"\\t").replace(/`/g,"\\`")}\``;else return e}function MTe(e,t){if(e.length===0)return!1;if(t==="allow-reserved"){if(u7.has(e))return!1;let i=Mw.get(e);if(i!==void 0&&cb(i))return!1}if(Mw.has(e))return!0;let n=e.codePointAt(0);if(!yw(n))return!0;let r=0;do r+=Jg(n);while(r{rc();ub();It()});function Ht(e,t){switch(e.kind){case"Namespace":return Um(e,t);case"TemplateParameter":return Ns(e.node.id.sv,t);case"TemplateParameterAccess":return e.path;case"Scalar":return qTe(e,t);case"Model":return m7(e,t);case"ModelProperty":return JTe(e,t);case"Interface":return y7(e,t);case"Operation":return GTe(e,t);case"Enum":return f7(e,t);case"EnumMember":return`${f7(e.enum,t)}.${Ns(e.name,t)}`;case"Union":return BTe(e,t);case"UnionVariant":return Ht(e.type,t);case"Tuple":return"["+e.values.map((n)=>Ht(n,t)).join(", ")+"]";case"StringTemplate":return HTe(e);case"String":return`"${e.value}"`;case"Number":return e.valueAsString;case"Boolean":return e.value.toString();case"Intrinsic":return e.name;case"FunctionType":return LTe(e);default:return"(unnamed type)"}}function LTe(e){return`fn (${[...e.parameters].map((n)=>{let r=n.rest?"...":"",i=n.optional?"?":"";return`${r}${n.name}${i}: ${Uo(n.type)}`}).join(", ")}) => ${Uo(e.returnType)}`}function Uw(e,t){switch(e.valueKind){case"ObjectValue":return`#{${[...e.properties.entries()].map(([n,r])=>`${n}: ${Uw(r.value,t)}`).join(", ")}}`;case"ArrayValue":return`#[${e.values.map((n)=>Uw(n,t)).join(", ")}]`;case"StringValue":return`"${e.value}"`;case"BooleanValue":return`${e.value}`;case"NumericValue":return`${e.value.toString()}`;case"EnumValue":return Ht(e.value);case"NullValue":return"null";case"ScalarValue":return`${Ht(e.type,t)}.${e.value.name}(${e.value.args.map((n)=>Uw(n,t)).join(", ")}})`;case"Function":return`fn ${e.name??""}`}}function Uo(e,t){if(Sa(e))return Uw(e,t);else if(Mo(e))return Ht(e,t);else switch(e.entityKind){case"MixedParameterConstraint":return[e.type&&Uo(e.type),e.valueType&&`valueof ${Uo(e.valueType)}`].filter(Ed).join(" | ");case"Indeterminate":return Ht(e.type,t)}}function Bw(e){return e.name==="TypeSpec"&&e.namespace?.name===""||e.name==="Reflection"&&e.namespace?.name==="TypeSpec"&&e.namespace?.namespace?.name===""}function Um(e,t){let n=t?.namespaceFilter,r=[],i=e;while(i&&i.name!==""){if(n&&!n(i))break;r.unshift(Ns(i.name,t)),i=i.namespace}return r.join(".")}function Lu(e,t){if(e===void 0||Bw(e)||t?.nameOnly===!0)return"";let n=Um(e,t);return n!==""?n+".":""}function f7(e,t){return`${Lu(e.namespace,t)}${Ns(e.name,t)}`}function qTe(e,t){return`${Lu(e.namespace,t)}${Ns(e.name,t)}`}function m7(e,t){let n=Lu(e.namespace,t);if(e.name===""){let i=UTe(e,t);if(i!==void 0)return i}if(e.name===""&&e.properties.size===0)return"{}";if(e.indexer&&e.indexer.key.kind==="Scalar"){if(e.name==="Array"&&KTe(e))return`${Ht(e.indexer.value,t)}[]`}if(e.name==="")return n+`{ ${[...e.properties.values()].map((i)=>`${i.name}: ${Ht(i.type,t)}`).join(", ")} }`;let r=n+Ns(e.name,t);if(Lo(e)){let i=e.templateMapper.args.map((s)=>Uo(s,t));return`${r}<${i.join(", ")}>`}else if(e.node?.templateParameters?.length>0){let i=e.node.templateParameters.map((s)=>{let o=Aw(s);return Ns(s.id.sv,t,o)});return`${r}<${i.join(", ")}>`}else return r}function UTe(e,t){let n=e.node;if(n?.kind!==re.ModelExpression)return;let r=n.parent;if(r?.kind!==re.OperationSignatureDeclaration||r.parameters!==n)return;let i=r.parent;if(i?.kind!==re.OperationStatement)return;let s=Ns(i.id.sv,t);if(t?.nameOnly===!0)return`${s}::parameters`;let o=i.parent;return`${o?.kind===re.InterfaceStatement?`${Lu(e.namespace,t)}${Ns(o.id.sv,t)}.`:Lu(e.namespace,t)}${s}::parameters`}function BTe(e,t){let n=e.expression?"":Lu(e.namespace,t),r=e.name?Ns(e.name,t):[...e.variants.values()].map((i)=>Ht(i.type,t)).join(" | ");return n+r}function VTe(e){return e.name==="TypeSpec"&&e.namespace?.name===""}function KTe(e){return Boolean(e.namespace&&VTe(e.namespace))}function JTe(e,t){if(t?.nameOnly===!0)return e.name;return`${(e.model?m7(e.model,t):void 0)??"(anonymous model)"}.${e.name}`}function y7(e,t){let n=Ns(e.name,t);if(Lo(e))n+=`<${e.templateMapper.args.map((r)=>Uo(r,t)).join(", ")}>`;else if(e.node&&e.node.templateParameters.length>0){let r=e.node.templateParameters.map((i)=>{let s=Aw(i);return Ns(i.id.sv,t,s)});n+=`<${r.join(", ")}>`}return`${Lu(e.namespace,t)}${n}`}function GTe(e,t){let n=Ns(e.name,t);if(e.node&&e.node.templateParameters.length>0){let r=e.node.templateParameters.map((i)=>Ns(i.id.sv,t));n+=`<${r.join(", ")}>`}if(t?.nameOnly===!0)return n;else return`${e.interface?y7(e.interface,t)+".":Lu(e.namespace,t)}${n}`}function Ns(e,t,n){return n??(t?.printable?cl(e):e)}function HTe(e){if(e.stringValue)return`"${e.stringValue}"`;return"string"}var cc=q(()=>{Gt();yr();It();Rw();Mu()});function pb(e){let t=e.match(zTe);if(t==null)return;return{type:t[1],...WTe(t[2])}}function WTe(e){if(!e.includes("+"))return{subtype:e};let[t,n]=e.split("+",2);return{subtype:t,suffix:n}}var zTe;var aP=q(()=>{zTe=/^(application|audio|font|example|image|message|model|multipart|text|video|x-(?:[0-9A-Za-z!#$%&'*+.^_`|~-]+))\/([0-9A-Za-z!#$%&'*+.^_`|~-]+)$/});var Vw=()=>{};var Nn=q(()=>{Vw();Gt()});function fb(e,t){return db(e,t)!==void 0}var db,g7;var Kw=q(()=>{Nn();[db,g7]=ze(Pt("key"))});function Jw(e,t,n,r){let i=b7(e.program,t);if(i===void 0)i=new Map,XTe(e.program,t,i);let s=pb(n);if(s===void 0)gn(e.program,{code:"invalid-mime-type",format:{mimeType:n},target:e.getArgumentTarget(0)});else if(s.suffix)gn(e.program,{code:"no-mime-type-suffix",format:{mimeType:n,suffix:s.suffix},target:e.getArgumentTarget(0)});i.set(n,r)}function ZTe(e,t,n){let r=pb(n);if(r===void 0)return;let i=r?.suffix?`${r.type}/${r.suffix}`:n;return b7(e,t)?.get(i)}function mb(e,t,n){return ZTe(e,t,n)??t.name}var b7,XTe,Vpt;var Gw=q(()=>{Yn();aP();Nn();[b7,XTe,Vpt]=ze(Pt("encodedName"))});function yb(e,t,n){let r=tSe(t,n);Bo(e,r)}function tSe(e,t={}){return{visited:new Set,emit:(n,...r)=>e[n]?.(...r),options:nSe(t)}}function nSe(e){return{...eSe,...e}}function v7(e,t){if(t.emit("namespace",e)===Lr.NoRecursion)return;for(let n of e.models.values())Hw(n,t);for(let n of e.scalars.values())uP(n,t);for(let n of e.operations.values())cP(n,t);for(let n of e.namespaces.values())if(!(e.name==="TypeSpec"&&n.name==="Prototypes"))v7(n,t);for(let n of e.unions.values())D7(n,t);for(let n of e.interfaces.values())x7(n,t);for(let n of e.enums.values())w7(n,t);for(let n of e.decoratorDeclarations.values())S7(n,t);for(let n of e.functionDeclarations.values())k7(n,t);t.emit("exitNamespace",e)}function Ai(e,t){if(e.has(t))return!0;return e.add(t),!1}function zw(e,t){if(e.options.includeTemplateDeclaration)return t.isFinished||oc(t);else return t.isFinished}function cP(e,t){if(Ai(t.visited,e))return;if(!zw(t,e))return;if(t.emit("operation",e)===Lr.NoRecursion)return;for(let n of e.parameters.properties.values())Bo(n,t);if(Bo(e.returnType,t),e.sourceOperation)Bo(e.sourceOperation,t);t.emit("exitOperation",e)}function Hw(e,t){if(Ai(t.visited,e))return;if(!zw(t,e))return;if(t.emit("model",e)===Lr.NoRecursion)return;for(let n of e.properties.values())_7(n,t);if(e.baseModel)Hw(e.baseModel,t);if(e.indexer&&e.indexer.value)Bo(e.indexer.value,t);if(t.options.visitDerivedTypes)for(let n of e.derivedModels)Hw(n,t);t.emit("exitModel",e)}function _7(e,t){if(Ai(t.visited,e))return;if(t.emit("modelProperty",e)===Lr.NoRecursion)return;Bo(e.type,t),t.emit("exitModelProperty",e)}function uP(e,t){if(Ai(t.visited,e))return;if(t.emit("scalar",e)===Lr.NoRecursion)return;if(e.baseScalar)uP(e.baseScalar,t);for(let n of e.constructors.values())E7(n,t);t.emit("exitScalar",e)}function x7(e,t){if(Ai(t.visited,e))return;if(!zw(t,e))return;t.emit("interface",e);for(let n of e.operations.values())cP(n,t);t.emit("exitInterface",e)}function w7(e,t){if(Ai(t.visited,e))return;t.emit("enum",e);for(let n of e.members.values())Bo(n,t);t.emit("exitEnum",e)}function D7(e,t){if(Ai(t.visited,e))return;if(!zw(t,e))return;if(t.emit("union",e)===Lr.NoRecursion)return;if(e.baseType)Bo(e.baseType,t);for(let n of e.variants.values())T7(n,t);t.emit("exitUnion",e)}function T7(e,t){if(Ai(t.visited,e))return;if(t.emit("unionVariant",e)===Lr.NoRecursion)return;Bo(e.type,t),t.emit("exitUnionVariant",e)}function rSe(e,t){if(Ai(t.visited,e))return;if(t.emit("tuple",e)===Lr.NoRecursion)return;for(let n of e.values)Bo(n,t);t.emit("exitTuple",e)}function iSe(e,t){if(Ai(t.visited,e))return;if(t.emit("stringTemplate",e)===Lr.NoRecursion)return;for(let n of e.spans)Bo(n,t)}function sSe(e,t){if(Ai(t.visited,e))return;if(t.emit("stringTemplateSpan",e)===Lr.NoRecursion)return;Bo(e.type,t)}function oSe(e,t){if(Ai(t.visited,e))return;if(t.emit("templateParameter",e)===Lr.NoRecursion)return;t.emit("exitTemplateParameter",e)}function aSe(e,t){if(Ai(t.visited,e))return;if(t.emit("templateParameterAccess",e)===Lr.NoRecursion)return;t.emit("exitTemplateParameterAccess",e)}function S7(e,t){if(Ai(t.visited,e))return;if(t.emit("decorator",e)===Lr.NoRecursion)return}function E7(e,t){if(Ai(t.visited,e))return;if(t.emit("scalarConstructor",e)===Lr.NoRecursion)return}function k7(e,t){if(Ai(t.visited,e))return;if(t.emit("function",e)===Lr.NoRecursion)return}function Bo(e,t){if(e.entityKind==="Type")switch(e.kind){case"Model":return Hw(e,t);case"Scalar":return uP(e,t);case"ModelProperty":return _7(e,t);case"Namespace":return v7(e,t);case"Interface":return x7(e,t);case"Enum":return w7(e,t);case"Operation":return cP(e,t);case"Union":return D7(e,t);case"UnionVariant":return T7(e,t);case"Tuple":return rSe(e,t);case"StringTemplate":return iSe(e,t);case"StringTemplateSpan":return sSe(e,t);case"TemplateParameter":return oSe(e,t);case"TemplateParameterAccess":return aSe(e,t);case"Decorator":return S7(e,t);case"ScalarConstructor":return E7(e,t);case"FunctionParameter":case"FunctionType":case"Boolean":case"EnumMember":case"Intrinsic":case"Number":case"String":return;default:let n=e;return}else{if(e.valueKind==="Function")return k7(e,t);return}}function Rd(e,t){while(e.baseModel){if(e.properties.has(t))return e.properties.get(t);e=e.baseModel}return e.properties.get(t)}var eSe;var hb=q(()=>{yr();It();eSe={includeTemplateDeclaration:!1}});var pP=q(()=>{vt();hb();yr();ul()});function O7(e,t,n,r){let i=Ct(),s=r==="input"?gSe:bSe,o=new Ws,a={};gb(n,(l,c)=>{let u=i.pipe(vSe(e,l));if(u===void 0)return;if(o.track(u,l),s.has(u))a[u]={property:l,path:c};else i.add(tn({code:"invalid-paging-prop",messageId:r==="input"?"input":"output",format:{kind:u},target:l}))});for(let[l,c]of o.entries())for(let u of c)i.add(tn({code:"duplicate-paging-prop",format:{kind:l,operationName:t.name},target:u}));return i.wrap(a)}function Ww(e,t){let n=Ct(),r={input:n.pipe(O7(e,t,t.parameters,"input")),output:n.pipe(O7(e,t,t.returnType,"output"))};if(r.output.pageItems===void 0)return n.add(tn({code:"missing-paging-items",format:{operationName:t.name},target:t})),n.wrap(void 0);return n.wrap(r)}function gb(e,t,n=[],r=new Set){if(r.has(e))return;switch(r.add(e),e.kind){case"Model":for(let i of e.properties.values())t(i,[...n,i]),gb(i.type,t,[...n,i],r);if(e.baseModel)gb(e.baseModel,t,n,r);break;case"Union":for(let i of e.variants.values())gb(i,t,n,r);break;case"UnionVariant":gb(e.type,t,n,r);break}}function vSe(e,t){let n=[],r={offset:lSe(e,t),pageIndex:cSe(e,t),pageItems:pSe(e,t),pageSize:uSe(e,t),continuationToken:dSe(e,t),nextLink:fSe(e,t),prevLink:mSe(e,t),lastLink:hSe(e,t),firstLink:ySe(e,t)},i=Object.entries(r).filter((s)=>!!s[1]);if(i.length>1)n.push(tn({code:"incompatible-paging-props",format:{kinds:i.map((s)=>s[0]).join(", ")},target:t}));if(i.length===0)return[void 0,n];return[i[0][0],n]}function pl(e,t){let[n,r]=hr(Pt(e));return[n,r,(...s)=>{if(t&&!t(...s))return;let[o,a]=s;r(o.program,a)}]}function dP(e){return(t,n)=>{if(!Qw(t.program,n.type))return gn(t.program,{code:"decorator-wrong-target",messageId:"withExpected",format:{decorator:e,expected:"numeric",to:Ht(n.type)},target:t.decoratorTarget}),!1;return!0}}var P7,adt,$7,lSe,ldt,I7,cSe,cdt,A7,uSe,udt,R7,pSe,pdt,j7,dSe,ddt,F7,fSe,fdt,C7,mSe,mdt,M7,ySe,ydt,L7,hSe,hdt,q7,gSe,bSe;var vb=q(()=>{vt();cc();Yn();hb();yr();Nn();ul();[P7,adt,$7]=pl("list"),[lSe,ldt,I7]=pl("offset",dP("offset")),[cSe,cdt,A7]=pl("pageIndex",dP("pageIndex")),[uSe,udt,R7]=pl("pageSize",dP("pageSize")),[pSe,pdt,j7]=pl("pageItems",(e,t)=>{if(t.type.kind!=="Model"||!ks(t.type))return gn(e.program,{code:"decorator-wrong-target",messageId:"withExpected",format:{decorator:"continuationToken",expected:"Array",to:Ht(t.type)},target:e.decoratorTarget}),!1;return!0}),[dSe,ddt,F7]=pl("continuationToken"),[fSe,fdt,C7]=pl("nextLink"),[mSe,mdt,M7]=pl("prevLink"),[ySe,ydt,L7]=pl("firstLink"),[hSe,hdt,q7]=pl("lastLink"),gSe=new Set(["offset","pageIndex","pageSize","continuationToken"]),bSe=new Set(["pageItems","nextLink","prevLink","firstLink","lastLink","continuationToken"])});function B7(e,t,n={}){let i=xSe(e).get(t)??{};_Se(e,t,{...i,...n,type:t})}var U7,_Se,xSe,Yw=(e,t,n)=>{bn(e,t,Yw),B7(e.program,t,n)};var V7=q(()=>{Od();Pd();Nn();[U7,_Se,xSe]=ze(Symbol.for("@typespec/compiler.services"))});function K7(...e){return fP(...e)}function J7(e,t){let n=fP(e,t);if(!n)n=new Map,wSe(e,t,n);return n}function mP(e,t,n,r){let i=J7(e,t),s=i.get(n);if(!s)s=r,i.set(n,s);return s}function z7(e,t){let n=G7(e,t);if(n)return new Set(n);let r=new Set(t.members.values());return H7(e,t,r),new Set(r)}function W7(e,t,n){Qe(!G7(e,t),"The default modifier set for a visibility class may only be set once."),H7(e,t,n)}function Q7(e){let t=new Map;for(let n of e){let r=n.enum,i=t.get(r);if(!i)i=new Set,t.set(r,i);i.add(n)}return t}function Bm(e,t,n){if(DSe.has(e))return!0;return(n?SSe(e,t)?.has(n):!1)||TSe(e,t)}function Xw(e,t,n,r){let i=Q7(n);for(let[s,o]of i.entries()){let a=r?.decoratorTarget??t;if(Bm(e,t,s)){gn(e,{code:"visibility-sealed",format:{propName:t.name},target:a});continue}let l=mP(e,t,s,new Set);for(let c of o)l.add(c)}}function Zw(e,t,n,r){let i=Q7(n);for(let[s,o]of i.entries()){let a=r?.decoratorTarget??t;if(Bm(e,t,s)){gn(e,{code:"visibility-sealed",format:{propName:t.name},target:a});continue}let l=mP(e,t,s,z7(e,s));for(let c of o)l.delete(c)}}function eD(e,t,n,r){let i=r?.decoratorTarget??t;if(Bm(e,t,n)){gn(e,{code:"visibility-sealed",format:{propName:t.name},target:i});return}mP(e,t,n,new Set).clear()}function Vm(e,t,n,r){let i=r?.decoratorTarget??t;if(Bm(e,t,n)){gn(e,{code:"visibility-sealed",format:{propName:t.name},target:i});return}J7(e,t).delete(n)}function Km(e,t,n){return fP(e,t)?.get(n)??z7(e,n)}function _b(e,t,n){let r=n.enum;return Km(e,t,r).has(n)??!1}function NSe(e,t){let n=e[kSe]??={idx:0,map:new WeakMap},r=n.map.get(t);if(r===void 0)r=n.idx++,n.map.set(t,r);return r}function PSe(e,t){let n=e[OSe]??=new WeakMap,r=n.get(t);if(r)return r;r="{";for(let[i,s]of Object.entries(t).sort(([o],[a])=>o.localeCompare(a))){if(!s)continue;r+=`${i}:[`;let o=[];for(let a of s){let l=NSe(e,a.enum);o.push({_enum:l,modifier:a.name})}r+=o.sort(function(l,c){if(l._enum!==c._enum)return l._enum-c._enum;return l.modifier.localeCompare(c.modifier)}).join(",")+"]"}return r+="}",n.set(t,r),r}function pc(e,t,n){if(n.all){for(let r of n.all)if(!_b(e,t,r))return!1}if(n.none){for(let r of n.none)if(_b(e,t,r))return!1}if(n.any){for(let r of n.any)if(_b(e,t,r))return!0;return!1}return!0}var fP,wSe,DSe,TSe,Edt,SSe,kdt,G7,H7,ESe,Jm,kSe,OSe;var tD=q(()=>{vt();Yn();Nn();[fP,wSe]=ze(Pt("visibilityStore"));DSe=new WeakSet,[TSe,Edt]=hr(Pt("propertyVisibilitySealed")),[SSe,kdt]=ze(Pt("sealedVisibilityClasses")),[G7,H7]=ze(Pt("defaultVisibilityModifiers"));ESe=Symbol.for("TypeSpec.Core.VisibilityFilter"),Jm={fromDecoratorArgument(e){return e[ESe]??={all:e.all&&new Set(e.all.map((t)=>t.value)),any:e.any&&new Set(e.any.map((t)=>t.value)),none:e.none&&new Set(e.none.map((t)=>t.value))}},getVisibilityClasses(e){let t=new Set;if(e.all)e.all.forEach((n)=>t.add(n.enum));if(e.any)e.any.forEach((n)=>t.add(n.enum));if(e.none)e.none.forEach((n)=>t.add(n.enum));return t},toCacheKey(e,t){return PSe(e,t)}},kSe=Symbol.for("TypeSpec.Core.enumInternTable");OSe=Symbol.for("TypeSpec.Core.visibilityFilterToStringCache")});function Ea(e){let t=Y7.get(e);if(t)return t;let[n,r]=e.resolveTypeReference("TypeSpec.Lifecycle");return Qe(r.length===0,"Encountered diagnostics when resolving the `TypeSpec.Lifecycle` visibility class enum"),Qe(n.kind==="Enum","Expected `TypeSpec.Visibility.Lifecycle` to be an enum"),Y7.set(e,n),n}var Y7;var yP=q(()=>{vt();Y7=new WeakMap});class xb{#e=new Map;#t;constructor(e){this.#t=e}get(e){return this.#e.get(this.#t(e))}set(e,t){let n=this.#t(e);this.#e.set(n,t)}static objectKeyer(){let e=new WeakMap,t=0;return{getKey(n){if(e.has(n))return e.get(n);let r=t;return t++,e.set(n,r),r}}}}function $Se(e){switch(e.kind){case"TemplateParameter":case"Intrinsic":case"Decorator":case"FunctionParameter":return!1;default:return!0}}function RSe(e){let t=X7.get(e);if(t===void 0)t=new xb(([n,r])=>`${ISe.getKey(n)}-${[...r.values()].map((s)=>ASe.getKey(s)).join("-")}`),X7.set(e,t);return t}function nD(e,t,n){let r=CSe(e,t,{mutateNamespaces:!1}),i=r.mutate(n);if(i===n)return{realm:null,type:n};return{realm:r.realm,type:i}}function wb(e,t,n=!0){FSe(e,t,n)}function CSe(e,t,n){let r=new zs(e,`Mutator realm ${t.map((v)=>v.name).join(", ")}`),i=[],s=RSe(e),o=!1,a=new Set(t),l=[],c=new Set;if(n.mutateNamespaces)o=!0,d(e.getGlobalNamespaceType(),a),o=!1,l.forEach((v)=>v());return{realm:r,mutate:(v)=>d(v,a)};function u(v,D){let T=[],N=new Set(v.values());for(let O of v){let C=O[D.kind];if(!C)continue;let X,te=null,L,Y;if(typeof C==="function")X=C,L=!0,Y=!0;else if(X="mutate"in C?C.mutate:null,te="replace"in C?C.replace:null,C.filter){let me=C.filter(D,e,r);if(me===!0)L=!0,Y=!0;else if(me===!1)L=!1,Y=!0;else L=(me&Qs.DoNotMutate)===0,Y=(me&Qs.DoNotRecur)===0}else L=!0,Y=!0;if(!Y)N.delete(O);if(L)T.push({mutator:O,mutationFn:X,replaceFn:te})}return{mutatorsWithOptions:T,newMutators:N}}function p(v,D,T){let N=D;for(let{mutationFn:O,replaceFn:C}of T){let X=(O??C)(v,N,e,r);if(C&&X!==void 0)N=X}return N}function d(v,D,T=!0){let N=s.get([v,D]);if(N){if(T&&N.kind==="Namespace"&&!c.has(N))c.add(N),b(N,"namespaces",!0,D);return Z(),N}if(!jSe(e,v)&&Co(e,v).type==="compiler"&&!Lo(v))return v;let C=null,{mutatorsWithOptions:X,newMutators:te}=u(D,v),L=X.map((ue)=>ue.mutator),Y=!1;if(X.length===0)if(te.size>0)return i.push(I),s.set([v,D],v),J(),_e(),i.pop(),C??v;else return v;if(Z(),N=s.get([v,L]),N)return N;I();let me=p(v,C,X);if(me!==C)C=me,s.set([v,D],C),s.set([v,L],C);if(te.size>0)if(o&&v.kind==="Namespace")Qe(Y,"Cannot be preparing namespaces and not have cloned it."),de(C),l.push(()=>be(C));else J();if(v.isFinished)Kn(r).type.finishType(C);if(v.kind==="Namespace"&&T)Qe(Y,"Cannot be preparing namespaces and not have cloned it."),je(C);if(v.kind!=="Namespace")_e();return C;function I(){C=Kn(r).type.clone(v),Y=!0,s.set([v,D],C),s.set([v,L],C)}function Z(){for(let ue of i)ue();i.length=0}function pe(ue){if(!n.mutateNamespaces)return;if("namespace"in ue&&ue.namespace){let ce=d(ue.namespace,te,!1);Qe(ce.kind==="Namespace","Expected to be mutated to a namespace"),C.namespace=ce}}function de(ue){f(ue,!0,te),pe(ue)}function je(ue){c.add(ue),b(ue,"namespaces",!0,te)}function be(ue){b(ue,"models",Y,te),b(ue,"operations",Y,te),b(ue,"interfaces",Y,te),b(ue,"enums",Y,te),b(ue,"unions",Y,te),b(ue,"scalars",Y,te)}function Ie(ue){if(b(ue,"properties",Y,te),ue.indexer){let ce=d(ue.indexer.value,te);if(Y)ue.indexer.value=ce}for(let[ce,Le]of ue.sourceModels.entries()){let Ke=d(Le.model,te);if(Y)Tn(ue.sourceModels[ce]).model=Ke}x(ue,"sourceModel",Y,te),x(ue,"baseModel",Y,te),g(ue,"derivedModels",Y,te)}function J(){let ue=C??v;switch(ue.kind){case"Namespace":be(ue);break;case"Model":Ie(ue);break;case"ModelProperty":x(ue,"type",Y,te),x(ue,"sourceProperty",Y,te);break;case"Tuple":g(ue,"values",Y,te);break;case"Operation":x(ue,"parameters",Y,te),x(ue,"returnType",Y,te),x(ue,"sourceOperation",Y,te);break;case"Interface":b(ue,"operations",Y,te);break;case"Enum":b(ue,"members",Y,te);break;case"EnumMember":break;case"Union":b(ue,"variants",Y,te),x(ue,"baseType",Y,te);break;case"UnionVariant":x(ue,"type",Y,te);break;case"Scalar":b(ue,"constructors",Y,te),x(ue,"baseScalar",Y,te),g(ue,"derivedScalars",Y,te);break;case"ScalarConstructor":x(ue,"scalar",Y,te);break}if("templateMapper"in ue)h(ue,Y,te);if("decorators"in ue)f(ue,Y,te);pe(ue)}function _e(){let ue=C??v;switch(ue.kind){case"ModelProperty":x(ue,"model",Y,te);break;case"Operation":x(ue,"interface",Y,te);break;case"EnumMember":x(ue,"enum",Y,te);break;case"UnionVariant":x(ue,"union",Y,te);break;case"ScalarConstructor":x(ue,"scalar",Y,te);break}}}function f(v,D,T){for(let[N,O]of v.decorators.entries()){let C=[];for(let X of O.args)C.push({...X,value:m(X.value,T),jsValue:m(X.jsValue,T)});if(D)v.decorators[N]={...O,args:C}}}function m(v,D){if(typeof v==="object"&&v!==null){if(Mo(v))return $Se(v)?d(v,D):v;if(Sa(v))return y(v,D);if(qo(v))return v;if(Array.isArray(v))return v.map((T)=>m(T,D));return Object.entries(v).reduce((T,[N,O])=>({...T,[N]:m(O,D)}),{})}return v}function y(v,D){switch(v.valueKind){case"ObjectValue":let T={...v,properties:new Map,type:m(v.type,D)};for(let[N,O]of v.properties.entries())T.properties.set(N,{...O,value:y(O.value,D)});return T;case"ArrayValue":return{...v,type:m(v.type,D),values:v.values.map((N)=>y(N,D))};case"EnumValue":return{...v,type:m(v.type,D),value:m(v.value,D)};default:return v}}function h(v,D,T){if(v.templateMapper===void 0)return;let N={...v.templateMapper,args:[],map:new Map};for(let O of v.templateMapper.args)Tn(N.args).push(d(O,T));for(let[O,C]of v.templateMapper.map)N.map.set(O,d(C,T));if(D)v.templateMapper=N}function b(v,D,T,N){for(let[O,C]of v[D].entries()){let X=d(C,N);if(T){if(v[D].set(O,X),X.name!==C.name)v[D].rekey(O,X.name)}}}function g(v,D,T,N){for(let[O,C]of v[D].entries()){let X=d(C,N);if(T)v[D][O]=X}}function x(v,D,T,N){if(v[D]===void 0)return;let O=d(v[D],N);if(T)v[D]=O}}var Qs,ISe,ASe,X7,jSe,FSe;var hP=q(()=>{vt();ic();ac();yr();ka();Gt();Pd();(function(e){e[e.MutateAndRecur=0]="MutateAndRecur",e[e.DoNotMutate=1]="DoNotMutate",e[e.DoNotRecur=2]="DoNotRecur"})(Qs||(Qs={}));ISe=xb.objectKeyer(),ASe=xb.objectKeyer(),X7=new WeakMap;[jSe,FSe]=ze(Symbol.for("TypeSpec.Mutators.alwaysMutate"))});function vP(e,t){let n=MSe(e,t);if(!n)n={},LSe(e,t,n);return n}function _P(e,t,n){let r=vP(e,t);if(!r.parameters)return n.parameters(e,t);return Qe(r.parameters.length!==0,"Empty parameter visibility constraint."),{any:new Set(r.parameters)}}function TP(e,t,n,r){let i=Jm.fromDecoratorArgument(n),s=e.program[e5]??={},o=s.byNameTemplate??={},a=r===void 0?s.unnamed??={}:o[r]??={},l=a.byVisibilityFilter??=new Map,c=Jm.toCacheKey(e.program,i),u=l.get(c);if(!u)u=gP(i,{decoratorFn:iD,decoratorName:"@withVisibilityFilter",nameTemplate:r}),l.set(c,u);wb(e.program,t);let{type:p}=dc(e.program,u,t);return wb(e.program,t,!1),Qe(p.kind==="Model","Expected visibility filter mutator to return a Model type."),p}function SP(e,t,n){let r=e.program[e5]??={},i=r.byNameTemplate??={},s=n===void 0?r.unnamed??={}:i[n]??={},o=s.lifecycleUpdate;if(!o){let l=Ea(e.program),c={all:new Set([l.members.get("Update")])},u={any:new Set([l.members.get("Create"),l.members.get("Update")])},p=gP(u,{nameTemplate:n});o=gP(c,{recur:p,decoratorFn:sD,decoratorName:"@withLifecycleUpdate",nameTemplate:n}),s.lifecycleUpdate=o}wb(e.program,t);let{type:a}=dc(e.program,o,t);return wb(e.program,t,!1),Qe(a.kind==="Model","Expected lifecycle update mutator to return a Model type."),a}function dc(e,t,n){let r=t[qSe]??=new WeakMap,i=r.get(n);if(i)return i;let s=nD(e,[t],n);return r.set(n,s),s}function gP(e,t={}){let n=Jm.getVisibilityClasses(e),r=(a,l)=>a.definition?.name===l&&a.definition.namespace.name==="TypeSpec",i=(a,l,c)=>r(a,l)||a.decorator===c,s={name:"VisibilityFilterProperty",ModelProperty:{filter:()=>Qs.DoNotRecur,replace:(a,l,c)=>{let u=!1,p=[];for(let d of a.decorators)if(i(d,"@visibility",jd)||i(d,"@removeVisibility",Hm)){let f=d.args.filter((m)=>{if(m.value.entityKind!=="Value")return!1;let y=m.value.valueKind==="StringValue",h=m.value.valueKind==="EnumValue"&&n.has(m.value.value.enum);return!(y||h)});if(u||=f.length!==d.args.length,f.length>0)p.push({...d,args:f})}else if(!i(d,"@invisible",zm))p.push(d);l.decorators=p,u||=p.length!==a.decorators.length;for(let d of n)Vm(c,l,d);if(Gm(a.type))l.type=dc(c,t.recur??o,a.type).type,u||=l.type!==a.type;return u?l:a}}},o={name:"VisibilityFilter",Union:{filter:()=>Qs.DoNotRecur,replace:(a,l,c)=>{let u=!1;for(let[p,d]of a.variants)if(Gm(d.type)){let f={...d,type:dc(c,o,d.type).type};l.variants.set(p,f),u||=f.type!==d.type}return Z7(l,t.nameTemplate),u?l:a}},Model:{filter:()=>Qs.DoNotRecur,replace:(a,l,c,u)=>{let p=!1;if(a.indexer&&Gm(a.indexer.value)){if(l.indexer={...a.indexer},Tn(l.indexer).value=dc(c,t.recur??o,a.indexer.value).type,Kn(u).array.is(a)&&l.name==="Array"&&l.indexer.value!==a.indexer.value)return Kn(c).array.create(l.indexer.value);if(Kn(u).record.is(a)&&l.name==="Record"&&l.indexer.value!==a.indexer.value)return Kn(c).record.create(l.indexer.value);p||=l.indexer.value!==a.indexer.value}for(let[d,f]of a.properties)if(!pc(c,f,e))l.properties.delete(d),u.remove(l),p=!0;else{let m=dc(c,s,f);l.properties.set(d,m.type),p||=m.type!==f}if(t.decoratorFn)l.decorators=l.decorators.filter((d)=>!(d.decorator===t.decoratorFn||t.decoratorName&&r(d,t.decoratorName))),p||=l.decorators.length!==a.decorators.length;return Z7(l,t.nameTemplate),p?l:a}},ModelProperty:{filter:()=>Qs.DoNotRecur,replace:(a,l,c)=>{if(Gm(a.type))l.type=dc(c,o,a.type).type;return l.type!==a.type?l:a}},UnionVariant:{filter:()=>Qs.DoNotRecur,replace:(a,l,c)=>{if(Gm(a.type))l.type=dc(c,o,a.type).type;return l.type!==a.type?l:a}},Tuple:{filter:()=>Qs.DoNotRecur,replace:(a,l,c)=>{let u=!1;for(let[p,d]of a.values.entries())if(Gm(d))l.values[p]=dc(c,o,d).type,u||=l.values[p]!==d;return u?l:a}}};return o}function Z7(e,t){if(!t||!e.name)return;let n=Im(t,e);e.name=n}function Gm(e){return e.kind==="Model"||e.kind==="Union"||e.kind==="ModelProperty"||e.kind==="UnionVariant"||e.kind==="Tuple"}var bP=(e,t,n)=>{let r=[...t.properties].filter(([i,s])=>fb(e.program,s)&&!K7(e.program,s));for(let[i,s]of r)t.properties.set(i,e.program.checker.cloneType(s,{decorators:[...s.decorators,{decorator:jd,args:[{value:n,jsValue:n}]}]}))},MSe,LSe,Db=(e,t,...n)=>{if(bn(e,t,Db),n.length===0){gn(e.program,{code:"operation-visibility-constraint-empty",messageId:"parameter",target:e.decoratorTarget});return}vP(e.program,t).parameters=n.map((r)=>r.value)},xP=(e,t,...n)=>{if(bn(e,t,Db),n.length===0){gn(e.program,{code:"operation-visibility-constraint-empty",messageId:"returnType",target:e.decoratorTarget});return}vP(e.program,t).returnType=n.map((r)=>r.value)},jd=(e,t,...n)=>{Xw(e.program,t,n.map((r)=>r.value),e)},Hm=(e,t,...n)=>{Zw(e.program,t,n.map((r)=>r.value))},zm=(e,t,n)=>{eD(e.program,t,n)},rD=(e,t,...n)=>{bn(e,t,rD);let r=new Set;for(let i of n)if(i.value.enum!==t)gn(e.program,{code:"default-visibility-not-member",target:e.decoratorTarget});else r.add(i.value);W7(e.program,t,r)},wP=(e,t,...n)=>{let r=n.map((o)=>o.value),i={all:new Set(r)},s=new Set(r.map((o)=>o.enum));$m(t,(o)=>pc(e.program,o,i));for(let o of t.properties.values())for(let a of s)Vm(e.program,o,a)},DP=(e,t)=>{if(!j9(e,t,"@withUpdateableProperties","Model"))return;let n={all:new Set([Ea(e.program).members.get("Update")])};$m(t,(r)=>pc(e.program,r,n))},e5,iD=(e,t,n,r)=>{let i=TP(e,t,n,r);t.properties=i.properties},sD=(e,t,n)=>{let r=SP(e,t,n);t.properties=r.properties},qSe;var EP=q(()=>{Od();vt();Yn();tD();yP();hP();ka();Nn();Gt();Kw();[MSe,LSe]=ze(Pt("operationVisibilityConfig"));e5=Symbol.for("TypeSpec.Core.visibilityFilterMutatorCache");qSe=Symbol.for("TypeSpec.Core.visibilityFilterMutatorResult")});function Zr(e,t){return $w(e,t,"self")?.value}function $P(e,t){return $w(e,t,"returns")?.value}function AP(e,t){return $w(e,t,"errors")?.value}function FP(e,t){let n=e.checker.getStdType("string");return t.kind==="Scalar"&&e.checker.isTypeAssignableTo(t,n,t)[0]}function Qw(e,t){let n=e.checker.getStdType("numeric");return t.kind==="Scalar"&&e.checker.isTypeAssignableTo(t,n,t)[0]}function BSe(e,t){if(t.kind!=="Scalar")return!1;return["utcDateTime","offsetDateTime","plainDate","plainTime","duration"].some((r)=>{let i=e.checker.getStdType(r);return e.checker.isTypeAssignableTo(t,i,t)[0]})}function aD(e,t){if(e.kind==="Union")return[...e.variants.values()].some((n)=>t(n.type));return t(e)}function lD(e,t,n){let r=aD(Om(t),(i)=>Qw(e.program,i)||BSe(e.program,i));if(!r)gn(e.program,{code:"decorator-wrong-target",format:{decorator:n,to:"type it must be a numeric or comparable type"},target:e.decoratorTarget});return r}function cD(e,t,n){let r=Om(t);if(qo(n))n=Kn(e.program).value.createNumeric(n);let[i,s]=Kn(e.program).value.isOfType.withDiagnostics(n,r,e.getArgumentTarget(0));if(!i)e.program.reportDiagnostics(s);return i}function uD(e,t,n){let r=Om(t),i=aD(r,(s)=>FP(e.program,s));if(!i)gn(e.program,{code:"decorator-wrong-target",format:{decorator:n,to:r.kind==="Union"?'a union type that is not string compatible. The union must explicitly include a string type, and all union values should be strings. For example: union Test { string, "A", "B" }':"type it is not a string"},target:e.decoratorTarget});return i}function VSe(e){if(e.kind==="ModelProperty")return e.type;else return e.kind==="Model"?e:e.type}function t5(e,t,n){let r=VSe(t),i=aD(r,(s)=>s.kind==="Model"&&ks(s));if(!i)gn(e.program,{code:"decorator-wrong-target",format:{decorator:n,to:"non Array type"},target:e.decoratorTarget});return i}function fc(e,t){if(t.kind!=="Model")return!1;let n=t;while(n){if(KSe(e,n))return!0;n=n.baseModel}return!1}function dD(e,t){switch(t.kind){case"Scalar":if(t.name==="string"&&t.namespace?.name==="TypeSpec"&&t.namespace.namespace===e.getGlobalNamespaceType())return"text/plain";case"Union":case"Enum":case"Model":{let r=GSe(e,t);if(!r){let i=t.kind==="Model"?t.baseModel:t.kind==="Scalar"?t.baseScalar:void 0;if(i)return dD(e,i)}return r}default:return}}function eEe(e,t,n){let r=e.checker.getStdType("string"),i=n??r;if(typeof t==="string")return{encoding:t,type:i};else if(Sa(t)){let s=t.value;if(s.value&&typeof s.value==="string")return{encoding:s.value,type:i};else return{encoding:Ht(s),type:i}}else{if(t!==r){gn(e,{code:"invalid-encode",messageId:"firstArg",target:t});return}return{type:t}}}function tEe(e,t,n){function r(i,s){let o=e.program.checker;if(!aD(t,(c)=>i.some((u)=>Ts(o.isTypeAssignableTo(c,o.getStdType(u),t)))))gn(e.program,{code:"invalid-encode",messageId:"wrongType",format:{encoding:n.encoding??"string",type:Ht(t),expected:i.join(", ")},target:e.decoratorTarget});if(!s.some((c)=>Ts(o.isTypeAssignableTo(n.type,o.getStdType(c),t)))){let c=Ht(n.type);gn(e.program,{code:"invalid-encode",messageId:["unixTimestamp","seconds","milliseconds"].includes(n.encoding??"string")?"wrongNumericEncodingType":"wrongEncodingType",format:{encoding:n.encoding,type:Ht(t),expected:s.join(", "),actual:c},target:e.decoratorTarget})}}switch(n.encoding){case"rfc3339":return r(["utcDateTime","offsetDateTime"],["string"]);case"rfc7231":return r(["utcDateTime","offsetDateTime"],["string"]);case"unixTimestamp":return r(["utcDateTime"],["integer"]);case"seconds":return r(["duration"],["numeric"]);case"milliseconds":return r(["duration"],["numeric"]);case"base64":return r(["bytes"],["string"]);case"base64url":return r(["bytes"],["string"]);case void 0:return r(["numeric","boolean"],["string"])}}function aEe(e,t){if(e.interface||t.interface)return e.interface===t.interface||e.interface?.node!==void 0&&e.interface?.node===t.interface?.node;return e.namespace===t.namespace||e.namespace?.node!==void 0&&e.namespace?.node===t.namespace?.node}function qu(e,t,n){if(t===void 0||n===void 0)return!0;if(!qo(t)||!qo(n))return!0;if(t.gt(n))return gn(e.program,{code:"invalid-range",format:{start:t.toString(),end:n.toString()},target:e.decoratorTarget}),!1;return!0}function kP(e,t,n,r){let i=e.checker.getValueExactType(t),[s,o]=e.checker.isTypeAssignableTo(i??t.type,n,r);if(!s)e.reportDiagnostics(o);return s}var Tb,USe,OP=(e,t,n,r)=>{if(r)n=Im(n,r);USe(e.program,t,n)},Ys=(e,t,n,r)=>{if(bn(e,t,Ys),r)n=Im(n,r);Lm(e.program,t,"self",{value:n,source:"decorator"})},PP=(e,t,n)=>{bn(e,t,Ys),Lm(e.program,t,"returns",{value:n,source:"decorator"})},IP=(e,t,n)=>{bn(e,t,Ys),Lm(e.program,t,"errors",{value:n,source:"decorator"})},RP=(e,t,n)=>{if(n)console.log(n);console.dir(t,{depth:3})},jP=(e,t,n)=>{if(n)console.log(n);console.log(Ht(t))},KSe,JSe,pD=(e,t)=>{bn(e,t,pD),JSe(e.program,t)},GSe,HSe,CP=(e,t,n)=>{if(bn(e,t,CP),pb(n)===void 0)gn(e.program,{code:"invalid-mime-type",format:{mimeType:n},target:e.getArgumentTarget(0)});HSe(e.program,t,n)},Fd,zSe,fD=(e,t,n)=>{if(bn(e,t,fD),!uD(e,t,"@format"))return;zSe(e.program,t,n)},WSe,QSe,mD=(e,t,n,r)=>{if(bn(e,t,mD),!uD(e,t,"@pattern"))return;try{new RegExp(n)}catch(s){gn(e.program,{code:"invalid-pattern-regex",target:t})}let i={pattern:n,validationMessage:r};QSe(e.program,t,i)},yD=(e,t,n)=>{if(bn(e,t,yD),!uD(e,t,"@minLength")||!qu(e,n,Nw(e.program,t)))return;z9(e.program,t,n)},hD=(e,t,n)=>{if(bn(e,t,hD),!uD(e,t,"@maxLength")||!qu(e,kw(e.program,t),n))return;W9(e.program,t,n)},gD=(e,t,n)=>{if(bn(e,t,gD),!t5(e,t,"@minItems"))return;if(!qu(e,n,Pw(e.program,t)))return;Q9(e.program,t,n)},bD=(e,t,n)=>{if(bn(e,t,bD),!t5(e,t,"@maxItems"))return;if(!qu(e,Ow(e.program,t),n))return;Y9(e.program,t,n)},Wm=(e,t,n)=>{bn(e,t,Wm),Nm(e,t,Ym,Wm);let{program:r}=e;if(!lD(e,t,"@minValue"))return;if(!cD(e,t,n))return;if(!qu(e,n,jm(e.program,t)??Mm(e.program,t)))return;K9(r,t,n)},Qm=(e,t,n)=>{bn(e,t,Qm),Nm(e,t,Xm,Qm);let{program:r}=e;if(!lD(e,t,"@maxValue"))return;if(!cD(e,t,n))return;if(!qu(e,Am(e.program,t)??Cm(e.program,t),n))return;J9(r,t,n)},Ym=(e,t,n)=>{bn(e,t,Ym),Nm(e,t,Wm,Ym);let{program:r}=e;if(!lD(e,t,"@minValueExclusive"))return;if(!cD(e,t,n))return;if(!qu(e,n,jm(e.program,t)??Mm(e.program,t)))return;G9(r,t,n)},Xm=(e,t,n)=>{bn(e,t,Xm),Nm(e,t,Qm,Xm);let{program:r}=e;if(!lD(e,t,"@maxValueExclusive"))return;if(!cD(e,t,n))return;if(!qu(e,Am(e.program,t)??Cm(e.program,t),n))return;H9(r,t,n)},YSe,XSe,vD=(e,t)=>{bn(e,t,vD),XSe(e.program,t)},uc,ZSe,_D=(e,t,n,r)=>{bn(e,t,_D);let i=eEe(e.program,n,r);if(i===void 0)return;let s=Om(t);tEe(e,s,i),ZSe(e.program,t,i)},MP=(e,t)=>{t.properties.forEach((n)=>n.optional=!0)},LP=(e,t,n)=>{let r=new Set;if(n.kind==="String")r.add(n.value);else if(n.kind==="Union"){for(let i of n.variants.values())if(i.type.kind==="String")r.add(i.type.value)}$m(t,(i)=>!r.has(i.name))},qP=(e,t,n)=>{let r=new Set;if(n.kind==="String")r.add(n.value);else if(n.kind==="Union"){for(let i of n.variants.values())if(i.type.kind==="String")r.add(i.type.value)}$m(t,(i)=>r.has(i.name))},UP=(e,t)=>{t.properties.forEach((n)=>{delete n.defaultValue})},nEe,rEe,BP=(e,t,n)=>{let r=nEe(e.program,t);if(r)r.push(n);else rEe(e.program,t,[n])},VP,iEe,KP=(e,t,n,r)=>{if(t.kind==="Model"||t.kind==="Operation"){if(e.decoratorTarget.kind===re.AugmentDecoratorStatement){if(Ts(e.program.checker.resolveTypeReference(e.decoratorTarget.targetType))?.node!==t.node)return}if(e.decoratorTarget.kind===re.DecoratorExpression){if(e.decoratorTarget.parent!==t.node)return}}if(r)n=Im(n,r);iEe(e.program,t,n)},JP=(e,t,n)=>{if(t.optional){gn(e.program,{code:"no-optional-key",format:{propertyName:t.name},target:t});return}g7(e.program,t,n||t.name)},xD,sEe,GP,oEe,HP=(e,t,n)=>{let[r,i]=e.program.checker.isTypeAssignableTo(t.parameters,n.parameters,t);if(!r)e.program.reportDiagnostics(i);let[s,o]=e.program.checker.isTypeAssignableTo(t.returnType,n.returnType,t);if(!s)e.program.reportDiagnostics(o);if(!aEe(t,n))gn(e.program,{code:"overload-same-parent",target:e.decoratorTarget});oEe(e.program,t,n);let a=xD(e.program,n)||[];sEe(e.program,n,a.concat(t))},zP=(e,t,n={})=>{t7(e.program,t,{envelope:"object",discriminatorPropertyName:"kind",envelopePropertyName:"value",...n});let[r,i]=Ad(e.program,t);e.program.reportDiagnostics(i)},WP=(e,t,n)=>{Z9(e.program,t,{propertyName:n})},lEe,cEe,wD=(e,t,n,r)=>{let i=t.decorators.find((a)=>a.decorator===wD&&a.node===e.decoratorTarget);Qe(i,"Couldn't find @example decorator",e.decoratorTarget);let s=i.args[0].value;if(zs.realmForType.get(t)===void 0){if(!kP(e.program,s,t.kind==="ModelProperty"?t.type:t,e.getArgumentTarget(0)))return}let o=lEe(e.program,t);if(o===void 0)o=[],cEe(e.program,t,o);o.push({value:s,...r})},uEe,pEe,DD=(e,t,n,r)=>{let i=t.decorators.find((c)=>c.decorator===DD&&c.node===e.decoratorTarget);Qe(i,"Couldn't find @opExample decorator",e.decoratorTarget);let s=i.args[0].value,o=s.properties.get("parameters")?.value,a=s.properties.get("returnType")?.value;if(zs.realmForType.get(t)===void 0){if(o&&!kP(e.program,o,t.parameters,e.getArgumentTarget(0)))return;if(a&&!kP(e.program,a,t.returnType,e.getArgumentTarget(0)))return}let l=uEe(e.program,t);if(l===void 0)l=[],pEe(e.program,t,l);l.push({parameters:o,returnType:a,...r})};var ul=q(()=>{Od();sb();vt();qm();cc();lc();Yn();aP();ac();yr();It();Pd();ka();Nn();Kw();Gw();pP();vb();Kw();V7();EP();[Tb,USe]=ze(Pt("summary"));[KSe,JSe]=hr(Pt("error"));[GSe,HSe]=ze(Pt("mediaTypeHint"));[Fd,zSe]=ze(Pt("format")),[WSe,QSe]=ze(Pt("patternValues")),[YSe,XSe]=hr(Pt("secretTypes")),[uc,ZSe]=ze(Pt("encode"));[nEe,rEe]=ze(Pt("tagProperties")),[VP,iEe]=ze(Pt("friendlyNames")),[xD,sEe]=ze(Pt("overloadedByKey")),[GP,oEe]=ze(Pt("overloadsOperation"));[lEe,cEe]=ze(Pt("examples")),[uEe,pEe]=ze(Pt("opExamples"))});var n5=q(()=>{ul();Gt();Nr();Id();nn({enum:{create(e){let t=this.program.checker.createType({kind:"Enum",name:e.name,decorators:ll(this,e.decorators),members:il()});if(Array.isArray(e.members))for(let n of e.members)n.enum=t,t.members.set(n.name,n);else for(let[n,r]of Object.entries(e.members??{}))t.members.set(n,this.enumMember.create({name:n,value:r,enum:t}));return this.program.checker.finishType(t),t},is(e){return e.entityKind==="Type"&&e.kind==="Enum"},createFromUnion(e){if(!e.name)throw Error("Cannot create an enum from an anonymous union.");let t=[];for(let r of e.variants.values()){if(r.name&&typeof r.name==="symbol"||!this.literal.isString(r.type)&&!this.literal.isNumeric(r.type))continue;let i=Zr(this.program,r);t.push(this.enumMember.create({name:r.name,value:r.type.value,decorators:i?[[Ys,i]]:void 0}))}let n=Zr(this.program,e);return this.enum.create({name:e.name,members:t,decorators:n?[[Ys,n]]:void 0})}}})});var r5=q(()=>{Nr();nn({intrinsic:{get any(){return this.program.checker.anyType},get error(){return this.program.checker.errorType},get never(){return this.program.checker.neverType},get null(){return this.program.checker.nullType},get void(){return this.program.checker.voidType},is(e){return e.entityKind==="Type"&&e.kind==="Intrinsic"}}})});var i5=q(()=>{Nr();nn({literal:{create(e){return this.program.checker.createLiteralType(e)},createString(e){return this.program.checker.createLiteralType(e)},createNumeric(e){return this.program.checker.createLiteralType(e)},createBoolean(e){return this.program.checker.createLiteralType(e)},isBoolean(e){return e.entityKind==="Type"&&e.kind==="Boolean"},isString(e){return e.entityKind==="Type"&&e.kind==="String"},isNumeric(e){return e.entityKind==="Type"&&e.kind==="Number"},is(e){return this.literal.isBoolean(e)||this.literal.isNumeric(e)||this.literal.isString(e)}}})});var s5=q(()=>{tD();ul();Nr();nn({modelProperty:{is(e){return e.entityKind==="Type"&&e.kind==="ModelProperty"},getEncoding(e){return uc(this.program,e)??uc(this.program,e.type)},getFormat(e){return Fd(this.program,e)??Fd(this.program,e.type)},getVisibilityForClass(e,t){return Km(this.program,e,t)},create(e){return this.program.checker.createType({kind:"ModelProperty",name:e.name,type:e.type,optional:e.optional??!1,decorators:[],defaultValue:e.defaultValue})}}})});var TD;var o5=q(()=>{Eb();qm();lc();Gt();Cu();Nr();Id();TD=new Map;nn({model:{create(e){let t=il(Array.from(Object.entries(e.properties))),n=this.program.checker.createType({kind:"Model",name:e.name??"",decorators:ll(this,e.decorators),properties:t,derivedModels:e.derivedModels??[],sourceModels:e.sourceModels??[],indexer:e.indexer});return this.program.checker.finishType(n),n},is(e){return e.entityKind==="Type"&&e.kind==="Model"},isExpresion(e){return e.name===""},getEffectiveModel(e,t){return Sb(this.program,e,t)},getIndexType(e){if(TD.has(e))return TD.get(e);if(!e.indexer)return;if(e.indexer.key.name==="string"){let t=this.record.create(e.indexer.value);return TD.set(e,t),t}if(e.indexer.key.name==="integer"){let t=this.array.create(e.indexer.value);return TD.set(e,t),t}return},getProperties(e,t={}){let n=Ii(e.properties),r=this.model.getDiscriminatedUnion(e);if(r){let i=r.propertyName;n.set(i,this.modelProperty.create({name:i,type:this.builtin.string}))}if(t.includeExtended){let i=e.baseModel;while(i){for(let[s,o]of i.properties)if(!n.has(s))n.set(s,o);i=i.baseModel}}return n},getAdditionalPropertiesRecord(e){if(this.model.is(e)&&e.sourceModel&&this.record.is(e.sourceModel))return e.sourceModel;if(e.baseModel&&this.record.is(e.baseModel))return e.baseModel;let t=this.model.getIndexType(e);if(t&&this.record.is(t))return t;if(e.baseModel)return this.model.getAdditionalPropertiesRecord(e.baseModel);return},getDiscriminatedUnion:fi(function(e){let t=$d(this.program,e);if(!t)return[void 0,[]];return Iw(e,t)})}})});var a5=q(()=>{vb();Cu();Nr();nn({operation:{is(e){return e.entityKind==="Type"&&e.kind==="Operation"},getPagingMetadata:fi(function(e){return Ww(this.program,e)}),create(e){let t=this.model.create({name:`${e.name}Parameters`,properties:e.parameters.reduce((r,i)=>(r[i.name]=i,r),{})}),n=this.program.checker.createType({kind:"Operation",name:e.name,decorators:[],parameters:t,returnType:e.returnType});return this.program.checker.finishType(n),n}}})});var l5=q(()=>{yr();Nr();nn({record:{is(e){return e.entityKind==="Type"&&e.kind==="Model"&&QO(e)&&e.properties.size===0},getElementType(e){if(!this.record.is(e))throw Error("Type is not a record.");return e.indexer.value},create(e){return this.model.create({name:"Record",properties:{},indexer:{key:this.builtin.string,value:e}})}}})});function Jn(e){return function(t){return t===this.program.checker.getStdType(e)}}function Gn(e){return function(t){if(!this.scalar.is(t))return!1;return F9(this.program,t,e)}}var c5=q(()=>{Od();ul();Nr();nn({scalar:{is(e){return e.entityKind==="Type"&&e.kind==="Scalar"},extendsBoolean:Gn("boolean"),extendsBytes:Gn("bytes"),extendsDecimal:Gn("decimal"),extendsDecimal128:Gn("decimal128"),extendsDuration:Gn("duration"),extendsFloat:Gn("float"),extendsFloat32:Gn("float32"),extendsFloat64:Gn("float64"),extendsInt8:Gn("int8"),extendsInt16:Gn("int16"),extendsInt32:Gn("int32"),extendsInt64:Gn("int64"),extendsInteger:Gn("integer"),extendsNumeric:Gn("numeric"),extendsOffsetDateTime:Gn("offsetDateTime"),extendsPlainDate:Gn("plainDate"),extendsPlainTime:Gn("plainTime"),extendsSafeint:Gn("safeint"),extendsString:Gn("string"),extendsUint8:Gn("uint8"),extendsUint16:Gn("uint16"),extendsUint32:Gn("uint32"),extendsUint64:Gn("uint64"),extendsUrl:Gn("url"),extendsUtcDateTime:Gn("utcDateTime"),isBoolean:Jn("boolean"),isBytes:Jn("bytes"),isDecimal:Jn("decimal"),isDecimal128:Jn("decimal128"),isDuration:Jn("duration"),isFloat:Jn("float"),isFloat32:Jn("float32"),isFloat64:Jn("float64"),isInt8:Jn("int8"),isInt16:Jn("int16"),isInt32:Jn("int32"),isInt64:Jn("int64"),isInteger:Jn("integer"),isNumeric:Jn("numeric"),isOffsetDateTime:Jn("offsetDateTime"),isPlainDate:Jn("plainDate"),isPlainTime:Jn("plainTime"),isSafeint:Jn("safeint"),isString:Jn("string"),isUint8:Jn("uint8"),isUint16:Jn("uint16"),isUint32:Jn("uint32"),isUint64:Jn("uint64"),isUrl:Jn("url"),isUtcDateTime:Jn("utcDateTime"),getStdBase(e){let t=this.program.resolveTypeReference("TypeSpec")[0],n=e;while(n){if(n.namespace===t)return n;n=n.baseScalar}return null},getEncoding(e){return uc(this.program,e)},getFormat(e){return Fd(this.program,e)}}})});var u5=q(()=>{Nr();nn({tuple:{is(e){return e.entityKind==="Type"&&e.kind==="Tuple"},create(e=[]){let t=this.program.checker.createType({kind:"Tuple",name:"Tuple",values:e});return this.program.checker.finishType(t),t}}})});function QP(e){return e.charAt(0).toUpperCase()+e.slice(1)}function SD(e){let t=e.name??"TypeExpression";if(Lo(e))t=`${e.templateMapper.args.map((r)=>{if(r.entityKind==="Type")switch(r.kind){case"Scalar":let i=SD(r);return QP(i);case"Model":case"Interface":case"Enum":case"Union":return SD(r)}return"name"in r?r.name:""}).join("_")}${t}`;return t}var p5=q(()=>{yr()});var d5=q(()=>{ic();lc();yr();ul();Gw();Cu();Nr();Id();p5();nn({type:{is(e){return e.entityKind==="Type"},finishType(e){this.program.checker.finishType(e)},clone(e){let t;switch(e.kind){case"Model":t=this.program.checker.createType({...e,decorators:[...e.decorators],derivedModels:[...e.derivedModels],sourceModels:e.sourceModels.map((n)=>({...n})),properties:Ii(e.properties),indexer:e.indexer?{...e.indexer}:void 0});break;case"Union":t=this.program.checker.createType({...e,decorators:[...e.decorators],variants:Ii(e.variants),get options(){return Array.from(this.variants.values()).map((n)=>n.type)}});break;case"Interface":t=this.program.checker.createType({...e,decorators:[...e.decorators],operations:Ii(e.operations)});break;case"Enum":t=this.program.checker.createType({...e,decorators:[...e.decorators],members:Ii(e.members)});break;case"Namespace":t=this.program.checker.createType({...e,decorators:[...e.decorators],instantiationParameters:e.instantiationParameters?[...e.instantiationParameters]:void 0,models:Ii(e.models),decoratorDeclarations:Ii(e.decoratorDeclarations),enums:Ii(e.enums),unions:Ii(e.unions),operations:Ii(e.operations),interfaces:Ii(e.interfaces),namespaces:Ii(e.namespaces),scalars:Ii(e.scalars)});break;case"Scalar":t=this.program.checker.createType({...e,decorators:[...e.decorators],derivedScalars:[...e.derivedScalars],constructors:Ii(e.constructors)});break;case"Tuple":t=this.program.checker.createType({...e,values:[...e.values]});break;default:t=this.program.checker.createType({...e,..."decorators"in e?{decorators:[...e.decorators]}:{}});break}return this.realm.addType(t),t},isError(e){return fc(this.program,e)},getEncodedName(e,t){return mb(this.program,e,t)},getSummary(e){return Tb(this.program,e)},getDoc(e){return Zr(this.program,e)},getPlausibleName(e){return SD(e)},maxValue(e){return Fm(this.program,e)},minValue(e){return Rm(this.program,e)},maxLength(e){return nb(this.program,e)},minLength(e){return tb(this.program,e)},maxItems(e){return ib(this.program,e)},maxValueExclusive(e){return Ew(this.program,e)},minValueExclusive(e){return Sw(this.program,e)},minItems(e){return rb(this.program,e)},isNever(e){return ww(e)},isUserDefined(e){return Co(this.program,e).type==="project"},inNamespace(e,t){if(e===t)return!0;switch(e.kind){case"ModelProperty":if(e.model)return this.type.inNamespace(e.model,t);break;case"EnumMember":return this.type.inNamespace(e.enum,t);case"UnionVariant":return this.type.inNamespace(e.union,t);case"Operation":if(e.interface)return this.type.inNamespace(e.interface,t);break}if("namespace"in e&&e.namespace)return this.type.inNamespace(e.namespace,t);return!1},isAssignableTo:fi(function(e,t,n){return this.program.checker.isTypeAssignableTo(e,t,n??e)}),resolve:fi(function(e,t){let[n,r]=this.program.resolveTypeReference(e);if(n&&t&&n.kind!==t)throw Error(`Type kind mismatch: expected ${t}, got ${n.kind}`);return[n,r]})}})});var f5=q(()=>{Nr();Id();nn({unionVariant:{create(e){let t=this.program.checker.createType({kind:"UnionVariant",name:e.name??Symbol("name"),decorators:ll(this,e.decorators),type:e.type,union:e.union});return this.program.checker.finishType(t),t},is(e){return e.entityKind==="Type"&&e.kind==="UnionVariant"}}})});var dEe;var m5=q(()=>{vt();qm();ul();Gt();Cu();Nr();Id();dEe=nn({union:{filter(e,t){let n=Array.from(e.variants.values()).filter(t);return this.union.create({variants:n})},create(e){let t;if(Array.isArray(e))t={decorators:[],variants:e.map((r)=>{let i=Zr(this.program,r);return this.unionVariant.create({type:r,decorators:i?[[Ys,i]]:void 0})})};else t=e;let n=this.program.checker.createType({kind:"Union",name:t.name,decorators:ll(this,t.decorators),variants:il(),get options(){return Array.from(this.variants.values()).map((r)=>r.type)},expression:t.name===void 0});if(Array.isArray(t.variants))for(let r of t.variants)n.variants.set(r.name,r),r.union=n;else if(t.variants)for(let[r,i]of Object.entries(t.variants))n.variants.set(r,this.unionVariant.create({name:r,type:this.literal.create(i)}));return this.program.checker.finishType(n),n},createFromEnum(e){let t=Zr(this.program,e);return this.union.create({name:e.name,decorators:t?[[Ys,t]]:void 0,variants:Array.from(e.members.values()).map((n)=>{let r=Zr(this.program,n),i=n.value??n.name;return this.unionVariant.create({name:n.name,type:this.literal.create(i),decorators:r?[[Ys,r]]:void 0})})})},is(e){return e.entityKind==="Type"&&e.kind==="Union"},isValidEnum(e){for(let t of e.variants.values())if(!this.literal.isString(t.type)&&!this.literal.isNumeric(t.type))return!1;return!0},isExtensible(e){let t=Array.from(e.variants.values());if(t.length===0)return!1;for(let n=0;n{ac();yr();Cu();Nr();nn({value:{is(e){return e.entityKind==="Value"},create(e){if(typeof e==="string")return this.value.createString(e);else if(typeof e==="number")return this.value.createNumeric(e);else return this.value.createBoolean(e)},createString(e){return{entityKind:"Value",value:e,valueKind:"StringValue",type:this.literal.createString(e),scalar:void 0}},createNumeric(e){let t=String(e);return{entityKind:"Value",value:kn(t),valueKind:"NumericValue",type:this.literal.createNumeric(e),scalar:void 0}},createBoolean(e){return{entityKind:"Value",value:e,valueKind:"BooleanValue",type:this.literal.createBoolean(e),scalar:void 0}},isBoolean(e){return this.value.is(e)&&e.valueKind==="BooleanValue"},isString(e){return this.value.is(e)&&e.valueKind==="StringValue"},isNumeric(e){return this.value.is(e)&&e.valueKind==="NumericValue"},isArray(e){return this.value.is(e)&&e.valueKind==="ArrayValue"},isObject(e){return this.value.is(e)&&e.valueKind==="ObjectValue"},isEnum(e){return this.value.is(e)&&e.valueKind==="EnumValue"},isNull(e){return this.value.is(e)&&e.valueKind==="NullValue"},isScalar(e){return this.value.is(e)&&e.valueKind==="ScalarValue"},isAssignableTo:fi(function(e,t,n){return this.program.checker.isTypeAssignableTo(e,t,n??e)}),isOfType:fi(function(e,t,n){return this.program.checker.isValueOfType(e,t,n??e)}),resolve:fi(function(e,t){let[n,r]=this.program.resolveTypeOrValueReference(e);if(n&&!Sa(n))return[void 0,r];if(n&&t&&n.valueKind!==t)throw Error(`Value kind mismatch: expected ${t}, got ${n.valueKind}`);return[n,r]})}})});var h5=q(()=>{i7();s7();o7();a7();n5();r5();i5();s5();o5();a5();l5();c5();u5();d5();f5();m5();y5()});function mEe(e){let t;if(Object.hasOwn(e,"projectRoot"))t=e[fEe]??=new zs(e,"default typekit realm");else t=e;return t.typekit}var fEe,Kn;var ka=q(()=>{Pd();Cu();Nr();h5();fEe=Symbol.for("TypeSpec.Typekit.DEFAULT_TYPEKIT_REALM");Kn=mEe});function Vo(e){let t=Vn.None;for(let n of e)t|=hEe(n);return t}function hEe(e){switch(e.kind){case re.ExternKeyword:return Vn.Extern;case re.InternalKeyword:return Vn.Internal;case re.AutoKeyword:return Vn.Auto;default:Qe(!1,`Unknown modifier kind: ${e.kind}`)}}var Uu,yEe,Hmt;var YP=q(()=>{vt();Yn();It();Uu={allowed:Vn.Internal,required:Vn.None},yEe={allowed:Vn.None,required:Vn.None},Hmt={[re.NamespaceStatement]:yEe,[re.OperationStatement]:Uu,[re.ModelStatement]:Uu,[re.ScalarStatement]:Uu,[re.InterfaceStatement]:Uu,[re.UnionStatement]:Uu,[re.EnumStatement]:Uu,[re.AliasStatement]:Uu,[re.ConstStatement]:Uu,[re.DecoratorDeclarationStatement]:{allowed:Vn.All,required:Vn.Extern|Vn.Auto,mutuallyExclusive:[[Vn.Extern,Vn.Auto]]},[re.FunctionDeclarationStatement]:{allowed:Vn.Extern|Vn.Internal,required:Vn.Extern}}});function Cd(e,t={}){return bEe(e,t).parseTypeSpecScript()}function bEe(e,t={}){let n=!1,r=-1,i=-1,s=0,o=!0,a=!0,l=kb.Syntax,c=[],u=oP(e,Jle),p=[],d=[];return Qn(),{parseDiagnostics:c,parseTypeSpecScript:f,parseStandaloneReferenceExpression:fe};function f(){let P=y();return{kind:re.TypeSpecScript,statements:P,file:u.file,id:{kind:re.Identifier,sv:u.file.path,pos:0,end:0,flags:Xi.Synthetic},namespaces:[],usings:[],locals:void 0,inScopeNamespaces:[],parseDiagnostics:c,comments:p,printable:o,parseOptions:t,...Ue(0)}}function m({skipParsingDocNodes:P}={}){let B=[],ee=[],Te=[],Me=rt();if(!P){let[gt,yt]=po();Me=gt;for(let jn of yt)Te.push(jn)}while(Ze()===w.Hash||Ze()===w.At){if(Ze()===w.Hash)B.push(Q());else if(Ze()===w.At)ee.push(A());if(!P){let[gt,yt]=po();for(let jn of yt)Te.push(jn)}}return{pos:Me,docs:Te,directives:B,decorators:ee}}function y(){let P=[],B=!1,ee=!1,Te=!1;while(Ze()!==w.EndOfFile){let{pos:Me,docs:gt,directives:yt,decorators:jn}=m(),ar=Ze(),qn;switch(ar){case w.AtAt:xi(jn,"augment decorator statement"),qn=k();break;case w.ImportKeyword:xi(jn,"import statement"),qn=E();break;case w.UsingKeyword:xi(jn,"using statement"),qn=X(Me);break;case w.Semicolon:xi(jn,"empty statement"),qn=EC(Me);break;case w.NamespaceKeyword:case w.ModelKeyword:case w.ScalarKeyword:case w.InterfaceKeyword:case w.UnionKeyword:case w.OpKeyword:case w.EnumKeyword:case w.AliasKeyword:case w.ConstKeyword:case w.ExternKeyword:case w.InternalKeyword:case w.AutoKeyword:case w.FnKeyword:case w.DecKeyword:qn=ch(Me,jn,gt,yt);break;default:qn=bE(Me,jn);break}if(ar!==w.NamespaceKeyword)Tn(qn).directives=yt,Tn(qn).docs=gt;if(g5(qn)){if(B)an({code:"multiple-blockless-namespace",target:qn});if(ee)an({code:"blockless-namespace-first",target:qn});B=!0}else if(qn.kind===re.ImportStatement){if(ee||B||Te)an({code:"import-first",target:qn})}else if(qn.kind===re.UsingStatement)Te=!0;else ee=!0;P.push(qn)}return P}function h(){let P=[];while(Ze()!==w.CloseBrace){let{pos:B,docs:ee,directives:Te,decorators:Me}=m(),gt=Ze(),yt;switch(gt){case w.AtAt:xi(Me,"augment decorator statement"),yt=k();break;case w.ImportKeyword:xi(Me,"import statement"),yt=E(),an({code:"import-first",messageId:"topLevel",target:yt});break;case w.UsingKeyword:xi(Me,"using statement"),yt=X(B);break;case w.ModelKeyword:case w.ScalarKeyword:case w.NamespaceKeyword:case w.InterfaceKeyword:case w.UnionKeyword:case w.OpKeyword:case w.EnumKeyword:case w.AliasKeyword:case w.ConstKeyword:case w.ExternKeyword:case w.InternalKeyword:case w.AutoKeyword:case w.FnKeyword:case w.DecKeyword:yt=ch(B,Me,ee,Te);break;case w.EndOfFile:return it(w.CloseBrace),P;case w.Semicolon:xi(Me,"empty statement"),yt=EC(B);break;default:yt=bE(B,Me);break}if(g5(yt))an({code:"blockless-namespace-first",messageId:"topLevel",target:yt});if(Tn(yt).directives=Te,gt!==w.NamespaceKeyword)Tn(yt).docs=ee;P.push(yt)}return P}function b(){let P=[];while(Ze()===w.At)P.push(A());return P}function g(){let P=[];while(Ze()===w.Hash)P.push(Q());return P}function x(P,B,ee,Te,Me){it(w.NamespaceKeyword);let gt=Je(),yt=[];while(gt.kind!==re.Identifier)yt.push(gt.id),gt=gt.base;yt.push(gt);let jn=OC(w.Semicolon,w.OpenBrace),ar;if(jn===w.OpenBrace)ar=h(),it(w.CloseBrace);let qn={kind:re.NamespaceStatement,decorators:B,docs:Te,id:yt[0],locals:void 0,statements:ar,directives:Me,modifiers:ee,modifierFlags:Vo(ee),...Ue(P)};for(let Qc=1;Qcte(qn,Qc,void 0,!0));return{kind:re.InterfaceStatement,id:Te,templateParameters:Me,templateParametersRange:gt,operations:jn,bodyRange:ar,extends:yt.items,decorators:B,modifiers:ee,modifierFlags:Vo(ee),...Ue(P)}}function D(){let P=x_(Or.TemplateParameters,Z),B=!1;for(let ee of P.items){if(!ee.default&&B){an({code:"default-required",target:ee});continue}if(ee.default)B=!0}return P}function T(P,B,ee){it(w.UnionKeyword);let Te=wn(),{items:Me,range:gt}=D();mh(w.OpenBrace,w.ExtendsKeyword);let yt=N(),{items:jn}=Bi(Or.UnionVariants,C);return{kind:re.UnionStatement,id:Te,templateParameters:Me,templateParametersRange:gt,extends:yt,decorators:B,modifiers:ee,modifierFlags:Vo(ee),options:jn,...Ue(P)}}function N(){if(Mt(w.ExtendsKeyword))return V();return}function O(){let P=Ze(),B;if(lb(P)||cb(P)){if(B=wn({allowReservedIdentifier:!0}),Ze()!==w.Colon)if(lb(P))an({code:"reserved-identifier",messageId:"future",format:{name:B.sv}});else an({code:"reserved-identifier"});return{kind:re.TypeReference,target:B,arguments:[],...Ue(B.pos)}}else return V()}function C(P,B){let ee=O();if(Mt(w.Colon)){let Te=void 0;if(ee.kind!==re.TypeReference&&ee.kind!==re.StringLiteral)an({code:"token-expected",messageId:"identifier"});else if(ee.kind===re.StringLiteral)Te={kind:re.Identifier,sv:ee.value,...Ue(ee.pos)};else{let gt=ee.target;if(gt.kind===re.Identifier)Te=gt;else an({code:"token-expected",messageId:"identifier"})}let Me=V();return{kind:re.UnionVariant,id:Te,value:Me,decorators:B,...Ue(P)}}return{kind:re.UnionVariant,id:void 0,value:ee,decorators:B,...Ue(P)}}function X(P){it(w.UsingKeyword);let B=Je();return it(w.Semicolon),{kind:re.UsingStatement,name:B,...Ue(P)}}function te(P,B,ee,Te){let Me;if(Te)Me=b_(),Mt(w.OpKeyword);else Me=ee,it(w.OpKeyword);let gt=wn(),{items:yt,range:jn}=D(),ar=mh(w.OpenParen,w.IsKeyword),qn,Qc=rt();if(ar===w.OpenParen){let vE=L();it(w.Colon);let Hle=V();qn={kind:re.OperationSignatureDeclaration,parameters:vE,returnType:Hle,...Ue(Qc)}}else{it(w.IsKeyword);let vE=Ce();qn={kind:re.OperationSignatureReference,baseOperation:vE,...Ue(Qc)}}if(!Te)it(w.Semicolon);return{kind:re.OperationStatement,id:gt,templateParameters:yt,templateParametersRange:jn,signature:qn,decorators:B,modifiers:Me,modifierFlags:Vo(Me),...Ue(P)}}function L(){let P=rt(),{items:B,range:ee}=Bi(Or.OperationParameters,je);return{kind:re.ModelExpression,properties:B,bodyRange:ee,...Ue(P)}}function Y(P,B,ee){it(w.ModelKeyword);let Te=wn(),{items:Me,range:gt}=D();mh(w.OpenBrace,w.Equals,w.ExtendsKeyword,w.IsKeyword);let yt=me(),jn=yt?void 0:I(),ar=Wc();if(jn)if(mh(w.Semicolon,w.OpenBrace)===w.Semicolon)Qn();else ar=Bi(Or.ModelProperties,je);else ar=Bi(Or.ModelProperties,je);return{kind:re.ModelStatement,id:Te,extends:yt,is:jn,templateParameters:Me,templateParametersRange:gt,decorators:B,properties:ar.items,bodyRange:ar.range,modifiers:ee,modifierFlags:Vo(ee),...Ue(P)}}function me(){if(Mt(w.ExtendsKeyword))return V();return}function I(){if(Mt(w.IsKeyword))return V();return}function Z(){let P=rt(),B=wn(),ee;if(Mt(w.ExtendsKeyword))ee=de();let Te;if(Mt(w.Equals))Te=V();return{kind:re.TemplateParameterDeclaration,id:B,constraint:ee,default:Te,...Ue(P)}}function pe(){if(Ze()===w.ValueOfKeyword)return W();else if(Mt(w.OpenParen)){let P=de();return it(w.CloseParen),P}return H()}function de(){let P=rt();Mt(w.Bar);let B=pe();if(Ze()!==w.Bar)return B;let ee=[B];while(Mt(w.Bar)){let Te=pe();ee.push(Te)}return{kind:re.UnionExpression,options:ee,...Ue(P)}}function je(P,B){return Ze()===w.Ellipsis?be(P,B):Ie(P,B)}function be(P,B){it(w.Ellipsis),xi(B,"spread property");let ee=Ce();return{kind:re.ModelSpreadProperty,target:ee,...Ue(P)}}function Ie(P,B){let ee=wn({message:"property",allowStringLiteral:!0,allowReservedIdentifier:!0}),Te=Mt(w.Question);it(w.Colon);let Me=V(),yt=Mt(w.Equals)?V():void 0;return{kind:re.ModelProperty,id:ee,decorators:B,value:Me,optional:Te,default:yt,...Ue(P)}}function J(P,B){return xi(B,"object literal property"),Ze()===w.Ellipsis?_e(P):ue(P)}function _e(P){it(w.Ellipsis);let B=Ce();return{kind:re.ObjectLiteralSpreadProperty,target:B,...Ue(P)}}function ue(P){let B=wn({message:"property",allowReservedIdentifier:!0});it(w.Colon);let ee=V();return{kind:re.ObjectLiteralProperty,id:B,value:ee,...Ue(P)}}function ce(P,B,ee){it(w.ScalarKeyword);let Te=wn(),{items:Me,range:gt}=D(),yt=Le(),{items:jn,range:ar}=Ke();return{kind:re.ScalarStatement,id:Te,templateParameters:Me,templateParametersRange:gt,extends:yt,members:jn,bodyRange:ar,decorators:B,modifiers:ee,modifierFlags:Vo(ee),...Ue(P)}}function Le(){if(Mt(w.ExtendsKeyword))return Ce();return}function Ke(){if(Ze()===w.Semicolon)return Qn(),Wc();else return Bi(Or.ScalarMembers,ct)}function ct(P,B){xi(B,"scalar member"),it(w.InitKeyword);let ee=wn(),{items:Te}=Hc();return{kind:re.ScalarConstructor,id:ee,parameters:Te,...Ue(P)}}function lt(P,B,ee){it(w.EnumKeyword);let Te=wn(),{items:Me}=Bi(Or.EnumMembers,se);return{kind:re.EnumStatement,id:Te,decorators:B,modifiers:ee,modifierFlags:Vo(ee),members:Me,...Ue(P)}}function se(P,B){return Ze()===w.Ellipsis?he(P,B):ke(P,B)}function he(P,B){it(w.Ellipsis),xi(B,"spread enum");let ee=Ce();return{kind:re.EnumSpreadMember,target:ee,...Ue(P)}}function ke(P,B){let ee=wn({message:"enumMember",allowStringLiteral:!0,allowReservedIdentifier:!0}),Te;if(Mt(w.Colon)){let Me=V();if(Me.kind===re.StringLiteral||Me.kind===re.NumericLiteral)Te=Me;else if(Me.kind===re.TypeReference&&Me.target.flags&Xi.ThisNodeHasError)n=!0;else an({code:"token-expected",messageId:"numericOrStringLiteral",target:Me})}return{kind:re.EnumMember,id:ee,value:Te,decorators:B,...Ue(P)}}function Re(P,B){it(w.AliasKeyword);let ee=wn(),{items:Te,range:Me}=D();it(w.Equals);let gt=V();return it(w.Semicolon),{kind:re.AliasStatement,id:ee,templateParameters:Te,templateParametersRange:Me,value:gt,modifiers:B,modifierFlags:Vo(B),...Ue(P)}}function Ne(P,B){it(w.ConstKeyword);let ee=wn(),Te=G();it(w.Equals);let Me=V();return it(w.Semicolon),{kind:re.ConstStatement,id:ee,value:Me,type:Te,modifiers:B,modifierFlags:Vo(B),...Ue(P)}}function G(){if(Mt(w.Colon))return V();return}function V(){return j()}function j(){let P=rt();Mt(w.Bar);let B=H();if(Ze()!==w.Bar)return B;let ee=[B];while(Mt(w.Bar)){let Te=H();ee.push(Te)}for(let Te of ee.filter((Me)=>Me.kind===re.FunctionTypeExpression))if(!Te.parenthesized)an({code:"fn-in-union-expression",target:Te});return{kind:re.UnionExpression,options:ee,...Ue(P)}}function H(){let P=rt();Mt(w.Ampersand);let B=ge();if(Ze()!==w.Ampersand)return B;let ee=[B];while(Mt(w.Ampersand)){let Te=ge();ee.push(Te)}return{kind:re.IntersectionExpression,options:ee,...Ue(P)}}function ge(){let P=rt(),B=St();while(Mt(w.OpenBracket))it(w.CloseBracket),B={kind:re.ArrayExpression,elementType:B,...Ue(P)};return B}function fe(){let P=Ce();if(c.length===0&&Ze()!==w.EndOfFile)an({code:"token-expected",messageId:"unexpected",format:{token:w[Ze()]}});return P}function W(){let P=rt();it(w.ValueOfKeyword);let B=V();return{kind:re.ValueOfExpression,target:B,...Ue(P)}}function ye(){let P=rt();it(w.TypeOfKeyword);let B=Oe();return{kind:re.TypeOfExpression,target:B,...Ue(P)}}function Oe(){while(!0)switch(Ze()){case w.TypeOfKeyword:return ye();case w.Identifier:return Bt();case w.StringLiteral:return Gc();case w.StringTemplateHead:return lh();case w.TrueKeyword:case w.FalseKeyword:return Ui();case w.NumericLiteral:return Ir();case w.OpenParen:it(w.OpenParen);let P=Oe();return it(w.CloseParen),P;default:return Ce("typeofTarget")}}function Se(){let P=rt();it(w.FnKeyword);let{items:B}=Hc(),Te=Mt(w.EqualsGreaterThan)?de():void 0;return{kind:re.FunctionTypeExpression,parameters:B,returnType:Te,...Ue(P)}}function Ce(P){let B=rt(),ee=Je({message:P,allowReservedIdentifierInMember:!0});return _(ee,B)}function Bt(P){let B=rt(),ee=Je({message:P,allowReservedIdentifierInMember:!0});if(Ze()===w.OpenParen){let{items:Te}=Bi(Or.FunctionArguments,V);return{kind:re.CallExpression,target:ee,arguments:Te,...Ue(B)}}return _(ee,B)}function _(P,B){let{items:ee}=x_(Or.TemplateArguments,S);return{kind:re.TypeReference,target:P,arguments:ee,...Ue(B)}}function S(){let P=rt();if(Ze()===w.Equals)return an({code:"token-expected",messageId:"identifier"}),Qn(),{kind:re.TemplateArgument,name:zc(),argument:V(),...Ue(P)};let B=V();if(Mt(w.Equals)){let Te=XP(B);if(!Te)an({code:"invalid-template-argument-name",target:B});return{kind:re.TemplateArgument,name:Te?B.target:zc(),argument:V(),...Ue(P)}}else return{kind:re.TemplateArgument,argument:B,...Ue(P)}}function k(){let P=rt();it(w.AtAt);let B=Je({allowReservedIdentifier:!0,allowReservedIdentifierInMember:!0}),{items:ee}=x_(Or.DecoratorArguments,V);if(ee.length===0){an({code:"augment-decorator-target"});let gt=Wc();return{kind:re.AugmentDecoratorStatement,target:B,targetType:{kind:re.TypeReference,target:zc(),arguments:gt.items,...Ue(P)},arguments:ee,...Ue(P)}}let[Te,...Me]=ee;if(Te.kind!==re.TypeReference){an({code:"augment-decorator-target",target:Te});let gt=Wc();Te={kind:re.TypeReference,target:zc(),arguments:gt.items,...Ue(P)}}return it(w.Semicolon),{kind:re.AugmentDecoratorStatement,target:B,targetType:Te,arguments:Me,...Ue(P)}}function E(){let P=rt();it(w.ImportKeyword);let B=Gc();return it(w.Semicolon),{kind:re.ImportStatement,path:B,...Ue(P)}}function A(){let P=rt();it(w.At);let B=Je({allowReservedIdentifier:!0,allowReservedIdentifierInMember:!0}),{items:ee}=x_(Or.DecoratorArguments,V);return{kind:re.DecoratorExpression,arguments:ee,target:B,...Ue(P)}}function Q(){let P=rt();it(w.Hash);let B=wn();if(B.sv!=="suppress"&&B.sv!=="deprecated")an({code:"unknown-directive",format:{id:B.sv},target:{pos:P,end:P+B.sv.length},printable:!0});a=!1;let ee=[];while(Ze()!==w.NewLine&&Ze()!==w.EndOfFile){let Te=le();if(Te)ee.push(Te)}return a=!0,Qn(),{kind:re.DirectiveExpression,arguments:ee,target:B,...Ue(P)}}function le(){switch(Ze()){case w.Identifier:return wn();case w.StringLiteral:return Gc();default:an({code:"token-expected",messageId:"unexpected",format:{token:w[Ze()]}});do Qn();while(!qw(Ze())&&Ze()!==w.NewLine&&Ze()!==w.At&&Ze()!==w.Semicolon&&Ze()!==w.EndOfFile);return}}function Je(P){let B=rt(),ee=wn({message:P?.message,allowReservedIdentifier:P?.allowReservedIdentifier});while(Ze()!==w.EndOfFile)if(Mt(w.Dot))ee={kind:re.MemberExpression,base:ee,id:wn({allowReservedIdentifier:P?.allowReservedIdentifierInMember}),selector:".",...Ue(B)};else if(Mt(w.ColonColon))ee={kind:re.MemberExpression,base:ee,id:wn(),selector:"::",...Ue(B)};else break;return ee}function St(){while(!0)switch(Ze()){case w.TypeOfKeyword:return ye();case w.FnKeyword:return Se();case w.Identifier:return Bt();case w.StringLiteral:return Gc();case w.StringTemplateHead:return lh();case w.TrueKeyword:case w.FalseKeyword:return Ui();case w.NumericLiteral:return Ir();case w.OpenBrace:return Us();case w.OpenBracket:return qa();case w.OpenParen:return qs();case w.At:let P=b();xi(P,"expression");continue;case w.Hash:let B=g();NC(B,"expression");continue;case w.HashBrace:return as();case w.HashBracket:return ah();case w.VoidKeyword:return Ln();case w.NeverKeyword:return Rn();case w.UnknownKeyword:return _i();default:return Ce("expression")}}function ut(){let P=rt();return it(w.ExternKeyword),{kind:re.ExternKeyword,...Ue(P)}}function xt(){let P=rt();return it(w.InternalKeyword),{kind:re.InternalKeyword,...Ue(P)}}function At(){let P=rt();return it(w.AutoKeyword),{kind:re.AutoKeyword,...Ue(P)}}function Ln(){let P=rt();return it(w.VoidKeyword),{kind:re.VoidKeyword,...Ue(P)}}function Rn(){let P=rt();return it(w.NeverKeyword),{kind:re.NeverKeyword,...Ue(P)}}function _i(){let P=rt();return it(w.UnknownKeyword),{kind:re.UnknownKeyword,...Ue(P)}}function qs(){let P=rt();it(w.OpenParen);let B=V();return it(w.CloseParen),{parenthesized:!0,...B,...Ue(P)}}function qa(){let P=rt(),{items:B}=Bi(Or.Tuple,V);return{kind:re.TupleExpression,values:B,...Ue(P)}}function Us(){let P=rt(),{items:B,range:ee}=Bi(Or.ModelProperties,je);return{kind:re.ModelExpression,properties:B,bodyRange:ee,...Ue(P)}}function as(){let P=rt(),{items:B,range:ee}=Bi(Or.ObjectLiteralProperties,J);return{kind:re.ObjectLiteral,properties:B,bodyRange:ee,...Ue(P)}}function ah(){let P=rt(),{items:B}=Bi(Or.ArrayLiteral,V);return{kind:re.ArrayLiteral,values:B,...Ue(P)}}function Gc(){let P=rt(),B=Ua();return it(w.StringLiteral),{kind:re.StringLiteral,value:B,...Ue(P)}}function lh(){let P=rt(),B=R(),ee=K(B.tokenFlags),Te=ee[ee.length-1];if(B.tokenFlags&qt.TripleQuoted){let[Me,gt]=u.findTripleQuotedStringIndent(Te.literal.pos,Te.literal.end);Tn(B).value=u.unindentAndUnescapeTripleQuotedString(B.pos,B.end,Me,gt,w.StringTemplateHead,B.tokenFlags);for(let yt of ee)Tn(yt.literal).value=u.unindentAndUnescapeTripleQuotedString(yt.literal.pos,yt.literal.end,Me,gt,yt===Te?w.StringTemplateTail:w.StringTemplateMiddle,B.tokenFlags)}return{kind:re.StringTemplateExpression,head:B,spans:ee,...Ue(P)}}function R(){let P=rt(),B=dh(),ee=B&qt.TripleQuoted?"":Ua();return it(w.StringTemplateHead),{kind:re.StringTemplateHead,value:ee,tokenFlags:B,...Ue(P)}}function K(P){let B=[],ee;do ee=Fe(P),B.push(ee);while(ee.literal.kind===re.StringTemplateMiddle);return B}function Fe(P){let B=rt(),ee=V(),Te=Ge(P);return{kind:re.StringTemplateSpan,literal:Te,expression:ee,...Ue(B)}}function Ge(P){let B=rt(),ee=dh(),Te=ee&qt.TripleQuoted?"":Ua();if(Ze()===w.CloseBrace)return qle(P),tt();else return it(w.StringTemplateTail),{kind:re.StringTemplateTail,value:Te,tokenFlags:ee,...Ue(B)}}function tt(){let P=rt(),B=dh(),ee=B&qt.TripleQuoted?"":Ua(),Te=Ze()===w.StringTemplateMiddle?re.StringTemplateMiddle:re.StringTemplateTail;return Qn(),{kind:Te,value:ee,tokenFlags:B,...Ue(P)}}function Ir(){let P=rt(),B=Ua(),ee=Number(B);return it(w.NumericLiteral),{kind:re.NumericLiteral,value:ee,valueAsString:B,...Ue(P)}}function Ui(){let P=rt(),ee=OC(w.TrueKeyword,w.FalseKeyword)===w.TrueKeyword;return{kind:re.BooleanLiteral,value:ee,...Ue(P)}}function wn(P){if(sP(Ze())){if(!(cb(Ze())&&P?.allowReservedIdentifier))return an({code:"reserved-identifier"}),zc()}else if(lb(Ze())){if(!P?.allowReservedIdentifier)an({code:"reserved-identifier",messageId:"future",format:{name:Ua()}})}else if(Ze()!==w.Identifier&&(!P?.allowStringLiteral||Ze()!==w.StringLiteral))return an({code:"token-expected",messageId:P?.message??"identifier"}),zc();let B=rt(),ee=Ua();return Qn(),{kind:re.Identifier,sv:ee,...Ue(B)}}function ch(P,B,ee,Te){let Me=b_();switch(Ze()){case w.ModelKeyword:return Y(P,B,Me);case w.ScalarKeyword:return ce(P,B,Me);case w.NamespaceKeyword:return x(P,B,Me,ee,Te);case w.InterfaceKeyword:return v(P,B,Me);case w.UnionKeyword:return T(P,B,Me);case w.OpKeyword:return te(P,B,Me);case w.EnumKeyword:return lt(P,B,Me);case w.AliasKeyword:return xi(B,"alias statement"),Re(P,Me);case w.ConstKeyword:return xi(B,"const statement"),Ne(P,Me);case w.DecKeyword:return __(P,Me);case w.FnKeyword:return uh(P,Me)}return bE(P,[])}function b_(){let P=[],B;while(B=v_())P.push(B);return P}function v_(){switch(Ze()){case w.ExternKeyword:return ut();case w.InternalKeyword:return xt();case w.AutoKeyword:return At();default:return}}function __(P,B){let ee=Vo(B);it(w.DecKeyword);let Te=wn(),Me=Hc(),[gt,...yt]=Me.items;if(gt===void 0)an({code:"decorator-decl-target",target:{pos:P,end:r}}),gt={kind:re.FunctionParameter,id:zc(),type:Ule(),optional:!1,rest:!1,...Ue(P)};if(gt.optional)an({code:"decorator-decl-target",messageId:"required"});return it(w.Semicolon),{kind:re.DecoratorDeclarationStatement,modifiers:B,modifierFlags:ee,id:Te,target:gt,parameters:yt,...Ue(P)}}function uh(P,B){let ee=Vo(B);it(w.FnKeyword);let Te=wn(),{items:Me}=Hc(),gt;if(Mt(w.Colon))gt=de();return it(w.Semicolon),{kind:re.FunctionDeclarationStatement,modifiers:B,modifierFlags:ee,id:Te,parameters:Me,returnType:gt,...Ue(P)}}function Hc(){let P=Bi(Or.FunctionParameters,ph),B=!1;for(let[ee,Te]of P.items.entries()){if(!Te.optional&&B){an({code:"required-parameter-first",target:Te});continue}if(Te.optional)B=!0;if(Te.rest&&Te.optional)an({code:"rest-parameter-required",target:Te});if(Te.rest&&ee!==P.items.length-1)an({code:"rest-parameter-last",target:Te})}return P}function ph(){let P=rt(),B=Mt(w.Ellipsis),ee=wn({message:"property",allowReservedIdentifier:!0}),Te=Mt(w.Question),Me;if(Mt(w.Colon))Me=de();return{kind:re.FunctionParameter,id:ee,type:Me,optional:Te,rest:B,...Ue(P)}}function Ep(P,B,ee){let Te=l,Me=u.scanRange(B,()=>(l=P,Qn(),ee()));return l=Te,Me}function Al(P){return{pos:P.pos+3,end:dh()&qt.Unterminated?P.end:P.end-2}}function po(){if(d.length===0||t.docs===!1)return[rt(),[]];let P=[];for(let B of d){let ee=Ep(kb.Doc,Al(B),()=>Rle(B));if(P.push(ee),B.comment)Tn(B.comment).parsedAsDocs=!0}return[d[0].pos,P]}function Rle(P){let B=[],ee=[];e:while(!0)switch(Ze()){case w.EndOfFile:break e;case w.At:let Te=jle();ee.push(Te);break;default:B.push(...hE());break}return{kind:re.Doc,content:B,tags:ee,...Ue(P.pos),end:P.end}}function hE(){let P=[],B=u.file.text,ee=rt(),Te=ee,Me=!1;e:while(!0)switch(Ze()){case w.DocCodeFenceDelimiter:Me=!Me,Qn();break;case w.NewLine:P.push(B.substring(Te,rt())),P.push(` -`),Qn(),Te=rt();while(Mt(w.Whitespace));if(!Mt(w.Star))break;if(!Me){Mt(w.Whitespace),Te=rt();break}let yt=rt();Mt(w.Whitespace),Te=Math.min(yt+1,rt());break;case w.EndOfFile:break e;case w.At:if(!Me)break e;Qn();break;case w.DocText:P.push(B.substring(Te,rt())),P.push(Ua()),Qn(),Te=rt();break;default:Qn();break}P.push(B.substring(Te,rt()));let gt=v9(P.join(""));return[{kind:re.DocText,text:gt,...Ue(ee)}]}function jle(){let P=rt();it(w.At);let B=TC("tag");switch(B.sv){case"param":return wC(P,B,re.DocParamTag,"param");case"template":return wC(P,B,re.DocTemplateTag,"templateParam");case"prop":return Fle(P,B);case"return":case"returns":return gE(P,B,re.DocReturnsTag);case"errors":return gE(P,B,re.DocErrorsTag);default:return gE(P,B,re.DocUnknownTag)}}function wC(P,B,ee,Te){let{name:Me,content:gt}=DC(Te);return{kind:ee,tagName:B,paramName:Me,content:gt,...Ue(P)}}function Fle(P,B){let{name:ee,content:Te}=DC("prop");return{kind:re.DocPropTag,tagName:B,propName:ee,content:Te,...Ue(P)}}function DC(P){let B=TC(P);Cle();let ee=hE();return{name:B,content:ee}}function Cle(){while(Mt(w.Whitespace));if(Mt(w.Hyphen))while(Mt(w.Whitespace));}function gE(P,B,ee){let Te=hE();return{kind:ee,tagName:B,content:Te,...Ue(P)}}function TC(P){if(P!=="tag")while(Mt(w.Whitespace));let B=rt(),ee;if(Ze()===w.Identifier)ee=Ua(),Qn();else if(Ze()===w.DocCodeSpan)ee=Ua(),Qn();else ee="",Kle({code:"doc-invalid-identifier",messageId:P});return{kind:re.Identifier,sv:ee,...Ue(B)}}function Ze(){return u.token}function dh(){return u.tokenFlags}function Ua(){return u.getTokenValue()}function rt(){return u.tokenPosition}function fh(){return u.position}function Qn(){return r=u.position,l===kb.Syntax?Mle():Lle()}function Mle(){d=[];for(;;)if(u.scan(),p7(Ze())){if(!a&&Ze()===w.NewLine)break;let P=void 0;if(t.comments&&d7(Ze()))P={kind:Ze()===w.SingleLineComment?re.LineComment:re.BlockComment,pos:rt(),end:fh()},p.push(P);if(dh()&qt.DocComment)d.push({pos:rt(),end:fh(),comment:P})}else break}function Lle(){u.scanDoc()}function qle(P){u.reScanStringTemplate(P)}function zc(){let P=rt();return r=P,s++,{kind:re.Identifier,sv:""+s,...Ue(P)}}function Ule(){let P=rt(),{items:B}=Wc();return{kind:re.TypeReference,target:zc(),arguments:B,...Ue(P)}}function Ue(P){let B=n?Xi.ThisNodeHasError:Xi.None;return n=!1,Ble({pos:P,end:r,flags:B})}function Ble(P){return P}function Wc(P={pos:-1,end:-1}){return{items:[],range:P}}function Bi(P,B){let ee=Wc();if(P.open!==w.None){let Te=rt();if(it(P.open))Tn(ee.range).pos=Te}if(P.allowEmpty&&Mt(P.close))return Tn(ee.range).end=r,ee;while(!0){let Te=rt(),{pos:Me,docs:gt,directives:yt,decorators:jn}=m({skipParsingDocNodes:Boolean(P.invalidAnnotationTarget)});if(P.invalidAnnotationTarget)xi(jn,P.invalidAnnotationTarget),NC(yt,P.invalidAnnotationTarget);if(yt.length===0&&jn.length===0&&SC(P)){if(it(P.close))Tn(ee.range).end=r;break}let ar;if(P.invalidAnnotationTarget)ar=B();else ar=B(Me,jn),Tn(ar).docs=gt,Tn(ar).directives=yt;if(ee.items.push(ar),Vle(P)){if(Mt(P.close)){Tn(ee.range).end=r;break}continue}else if(P.close===w.None)break;else if(Mt(P.close)){Tn(ee.range).end=r;break}else if(SC(P)){if(it(P.close))Tn(ee.range).end=r;break}else it(P.delimiter);if(Te===rt()){if(it(P.close))Tn(ee.range).end=r;Qn(),ee.items.pop();break}}return ee}function x_(P,B){return Ze()===P.open?Bi(P,B):Wc()}function Vle(P){if(Mt(P.delimiter))return!0;if(Ze()===P.toleratedDelimiter){if(!P.toleratedDelimiterIsValid)it(P.delimiter);return Qn(),!0}return!1}function SC(P){return P.close!==w.None&&(qw(Ze())||Ze()===w.EndOfFile)&&Ze()!==P.allowedStatementKeyword}function EC(P){return it(w.Semicolon),{kind:re.EmptyStatement,...Ue(P)}}function bE(P,B){do Qn();while(!qw(Ze())&&Ze()!==w.At&&Ze()!==w.Semicolon&&Ze()!==w.EndOfFile);return an({code:"token-expected",messageId:"statement",target:{pos:P,end:r}}),{kind:re.InvalidStatement,decorators:B,...Ue(P)}}function an(P){n=!0;let B={file:u.file,pos:P.target?.pos??rt(),end:P.target?.end??fh()};if(!P.printable)o=!1;let ee=P.target?.realPos??B.pos;if(i===ee)return;i=ee;let Te=tn({...P,target:B});kC(Te.severity==="error","This function is for reporting errors. Use warning() for warnings."),c.push(Te)}function Kle(P){let B={file:u.file,pos:P.target?.pos??rt(),end:P.target?.end??fh()},ee=tn({...P,target:B});kC(ee.severity==="warning","This function is for reporting warnings only. Use error() for errors."),c.push(ee)}function Jle(P){if(P.severity==="error")n=!0,o=!1;c.push(P)}function kC(P,B){let ee={file:u.file,pos:rt(),end:fh()};Qe(P,B,ee)}function xi(P,B){for(let ee of P)an({code:"invalid-decorator-location",format:{nodeName:B},target:ee})}function NC(P,B){for(let ee of P)an({code:"invalid-directive-location",format:{nodeName:B},target:ee})}function it(P){if(Ze()===P)return Qn(),!0;let B=PC(P);return an({code:"token-expected",format:{token:ab[P]},target:B,printable:Lw(P)}),!1}function mh(...P){let B=Ze();for(let ee of P){if(ee===w.None)continue;if(B===ee)return B}return Gle(...P),w.None}function OC(...P){let B=mh(...P);if(B!==w.None)Qn();return B}function Gle(...P){let B=PC(P[0]),ee=P.map((Te,Me)=>{if(Me===P.length-1)return`or ${ab[Te]}`;return ab[Te]});an({code:"token-expected",format:{token:ee.join(", ")},target:B})}function Mt(P){if(Ze()===P)return Qn(),!0;return!1}function PC(P){return Lw(P)?{pos:r,end:r+1,realPos:rt()}:void 0}}function XP(e){return e.kind===re.TypeReference&&e.target.kind===re.Identifier&&e.arguments.length===0}function g5(e){if(e.kind!==re.NamespaceStatement)return!1;while(!wm(e.statements)&&e.statements)e=e.statements;return e.statements===void 0}var Or,kb;var Xs=q(()=>{Gt();rc();vt();Yn();YP();ub();It();(function(e){let t={allowEmpty:!0,toleratedDelimiterIsValid:!0,allowedStatementKeyword:w.None};e.OperationParameters={...t,open:w.OpenParen,close:w.CloseParen,delimiter:w.Comma,toleratedDelimiter:w.Semicolon},e.DecoratorArguments={...e.OperationParameters,invalidAnnotationTarget:"expression"},e.FunctionArguments={...e.OperationParameters,invalidAnnotationTarget:"expression"},e.ModelProperties={...t,open:w.OpenBrace,close:w.CloseBrace,delimiter:w.Semicolon,toleratedDelimiter:w.Comma},e.ObjectLiteralProperties={...t,open:w.HashBrace,close:w.CloseBrace,delimiter:w.Comma,toleratedDelimiter:w.Comma},e.InterfaceMembers={...t,open:w.OpenBrace,close:w.CloseBrace,delimiter:w.Semicolon,toleratedDelimiter:w.Comma,toleratedDelimiterIsValid:!1,allowedStatementKeyword:w.OpKeyword},e.ScalarMembers={...t,open:w.OpenBrace,close:w.CloseBrace,delimiter:w.Semicolon,toleratedDelimiter:w.Comma,toleratedDelimiterIsValid:!1,allowedStatementKeyword:w.InitKeyword},e.UnionVariants={...t,open:w.OpenBrace,close:w.CloseBrace,delimiter:w.Semicolon,toleratedDelimiter:w.Comma,toleratedDelimiterIsValid:!0},e.EnumMembers={...e.ModelProperties};let n={allowEmpty:!0,delimiter:w.Comma,toleratedDelimiter:w.Semicolon,toleratedDelimiterIsValid:!1,invalidAnnotationTarget:"expression",allowedStatementKeyword:w.None};e.TemplateParameters={...n,allowEmpty:!1,open:w.LessThan,close:w.GreaterThan,invalidAnnotationTarget:"template parameter"},e.TemplateArguments={...e.TemplateParameters},e.CallArguments={...n,allowEmpty:!0,open:w.OpenParen,close:w.CloseParen},e.Heritage={...n,allowEmpty:!1,open:w.None,close:w.None},e.Tuple={...n,allowEmpty:!0,open:w.OpenBracket,close:w.CloseBracket},e.ArrayLiteral={...n,allowEmpty:!0,open:w.HashBracket,close:w.CloseBracket},e.FunctionParameters={...n,allowEmpty:!0,open:w.OpenParen,close:w.CloseParen,invalidAnnotationTarget:"expression"}})(Or||(Or={}));(function(e){e[e.Syntax=0]="Syntax",e[e.Doc=1]="Doc"})(kb||(kb={}))});var Vu=q(()=>{Gt();vt();Hg();ic();Xs();It()});var b5=q(()=>{vt()});var v5=q(()=>{vt();It()});var e$=q(()=>{vt();Yn();yr()});var _5;var t$=q(()=>{ac();_5={int64:[kn("-9223372036854775808"),kn("9223372036854775807"),{int:!0,isJsNumber:!1}],int32:[kn("-2147483648"),kn("2147483647"),{int:!0,isJsNumber:!0}],int16:[kn("-32768"),kn("32767"),{int:!0,isJsNumber:!0}],int8:[kn("-128"),kn("127"),{int:!0,isJsNumber:!0}],uint64:[kn("0"),kn("18446744073709551615"),{int:!0,isJsNumber:!1}],uint32:[kn("0"),kn("4294967295"),{int:!0,isJsNumber:!0}],uint16:[kn("0"),kn("65535"),{int:!0,isJsNumber:!0}],uint8:[kn("0"),kn("255"),{int:!0,isJsNumber:!0}],safeint:[kn(Number.MIN_SAFE_INTEGER.toString()),kn(Number.MAX_SAFE_INTEGER.toString()),{int:!0,isJsNumber:!0}],float32:[kn("-3.4e38"),kn("3.4e38"),{int:!1,isJsNumber:!0}],float64:[kn(`${-Number.MAX_VALUE}`),kn(Number.MAX_VALUE.toString()),{int:!1,isJsNumber:!0}]}});var x5=q(()=>{ka();vt();t$();ac()});var w5;var D5=q(()=>{Gt();Eb();vt();cc();lc();Yn();t$();yr();It();(function(e){e[e.false=0]="false",e[e.true=1]="true",e[e.maybe=2]="maybe"})(w5||(w5={}))});function EEe(e){if(!e.sourceProperty)return;let t=new Set;for(let n=e;n;n=n.sourceProperty)if(n.model?.name)t.add(n.model);return t}function kEe(e,t){for(let n of t)if(!e.has(n)){for(let r=n.baseModel;r;r=r.baseModel)if(e.has(r)){e.add(n);break}}}function Sb(e,t,n){if(n)t=kD(e,t,n);if(t.name)return t;if(Qe(!t.baseModel,"Anonymous model with base model."),t.properties.size===0)return t;let r;for(let s of t.properties.values()){let o=EEe(s);if(!o)return t;if(!r){r=o;continue}kEe(o,r);for(let a of r)if(!o.has(a))r.delete(a)}let i;for(let s of r??[]){if(t.properties.size===T5(s)){i=s;break}if(n&&!i&&t.properties.size===T5(s,n)){i=s;continue}}return i??t}function kD(e,t,n){let r=!1;for(let a of Zs(t))if(!n(a)){r=!0;break}if(!r)return t;let i=zs.realmForType.get(t),s=i?Kn(i):Kn(e),o=s.model.create({name:"",indexer:void 0,properties:{},decorators:[],derivedModels:[],sourceModels:[{usage:"spread",model:t}]});for(let a of Zs(t))if(n(a)){let l=s.type.clone(a);Object.assign(l,{sourceProperty:a,model:o}),o.properties.set(a.name,l),s.type.finishType(l)}return e.checker.finishType(o)}function*Zs(e){let t=new Set;for(let n=e;n;n=n.baseModel)for(let r of n.properties.values()){if(t.has(r.name))continue;t.add(r.name),yield r}}function T5(e,t){let n=0;for(let r of Zs(e))if(!t||t(r))n++;return n}var ED,mc,S5;var Eb=q(()=>{Pd();nP();ka();Gt();YO();Vu();b5();v5();sb();vt();Hg();qm();ic();e$();Mu();cc();x5();Yn();YP();ac();Xs();D5();yr();It();(function(e){e[e.None=0]="None",e[e.InTemplateDeclaration=1]="InTemplateDeclaration"})(ED||(ED={}));mc=class mc{mapper;flags;#e;static from(e){if(e instanceof mc)return e;return new mc(e,ED.None)}static DEFAULT=new mc(void 0,ED.None);constructor(e,t,n){this.mapper=e,this.flags=t,this.#e=n,Object.freeze(this)}withFlags(e){return new mc(this.mapper,this.flags|e,this.#e)}maskFlags(e){return new mc(this.mapper,this.flags&~e,this.#e)}hasFlags(e){return(this.flags&e)===e}withMapper(e){return new mc(e,this.flags,this.#e)}observeTemplateParameter(e){this.#e?.add(e)}enterTemplateObserverScope(){return new mc(this.mapper,this.flags,new Set)}exitTemplateObserverScope(){return new mc(this.mapper,this.flags,void 0)}hasObservedTemplateParameters(){return this.#e!==void 0?this.#e.size>0:!1}};(function(e){e[e.Value=0]="Value",e[e.Type=1]="Type",e[e.BaseType=2]="BaseType",e[e.Constraint=3]="Constraint"})(S5||(S5={}))});var E5;var i$=q(()=>{mn();E5=Symbol.for("TYPESPEC_EMITTED_FILES_PATHS");if(globalThis[E5]===void 0)globalThis[E5]=new WeakMap});var dl;var k5=q(()=>{dl={fromPackageRoot(e){return{kind:"file-ref",path:e}}}});function jEe(e,t,n){return REe.diff(e,t,n)}function qEe(e){let t=e.indexOf(h$);return t!==-1?e.charAt(t+1)===AD?nK:tK:MEe}function g$(e){return e===tK?h$:e===nK?rK:LEe}function iK(e,t){let n=UEe.get(t);return e.match(n)?.length??0}function VEe(e){return ID(0,e,BEe,AD)}function KEe(e){return this[e<0?this.length+e:e]}function GEe(e){let t=e.length;for(;t>0&&(e[t-1]==="\r"||e[t-1]===` -`);)t--;return t`'${i}'`));return`Unexpected doc.type '${e.type}'. -Expected it to be ${r}.`}function YEe(e,t,n,r){let i=[e];for(;i.length>0;){let s=i.pop();if(s===N5){n(i.pop());continue}n&&i.push(s,N5);let o=Vd(s);if(!o)throw new ty(s);if(t?.(s)!==!1)switch(o){case gc:case hl:{let a=o===gc?s:s.parts;for(let l=a.length,c=l-1;c>=0;--c)i.push(a[c]);break}case eo:i.push(s.flatContents,s.breakContents);break;case Os:if(r&&s.expandedStates)for(let a=s.expandedStates.length,l=a-1;l>=0;--l)i.push(s.expandedStates[l]);else i.push(s.contents);break;case vc:case bc:case xc:case gl:case wc:i.push(s.contents);break;case Bd:case Hu:case _c:case Dc:case yi:case Jo:break;default:throw new ty(s)}}}function jD(e,t){if(typeof e=="string")return t(e);let n=new Map;return r(e);function r(s){return b$(n,s,i)}function i(s){switch(Vd(s)){case gc:return t(s.map(r));case hl:return t({...s,parts:s.parts.map(r)});case eo:return t({...s,breakContents:r(s.breakContents),flatContents:r(s.flatContents)});case Os:{let{expandedStates:o,contents:a}=s;return o?(o=o.map(r),a=o[0]):a=r(a),t({...s,contents:a,expandedStates:o})}case vc:case bc:case xc:case gl:case wc:return t({...s,contents:r(s.contents)});case Bd:case Hu:case _c:case Dc:case yi:case Jo:return t(s);default:throw new ty(s)}}}function _$(e,t,n){let r=n,i=!1;function s(o){if(i)return!1;let a=t(o);a!==void 0&&(i=!0,r=a)}return v$(e,s),r}function XEe(e){if(e.type===Os&&e.break||e.type===yi&&e.hard||e.type===Jo)return!0}function ZEe(e){return _$(e,XEe,!1)}function O5(e){if(e.length>0){let t=mi(0,e,-1);!t.expandedStates&&!t.break&&(t.break="propagated")}return null}function eke(e){let t=new Set,n=[];function r(s){if(s.type===Jo&&O5(n),s.type===Os){if(n.push(s),t.has(s))return!1;t.add(s)}}function i(s){s.type===Os&&n.pop().break&&O5(n)}v$(e,r,i,!0)}function tke(e){return e.type===yi&&!e.hard?e.soft?"":" ":e.type===eo?e.flatContents:e}function nke(e){return jD(e,tke)}function P5(e){for(e=[...e];e.length>=2&&mi(0,e,-2).type===yi&&mi(0,e,-1).type===Jo;)e.length-=2;if(e.length>0){let t=Ob(mi(0,e,-1));e[e.length-1]=t}return e}function Ob(e){switch(Vd(e)){case bc:case xc:case Os:case wc:case gl:{let t=Ob(e.contents);return{...e,contents:t}}case eo:return{...e,breakContents:Ob(e.breakContents),flatContents:Ob(e.flatContents)};case hl:return{...e,parts:P5(e.parts)};case gc:return P5(e);case Bd:return GEe(e);case vc:case Hu:case _c:case Dc:case yi:case Jo:break;default:throw new ty(e)}return e}function oK(e){return Ob(ike(e))}function rke(e){switch(Vd(e)){case hl:{let{parts:t}=e;if(t.every((n)=>n===""))return"";if(t.length===1)return t[0];break}case Os:if(!e.contents&&!e.id&&!e.break&&!e.expandedStates)return"";if(e.contents.type===Os&&e.contents.id===e.id&&e.contents.break===e.break&&e.contents.expandedStates===e.expandedStates)return e.contents;break;case vc:case bc:case xc:case wc:if(!e.contents)return"";break;case eo:if(!e.flatContents&&!e.breakContents)return"";break;case gc:{let t=[];for(let n of e){if(!n)continue;let[r,...i]=Array.isArray(n)?n:[n];typeof r=="string"&&typeof mi(0,t,-1)=="string"?t[t.length-1]+=r:t.push(r),t.push(...i)}return t.length===0?"":t.length===1?t[0]:t}case Bd:case Hu:case _c:case Dc:case yi:case gl:case Jo:break;default:throw new ty(e)}return e}function ike(e){return jD(e,(t)=>rke(t))}function ske(e,t=mK){return jD(e,(n)=>typeof n=="string"?pK(t,n.split(` -`)):n)}function oke(e){if(e.type===yi)return!0}function ake(e){return _$(e,oke,!1)}function OD(e,t){return e.type===gl?{...e,contents:t(e.contents)}:t(e)}function $D(e){return yl(e),{type:bc,contents:e}}function ny(e,t){return cke(e),yl(t),{type:vc,contents:t,n:e}}function uke(e){return ny(Number.NEGATIVE_INFINITY,e)}function lK(e){return ny({type:"root"},e)}function pke(e){return ny(-1,e)}function cK(e,t,n){yl(e);let r=e;if(t>0){for(let i=0;i0?`, { ${l.join(", ")} }`:"";return`indentIfBreak(${r(s.contents)}${c})`}if(s.type===Os){let l=[];s.break&&s.break!=="propagated"&&l.push("shouldBreak: true"),s.id&&l.push(`id: ${i(s.id)}`);let c=l.length>0?`, { ${l.join(", ")} }`:"";return s.expandedStates?`conditionalGroup([${s.expandedStates.map((u)=>r(u)).join(",")}]${c})`:`group(${r(s.contents)}${c})`}if(s.type===hl)return`fill([${s.parts.map((l)=>r(l)).join(", ")}])`;if(s.type===wc)return"lineSuffix("+r(s.contents)+")";if(s.type===Dc)return"lineSuffixBoundary";if(s.type===gl)return`label(${JSON.stringify(s.label)}, ${r(s.contents)})`;if(s.type===Hu)return"cursor";throw Error("Unknown doc type "+s.type)}function i(s){if(typeof s!="symbol")return JSON.stringify(String(s));if(s in t)return t[s];let o=s.description||"symbol";for(let a=0;;a++){let l=o+(a>0?` #${a}`:"");if(!n.has(l))return n.add(l),t[s]=`Symbol.for(${JSON.stringify(l)})`}}}function Oke(e){let t=e[0],n=e[1];for(let r=0;r=i&&$5<=s)return[i,s];s-i>n-t&&(t=i,n=s)}return[t,n]}function jke(e){if(!e)return 0;if(!Rke.test(e))return e.length;let t=0;e=e.replace(xke(),(n)=>(t+=Ake(n)?1:2,""));for(let n of e){let r=n.codePointAt(0);r<=31||r>=127&&r<=159||r>=768&&r<=879||r>=65024&&r<=65039||(t+=Pke(r)||$ke(r)?2:1)}return t}function bK(e,t,n){let r=t.type===1?e.queue.slice(0,-1):[...e.queue,t],i="",s=0,o=0,a=0;for(let m of r)switch(m.type){case 0:u(),n.useTabs?l(1):c(n.tabWidth);break;case 3:{let{string:y}=m;u(),i+=y,s+=y.length;break}case 2:{let{width:y}=m;o+=1,a+=y;break}default:throw Error(`Unexpected indent comment '${m.type}'.`)}return d(),{...e,value:i,length:s,queue:r};function l(m){i+="\t".repeat(m),s+=n.tabWidth*m}function c(m){i+=" ".repeat(m),s+=m}function u(){n.useTabs?p():d()}function p(){o>0&&l(o),f()}function d(){a>0&&c(a),f()}function f(){o=0,a=0}}function Mke(e,t,n){if(!t)return e;if(t.type==="root")return{...e,root:e};if(t===Number.NEGATIVE_INFINITY)return e.root;let r;return typeof t=="number"?t<0?r=Cke:r={type:2,width:t}:r={type:3,string:t},bK(e,r,n)}function Lke(e,t){return bK(e,Fke,t)}function qke(e){let t=0;for(let n=e.length-1;n>=0;n--){let r=e[n];if(r===" "||r==="\t")t++;else break}return t}function vK(e){let t=qke(e);return{text:t===0?e:e.slice(0,e.length-t),count:t}}function ND(e,t,n,r,i,s){if(n===Number.POSITIVE_INFINITY)return!0;let o=t.length,a=!1,l=[e],c="";for(;n>=0;){if(l.length===0){if(o===0)return!0;l.push(t[--o]);continue}let{mode:u,doc:p}=l.pop(),d=Vd(p);switch(d){case Bd:p&&(a&&(c+=" ",n-=1,a=!1),c+=p,n-=w$(p));break;case gc:case hl:{let f=d===gc?p:p.parts,m=p[d$]??0;for(let y=f.length-1;y>=m;y--)l.push({mode:u,doc:f[y]});break}case bc:case vc:case xc:case gl:l.push({mode:u,doc:p.contents});break;case _c:{let{text:f,count:m}=vK(c);c=f,n+=m;break}case Os:{if(s&&p.break)return!1;let f=p.break?Ko:u,m=p.expandedStates&&f===Ko?mi(0,p.expandedStates,-1):p.contents;l.push({mode:f,doc:m});break}case eo:{let f=(p.groupId?i[p.groupId]||fl:u)===Ko?p.breakContents:p.flatContents;f&&l.push({mode:u,doc:f});break}case yi:if(u===Ko||p.hard)return!0;p.soft||(a=!0);break;case wc:r=!0;break;case Dc:if(r)return!1;break}}return!1}function CD(e,t){let n=Object.create(null),r=t.printWidth,i=g$(t.endOfLine),s=0,o=[{indent:gK,mode:Ko,doc:e}],a=!1,l=[],c=new Bke;for(eke(e);o.length>0;){let{indent:m,mode:y,doc:h}=o.pop();switch(Vd(h)){case Bd:{let b=i!==` +`;case ne.t:return"\t";case ne.DoubleQuote:return'"';case ne.Backslash:return"\\";case ne.$:return"$";case ne.At:return"@";case ne.Backtick:return"`";default:return T({code:"invalid-escape-sequence"},j,j+2),String.fromCharCode(H)}}function he(){let j=0;while(!0){if(i++,j++,c())break;let H=r.charCodeAt(i);if(jne.MaxAscii){let ge=r.codePointAt(i);if(Em(ge))return Oe(ge)}break}if(j>=ob.MinLength&&j<=ob.MaxLength){let H=Mw.get(u());if(H)return o=H}return o=w.Identifier}function Ne(){let j;do if(i++,c())return o=w.Identifier;while(mw(j=r.charCodeAt(i)));if(j>ne.MaxAscii){let H=r.codePointAt(i);if(Em(H))return Oe(H)}return o=w.Identifier}function Re(){i++,l|=qt.Backticked;e:for(;!c();i++){let j=r.charCodeAt(i);switch(j){case ne.Backslash:i++,l|=qt.Escaped;continue;case ne.Backtick:return i++,o=w.Identifier;case ne.CarriageReturn:case ne.LineFeed:break e;default:if(j>ne.MaxAscii)l|=qt.NonAscii}}return g(w.Identifier)}function Oe(j){l|=qt.NonAscii;let H=j;do i+=Jg(H);while(!c()&&Gg(H=r.codePointAt(i)));return o=w.Identifier}function G(){return c7(r,i,s)}function V(){let j=r.charCodeAt(i);if(i+=Cw,T({code:"conflict-marker"}),j===ne.LessThan||j===ne.GreaterThan)while(i=0&&n{rc();l7();_t();Yn();Fw();ol();(function(e){e[e.None=0]="None",e[e.Invalid=1]="Invalid",e[e.EndOfFile=2]="EndOfFile",e[e.Identifier=3]="Identifier",e[e.NumericLiteral=4]="NumericLiteral",e[e.StringLiteral=5]="StringLiteral",e[e.StringTemplateHead=6]="StringTemplateHead",e[e.StringTemplateMiddle=7]="StringTemplateMiddle",e[e.StringTemplateTail=8]="StringTemplateTail",e[e.__StartTrivia=9]="__StartTrivia",e[e.SingleLineComment=9]="SingleLineComment",e[e.MultiLineComment=10]="MultiLineComment",e[e.NewLine=11]="NewLine",e[e.Whitespace=12]="Whitespace",e[e.ConflictMarker=13]="ConflictMarker",e[e.__EndTrivia=14]="__EndTrivia",e[e.__StartDocComment=14]="__StartDocComment",e[e.DocText=14]="DocText",e[e.DocCodeSpan=15]="DocCodeSpan",e[e.DocCodeFenceDelimiter=16]="DocCodeFenceDelimiter",e[e.__EndDocComment=17]="__EndDocComment",e[e.__StartPunctuation=17]="__StartPunctuation",e[e.OpenBrace=17]="OpenBrace",e[e.CloseBrace=18]="CloseBrace",e[e.OpenParen=19]="OpenParen",e[e.CloseParen=20]="CloseParen",e[e.OpenBracket=21]="OpenBracket",e[e.CloseBracket=22]="CloseBracket",e[e.Dot=23]="Dot",e[e.Ellipsis=24]="Ellipsis",e[e.Semicolon=25]="Semicolon",e[e.Comma=26]="Comma",e[e.LessThan=27]="LessThan",e[e.GreaterThan=28]="GreaterThan",e[e.Equals=29]="Equals",e[e.Ampersand=30]="Ampersand",e[e.Bar=31]="Bar",e[e.Question=32]="Question",e[e.Colon=33]="Colon",e[e.ColonColon=34]="ColonColon",e[e.At=35]="At",e[e.AtAt=36]="AtAt",e[e.Hash=37]="Hash",e[e.HashBrace=38]="HashBrace",e[e.HashBracket=39]="HashBracket",e[e.Star=40]="Star",e[e.ForwardSlash=41]="ForwardSlash",e[e.Plus=42]="Plus",e[e.Hyphen=43]="Hyphen",e[e.Exclamation=44]="Exclamation",e[e.LessThanEquals=45]="LessThanEquals",e[e.GreaterThanEquals=46]="GreaterThanEquals",e[e.AmpsersandAmpersand=47]="AmpsersandAmpersand",e[e.BarBar=48]="BarBar",e[e.EqualsEquals=49]="EqualsEquals",e[e.ExclamationEquals=50]="ExclamationEquals",e[e.EqualsGreaterThan=51]="EqualsGreaterThan",e[e.__EndPunctuation=52]="__EndPunctuation",e[e.__StartKeyword=52]="__StartKeyword",e[e.__StartStatementKeyword=52]="__StartStatementKeyword",e[e.ImportKeyword=52]="ImportKeyword",e[e.ModelKeyword=53]="ModelKeyword",e[e.ScalarKeyword=54]="ScalarKeyword",e[e.NamespaceKeyword=55]="NamespaceKeyword",e[e.UsingKeyword=56]="UsingKeyword",e[e.OpKeyword=57]="OpKeyword",e[e.EnumKeyword=58]="EnumKeyword",e[e.AliasKeyword=59]="AliasKeyword",e[e.IsKeyword=60]="IsKeyword",e[e.InterfaceKeyword=61]="InterfaceKeyword",e[e.UnionKeyword=62]="UnionKeyword",e[e.ProjectionKeyword=63]="ProjectionKeyword",e[e.ElseKeyword=64]="ElseKeyword",e[e.IfKeyword=65]="IfKeyword",e[e.DecKeyword=66]="DecKeyword",e[e.ConstKeyword=67]="ConstKeyword",e[e.InitKeyword=68]="InitKeyword",e[e.__EndStatementKeyword=69]="__EndStatementKeyword",e[e.__StartModifierKeyword=69]="__StartModifierKeyword",e[e.ExternKeyword=69]="ExternKeyword",e[e.InternalKeyword=70]="InternalKeyword",e[e.AutoKeyword=71]="AutoKeyword",e[e.__EndModifierKeyword=72]="__EndModifierKeyword",e[e.ExtendsKeyword=72]="ExtendsKeyword",e[e.FnKeyword=73]="FnKeyword",e[e.TrueKeyword=74]="TrueKeyword",e[e.FalseKeyword=75]="FalseKeyword",e[e.ReturnKeyword=76]="ReturnKeyword",e[e.VoidKeyword=77]="VoidKeyword",e[e.NeverKeyword=78]="NeverKeyword",e[e.UnknownKeyword=79]="UnknownKeyword",e[e.ValueOfKeyword=80]="ValueOfKeyword",e[e.TypeOfKeyword=81]="TypeOfKeyword",e[e.__EndKeyword=82]="__EndKeyword",e[e.__StartReservedKeyword=82]="__StartReservedKeyword",e[e.StatemachineKeyword=82]="StatemachineKeyword",e[e.MacroKeyword=83]="MacroKeyword",e[e.PackageKeyword=84]="PackageKeyword",e[e.MetadataKeyword=85]="MetadataKeyword",e[e.EnvKeyword=86]="EnvKeyword",e[e.ArgKeyword=87]="ArgKeyword",e[e.DeclareKeyword=88]="DeclareKeyword",e[e.ArrayKeyword=89]="ArrayKeyword",e[e.StructKeyword=90]="StructKeyword",e[e.RecordKeyword=91]="RecordKeyword",e[e.ModuleKeyword=92]="ModuleKeyword",e[e.ModKeyword=93]="ModKeyword",e[e.SymKeyword=94]="SymKeyword",e[e.ContextKeyword=95]="ContextKeyword",e[e.PropKeyword=96]="PropKeyword",e[e.PropertyKeyword=97]="PropertyKeyword",e[e.ScenarioKeyword=98]="ScenarioKeyword",e[e.PubKeyword=99]="PubKeyword",e[e.SubKeyword=100]="SubKeyword",e[e.TypeRefKeyword=101]="TypeRefKeyword",e[e.TraitKeyword=102]="TraitKeyword",e[e.ThisKeyword=103]="ThisKeyword",e[e.SelfKeyword=104]="SelfKeyword",e[e.SuperKeyword=105]="SuperKeyword",e[e.KeyofKeyword=106]="KeyofKeyword",e[e.WithKeyword=107]="WithKeyword",e[e.ImplementsKeyword=108]="ImplementsKeyword",e[e.ImplKeyword=109]="ImplKeyword",e[e.SatisfiesKeyword=110]="SatisfiesKeyword",e[e.FlagKeyword=111]="FlagKeyword",e[e.PartialKeyword=112]="PartialKeyword",e[e.PrivateKeyword=113]="PrivateKeyword",e[e.PublicKeyword=114]="PublicKeyword",e[e.ProtectedKeyword=115]="ProtectedKeyword",e[e.SealedKeyword=116]="SealedKeyword",e[e.LocalKeyword=117]="LocalKeyword",e[e.AsyncKeyword=118]="AsyncKeyword",e[e.__EndReservedKeyword=119]="__EndReservedKeyword",e[e.__Count=119]="__Count"})(w||(w={}));ab=MTe([[w.None,"none"],[w.Invalid,"invalid"],[w.EndOfFile,"end of file"],[w.SingleLineComment,"single-line comment"],[w.MultiLineComment,"multi-line comment"],[w.ConflictMarker,"conflict marker"],[w.NumericLiteral,"numeric literal"],[w.StringLiteral,"string literal"],[w.StringTemplateHead,"string template head"],[w.StringTemplateMiddle,"string template middle"],[w.StringTemplateTail,"string template tail"],[w.NewLine,"newline"],[w.Whitespace,"whitespace"],[w.DocCodeFenceDelimiter,"doc code fence delimiter"],[w.DocCodeSpan,"doc code span"],[w.DocText,"doc text"],[w.OpenBrace,"'{'"],[w.CloseBrace,"'}'"],[w.OpenParen,"'('"],[w.CloseParen,"')'"],[w.OpenBracket,"'['"],[w.CloseBracket,"']'"],[w.Dot,"'.'"],[w.Ellipsis,"'...'"],[w.Semicolon,"';'"],[w.Comma,"','"],[w.LessThan,"'<'"],[w.GreaterThan,"'>'"],[w.Equals,"'='"],[w.Ampersand,"'&'"],[w.Bar,"'|'"],[w.Question,"'?'"],[w.Colon,"':'"],[w.ColonColon,"'::'"],[w.At,"'@'"],[w.AtAt,"'@@'"],[w.Hash,"'#'"],[w.HashBrace,"'#{'"],[w.HashBracket,"'#['"],[w.Star,"'*'"],[w.ForwardSlash,"'/'"],[w.Plus,"'+'"],[w.Hyphen,"'-'"],[w.Exclamation,"'!'"],[w.LessThanEquals,"'<='"],[w.GreaterThanEquals,"'>='"],[w.AmpsersandAmpersand,"'&&'"],[w.BarBar,"'||'"],[w.EqualsEquals,"'=='"],[w.ExclamationEquals,"'!='"],[w.EqualsGreaterThan,"'=>'"],[w.Identifier,"identifier"],[w.ImportKeyword,"'import'"],[w.ModelKeyword,"'model'"],[w.ScalarKeyword,"'scalar'"],[w.NamespaceKeyword,"'namespace'"],[w.UsingKeyword,"'using'"],[w.OpKeyword,"'op'"],[w.EnumKeyword,"'enum'"],[w.AliasKeyword,"'alias'"],[w.IsKeyword,"'is'"],[w.InterfaceKeyword,"'interface'"],[w.UnionKeyword,"'union'"],[w.ProjectionKeyword,"'projection'"],[w.ElseKeyword,"'else'"],[w.IfKeyword,"'if'"],[w.DecKeyword,"'dec'"],[w.FnKeyword,"'fn'"],[w.ValueOfKeyword,"'valueof'"],[w.TypeOfKeyword,"'typeof'"],[w.ConstKeyword,"'const'"],[w.InitKeyword,"'init'"],[w.ExtendsKeyword,"'extends'"],[w.TrueKeyword,"'true'"],[w.FalseKeyword,"'false'"],[w.ReturnKeyword,"'return'"],[w.VoidKeyword,"'void'"],[w.NeverKeyword,"'never'"],[w.UnknownKeyword,"'unknown'"],[w.ExternKeyword,"'extern'"],[w.AutoKeyword,"'auto'"],[w.StatemachineKeyword,"'statemachine'"],[w.MacroKeyword,"'macro'"],[w.PackageKeyword,"'package'"],[w.MetadataKeyword,"'metadata'"],[w.EnvKeyword,"'env'"],[w.ArgKeyword,"'arg'"],[w.DeclareKeyword,"'declare'"],[w.ArrayKeyword,"'array'"],[w.StructKeyword,"'struct'"],[w.RecordKeyword,"'record'"],[w.ModuleKeyword,"'module'"],[w.ModKeyword,"'mod'"],[w.SymKeyword,"'sym'"],[w.ContextKeyword,"'context'"],[w.PropKeyword,"'prop'"],[w.PropertyKeyword,"'property'"],[w.ScenarioKeyword,"'scenario'"],[w.PubKeyword,"'pub'"],[w.SubKeyword,"'sub'"],[w.TypeRefKeyword,"'typeref'"],[w.TraitKeyword,"'trait'"],[w.ThisKeyword,"'this'"],[w.SelfKeyword,"'self'"],[w.SuperKeyword,"'super'"],[w.KeyofKeyword,"'keyof'"],[w.WithKeyword,"'with'"],[w.ImplementsKeyword,"'implements'"],[w.ImplKeyword,"'impl'"],[w.SatisfiesKeyword,"'satisfies'"],[w.FlagKeyword,"'flag'"],[w.PartialKeyword,"'partial'"],[w.PrivateKeyword,"'private'"],[w.PublicKeyword,"'public'"],[w.ProtectedKeyword,"'protected'"],[w.InternalKeyword,"'internal'"],[w.SealedKeyword,"'sealed'"],[w.LocalKeyword,"'local'"],[w.AsyncKeyword,"'async'"]]),Mw=new Map([["import",w.ImportKeyword],["model",w.ModelKeyword],["scalar",w.ScalarKeyword],["namespace",w.NamespaceKeyword],["interface",w.InterfaceKeyword],["union",w.UnionKeyword],["if",w.IfKeyword],["else",w.ElseKeyword],["projection",w.ProjectionKeyword],["using",w.UsingKeyword],["op",w.OpKeyword],["extends",w.ExtendsKeyword],["is",w.IsKeyword],["enum",w.EnumKeyword],["alias",w.AliasKeyword],["dec",w.DecKeyword],["fn",w.FnKeyword],["valueof",w.ValueOfKeyword],["typeof",w.TypeOfKeyword],["const",w.ConstKeyword],["init",w.InitKeyword],["true",w.TrueKeyword],["false",w.FalseKeyword],["return",w.ReturnKeyword],["void",w.VoidKeyword],["never",w.NeverKeyword],["unknown",w.UnknownKeyword],["extern",w.ExternKeyword],["auto",w.AutoKeyword],["internal",w.InternalKeyword],["statemachine",w.StatemachineKeyword],["macro",w.MacroKeyword],["package",w.PackageKeyword],["metadata",w.MetadataKeyword],["env",w.EnvKeyword],["arg",w.ArgKeyword],["declare",w.DeclareKeyword],["array",w.ArrayKeyword],["struct",w.StructKeyword],["record",w.RecordKeyword],["module",w.ModuleKeyword],["mod",w.ModKeyword],["sym",w.SymKeyword],["context",w.ContextKeyword],["prop",w.PropKeyword],["property",w.PropertyKeyword],["scenario",w.ScenarioKeyword],["pub",w.PubKeyword],["sub",w.SubKeyword],["typeref",w.TypeRefKeyword],["trait",w.TraitKeyword],["this",w.ThisKeyword],["self",w.SelfKeyword],["super",w.SuperKeyword],["keyof",w.KeyofKeyword],["with",w.WithKeyword],["implements",w.ImplementsKeyword],["impl",w.ImplKeyword],["satisfies",w.SatisfiesKeyword],["flag",w.FlagKeyword],["partial",w.PartialKeyword],["private",w.PrivateKeyword],["public",w.PublicKeyword],["protected",w.ProtectedKeyword],["sealed",w.SealedKeyword],["local",w.LocalKeyword],["async",w.AsyncKeyword]]),u7=new Map([["statemachine",w.StatemachineKeyword],["macro",w.MacroKeyword],["package",w.PackageKeyword],["metadata",w.MetadataKeyword],["env",w.EnvKeyword],["arg",w.ArgKeyword],["declare",w.DeclareKeyword],["array",w.ArrayKeyword],["struct",w.StructKeyword],["record",w.RecordKeyword],["module",w.ModuleKeyword],["mod",w.ModuleKeyword],["sym",w.SymKeyword],["context",w.ContextKeyword],["prop",w.PropKeyword],["property",w.PropertyKeyword],["scenario",w.ScenarioKeyword],["trait",w.TraitKeyword],["this",w.ThisKeyword],["self",w.SelfKeyword],["super",w.SuperKeyword],["keyof",w.KeyofKeyword],["with",w.WithKeyword],["implements",w.ImplementsKeyword],["impl",w.ImplKeyword],["satisfies",w.SatisfiesKeyword],["flag",w.FlagKeyword],["partial",w.PartialKeyword],["private",w.PrivateKeyword],["public",w.PublicKeyword],["protected",w.ProtectedKeyword],["sealed",w.SealedKeyword],["local",w.LocalKeyword],["async",w.AsyncKeyword]]);(function(e){e[e.MinLength=2]="MinLength",e[e.MaxLength=12]="MaxLength"})(ob||(ob={}));(function(e){e[e.None=0]="None",e[e.Escaped=1]="Escaped",e[e.TripleQuoted=2]="TripleQuoted",e[e.Unterminated=4]="Unterminated",e[e.NonAscii=8]="NonAscii",e[e.DocComment=16]="DocComment",e[e.Backticked=32]="Backticked"})(qt||(qt={}))});function cl(e,t="disallow-reserved"){if(LTe(e,t))return`\`${e.replace(/\\/g,"\\\\").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\t/g,"\\t").replace(/`/g,"\\`")}\``;else return e}function LTe(e,t){if(e.length===0)return!1;if(t==="allow-reserved"){if(u7.has(e))return!1;let i=Mw.get(e);if(i!==void 0&&cb(i))return!1}if(Mw.has(e))return!0;let n=e.codePointAt(0);if(!yw(n))return!0;let r=0;do r+=Jg(n);while(r{rc();ub();It()});function Ht(e,t){switch(e.kind){case"Namespace":return Vm(e,t);case"TemplateParameter":return Os(e.node.id.sv,t);case"TemplateParameterAccess":return e.path;case"Scalar":return UTe(e,t);case"Model":return m7(e,t);case"ModelProperty":return GTe(e,t);case"Interface":return y7(e,t);case"Operation":return HTe(e,t);case"Enum":return f7(e,t);case"EnumMember":return`${f7(e.enum,t)}.${Os(e.name,t)}`;case"Union":return VTe(e,t);case"UnionVariant":return Ht(e.type,t);case"Tuple":return"["+e.values.map((n)=>Ht(n,t)).join(", ")+"]";case"StringTemplate":return zTe(e);case"String":return`"${e.value}"`;case"Number":return e.valueAsString;case"Boolean":return e.value.toString();case"Intrinsic":return e.name;case"FunctionType":return qTe(e);default:return"(unnamed type)"}}function qTe(e){return`fn (${[...e.parameters].map((n)=>{let r=n.rest?"...":"",i=n.optional?"?":"";return`${r}${n.name}${i}: ${Uo(n.type)}`}).join(", ")}) => ${Uo(e.returnType)}`}function Uw(e,t){switch(e.valueKind){case"ObjectValue":return`#{${[...e.properties.entries()].map(([n,r])=>`${n}: ${Uw(r.value,t)}`).join(", ")}}`;case"ArrayValue":return`#[${e.values.map((n)=>Uw(n,t)).join(", ")}]`;case"StringValue":return`"${e.value}"`;case"BooleanValue":return`${e.value}`;case"NumericValue":return`${e.value.toString()}`;case"EnumValue":return Ht(e.value);case"NullValue":return"null";case"ScalarValue":return`${Ht(e.type,t)}.${e.value.name}(${e.value.args.map((n)=>Uw(n,t)).join(", ")}})`;case"Function":return`fn ${e.name??""}`}}function Uo(e,t){if(Sa(e))return Uw(e,t);else if(Mo(e))return Ht(e,t);else switch(e.entityKind){case"MixedParameterConstraint":return[e.type&&Uo(e.type),e.valueType&&`valueof ${Uo(e.valueType)}`].filter(Nd).join(" | ");case"Indeterminate":return Ht(e.type,t)}}function Bw(e){return e.name==="TypeSpec"&&e.namespace?.name===""||e.name==="Reflection"&&e.namespace?.name==="TypeSpec"&&e.namespace?.namespace?.name===""}function Vm(e,t){let n=t?.namespaceFilter,r=[],i=e;while(i&&i.name!==""){if(n&&!n(i))break;r.unshift(Os(i.name,t)),i=i.namespace}return r.join(".")}function qu(e,t){if(e===void 0||Bw(e)||t?.nameOnly===!0)return"";let n=Vm(e,t);return n!==""?n+".":""}function f7(e,t){return`${qu(e.namespace,t)}${Os(e.name,t)}`}function UTe(e,t){return`${qu(e.namespace,t)}${Os(e.name,t)}`}function m7(e,t){let n=qu(e.namespace,t);if(e.name===""){let i=BTe(e,t);if(i!==void 0)return i}if(e.name===""&&e.properties.size===0)return"{}";if(e.indexer&&e.indexer.key.kind==="Scalar"){if(e.name==="Array"&&JTe(e))return`${Ht(e.indexer.value,t)}[]`}if(e.name==="")return n+`{ ${[...e.properties.values()].map((i)=>`${i.name}: ${Ht(i.type,t)}`).join(", ")} }`;let r=n+Os(e.name,t);if(Lo(e)){let i=e.templateMapper.args.map((s)=>Uo(s,t));return`${r}<${i.join(", ")}>`}else if(e.node?.templateParameters?.length>0){let i=e.node.templateParameters.map((s)=>{let o=Aw(s);return Os(s.id.sv,t,o)});return`${r}<${i.join(", ")}>`}else return r}function BTe(e,t){let n=e.node;if(n?.kind!==re.ModelExpression)return;let r=n.parent;if(r?.kind!==re.OperationSignatureDeclaration||r.parameters!==n)return;let i=r.parent;if(i?.kind!==re.OperationStatement)return;let s=Os(i.id.sv,t);if(t?.nameOnly===!0)return`${s}::parameters`;let o=i.parent;return`${o?.kind===re.InterfaceStatement?`${qu(e.namespace,t)}${Os(o.id.sv,t)}.`:qu(e.namespace,t)}${s}::parameters`}function VTe(e,t){let n=e.expression?"":qu(e.namespace,t),r=e.name?Os(e.name,t):[...e.variants.values()].map((i)=>Ht(i.type,t)).join(" | ");return n+r}function KTe(e){return e.name==="TypeSpec"&&e.namespace?.name===""}function JTe(e){return Boolean(e.namespace&&KTe(e.namespace))}function GTe(e,t){if(t?.nameOnly===!0)return e.name;return`${(e.model?m7(e.model,t):void 0)??"(anonymous model)"}.${e.name}`}function y7(e,t){let n=Os(e.name,t);if(Lo(e))n+=`<${e.templateMapper.args.map((r)=>Uo(r,t)).join(", ")}>`;else if(e.node&&e.node.templateParameters.length>0){let r=e.node.templateParameters.map((i)=>{let s=Aw(i);return Os(i.id.sv,t,s)});n+=`<${r.join(", ")}>`}return`${qu(e.namespace,t)}${n}`}function HTe(e,t){let n=Os(e.name,t);if(e.node&&e.node.templateParameters.length>0){let r=e.node.templateParameters.map((i)=>Os(i.id.sv,t));n+=`<${r.join(", ")}>`}if(t?.nameOnly===!0)return n;else return`${e.interface?y7(e.interface,t)+".":qu(e.namespace,t)}${n}`}function Os(e,t,n){return n??(t?.printable?cl(e):e)}function zTe(e){if(e.stringValue)return`"${e.stringValue}"`;return"string"}var cc=q(()=>{Gt();yr();It();Rw();Lu()});function pb(e){let t=e.match(WTe);if(t==null)return;return{type:t[1],...QTe(t[2])}}function QTe(e){if(!e.includes("+"))return{subtype:e};let[t,n]=e.split("+",2);return{subtype:t,suffix:n}}var WTe;var aP=q(()=>{WTe=/^(application|audio|font|example|image|message|model|multipart|text|video|x-(?:[0-9A-Za-z!#$%&'*+.^_`|~-]+))\/([0-9A-Za-z!#$%&'*+.^_`|~-]+)$/});var Vw=()=>{};var Nn=q(()=>{Vw();Gt()});function fb(e,t){return db(e,t)!==void 0}var db,g7;var Kw=q(()=>{Nn();[db,g7]=ze(Pt("key"))});function Jw(e,t,n,r){let i=b7(e.program,t);if(i===void 0)i=new Map,ZTe(e.program,t,i);let s=pb(n);if(s===void 0)gn(e.program,{code:"invalid-mime-type",format:{mimeType:n},target:e.getArgumentTarget(0)});else if(s.suffix)gn(e.program,{code:"no-mime-type-suffix",format:{mimeType:n,suffix:s.suffix},target:e.getArgumentTarget(0)});i.set(n,r)}function eSe(e,t,n){let r=pb(n);if(r===void 0)return;let i=r?.suffix?`${r.type}/${r.suffix}`:n;return b7(e,t)?.get(i)}function mb(e,t,n){return eSe(e,t,n)??t.name}var b7,ZTe,Jpt;var Gw=q(()=>{Yn();aP();Nn();[b7,ZTe,Jpt]=ze(Pt("encodedName"))});function yb(e,t,n){let r=nSe(t,n);Bo(e,r)}function nSe(e,t={}){return{visited:new Set,emit:(n,...r)=>e[n]?.(...r),options:rSe(t)}}function rSe(e){return{...tSe,...e}}function v7(e,t){if(t.emit("namespace",e)===qr.NoRecursion)return;for(let n of e.models.values())Hw(n,t);for(let n of e.scalars.values())uP(n,t);for(let n of e.operations.values())cP(n,t);for(let n of e.namespaces.values())if(!(e.name==="TypeSpec"&&n.name==="Prototypes"))v7(n,t);for(let n of e.unions.values())D7(n,t);for(let n of e.interfaces.values())x7(n,t);for(let n of e.enums.values())w7(n,t);for(let n of e.decoratorDeclarations.values())S7(n,t);for(let n of e.functionDeclarations.values())k7(n,t);t.emit("exitNamespace",e)}function Ai(e,t){if(e.has(t))return!0;return e.add(t),!1}function zw(e,t){if(e.options.includeTemplateDeclaration)return t.isFinished||oc(t);else return t.isFinished}function cP(e,t){if(Ai(t.visited,e))return;if(!zw(t,e))return;if(t.emit("operation",e)===qr.NoRecursion)return;for(let n of e.parameters.properties.values())Bo(n,t);if(Bo(e.returnType,t),e.sourceOperation)Bo(e.sourceOperation,t);t.emit("exitOperation",e)}function Hw(e,t){if(Ai(t.visited,e))return;if(!zw(t,e))return;if(t.emit("model",e)===qr.NoRecursion)return;for(let n of e.properties.values())_7(n,t);if(e.baseModel)Hw(e.baseModel,t);if(e.indexer&&e.indexer.value)Bo(e.indexer.value,t);if(t.options.visitDerivedTypes)for(let n of e.derivedModels)Hw(n,t);t.emit("exitModel",e)}function _7(e,t){if(Ai(t.visited,e))return;if(t.emit("modelProperty",e)===qr.NoRecursion)return;Bo(e.type,t),t.emit("exitModelProperty",e)}function uP(e,t){if(Ai(t.visited,e))return;if(t.emit("scalar",e)===qr.NoRecursion)return;if(e.baseScalar)uP(e.baseScalar,t);for(let n of e.constructors.values())E7(n,t);t.emit("exitScalar",e)}function x7(e,t){if(Ai(t.visited,e))return;if(!zw(t,e))return;t.emit("interface",e);for(let n of e.operations.values())cP(n,t);t.emit("exitInterface",e)}function w7(e,t){if(Ai(t.visited,e))return;t.emit("enum",e);for(let n of e.members.values())Bo(n,t);t.emit("exitEnum",e)}function D7(e,t){if(Ai(t.visited,e))return;if(!zw(t,e))return;if(t.emit("union",e)===qr.NoRecursion)return;if(e.baseType)Bo(e.baseType,t);for(let n of e.variants.values())T7(n,t);t.emit("exitUnion",e)}function T7(e,t){if(Ai(t.visited,e))return;if(t.emit("unionVariant",e)===qr.NoRecursion)return;Bo(e.type,t),t.emit("exitUnionVariant",e)}function iSe(e,t){if(Ai(t.visited,e))return;if(t.emit("tuple",e)===qr.NoRecursion)return;for(let n of e.values)Bo(n,t);t.emit("exitTuple",e)}function sSe(e,t){if(Ai(t.visited,e))return;if(t.emit("stringTemplate",e)===qr.NoRecursion)return;for(let n of e.spans)Bo(n,t)}function oSe(e,t){if(Ai(t.visited,e))return;if(t.emit("stringTemplateSpan",e)===qr.NoRecursion)return;Bo(e.type,t)}function aSe(e,t){if(Ai(t.visited,e))return;if(t.emit("templateParameter",e)===qr.NoRecursion)return;t.emit("exitTemplateParameter",e)}function lSe(e,t){if(Ai(t.visited,e))return;if(t.emit("templateParameterAccess",e)===qr.NoRecursion)return;t.emit("exitTemplateParameterAccess",e)}function S7(e,t){if(Ai(t.visited,e))return;if(t.emit("decorator",e)===qr.NoRecursion)return}function E7(e,t){if(Ai(t.visited,e))return;if(t.emit("scalarConstructor",e)===qr.NoRecursion)return}function k7(e,t){if(Ai(t.visited,e))return;if(t.emit("function",e)===qr.NoRecursion)return}function Bo(e,t){if(e.entityKind==="Type")switch(e.kind){case"Model":return Hw(e,t);case"Scalar":return uP(e,t);case"ModelProperty":return _7(e,t);case"Namespace":return v7(e,t);case"Interface":return x7(e,t);case"Enum":return w7(e,t);case"Operation":return cP(e,t);case"Union":return D7(e,t);case"UnionVariant":return T7(e,t);case"Tuple":return iSe(e,t);case"StringTemplate":return sSe(e,t);case"StringTemplateSpan":return oSe(e,t);case"TemplateParameter":return aSe(e,t);case"TemplateParameterAccess":return lSe(e,t);case"Decorator":return S7(e,t);case"ScalarConstructor":return E7(e,t);case"FunctionParameter":case"FunctionType":case"Boolean":case"EnumMember":case"Intrinsic":case"Number":case"String":return;default:let n=e;return}else{if(e.valueKind==="Function")return k7(e,t);return}}function Fd(e,t){while(e.baseModel){if(e.properties.has(t))return e.properties.get(t);e=e.baseModel}return e.properties.get(t)}var tSe;var hb=q(()=>{yr();It();tSe={includeTemplateDeclaration:!1}});var pP=q(()=>{_t();hb();yr();ul()});function O7(e,t,n,r){let i=Ct(),s=r==="input"?bSe:vSe,o=new Qs,a={};gb(n,(l,c)=>{let u=i.pipe(_Se(e,l));if(u===void 0)return;if(o.track(u,l),s.has(u))a[u]={property:l,path:c};else i.add(tn({code:"invalid-paging-prop",messageId:r==="input"?"input":"output",format:{kind:u},target:l}))});for(let[l,c]of o.entries())for(let u of c)i.add(tn({code:"duplicate-paging-prop",format:{kind:l,operationName:t.name},target:u}));return i.wrap(a)}function Ww(e,t){let n=Ct(),r={input:n.pipe(O7(e,t,t.parameters,"input")),output:n.pipe(O7(e,t,t.returnType,"output"))};if(r.output.pageItems===void 0)return n.add(tn({code:"missing-paging-items",format:{operationName:t.name},target:t})),n.wrap(void 0);return n.wrap(r)}function gb(e,t,n=[],r=new Set){if(r.has(e))return;switch(r.add(e),e.kind){case"Model":for(let i of e.properties.values())t(i,[...n,i]),gb(i.type,t,[...n,i],r);if(e.baseModel)gb(e.baseModel,t,n,r);break;case"Union":for(let i of e.variants.values())gb(i,t,n,r);break;case"UnionVariant":gb(e.type,t,n,r);break}}function _Se(e,t){let n=[],r={offset:cSe(e,t),pageIndex:uSe(e,t),pageItems:dSe(e,t),pageSize:pSe(e,t),continuationToken:fSe(e,t),nextLink:mSe(e,t),prevLink:ySe(e,t),lastLink:gSe(e,t),firstLink:hSe(e,t)},i=Object.entries(r).filter((s)=>!!s[1]);if(i.length>1)n.push(tn({code:"incompatible-paging-props",format:{kinds:i.map((s)=>s[0]).join(", ")},target:t}));if(i.length===0)return[void 0,n];return[i[0][0],n]}function pl(e,t){let[n,r]=hr(Pt(e));return[n,r,(...s)=>{if(t&&!t(...s))return;let[o,a]=s;r(o.program,a)}]}function dP(e){return(t,n)=>{if(!Qw(t.program,n.type))return gn(t.program,{code:"decorator-wrong-target",messageId:"withExpected",format:{decorator:e,expected:"numeric",to:Ht(n.type)},target:t.decoratorTarget}),!1;return!0}}var P7,cdt,$7,cSe,udt,I7,uSe,pdt,A7,pSe,ddt,R7,dSe,fdt,j7,fSe,mdt,F7,mSe,ydt,C7,ySe,hdt,M7,hSe,gdt,L7,gSe,bdt,q7,bSe,vSe;var vb=q(()=>{_t();cc();Yn();hb();yr();Nn();ul();[P7,cdt,$7]=pl("list"),[cSe,udt,I7]=pl("offset",dP("offset")),[uSe,pdt,A7]=pl("pageIndex",dP("pageIndex")),[pSe,ddt,R7]=pl("pageSize",dP("pageSize")),[dSe,fdt,j7]=pl("pageItems",(e,t)=>{if(t.type.kind!=="Model"||!Ns(t.type))return gn(e.program,{code:"decorator-wrong-target",messageId:"withExpected",format:{decorator:"continuationToken",expected:"Array",to:Ht(t.type)},target:e.decoratorTarget}),!1;return!0}),[fSe,mdt,F7]=pl("continuationToken"),[mSe,ydt,C7]=pl("nextLink"),[ySe,hdt,M7]=pl("prevLink"),[hSe,gdt,L7]=pl("firstLink"),[gSe,bdt,q7]=pl("lastLink"),bSe=new Set(["offset","pageIndex","pageSize","continuationToken"]),vSe=new Set(["pageItems","nextLink","prevLink","firstLink","lastLink","continuationToken"])});function B7(e,t,n={}){let i=wSe(e).get(t)??{};xSe(e,t,{...i,...n,type:t})}var U7,xSe,wSe,Yw=(e,t,n)=>{bn(e,t,Yw),B7(e.program,t,n)};var V7=q(()=>{$d();Id();Nn();[U7,xSe,wSe]=ze(Symbol.for("@typespec/compiler.services"))});function K7(...e){return fP(...e)}function J7(e,t){let n=fP(e,t);if(!n)n=new Map,DSe(e,t,n);return n}function mP(e,t,n,r){let i=J7(e,t),s=i.get(n);if(!s)s=r,i.set(n,s);return s}function z7(e,t){let n=G7(e,t);if(n)return new Set(n);let r=new Set(t.members.values());return H7(e,t,r),new Set(r)}function W7(e,t,n){Qe(!G7(e,t),"The default modifier set for a visibility class may only be set once."),H7(e,t,n)}function Q7(e){let t=new Map;for(let n of e){let r=n.enum,i=t.get(r);if(!i)i=new Set,t.set(r,i);i.add(n)}return t}function Km(e,t,n){if(TSe.has(e))return!0;return(n?ESe(e,t)?.has(n):!1)||SSe(e,t)}function Xw(e,t,n,r){let i=Q7(n);for(let[s,o]of i.entries()){let a=r?.decoratorTarget??t;if(Km(e,t,s)){gn(e,{code:"visibility-sealed",format:{propName:t.name},target:a});continue}let l=mP(e,t,s,new Set);for(let c of o)l.add(c)}}function Zw(e,t,n,r){let i=Q7(n);for(let[s,o]of i.entries()){let a=r?.decoratorTarget??t;if(Km(e,t,s)){gn(e,{code:"visibility-sealed",format:{propName:t.name},target:a});continue}let l=mP(e,t,s,z7(e,s));for(let c of o)l.delete(c)}}function eD(e,t,n,r){let i=r?.decoratorTarget??t;if(Km(e,t,n)){gn(e,{code:"visibility-sealed",format:{propName:t.name},target:i});return}mP(e,t,n,new Set).clear()}function Jm(e,t,n,r){let i=r?.decoratorTarget??t;if(Km(e,t,n)){gn(e,{code:"visibility-sealed",format:{propName:t.name},target:i});return}J7(e,t).delete(n)}function Gm(e,t,n){return fP(e,t)?.get(n)??z7(e,n)}function _b(e,t,n){let r=n.enum;return Gm(e,t,r).has(n)??!1}function OSe(e,t){let n=e[NSe]??={idx:0,map:new WeakMap},r=n.map.get(t);if(r===void 0)r=n.idx++,n.map.set(t,r);return r}function $Se(e,t){let n=e[PSe]??=new WeakMap,r=n.get(t);if(r)return r;r="{";for(let[i,s]of Object.entries(t).sort(([o],[a])=>o.localeCompare(a))){if(!s)continue;r+=`${i}:[`;let o=[];for(let a of s){let l=OSe(e,a.enum);o.push({_enum:l,modifier:a.name})}r+=o.sort(function(l,c){if(l._enum!==c._enum)return l._enum-c._enum;return l.modifier.localeCompare(c.modifier)}).join(",")+"]"}return r+="}",n.set(t,r),r}function pc(e,t,n){if(n.all){for(let r of n.all)if(!_b(e,t,r))return!1}if(n.none){for(let r of n.none)if(_b(e,t,r))return!1}if(n.any){for(let r of n.any)if(_b(e,t,r))return!0;return!1}return!0}var fP,DSe,TSe,SSe,Ndt,ESe,Odt,G7,H7,kSe,Hm,NSe,PSe;var tD=q(()=>{_t();Yn();Nn();[fP,DSe]=ze(Pt("visibilityStore"));TSe=new WeakSet,[SSe,Ndt]=hr(Pt("propertyVisibilitySealed")),[ESe,Odt]=ze(Pt("sealedVisibilityClasses")),[G7,H7]=ze(Pt("defaultVisibilityModifiers"));kSe=Symbol.for("TypeSpec.Core.VisibilityFilter"),Hm={fromDecoratorArgument(e){return e[kSe]??={all:e.all&&new Set(e.all.map((t)=>t.value)),any:e.any&&new Set(e.any.map((t)=>t.value)),none:e.none&&new Set(e.none.map((t)=>t.value))}},getVisibilityClasses(e){let t=new Set;if(e.all)e.all.forEach((n)=>t.add(n.enum));if(e.any)e.any.forEach((n)=>t.add(n.enum));if(e.none)e.none.forEach((n)=>t.add(n.enum));return t},toCacheKey(e,t){return $Se(e,t)}},NSe=Symbol.for("TypeSpec.Core.enumInternTable");PSe=Symbol.for("TypeSpec.Core.visibilityFilterToStringCache")});function Ea(e){let t=Y7.get(e);if(t)return t;let[n,r]=e.resolveTypeReference("TypeSpec.Lifecycle");return Qe(r.length===0,"Encountered diagnostics when resolving the `TypeSpec.Lifecycle` visibility class enum"),Qe(n.kind==="Enum","Expected `TypeSpec.Visibility.Lifecycle` to be an enum"),Y7.set(e,n),n}var Y7;var yP=q(()=>{_t();Y7=new WeakMap});class xb{#e=new Map;#t;constructor(e){this.#t=e}get(e){return this.#e.get(this.#t(e))}set(e,t){let n=this.#t(e);this.#e.set(n,t)}static objectKeyer(){let e=new WeakMap,t=0;return{getKey(n){if(e.has(n))return e.get(n);let r=t;return t++,e.set(n,r),r}}}}function ISe(e){switch(e.kind){case"TemplateParameter":case"Intrinsic":case"Decorator":case"FunctionParameter":return!1;default:return!0}}function jSe(e){let t=X7.get(e);if(t===void 0)t=new xb(([n,r])=>`${ASe.getKey(n)}-${[...r.values()].map((s)=>RSe.getKey(s)).join("-")}`),X7.set(e,t);return t}function nD(e,t,n){let r=MSe(e,t,{mutateNamespaces:!1}),i=r.mutate(n);if(i===n)return{realm:null,type:n};return{realm:r.realm,type:i}}function wb(e,t,n=!0){CSe(e,t,n)}function MSe(e,t,n){let r=new Ws(e,`Mutator realm ${t.map((v)=>v.name).join(", ")}`),i=[],s=jSe(e),o=!1,a=new Set(t),l=[],c=new Set;if(n.mutateNamespaces)o=!0,d(e.getGlobalNamespaceType(),a),o=!1,l.forEach((v)=>v());return{realm:r,mutate:(v)=>d(v,a)};function u(v,D){let T=[],N=new Set(v.values());for(let O of v){let C=O[D.kind];if(!C)continue;let X,te=null,L,Y;if(typeof C==="function")X=C,L=!0,Y=!0;else if(X="mutate"in C?C.mutate:null,te="replace"in C?C.replace:null,C.filter){let me=C.filter(D,e,r);if(me===!0)L=!0,Y=!0;else if(me===!1)L=!1,Y=!0;else L=(me&Ys.DoNotMutate)===0,Y=(me&Ys.DoNotRecur)===0}else L=!0,Y=!0;if(!Y)N.delete(O);if(L)T.push({mutator:O,mutationFn:X,replaceFn:te})}return{mutatorsWithOptions:T,newMutators:N}}function p(v,D,T){let N=D;for(let{mutationFn:O,replaceFn:C}of T){let X=(O??C)(v,N,e,r);if(C&&X!==void 0)N=X}return N}function d(v,D,T=!0){let N=s.get([v,D]);if(N){if(T&&N.kind==="Namespace"&&!c.has(N))c.add(N),b(N,"namespaces",!0,D);return Z(),N}if(!FSe(e,v)&&Co(e,v).type==="compiler"&&!Lo(v))return v;let C=null,{mutatorsWithOptions:X,newMutators:te}=u(D,v),L=X.map((ue)=>ue.mutator),Y=!1;if(X.length===0)if(te.size>0)return i.push(I),s.set([v,D],v),J(),_e(),i.pop(),C??v;else return v;if(Z(),N=s.get([v,L]),N)return N;I();let me=p(v,C,X);if(me!==C)C=me,s.set([v,D],C),s.set([v,L],C);if(te.size>0)if(o&&v.kind==="Namespace")Qe(Y,"Cannot be preparing namespaces and not have cloned it."),de(C),l.push(()=>be(C));else J();if(v.isFinished)Kn(r).type.finishType(C);if(v.kind==="Namespace"&&T)Qe(Y,"Cannot be preparing namespaces and not have cloned it."),je(C);if(v.kind!=="Namespace")_e();return C;function I(){C=Kn(r).type.clone(v),Y=!0,s.set([v,D],C),s.set([v,L],C)}function Z(){for(let ue of i)ue();i.length=0}function pe(ue){if(!n.mutateNamespaces)return;if("namespace"in ue&&ue.namespace){let ce=d(ue.namespace,te,!1);Qe(ce.kind==="Namespace","Expected to be mutated to a namespace"),C.namespace=ce}}function de(ue){f(ue,!0,te),pe(ue)}function je(ue){c.add(ue),b(ue,"namespaces",!0,te)}function be(ue){b(ue,"models",Y,te),b(ue,"operations",Y,te),b(ue,"interfaces",Y,te),b(ue,"enums",Y,te),b(ue,"unions",Y,te),b(ue,"scalars",Y,te)}function Ie(ue){if(b(ue,"properties",Y,te),ue.indexer){let ce=d(ue.indexer.value,te);if(Y)ue.indexer.value=ce}for(let[ce,Le]of ue.sourceModels.entries()){let Ke=d(Le.model,te);if(Y)Tn(ue.sourceModels[ce]).model=Ke}x(ue,"sourceModel",Y,te),x(ue,"baseModel",Y,te),g(ue,"derivedModels",Y,te)}function J(){let ue=C??v;switch(ue.kind){case"Namespace":be(ue);break;case"Model":Ie(ue);break;case"ModelProperty":x(ue,"type",Y,te),x(ue,"sourceProperty",Y,te);break;case"Tuple":g(ue,"values",Y,te);break;case"Operation":x(ue,"parameters",Y,te),x(ue,"returnType",Y,te),x(ue,"sourceOperation",Y,te);break;case"Interface":b(ue,"operations",Y,te);break;case"Enum":b(ue,"members",Y,te);break;case"EnumMember":break;case"Union":b(ue,"variants",Y,te),x(ue,"baseType",Y,te);break;case"UnionVariant":x(ue,"type",Y,te);break;case"Scalar":b(ue,"constructors",Y,te),x(ue,"baseScalar",Y,te),g(ue,"derivedScalars",Y,te);break;case"ScalarConstructor":x(ue,"scalar",Y,te);break}if("templateMapper"in ue)h(ue,Y,te);if("decorators"in ue)f(ue,Y,te);pe(ue)}function _e(){let ue=C??v;switch(ue.kind){case"ModelProperty":x(ue,"model",Y,te);break;case"Operation":x(ue,"interface",Y,te);break;case"EnumMember":x(ue,"enum",Y,te);break;case"UnionVariant":x(ue,"union",Y,te);break;case"ScalarConstructor":x(ue,"scalar",Y,te);break}}}function f(v,D,T){for(let[N,O]of v.decorators.entries()){let C=[];for(let X of O.args)C.push({...X,value:m(X.value,T),jsValue:m(X.jsValue,T)});if(D)v.decorators[N]={...O,args:C}}}function m(v,D){if(typeof v==="object"&&v!==null){if(Mo(v))return ISe(v)?d(v,D):v;if(Sa(v))return y(v,D);if(qo(v))return v;if(Array.isArray(v))return v.map((T)=>m(T,D));return Object.entries(v).reduce((T,[N,O])=>({...T,[N]:m(O,D)}),{})}return v}function y(v,D){switch(v.valueKind){case"ObjectValue":let T={...v,properties:new Map,type:m(v.type,D)};for(let[N,O]of v.properties.entries())T.properties.set(N,{...O,value:y(O.value,D)});return T;case"ArrayValue":return{...v,type:m(v.type,D),values:v.values.map((N)=>y(N,D))};case"EnumValue":return{...v,type:m(v.type,D),value:m(v.value,D)};default:return v}}function h(v,D,T){if(v.templateMapper===void 0)return;let N={...v.templateMapper,args:[],map:new Map};for(let O of v.templateMapper.args)Tn(N.args).push(d(O,T));for(let[O,C]of v.templateMapper.map)N.map.set(O,d(C,T));if(D)v.templateMapper=N}function b(v,D,T,N){for(let[O,C]of v[D].entries()){let X=d(C,N);if(T){if(v[D].set(O,X),X.name!==C.name)v[D].rekey(O,X.name)}}}function g(v,D,T,N){for(let[O,C]of v[D].entries()){let X=d(C,N);if(T)v[D][O]=X}}function x(v,D,T,N){if(v[D]===void 0)return;let O=d(v[D],N);if(T)v[D]=O}}var Ys,ASe,RSe,X7,FSe,CSe;var hP=q(()=>{_t();ic();ac();yr();ka();Gt();Id();(function(e){e[e.MutateAndRecur=0]="MutateAndRecur",e[e.DoNotMutate=1]="DoNotMutate",e[e.DoNotRecur=2]="DoNotRecur"})(Ys||(Ys={}));ASe=xb.objectKeyer(),RSe=xb.objectKeyer(),X7=new WeakMap;[FSe,CSe]=ze(Symbol.for("TypeSpec.Mutators.alwaysMutate"))});function vP(e,t){let n=LSe(e,t);if(!n)n={},qSe(e,t,n);return n}function _P(e,t,n){let r=vP(e,t);if(!r.parameters)return n.parameters(e,t);return Qe(r.parameters.length!==0,"Empty parameter visibility constraint."),{any:new Set(r.parameters)}}function TP(e,t,n,r){let i=Hm.fromDecoratorArgument(n),s=e.program[e5]??={},o=s.byNameTemplate??={},a=r===void 0?s.unnamed??={}:o[r]??={},l=a.byVisibilityFilter??=new Map,c=Hm.toCacheKey(e.program,i),u=l.get(c);if(!u)u=gP(i,{decoratorFn:iD,decoratorName:"@withVisibilityFilter",nameTemplate:r}),l.set(c,u);wb(e.program,t);let{type:p}=dc(e.program,u,t);return wb(e.program,t,!1),Qe(p.kind==="Model","Expected visibility filter mutator to return a Model type."),p}function SP(e,t,n){let r=e.program[e5]??={},i=r.byNameTemplate??={},s=n===void 0?r.unnamed??={}:i[n]??={},o=s.lifecycleUpdate;if(!o){let l=Ea(e.program),c={all:new Set([l.members.get("Update")])},u={any:new Set([l.members.get("Create"),l.members.get("Update")])},p=gP(u,{nameTemplate:n});o=gP(c,{recur:p,decoratorFn:sD,decoratorName:"@withLifecycleUpdate",nameTemplate:n}),s.lifecycleUpdate=o}wb(e.program,t);let{type:a}=dc(e.program,o,t);return wb(e.program,t,!1),Qe(a.kind==="Model","Expected lifecycle update mutator to return a Model type."),a}function dc(e,t,n){let r=t[USe]??=new WeakMap,i=r.get(n);if(i)return i;let s=nD(e,[t],n);return r.set(n,s),s}function gP(e,t={}){let n=Hm.getVisibilityClasses(e),r=(a,l)=>a.definition?.name===l&&a.definition.namespace.name==="TypeSpec",i=(a,l,c)=>r(a,l)||a.decorator===c,s={name:"VisibilityFilterProperty",ModelProperty:{filter:()=>Ys.DoNotRecur,replace:(a,l,c)=>{let u=!1,p=[];for(let d of a.decorators)if(i(d,"@visibility",Cd)||i(d,"@removeVisibility",Wm)){let f=d.args.filter((m)=>{if(m.value.entityKind!=="Value")return!1;let y=m.value.valueKind==="StringValue",h=m.value.valueKind==="EnumValue"&&n.has(m.value.value.enum);return!(y||h)});if(u||=f.length!==d.args.length,f.length>0)p.push({...d,args:f})}else if(!i(d,"@invisible",Qm))p.push(d);l.decorators=p,u||=p.length!==a.decorators.length;for(let d of n)Jm(c,l,d);if(zm(a.type))l.type=dc(c,t.recur??o,a.type).type,u||=l.type!==a.type;return u?l:a}}},o={name:"VisibilityFilter",Union:{filter:()=>Ys.DoNotRecur,replace:(a,l,c)=>{let u=!1;for(let[p,d]of a.variants)if(zm(d.type)){let f={...d,type:dc(c,o,d.type).type};l.variants.set(p,f),u||=f.type!==d.type}return Z7(l,t.nameTemplate),u?l:a}},Model:{filter:()=>Ys.DoNotRecur,replace:(a,l,c,u)=>{let p=!1;if(a.indexer&&zm(a.indexer.value)){if(l.indexer={...a.indexer},Tn(l.indexer).value=dc(c,t.recur??o,a.indexer.value).type,Kn(u).array.is(a)&&l.name==="Array"&&l.indexer.value!==a.indexer.value)return Kn(c).array.create(l.indexer.value);if(Kn(u).record.is(a)&&l.name==="Record"&&l.indexer.value!==a.indexer.value)return Kn(c).record.create(l.indexer.value);p||=l.indexer.value!==a.indexer.value}for(let[d,f]of a.properties)if(!pc(c,f,e))l.properties.delete(d),u.remove(l),p=!0;else{let m=dc(c,s,f);l.properties.set(d,m.type),p||=m.type!==f}if(t.decoratorFn)l.decorators=l.decorators.filter((d)=>!(d.decorator===t.decoratorFn||t.decoratorName&&r(d,t.decoratorName))),p||=l.decorators.length!==a.decorators.length;return Z7(l,t.nameTemplate),p?l:a}},ModelProperty:{filter:()=>Ys.DoNotRecur,replace:(a,l,c)=>{if(zm(a.type))l.type=dc(c,o,a.type).type;return l.type!==a.type?l:a}},UnionVariant:{filter:()=>Ys.DoNotRecur,replace:(a,l,c)=>{if(zm(a.type))l.type=dc(c,o,a.type).type;return l.type!==a.type?l:a}},Tuple:{filter:()=>Ys.DoNotRecur,replace:(a,l,c)=>{let u=!1;for(let[p,d]of a.values.entries())if(zm(d))l.values[p]=dc(c,o,d).type,u||=l.values[p]!==d;return u?l:a}}};return o}function Z7(e,t){if(!t||!e.name)return;let n=Rm(t,e);e.name=n}function zm(e){return e.kind==="Model"||e.kind==="Union"||e.kind==="ModelProperty"||e.kind==="UnionVariant"||e.kind==="Tuple"}var bP=(e,t,n)=>{let r=[...t.properties].filter(([i,s])=>fb(e.program,s)&&!K7(e.program,s));for(let[i,s]of r)t.properties.set(i,e.program.checker.cloneType(s,{decorators:[...s.decorators,{decorator:Cd,args:[{value:n,jsValue:n}]}]}))},LSe,qSe,Db=(e,t,...n)=>{if(bn(e,t,Db),n.length===0){gn(e.program,{code:"operation-visibility-constraint-empty",messageId:"parameter",target:e.decoratorTarget});return}vP(e.program,t).parameters=n.map((r)=>r.value)},xP=(e,t,...n)=>{if(bn(e,t,Db),n.length===0){gn(e.program,{code:"operation-visibility-constraint-empty",messageId:"returnType",target:e.decoratorTarget});return}vP(e.program,t).returnType=n.map((r)=>r.value)},Cd=(e,t,...n)=>{Xw(e.program,t,n.map((r)=>r.value),e)},Wm=(e,t,...n)=>{Zw(e.program,t,n.map((r)=>r.value))},Qm=(e,t,n)=>{eD(e.program,t,n)},rD=(e,t,...n)=>{bn(e,t,rD);let r=new Set;for(let i of n)if(i.value.enum!==t)gn(e.program,{code:"default-visibility-not-member",target:e.decoratorTarget});else r.add(i.value);W7(e.program,t,r)},wP=(e,t,...n)=>{let r=n.map((o)=>o.value),i={all:new Set(r)},s=new Set(r.map((o)=>o.enum));Am(t,(o)=>pc(e.program,o,i));for(let o of t.properties.values())for(let a of s)Jm(e.program,o,a)},DP=(e,t)=>{if(!j9(e,t,"@withUpdateableProperties","Model"))return;let n={all:new Set([Ea(e.program).members.get("Update")])};Am(t,(r)=>pc(e.program,r,n))},e5,iD=(e,t,n,r)=>{let i=TP(e,t,n,r);t.properties=i.properties},sD=(e,t,n)=>{let r=SP(e,t,n);t.properties=r.properties},USe;var EP=q(()=>{$d();_t();Yn();tD();yP();hP();ka();Nn();Gt();Kw();[LSe,qSe]=ze(Pt("operationVisibilityConfig"));e5=Symbol.for("TypeSpec.Core.visibilityFilterMutatorCache");USe=Symbol.for("TypeSpec.Core.visibilityFilterMutatorResult")});function ei(e,t){return $w(e,t,"self")?.value}function $P(e,t){return $w(e,t,"returns")?.value}function AP(e,t){return $w(e,t,"errors")?.value}function FP(e,t){let n=e.checker.getStdType("string");return t.kind==="Scalar"&&e.checker.isTypeAssignableTo(t,n,t)[0]}function Qw(e,t){let n=e.checker.getStdType("numeric");return t.kind==="Scalar"&&e.checker.isTypeAssignableTo(t,n,t)[0]}function VSe(e,t){if(t.kind!=="Scalar")return!1;return["utcDateTime","offsetDateTime","plainDate","plainTime","duration"].some((r)=>{let i=e.checker.getStdType(r);return e.checker.isTypeAssignableTo(t,i,t)[0]})}function aD(e,t){if(e.kind==="Union")return[...e.variants.values()].some((n)=>t(n.type));return t(e)}function lD(e,t,n){let r=aD($m(t),(i)=>Qw(e.program,i)||VSe(e.program,i));if(!r)gn(e.program,{code:"decorator-wrong-target",format:{decorator:n,to:"type it must be a numeric or comparable type"},target:e.decoratorTarget});return r}function cD(e,t,n){let r=$m(t);if(qo(n))n=Kn(e.program).value.createNumeric(n);let[i,s]=Kn(e.program).value.isOfType.withDiagnostics(n,r,e.getArgumentTarget(0));if(!i)e.program.reportDiagnostics(s);return i}function uD(e,t,n){let r=$m(t),i=aD(r,(s)=>FP(e.program,s));if(!i)gn(e.program,{code:"decorator-wrong-target",format:{decorator:n,to:r.kind==="Union"?'a union type that is not string compatible. The union must explicitly include a string type, and all union values should be strings. For example: union Test { string, "A", "B" }':"type it is not a string"},target:e.decoratorTarget});return i}function KSe(e){if(e.kind==="ModelProperty")return e.type;else return e.kind==="Model"?e:e.type}function t5(e,t,n){let r=KSe(t),i=aD(r,(s)=>s.kind==="Model"&&Ns(s));if(!i)gn(e.program,{code:"decorator-wrong-target",format:{decorator:n,to:"non Array type"},target:e.decoratorTarget});return i}function fc(e,t){if(t.kind!=="Model")return!1;let n=t;while(n){if(JSe(e,n))return!0;n=n.baseModel}return!1}function dD(e,t){switch(t.kind){case"Scalar":if(t.name==="string"&&t.namespace?.name==="TypeSpec"&&t.namespace.namespace===e.getGlobalNamespaceType())return"text/plain";case"Union":case"Enum":case"Model":{let r=HSe(e,t);if(!r){let i=t.kind==="Model"?t.baseModel:t.kind==="Scalar"?t.baseScalar:void 0;if(i)return dD(e,i)}return r}default:return}}function tEe(e,t,n){let r=e.checker.getStdType("string"),i=n??r;if(typeof t==="string")return{encoding:t,type:i};else if(Sa(t)){let s=t.value;if(s.value&&typeof s.value==="string")return{encoding:s.value,type:i};else return{encoding:Ht(s),type:i}}else{if(t!==r){gn(e,{code:"invalid-encode",messageId:"firstArg",target:t});return}return{type:t}}}function nEe(e,t,n){function r(i,s){let o=e.program.checker;if(!aD(t,(c)=>i.some((u)=>Ss(o.isTypeAssignableTo(c,o.getStdType(u),t)))))gn(e.program,{code:"invalid-encode",messageId:"wrongType",format:{encoding:n.encoding??"string",type:Ht(t),expected:i.join(", ")},target:e.decoratorTarget});if(!s.some((c)=>Ss(o.isTypeAssignableTo(n.type,o.getStdType(c),t)))){let c=Ht(n.type);gn(e.program,{code:"invalid-encode",messageId:["unixTimestamp","seconds","milliseconds"].includes(n.encoding??"string")?"wrongNumericEncodingType":"wrongEncodingType",format:{encoding:n.encoding,type:Ht(t),expected:s.join(", "),actual:c},target:e.decoratorTarget})}}switch(n.encoding){case"rfc3339":return r(["utcDateTime","offsetDateTime"],["string"]);case"rfc7231":return r(["utcDateTime","offsetDateTime"],["string"]);case"unixTimestamp":return r(["utcDateTime"],["integer"]);case"seconds":return r(["duration"],["numeric"]);case"milliseconds":return r(["duration"],["numeric"]);case"base64":return r(["bytes"],["string"]);case"base64url":return r(["bytes"],["string"]);case void 0:return r(["numeric","boolean"],["string"])}}function lEe(e,t){if(e.interface||t.interface)return e.interface===t.interface||e.interface?.node!==void 0&&e.interface?.node===t.interface?.node;return e.namespace===t.namespace||e.namespace?.node!==void 0&&e.namespace?.node===t.namespace?.node}function Uu(e,t,n){if(t===void 0||n===void 0)return!0;if(!qo(t)||!qo(n))return!0;if(t.gt(n))return gn(e.program,{code:"invalid-range",format:{start:t.toString(),end:n.toString()},target:e.decoratorTarget}),!1;return!0}function kP(e,t,n,r){let i=e.checker.getValueExactType(t),[s,o]=e.checker.isTypeAssignableTo(i??t.type,n,r);if(!s)e.reportDiagnostics(o);return s}var Tb,BSe,OP=(e,t,n,r)=>{if(r)n=Rm(n,r);BSe(e.program,t,n)},Xs=(e,t,n,r)=>{if(bn(e,t,Xs),r)n=Rm(n,r);Um(e.program,t,"self",{value:n,source:"decorator"})},PP=(e,t,n)=>{bn(e,t,Xs),Um(e.program,t,"returns",{value:n,source:"decorator"})},IP=(e,t,n)=>{bn(e,t,Xs),Um(e.program,t,"errors",{value:n,source:"decorator"})},RP=(e,t,n)=>{if(n)console.log(n);console.dir(t,{depth:3})},jP=(e,t,n)=>{if(n)console.log(n);console.log(Ht(t))},JSe,GSe,pD=(e,t)=>{bn(e,t,pD),GSe(e.program,t)},HSe,zSe,CP=(e,t,n)=>{if(bn(e,t,CP),pb(n)===void 0)gn(e.program,{code:"invalid-mime-type",format:{mimeType:n},target:e.getArgumentTarget(0)});zSe(e.program,t,n)},Md,WSe,fD=(e,t,n)=>{if(bn(e,t,fD),!uD(e,t,"@format"))return;WSe(e.program,t,n)},QSe,YSe,mD=(e,t,n,r)=>{if(bn(e,t,mD),!uD(e,t,"@pattern"))return;try{new RegExp(n)}catch(s){gn(e.program,{code:"invalid-pattern-regex",target:t})}let i={pattern:n,validationMessage:r};YSe(e.program,t,i)},yD=(e,t,n)=>{if(bn(e,t,yD),!uD(e,t,"@minLength")||!Uu(e,n,Nw(e.program,t)))return;z9(e.program,t,n)},hD=(e,t,n)=>{if(bn(e,t,hD),!uD(e,t,"@maxLength")||!Uu(e,kw(e.program,t),n))return;W9(e.program,t,n)},gD=(e,t,n)=>{if(bn(e,t,gD),!t5(e,t,"@minItems"))return;if(!Uu(e,n,Pw(e.program,t)))return;Q9(e.program,t,n)},bD=(e,t,n)=>{if(bn(e,t,bD),!t5(e,t,"@maxItems"))return;if(!Uu(e,Ow(e.program,t),n))return;Y9(e.program,t,n)},Ym=(e,t,n)=>{bn(e,t,Ym),Pm(e,t,Zm,Ym);let{program:r}=e;if(!lD(e,t,"@minValue"))return;if(!cD(e,t,n))return;if(!Uu(e,n,Cm(e.program,t)??qm(e.program,t)))return;K9(r,t,n)},Xm=(e,t,n)=>{bn(e,t,Xm),Pm(e,t,ey,Xm);let{program:r}=e;if(!lD(e,t,"@maxValue"))return;if(!cD(e,t,n))return;if(!Uu(e,jm(e.program,t)??Lm(e.program,t),n))return;J9(r,t,n)},Zm=(e,t,n)=>{bn(e,t,Zm),Pm(e,t,Ym,Zm);let{program:r}=e;if(!lD(e,t,"@minValueExclusive"))return;if(!cD(e,t,n))return;if(!Uu(e,n,Cm(e.program,t)??qm(e.program,t)))return;G9(r,t,n)},ey=(e,t,n)=>{bn(e,t,ey),Pm(e,t,Xm,ey);let{program:r}=e;if(!lD(e,t,"@maxValueExclusive"))return;if(!cD(e,t,n))return;if(!Uu(e,jm(e.program,t)??Lm(e.program,t),n))return;H9(r,t,n)},XSe,ZSe,vD=(e,t)=>{bn(e,t,vD),ZSe(e.program,t)},uc,eEe,_D=(e,t,n,r)=>{bn(e,t,_D);let i=tEe(e.program,n,r);if(i===void 0)return;let s=$m(t);nEe(e,s,i),eEe(e.program,t,i)},MP=(e,t)=>{t.properties.forEach((n)=>n.optional=!0)},LP=(e,t,n)=>{let r=new Set;if(n.kind==="String")r.add(n.value);else if(n.kind==="Union"){for(let i of n.variants.values())if(i.type.kind==="String")r.add(i.type.value)}Am(t,(i)=>!r.has(i.name))},qP=(e,t,n)=>{let r=new Set;if(n.kind==="String")r.add(n.value);else if(n.kind==="Union"){for(let i of n.variants.values())if(i.type.kind==="String")r.add(i.type.value)}Am(t,(i)=>r.has(i.name))},UP=(e,t)=>{t.properties.forEach((n)=>{delete n.defaultValue})},rEe,iEe,BP=(e,t,n)=>{let r=rEe(e.program,t);if(r)r.push(n);else iEe(e.program,t,[n])},VP,sEe,KP=(e,t,n,r)=>{if(t.kind==="Model"||t.kind==="Operation"){if(e.decoratorTarget.kind===re.AugmentDecoratorStatement){if(Ss(e.program.checker.resolveTypeReference(e.decoratorTarget.targetType))?.node!==t.node)return}if(e.decoratorTarget.kind===re.DecoratorExpression){if(e.decoratorTarget.parent!==t.node)return}}if(r)n=Rm(n,r);sEe(e.program,t,n)},JP=(e,t,n)=>{if(t.optional){gn(e.program,{code:"no-optional-key",format:{propertyName:t.name},target:t});return}g7(e.program,t,n||t.name)},xD,oEe,GP,aEe,HP=(e,t,n)=>{let[r,i]=e.program.checker.isTypeAssignableTo(t.parameters,n.parameters,t);if(!r)e.program.reportDiagnostics(i);let[s,o]=e.program.checker.isTypeAssignableTo(t.returnType,n.returnType,t);if(!s)e.program.reportDiagnostics(o);if(!lEe(t,n))gn(e.program,{code:"overload-same-parent",target:e.decoratorTarget});aEe(e.program,t,n);let a=xD(e.program,n)||[];oEe(e.program,n,a.concat(t))},zP=(e,t,n={})=>{t7(e.program,t,{envelope:"object",discriminatorPropertyName:"kind",envelopePropertyName:"value",...n});let[r,i]=jd(e.program,t);e.program.reportDiagnostics(i)},WP=(e,t,n)=>{Z9(e.program,t,{propertyName:n})},cEe,uEe,wD=(e,t,n,r)=>{let i=t.decorators.find((a)=>a.decorator===wD&&a.node===e.decoratorTarget);Qe(i,"Couldn't find @example decorator",e.decoratorTarget);let s=i.args[0].value;if(Ws.realmForType.get(t)===void 0){if(!kP(e.program,s,t.kind==="ModelProperty"?t.type:t,e.getArgumentTarget(0)))return}let o=cEe(e.program,t);if(o===void 0)o=[],uEe(e.program,t,o);o.push({value:s,...r})},pEe,dEe,DD=(e,t,n,r)=>{let i=t.decorators.find((c)=>c.decorator===DD&&c.node===e.decoratorTarget);Qe(i,"Couldn't find @opExample decorator",e.decoratorTarget);let s=i.args[0].value,o=s.properties.get("parameters")?.value,a=s.properties.get("returnType")?.value;if(Ws.realmForType.get(t)===void 0){if(o&&!kP(e.program,o,t.parameters,e.getArgumentTarget(0)))return;if(a&&!kP(e.program,a,t.returnType,e.getArgumentTarget(0)))return}let l=pEe(e.program,t);if(l===void 0)l=[],dEe(e.program,t,l);l.push({parameters:o,returnType:a,...r})};var ul=q(()=>{$d();sb();_t();Bm();cc();lc();Yn();aP();ac();yr();It();Id();ka();Nn();Kw();Gw();pP();vb();Kw();V7();EP();[Tb,BSe]=ze(Pt("summary"));[JSe,GSe]=hr(Pt("error"));[HSe,zSe]=ze(Pt("mediaTypeHint"));[Md,WSe]=ze(Pt("format")),[QSe,YSe]=ze(Pt("patternValues")),[XSe,ZSe]=hr(Pt("secretTypes")),[uc,eEe]=ze(Pt("encode"));[rEe,iEe]=ze(Pt("tagProperties")),[VP,sEe]=ze(Pt("friendlyNames")),[xD,oEe]=ze(Pt("overloadedByKey")),[GP,aEe]=ze(Pt("overloadsOperation"));[cEe,uEe]=ze(Pt("examples")),[pEe,dEe]=ze(Pt("opExamples"))});var n5=q(()=>{ul();Gt();Or();Rd();nn({enum:{create(e){let t=this.program.checker.createType({kind:"Enum",name:e.name,decorators:ll(this,e.decorators),members:il()});if(Array.isArray(e.members))for(let n of e.members)n.enum=t,t.members.set(n.name,n);else for(let[n,r]of Object.entries(e.members??{}))t.members.set(n,this.enumMember.create({name:n,value:r,enum:t}));return this.program.checker.finishType(t),t},is(e){return e.entityKind==="Type"&&e.kind==="Enum"},createFromUnion(e){if(!e.name)throw Error("Cannot create an enum from an anonymous union.");let t=[];for(let r of e.variants.values()){if(r.name&&typeof r.name==="symbol"||!this.literal.isString(r.type)&&!this.literal.isNumeric(r.type))continue;let i=ei(this.program,r);t.push(this.enumMember.create({name:r.name,value:r.type.value,decorators:i?[[Xs,i]]:void 0}))}let n=ei(this.program,e);return this.enum.create({name:e.name,members:t,decorators:n?[[Xs,n]]:void 0})}}})});var r5=q(()=>{Or();nn({intrinsic:{get any(){return this.program.checker.anyType},get error(){return this.program.checker.errorType},get never(){return this.program.checker.neverType},get null(){return this.program.checker.nullType},get void(){return this.program.checker.voidType},is(e){return e.entityKind==="Type"&&e.kind==="Intrinsic"}}})});var i5=q(()=>{Or();nn({literal:{create(e){return this.program.checker.createLiteralType(e)},createString(e){return this.program.checker.createLiteralType(e)},createNumeric(e){return this.program.checker.createLiteralType(e)},createBoolean(e){return this.program.checker.createLiteralType(e)},isBoolean(e){return e.entityKind==="Type"&&e.kind==="Boolean"},isString(e){return e.entityKind==="Type"&&e.kind==="String"},isNumeric(e){return e.entityKind==="Type"&&e.kind==="Number"},is(e){return this.literal.isBoolean(e)||this.literal.isNumeric(e)||this.literal.isString(e)}}})});var s5=q(()=>{tD();ul();Or();nn({modelProperty:{is(e){return e.entityKind==="Type"&&e.kind==="ModelProperty"},getEncoding(e){return uc(this.program,e)??uc(this.program,e.type)},getFormat(e){return Md(this.program,e)??Md(this.program,e.type)},getVisibilityForClass(e,t){return Gm(this.program,e,t)},create(e){return this.program.checker.createType({kind:"ModelProperty",name:e.name,type:e.type,optional:e.optional??!1,decorators:[],defaultValue:e.defaultValue})}}})});var TD;var o5=q(()=>{Eb();Bm();lc();Gt();Mu();Or();Rd();TD=new Map;nn({model:{create(e){let t=il(Array.from(Object.entries(e.properties))),n=this.program.checker.createType({kind:"Model",name:e.name??"",decorators:ll(this,e.decorators),properties:t,derivedModels:e.derivedModels??[],sourceModels:e.sourceModels??[],indexer:e.indexer});return this.program.checker.finishType(n),n},is(e){return e.entityKind==="Type"&&e.kind==="Model"},isExpresion(e){return e.name===""},getEffectiveModel(e,t){return Sb(this.program,e,t)},getIndexType(e){if(TD.has(e))return TD.get(e);if(!e.indexer)return;if(e.indexer.key.name==="string"){let t=this.record.create(e.indexer.value);return TD.set(e,t),t}if(e.indexer.key.name==="integer"){let t=this.array.create(e.indexer.value);return TD.set(e,t),t}return},getProperties(e,t={}){let n=Ii(e.properties),r=this.model.getDiscriminatedUnion(e);if(r){let i=r.propertyName;n.set(i,this.modelProperty.create({name:i,type:this.builtin.string}))}if(t.includeExtended){let i=e.baseModel;while(i){for(let[s,o]of i.properties)if(!n.has(s))n.set(s,o);i=i.baseModel}}return n},getAdditionalPropertiesRecord(e){if(this.model.is(e)&&e.sourceModel&&this.record.is(e.sourceModel))return e.sourceModel;if(e.baseModel&&this.record.is(e.baseModel))return e.baseModel;let t=this.model.getIndexType(e);if(t&&this.record.is(t))return t;if(e.baseModel)return this.model.getAdditionalPropertiesRecord(e.baseModel);return},getDiscriminatedUnion:mi(function(e){let t=Ad(this.program,e);if(!t)return[void 0,[]];return Iw(e,t)})}})});var a5=q(()=>{vb();Mu();Or();nn({operation:{is(e){return e.entityKind==="Type"&&e.kind==="Operation"},getPagingMetadata:mi(function(e){return Ww(this.program,e)}),create(e){let t=this.model.create({name:`${e.name}Parameters`,properties:e.parameters.reduce((r,i)=>(r[i.name]=i,r),{})}),n=this.program.checker.createType({kind:"Operation",name:e.name,decorators:[],parameters:t,returnType:e.returnType});return this.program.checker.finishType(n),n}}})});var l5=q(()=>{yr();Or();nn({record:{is(e){return e.entityKind==="Type"&&e.kind==="Model"&&QO(e)&&e.properties.size===0},getElementType(e){if(!this.record.is(e))throw Error("Type is not a record.");return e.indexer.value},create(e){return this.model.create({name:"Record",properties:{},indexer:{key:this.builtin.string,value:e}})}}})});function Jn(e){return function(t){return t===this.program.checker.getStdType(e)}}function Gn(e){return function(t){if(!this.scalar.is(t))return!1;return F9(this.program,t,e)}}var c5=q(()=>{$d();ul();Or();nn({scalar:{is(e){return e.entityKind==="Type"&&e.kind==="Scalar"},extendsBoolean:Gn("boolean"),extendsBytes:Gn("bytes"),extendsDecimal:Gn("decimal"),extendsDecimal128:Gn("decimal128"),extendsDuration:Gn("duration"),extendsFloat:Gn("float"),extendsFloat32:Gn("float32"),extendsFloat64:Gn("float64"),extendsInt8:Gn("int8"),extendsInt16:Gn("int16"),extendsInt32:Gn("int32"),extendsInt64:Gn("int64"),extendsInteger:Gn("integer"),extendsNumeric:Gn("numeric"),extendsOffsetDateTime:Gn("offsetDateTime"),extendsPlainDate:Gn("plainDate"),extendsPlainTime:Gn("plainTime"),extendsSafeint:Gn("safeint"),extendsString:Gn("string"),extendsUint8:Gn("uint8"),extendsUint16:Gn("uint16"),extendsUint32:Gn("uint32"),extendsUint64:Gn("uint64"),extendsUrl:Gn("url"),extendsUtcDateTime:Gn("utcDateTime"),isBoolean:Jn("boolean"),isBytes:Jn("bytes"),isDecimal:Jn("decimal"),isDecimal128:Jn("decimal128"),isDuration:Jn("duration"),isFloat:Jn("float"),isFloat32:Jn("float32"),isFloat64:Jn("float64"),isInt8:Jn("int8"),isInt16:Jn("int16"),isInt32:Jn("int32"),isInt64:Jn("int64"),isInteger:Jn("integer"),isNumeric:Jn("numeric"),isOffsetDateTime:Jn("offsetDateTime"),isPlainDate:Jn("plainDate"),isPlainTime:Jn("plainTime"),isSafeint:Jn("safeint"),isString:Jn("string"),isUint8:Jn("uint8"),isUint16:Jn("uint16"),isUint32:Jn("uint32"),isUint64:Jn("uint64"),isUrl:Jn("url"),isUtcDateTime:Jn("utcDateTime"),getStdBase(e){let t=this.program.resolveTypeReference("TypeSpec")[0],n=e;while(n){if(n.namespace===t)return n;n=n.baseScalar}return null},getEncoding(e){return uc(this.program,e)},getFormat(e){return Md(this.program,e)}}})});var u5=q(()=>{Or();nn({tuple:{is(e){return e.entityKind==="Type"&&e.kind==="Tuple"},create(e=[]){let t=this.program.checker.createType({kind:"Tuple",name:"Tuple",values:e});return this.program.checker.finishType(t),t}}})});function QP(e){return e.charAt(0).toUpperCase()+e.slice(1)}function SD(e){let t=e.name??"TypeExpression";if(Lo(e))t=`${e.templateMapper.args.map((r)=>{if(r.entityKind==="Type")switch(r.kind){case"Scalar":let i=SD(r);return QP(i);case"Model":case"Interface":case"Enum":case"Union":return SD(r)}return"name"in r?r.name:""}).join("_")}${t}`;return t}var p5=q(()=>{yr()});var d5=q(()=>{ic();lc();yr();ul();Gw();Mu();Or();Rd();p5();nn({type:{is(e){return e.entityKind==="Type"},finishType(e){this.program.checker.finishType(e)},clone(e){let t;switch(e.kind){case"Model":t=this.program.checker.createType({...e,decorators:[...e.decorators],derivedModels:[...e.derivedModels],sourceModels:e.sourceModels.map((n)=>({...n})),properties:Ii(e.properties),indexer:e.indexer?{...e.indexer}:void 0});break;case"Union":t=this.program.checker.createType({...e,decorators:[...e.decorators],variants:Ii(e.variants),get options(){return Array.from(this.variants.values()).map((n)=>n.type)}});break;case"Interface":t=this.program.checker.createType({...e,decorators:[...e.decorators],operations:Ii(e.operations)});break;case"Enum":t=this.program.checker.createType({...e,decorators:[...e.decorators],members:Ii(e.members)});break;case"Namespace":t=this.program.checker.createType({...e,decorators:[...e.decorators],instantiationParameters:e.instantiationParameters?[...e.instantiationParameters]:void 0,models:Ii(e.models),decoratorDeclarations:Ii(e.decoratorDeclarations),enums:Ii(e.enums),unions:Ii(e.unions),operations:Ii(e.operations),interfaces:Ii(e.interfaces),namespaces:Ii(e.namespaces),scalars:Ii(e.scalars)});break;case"Scalar":t=this.program.checker.createType({...e,decorators:[...e.decorators],derivedScalars:[...e.derivedScalars],constructors:Ii(e.constructors)});break;case"Tuple":t=this.program.checker.createType({...e,values:[...e.values]});break;default:t=this.program.checker.createType({...e,..."decorators"in e?{decorators:[...e.decorators]}:{}});break}return this.realm.addType(t),t},isError(e){return fc(this.program,e)},getEncodedName(e,t){return mb(this.program,e,t)},getSummary(e){return Tb(this.program,e)},getDoc(e){return ei(this.program,e)},getPlausibleName(e){return SD(e)},maxValue(e){return Mm(this.program,e)},minValue(e){return Fm(this.program,e)},maxLength(e){return nb(this.program,e)},minLength(e){return tb(this.program,e)},maxItems(e){return ib(this.program,e)},maxValueExclusive(e){return Ew(this.program,e)},minValueExclusive(e){return Sw(this.program,e)},minItems(e){return rb(this.program,e)},isNever(e){return ww(e)},isUserDefined(e){return Co(this.program,e).type==="project"},inNamespace(e,t){if(e===t)return!0;switch(e.kind){case"ModelProperty":if(e.model)return this.type.inNamespace(e.model,t);break;case"EnumMember":return this.type.inNamespace(e.enum,t);case"UnionVariant":return this.type.inNamespace(e.union,t);case"Operation":if(e.interface)return this.type.inNamespace(e.interface,t);break}if("namespace"in e&&e.namespace)return this.type.inNamespace(e.namespace,t);return!1},isAssignableTo:mi(function(e,t,n){return this.program.checker.isTypeAssignableTo(e,t,n??e)}),resolve:mi(function(e,t){let[n,r]=this.program.resolveTypeReference(e);if(n&&t&&n.kind!==t)throw Error(`Type kind mismatch: expected ${t}, got ${n.kind}`);return[n,r]})}})});var f5=q(()=>{Or();Rd();nn({unionVariant:{create(e){let t=this.program.checker.createType({kind:"UnionVariant",name:e.name??Symbol("name"),decorators:ll(this,e.decorators),type:e.type,union:e.union});return this.program.checker.finishType(t),t},is(e){return e.entityKind==="Type"&&e.kind==="UnionVariant"}}})});var fEe;var m5=q(()=>{_t();Bm();ul();Gt();Mu();Or();Rd();fEe=nn({union:{filter(e,t){let n=Array.from(e.variants.values()).filter(t);return this.union.create({variants:n})},create(e){let t;if(Array.isArray(e))t={decorators:[],variants:e.map((r)=>{let i=ei(this.program,r);return this.unionVariant.create({type:r,decorators:i?[[Xs,i]]:void 0})})};else t=e;let n=this.program.checker.createType({kind:"Union",name:t.name,decorators:ll(this,t.decorators),variants:il(),get options(){return Array.from(this.variants.values()).map((r)=>r.type)},expression:t.name===void 0});if(Array.isArray(t.variants))for(let r of t.variants)n.variants.set(r.name,r),r.union=n;else if(t.variants)for(let[r,i]of Object.entries(t.variants))n.variants.set(r,this.unionVariant.create({name:r,type:this.literal.create(i)}));return this.program.checker.finishType(n),n},createFromEnum(e){let t=ei(this.program,e);return this.union.create({name:e.name,decorators:t?[[Xs,t]]:void 0,variants:Array.from(e.members.values()).map((n)=>{let r=ei(this.program,n),i=n.value??n.name;return this.unionVariant.create({name:n.name,type:this.literal.create(i),decorators:r?[[Xs,r]]:void 0})})})},is(e){return e.entityKind==="Type"&&e.kind==="Union"},isValidEnum(e){for(let t of e.variants.values())if(!this.literal.isString(t.type)&&!this.literal.isNumeric(t.type))return!1;return!0},isExtensible(e){let t=Array.from(e.variants.values());if(t.length===0)return!1;for(let n=0;n{ac();yr();Mu();Or();nn({value:{is(e){return e.entityKind==="Value"},create(e){if(typeof e==="string")return this.value.createString(e);else if(typeof e==="number")return this.value.createNumeric(e);else return this.value.createBoolean(e)},createString(e){return{entityKind:"Value",value:e,valueKind:"StringValue",type:this.literal.createString(e),scalar:void 0}},createNumeric(e){let t=String(e);return{entityKind:"Value",value:kn(t),valueKind:"NumericValue",type:this.literal.createNumeric(e),scalar:void 0}},createBoolean(e){return{entityKind:"Value",value:e,valueKind:"BooleanValue",type:this.literal.createBoolean(e),scalar:void 0}},isBoolean(e){return this.value.is(e)&&e.valueKind==="BooleanValue"},isString(e){return this.value.is(e)&&e.valueKind==="StringValue"},isNumeric(e){return this.value.is(e)&&e.valueKind==="NumericValue"},isArray(e){return this.value.is(e)&&e.valueKind==="ArrayValue"},isObject(e){return this.value.is(e)&&e.valueKind==="ObjectValue"},isEnum(e){return this.value.is(e)&&e.valueKind==="EnumValue"},isNull(e){return this.value.is(e)&&e.valueKind==="NullValue"},isScalar(e){return this.value.is(e)&&e.valueKind==="ScalarValue"},isAssignableTo:mi(function(e,t,n){return this.program.checker.isTypeAssignableTo(e,t,n??e)}),isOfType:mi(function(e,t,n){return this.program.checker.isValueOfType(e,t,n??e)}),resolve:mi(function(e,t){let[n,r]=this.program.resolveTypeOrValueReference(e);if(n&&!Sa(n))return[void 0,r];if(n&&t&&n.valueKind!==t)throw Error(`Value kind mismatch: expected ${t}, got ${n.valueKind}`);return[n,r]})}})});var h5=q(()=>{i7();s7();o7();a7();n5();r5();i5();s5();o5();a5();l5();c5();u5();d5();f5();m5();y5()});function yEe(e){let t;if(Object.hasOwn(e,"projectRoot"))t=e[mEe]??=new Ws(e,"default typekit realm");else t=e;return t.typekit}var mEe,Kn;var ka=q(()=>{Id();Mu();Or();h5();mEe=Symbol.for("TypeSpec.Typekit.DEFAULT_TYPEKIT_REALM");Kn=yEe});function Vo(e){let t=Vn.None;for(let n of e)t|=gEe(n);return t}function gEe(e){switch(e.kind){case re.ExternKeyword:return Vn.Extern;case re.InternalKeyword:return Vn.Internal;case re.AutoKeyword:return Vn.Auto;default:Qe(!1,`Unknown modifier kind: ${e.kind}`)}}var Bu,hEe,Wmt;var YP=q(()=>{_t();Yn();It();Bu={allowed:Vn.Internal,required:Vn.None},hEe={allowed:Vn.None,required:Vn.None},Wmt={[re.NamespaceStatement]:hEe,[re.OperationStatement]:Bu,[re.ModelStatement]:Bu,[re.ScalarStatement]:Bu,[re.InterfaceStatement]:Bu,[re.UnionStatement]:Bu,[re.EnumStatement]:Bu,[re.AliasStatement]:Bu,[re.ConstStatement]:Bu,[re.DecoratorDeclarationStatement]:{allowed:Vn.All,required:Vn.Extern|Vn.Auto,mutuallyExclusive:[[Vn.Extern,Vn.Auto]]},[re.FunctionDeclarationStatement]:{allowed:Vn.Extern|Vn.Internal,required:Vn.Extern}}});function Ld(e,t={}){return vEe(e,t).parseTypeSpecScript()}function vEe(e,t={}){let n=!1,r=-1,i=-1,s=0,o=!0,a=!0,l=kb.Syntax,c=[],u=oP(e,Gle),p=[],d=[];return Qn(),{parseDiagnostics:c,parseTypeSpecScript:f,parseStandaloneReferenceExpression:fe};function f(){let P=y();return{kind:re.TypeSpecScript,statements:P,file:u.file,id:{kind:re.Identifier,sv:u.file.path,pos:0,end:0,flags:Zi.Synthetic},namespaces:[],usings:[],locals:void 0,inScopeNamespaces:[],parseDiagnostics:c,comments:p,printable:o,parseOptions:t,...Ue(0)}}function m({skipParsingDocNodes:P}={}){let B=[],ee=[],Te=[],Me=rt();if(!P){let[bt,ht]=po();Me=bt;for(let jn of ht)Te.push(jn)}while(Ze()===w.Hash||Ze()===w.At){if(Ze()===w.Hash)B.push(Q());else if(Ze()===w.At)ee.push(A());if(!P){let[bt,ht]=po();for(let jn of ht)Te.push(jn)}}return{pos:Me,docs:Te,directives:B,decorators:ee}}function y(){let P=[],B=!1,ee=!1,Te=!1;while(Ze()!==w.EndOfFile){let{pos:Me,docs:bt,directives:ht,decorators:jn}=m(),ar=Ze(),qn;switch(ar){case w.AtAt:xi(jn,"augment decorator statement"),qn=k();break;case w.ImportKeyword:xi(jn,"import statement"),qn=E();break;case w.UsingKeyword:xi(jn,"using statement"),qn=X(Me);break;case w.Semicolon:xi(jn,"empty statement"),qn=EC(Me);break;case w.NamespaceKeyword:case w.ModelKeyword:case w.ScalarKeyword:case w.InterfaceKeyword:case w.UnionKeyword:case w.OpKeyword:case w.EnumKeyword:case w.AliasKeyword:case w.ConstKeyword:case w.ExternKeyword:case w.InternalKeyword:case w.AutoKeyword:case w.FnKeyword:case w.DecKeyword:qn=ch(Me,jn,bt,ht);break;default:qn=bE(Me,jn);break}if(ar!==w.NamespaceKeyword)Tn(qn).directives=ht,Tn(qn).docs=bt;if(g5(qn)){if(B)an({code:"multiple-blockless-namespace",target:qn});if(ee)an({code:"blockless-namespace-first",target:qn});B=!0}else if(qn.kind===re.ImportStatement){if(ee||B||Te)an({code:"import-first",target:qn})}else if(qn.kind===re.UsingStatement)Te=!0;else ee=!0;P.push(qn)}return P}function h(){let P=[];while(Ze()!==w.CloseBrace){let{pos:B,docs:ee,directives:Te,decorators:Me}=m(),bt=Ze(),ht;switch(bt){case w.AtAt:xi(Me,"augment decorator statement"),ht=k();break;case w.ImportKeyword:xi(Me,"import statement"),ht=E(),an({code:"import-first",messageId:"topLevel",target:ht});break;case w.UsingKeyword:xi(Me,"using statement"),ht=X(B);break;case w.ModelKeyword:case w.ScalarKeyword:case w.NamespaceKeyword:case w.InterfaceKeyword:case w.UnionKeyword:case w.OpKeyword:case w.EnumKeyword:case w.AliasKeyword:case w.ConstKeyword:case w.ExternKeyword:case w.InternalKeyword:case w.AutoKeyword:case w.FnKeyword:case w.DecKeyword:ht=ch(B,Me,ee,Te);break;case w.EndOfFile:return it(w.CloseBrace),P;case w.Semicolon:xi(Me,"empty statement"),ht=EC(B);break;default:ht=bE(B,Me);break}if(g5(ht))an({code:"blockless-namespace-first",messageId:"topLevel",target:ht});if(Tn(ht).directives=Te,bt!==w.NamespaceKeyword)Tn(ht).docs=ee;P.push(ht)}return P}function b(){let P=[];while(Ze()===w.At)P.push(A());return P}function g(){let P=[];while(Ze()===w.Hash)P.push(Q());return P}function x(P,B,ee,Te,Me){it(w.NamespaceKeyword);let bt=Je(),ht=[];while(bt.kind!==re.Identifier)ht.push(bt.id),bt=bt.base;ht.push(bt);let jn=OC(w.Semicolon,w.OpenBrace),ar;if(jn===w.OpenBrace)ar=h(),it(w.CloseBrace);let qn={kind:re.NamespaceStatement,decorators:B,docs:Te,id:ht[0],locals:void 0,statements:ar,directives:Me,modifiers:ee,modifierFlags:Vo(ee),...Ue(P)};for(let Yc=1;Ycte(qn,Yc,void 0,!0));return{kind:re.InterfaceStatement,id:Te,templateParameters:Me,templateParametersRange:bt,operations:jn,bodyRange:ar,extends:ht.items,decorators:B,modifiers:ee,modifierFlags:Vo(ee),...Ue(P)}}function D(){let P=x_(Pr.TemplateParameters,Z),B=!1;for(let ee of P.items){if(!ee.default&&B){an({code:"default-required",target:ee});continue}if(ee.default)B=!0}return P}function T(P,B,ee){it(w.UnionKeyword);let Te=wn(),{items:Me,range:bt}=D();mh(w.OpenBrace,w.ExtendsKeyword);let ht=N(),{items:jn}=Vi(Pr.UnionVariants,C);return{kind:re.UnionStatement,id:Te,templateParameters:Me,templateParametersRange:bt,extends:ht,decorators:B,modifiers:ee,modifierFlags:Vo(ee),options:jn,...Ue(P)}}function N(){if(Mt(w.ExtendsKeyword))return V();return}function O(){let P=Ze(),B;if(lb(P)||cb(P)){if(B=wn({allowReservedIdentifier:!0}),Ze()!==w.Colon)if(lb(P))an({code:"reserved-identifier",messageId:"future",format:{name:B.sv}});else an({code:"reserved-identifier"});return{kind:re.TypeReference,target:B,arguments:[],...Ue(B.pos)}}else return V()}function C(P,B){let ee=O();if(Mt(w.Colon)){let Te=void 0;if(ee.kind!==re.TypeReference&&ee.kind!==re.StringLiteral)an({code:"token-expected",messageId:"identifier"});else if(ee.kind===re.StringLiteral)Te={kind:re.Identifier,sv:ee.value,...Ue(ee.pos)};else{let bt=ee.target;if(bt.kind===re.Identifier)Te=bt;else an({code:"token-expected",messageId:"identifier"})}let Me=V();return{kind:re.UnionVariant,id:Te,value:Me,decorators:B,...Ue(P)}}return{kind:re.UnionVariant,id:void 0,value:ee,decorators:B,...Ue(P)}}function X(P){it(w.UsingKeyword);let B=Je();return it(w.Semicolon),{kind:re.UsingStatement,name:B,...Ue(P)}}function te(P,B,ee,Te){let Me;if(Te)Me=b_(),Mt(w.OpKeyword);else Me=ee,it(w.OpKeyword);let bt=wn(),{items:ht,range:jn}=D(),ar=mh(w.OpenParen,w.IsKeyword),qn,Yc=rt();if(ar===w.OpenParen){let vE=L();it(w.Colon);let zle=V();qn={kind:re.OperationSignatureDeclaration,parameters:vE,returnType:zle,...Ue(Yc)}}else{it(w.IsKeyword);let vE=Ce();qn={kind:re.OperationSignatureReference,baseOperation:vE,...Ue(Yc)}}if(!Te)it(w.Semicolon);return{kind:re.OperationStatement,id:bt,templateParameters:ht,templateParametersRange:jn,signature:qn,decorators:B,modifiers:Me,modifierFlags:Vo(Me),...Ue(P)}}function L(){let P=rt(),{items:B,range:ee}=Vi(Pr.OperationParameters,je);return{kind:re.ModelExpression,properties:B,bodyRange:ee,...Ue(P)}}function Y(P,B,ee){it(w.ModelKeyword);let Te=wn(),{items:Me,range:bt}=D();mh(w.OpenBrace,w.Equals,w.ExtendsKeyword,w.IsKeyword);let ht=me(),jn=ht?void 0:I(),ar=Qc();if(jn)if(mh(w.Semicolon,w.OpenBrace)===w.Semicolon)Qn();else ar=Vi(Pr.ModelProperties,je);else ar=Vi(Pr.ModelProperties,je);return{kind:re.ModelStatement,id:Te,extends:ht,is:jn,templateParameters:Me,templateParametersRange:bt,decorators:B,properties:ar.items,bodyRange:ar.range,modifiers:ee,modifierFlags:Vo(ee),...Ue(P)}}function me(){if(Mt(w.ExtendsKeyword))return V();return}function I(){if(Mt(w.IsKeyword))return V();return}function Z(){let P=rt(),B=wn(),ee;if(Mt(w.ExtendsKeyword))ee=de();let Te;if(Mt(w.Equals))Te=V();return{kind:re.TemplateParameterDeclaration,id:B,constraint:ee,default:Te,...Ue(P)}}function pe(){if(Ze()===w.ValueOfKeyword)return W();else if(Mt(w.OpenParen)){let P=de();return it(w.CloseParen),P}return H()}function de(){let P=rt();Mt(w.Bar);let B=pe();if(Ze()!==w.Bar)return B;let ee=[B];while(Mt(w.Bar)){let Te=pe();ee.push(Te)}return{kind:re.UnionExpression,options:ee,...Ue(P)}}function je(P,B){return Ze()===w.Ellipsis?be(P,B):Ie(P,B)}function be(P,B){it(w.Ellipsis),xi(B,"spread property");let ee=Ce();return{kind:re.ModelSpreadProperty,target:ee,...Ue(P)}}function Ie(P,B){let ee=wn({message:"property",allowStringLiteral:!0,allowReservedIdentifier:!0}),Te=Mt(w.Question);it(w.Colon);let Me=V(),ht=Mt(w.Equals)?V():void 0;return{kind:re.ModelProperty,id:ee,decorators:B,value:Me,optional:Te,default:ht,...Ue(P)}}function J(P,B){return xi(B,"object literal property"),Ze()===w.Ellipsis?_e(P):ue(P)}function _e(P){it(w.Ellipsis);let B=Ce();return{kind:re.ObjectLiteralSpreadProperty,target:B,...Ue(P)}}function ue(P){let B=wn({message:"property",allowReservedIdentifier:!0});it(w.Colon);let ee=V();return{kind:re.ObjectLiteralProperty,id:B,value:ee,...Ue(P)}}function ce(P,B,ee){it(w.ScalarKeyword);let Te=wn(),{items:Me,range:bt}=D(),ht=Le(),{items:jn,range:ar}=Ke();return{kind:re.ScalarStatement,id:Te,templateParameters:Me,templateParametersRange:bt,extends:ht,members:jn,bodyRange:ar,decorators:B,modifiers:ee,modifierFlags:Vo(ee),...Ue(P)}}function Le(){if(Mt(w.ExtendsKeyword))return Ce();return}function Ke(){if(Ze()===w.Semicolon)return Qn(),Qc();else return Vi(Pr.ScalarMembers,ct)}function ct(P,B){xi(B,"scalar member"),it(w.InitKeyword);let ee=wn(),{items:Te}=zc();return{kind:re.ScalarConstructor,id:ee,parameters:Te,...Ue(P)}}function lt(P,B,ee){it(w.EnumKeyword);let Te=wn(),{items:Me}=Vi(Pr.EnumMembers,se);return{kind:re.EnumStatement,id:Te,decorators:B,modifiers:ee,modifierFlags:Vo(ee),members:Me,...Ue(P)}}function se(P,B){return Ze()===w.Ellipsis?he(P,B):Ne(P,B)}function he(P,B){it(w.Ellipsis),xi(B,"spread enum");let ee=Ce();return{kind:re.EnumSpreadMember,target:ee,...Ue(P)}}function Ne(P,B){let ee=wn({message:"enumMember",allowStringLiteral:!0,allowReservedIdentifier:!0}),Te;if(Mt(w.Colon)){let Me=V();if(Me.kind===re.StringLiteral||Me.kind===re.NumericLiteral)Te=Me;else if(Me.kind===re.TypeReference&&Me.target.flags&Zi.ThisNodeHasError)n=!0;else an({code:"token-expected",messageId:"numericOrStringLiteral",target:Me})}return{kind:re.EnumMember,id:ee,value:Te,decorators:B,...Ue(P)}}function Re(P,B){it(w.AliasKeyword);let ee=wn(),{items:Te,range:Me}=D();it(w.Equals);let bt=V();return it(w.Semicolon),{kind:re.AliasStatement,id:ee,templateParameters:Te,templateParametersRange:Me,value:bt,modifiers:B,modifierFlags:Vo(B),...Ue(P)}}function Oe(P,B){it(w.ConstKeyword);let ee=wn(),Te=G();it(w.Equals);let Me=V();return it(w.Semicolon),{kind:re.ConstStatement,id:ee,value:Me,type:Te,modifiers:B,modifierFlags:Vo(B),...Ue(P)}}function G(){if(Mt(w.Colon))return V();return}function V(){return j()}function j(){let P=rt();Mt(w.Bar);let B=H();if(Ze()!==w.Bar)return B;let ee=[B];while(Mt(w.Bar)){let Te=H();ee.push(Te)}for(let Te of ee.filter((Me)=>Me.kind===re.FunctionTypeExpression))if(!Te.parenthesized)an({code:"fn-in-union-expression",target:Te});return{kind:re.UnionExpression,options:ee,...Ue(P)}}function H(){let P=rt();Mt(w.Ampersand);let B=ge();if(Ze()!==w.Ampersand)return B;let ee=[B];while(Mt(w.Ampersand)){let Te=ge();ee.push(Te)}return{kind:re.IntersectionExpression,options:ee,...Ue(P)}}function ge(){let P=rt(),B=Et();while(Mt(w.OpenBracket))it(w.CloseBracket),B={kind:re.ArrayExpression,elementType:B,...Ue(P)};return B}function fe(){let P=Ce();if(c.length===0&&Ze()!==w.EndOfFile)an({code:"token-expected",messageId:"unexpected",format:{token:w[Ze()]}});return P}function W(){let P=rt();it(w.ValueOfKeyword);let B=V();return{kind:re.ValueOfExpression,target:B,...Ue(P)}}function ye(){let P=rt();it(w.TypeOfKeyword);let B=Pe();return{kind:re.TypeOfExpression,target:B,...Ue(P)}}function Pe(){while(!0)switch(Ze()){case w.TypeOfKeyword:return ye();case w.Identifier:return Bt();case w.StringLiteral:return Hc();case w.StringTemplateHead:return lh();case w.TrueKeyword:case w.FalseKeyword:return Bi();case w.NumericLiteral:return Ar();case w.OpenParen:it(w.OpenParen);let P=Pe();return it(w.CloseParen),P;default:return Ce("typeofTarget")}}function Se(){let P=rt();it(w.FnKeyword);let{items:B}=zc(),Te=Mt(w.EqualsGreaterThan)?de():void 0;return{kind:re.FunctionTypeExpression,parameters:B,returnType:Te,...Ue(P)}}function Ce(P){let B=rt(),ee=Je({message:P,allowReservedIdentifierInMember:!0});return _(ee,B)}function Bt(P){let B=rt(),ee=Je({message:P,allowReservedIdentifierInMember:!0});if(Ze()===w.OpenParen){let{items:Te}=Vi(Pr.FunctionArguments,V);return{kind:re.CallExpression,target:ee,arguments:Te,...Ue(B)}}return _(ee,B)}function _(P,B){let{items:ee}=x_(Pr.TemplateArguments,S);return{kind:re.TypeReference,target:P,arguments:ee,...Ue(B)}}function S(){let P=rt();if(Ze()===w.Equals)return an({code:"token-expected",messageId:"identifier"}),Qn(),{kind:re.TemplateArgument,name:Wc(),argument:V(),...Ue(P)};let B=V();if(Mt(w.Equals)){let Te=XP(B);if(!Te)an({code:"invalid-template-argument-name",target:B});return{kind:re.TemplateArgument,name:Te?B.target:Wc(),argument:V(),...Ue(P)}}else return{kind:re.TemplateArgument,argument:B,...Ue(P)}}function k(){let P=rt();it(w.AtAt);let B=Je({allowReservedIdentifier:!0,allowReservedIdentifierInMember:!0}),{items:ee}=x_(Pr.DecoratorArguments,V);if(ee.length===0){an({code:"augment-decorator-target"});let bt=Qc();return{kind:re.AugmentDecoratorStatement,target:B,targetType:{kind:re.TypeReference,target:Wc(),arguments:bt.items,...Ue(P)},arguments:ee,...Ue(P)}}let[Te,...Me]=ee;if(Te.kind!==re.TypeReference){an({code:"augment-decorator-target",target:Te});let bt=Qc();Te={kind:re.TypeReference,target:Wc(),arguments:bt.items,...Ue(P)}}return it(w.Semicolon),{kind:re.AugmentDecoratorStatement,target:B,targetType:Te,arguments:Me,...Ue(P)}}function E(){let P=rt();it(w.ImportKeyword);let B=Hc();return it(w.Semicolon),{kind:re.ImportStatement,path:B,...Ue(P)}}function A(){let P=rt();it(w.At);let B=Je({allowReservedIdentifier:!0,allowReservedIdentifierInMember:!0}),{items:ee}=x_(Pr.DecoratorArguments,V);return{kind:re.DecoratorExpression,arguments:ee,target:B,...Ue(P)}}function Q(){let P=rt();it(w.Hash);let B=wn();if(B.sv!=="suppress"&&B.sv!=="deprecated")an({code:"unknown-directive",format:{id:B.sv},target:{pos:P,end:P+B.sv.length},printable:!0});a=!1;let ee=[];while(Ze()!==w.NewLine&&Ze()!==w.EndOfFile){let Te=le();if(Te)ee.push(Te)}return a=!0,Qn(),{kind:re.DirectiveExpression,arguments:ee,target:B,...Ue(P)}}function le(){switch(Ze()){case w.Identifier:return wn();case w.StringLiteral:return Hc();default:an({code:"token-expected",messageId:"unexpected",format:{token:w[Ze()]}});do Qn();while(!qw(Ze())&&Ze()!==w.NewLine&&Ze()!==w.At&&Ze()!==w.Semicolon&&Ze()!==w.EndOfFile);return}}function Je(P){let B=rt(),ee=wn({message:P?.message,allowReservedIdentifier:P?.allowReservedIdentifier});while(Ze()!==w.EndOfFile)if(Mt(w.Dot))ee={kind:re.MemberExpression,base:ee,id:wn({allowReservedIdentifier:P?.allowReservedIdentifierInMember}),selector:".",...Ue(B)};else if(Mt(w.ColonColon))ee={kind:re.MemberExpression,base:ee,id:wn(),selector:"::",...Ue(B)};else break;return ee}function Et(){while(!0)switch(Ze()){case w.TypeOfKeyword:return ye();case w.FnKeyword:return Se();case w.Identifier:return Bt();case w.StringLiteral:return Hc();case w.StringTemplateHead:return lh();case w.TrueKeyword:case w.FalseKeyword:return Bi();case w.NumericLiteral:return Ar();case w.OpenBrace:return Bs();case w.OpenBracket:return qa();case w.OpenParen:return Us();case w.At:let P=b();xi(P,"expression");continue;case w.Hash:let B=g();NC(B,"expression");continue;case w.HashBrace:return ls();case w.HashBracket:return ah();case w.VoidKeyword:return Ln();case w.NeverKeyword:return Rn();case w.UnknownKeyword:return _i();default:return Ce("expression")}}function ut(){let P=rt();return it(w.ExternKeyword),{kind:re.ExternKeyword,...Ue(P)}}function wt(){let P=rt();return it(w.InternalKeyword),{kind:re.InternalKeyword,...Ue(P)}}function At(){let P=rt();return it(w.AutoKeyword),{kind:re.AutoKeyword,...Ue(P)}}function Ln(){let P=rt();return it(w.VoidKeyword),{kind:re.VoidKeyword,...Ue(P)}}function Rn(){let P=rt();return it(w.NeverKeyword),{kind:re.NeverKeyword,...Ue(P)}}function _i(){let P=rt();return it(w.UnknownKeyword),{kind:re.UnknownKeyword,...Ue(P)}}function Us(){let P=rt();it(w.OpenParen);let B=V();return it(w.CloseParen),{parenthesized:!0,...B,...Ue(P)}}function qa(){let P=rt(),{items:B}=Vi(Pr.Tuple,V);return{kind:re.TupleExpression,values:B,...Ue(P)}}function Bs(){let P=rt(),{items:B,range:ee}=Vi(Pr.ModelProperties,je);return{kind:re.ModelExpression,properties:B,bodyRange:ee,...Ue(P)}}function ls(){let P=rt(),{items:B,range:ee}=Vi(Pr.ObjectLiteralProperties,J);return{kind:re.ObjectLiteral,properties:B,bodyRange:ee,...Ue(P)}}function ah(){let P=rt(),{items:B}=Vi(Pr.ArrayLiteral,V);return{kind:re.ArrayLiteral,values:B,...Ue(P)}}function Hc(){let P=rt(),B=Ua();return it(w.StringLiteral),{kind:re.StringLiteral,value:B,...Ue(P)}}function lh(){let P=rt(),B=R(),ee=K(B.tokenFlags),Te=ee[ee.length-1];if(B.tokenFlags&qt.TripleQuoted){let[Me,bt]=u.findTripleQuotedStringIndent(Te.literal.pos,Te.literal.end);Tn(B).value=u.unindentAndUnescapeTripleQuotedString(B.pos,B.end,Me,bt,w.StringTemplateHead,B.tokenFlags);for(let ht of ee)Tn(ht.literal).value=u.unindentAndUnescapeTripleQuotedString(ht.literal.pos,ht.literal.end,Me,bt,ht===Te?w.StringTemplateTail:w.StringTemplateMiddle,B.tokenFlags)}return{kind:re.StringTemplateExpression,head:B,spans:ee,...Ue(P)}}function R(){let P=rt(),B=dh(),ee=B&qt.TripleQuoted?"":Ua();return it(w.StringTemplateHead),{kind:re.StringTemplateHead,value:ee,tokenFlags:B,...Ue(P)}}function K(P){let B=[],ee;do ee=Fe(P),B.push(ee);while(ee.literal.kind===re.StringTemplateMiddle);return B}function Fe(P){let B=rt(),ee=V(),Te=Ge(P);return{kind:re.StringTemplateSpan,literal:Te,expression:ee,...Ue(B)}}function Ge(P){let B=rt(),ee=dh(),Te=ee&qt.TripleQuoted?"":Ua();if(Ze()===w.CloseBrace)return Ule(P),tt();else return it(w.StringTemplateTail),{kind:re.StringTemplateTail,value:Te,tokenFlags:ee,...Ue(B)}}function tt(){let P=rt(),B=dh(),ee=B&qt.TripleQuoted?"":Ua(),Te=Ze()===w.StringTemplateMiddle?re.StringTemplateMiddle:re.StringTemplateTail;return Qn(),{kind:Te,value:ee,tokenFlags:B,...Ue(P)}}function Ar(){let P=rt(),B=Ua(),ee=Number(B);return it(w.NumericLiteral),{kind:re.NumericLiteral,value:ee,valueAsString:B,...Ue(P)}}function Bi(){let P=rt(),ee=OC(w.TrueKeyword,w.FalseKeyword)===w.TrueKeyword;return{kind:re.BooleanLiteral,value:ee,...Ue(P)}}function wn(P){if(sP(Ze())){if(!(cb(Ze())&&P?.allowReservedIdentifier))return an({code:"reserved-identifier"}),Wc()}else if(lb(Ze())){if(!P?.allowReservedIdentifier)an({code:"reserved-identifier",messageId:"future",format:{name:Ua()}})}else if(Ze()!==w.Identifier&&(!P?.allowStringLiteral||Ze()!==w.StringLiteral))return an({code:"token-expected",messageId:P?.message??"identifier"}),Wc();let B=rt(),ee=Ua();return Qn(),{kind:re.Identifier,sv:ee,...Ue(B)}}function ch(P,B,ee,Te){let Me=b_();switch(Ze()){case w.ModelKeyword:return Y(P,B,Me);case w.ScalarKeyword:return ce(P,B,Me);case w.NamespaceKeyword:return x(P,B,Me,ee,Te);case w.InterfaceKeyword:return v(P,B,Me);case w.UnionKeyword:return T(P,B,Me);case w.OpKeyword:return te(P,B,Me);case w.EnumKeyword:return lt(P,B,Me);case w.AliasKeyword:return xi(B,"alias statement"),Re(P,Me);case w.ConstKeyword:return xi(B,"const statement"),Oe(P,Me);case w.DecKeyword:return __(P,Me);case w.FnKeyword:return uh(P,Me)}return bE(P,[])}function b_(){let P=[],B;while(B=v_())P.push(B);return P}function v_(){switch(Ze()){case w.ExternKeyword:return ut();case w.InternalKeyword:return wt();case w.AutoKeyword:return At();default:return}}function __(P,B){let ee=Vo(B);it(w.DecKeyword);let Te=wn(),Me=zc(),[bt,...ht]=Me.items;if(bt===void 0)an({code:"decorator-decl-target",target:{pos:P,end:r}}),bt={kind:re.FunctionParameter,id:Wc(),type:Ble(),optional:!1,rest:!1,...Ue(P)};if(bt.optional)an({code:"decorator-decl-target",messageId:"required"});return it(w.Semicolon),{kind:re.DecoratorDeclarationStatement,modifiers:B,modifierFlags:ee,id:Te,target:bt,parameters:ht,...Ue(P)}}function uh(P,B){let ee=Vo(B);it(w.FnKeyword);let Te=wn(),{items:Me}=zc(),bt;if(Mt(w.Colon))bt=de();return it(w.Semicolon),{kind:re.FunctionDeclarationStatement,modifiers:B,modifierFlags:ee,id:Te,parameters:Me,returnType:bt,...Ue(P)}}function zc(){let P=Vi(Pr.FunctionParameters,ph),B=!1;for(let[ee,Te]of P.items.entries()){if(!Te.optional&&B){an({code:"required-parameter-first",target:Te});continue}if(Te.optional)B=!0;if(Te.rest&&Te.optional)an({code:"rest-parameter-required",target:Te});if(Te.rest&&ee!==P.items.length-1)an({code:"rest-parameter-last",target:Te})}return P}function ph(){let P=rt(),B=Mt(w.Ellipsis),ee=wn({message:"property",allowReservedIdentifier:!0}),Te=Mt(w.Question),Me;if(Mt(w.Colon))Me=de();return{kind:re.FunctionParameter,id:ee,type:Me,optional:Te,rest:B,...Ue(P)}}function Np(P,B,ee){let Te=l,Me=u.scanRange(B,()=>(l=P,Qn(),ee()));return l=Te,Me}function Al(P){return{pos:P.pos+3,end:dh()&qt.Unterminated?P.end:P.end-2}}function po(){if(d.length===0||t.docs===!1)return[rt(),[]];let P=[];for(let B of d){let ee=Np(kb.Doc,Al(B),()=>jle(B));if(P.push(ee),B.comment)Tn(B.comment).parsedAsDocs=!0}return[d[0].pos,P]}function jle(P){let B=[],ee=[];e:while(!0)switch(Ze()){case w.EndOfFile:break e;case w.At:let Te=Fle();ee.push(Te);break;default:B.push(...hE());break}return{kind:re.Doc,content:B,tags:ee,...Ue(P.pos),end:P.end}}function hE(){let P=[],B=u.file.text,ee=rt(),Te=ee,Me=!1;e:while(!0)switch(Ze()){case w.DocCodeFenceDelimiter:Me=!Me,Qn();break;case w.NewLine:P.push(B.substring(Te,rt())),P.push(` +`),Qn(),Te=rt();while(Mt(w.Whitespace));if(!Mt(w.Star))break;if(!Me){Mt(w.Whitespace),Te=rt();break}let ht=rt();Mt(w.Whitespace),Te=Math.min(ht+1,rt());break;case w.EndOfFile:break e;case w.At:if(!Me)break e;Qn();break;case w.DocText:P.push(B.substring(Te,rt())),P.push(Ua()),Qn(),Te=rt();break;default:Qn();break}P.push(B.substring(Te,rt()));let bt=v9(P.join(""));return[{kind:re.DocText,text:bt,...Ue(ee)}]}function Fle(){let P=rt();it(w.At);let B=TC("tag");switch(B.sv){case"param":return wC(P,B,re.DocParamTag,"param");case"template":return wC(P,B,re.DocTemplateTag,"templateParam");case"prop":return Cle(P,B);case"return":case"returns":return gE(P,B,re.DocReturnsTag);case"errors":return gE(P,B,re.DocErrorsTag);default:return gE(P,B,re.DocUnknownTag)}}function wC(P,B,ee,Te){let{name:Me,content:bt}=DC(Te);return{kind:ee,tagName:B,paramName:Me,content:bt,...Ue(P)}}function Cle(P,B){let{name:ee,content:Te}=DC("prop");return{kind:re.DocPropTag,tagName:B,propName:ee,content:Te,...Ue(P)}}function DC(P){let B=TC(P);Mle();let ee=hE();return{name:B,content:ee}}function Mle(){while(Mt(w.Whitespace));if(Mt(w.Hyphen))while(Mt(w.Whitespace));}function gE(P,B,ee){let Te=hE();return{kind:ee,tagName:B,content:Te,...Ue(P)}}function TC(P){if(P!=="tag")while(Mt(w.Whitespace));let B=rt(),ee;if(Ze()===w.Identifier)ee=Ua(),Qn();else if(Ze()===w.DocCodeSpan)ee=Ua(),Qn();else ee="",Jle({code:"doc-invalid-identifier",messageId:P});return{kind:re.Identifier,sv:ee,...Ue(B)}}function Ze(){return u.token}function dh(){return u.tokenFlags}function Ua(){return u.getTokenValue()}function rt(){return u.tokenPosition}function fh(){return u.position}function Qn(){return r=u.position,l===kb.Syntax?Lle():qle()}function Lle(){d=[];for(;;)if(u.scan(),p7(Ze())){if(!a&&Ze()===w.NewLine)break;let P=void 0;if(t.comments&&d7(Ze()))P={kind:Ze()===w.SingleLineComment?re.LineComment:re.BlockComment,pos:rt(),end:fh()},p.push(P);if(dh()&qt.DocComment)d.push({pos:rt(),end:fh(),comment:P})}else break}function qle(){u.scanDoc()}function Ule(P){u.reScanStringTemplate(P)}function Wc(){let P=rt();return r=P,s++,{kind:re.Identifier,sv:""+s,...Ue(P)}}function Ble(){let P=rt(),{items:B}=Qc();return{kind:re.TypeReference,target:Wc(),arguments:B,...Ue(P)}}function Ue(P){let B=n?Zi.ThisNodeHasError:Zi.None;return n=!1,Vle({pos:P,end:r,flags:B})}function Vle(P){return P}function Qc(P={pos:-1,end:-1}){return{items:[],range:P}}function Vi(P,B){let ee=Qc();if(P.open!==w.None){let Te=rt();if(it(P.open))Tn(ee.range).pos=Te}if(P.allowEmpty&&Mt(P.close))return Tn(ee.range).end=r,ee;while(!0){let Te=rt(),{pos:Me,docs:bt,directives:ht,decorators:jn}=m({skipParsingDocNodes:Boolean(P.invalidAnnotationTarget)});if(P.invalidAnnotationTarget)xi(jn,P.invalidAnnotationTarget),NC(ht,P.invalidAnnotationTarget);if(ht.length===0&&jn.length===0&&SC(P)){if(it(P.close))Tn(ee.range).end=r;break}let ar;if(P.invalidAnnotationTarget)ar=B();else ar=B(Me,jn),Tn(ar).docs=bt,Tn(ar).directives=ht;if(ee.items.push(ar),Kle(P)){if(Mt(P.close)){Tn(ee.range).end=r;break}continue}else if(P.close===w.None)break;else if(Mt(P.close)){Tn(ee.range).end=r;break}else if(SC(P)){if(it(P.close))Tn(ee.range).end=r;break}else it(P.delimiter);if(Te===rt()){if(it(P.close))Tn(ee.range).end=r;Qn(),ee.items.pop();break}}return ee}function x_(P,B){return Ze()===P.open?Vi(P,B):Qc()}function Kle(P){if(Mt(P.delimiter))return!0;if(Ze()===P.toleratedDelimiter){if(!P.toleratedDelimiterIsValid)it(P.delimiter);return Qn(),!0}return!1}function SC(P){return P.close!==w.None&&(qw(Ze())||Ze()===w.EndOfFile)&&Ze()!==P.allowedStatementKeyword}function EC(P){return it(w.Semicolon),{kind:re.EmptyStatement,...Ue(P)}}function bE(P,B){do Qn();while(!qw(Ze())&&Ze()!==w.At&&Ze()!==w.Semicolon&&Ze()!==w.EndOfFile);return an({code:"token-expected",messageId:"statement",target:{pos:P,end:r}}),{kind:re.InvalidStatement,decorators:B,...Ue(P)}}function an(P){n=!0;let B={file:u.file,pos:P.target?.pos??rt(),end:P.target?.end??fh()};if(!P.printable)o=!1;let ee=P.target?.realPos??B.pos;if(i===ee)return;i=ee;let Te=tn({...P,target:B});kC(Te.severity==="error","This function is for reporting errors. Use warning() for warnings."),c.push(Te)}function Jle(P){let B={file:u.file,pos:P.target?.pos??rt(),end:P.target?.end??fh()},ee=tn({...P,target:B});kC(ee.severity==="warning","This function is for reporting warnings only. Use error() for errors."),c.push(ee)}function Gle(P){if(P.severity==="error")n=!0,o=!1;c.push(P)}function kC(P,B){let ee={file:u.file,pos:rt(),end:fh()};Qe(P,B,ee)}function xi(P,B){for(let ee of P)an({code:"invalid-decorator-location",format:{nodeName:B},target:ee})}function NC(P,B){for(let ee of P)an({code:"invalid-directive-location",format:{nodeName:B},target:ee})}function it(P){if(Ze()===P)return Qn(),!0;let B=PC(P);return an({code:"token-expected",format:{token:ab[P]},target:B,printable:Lw(P)}),!1}function mh(...P){let B=Ze();for(let ee of P){if(ee===w.None)continue;if(B===ee)return B}return Hle(...P),w.None}function OC(...P){let B=mh(...P);if(B!==w.None)Qn();return B}function Hle(...P){let B=PC(P[0]),ee=P.map((Te,Me)=>{if(Me===P.length-1)return`or ${ab[Te]}`;return ab[Te]});an({code:"token-expected",format:{token:ee.join(", ")},target:B})}function Mt(P){if(Ze()===P)return Qn(),!0;return!1}function PC(P){return Lw(P)?{pos:r,end:r+1,realPos:rt()}:void 0}}function XP(e){return e.kind===re.TypeReference&&e.target.kind===re.Identifier&&e.arguments.length===0}function g5(e){if(e.kind!==re.NamespaceStatement)return!1;while(!Tm(e.statements)&&e.statements)e=e.statements;return e.statements===void 0}var Pr,kb;var Zs=q(()=>{Gt();rc();_t();Yn();YP();ub();It();(function(e){let t={allowEmpty:!0,toleratedDelimiterIsValid:!0,allowedStatementKeyword:w.None};e.OperationParameters={...t,open:w.OpenParen,close:w.CloseParen,delimiter:w.Comma,toleratedDelimiter:w.Semicolon},e.DecoratorArguments={...e.OperationParameters,invalidAnnotationTarget:"expression"},e.FunctionArguments={...e.OperationParameters,invalidAnnotationTarget:"expression"},e.ModelProperties={...t,open:w.OpenBrace,close:w.CloseBrace,delimiter:w.Semicolon,toleratedDelimiter:w.Comma},e.ObjectLiteralProperties={...t,open:w.HashBrace,close:w.CloseBrace,delimiter:w.Comma,toleratedDelimiter:w.Comma},e.InterfaceMembers={...t,open:w.OpenBrace,close:w.CloseBrace,delimiter:w.Semicolon,toleratedDelimiter:w.Comma,toleratedDelimiterIsValid:!1,allowedStatementKeyword:w.OpKeyword},e.ScalarMembers={...t,open:w.OpenBrace,close:w.CloseBrace,delimiter:w.Semicolon,toleratedDelimiter:w.Comma,toleratedDelimiterIsValid:!1,allowedStatementKeyword:w.InitKeyword},e.UnionVariants={...t,open:w.OpenBrace,close:w.CloseBrace,delimiter:w.Semicolon,toleratedDelimiter:w.Comma,toleratedDelimiterIsValid:!0},e.EnumMembers={...e.ModelProperties};let n={allowEmpty:!0,delimiter:w.Comma,toleratedDelimiter:w.Semicolon,toleratedDelimiterIsValid:!1,invalidAnnotationTarget:"expression",allowedStatementKeyword:w.None};e.TemplateParameters={...n,allowEmpty:!1,open:w.LessThan,close:w.GreaterThan,invalidAnnotationTarget:"template parameter"},e.TemplateArguments={...e.TemplateParameters},e.CallArguments={...n,allowEmpty:!0,open:w.OpenParen,close:w.CloseParen},e.Heritage={...n,allowEmpty:!1,open:w.None,close:w.None},e.Tuple={...n,allowEmpty:!0,open:w.OpenBracket,close:w.CloseBracket},e.ArrayLiteral={...n,allowEmpty:!0,open:w.HashBracket,close:w.CloseBracket},e.FunctionParameters={...n,allowEmpty:!0,open:w.OpenParen,close:w.CloseParen,invalidAnnotationTarget:"expression"}})(Pr||(Pr={}));(function(e){e[e.Syntax=0]="Syntax",e[e.Doc=1]="Doc"})(kb||(kb={}))});var Ku=q(()=>{Gt();_t();Hg();ic();Zs();It()});var b5=q(()=>{_t()});var v5=q(()=>{_t();It()});var e$=q(()=>{_t();Yn();yr()});var _5;var t$=q(()=>{ac();_5={int64:[kn("-9223372036854775808"),kn("9223372036854775807"),{int:!0,isJsNumber:!1}],int32:[kn("-2147483648"),kn("2147483647"),{int:!0,isJsNumber:!0}],int16:[kn("-32768"),kn("32767"),{int:!0,isJsNumber:!0}],int8:[kn("-128"),kn("127"),{int:!0,isJsNumber:!0}],uint64:[kn("0"),kn("18446744073709551615"),{int:!0,isJsNumber:!1}],uint32:[kn("0"),kn("4294967295"),{int:!0,isJsNumber:!0}],uint16:[kn("0"),kn("65535"),{int:!0,isJsNumber:!0}],uint8:[kn("0"),kn("255"),{int:!0,isJsNumber:!0}],safeint:[kn(Number.MIN_SAFE_INTEGER.toString()),kn(Number.MAX_SAFE_INTEGER.toString()),{int:!0,isJsNumber:!0}],float32:[kn("-3.4e38"),kn("3.4e38"),{int:!1,isJsNumber:!0}],float64:[kn(`${-Number.MAX_VALUE}`),kn(Number.MAX_VALUE.toString()),{int:!1,isJsNumber:!0}]}});var x5=q(()=>{ka();_t();t$();ac()});var w5;var D5=q(()=>{Gt();Eb();_t();cc();lc();Yn();t$();yr();It();(function(e){e[e.false=0]="false",e[e.true=1]="true",e[e.maybe=2]="maybe"})(w5||(w5={}))});function kEe(e){if(!e.sourceProperty)return;let t=new Set;for(let n=e;n;n=n.sourceProperty)if(n.model?.name)t.add(n.model);return t}function NEe(e,t){for(let n of t)if(!e.has(n)){for(let r=n.baseModel;r;r=r.baseModel)if(e.has(r)){e.add(n);break}}}function Sb(e,t,n){if(n)t=kD(e,t,n);if(t.name)return t;if(Qe(!t.baseModel,"Anonymous model with base model."),t.properties.size===0)return t;let r;for(let s of t.properties.values()){let o=kEe(s);if(!o)return t;if(!r){r=o;continue}NEe(o,r);for(let a of r)if(!o.has(a))r.delete(a)}let i;for(let s of r??[]){if(t.properties.size===T5(s)){i=s;break}if(n&&!i&&t.properties.size===T5(s,n)){i=s;continue}}return i??t}function kD(e,t,n){let r=!1;for(let a of eo(t))if(!n(a)){r=!0;break}if(!r)return t;let i=Ws.realmForType.get(t),s=i?Kn(i):Kn(e),o=s.model.create({name:"",indexer:void 0,properties:{},decorators:[],derivedModels:[],sourceModels:[{usage:"spread",model:t}]});for(let a of eo(t))if(n(a)){let l=s.type.clone(a);Object.assign(l,{sourceProperty:a,model:o}),o.properties.set(a.name,l),s.type.finishType(l)}return e.checker.finishType(o)}function*eo(e){let t=new Set;for(let n=e;n;n=n.baseModel)for(let r of n.properties.values()){if(t.has(r.name))continue;t.add(r.name),yield r}}function T5(e,t){let n=0;for(let r of eo(e))if(!t||t(r))n++;return n}var ED,mc,S5;var Eb=q(()=>{Id();nP();ka();Gt();YO();Ku();b5();v5();sb();_t();Hg();Bm();ic();e$();Lu();cc();x5();Yn();YP();ac();Zs();D5();yr();It();(function(e){e[e.None=0]="None",e[e.InTemplateDeclaration=1]="InTemplateDeclaration"})(ED||(ED={}));mc=class mc{mapper;flags;#e;static from(e){if(e instanceof mc)return e;return new mc(e,ED.None)}static DEFAULT=new mc(void 0,ED.None);constructor(e,t,n){this.mapper=e,this.flags=t,this.#e=n,Object.freeze(this)}withFlags(e){return new mc(this.mapper,this.flags|e,this.#e)}maskFlags(e){return new mc(this.mapper,this.flags&~e,this.#e)}hasFlags(e){return(this.flags&e)===e}withMapper(e){return new mc(e,this.flags,this.#e)}observeTemplateParameter(e){this.#e?.add(e)}enterTemplateObserverScope(){return new mc(this.mapper,this.flags,new Set)}exitTemplateObserverScope(){return new mc(this.mapper,this.flags,void 0)}hasObservedTemplateParameters(){return this.#e!==void 0?this.#e.size>0:!1}};(function(e){e[e.Value=0]="Value",e[e.Type=1]="Type",e[e.BaseType=2]="BaseType",e[e.Constraint=3]="Constraint"})(S5||(S5={}))});var E5;var i$=q(()=>{mn();E5=Symbol.for("TYPESPEC_EMITTED_FILES_PATHS");if(globalThis[E5]===void 0)globalThis[E5]=new WeakMap});var dl;var k5=q(()=>{dl={fromPackageRoot(e){return{kind:"file-ref",path:e}}}});function FEe(e,t,n){return jEe.diff(e,t,n)}function UEe(e){let t=e.indexOf(h$);return t!==-1?e.charAt(t+1)===AD?nK:tK:LEe}function g$(e){return e===tK?h$:e===nK?rK:qEe}function iK(e,t){let n=BEe.get(t);return e.match(n)?.length??0}function KEe(e){return ID(0,e,VEe,AD)}function JEe(e){return this[e<0?this.length+e:e]}function HEe(e){let t=e.length;for(;t>0&&(e[t-1]==="\r"||e[t-1]===` +`);)t--;return t`'${i}'`));return`Unexpected doc.type '${e.type}'. +Expected it to be ${r}.`}function XEe(e,t,n,r){let i=[e];for(;i.length>0;){let s=i.pop();if(s===N5){n(i.pop());continue}n&&i.push(s,N5);let o=Jd(s);if(!o)throw new ry(s);if(t?.(s)!==!1)switch(o){case gc:case hl:{let a=o===gc?s:s.parts;for(let l=a.length,c=l-1;c>=0;--c)i.push(a[c]);break}case to:i.push(s.flatContents,s.breakContents);break;case Ps:if(r&&s.expandedStates)for(let a=s.expandedStates.length,l=a-1;l>=0;--l)i.push(s.expandedStates[l]);else i.push(s.contents);break;case vc:case bc:case xc:case gl:case wc:i.push(s.contents);break;case Kd:case zu:case _c:case Dc:case hi:case Jo:break;default:throw new ry(s)}}}function jD(e,t){if(typeof e=="string")return t(e);let n=new Map;return r(e);function r(s){return b$(n,s,i)}function i(s){switch(Jd(s)){case gc:return t(s.map(r));case hl:return t({...s,parts:s.parts.map(r)});case to:return t({...s,breakContents:r(s.breakContents),flatContents:r(s.flatContents)});case Ps:{let{expandedStates:o,contents:a}=s;return o?(o=o.map(r),a=o[0]):a=r(a),t({...s,contents:a,expandedStates:o})}case vc:case bc:case xc:case gl:case wc:return t({...s,contents:r(s.contents)});case Kd:case zu:case _c:case Dc:case hi:case Jo:return t(s);default:throw new ry(s)}}}function _$(e,t,n){let r=n,i=!1;function s(o){if(i)return!1;let a=t(o);a!==void 0&&(i=!0,r=a)}return v$(e,s),r}function ZEe(e){if(e.type===Ps&&e.break||e.type===hi&&e.hard||e.type===Jo)return!0}function eke(e){return _$(e,ZEe,!1)}function O5(e){if(e.length>0){let t=yi(0,e,-1);!t.expandedStates&&!t.break&&(t.break="propagated")}return null}function tke(e){let t=new Set,n=[];function r(s){if(s.type===Jo&&O5(n),s.type===Ps){if(n.push(s),t.has(s))return!1;t.add(s)}}function i(s){s.type===Ps&&n.pop().break&&O5(n)}v$(e,r,i,!0)}function nke(e){return e.type===hi&&!e.hard?e.soft?"":" ":e.type===to?e.flatContents:e}function rke(e){return jD(e,nke)}function P5(e){for(e=[...e];e.length>=2&&yi(0,e,-2).type===hi&&yi(0,e,-1).type===Jo;)e.length-=2;if(e.length>0){let t=Ob(yi(0,e,-1));e[e.length-1]=t}return e}function Ob(e){switch(Jd(e)){case bc:case xc:case Ps:case wc:case gl:{let t=Ob(e.contents);return{...e,contents:t}}case to:return{...e,breakContents:Ob(e.breakContents),flatContents:Ob(e.flatContents)};case hl:return{...e,parts:P5(e.parts)};case gc:return P5(e);case Kd:return HEe(e);case vc:case zu:case _c:case Dc:case hi:case Jo:break;default:throw new ry(e)}return e}function oK(e){return Ob(ske(e))}function ike(e){switch(Jd(e)){case hl:{let{parts:t}=e;if(t.every((n)=>n===""))return"";if(t.length===1)return t[0];break}case Ps:if(!e.contents&&!e.id&&!e.break&&!e.expandedStates)return"";if(e.contents.type===Ps&&e.contents.id===e.id&&e.contents.break===e.break&&e.contents.expandedStates===e.expandedStates)return e.contents;break;case vc:case bc:case xc:case wc:if(!e.contents)return"";break;case to:if(!e.flatContents&&!e.breakContents)return"";break;case gc:{let t=[];for(let n of e){if(!n)continue;let[r,...i]=Array.isArray(n)?n:[n];typeof r=="string"&&typeof yi(0,t,-1)=="string"?t[t.length-1]+=r:t.push(r),t.push(...i)}return t.length===0?"":t.length===1?t[0]:t}case Kd:case zu:case _c:case Dc:case hi:case gl:case Jo:break;default:throw new ry(e)}return e}function ske(e){return jD(e,(t)=>ike(t))}function oke(e,t=mK){return jD(e,(n)=>typeof n=="string"?pK(t,n.split(` +`)):n)}function ake(e){if(e.type===hi)return!0}function lke(e){return _$(e,ake,!1)}function OD(e,t){return e.type===gl?{...e,contents:t(e.contents)}:t(e)}function $D(e){return yl(e),{type:bc,contents:e}}function iy(e,t){return uke(e),yl(t),{type:vc,contents:t,n:e}}function pke(e){return iy(Number.NEGATIVE_INFINITY,e)}function lK(e){return iy({type:"root"},e)}function dke(e){return iy(-1,e)}function cK(e,t,n){yl(e);let r=e;if(t>0){for(let i=0;i0?`, { ${l.join(", ")} }`:"";return`indentIfBreak(${r(s.contents)}${c})`}if(s.type===Ps){let l=[];s.break&&s.break!=="propagated"&&l.push("shouldBreak: true"),s.id&&l.push(`id: ${i(s.id)}`);let c=l.length>0?`, { ${l.join(", ")} }`:"";return s.expandedStates?`conditionalGroup([${s.expandedStates.map((u)=>r(u)).join(",")}]${c})`:`group(${r(s.contents)}${c})`}if(s.type===hl)return`fill([${s.parts.map((l)=>r(l)).join(", ")}])`;if(s.type===wc)return"lineSuffix("+r(s.contents)+")";if(s.type===Dc)return"lineSuffixBoundary";if(s.type===gl)return`label(${JSON.stringify(s.label)}, ${r(s.contents)})`;if(s.type===zu)return"cursor";throw Error("Unknown doc type "+s.type)}function i(s){if(typeof s!="symbol")return JSON.stringify(String(s));if(s in t)return t[s];let o=s.description||"symbol";for(let a=0;;a++){let l=o+(a>0?` #${a}`:"");if(!n.has(l))return n.add(l),t[s]=`Symbol.for(${JSON.stringify(l)})`}}}function Pke(e){let t=e[0],n=e[1];for(let r=0;r=i&&$5<=s)return[i,s];s-i>n-t&&(t=i,n=s)}return[t,n]}function Fke(e){if(!e)return 0;if(!jke.test(e))return e.length;let t=0;e=e.replace(wke(),(n)=>(t+=Rke(n)?1:2,""));for(let n of e){let r=n.codePointAt(0);r<=31||r>=127&&r<=159||r>=768&&r<=879||r>=65024&&r<=65039||(t+=$ke(r)||Ike(r)?2:1)}return t}function bK(e,t,n){let r=t.type===1?e.queue.slice(0,-1):[...e.queue,t],i="",s=0,o=0,a=0;for(let m of r)switch(m.type){case 0:u(),n.useTabs?l(1):c(n.tabWidth);break;case 3:{let{string:y}=m;u(),i+=y,s+=y.length;break}case 2:{let{width:y}=m;o+=1,a+=y;break}default:throw Error(`Unexpected indent comment '${m.type}'.`)}return d(),{...e,value:i,length:s,queue:r};function l(m){i+="\t".repeat(m),s+=n.tabWidth*m}function c(m){i+=" ".repeat(m),s+=m}function u(){n.useTabs?p():d()}function p(){o>0&&l(o),f()}function d(){a>0&&c(a),f()}function f(){o=0,a=0}}function Lke(e,t,n){if(!t)return e;if(t.type==="root")return{...e,root:e};if(t===Number.NEGATIVE_INFINITY)return e.root;let r;return typeof t=="number"?t<0?r=Mke:r={type:2,width:t}:r={type:3,string:t},bK(e,r,n)}function qke(e,t){return bK(e,Cke,t)}function Uke(e){let t=0;for(let n=e.length-1;n>=0;n--){let r=e[n];if(r===" "||r==="\t")t++;else break}return t}function vK(e){let t=Uke(e);return{text:t===0?e:e.slice(0,e.length-t),count:t}}function ND(e,t,n,r,i,s){if(n===Number.POSITIVE_INFINITY)return!0;let o=t.length,a=!1,l=[e],c="";for(;n>=0;){if(l.length===0){if(o===0)return!0;l.push(t[--o]);continue}let{mode:u,doc:p}=l.pop(),d=Jd(p);switch(d){case Kd:p&&(a&&(c+=" ",n-=1,a=!1),c+=p,n-=w$(p));break;case gc:case hl:{let f=d===gc?p:p.parts,m=p[d$]??0;for(let y=f.length-1;y>=m;y--)l.push({mode:u,doc:f[y]});break}case bc:case vc:case xc:case gl:l.push({mode:u,doc:p.contents});break;case _c:{let{text:f,count:m}=vK(c);c=f,n+=m;break}case Ps:{if(s&&p.break)return!1;let f=p.break?Ko:u,m=p.expandedStates&&f===Ko?yi(0,p.expandedStates,-1):p.contents;l.push({mode:f,doc:m});break}case to:{let f=(p.groupId?i[p.groupId]||fl:u)===Ko?p.breakContents:p.flatContents;f&&l.push({mode:u,doc:f});break}case hi:if(u===Ko||p.hard)return!0;p.soft||(a=!0);break;case wc:r=!0;break;case Dc:if(r)return!1;break}}return!1}function CD(e,t){let n=Object.create(null),r=t.printWidth,i=g$(t.endOfLine),s=0,o=[{indent:gK,mode:Ko,doc:e}],a=!1,l=[],c=new Vke;for(tke(e);o.length>0;){let{indent:m,mode:y,doc:h}=o.pop();switch(Jd(h)){case Kd:{let b=i!==` `?ID(0,h,` -`,i):h;b&&(c.write(b),o.length>0&&(s+=w$(b)));break}case gc:for(let b=h.length-1;b>=0;b--)o.push({indent:m,mode:y,doc:h[b]});break;case Hu:c.markPosition();break;case bc:o.push({indent:Lke(m,t),mode:y,doc:h.contents});break;case vc:o.push({indent:Mke(m,h.n,t),mode:y,doc:h.contents});break;case _c:s-=c.trim();break;case Os:{let b=function(){if(y===fl&&!a)return{indent:m,mode:h.break?Ko:fl,doc:h.contents};a=!1;let g=r-s,x=l.length>0,v={indent:m,mode:fl,doc:h.contents};if(!h.break&&ND(v,o,g,x,n))return v;if(!h.expandedStates)return{indent:m,mode:Ko,doc:h.contents};if(!h.break)for(let D=1;D0,n,!0);if(v===1){C?o.push(N):o.push(O);break}let X={indent:m,mode:fl,doc:T},te={indent:m,mode:Ko,doc:T};if(v===2){C?o.push(X,N):o.push(te,O);break}let L=x[g+2],Y={indent:m,mode:y,doc:{...h,[d$]:g+2}},me=ND({indent:m,mode:fl,doc:[D,T,L]},[],b,l.length>0,n,!0);o.push(Y),me?o.push(X,N):C?o.push(te,N):o.push(te,O);break}case eo:case xc:{let b=h.groupId?n[h.groupId]:y;if(b===Ko){let g=h.type===eo?h.breakContents:h.negate?h.contents:$D(h.contents);g&&o.push({indent:m,mode:y,doc:g})}if(b===fl){let g=h.type===eo?h.flatContents:h.negate?$D(h.contents):h.contents;g&&o.push({indent:m,mode:y,doc:g})}break}case wc:l.push({indent:m,mode:y,doc:h.contents});break;case Dc:l.length>0&&o.push({indent:m,mode:y,doc:x$});break;case yi:switch(y){case fl:if(!h.hard){h.soft||(c.write(" "),s+=1);break}a=!0;case Ko:if(l.length>0){o.push({indent:m,mode:y,doc:h},...l.reverse()),l.length=0;break}h.literal?(c.write(i),s=0,m.root&&(m.root.value&&c.write(m.root.value),s=m.root.length)):(c.trim(),c.write(i+m.value),s=m.length);break}break;case gl:o.push({indent:m,mode:y,doc:h.contents});break;case Jo:break;default:throw new ty(h)}o.length===0&&l.length>0&&(o.push(...l.reverse()),l.length=0)}let{text:u,positions:p}=c.finish();if(p.length!==2)return{formatted:u};let[d,f]=p;return{formatted:u,cursorNodeStart:d,cursorNodeText:u.slice(d,f)}}function Vke(e,t,n=0){let r=0;for(let i=n;i0}function Hke(e){return e!==null&&typeof e=="object"}function Ab(e){return(t,n,r)=>{if(n===!1)return!1;let i=!!r?.backwards,{length:s}=t,o=n;for(;o>=0&&o0&&(s+=w$(b)));break}case gc:for(let b=h.length-1;b>=0;b--)o.push({indent:m,mode:y,doc:h[b]});break;case zu:c.markPosition();break;case bc:o.push({indent:qke(m,t),mode:y,doc:h.contents});break;case vc:o.push({indent:Lke(m,h.n,t),mode:y,doc:h.contents});break;case _c:s-=c.trim();break;case Ps:{let b=function(){if(y===fl&&!a)return{indent:m,mode:h.break?Ko:fl,doc:h.contents};a=!1;let g=r-s,x=l.length>0,v={indent:m,mode:fl,doc:h.contents};if(!h.break&&ND(v,o,g,x,n))return v;if(!h.expandedStates)return{indent:m,mode:Ko,doc:h.contents};if(!h.break)for(let D=1;D0,n,!0);if(v===1){C?o.push(N):o.push(O);break}let X={indent:m,mode:fl,doc:T},te={indent:m,mode:Ko,doc:T};if(v===2){C?o.push(X,N):o.push(te,O);break}let L=x[g+2],Y={indent:m,mode:y,doc:{...h,[d$]:g+2}},me=ND({indent:m,mode:fl,doc:[D,T,L]},[],b,l.length>0,n,!0);o.push(Y),me?o.push(X,N):C?o.push(te,N):o.push(te,O);break}case to:case xc:{let b=h.groupId?n[h.groupId]:y;if(b===Ko){let g=h.type===to?h.breakContents:h.negate?h.contents:$D(h.contents);g&&o.push({indent:m,mode:y,doc:g})}if(b===fl){let g=h.type===to?h.flatContents:h.negate?$D(h.contents):h.contents;g&&o.push({indent:m,mode:y,doc:g})}break}case wc:l.push({indent:m,mode:y,doc:h.contents});break;case Dc:l.length>0&&o.push({indent:m,mode:y,doc:x$});break;case hi:switch(y){case fl:if(!h.hard){h.soft||(c.write(" "),s+=1);break}a=!0;case Ko:if(l.length>0){o.push({indent:m,mode:y,doc:h},...l.reverse()),l.length=0;break}h.literal?(c.write(i),s=0,m.root&&(m.root.value&&c.write(m.root.value),s=m.root.length)):(c.trim(),c.write(i+m.value),s=m.length);break}break;case gl:o.push({indent:m,mode:y,doc:h.contents});break;case Jo:break;default:throw new ry(h)}o.length===0&&l.length>0&&(o.push(...l.reverse()),l.length=0)}let{text:u,positions:p}=c.finish();if(p.length!==2)return{formatted:u};let[d,f]=p;return{formatted:u,cursorNodeStart:d,cursorNodeText:u.slice(d,f)}}function Kke(e,t,n=0){let r=0;for(let i=n;i0}function zke(e){return e!==null&&typeof e=="object"}function Ab(e){return(t,n,r)=>{if(n===!1)return!1;let i=!!r?.backwards,{length:s}=t,o=n;for(;o>=0&&o!0}=t,i=(s)=>T$(s)&&r(s);for(let s of n(e)){let o=e[s];if(Array.isArray(o))for(let a of o)i(a)&&(yield a);else i(o)&&(yield o)}}function*Yke(e,t){let n=[e];for(let r=0;r(i??(i=[e,...t]),r(l,i)?[l]:DK(l,i,n))),{locStart:o,locEnd:a}=n;return s.sort((l,c)=>o(l)-o(c)||a(l)-a(c)),s}function DK(e,t,n){return b$(n.cache,e,(r)=>Zke(r,t,n))}function e1e(e){let t=e.type||e.kind||"(unknown type)",n=String(e.name||e.id&&(typeof e.id=="object"?e.id.name:e.id)||e.key&&(typeof e.key=="object"?e.key.name:e.key)||e.value&&(typeof e.value=="object"?"":String(e.value))||e.operator||"");return n.length>20&&(n=n.slice(0,19)+"…"),t+(n?" "+n:"")}function S$(e,t){(e.comments??(e.comments=[])).push(t),t.printed=!1,t.nodeDescription=e1e(e)}function Pb(e,t){t.leading=!0,t.trailing=!1,S$(e,t)}function Md(e,t,n){t.leading=!1,t.trailing=!1,n&&(t.marker=n),S$(e,t)}function $b(e,t){t.leading=!1,t.trailing=!0,S$(e,t)}function EK(e,t,n,r,i=[]){let{locStart:s,locEnd:o}=n,a=s(t),l=o(t),c=TK(e,i,{cache:SK,locStart:s,locEnd:o,getVisitorKeys:n.getVisitorKeys,filter:n.printer.canAttachComment,getChildren:n.printer.getCommentChildNodes}),u,p,d=0,f=c.length;for(;d>1,y=c[m],h=s(y),b=o(y);if(h<=a&&l<=b)return EK(y,t,n,y,[y,...i]);if(b<=a){u=y,d=m+1;continue}if(l<=h){p=y,f=m;continue}throw Error("Comment location overlaps with node location")}if(r?.type==="TemplateLiteral"){let{quasis:m}=r,y=o$(m,t,n);u&&o$(m,u,n)!==y&&(u=null),p&&o$(m,p,n)!==y&&(p=null)}return{enclosingNode:r,precedingNode:u,followingNode:p}}function t1e(e,t){let{comments:n}=e;if(delete e.comments,!_K(n)||!t.printer.canAttachComment)return;let r=[],{printer:{features:{experimental_avoidAstMutation:i},handleComments:s={}},originalText:o}=t,{ownLine:a=s$,endOfLine:l=s$,remaining:c=s$}=s,u=n.map((d,f)=>({...EK(e,d,t),comment:d,text:o,options:t,ast:e,isLastComment:n.length-1===f,placement:void 0})),p=!i;for(let[d,f]of u.entries()){let{comment:m,precedingNode:y,enclosingNode:h,followingNode:b,text:g,options:x,ast:v,isLastComment:D}=f,T=n1e(g,x,u,d)?"ownLine":r1e(g,x,u,d)?"endOfLine":"remaining",N;if(i?(f.placement=T,N=[f]):N=[m,g,x,v,D],p&&(m.enclosingNode=h,m.precedingNode=y,m.followingNode=b),m.placement=T,T==="ownLine")a(...N)||(b?Pb(b,m):y?$b(y,m):h?Md(h,m):Md(v,m));else if(T==="endOfLine")l(...N)||(y?$b(y,m):b?Pb(b,m):h?Md(h,m):Md(v,m));else if(!c(...N))if(y&&b){let O=r.length;O>0&&r[O-1].followingNode!==b&&A5(r,x),r.push(f)}else y?$b(y,m):b?Pb(b,m):h?Md(h,m):Md(v,m)}if(A5(r,t),p)for(let d of n)delete d.precedingNode,delete d.enclosingNode,delete d.followingNode}function n1e(e,t,n,r){let{comment:i,precedingNode:s}=n[r],{locStart:o,locEnd:a}=t,l=o(i);if(s)for(let c=r-1;c>=0;c--){let{comment:u,precedingNode:p}=n[c];if(p!==s||!kK(e.slice(a(u),l)))break;l=o(u)}return Ku(e,l,{backwards:!0})}function r1e(e,t,n,r){let{comment:i,followingNode:s}=n[r],{locStart:o,locEnd:a}=t,l=a(i);if(s)for(let c=r+1;c0;--o){let{comment:a,precedingNode:l,followingNode:c}=e[o-1];Ju(l,r),Ju(c,i);let u=t.originalText.slice(t.locEnd(a),s);if(t.printer.isGap?.(u,t)??/^[\s(]*$/.test(u))s=t.locStart(a);else break}for(let[a,{comment:l}]of e.entries())a1&&a.comments.sort((l,c)=>t.locStart(l)-t.locStart(c));e.length=0}function o$(e,t,n){let r=n.locStart(t)-1;for(let i=1;i!r?.has(o)&&o.leading&&i(o)));return s.size===0?"":e.map(({node:o})=>s.has(o)?s1e(e,t):"","comments").filter(Boolean)}function l1e(e,t,n){let r=e.node?.comments,i=new Set(r?.filter((u)=>u.trailing)),s=t[Symbol.for("printedComments")],o=n?.filter??NK,a=new Set(r?.filter((u)=>i.has(u)&&!s?.has(u)&&o(u)));if(a.size===0)return"";let l=[],c;return e.each(({node:u})=>{i.has(u)&&(c=o1e(e,t,c),a.has(u)&&l.push(c.doc))},"comments"),l}function c1e(e,t,n,r){let i=a1e(e,n,r),s=l1e(e,n,r);return i||s?OD(t,(o)=>[i,o,s]):t}function u1e(e){let{[RD]:t,[Symbol.for("printedComments")]:n}=e;for(let r of t){if(!r.printed&&!n.has(r))throw Error('Comment "'+r.value.trim()+'" was not printed. Please report this error!');delete r.printed}}function $K({plugins:e=[],showDeprecated:t=!1}={}){let n=e.flatMap((i)=>i.languages??[]),r=[];for(let i of y1e(Object.assign({},...e.map(({options:s})=>s),f1e)))!t&&i.deprecated||(Array.isArray(i.choices)&&(t||(i.choices=i.choices.filter((s)=>!s.deprecated)),i.name==="parser"&&(i.choices=[...i.choices,...m1e(i.choices,n,e)])),i.pluginDefaults=Object.fromEntries(e.filter((s)=>s.defaultOptions?.[i.name]!==void 0).map((s)=>[s.name,s.defaultOptions[i.name]])),r.push(i));return{languages:n,options:r}}function*m1e(e,t,n){let r=new Set(e.map((i)=>i.value));for(let i of t)if(i.parsers){for(let s of i.parsers)if(!r.has(s)){r.add(s);let o=n.find((l)=>l.parsers&&LD(l.parsers,s)),a=i.name;o?.name&&(a+=` (plugin: ${o.name})`),yield{value:s,description:a}}}}function y1e(e){let t=[];for(let[n,r]of Object.entries(e)){let i={name:n,...r};Array.isArray(i.default)&&(i.default=mi(0,i.default,-1).value),t.push(i)}return t}function v1e(){let e=globalThis,t=e.process?.platform;if(typeof t=="string")return t.startsWith("win");let n=e.Deno?.build?.os;return typeof n=="string"?n==="windows":e.navigator?.platform?.startsWith("Win")??!1}function IK(e){if(e=e instanceof URL?e:new URL(e),e.protocol!=="file:")throw TypeError(`URL must be a file URL: received "${e.protocol}"`);return e}function x1e(e){return e=IK(e),decodeURIComponent(e.pathname.replace(/%(?![0-9A-Fa-f]{2})/g,"%25"))}function w1e(e){e=IK(e);let t=decodeURIComponent(e.pathname.replace(/\//g,"\\").replace(/%(?![0-9A-Fa-f]{2})/g,"%25")).replace(/^\\*([A-Za-z]:)(\\|$)/,"$1\\");return e.hostname!==""&&(t=`\\\\${e.hostname}${t}`),t}function D1e(e){return _1e?w1e(e):x1e(e)}function j5(e,t){if(!t)return;let n=T1e(t).toLowerCase();return e.find(({filenames:r})=>r?.some((i)=>i.toLowerCase()===n))??e.find(({extensions:r})=>r?.some((i)=>n.endsWith(i)))}function E1e(e,t){if(t)return e.find(({name:n})=>n.toLowerCase()===t)??e.find(({aliases:n})=>n?.includes(t))??e.find(({extensions:n})=>n?.includes(`.${t}`))}function F5(e,t){if(t){if(S1e(t))try{t=D1e(t)}catch{return}if(typeof t=="string")return e.find(({isSupported:n})=>n?.({filepath:t}))}}function N1e(e,t){let n=b1e(0,e.plugins).flatMap((r)=>r.languages??[]);return(E1e(n,t.language)??j5(n,t.physicalFile)??j5(n,t.file)??F5(n,t.physicalFile)??F5(n,t.file)??k1e?.(n,t.physicalFile))?.parsers[0]}function M5(e,t,n,r){return[`Invalid ${ml.red(r.key(e))} value.`,`Expected ${ml.blue(n)},`,`but received ${t===jK?ml.gray("nothing"):ml.red(r.value(t))}.`].join(" ")}function FK({text:e,list:t},n){let r=[];return e&&r.push(`- ${ml.blue(e)}`),t&&r.push([`- ${ml.blue(t.title)}:`].concat(t.values.map((i)=>FK(i,n-C5.length).replace(/^|\n/g,`$&${C5}`))).join(` +`)return t+2;if(I5(i))return t+1}return t}function Yke(e,t,n={}){let r=Hu(e,n.backwards?t-1:t,n),i=Vd(e,r,n);return r!==i}function*MD(e,t){let{getVisitorKeys:n,filter:r=()=>!0}=t,i=(s)=>T$(s)&&r(s);for(let s of n(e)){let o=e[s];if(Array.isArray(o))for(let a of o)i(a)&&(yield a);else i(o)&&(yield o)}}function*Xke(e,t){let n=[e];for(let r=0;r(i??(i=[e,...t]),r(l,i)?[l]:DK(l,i,n))),{locStart:o,locEnd:a}=n;return s.sort((l,c)=>o(l)-o(c)||a(l)-a(c)),s}function DK(e,t,n){return b$(n.cache,e,(r)=>e1e(r,t,n))}function t1e(e){let t=e.type||e.kind||"(unknown type)",n=String(e.name||e.id&&(typeof e.id=="object"?e.id.name:e.id)||e.key&&(typeof e.key=="object"?e.key.name:e.key)||e.value&&(typeof e.value=="object"?"":String(e.value))||e.operator||"");return n.length>20&&(n=n.slice(0,19)+"…"),t+(n?" "+n:"")}function S$(e,t){(e.comments??(e.comments=[])).push(t),t.printed=!1,t.nodeDescription=t1e(e)}function Pb(e,t){t.leading=!0,t.trailing=!1,S$(e,t)}function qd(e,t,n){t.leading=!1,t.trailing=!1,n&&(t.marker=n),S$(e,t)}function $b(e,t){t.leading=!1,t.trailing=!0,S$(e,t)}function EK(e,t,n,r,i=[]){let{locStart:s,locEnd:o}=n,a=s(t),l=o(t),c=TK(e,i,{cache:SK,locStart:s,locEnd:o,getVisitorKeys:n.getVisitorKeys,filter:n.printer.canAttachComment,getChildren:n.printer.getCommentChildNodes}),u,p,d=0,f=c.length;for(;d>1,y=c[m],h=s(y),b=o(y);if(h<=a&&l<=b)return EK(y,t,n,y,[y,...i]);if(b<=a){u=y,d=m+1;continue}if(l<=h){p=y,f=m;continue}throw Error("Comment location overlaps with node location")}if(r?.type==="TemplateLiteral"){let{quasis:m}=r,y=o$(m,t,n);u&&o$(m,u,n)!==y&&(u=null),p&&o$(m,p,n)!==y&&(p=null)}return{enclosingNode:r,precedingNode:u,followingNode:p}}function n1e(e,t){let{comments:n}=e;if(delete e.comments,!_K(n)||!t.printer.canAttachComment)return;let r=[],{printer:{features:{experimental_avoidAstMutation:i},handleComments:s={}},originalText:o}=t,{ownLine:a=s$,endOfLine:l=s$,remaining:c=s$}=s,u=n.map((d,f)=>({...EK(e,d,t),comment:d,text:o,options:t,ast:e,isLastComment:n.length-1===f,placement:void 0})),p=!i;for(let[d,f]of u.entries()){let{comment:m,precedingNode:y,enclosingNode:h,followingNode:b,text:g,options:x,ast:v,isLastComment:D}=f,T=r1e(g,x,u,d)?"ownLine":i1e(g,x,u,d)?"endOfLine":"remaining",N;if(i?(f.placement=T,N=[f]):N=[m,g,x,v,D],p&&(m.enclosingNode=h,m.precedingNode=y,m.followingNode=b),m.placement=T,T==="ownLine")a(...N)||(b?Pb(b,m):y?$b(y,m):h?qd(h,m):qd(v,m));else if(T==="endOfLine")l(...N)||(y?$b(y,m):b?Pb(b,m):h?qd(h,m):qd(v,m));else if(!c(...N))if(y&&b){let O=r.length;O>0&&r[O-1].followingNode!==b&&A5(r,x),r.push(f)}else y?$b(y,m):b?Pb(b,m):h?qd(h,m):qd(v,m)}if(A5(r,t),p)for(let d of n)delete d.precedingNode,delete d.enclosingNode,delete d.followingNode}function r1e(e,t,n,r){let{comment:i,precedingNode:s}=n[r],{locStart:o,locEnd:a}=t,l=o(i);if(s)for(let c=r-1;c>=0;c--){let{comment:u,precedingNode:p}=n[c];if(p!==s||!kK(e.slice(a(u),l)))break;l=o(u)}return Ju(e,l,{backwards:!0})}function i1e(e,t,n,r){let{comment:i,followingNode:s}=n[r],{locStart:o,locEnd:a}=t,l=a(i);if(s)for(let c=r+1;c0;--o){let{comment:a,precedingNode:l,followingNode:c}=e[o-1];Gu(l,r),Gu(c,i);let u=t.originalText.slice(t.locEnd(a),s);if(t.printer.isGap?.(u,t)??/^[\s(]*$/.test(u))s=t.locStart(a);else break}for(let[a,{comment:l}]of e.entries())a1&&a.comments.sort((l,c)=>t.locStart(l)-t.locStart(c));e.length=0}function o$(e,t,n){let r=n.locStart(t)-1;for(let i=1;i!r?.has(o)&&o.leading&&i(o)));return s.size===0?"":e.map(({node:o})=>s.has(o)?o1e(e,t):"","comments").filter(Boolean)}function c1e(e,t,n){let r=e.node?.comments,i=new Set(r?.filter((u)=>u.trailing)),s=t[Symbol.for("printedComments")],o=n?.filter??NK,a=new Set(r?.filter((u)=>i.has(u)&&!s?.has(u)&&o(u)));if(a.size===0)return"";let l=[],c;return e.each(({node:u})=>{i.has(u)&&(c=a1e(e,t,c),a.has(u)&&l.push(c.doc))},"comments"),l}function u1e(e,t,n,r){let i=l1e(e,n,r),s=c1e(e,n,r);return i||s?OD(t,(o)=>[i,o,s]):t}function p1e(e){let{[RD]:t,[Symbol.for("printedComments")]:n}=e;for(let r of t){if(!r.printed&&!n.has(r))throw Error('Comment "'+r.value.trim()+'" was not printed. Please report this error!');delete r.printed}}function $K({plugins:e=[],showDeprecated:t=!1}={}){let n=e.flatMap((i)=>i.languages??[]),r=[];for(let i of h1e(Object.assign({},...e.map(({options:s})=>s),m1e)))!t&&i.deprecated||(Array.isArray(i.choices)&&(t||(i.choices=i.choices.filter((s)=>!s.deprecated)),i.name==="parser"&&(i.choices=[...i.choices,...y1e(i.choices,n,e)])),i.pluginDefaults=Object.fromEntries(e.filter((s)=>s.defaultOptions?.[i.name]!==void 0).map((s)=>[s.name,s.defaultOptions[i.name]])),r.push(i));return{languages:n,options:r}}function*y1e(e,t,n){let r=new Set(e.map((i)=>i.value));for(let i of t)if(i.parsers){for(let s of i.parsers)if(!r.has(s)){r.add(s);let o=n.find((l)=>l.parsers&&LD(l.parsers,s)),a=i.name;o?.name&&(a+=` (plugin: ${o.name})`),yield{value:s,description:a}}}}function h1e(e){let t=[];for(let[n,r]of Object.entries(e)){let i={name:n,...r};Array.isArray(i.default)&&(i.default=yi(0,i.default,-1).value),t.push(i)}return t}function _1e(){let e=globalThis,t=e.process?.platform;if(typeof t=="string")return t.startsWith("win");let n=e.Deno?.build?.os;return typeof n=="string"?n==="windows":e.navigator?.platform?.startsWith("Win")??!1}function IK(e){if(e=e instanceof URL?e:new URL(e),e.protocol!=="file:")throw TypeError(`URL must be a file URL: received "${e.protocol}"`);return e}function w1e(e){return e=IK(e),decodeURIComponent(e.pathname.replace(/%(?![0-9A-Fa-f]{2})/g,"%25"))}function D1e(e){e=IK(e);let t=decodeURIComponent(e.pathname.replace(/\//g,"\\").replace(/%(?![0-9A-Fa-f]{2})/g,"%25")).replace(/^\\*([A-Za-z]:)(\\|$)/,"$1\\");return e.hostname!==""&&(t=`\\\\${e.hostname}${t}`),t}function T1e(e){return x1e?D1e(e):w1e(e)}function j5(e,t){if(!t)return;let n=S1e(t).toLowerCase();return e.find(({filenames:r})=>r?.some((i)=>i.toLowerCase()===n))??e.find(({extensions:r})=>r?.some((i)=>n.endsWith(i)))}function k1e(e,t){if(t)return e.find(({name:n})=>n.toLowerCase()===t)??e.find(({aliases:n})=>n?.includes(t))??e.find(({extensions:n})=>n?.includes(`.${t}`))}function F5(e,t){if(t){if(E1e(t))try{t=T1e(t)}catch{return}if(typeof t=="string")return e.find(({isSupported:n})=>n?.({filepath:t}))}}function O1e(e,t){let n=v1e(0,e.plugins).flatMap((r)=>r.languages??[]);return(k1e(n,t.language)??j5(n,t.physicalFile)??j5(n,t.file)??F5(n,t.physicalFile)??F5(n,t.file)??N1e?.(n,t.physicalFile))?.parsers[0]}function M5(e,t,n,r){return[`Invalid ${ml.red(r.key(e))} value.`,`Expected ${ml.blue(n)},`,`but received ${t===jK?ml.gray("nothing"):ml.red(r.value(t))}.`].join(" ")}function FK({text:e,list:t},n){let r=[];return e&&r.push(`- ${ml.blue(e)}`),t&&r.push([`- ${ml.blue(t.title)}:`].concat(t.values.map((i)=>FK(i,n-C5.length).replace(/^|\n/g,`$&${C5}`))).join(` `)),CK(r,n)}function CK(e,t){if(e.length===1)return e[0];let[n,r]=e,[i,s]=e.map((o)=>o.split(` -`,1)[0].length);return i>t&&i>s?r:n}function l$(e,t,n){if(e===t)return 0;let r=n?.maxDistance,i=e;e.length>t.length&&(e=t,t=i);let s=e.length,o=t.length;for(;s>0&&e.charCodeAt(~-s)===t.charCodeAt(~-o);)s--,o--;let a=0;for(;ar)return r;if(s===0)return r!==void 0&&o>r?r:o;let l,c,u,p,d=0,f=0;for(;dc?p>c?c+1:p:p>u?u+1:p;if(r!==void 0){let m=c;for(d=0;dr)return r}}return Zm.length=s,a$.length=s,r!==void 0&&c>r?r:c}function $1e(e,t,n){if(!Array.isArray(t)||t.length===0)return;let r=n?.maxDistance,i=e.length;for(let l of t)if(l===e)return l;if(r===0)return;let s,o=Number.POSITIVE_INFINITY,a=new Set;for(let l of t){if(a.has(l))continue;a.add(l);let c=Math.abs(l.length-i);if(c>=o||r!==void 0&&c>r)continue;let u=Number.isFinite(o)?r===void 0?o:Math.min(o,r):r,p=u===void 0?l$(e,l):l$(e,l,{maxDistance:u});if(r!==void 0&&p>r)continue;let d=p;if(u!==void 0&&p===u&&u===r&&(d=l$(e,l)),dr))return s}function A1e(e,t){let n=new e(t),r=Object.create(n);for(let i of I1e)i in t&&(r[i]=R1e(t[i],n,zu.prototype[i].length));return r}function R1e(e,t,n){return typeof e=="function"?(...r)=>e(...r.slice(0,n-1),t,...r.slice(n-1)):()=>e}function L5({from:e,to:t}){return{from:[e],to:t}}function L1e(e,t){let n=Object.create(null);for(let r of e){let i=r[t];if(n[i])throw Error(`Duplicate ${t} ${JSON.stringify(i)}`);n[i]=r}return n}function q1e(e,t){let n=new Map;for(let r of e){let i=r[t];if(n.has(i))throw Error(`Duplicate ${t} ${JSON.stringify(i)}`);n.set(i,r)}return n}function U1e(){let e=Object.create(null);return(t)=>{let n=JSON.stringify(t);return e[n]?!0:(e[n]=!0,!1)}}function B1e(e,t){let n=[],r=[];for(let i of e)t(i)?n.push(i):r.push(i);return[n,r]}function V1e(e){return e===Math.floor(e)}function K1e(e,t){if(e===t)return 0;let n=typeof e,r=typeof t,i=["undefined","object","boolean","number","string"];return n!==r?i.indexOf(n)-i.indexOf(r):n!=="string"?Number(e)-Number(t):e.localeCompare(t)}function J1e(e){return(...t)=>{let n=e(...t);return typeof n=="string"?Error(n):n}}function q5(e){return e===void 0?{}:e}function LK(e){if(typeof e=="string")return{text:e};let{text:t,list:n}=e;return G1e((t||n)!==void 0,"Unexpected `expected` result, there should be at least one field."),n?{text:t,list:{title:n.title,values:n.values.map(LK)}}:{text:t}}function U5(e,t){return e===!0?!0:e===!1?{value:t}:e}function B5(e,t,n=!1){return e===!1?!1:e===!0?n?!0:[{value:t}]:("value"in e)?[e]:e.length===0?!1:e}function V5(e,t){return typeof e=="string"||"key"in e?{from:t,to:e}:("from"in e)?{from:e.from,to:e.to}:{from:t,to:e.to}}function f$(e,t){return e===void 0?[]:Array.isArray(e)?e.map((n)=>V5(n,t)):[V5(e,t)]}function K5(e,t){let n=f$(typeof e=="object"&&"redirect"in e?e.redirect:e,t);return n.length===0?{remain:t,redirect:n}:typeof e=="object"&&("remain"in e)?{remain:e.remain,redirect:n}:{redirect:n}}function G1e(e,t){if(!e)throw Error(t)}function tNe(e,t,{logger:n=!1,isCLI:r=!1,passThrough:i=!1,FlagSchema:s,descriptor:o}={}){if(r){if(!s)throw Error("'FlagSchema' option is required.");if(!o)throw Error("'descriptor' option is required.")}else o=ey;let a=i?Array.isArray(i)?(d,f)=>i.includes(d)?{[d]:f}:void 0:(d,f)=>({[d]:f}):(d,f,m)=>{let{_:y,...h}=m.schemas;return MK(d,f,{...m,schemas:h})},l=nNe(t,{isCLI:r,FlagSchema:s}),c=new eNe(l,{logger:n,unknown:a,descriptor:o}),u=n!==!1;u&&c$&&(c._hasDeprecationWarned=c$);let p=c.normalize(e);return u&&(c$=c._hasDeprecationWarned),p}function nNe(e,{isCLI:t,FlagSchema:n}){let r=[];t&&r.push(F1e.create({name:"_"}));for(let i of e)r.push(rNe(i,{isCLI:t,optionInfos:e,FlagSchema:n})),i.alias&&t&&r.push(j1e.create({name:i.alias,sourceName:i.name}));return r}function rNe(e,{isCLI:t,optionInfos:n,FlagSchema:r}){let{name:i}=e,s={name:i},o,a={};switch(e.type){case"int":o=W1e,t&&(s.preprocess=Number);break;case"string":o=J5;break;case"choice":o=H1e,s.choices=e.choices.map((l)=>l?.redirect?{...l,redirect:{to:{key:e.name,value:l.redirect}}}:l);break;case"boolean":o=M1e;break;case"flag":o=r,s.flags=n.flatMap((l)=>[l.alias,l.description&&l.name,l.oppositeDescription&&`no-${l.name}`].filter(Boolean));break;case"path":o=J5;break;default:throw Error(`Unexpected type ${e.type}`)}if(e.exception?s.validate=(l,c,u)=>e.exception(l)||c.validate(l,u):s.validate=(l,c,u)=>l===void 0||c.validate(l,u),e.redirect&&(a.redirect=(l)=>l?{to:typeof e.redirect=="string"?e.redirect:{key:e.redirect.option,value:e.redirect.value}}:void 0),e.deprecated&&(a.deprecated=!0),t&&!e.array){let l=s.preprocess||((c)=>c);s.preprocess=(c,u,p)=>u.preprocess(l(Array.isArray(c)?mi(0,c,-1):c),p)}return e.array?C1e.create({...t?{preprocess:(l)=>Array.isArray(l)?l:[l]}:{},...a,valueSchema:o.create(s)}):o.create({...s,...a})}function cNe(e){return!!e?.[aNe]}async function uNe(e,t,n,r){let{node:i}=n,{language:s}=i;if(!UK.has(s))return;let o=i.value.trim(),a;if(o){let l=s==="yaml"?s:AK(r,{language:s});if(!l)return;a=o?await e(o,{parser:l}):""}else a=o;return lK([i.startDelimiter,i.explicitLanguage??"",hc,a,a?hc:"",i.endDelimiter])}function pNe(e,t){return BK({node:e})&&(delete t.end,delete t.raw,delete t.value),t}function fNe({node:e}){return e.raw}function hNe(e,t){let n=e?(r)=>e(r,VK):yNe;return t?new Proxy(n,{apply:(r,i,s)=>k$(s[0])?lNe:Reflect.apply(r,i,s)}):n}function KK(e,t){if(!t)throw Error("parserName is required.");let n=qK(0,e,(i)=>i.parsers&&LD(i.parsers,t));if(n)return n;let r=`Couldn't resolve parser "${t}".`;throw r+=" Plugins must be explicitly added to the standalone bundle.",new PK(r)}function gNe(e,t){if(!t)throw Error("astFormat is required.");let n=qK(0,e,(i)=>i.printers&&LD(i.printers,t));if(n)return n;let r=`Couldn't find plugin for AST format "${t}".`;throw r+=" Plugins must be explicitly added to the standalone bundle.",new PK(r)}function N$({plugins:e,parser:t}){let n=KK(e,t);return JK(n,t)}function JK(e,t){let n=e.parsers[t];return typeof n=="function"?n():n}async function bNe(e,t){let n=e.printers[t],r=typeof n=="function"?await n():n;return xNe(r)}function vNe(e){let{features:t,getVisitorKeys:n,embed:r,massageAstNode:i,print:s,...o}=e;t=SNe(t);let a=t.experimental_frontMatterSupport;n=G5(n,a.massageAstNode||a.embed||a.print);let l=i;i&&a.massageAstNode&&(l=new Proxy(i,{apply(p,d,f){return dNe(...f),Reflect.apply(p,d,f)}}));let c=r;if(r){let p;c=new Proxy(r,{get(d,f,m){return f==="getVisitorKeys"?(p??(p=r.getVisitorKeys?G5(r.getVisitorKeys,a.massageAstNode||a.embed):n),p):Reflect.get(d,f,m)},apply:(d,f,m)=>a.embed&&BK(...m)?uNe:Reflect.apply(d,f,m)})}let u=s;return a.print&&(u=new Proxy(s,{apply(p,d,f){let[m]=f;return k$(m.node)?mNe(m):Reflect.apply(p,d,f)}})),{features:t,getVisitorKeys:n,embed:c,massageAstNode:l,print:u,...o}}function xNe(e){return b$(_Ne,e,vNe)}function TNe(e){return{...DNe,...e}}function SNe(e){return{experimental_avoidAstMutation:!1,...e,experimental_frontMatterSupport:TNe(e?.experimental_frontMatterSupport)}}async function ENe(e,t={}){let n={...e};if(!n.parser){if(!n.filepath)throw new R5("No parser and no file path given, couldn't infer a parser.");if(n.parser=AK(n,{physicalFile:n.filepath}),!n.parser)throw new R5(`No parser could be inferred for file "${n.filepath}".`)}let r=$K({plugins:e.plugins,showDeprecated:!0}).options,i={...H5,...Object.fromEntries(r.filter((p)=>p.default!==void 0).map((p)=>[p.name,p.default]))},s=KK(n.plugins,n.parser),o=await JK(s,n.parser);n.astFormat=o.astFormat,n.locEnd=o.locEnd,n.locStart=o.locStart;let a=s.printers?.[o.astFormat]?s:gNe(n.plugins,o.astFormat),l=await bNe(a,o.astFormat);n.printer=l,n.getVisitorKeys=l.getVisitorKeys;let c=a.defaultOptions?Object.fromEntries(Object.entries(a.defaultOptions).filter(([,p])=>p!==void 0)):{},u={...i,...c};for(let[p,d]of Object.entries(u))n[p]??(n[p]=d);return n.parser==="json"&&(n.trailingComma="none"),iNe(n,r,{passThrough:Object.keys(H5),...t})}function kNe(e,t,n,r){let i={column:null,line:-1,...e.start},s={...i,...e.end},{linesAbove:o=2,linesBelow:a=3}=n||{},l=i.line-r,c=i.column,u=s.line-r,p=s.column,d=Math.max(l-(o+1),0),f=Math.min(t.length,u+a);l===-1&&(d=0),u===-1&&(f=t.length);let m=u-l,y={};if(m)for(let h=0;h<=m;h++){let b=h+l;if(c==null)y[b]=!0;else if(h===0){let g=t[b-1].length;y[b]=[c,g-c]}else if(h===m)y[b]=[0,p];else{let g=t[b-1].length;y[b]=[0,g]}}else if(c===p)c!=null?y[l]=[c,0]:y[l]=!0;else{let h=c??0,b=p??h;y[l]=[h,b-h]}return{start:d,end:f,markerLines:y}}function NNe(e,t,n={},r){let{defs:i,highlight:s}=r||{defs:{gutter:String,marker:String,message:String,reset:String},highlight:String},o=(n.startLine||1)-1,a=e.split(z5),{start:l,end:c,markerLines:u}=kNe(t,a,n,o),p=t.start&&typeof t.start.column=="number",d=String(c+o).length,f=s(e).split(z5,c).slice(l,c).map((m,y)=>{let h=l+1+y,b=` ${` ${h+o}`.slice(-d)} |`,g=u[h],x=!u[h+1];if(g){let v="";if(Array.isArray(g)){let D=m.slice(0,g[0]).replace(/[^\t]/g," "),T=g[1]||1;v=[` +`,1)[0].length);return i>t&&i>s?r:n}function l$(e,t,n){if(e===t)return 0;let r=n?.maxDistance,i=e;e.length>t.length&&(e=t,t=i);let s=e.length,o=t.length;for(;s>0&&e.charCodeAt(~-s)===t.charCodeAt(~-o);)s--,o--;let a=0;for(;ar)return r;if(s===0)return r!==void 0&&o>r?r:o;let l,c,u,p,d=0,f=0;for(;dc?p>c?c+1:p:p>u?u+1:p;if(r!==void 0){let m=c;for(d=0;dr)return r}}return ty.length=s,a$.length=s,r!==void 0&&c>r?r:c}function I1e(e,t,n){if(!Array.isArray(t)||t.length===0)return;let r=n?.maxDistance,i=e.length;for(let l of t)if(l===e)return l;if(r===0)return;let s,o=Number.POSITIVE_INFINITY,a=new Set;for(let l of t){if(a.has(l))continue;a.add(l);let c=Math.abs(l.length-i);if(c>=o||r!==void 0&&c>r)continue;let u=Number.isFinite(o)?r===void 0?o:Math.min(o,r):r,p=u===void 0?l$(e,l):l$(e,l,{maxDistance:u});if(r!==void 0&&p>r)continue;let d=p;if(u!==void 0&&p===u&&u===r&&(d=l$(e,l)),dr))return s}function R1e(e,t){let n=new e(t),r=Object.create(n);for(let i of A1e)i in t&&(r[i]=j1e(t[i],n,Wu.prototype[i].length));return r}function j1e(e,t,n){return typeof e=="function"?(...r)=>e(...r.slice(0,n-1),t,...r.slice(n-1)):()=>e}function L5({from:e,to:t}){return{from:[e],to:t}}function q1e(e,t){let n=Object.create(null);for(let r of e){let i=r[t];if(n[i])throw Error(`Duplicate ${t} ${JSON.stringify(i)}`);n[i]=r}return n}function U1e(e,t){let n=new Map;for(let r of e){let i=r[t];if(n.has(i))throw Error(`Duplicate ${t} ${JSON.stringify(i)}`);n.set(i,r)}return n}function B1e(){let e=Object.create(null);return(t)=>{let n=JSON.stringify(t);return e[n]?!0:(e[n]=!0,!1)}}function V1e(e,t){let n=[],r=[];for(let i of e)t(i)?n.push(i):r.push(i);return[n,r]}function K1e(e){return e===Math.floor(e)}function J1e(e,t){if(e===t)return 0;let n=typeof e,r=typeof t,i=["undefined","object","boolean","number","string"];return n!==r?i.indexOf(n)-i.indexOf(r):n!=="string"?Number(e)-Number(t):e.localeCompare(t)}function G1e(e){return(...t)=>{let n=e(...t);return typeof n=="string"?Error(n):n}}function q5(e){return e===void 0?{}:e}function LK(e){if(typeof e=="string")return{text:e};let{text:t,list:n}=e;return H1e((t||n)!==void 0,"Unexpected `expected` result, there should be at least one field."),n?{text:t,list:{title:n.title,values:n.values.map(LK)}}:{text:t}}function U5(e,t){return e===!0?!0:e===!1?{value:t}:e}function B5(e,t,n=!1){return e===!1?!1:e===!0?n?!0:[{value:t}]:("value"in e)?[e]:e.length===0?!1:e}function V5(e,t){return typeof e=="string"||"key"in e?{from:t,to:e}:("from"in e)?{from:e.from,to:e.to}:{from:t,to:e.to}}function f$(e,t){return e===void 0?[]:Array.isArray(e)?e.map((n)=>V5(n,t)):[V5(e,t)]}function K5(e,t){let n=f$(typeof e=="object"&&"redirect"in e?e.redirect:e,t);return n.length===0?{remain:t,redirect:n}:typeof e=="object"&&("remain"in e)?{remain:e.remain,redirect:n}:{redirect:n}}function H1e(e,t){if(!e)throw Error(t)}function nNe(e,t,{logger:n=!1,isCLI:r=!1,passThrough:i=!1,FlagSchema:s,descriptor:o}={}){if(r){if(!s)throw Error("'FlagSchema' option is required.");if(!o)throw Error("'descriptor' option is required.")}else o=ny;let a=i?Array.isArray(i)?(d,f)=>i.includes(d)?{[d]:f}:void 0:(d,f)=>({[d]:f}):(d,f,m)=>{let{_:y,...h}=m.schemas;return MK(d,f,{...m,schemas:h})},l=rNe(t,{isCLI:r,FlagSchema:s}),c=new tNe(l,{logger:n,unknown:a,descriptor:o}),u=n!==!1;u&&c$&&(c._hasDeprecationWarned=c$);let p=c.normalize(e);return u&&(c$=c._hasDeprecationWarned),p}function rNe(e,{isCLI:t,FlagSchema:n}){let r=[];t&&r.push(C1e.create({name:"_"}));for(let i of e)r.push(iNe(i,{isCLI:t,optionInfos:e,FlagSchema:n})),i.alias&&t&&r.push(F1e.create({name:i.alias,sourceName:i.name}));return r}function iNe(e,{isCLI:t,optionInfos:n,FlagSchema:r}){let{name:i}=e,s={name:i},o,a={};switch(e.type){case"int":o=Q1e,t&&(s.preprocess=Number);break;case"string":o=J5;break;case"choice":o=z1e,s.choices=e.choices.map((l)=>l?.redirect?{...l,redirect:{to:{key:e.name,value:l.redirect}}}:l);break;case"boolean":o=L1e;break;case"flag":o=r,s.flags=n.flatMap((l)=>[l.alias,l.description&&l.name,l.oppositeDescription&&`no-${l.name}`].filter(Boolean));break;case"path":o=J5;break;default:throw Error(`Unexpected type ${e.type}`)}if(e.exception?s.validate=(l,c,u)=>e.exception(l)||c.validate(l,u):s.validate=(l,c,u)=>l===void 0||c.validate(l,u),e.redirect&&(a.redirect=(l)=>l?{to:typeof e.redirect=="string"?e.redirect:{key:e.redirect.option,value:e.redirect.value}}:void 0),e.deprecated&&(a.deprecated=!0),t&&!e.array){let l=s.preprocess||((c)=>c);s.preprocess=(c,u,p)=>u.preprocess(l(Array.isArray(c)?yi(0,c,-1):c),p)}return e.array?M1e.create({...t?{preprocess:(l)=>Array.isArray(l)?l:[l]}:{},...a,valueSchema:o.create(s)}):o.create({...s,...a})}function uNe(e){return!!e?.[lNe]}async function pNe(e,t,n,r){let{node:i}=n,{language:s}=i;if(!UK.has(s))return;let o=i.value.trim(),a;if(o){let l=s==="yaml"?s:AK(r,{language:s});if(!l)return;a=o?await e(o,{parser:l}):""}else a=o;return lK([i.startDelimiter,i.explicitLanguage??"",hc,a,a?hc:"",i.endDelimiter])}function dNe(e,t){return BK({node:e})&&(delete t.end,delete t.raw,delete t.value),t}function mNe({node:e}){return e.raw}function gNe(e,t){let n=e?(r)=>e(r,VK):hNe;return t?new Proxy(n,{apply:(r,i,s)=>k$(s[0])?cNe:Reflect.apply(r,i,s)}):n}function KK(e,t){if(!t)throw Error("parserName is required.");let n=qK(0,e,(i)=>i.parsers&&LD(i.parsers,t));if(n)return n;let r=`Couldn't resolve parser "${t}".`;throw r+=" Plugins must be explicitly added to the standalone bundle.",new PK(r)}function bNe(e,t){if(!t)throw Error("astFormat is required.");let n=qK(0,e,(i)=>i.printers&&LD(i.printers,t));if(n)return n;let r=`Couldn't find plugin for AST format "${t}".`;throw r+=" Plugins must be explicitly added to the standalone bundle.",new PK(r)}function N$({plugins:e,parser:t}){let n=KK(e,t);return JK(n,t)}function JK(e,t){let n=e.parsers[t];return typeof n=="function"?n():n}async function vNe(e,t){let n=e.printers[t],r=typeof n=="function"?await n():n;return wNe(r)}function _Ne(e){let{features:t,getVisitorKeys:n,embed:r,massageAstNode:i,print:s,...o}=e;t=ENe(t);let a=t.experimental_frontMatterSupport;n=G5(n,a.massageAstNode||a.embed||a.print);let l=i;i&&a.massageAstNode&&(l=new Proxy(i,{apply(p,d,f){return fNe(...f),Reflect.apply(p,d,f)}}));let c=r;if(r){let p;c=new Proxy(r,{get(d,f,m){return f==="getVisitorKeys"?(p??(p=r.getVisitorKeys?G5(r.getVisitorKeys,a.massageAstNode||a.embed):n),p):Reflect.get(d,f,m)},apply:(d,f,m)=>a.embed&&BK(...m)?pNe:Reflect.apply(d,f,m)})}let u=s;return a.print&&(u=new Proxy(s,{apply(p,d,f){let[m]=f;return k$(m.node)?yNe(m):Reflect.apply(p,d,f)}})),{features:t,getVisitorKeys:n,embed:c,massageAstNode:l,print:u,...o}}function wNe(e){return b$(xNe,e,_Ne)}function SNe(e){return{...TNe,...e}}function ENe(e){return{experimental_avoidAstMutation:!1,...e,experimental_frontMatterSupport:SNe(e?.experimental_frontMatterSupport)}}async function kNe(e,t={}){let n={...e};if(!n.parser){if(!n.filepath)throw new R5("No parser and no file path given, couldn't infer a parser.");if(n.parser=AK(n,{physicalFile:n.filepath}),!n.parser)throw new R5(`No parser could be inferred for file "${n.filepath}".`)}let r=$K({plugins:e.plugins,showDeprecated:!0}).options,i={...H5,...Object.fromEntries(r.filter((p)=>p.default!==void 0).map((p)=>[p.name,p.default]))},s=KK(n.plugins,n.parser),o=await JK(s,n.parser);n.astFormat=o.astFormat,n.locEnd=o.locEnd,n.locStart=o.locStart;let a=s.printers?.[o.astFormat]?s:bNe(n.plugins,o.astFormat),l=await vNe(a,o.astFormat);n.printer=l,n.getVisitorKeys=l.getVisitorKeys;let c=a.defaultOptions?Object.fromEntries(Object.entries(a.defaultOptions).filter(([,p])=>p!==void 0)):{},u={...i,...c};for(let[p,d]of Object.entries(u))n[p]??(n[p]=d);return n.parser==="json"&&(n.trailingComma="none"),sNe(n,r,{passThrough:Object.keys(H5),...t})}function NNe(e,t,n,r){let i={column:null,line:-1,...e.start},s={...i,...e.end},{linesAbove:o=2,linesBelow:a=3}=n||{},l=i.line-r,c=i.column,u=s.line-r,p=s.column,d=Math.max(l-(o+1),0),f=Math.min(t.length,u+a);l===-1&&(d=0),u===-1&&(f=t.length);let m=u-l,y={};if(m)for(let h=0;h<=m;h++){let b=h+l;if(c==null)y[b]=!0;else if(h===0){let g=t[b-1].length;y[b]=[c,g-c]}else if(h===m)y[b]=[0,p];else{let g=t[b-1].length;y[b]=[0,g]}}else if(c===p)c!=null?y[l]=[c,0]:y[l]=!0;else{let h=c??0,b=p??h;y[l]=[h,b-h]}return{start:d,end:f,markerLines:y}}function ONe(e,t,n={},r){let{defs:i,highlight:s}=r||{defs:{gutter:String,marker:String,message:String,reset:String},highlight:String},o=(n.startLine||1)-1,a=e.split(z5),{start:l,end:c,markerLines:u}=NNe(t,a,n,o),p=t.start&&typeof t.start.column=="number",d=String(c+o).length,f=s(e).split(z5,c).slice(l,c).map((m,y)=>{let h=l+1+y,b=` ${` ${h+o}`.slice(-d)} |`,g=u[h],x=!u[h+1];if(g){let v="";if(Array.isArray(g)){let D=m.slice(0,g[0]).replace(/[^\t]/g," "),T=g[1]||1;v=[` `,i.gutter(b.replace(/\d/g," "))," ",D,i.marker("^").repeat(T)].join(""),x&&n.message&&(v+=" "+i.message(n.message))}return[i.marker(">"),i.gutter(b),m.length>0?` ${m}`:"",v].join("")}else return` ${i.gutter(b)}${m.length>0?` ${m}`:""}`}).join(` `);return n.message&&!p&&(f=`${" ".repeat(d+1)}${n.message} -${f}`),i.reset(f)}function ONe(e,t,n={}){return NNe(e,t,n)}async function PNe(e,t){let n=await N$(t),r=n.preprocess?await n.preprocess(e,t):e;t.originalText=r;let i;try{i=await n.parse(r,t,t)}catch(s){$Ne(s,e)}return{text:r,ast:i}}function $Ne(e,t){let{loc:n}=e;if(n){let{start:r,end:i}=n;r&&(r={line:r.line,column:r.column-1}),i&&(i={line:i.line,column:i.column-1});let s=ONe(t,{start:r,end:i},{highlightCode:!0});e.message+=` -`+s,e.codeFrame=s}throw e}async function INe(e,t,n,r,i){if(n.embeddedLanguageFormatting!=="auto")return;let{printer:s}=n,{embed:o}=s;if(!o)return;if(o.length>2)throw Error("printer.embed has too many parameters. The API changed in Prettier v3. Please update your plugin. See https://prettier.io/docs/plugins#optional-embed");let{hasPrettierIgnore:a}=s,{getVisitorKeys:l}=o,c=[];d();let u=e.stack;for(let{print:f,node:m,pathStack:y}of c)try{e.stack=y;let h=await f(p,t,e,n);h&&i.set(m,h)}catch(h){if(globalThis.PRETTIER_DEBUG)throw h}e.stack=u;function p(f,m){return ANe(f,m,n,r)}function d(){let{node:f}=e;if(f===null||typeof f!="object"||a?.(e))return;for(let y of l(f))Array.isArray(f[y])?e.each(d,y):e.call(d,y);let m=o(e,n);if(m){if(typeof m=="function"){c.push({print:m,node:f,pathStack:[...e.stack]});return}i.set(f,m)}}}async function ANe(e,t,n,r){let i=await ry({...n,...t,parentParser:n.parser,originalText:e,cursorOffset:void 0,rangeStart:void 0,rangeEnd:void 0},{passThrough:!0}),{ast:s}=await Rb(e,i),o=await r(s,i);return oK(o)}function RNe(e,t,n,r){let{originalText:i,[RD]:s,locStart:o,locEnd:a,[Symbol.for("printedComments")]:l}=t,{node:c}=e,u=o(c),p=a(c);for(let f of s)o(f)>=u&&a(f)<=p&&l.add(f);let{printPrettierIgnored:d}=t.printer;return d?d(e,t,n,r):i.slice(u,p)}async function qD(e,t){({ast:e}=await GK(e,t));let n=new Map,r=new Jke(e),i=p1e(t),s=new Map;await INe(r,a,t,qD,s);let o=await W5(r,t,a,void 0,s);if(u1e(t),t.cursorOffset>=0){if(t.nodeAfterCursor&&!t.nodeBeforeCursor)return[qd,o];if(t.nodeBeforeCursor&&!t.nodeAfterCursor)return[o,qd]}return o;function a(c,u){return c===void 0||c===r?l(u):Array.isArray(c)?r.call(()=>l(u),...c):r.call(()=>l(u),c)}function l(c){i(r);let u=r.node;if(u==null)return"";let p=T$(u)&&c===void 0;if(p&&n.has(u))return n.get(u);let d=W5(r,t,a,c,s);return p&&n.set(u,d),d}}function W5(e,t,n,r,i){let{node:s}=e,{printer:o}=t,a;switch(o.hasPrettierIgnore?.(e)?a=jNe(e,t,n,r):i.has(s)?a=i.get(s):a=o.print(e,t,n,r),s){case t.cursorNode:a=OD(a,(l)=>[qd,l,qd]);break;case t.nodeBeforeCursor:a=OD(a,(l)=>[l,qd]);break;case t.nodeAfterCursor:a=OD(a,(l)=>[qd,l]);break}return o.printComment&&_K(s.comments)&&!o.willPrintOwnComments?.(e,t)&&(a=c1e(e,a,t)),a}async function GK(e,t){let n=e.comments??[];t[RD]=n,t[Symbol.for("printedComments")]=new Set,t1e(e,t);let{printer:{preprocess:r}}=t;return e=r?await r(e,t):e,{ast:e,comments:n}}function FNe(e,t){let{cursorOffset:n,locStart:r,locEnd:i,getVisitorKeys:s}=t,o=(f)=>r(f)<=n&&i(f)>=n,a=e,l=[e];for(let f of Yke(e,{getVisitorKeys:s,filter:o}))l.push(f),a=f;if(Xke(a,{getVisitorKeys:s}))return{cursorNode:a};let c,u,p=-1,d=Number.POSITIVE_INFINITY;for(;l.length>0&&(c===void 0||u===void 0);){a=l.pop();let f=c!==void 0,m=u!==void 0;for(let y of MD(a,{getVisitorKeys:s})){if(!f){let h=i(y);h<=n&&h>p&&(c=y,p=h)}if(!m){let h=r(y);h>=n&&ho(d,l)).filter(Boolean);let c={},u=new Set(i(a));for(let d in a)!LD(a,d)||s?.has(d)||(u.has(d)?c[d]=o(a[d],a):c[d]=a[d]);let p=r(a,c,l);if(p!==null)return p??c}}function BNe(e,t){return t=new Set(t),e.find((n)=>zK.has(n.type)&&t.has(n))}function Q5(e){let t=UNe(0,e,(n)=>n.type!=="Program"&&n.type!=="File");return t===-1?e:e.slice(0,t+1)}function VNe(e,t,{locStart:n,locEnd:r}){let[i,...s]=e,[o,...a]=t;if(i===o)return[i,o];let l=n(i);for(let u of Q5(a))if(n(u)>=l)o=u;else break;let c=r(o);for(let u of Q5(s)){if(r(u)<=c)i=u;else break;if(i===o)break}return[i,o]}function m$(e,t,n,r,i=[],s,o){let{locStart:a,locEnd:l}=o,c=a(e),u=l(e);if(t>u||tr);let s=e.slice(r,i).search(/\S/),o=s===-1;if(!o)for(r+=s;i>r&&!/\S/.test(e[i-1]);--i);let a=t.printer.features?.experimental_locForRangeFormat??t,l=m$(n,r,t,(m,y)=>Y5(t,m,y),[],"rangeStart",a);if(!l)return;let c=o?l:m$(n,i,t,(m)=>Y5(t,m),[],"rangeEnd",a);if(!c)return;let u,p;if(n.type==="JsonRoot"){let m=BNe(l,c);u=m,p=m}else[u,p]=VNe(l,c,t);let{locStart:d,locEnd:f}=a;return[Math.min(d(u),d(p)),Math.max(f(u),f(p))]}async function QK(e,t,n=0){if(!e||e.trim().length===0)return{formatted:"",cursorOffset:-1,comments:[]};let{ast:r,text:i}=await Rb(e,t);t.cursorOffset>=0&&(t={...t,...HK(r,t)});let s=await qD(r,t,n);n>0&&(s=cK([hc,s],n,t.tabWidth));let o=CD(s,t);if(n>0){let l=o.formatted.trim();o.cursorNodeStart!==void 0&&(o.cursorNodeStart-=o.formatted.indexOf(l),o.cursorNodeStart<0&&(o.cursorNodeStart=0,o.cursorNodeText=o.cursorNodeText.trimStart()),o.cursorNodeStart+o.cursorNodeText.length>l.length&&(o.cursorNodeText=o.cursorNodeText.trimEnd())),o.formatted=l+g$(t.endOfLine)}let a=t[RD];if(t.cursorOffset>=0){let l,c,u,p;if((t.cursorNode||t.nodeBeforeCursor||t.nodeAfterCursor)&&o.cursorNodeText)if(u=o.cursorNodeStart,p=o.cursorNodeText,t.cursorNode)l=t.locStart(t.cursorNode),c=i.slice(l,t.locEnd(t.cursorNode));else{if(!t.nodeBeforeCursor&&!t.nodeAfterCursor)throw Error("Cursor location must contain at least one of cursorNode, nodeBeforeCursor, nodeAfterCursor");l=t.nodeBeforeCursor?t.locEnd(t.nodeBeforeCursor):0;let b=t.nodeAfterCursor?t.locStart(t.nodeAfterCursor):i.length;c=i.slice(l,b)}else l=0,c=i,u=0,p=o.formatted;let d=t.cursorOffset-l;if(c===p)return{formatted:o.formatted,cursorOffset:u+d,comments:a};let f=c.split("");f.splice(d,0,X5);let m=p.split(""),y=jEe(f,m),h=u;for(let b of y)if(b.removed){if(b.value.includes(X5))break}else h+=b.count;return{formatted:o.formatted,cursorOffset:h,comments:a}}return{formatted:o.formatted,cursorOffset:-1,comments:a}}async function HNe(e,t){let{ast:n,text:r}=await Rb(e,t),[i,s]=GNe(r,t,n)??[0,0],o=r.slice(i,s),a=Math.min(i,r.lastIndexOf(` +${f}`),i.reset(f)}function PNe(e,t,n={}){return ONe(e,t,n)}async function $Ne(e,t){let n=await N$(t),r=n.preprocess?await n.preprocess(e,t):e;t.originalText=r;let i;try{i=await n.parse(r,t,t)}catch(s){INe(s,e)}return{text:r,ast:i}}function INe(e,t){let{loc:n}=e;if(n){let{start:r,end:i}=n;r&&(r={line:r.line,column:r.column-1}),i&&(i={line:i.line,column:i.column-1});let s=PNe(t,{start:r,end:i},{highlightCode:!0});e.message+=` +`+s,e.codeFrame=s}throw e}async function ANe(e,t,n,r,i){if(n.embeddedLanguageFormatting!=="auto")return;let{printer:s}=n,{embed:o}=s;if(!o)return;if(o.length>2)throw Error("printer.embed has too many parameters. The API changed in Prettier v3. Please update your plugin. See https://prettier.io/docs/plugins#optional-embed");let{hasPrettierIgnore:a}=s,{getVisitorKeys:l}=o,c=[];d();let u=e.stack;for(let{print:f,node:m,pathStack:y}of c)try{e.stack=y;let h=await f(p,t,e,n);h&&i.set(m,h)}catch(h){if(globalThis.PRETTIER_DEBUG)throw h}e.stack=u;function p(f,m){return RNe(f,m,n,r)}function d(){let{node:f}=e;if(f===null||typeof f!="object"||a?.(e))return;for(let y of l(f))Array.isArray(f[y])?e.each(d,y):e.call(d,y);let m=o(e,n);if(m){if(typeof m=="function"){c.push({print:m,node:f,pathStack:[...e.stack]});return}i.set(f,m)}}}async function RNe(e,t,n,r){let i=await sy({...n,...t,parentParser:n.parser,originalText:e,cursorOffset:void 0,rangeStart:void 0,rangeEnd:void 0},{passThrough:!0}),{ast:s}=await Rb(e,i),o=await r(s,i);return oK(o)}function jNe(e,t,n,r){let{originalText:i,[RD]:s,locStart:o,locEnd:a,[Symbol.for("printedComments")]:l}=t,{node:c}=e,u=o(c),p=a(c);for(let f of s)o(f)>=u&&a(f)<=p&&l.add(f);let{printPrettierIgnored:d}=t.printer;return d?d(e,t,n,r):i.slice(u,p)}async function qD(e,t){({ast:e}=await GK(e,t));let n=new Map,r=new Gke(e),i=d1e(t),s=new Map;await ANe(r,a,t,qD,s);let o=await W5(r,t,a,void 0,s);if(p1e(t),t.cursorOffset>=0){if(t.nodeAfterCursor&&!t.nodeBeforeCursor)return[Bd,o];if(t.nodeBeforeCursor&&!t.nodeAfterCursor)return[o,Bd]}return o;function a(c,u){return c===void 0||c===r?l(u):Array.isArray(c)?r.call(()=>l(u),...c):r.call(()=>l(u),c)}function l(c){i(r);let u=r.node;if(u==null)return"";let p=T$(u)&&c===void 0;if(p&&n.has(u))return n.get(u);let d=W5(r,t,a,c,s);return p&&n.set(u,d),d}}function W5(e,t,n,r,i){let{node:s}=e,{printer:o}=t,a;switch(o.hasPrettierIgnore?.(e)?a=FNe(e,t,n,r):i.has(s)?a=i.get(s):a=o.print(e,t,n,r),s){case t.cursorNode:a=OD(a,(l)=>[Bd,l,Bd]);break;case t.nodeBeforeCursor:a=OD(a,(l)=>[l,Bd]);break;case t.nodeAfterCursor:a=OD(a,(l)=>[Bd,l]);break}return o.printComment&&_K(s.comments)&&!o.willPrintOwnComments?.(e,t)&&(a=u1e(e,a,t)),a}async function GK(e,t){let n=e.comments??[];t[RD]=n,t[Symbol.for("printedComments")]=new Set,n1e(e,t);let{printer:{preprocess:r}}=t;return e=r?await r(e,t):e,{ast:e,comments:n}}function CNe(e,t){let{cursorOffset:n,locStart:r,locEnd:i,getVisitorKeys:s}=t,o=(f)=>r(f)<=n&&i(f)>=n,a=e,l=[e];for(let f of Xke(e,{getVisitorKeys:s,filter:o}))l.push(f),a=f;if(Zke(a,{getVisitorKeys:s}))return{cursorNode:a};let c,u,p=-1,d=Number.POSITIVE_INFINITY;for(;l.length>0&&(c===void 0||u===void 0);){a=l.pop();let f=c!==void 0,m=u!==void 0;for(let y of MD(a,{getVisitorKeys:s})){if(!f){let h=i(y);h<=n&&h>p&&(c=y,p=h)}if(!m){let h=r(y);h>=n&&ho(d,l)).filter(Boolean);let c={},u=new Set(i(a));for(let d in a)!LD(a,d)||s?.has(d)||(u.has(d)?c[d]=o(a[d],a):c[d]=a[d]);let p=r(a,c,l);if(p!==null)return p??c}}function VNe(e,t){return t=new Set(t),e.find((n)=>zK.has(n.type)&&t.has(n))}function Q5(e){let t=BNe(0,e,(n)=>n.type!=="Program"&&n.type!=="File");return t===-1?e:e.slice(0,t+1)}function KNe(e,t,{locStart:n,locEnd:r}){let[i,...s]=e,[o,...a]=t;if(i===o)return[i,o];let l=n(i);for(let u of Q5(a))if(n(u)>=l)o=u;else break;let c=r(o);for(let u of Q5(s)){if(r(u)<=c)i=u;else break;if(i===o)break}return[i,o]}function m$(e,t,n,r,i=[],s,o){let{locStart:a,locEnd:l}=o,c=a(e),u=l(e);if(t>u||tr);let s=e.slice(r,i).search(/\S/),o=s===-1;if(!o)for(r+=s;i>r&&!/\S/.test(e[i-1]);--i);let a=t.printer.features?.experimental_locForRangeFormat??t,l=m$(n,r,t,(m,y)=>Y5(t,m,y),[],"rangeStart",a);if(!l)return;let c=o?l:m$(n,i,t,(m)=>Y5(t,m),[],"rangeEnd",a);if(!c)return;let u,p;if(n.type==="JsonRoot"){let m=VNe(l,c);u=m,p=m}else[u,p]=KNe(l,c,t);let{locStart:d,locEnd:f}=a;return[Math.min(d(u),d(p)),Math.max(f(u),f(p))]}async function QK(e,t,n=0){if(!e||e.trim().length===0)return{formatted:"",cursorOffset:-1,comments:[]};let{ast:r,text:i}=await Rb(e,t);t.cursorOffset>=0&&(t={...t,...HK(r,t)});let s=await qD(r,t,n);n>0&&(s=cK([hc,s],n,t.tabWidth));let o=CD(s,t);if(n>0){let l=o.formatted.trim();o.cursorNodeStart!==void 0&&(o.cursorNodeStart-=o.formatted.indexOf(l),o.cursorNodeStart<0&&(o.cursorNodeStart=0,o.cursorNodeText=o.cursorNodeText.trimStart()),o.cursorNodeStart+o.cursorNodeText.length>l.length&&(o.cursorNodeText=o.cursorNodeText.trimEnd())),o.formatted=l+g$(t.endOfLine)}let a=t[RD];if(t.cursorOffset>=0){let l,c,u,p;if((t.cursorNode||t.nodeBeforeCursor||t.nodeAfterCursor)&&o.cursorNodeText)if(u=o.cursorNodeStart,p=o.cursorNodeText,t.cursorNode)l=t.locStart(t.cursorNode),c=i.slice(l,t.locEnd(t.cursorNode));else{if(!t.nodeBeforeCursor&&!t.nodeAfterCursor)throw Error("Cursor location must contain at least one of cursorNode, nodeBeforeCursor, nodeAfterCursor");l=t.nodeBeforeCursor?t.locEnd(t.nodeBeforeCursor):0;let b=t.nodeAfterCursor?t.locStart(t.nodeAfterCursor):i.length;c=i.slice(l,b)}else l=0,c=i,u=0,p=o.formatted;let d=t.cursorOffset-l;if(c===p)return{formatted:o.formatted,cursorOffset:u+d,comments:a};let f=c.split("");f.splice(d,0,X5);let m=p.split(""),y=FEe(f,m),h=u;for(let b of y)if(b.removed){if(b.value.includes(X5))break}else h+=b.count;return{formatted:o.formatted,cursorOffset:h,comments:a}}return{formatted:o.formatted,cursorOffset:-1,comments:a}}async function zNe(e,t){let{ast:n,text:r}=await Rb(e,t),[i,s]=HNe(r,t,n)??[0,0],o=r.slice(i,s),a=Math.min(i,r.lastIndexOf(` `,i)+1),l=r.slice(a,i).match(/^\s*/)[0],c=D$(l,t.tabWidth),u=await QK(o,{...t,rangeStart:0,rangeEnd:Number.POSITIVE_INFINITY,cursorOffset:t.cursorOffset>i&&t.cursorOffset<=s?t.cursorOffset-i:-1,endOfLine:"lf"},c),p=u.formatted.trimEnd(),{cursorOffset:d}=t;d>s?d+=p.length-o.length:u.cursorOffset>=0&&(d=u.cursorOffset+i);let f=r.slice(0,i)+p+r.slice(s);if(t.endOfLine!=="lf"){let m=g$(t.endOfLine);d>=0&&m===`\r `&&(d+=iK(f.slice(0,d),` `)),f=ID(0,f,` -`,m)}return{formatted:f,cursorOffset:d,comments:u.comments}}function u$(e,t,n){return typeof t!="number"||Number.isNaN(t)||t<0||t>e.length?n:t}function Z5(e,t){let{cursorOffset:n,rangeStart:r,rangeEnd:i}=t;return n=u$(e,n,-1),r=u$(e,r,0),i=u$(e,i,e.length),{...t,cursorOffset:n,rangeStart:r,rangeEnd:i}}function YK(e,t){let{cursorOffset:n,rangeStart:r,rangeEnd:i,endOfLine:s}=Z5(e,t),o=e.charAt(0)===WK;if(o&&(e=e.slice(1),n--,r--,i--),s==="auto"&&(s=qEe(e)),e.includes("\r")){let a=(l)=>iK(e.slice(0,Math.max(l,0)),`\r -`);n-=a(n),r-=a(r),i-=a(i),e=VEe(e)}return{hasBOM:o,text:e,options:Z5(e,{...t,cursorOffset:n,rangeStart:r,rangeEnd:i,endOfLine:s})}}async function eK(e,t){let n=await N$(t);return!n.hasPragma||n.hasPragma(e)}async function zNe(e,t){return(await N$(t)).hasIgnorePragma?.(e)}async function XK(e,t){let{hasBOM:n,text:r,options:i}=YK(e,await ry(t));if(i.rangeStart>=i.rangeEnd&&r!==""||i.requirePragma&&!await eK(r,i)||i.checkIgnorePragma&&await zNe(r,i))return{formatted:e,cursorOffset:t.cursorOffset,comments:[]};let s;return i.rangeStart>0||i.rangeEnd=0&&s.cursorOffset++),s}async function WNe(e,t,n){let{text:r,options:i}=YK(e,await ry(t)),s=await Rb(r,i);return n&&(n.preprocessForPrint&&(s.ast=await GK(s.ast,i)),n.massage&&(s.ast=MNe(s.ast,i))),s}async function QNe(e,t){t=await ry(t);let n=await qD(e,t);return CD(n,t)}async function YNe(e,t){let n=_ke(e),{formatted:r}=await XK(n,{...t,parser:"__js_expression"});return r}async function XNe(e,t){t=await ry(t);let{ast:n}=await Rb(e,t);return t.cursorOffset>=0&&(t={...t,...HK(n,t)}),qD(n,t)}async function ZNe(e,t){return CD(e,await ry(t))}function iOe(e,t){if(t===!1)return!1;if(e.charAt(t)==="/"&&e.charAt(t+1)==="*"){for(let n=t+2;nMath.max(r,i.length),0)/t.length}function fOe(e,t){let n=$$(e,t);return n===!1?"":e.charAt(n)}function gOe(e,t){let{preferred:n,alternate:r}=t===!0||t==="'"?yOe:hOe,{length:i}=e,s=0,o=0;for(let a=0;ao?r:n).character}function bOe(e,t,n){for(let r=t;ro===r?o:a===t?"\\"+a:a||(n&&/^[^\n\r"'0-7\\bfnrt-vx\u2028\u2029]$/.test(o)?o:"\\"+o));return t+i+t}function NOe(e,t){return arguments.length===2||typeof t=="number"?I$(e,t):EOe(...arguments)}function Ld(e,t=1){return async(...n)=>{let r=n[t]??{},i=r.plugins??[];return n[t]={...r,plugins:Array.isArray(i)?i:Object.values(i)},await e(...n)}}async function rJ(e,t){let{formatted:n}=await nJ(e,{...t,cursorOffset:-1});return n}async function OOe(e,t){return await rJ(e,t)===e}var NEe,y$=(e,t)=>{for(var n in t)NEe(e,n,{get:t[n],enumerable:!0})},OEe,Ib=(e,t)=>(n,r,...i)=>n|1&&r==null?void 0:(t.call(r)??r[e]).apply(r,i),PEe,$Ee,ID,IEe=class{diff(e,t,n={}){let r;typeof n=="function"?(r=n,n={}):("callback"in n)&&(r=n.callback);let i=this.castInput(e,n),s=this.castInput(t,n),o=this.removeEmpty(this.tokenize(i,n)),a=this.removeEmpty(this.tokenize(s,n));return this.diffWithOptionsObj(o,a,n,r)}diffWithOptionsObj(e,t,n,r){var i;let s=(b)=>{if(b=this.postProcess(b,n),r){setTimeout(function(){r(b)},0);return}else return b},o=t.length,a=e.length,l=1,c=o+a;n.maxEditLength!=null&&(c=Math.min(c,n.maxEditLength));let u=(i=n.timeout)!==null&&i!==void 0?i:1/0,p=Date.now()+u,d=[{oldPos:-1,lastComponent:void 0}],f=this.extractCommon(d[0],t,e,0,n);if(d[0].oldPos+1>=a&&f+1>=o)return s(this.buildValues(d[0].lastComponent,t,e));let m=-1/0,y=1/0,h=()=>{for(let b=Math.max(m,-l);b<=Math.min(y,l);b+=2){let g,x=d[b-1],v=d[b+1];x&&(d[b-1]=void 0);let D=!1;if(v){let N=v.oldPos-b;D=v&&0<=N&&N=a&&f+1>=o)return s(this.buildValues(g.lastComponent,t,e))||!0;d[b]=g,g.oldPos+1>=a&&(y=Math.min(y,b-1)),f+1>=o&&(m=Math.max(m,b+1))}l++};if(r)(function b(){setTimeout(function(){if(l>c||Date.now()>p)return r(void 0);h()||b()},0)})();else for(;l<=c&&Date.now()<=p;){let b=h();if(b)return b}}addToPath(e,t,n,r,i){let s=e.lastComponent;return s&&!i.oneChangePerToken&&s.added===t&&s.removed===n?{oldPos:e.oldPos+r,lastComponent:{count:s.count+1,added:t,removed:n,previousComponent:s.previousComponent}}:{oldPos:e.oldPos+r,lastComponent:{count:1,added:t,removed:n,previousComponent:s}}}extractCommon(e,t,n,r,i){let s=t.length,o=n.length,a=e.oldPos,l=a-r,c=0;for(;l+1p.length?f:p}),c.value=this.join(u)}else c.value=this.join(t.slice(a,a+c.count));a+=c.count,c.added||(l+=c.count)}}return r}},AEe,REe,FEe=()=>{},Ju,tK="cr",nK="crlf",CEe="lf",MEe,h$="\r",rK=`\r +`,m)}return{formatted:f,cursorOffset:d,comments:u.comments}}function u$(e,t,n){return typeof t!="number"||Number.isNaN(t)||t<0||t>e.length?n:t}function Z5(e,t){let{cursorOffset:n,rangeStart:r,rangeEnd:i}=t;return n=u$(e,n,-1),r=u$(e,r,0),i=u$(e,i,e.length),{...t,cursorOffset:n,rangeStart:r,rangeEnd:i}}function YK(e,t){let{cursorOffset:n,rangeStart:r,rangeEnd:i,endOfLine:s}=Z5(e,t),o=e.charAt(0)===WK;if(o&&(e=e.slice(1),n--,r--,i--),s==="auto"&&(s=UEe(e)),e.includes("\r")){let a=(l)=>iK(e.slice(0,Math.max(l,0)),`\r +`);n-=a(n),r-=a(r),i-=a(i),e=KEe(e)}return{hasBOM:o,text:e,options:Z5(e,{...t,cursorOffset:n,rangeStart:r,rangeEnd:i,endOfLine:s})}}async function eK(e,t){let n=await N$(t);return!n.hasPragma||n.hasPragma(e)}async function WNe(e,t){return(await N$(t)).hasIgnorePragma?.(e)}async function XK(e,t){let{hasBOM:n,text:r,options:i}=YK(e,await sy(t));if(i.rangeStart>=i.rangeEnd&&r!==""||i.requirePragma&&!await eK(r,i)||i.checkIgnorePragma&&await WNe(r,i))return{formatted:e,cursorOffset:t.cursorOffset,comments:[]};let s;return i.rangeStart>0||i.rangeEnd=0&&s.cursorOffset++),s}async function QNe(e,t,n){let{text:r,options:i}=YK(e,await sy(t)),s=await Rb(r,i);return n&&(n.preprocessForPrint&&(s.ast=await GK(s.ast,i)),n.massage&&(s.ast=LNe(s.ast,i))),s}async function YNe(e,t){t=await sy(t);let n=await qD(e,t);return CD(n,t)}async function XNe(e,t){let n=xke(e),{formatted:r}=await XK(n,{...t,parser:"__js_expression"});return r}async function ZNe(e,t){t=await sy(t);let{ast:n}=await Rb(e,t);return t.cursorOffset>=0&&(t={...t,...HK(n,t)}),qD(n,t)}async function eOe(e,t){return CD(e,await sy(t))}function sOe(e,t){if(t===!1)return!1;if(e.charAt(t)==="/"&&e.charAt(t+1)==="*"){for(let n=t+2;nMath.max(r,i.length),0)/t.length}function mOe(e,t){let n=$$(e,t);return n===!1?"":e.charAt(n)}function bOe(e,t){let{preferred:n,alternate:r}=t===!0||t==="'"?hOe:gOe,{length:i}=e,s=0,o=0;for(let a=0;ao?r:n).character}function vOe(e,t,n){for(let r=t;ro===r?o:a===t?"\\"+a:a||(n&&/^[^\n\r"'0-7\\bfnrt-vx\u2028\u2029]$/.test(o)?o:"\\"+o));return t+i+t}function OOe(e,t){return arguments.length===2||typeof t=="number"?I$(e,t):kOe(...arguments)}function Ud(e,t=1){return async(...n)=>{let r=n[t]??{},i=r.plugins??[];return n[t]={...r,plugins:Array.isArray(i)?i:Object.values(i)},await e(...n)}}async function rJ(e,t){let{formatted:n}=await nJ(e,{...t,cursorOffset:-1});return n}async function POe(e,t){return await rJ(e,t)===e}var OEe,y$=(e,t)=>{for(var n in t)OEe(e,n,{get:t[n],enumerable:!0})},PEe,Ib=(e,t)=>(n,r,...i)=>n|1&&r==null?void 0:(t.call(r)??r[e]).apply(r,i),$Ee,IEe,ID,AEe=class{diff(e,t,n={}){let r;typeof n=="function"?(r=n,n={}):("callback"in n)&&(r=n.callback);let i=this.castInput(e,n),s=this.castInput(t,n),o=this.removeEmpty(this.tokenize(i,n)),a=this.removeEmpty(this.tokenize(s,n));return this.diffWithOptionsObj(o,a,n,r)}diffWithOptionsObj(e,t,n,r){var i;let s=(b)=>{if(b=this.postProcess(b,n),r){setTimeout(function(){r(b)},0);return}else return b},o=t.length,a=e.length,l=1,c=o+a;n.maxEditLength!=null&&(c=Math.min(c,n.maxEditLength));let u=(i=n.timeout)!==null&&i!==void 0?i:1/0,p=Date.now()+u,d=[{oldPos:-1,lastComponent:void 0}],f=this.extractCommon(d[0],t,e,0,n);if(d[0].oldPos+1>=a&&f+1>=o)return s(this.buildValues(d[0].lastComponent,t,e));let m=-1/0,y=1/0,h=()=>{for(let b=Math.max(m,-l);b<=Math.min(y,l);b+=2){let g,x=d[b-1],v=d[b+1];x&&(d[b-1]=void 0);let D=!1;if(v){let N=v.oldPos-b;D=v&&0<=N&&N=a&&f+1>=o)return s(this.buildValues(g.lastComponent,t,e))||!0;d[b]=g,g.oldPos+1>=a&&(y=Math.min(y,b-1)),f+1>=o&&(m=Math.max(m,b+1))}l++};if(r)(function b(){setTimeout(function(){if(l>c||Date.now()>p)return r(void 0);h()||b()},0)})();else for(;l<=c&&Date.now()<=p;){let b=h();if(b)return b}}addToPath(e,t,n,r,i){let s=e.lastComponent;return s&&!i.oneChangePerToken&&s.added===t&&s.removed===n?{oldPos:e.oldPos+r,lastComponent:{count:s.count+1,added:t,removed:n,previousComponent:s.previousComponent}}:{oldPos:e.oldPos+r,lastComponent:{count:1,added:t,removed:n,previousComponent:s}}}extractCommon(e,t,n,r,i){let s=t.length,o=n.length,a=e.oldPos,l=a-r,c=0;for(;l+1p.length?f:p}),c.value=this.join(u)}else c.value=this.join(t.slice(a,a+c.count));a+=c.count,c.added||(l+=c.count)}}return r}},REe,jEe,CEe=()=>{},Gu,tK="cr",nK="crlf",MEe="lf",LEe,h$="\r",rK=`\r `,AD=` -`,LEe,UEe,BEe,RD,JEe,mi,Bd="string",gc="array",Hu="cursor",bc="indent",vc="align",_c="trim",Os="group",hl="fill",eo="if-break",xc="indent-if-break",wc="line-suffix",Dc="line-suffix-boundary",yi="line",gl="label",Jo="break-parent",sK,Vd,zEe=(e)=>new Intl.ListFormat("en-US",{type:"disjunction"}).format(e),QEe,ty,N5,v$,yl,aK,lke,cke,FD,qd,dK,gke,x$,hc,fK,mK,bke,vke,xke=()=>/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E-\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED8\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])))?))?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3C-\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE8A\uDE8E-\uDEC2\uDEC6\uDEC8\uDECD-\uDEDC\uDEDF-\uDEEA\uDEEF]|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g,wke=12288,Dke=65510,Tke,Ske=4352,Eke=262141,yK,hK=(e,t)=>{let n=0,r=Math.floor(e.length/2)-1;for(;n<=r;){let i=Math.floor((n+r)/2),s=i*2;if(te[s+1])n=i+1;else return!0}return!1},$5=19968,kke,Nke,Pke=(e)=>eDke?!1:hK(Tke,e),$ke=(e)=>e>=kke&&e<=Nke?!0:eEke?!1:hK(yK,e),Ike,Ake=(e)=>Ike.test(e),Rke,w$,Fke,Cke,gK,Uke=class{#e=[];#t="";#n=0;#r=[];#i=[];#s(){let e=this.#t;e!==""&&(this.#e.push(e),this.#n+=e.length,this.#t="");for(let t of this.#i)this.#r.push(Math.min(t,this.#n));this.#i.length=0}markPosition(){if(this.#r.length+this.#i.length>=2)throw Error("There are too many 'cursor' in doc.");this.#i.push(this.#n+this.#t.length)}write(e){this.#t+=e}trim(){let{text:e,count:t}=vK(this.#t);return this.#t=e,this.#s(),t}finish(){return this.#s(),{text:this.#e.join(""),positions:this.#r}}},Bke,Ko,fl,d$,D$,Kke=class{constructor(e){this.stack=[e]}get key(){let{stack:e,siblings:t}=this;return mi(0,e,t===null?-2:-4)??null}get index(){return this.siblings===null?null:mi(0,this.stack,-2)}get node(){return mi(0,this.stack,-1)}get parent(){return this.getNode(1)}get grandparent(){return this.getNode(2)}get isInArray(){return this.siblings!==null}get siblings(){let{stack:e}=this,t=mi(0,e,-3);return Array.isArray(t)?t:null}get next(){let{siblings:e}=this;return e===null?null:e[this.index+1]}get previous(){let{siblings:e}=this;return e===null?null:e[this.index-1]}get isFirst(){return this.index===0}get isLast(){let{siblings:e,index:t}=this;return e!==null&&t===e.length-1}get isRoot(){return this.stack.length===1}get root(){return this.stack[0]}get ancestors(){return[...this.#t()]}getName(){let{stack:e}=this,{length:t}=e;return t>1?mi(0,e,-2):null}getValue(){return mi(0,this.stack,-1)}getNode(e=0){let t=this.#e(e);return t===-1?null:this.stack[t]}getParentNode(e=0){return this.getNode(e+1)}#e(e){let{stack:t}=this;for(let n=t.length-1;n>=0;n-=2)if(!Array.isArray(t[n])&&--e<0)return n;return-1}call(e,...t){let{stack:n}=this,{length:r}=n,i=mi(0,n,-1);for(let s of t)i=i?.[s],n.push(s,i);try{return e(this)}finally{n.length=r}}callParent(e,t=0){let n=this.#e(t+1),r=this.stack.splice(n+1);try{return e(this)}finally{this.stack.push(...r)}}each(e,...t){let{stack:n}=this,{length:r}=n,i=mi(0,n,-1);for(let s of t)i=i[s],n.push(s,i);try{for(let s=0;s{n[i]=e(r,i,s)},...t),n}match(...e){let t=this.stack.length-1,n=null,r=this.stack[t--];for(let i of e){if(r===void 0)return!1;let s=null;if(typeof n=="number"&&(s=n,n=this.stack[t--],r=this.stack[t--]),i&&!i(r,n,s))return!1;n=this.stack[t--],r=this.stack[t--]}return!0}findAncestor(e){for(let t of this.#t())if(e(t))return t}hasAncestor(e){for(let t of this.#t())if(e(t))return!0;return!1}*#t(){let{stack:e}=this;for(let t=e.length-3;t>=0;t-=2){let n=e[t];Array.isArray(n)||(yield n)}}},Jke,_K,T$,zke,Gu,xK,wK,I5=(e)=>e===` -`||e==="\r"||e==="\u2028"||e==="\u2029",Ud,Ku,TK,SK,s$=()=>!1,kK=(e)=>!/[\S\n\u2028\u2029]/.test(e),E$,NK=()=>!0,p1e=()=>Ju,PK,R5,d1e,LD,f1e,h1e,g1e,b1e,_1e,T1e=(e)=>String(e).split(/[/\\]/).pop(),S1e=(e)=>String(e).startsWith("file:"),k1e=void 0,AK,ey,RK,ml,O1e=(e,t,{descriptor:n})=>{let r=[`${ml.yellow(typeof e=="string"?n.key(e):n.pair(e))} is deprecated`];return t&&r.push(`we now treat it as ${ml.blue(typeof t=="string"?n.key(t):n.pair(t))}`),r.join("; ")+"."},jK,PD,C5,P1e=(e,t,n)=>{let{text:r,list:i}=n.normalizeExpectedResult(n.schemas[e].expected(n)),s=[];return r&&s.push(M5(e,t,r,n.descriptor)),i&&s.push([M5(e,t,i.title,n.descriptor)].concat(i.values.map((o)=>FK(o,n.loggerPrintWidth))).join(` -`)),CK(s,n.loggerPrintWidth)},Zm,a$,MK=(e,t,{descriptor:n,logger:r,schemas:i})=>{let s=[`Ignored unknown option ${ml.yellow(n.pair({key:e,value:t}))}.`],o=$1e(e,Object.keys(i),{maxDistance:3});o&&s.push(`Did you mean ${ml.blue(n.key(o))}?`),r.warn(s.join(" "))},I1e,zu=class{static create(e){return A1e(this,e)}constructor(e){this.name=e.name}default(e){}expected(e){return"nothing"}validate(e,t){return!1}deprecated(e,t){return!1}forward(e,t){}redirect(e,t){}overlap(e,t,n){return e}preprocess(e,t){return e}postprocess(e,t){return PD}},j1e,F1e,C1e,M1e,H1e,z1e,W1e,J5,Q1e,Y1e,X1e,Z1e,eNe=class{constructor(e,t){let{logger:n=console,loggerPrintWidth:r=80,descriptor:i=Q1e,unknown:s=Y1e,invalid:o=X1e,deprecated:a=Z1e,missing:l=()=>!1,required:c=()=>!1,preprocess:u=(d)=>d,postprocess:p=()=>PD}=t||{};this._utils={descriptor:i,logger:n||{warn:()=>{}},loggerPrintWidth:r,schemas:L1e(e,"name"),normalizeDefaultResult:q5,normalizeExpectedResult:LK,normalizeDeprecatedResult:B5,normalizeForwardResult:f$,normalizeRedirectResult:K5,normalizeValidateResult:U5},this._unknownHandler=s,this._invalidHandler=J1e(o),this._deprecatedHandler=a,this._identifyMissing=(d,f)=>!(d in f)||l(d,f),this._identifyRequired=c,this._preprocess=u,this._postprocess=p,this.cleanHistory()}cleanHistory(){this._hasDeprecationWarned=U1e()}normalize(e){let t={},n=[this._preprocess(e,this._utils)],r=()=>{for(;n.length!==0;){let i=n.shift(),s=this._applyNormalization(i,t);n.push(...s)}};r();for(let i of Object.keys(this._utils.schemas)){let s=this._utils.schemas[i];if(!(i in t)){let o=q5(s.default(this._utils));"value"in o&&n.push({[i]:o.value})}}r();for(let i of Object.keys(this._utils.schemas)){if(!(i in t))continue;let s=this._utils.schemas[i],o=t[i],a=s.postprocess(o,this._utils);a!==PD&&(this._applyValidation(a,i,s),t[i]=a)}return this._applyPostprocess(t),this._applyRequiredCheck(t),t}_applyNormalization(e,t){let n=[],{knownKeys:r,unknownKeys:i}=this._partitionOptionKeys(e);for(let s of r){let o=this._utils.schemas[s],a=o.preprocess(e[s],this._utils);this._applyValidation(a,s,o);let l=({from:p,to:d})=>{n.push(typeof d=="string"?{[d]:p}:{[d.key]:d.value})},c=({value:p,redirectTo:d})=>{let f=B5(o.deprecated(p,this._utils),a,!0);if(f!==!1)if(f===!0)this._hasDeprecationWarned(s)||this._utils.logger.warn(this._deprecatedHandler(s,d,this._utils));else for(let{value:m}of f){let y={key:s,value:m};if(!this._hasDeprecationWarned(y)){let h=typeof d=="string"?{key:d,value:m}:d;this._utils.logger.warn(this._deprecatedHandler(y,h,this._utils))}}};f$(o.forward(a,this._utils),a).forEach(l);let u=K5(o.redirect(a,this._utils),a);if(u.redirect.forEach(l),"remain"in u){let p=u.remain;t[s]=s in t?o.overlap(t[s],p,this._utils):p,c({value:p})}for(let{from:p,to:d}of u.redirect)c({value:p,redirectTo:d})}for(let s of i){let o=e[s];this._applyUnknownHandler(s,o,t,(a,l)=>{n.push({[a]:l})})}return n}_applyRequiredCheck(e){for(let t of Object.keys(this._utils.schemas))if(this._identifyMissing(t,e)&&this._identifyRequired(t))throw this._invalidHandler(t,jK,this._utils)}_partitionOptionKeys(e){let[t,n]=B1e(Object.keys(e).filter((r)=>!this._identifyMissing(r,e)),(r)=>(r in this._utils.schemas));return{knownKeys:t,unknownKeys:n}}_applyValidation(e,t,n){let r=U5(n.validate(e,this._utils),e);if(r!==!0)throw this._invalidHandler(t,r.value,this._utils)}_applyUnknownHandler(e,t,n,r){let i=this._unknownHandler(e,t,this._utils);if(i)for(let s of Object.keys(i)){if(this._identifyMissing(s,i))continue;let o=i[s];s in this._utils.schemas?r(s,o):n[s]=o}}_applyPostprocess(e){let t=this._postprocess(e,this._utils);if(t!==PD){if(t.delete)for(let n of t.delete)delete e[n];if(t.override){let{knownKeys:n,unknownKeys:r}=this._partitionOptionKeys(t.override);for(let i of n){let s=t.override[i];this._applyValidation(s,i,this._utils.schemas[i]),e[i]=s}for(let i of r){let s=t.override[i];this._applyUnknownHandler(i,s,e,(o,a)=>{let l=this._utils.schemas[o];this._applyValidation(a,o,l),e[o]=a})}}}}},c$,iNe,sNe,oNe,qK,aNe,lNe,k$,UK,BK=({node:e})=>k$(e)&&UK.has(e.language),dNe,mNe,VK,yNe=(e)=>Object.keys(e).filter((t)=>!VK.has(t)),G5,_Ne,wNe,DNe,H5,ry,z5,Rb,jNe,HK,MNe,LNe,qNe,UNe,zK,JNe,WK="\uFEFF",X5,ZK,eOe,tOe,nOe,rOe="3.9.8",UD,O$,P$,$$,I$,cOe,dOe,mOe,eJ,tJ,yOe,hOe,vOe,xOe,nJ,POe,$Oe;var iJ=q(()=>{NEe=Object.defineProperty,OEe={};y$(OEe,{__debug:()=>$Oe,check:()=>OOe,doc:()=>ZK,format:()=>rJ,formatWithCursor:()=>nJ,getSupportInfo:()=>POe,util:()=>UD,version:()=>rOe});PEe=String.prototype.replaceAll??function(e,t){return e.global?this.replace(e,t):this.split(e).join(t)},$Ee=Ib("replaceAll",function(){if(typeof this=="string")return PEe}),ID=$Ee,AEe=class extends IEe{tokenize(e){return e.slice()}join(e){return e}removeEmpty(e){return e}},REe=new AEe;Ju=FEe,MEe=CEe,LEe=AD;UEe=new Map([[AD,/\n/g],[h$,/\r/g],[rK,/\r\n/g]]);BEe=/\r\n?/g;RD=Symbol.for("comments");JEe=Ib("at",function(){if(Array.isArray(this)||typeof this=="string")return KEe}),mi=JEe,sK=new Set([Hu,bc,vc,_c,Os,hl,eo,xc,wc,Dc,yi,gl,Jo]);Vd=HEe;QEe=class extends Error{name="InvalidDocError";constructor(e){super(WEe(e)),this.doc=e}},ty=QEe,N5={};v$=YEe;yl=Ju,aK=Ju,lke=Ju,cke=Ju;FD={type:Jo},qd={type:Hu};dK={type:yi},gke={type:yi,soft:!0},x$={type:yi,hard:!0},hc=[x$,FD],fK={type:yi,hard:!0,literal:!0},mK=[fK,FD];bke={type:Dc},vke={type:_c};Tke=[12288,12288,65281,65376,65504,65510],yK=[4352,4447,8986,8987,9001,9002,9193,9196,9200,9200,9203,9203,9725,9726,9748,9749,9776,9783,9800,9811,9855,9855,9866,9871,9875,9875,9889,9889,9898,9899,9917,9918,9924,9925,9934,9934,9940,9940,9962,9962,9970,9971,9973,9973,9978,9978,9981,9981,9989,9989,9994,9995,10024,10024,10060,10060,10062,10062,10067,10069,10071,10071,10133,10135,10160,10160,10175,10175,11035,11036,11088,11088,11093,11093,11904,11929,11931,12019,12032,12245,12272,12287,12289,12350,12353,12438,12441,12543,12549,12591,12593,12686,12688,12773,12783,12830,12832,12871,12880,42124,42128,42182,43360,43388,44032,55203,63744,64255,65040,65049,65072,65106,65108,65126,65128,65131,94176,94180,94192,94198,94208,101589,101631,101662,101760,101874,110576,110579,110581,110587,110589,110590,110592,110882,110898,110898,110928,110930,110933,110933,110948,110951,110960,111355,119552,119638,119648,119670,126980,126980,127183,127183,127374,127374,127377,127386,127488,127490,127504,127547,127552,127560,127568,127569,127584,127589,127744,127776,127789,127797,127799,127868,127870,127891,127904,127946,127951,127955,127968,127984,127988,127988,127992,128062,128064,128064,128066,128252,128255,128317,128331,128334,128336,128359,128378,128378,128405,128406,128420,128420,128507,128591,128640,128709,128716,128716,128720,128722,128725,128728,128732,128735,128747,128748,128756,128764,128992,129003,129008,129008,129292,129338,129340,129349,129351,129535,129648,129660,129664,129674,129678,129734,129736,129736,129741,129756,129759,129770,129775,129784,131072,196605,196608,262141],[kke,Nke]=Oke(yK);Ike=/^(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u2600-\u2604\u260E\u2611\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26B0\u26B1\u26C8\u26CF\u26D1\u26D3\u26E9\u26F0\u26F1\u26F4\u26F7\u26F8\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2763\u2764\u27A1\u2934\u2935\u2B05-\u2B07]|\uD83C[\uDD70\uDD71\uDD7E\uDD7F\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF3\uDFF5\uDFF7]|\uD83D[\uDC3F\uDC41\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3])$/,Rke=/[^\x20-\x7F]/;w$=jke,Fke={type:0},Cke={type:1},gK={value:"",length:0,queue:[],get root(){return gK}};Bke=Uke,Ko=Symbol("MODE_BREAK"),fl=Symbol("MODE_FLAT"),d$=Symbol("DOC_FILL_PRINTED_LENGTH");D$=Vke,Jke=Kke;_K=Gke;T$=Hke;zke=Ab(/\s/),Gu=Ab(" \t"),xK=Ab(",; \t"),wK=Ab(/[^\n\r]/);Ud=Wke;Ku=Qke;TK=DK;SK=new WeakMap;E$=i1e;PK=class extends Error{name="ConfigError"},R5=class extends Error{name="UndefinedParserError"},d1e=Object.hasOwn??Function.prototype.call.bind(Object.prototype.hasOwnProperty),LD=d1e,f1e={checkIgnorePragma:{category:"Special",type:"boolean",default:!1,description:"Check whether the file's first docblock comment contains '@noprettier' or '@noformat' to determine if it should be formatted.",cliCategory:"Other"},cursorOffset:{category:"Special",type:"int",default:-1,range:{start:-1,end:1/0,step:1},description:"Print (to stderr) where a cursor at the given position would move to after formatting.",cliCategory:"Editor"},endOfLine:{category:"Global",type:"choice",default:"lf",description:"Which end of line characters to apply.",choices:[{value:"lf",description:"Line Feed only (\\n), common on Linux and macOS as well as inside git repos"},{value:"crlf",description:"Carriage Return + Line Feed characters (\\r\\n), common on Windows"},{value:"cr",description:"Carriage Return character only (\\r), used very rarely"},{value:"auto",description:`Maintain existing +`,qEe,BEe,VEe,RD,GEe,yi,Kd="string",gc="array",zu="cursor",bc="indent",vc="align",_c="trim",Ps="group",hl="fill",to="if-break",xc="indent-if-break",wc="line-suffix",Dc="line-suffix-boundary",hi="line",gl="label",Jo="break-parent",sK,Jd,WEe=(e)=>new Intl.ListFormat("en-US",{type:"disjunction"}).format(e),YEe,ry,N5,v$,yl,aK,cke,uke,FD,Bd,dK,bke,x$,hc,fK,mK,vke,_ke,wke=()=>/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E-\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED8\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])))?))?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3C-\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE8A\uDE8E-\uDEC2\uDEC6\uDEC8\uDECD-\uDEDC\uDEDF-\uDEEA\uDEEF]|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g,Dke=12288,Tke=65510,Ske,Eke=4352,kke=262141,yK,hK=(e,t)=>{let n=0,r=Math.floor(e.length/2)-1;for(;n<=r;){let i=Math.floor((n+r)/2),s=i*2;if(te[s+1])n=i+1;else return!0}return!1},$5=19968,Nke,Oke,$ke=(e)=>eTke?!1:hK(Ske,e),Ike=(e)=>e>=Nke&&e<=Oke?!0:ekke?!1:hK(yK,e),Ake,Rke=(e)=>Ake.test(e),jke,w$,Cke,Mke,gK,Bke=class{#e=[];#t="";#n=0;#r=[];#i=[];#s(){let e=this.#t;e!==""&&(this.#e.push(e),this.#n+=e.length,this.#t="");for(let t of this.#i)this.#r.push(Math.min(t,this.#n));this.#i.length=0}markPosition(){if(this.#r.length+this.#i.length>=2)throw Error("There are too many 'cursor' in doc.");this.#i.push(this.#n+this.#t.length)}write(e){this.#t+=e}trim(){let{text:e,count:t}=vK(this.#t);return this.#t=e,this.#s(),t}finish(){return this.#s(),{text:this.#e.join(""),positions:this.#r}}},Vke,Ko,fl,d$,D$,Jke=class{constructor(e){this.stack=[e]}get key(){let{stack:e,siblings:t}=this;return yi(0,e,t===null?-2:-4)??null}get index(){return this.siblings===null?null:yi(0,this.stack,-2)}get node(){return yi(0,this.stack,-1)}get parent(){return this.getNode(1)}get grandparent(){return this.getNode(2)}get isInArray(){return this.siblings!==null}get siblings(){let{stack:e}=this,t=yi(0,e,-3);return Array.isArray(t)?t:null}get next(){let{siblings:e}=this;return e===null?null:e[this.index+1]}get previous(){let{siblings:e}=this;return e===null?null:e[this.index-1]}get isFirst(){return this.index===0}get isLast(){let{siblings:e,index:t}=this;return e!==null&&t===e.length-1}get isRoot(){return this.stack.length===1}get root(){return this.stack[0]}get ancestors(){return[...this.#t()]}getName(){let{stack:e}=this,{length:t}=e;return t>1?yi(0,e,-2):null}getValue(){return yi(0,this.stack,-1)}getNode(e=0){let t=this.#e(e);return t===-1?null:this.stack[t]}getParentNode(e=0){return this.getNode(e+1)}#e(e){let{stack:t}=this;for(let n=t.length-1;n>=0;n-=2)if(!Array.isArray(t[n])&&--e<0)return n;return-1}call(e,...t){let{stack:n}=this,{length:r}=n,i=yi(0,n,-1);for(let s of t)i=i?.[s],n.push(s,i);try{return e(this)}finally{n.length=r}}callParent(e,t=0){let n=this.#e(t+1),r=this.stack.splice(n+1);try{return e(this)}finally{this.stack.push(...r)}}each(e,...t){let{stack:n}=this,{length:r}=n,i=yi(0,n,-1);for(let s of t)i=i[s],n.push(s,i);try{for(let s=0;s{n[i]=e(r,i,s)},...t),n}match(...e){let t=this.stack.length-1,n=null,r=this.stack[t--];for(let i of e){if(r===void 0)return!1;let s=null;if(typeof n=="number"&&(s=n,n=this.stack[t--],r=this.stack[t--]),i&&!i(r,n,s))return!1;n=this.stack[t--],r=this.stack[t--]}return!0}findAncestor(e){for(let t of this.#t())if(e(t))return t}hasAncestor(e){for(let t of this.#t())if(e(t))return!0;return!1}*#t(){let{stack:e}=this;for(let t=e.length-3;t>=0;t-=2){let n=e[t];Array.isArray(n)||(yield n)}}},Gke,_K,T$,Wke,Hu,xK,wK,I5=(e)=>e===` +`||e==="\r"||e==="\u2028"||e==="\u2029",Vd,Ju,TK,SK,s$=()=>!1,kK=(e)=>!/[\S\n\u2028\u2029]/.test(e),E$,NK=()=>!0,d1e=()=>Gu,PK,R5,f1e,LD,m1e,g1e,b1e,v1e,x1e,S1e=(e)=>String(e).split(/[/\\]/).pop(),E1e=(e)=>String(e).startsWith("file:"),N1e=void 0,AK,ny,RK,ml,P1e=(e,t,{descriptor:n})=>{let r=[`${ml.yellow(typeof e=="string"?n.key(e):n.pair(e))} is deprecated`];return t&&r.push(`we now treat it as ${ml.blue(typeof t=="string"?n.key(t):n.pair(t))}`),r.join("; ")+"."},jK,PD,C5,$1e=(e,t,n)=>{let{text:r,list:i}=n.normalizeExpectedResult(n.schemas[e].expected(n)),s=[];return r&&s.push(M5(e,t,r,n.descriptor)),i&&s.push([M5(e,t,i.title,n.descriptor)].concat(i.values.map((o)=>FK(o,n.loggerPrintWidth))).join(` +`)),CK(s,n.loggerPrintWidth)},ty,a$,MK=(e,t,{descriptor:n,logger:r,schemas:i})=>{let s=[`Ignored unknown option ${ml.yellow(n.pair({key:e,value:t}))}.`],o=I1e(e,Object.keys(i),{maxDistance:3});o&&s.push(`Did you mean ${ml.blue(n.key(o))}?`),r.warn(s.join(" "))},A1e,Wu=class{static create(e){return R1e(this,e)}constructor(e){this.name=e.name}default(e){}expected(e){return"nothing"}validate(e,t){return!1}deprecated(e,t){return!1}forward(e,t){}redirect(e,t){}overlap(e,t,n){return e}preprocess(e,t){return e}postprocess(e,t){return PD}},F1e,C1e,M1e,L1e,z1e,W1e,Q1e,J5,Y1e,X1e,Z1e,eNe,tNe=class{constructor(e,t){let{logger:n=console,loggerPrintWidth:r=80,descriptor:i=Y1e,unknown:s=X1e,invalid:o=Z1e,deprecated:a=eNe,missing:l=()=>!1,required:c=()=>!1,preprocess:u=(d)=>d,postprocess:p=()=>PD}=t||{};this._utils={descriptor:i,logger:n||{warn:()=>{}},loggerPrintWidth:r,schemas:q1e(e,"name"),normalizeDefaultResult:q5,normalizeExpectedResult:LK,normalizeDeprecatedResult:B5,normalizeForwardResult:f$,normalizeRedirectResult:K5,normalizeValidateResult:U5},this._unknownHandler=s,this._invalidHandler=G1e(o),this._deprecatedHandler=a,this._identifyMissing=(d,f)=>!(d in f)||l(d,f),this._identifyRequired=c,this._preprocess=u,this._postprocess=p,this.cleanHistory()}cleanHistory(){this._hasDeprecationWarned=B1e()}normalize(e){let t={},n=[this._preprocess(e,this._utils)],r=()=>{for(;n.length!==0;){let i=n.shift(),s=this._applyNormalization(i,t);n.push(...s)}};r();for(let i of Object.keys(this._utils.schemas)){let s=this._utils.schemas[i];if(!(i in t)){let o=q5(s.default(this._utils));"value"in o&&n.push({[i]:o.value})}}r();for(let i of Object.keys(this._utils.schemas)){if(!(i in t))continue;let s=this._utils.schemas[i],o=t[i],a=s.postprocess(o,this._utils);a!==PD&&(this._applyValidation(a,i,s),t[i]=a)}return this._applyPostprocess(t),this._applyRequiredCheck(t),t}_applyNormalization(e,t){let n=[],{knownKeys:r,unknownKeys:i}=this._partitionOptionKeys(e);for(let s of r){let o=this._utils.schemas[s],a=o.preprocess(e[s],this._utils);this._applyValidation(a,s,o);let l=({from:p,to:d})=>{n.push(typeof d=="string"?{[d]:p}:{[d.key]:d.value})},c=({value:p,redirectTo:d})=>{let f=B5(o.deprecated(p,this._utils),a,!0);if(f!==!1)if(f===!0)this._hasDeprecationWarned(s)||this._utils.logger.warn(this._deprecatedHandler(s,d,this._utils));else for(let{value:m}of f){let y={key:s,value:m};if(!this._hasDeprecationWarned(y)){let h=typeof d=="string"?{key:d,value:m}:d;this._utils.logger.warn(this._deprecatedHandler(y,h,this._utils))}}};f$(o.forward(a,this._utils),a).forEach(l);let u=K5(o.redirect(a,this._utils),a);if(u.redirect.forEach(l),"remain"in u){let p=u.remain;t[s]=s in t?o.overlap(t[s],p,this._utils):p,c({value:p})}for(let{from:p,to:d}of u.redirect)c({value:p,redirectTo:d})}for(let s of i){let o=e[s];this._applyUnknownHandler(s,o,t,(a,l)=>{n.push({[a]:l})})}return n}_applyRequiredCheck(e){for(let t of Object.keys(this._utils.schemas))if(this._identifyMissing(t,e)&&this._identifyRequired(t))throw this._invalidHandler(t,jK,this._utils)}_partitionOptionKeys(e){let[t,n]=V1e(Object.keys(e).filter((r)=>!this._identifyMissing(r,e)),(r)=>(r in this._utils.schemas));return{knownKeys:t,unknownKeys:n}}_applyValidation(e,t,n){let r=U5(n.validate(e,this._utils),e);if(r!==!0)throw this._invalidHandler(t,r.value,this._utils)}_applyUnknownHandler(e,t,n,r){let i=this._unknownHandler(e,t,this._utils);if(i)for(let s of Object.keys(i)){if(this._identifyMissing(s,i))continue;let o=i[s];s in this._utils.schemas?r(s,o):n[s]=o}}_applyPostprocess(e){let t=this._postprocess(e,this._utils);if(t!==PD){if(t.delete)for(let n of t.delete)delete e[n];if(t.override){let{knownKeys:n,unknownKeys:r}=this._partitionOptionKeys(t.override);for(let i of n){let s=t.override[i];this._applyValidation(s,i,this._utils.schemas[i]),e[i]=s}for(let i of r){let s=t.override[i];this._applyUnknownHandler(i,s,e,(o,a)=>{let l=this._utils.schemas[o];this._applyValidation(a,o,l),e[o]=a})}}}}},c$,sNe,oNe,aNe,qK,lNe,cNe,k$,UK,BK=({node:e})=>k$(e)&&UK.has(e.language),fNe,yNe,VK,hNe=(e)=>Object.keys(e).filter((t)=>!VK.has(t)),G5,xNe,DNe,TNe,H5,sy,z5,Rb,FNe,HK,LNe,qNe,UNe,BNe,zK,GNe,WK="\uFEFF",X5,ZK,tOe,nOe,rOe,iOe="3.9.8",UD,O$,P$,$$,I$,uOe,fOe,yOe,eJ,tJ,hOe,gOe,_Oe,wOe,nJ,$Oe,IOe;var iJ=q(()=>{OEe=Object.defineProperty,PEe={};y$(PEe,{__debug:()=>IOe,check:()=>POe,doc:()=>ZK,format:()=>rJ,formatWithCursor:()=>nJ,getSupportInfo:()=>$Oe,util:()=>UD,version:()=>iOe});$Ee=String.prototype.replaceAll??function(e,t){return e.global?this.replace(e,t):this.split(e).join(t)},IEe=Ib("replaceAll",function(){if(typeof this=="string")return $Ee}),ID=IEe,REe=class extends AEe{tokenize(e){return e.slice()}join(e){return e}removeEmpty(e){return e}},jEe=new REe;Gu=CEe,LEe=MEe,qEe=AD;BEe=new Map([[AD,/\n/g],[h$,/\r/g],[rK,/\r\n/g]]);VEe=/\r\n?/g;RD=Symbol.for("comments");GEe=Ib("at",function(){if(Array.isArray(this)||typeof this=="string")return JEe}),yi=GEe,sK=new Set([zu,bc,vc,_c,Ps,hl,to,xc,wc,Dc,hi,gl,Jo]);Jd=zEe;YEe=class extends Error{name="InvalidDocError";constructor(e){super(QEe(e)),this.doc=e}},ry=YEe,N5={};v$=XEe;yl=Gu,aK=Gu,cke=Gu,uke=Gu;FD={type:Jo},Bd={type:zu};dK={type:hi},bke={type:hi,soft:!0},x$={type:hi,hard:!0},hc=[x$,FD],fK={type:hi,hard:!0,literal:!0},mK=[fK,FD];vke={type:Dc},_ke={type:_c};Ske=[12288,12288,65281,65376,65504,65510],yK=[4352,4447,8986,8987,9001,9002,9193,9196,9200,9200,9203,9203,9725,9726,9748,9749,9776,9783,9800,9811,9855,9855,9866,9871,9875,9875,9889,9889,9898,9899,9917,9918,9924,9925,9934,9934,9940,9940,9962,9962,9970,9971,9973,9973,9978,9978,9981,9981,9989,9989,9994,9995,10024,10024,10060,10060,10062,10062,10067,10069,10071,10071,10133,10135,10160,10160,10175,10175,11035,11036,11088,11088,11093,11093,11904,11929,11931,12019,12032,12245,12272,12287,12289,12350,12353,12438,12441,12543,12549,12591,12593,12686,12688,12773,12783,12830,12832,12871,12880,42124,42128,42182,43360,43388,44032,55203,63744,64255,65040,65049,65072,65106,65108,65126,65128,65131,94176,94180,94192,94198,94208,101589,101631,101662,101760,101874,110576,110579,110581,110587,110589,110590,110592,110882,110898,110898,110928,110930,110933,110933,110948,110951,110960,111355,119552,119638,119648,119670,126980,126980,127183,127183,127374,127374,127377,127386,127488,127490,127504,127547,127552,127560,127568,127569,127584,127589,127744,127776,127789,127797,127799,127868,127870,127891,127904,127946,127951,127955,127968,127984,127988,127988,127992,128062,128064,128064,128066,128252,128255,128317,128331,128334,128336,128359,128378,128378,128405,128406,128420,128420,128507,128591,128640,128709,128716,128716,128720,128722,128725,128728,128732,128735,128747,128748,128756,128764,128992,129003,129008,129008,129292,129338,129340,129349,129351,129535,129648,129660,129664,129674,129678,129734,129736,129736,129741,129756,129759,129770,129775,129784,131072,196605,196608,262141],[Nke,Oke]=Pke(yK);Ake=/^(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u2600-\u2604\u260E\u2611\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26B0\u26B1\u26C8\u26CF\u26D1\u26D3\u26E9\u26F0\u26F1\u26F4\u26F7\u26F8\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2763\u2764\u27A1\u2934\u2935\u2B05-\u2B07]|\uD83C[\uDD70\uDD71\uDD7E\uDD7F\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF3\uDFF5\uDFF7]|\uD83D[\uDC3F\uDC41\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3])$/,jke=/[^\x20-\x7F]/;w$=Fke,Cke={type:0},Mke={type:1},gK={value:"",length:0,queue:[],get root(){return gK}};Vke=Bke,Ko=Symbol("MODE_BREAK"),fl=Symbol("MODE_FLAT"),d$=Symbol("DOC_FILL_PRINTED_LENGTH");D$=Kke,Gke=Jke;_K=Hke;T$=zke;Wke=Ab(/\s/),Hu=Ab(" \t"),xK=Ab(",; \t"),wK=Ab(/[^\n\r]/);Vd=Qke;Ju=Yke;TK=DK;SK=new WeakMap;E$=s1e;PK=class extends Error{name="ConfigError"},R5=class extends Error{name="UndefinedParserError"},f1e=Object.hasOwn??Function.prototype.call.bind(Object.prototype.hasOwnProperty),LD=f1e,m1e={checkIgnorePragma:{category:"Special",type:"boolean",default:!1,description:"Check whether the file's first docblock comment contains '@noprettier' or '@noformat' to determine if it should be formatted.",cliCategory:"Other"},cursorOffset:{category:"Special",type:"int",default:-1,range:{start:-1,end:1/0,step:1},description:"Print (to stderr) where a cursor at the given position would move to after formatting.",cliCategory:"Editor"},endOfLine:{category:"Global",type:"choice",default:"lf",description:"Which end of line characters to apply.",choices:[{value:"lf",description:"Line Feed only (\\n), common on Linux and macOS as well as inside git repos"},{value:"crlf",description:"Carriage Return + Line Feed characters (\\r\\n), common on Windows"},{value:"cr",description:"Carriage Return character only (\\r), used very rarely"},{value:"auto",description:`Maintain existing (mixed values within one file are normalised by looking at what's used after the first line)`}]},filepath:{category:"Special",type:"path",description:"Specify the input filepath. This will be used to do parser inference.",cliName:"stdin-filepath",cliCategory:"Other",cliDescription:"Path to the file to pretend that stdin comes from."},insertPragma:{category:"Special",type:"boolean",default:!1,description:"Insert @format pragma into file's first docblock comment.",cliCategory:"Other"},parser:{category:"Global",type:"choice",default:void 0,description:"Which parser to use.",exception:(e)=>typeof e=="string"||typeof e=="function",choices:[{value:"flow",description:"Flow"},{value:"babel",description:"JavaScript"},{value:"babel-flow",description:"Flow"},{value:"babel-ts",description:"TypeScript"},{value:"typescript",description:"TypeScript"},{value:"acorn",description:"JavaScript"},{value:"espree",description:"JavaScript"},{value:"meriyah",description:"JavaScript"},{value:"css",description:"CSS"},{value:"less",description:"Less"},{value:"scss",description:"SCSS"},{value:"json",description:"JSON"},{value:"json5",description:"JSON5"},{value:"jsonc",description:"JSON with Comments"},{value:"json-stringify",description:"JSON.stringify"},{value:"graphql",description:"GraphQL"},{value:"markdown",description:"Markdown"},{value:"mdx",description:"MDX"},{value:"vue",description:"Vue"},{value:"yaml",description:"YAML"},{value:"glimmer",description:"Ember / Handlebars"},{value:"html",description:"HTML"},{value:"angular",description:"Angular"},{value:"lwc",description:"Lightning Web Components"},{value:"mjml",description:"MJML"}]},plugins:{type:"path",array:!0,default:[{value:[]}],category:"Global",description:"Add a plugin. Multiple plugins can be passed as separate `--plugin`s.",exception:(e)=>typeof e=="string"||typeof e=="object",cliName:"plugin",cliCategory:"Config"},printWidth:{category:"Global",type:"int",default:80,description:"The line length where Prettier will try wrap.",range:{start:0,end:1/0,step:1}},rangeEnd:{category:"Special",type:"int",default:1/0,range:{start:0,end:1/0,step:1},description:`Format code ending at a given character offset (exclusive). The range will extend forwards to the end of the selected statement.`,cliCategory:"Editor"},rangeStart:{category:"Special",type:"int",default:0,range:{start:0,end:1/0,step:1},description:`Format code starting at a given character offset. -The range will extend backwards to the start of the first line containing the selected statement.`,cliCategory:"Editor"},requirePragma:{category:"Special",type:"boolean",default:!1,description:"Require either '@prettier' or '@format' to be present in the file's first docblock comment in order for it to be formatted.",cliCategory:"Other"},tabWidth:{type:"int",category:"Global",default:2,description:"Number of spaces per indentation level.",range:{start:0,end:1/0,step:1}},useTabs:{category:"Global",type:"boolean",default:!1,description:"Indent with tabs instead of spaces."},embeddedLanguageFormatting:{category:"Global",type:"choice",default:"auto",description:"Control how Prettier formats quoted code embedded in the file.",choices:[{value:"auto",description:"Format embedded code if Prettier can automatically identify it."},{value:"off",description:"Never automatically format embedded code."}]}};h1e=Array.prototype.toReversed??function(){return[...this].reverse()},g1e=Ib("toReversed",function(){if(Array.isArray(this))return h1e}),b1e=g1e;_1e=v1e();AK=N1e,ey={key:(e)=>/^[$_a-zA-Z][$_a-zA-Z0-9]*$/.test(e)?e:JSON.stringify(e),value(e){if(e===null||typeof e!="object")return JSON.stringify(e);if(Array.isArray(e))return`[${e.map((n)=>ey.value(n)).join(", ")}]`;let t=Object.keys(e);return t.length===0?"{}":`{ ${t.map((n)=>`${ey.key(n)}: ${ey.value(e[n])}`).join(", ")} }`},pair:({key:e,value:t})=>ey.value({[e]:t})},RK=new Proxy(String,{get:()=>RK}),ml=RK,jK=Symbol.for("vnopts.VALUE_NOT_EXIST"),PD=Symbol.for("vnopts.VALUE_UNCHANGED"),C5=" ".repeat(2);Zm=[],a$=[];I1e=["default","expected","validate","deprecated","forward","redirect","overlap","preprocess","postprocess"];j1e=class extends zu{constructor(e){super(e),this._sourceName=e.sourceName}expected(e){return e.schemas[this._sourceName].expected(e)}validate(e,t){return t.schemas[this._sourceName].validate(e,t)}redirect(e,t){return this._sourceName}},F1e=class extends zu{expected(){return"anything"}validate(){return!0}},C1e=class extends zu{constructor({valueSchema:e,name:t=e.name,...n}){super({...n,name:t}),this._valueSchema=e}expected(e){let{text:t,list:n}=e.normalizeExpectedResult(this._valueSchema.expected(e));return{text:t&&`an array of ${t}`,list:n&&{title:"an array of the following values",values:[{list:n}]}}}validate(e,t){if(!Array.isArray(e))return!1;let n=[];for(let r of e){let i=t.normalizeValidateResult(this._valueSchema.validate(r,t),r);i!==!0&&n.push(i.value)}return n.length===0?!0:{value:n}}deprecated(e,t){let n=[];for(let r of e){let i=t.normalizeDeprecatedResult(this._valueSchema.deprecated(r,t),r);i!==!1&&n.push(...i.map(({value:s})=>({value:[s]})))}return n}forward(e,t){let n=[];for(let r of e){let i=t.normalizeForwardResult(this._valueSchema.forward(r,t),r);n.push(...i.map(L5))}return n}redirect(e,t){let n=[],r=[];for(let i of e){let s=t.normalizeRedirectResult(this._valueSchema.redirect(i,t),i);"remain"in s&&n.push(s.remain),r.push(...s.redirect.map(L5))}return n.length===0?{redirect:r}:{redirect:r,remain:n}}overlap(e,t){return e.concat(t)}};M1e=class extends zu{expected(){return"true or false"}validate(e){return typeof e=="boolean"}};H1e=class extends zu{constructor(e){super(e),this._choices=q1e(e.choices.map((t)=>t&&typeof t=="object"?t:{value:t}),"value")}expected({descriptor:e}){let t=Array.from(this._choices.keys()).map((i)=>this._choices.get(i)).filter(({hidden:i})=>!i).map((i)=>i.value).sort(K1e).map(e.value),n=t.slice(0,-2),r=t.slice(-2);return{text:n.concat(r.join(" or ")).join(", "),list:{title:"one of the following values",values:t}}}validate(e){return this._choices.has(e)}deprecated(e){let t=this._choices.get(e);return t&&t.deprecated?{value:e}:!1}forward(e){let t=this._choices.get(e);return t?t.forward:void 0}redirect(e){let t=this._choices.get(e);return t?t.redirect:void 0}},z1e=class extends zu{expected(){return"a number"}validate(e,t){return typeof e=="number"}},W1e=class extends z1e{expected(){return"an integer"}validate(e,t){return t.normalizeValidateResult(super.validate(e,t),e)===!0&&V1e(e)}},J5=class extends zu{expected(){return"a string"}validate(e){return typeof e=="string"}},Q1e=ey,Y1e=MK,X1e=P1e,Z1e=O1e;iNe=tNe,sNe=Array.prototype.findLast??function(e){for(let t=this.length-1;t>=0;t--){let n=this[t];if(e(n,t,this))return n}},oNe=Ib("findLast",function(){if(Array.isArray(this))return sNe}),qK=oNe,aNe=Symbol.for("PRETTIER_IS_FRONT_MATTER"),lNe=[];k$=cNe,UK=new Set(["yaml","toml"]);dNe=pNe;mNe=fNe,VK=new Set(["tokens","comments","parent","enclosingNode","precedingNode","followingNode"]);G5=hNe;_Ne=new WeakMap;wNe=["clean","embed","print"],DNe=Object.fromEntries(wNe.map((e)=>[e,!1]));H5={astFormat:"estree",printer:{},originalText:void 0,locStart:null,locEnd:null,getVisitorKeys:null};ry=ENe,z5=/\r\n|[\n\r\u2028\u2029]/;Rb=PNe;jNe=RNe;HK=FNe;MNe=CNe,LNe=Array.prototype.findLastIndex??function(e){for(let t=this.length-1;t>=0;t--){let n=this[t];if(e(n,t,this))return t}return-1},qNe=Ib("findLastIndex",function(){if(Array.isArray(this))return LNe}),UNe=qNe;zK=new Set(["JsonRoot","ObjectExpression","ArrayExpression","StringLiteral","NumericLiteral","BooleanLiteral","NullLiteral","UnaryExpression","TemplateLiteral"]),JNe=new Set(["OperationDefinition","FragmentDefinition","VariableDefinition","TypeExtensionDefinition","ObjectTypeDefinition","FieldDefinition","DirectiveDefinition","EnumTypeDefinition","EnumValueDefinition","InputValueDefinition","InputObjectTypeDefinition","SchemaDefinition","OperationTypeDefinition","InterfaceTypeDefinition","UnionTypeDefinition","ScalarTypeDefinition"]);X5=Symbol("cursor");ZK={};y$(ZK,{builders:()=>eOe,printer:()=>tOe,utils:()=>nOe});eOe={join:pK,line:dK,softline:gke,hardline:hc,literalline:mK,group:uK,conditionalGroup:fke,fill:dke,lineSuffix:p$,lineSuffixBoundary:bke,cursor:qd,breakParent:FD,ifBreak:mke,trim:vke,indent:$D,indentIfBreak:yke,align:ny,addAlignmentToDoc:cK,markAsRoot:lK,dedentToRoot:uke,dedent:pke,hardlineWithoutBreakParent:x$,literallineWithoutBreakParent:fK,label:hke,concat:(e)=>e},tOe={printDocToString:CD},nOe={willBreak:ZEe,traverseDoc:v$,findInDoc:_$,mapDoc:jD,removeLines:nke,stripTrailingHardline:oK,replaceEndOfLine:ske,canBreak:ake},UD={};y$(UD,{addDanglingComment:()=>Md,addLeadingComment:()=>Pb,addTrailingComment:()=>$b,getAlignmentSize:()=>D$,getIndentSize:()=>cOe,getMaxContinuousCount:()=>dOe,getNextNonSpaceNonCommentCharacter:()=>mOe,getNextNonSpaceNonCommentCharacterIndex:()=>DOe,getPreferredQuote:()=>gOe,getStringWidth:()=>w$,hasNewline:()=>Ku,hasNewlineInRange:()=>vOe,hasSpaces:()=>xOe,isNextLineEmpty:()=>NOe,isNextLineEmptyAfterIndex:()=>I$,isPreviousLineEmpty:()=>SOe,makeString:()=>kOe,skip:()=>Ab,skipEverythingButNewLine:()=>wK,skipInlineComment:()=>O$,skipNewline:()=>Ud,skipSpaces:()=>Gu,skipToLineEnd:()=>xK,skipTrailingComment:()=>P$,skipWhitespace:()=>zke});O$=iOe;P$=sOe;$$=oOe;I$=aOe;cOe=lOe;dOe=pOe;mOe=fOe,eJ=Object.freeze({character:"'",codePoint:39}),tJ=Object.freeze({character:'"',codePoint:34}),yOe=Object.freeze({preferred:eJ,alternate:tJ}),hOe=Object.freeze({preferred:tJ,alternate:eJ});vOe=bOe;xOe=_Oe;nJ=Ld(XK);POe=Ld($K,0),$Oe={parse:Ld(WNe),formatAST:Ld(QNe),formatDoc:Ld(YNe),printToDoc:Ld(XNe),printDocToString:Ld(ZNe)}});var sJ=q(()=>{vt();Xs();It();Gt()});function COe(e){return this[e<0?this.length+e:e]}function qOe(e){let t=e.length;while(t>0&&(e[t-1]==="\r"||e[t-1]===` -`))t--;return t`'${i}'`));return`Unexpected doc.type '${e.type}'. -Expected it to be ${r}.`}function GOe(e,t,n,r){let i=[e];while(i.length>0){let s=i.pop();if(s===oJ){n(i.pop());continue}if(n)i.push(s,oJ);let o=Hd(s);if(!o)throw new iy(s);if(t?.(s)===!1)continue;switch(o){case Tc:case Xu:{let a=o===Tc?s:s.parts;for(let l=a.length,c=l-1;c>=0;--c)i.push(a[c]);break}case Na:i.push(s.flatContents,s.breakContents);break;case Ho:if(r&&s.expandedStates)for(let a=s.expandedStates.length,l=a-1;l>=0;--l)i.push(s.expandedStates[l]);else i.push(s.contents);break;case Qu:case Wu:case Zu:case np:case ep:i.push(s.contents);break;case Jd:case Gd:case Yu:case tp:case Zi:case _l:break;default:throw new iy(s)}}}function JD(e,t){if(typeof e==="string")return t(e);let n=new Map;return r(e);function r(s){return UOe(n,s,i)}function i(s){switch(Hd(s)){case Tc:return t(s.map(r));case Xu:return t({...s,parts:s.parts.map(r)});case Na:return t({...s,breakContents:r(s.breakContents),flatContents:r(s.flatContents)});case Ho:{let{expandedStates:o,contents:a}=s;if(o)o=o.map(r),a=o[0];else a=r(a);return t({...s,contents:a,expandedStates:o})}case Qu:case Wu:case Zu:case np:case ep:return t({...s,contents:r(s.contents)});case Jd:case Gd:case Yu:case tp:case Zi:case _l:return t(s);default:throw new iy(s)}}}function j$(e,t,n){let r=n,i=!1;function s(o){if(i)return!1;let a=t(o);if(a!==void 0)i=!0,r=a}return R$(e,s),r}function HOe(e){if(e.type===Ho&&e.break)return!0;if(e.type===Zi&&e.hard)return!0;if(e.type===_l)return!0}function zOe(e){return j$(e,HOe,!1)}function aJ(e){if(e.length>0){let t=Kd(0,e,-1);if(!t.expandedStates&&!t.break)t.break="propagated"}return null}function WOe(e){let t=new Set,n=[];function r(s){if(s.type===_l)aJ(n);if(s.type===Ho){if(n.push(s),t.has(s))return!1;t.add(s)}}function i(s){if(s.type===Ho){if(n.pop().break)aJ(n)}}R$(e,r,i,!0)}function QOe(e){if(e.type===Zi&&!e.hard)return e.soft?"":" ";if(e.type===Na)return e.flatContents;return e}function YOe(e){return JD(e,QOe)}function lJ(e){e=[...e];while(e.length>=2&&Kd(0,e,-2).type===Zi&&Kd(0,e,-1).type===_l)e.length-=2;if(e.length>0){let t=jb(Kd(0,e,-1));e[e.length-1]=t}return e}function jb(e){switch(Hd(e)){case Wu:case Zu:case Ho:case ep:case np:{let t=jb(e.contents);return{...e,contents:t}}case Na:return{...e,breakContents:jb(e.breakContents),flatContents:jb(e.flatContents)};case Xu:return{...e,parts:lJ(e.parts)};case Tc:return lJ(e);case Jd:return qOe(e);case Qu:case Gd:case Yu:case tp:case Zi:case _l:break;default:throw new iy(e)}return e}function XOe(e){return jb(ePe(e))}function ZOe(e){switch(Hd(e)){case Xu:{let{parts:t}=e;if(t.every((n)=>n===""))return"";if(t.length===1)return t[0];break}case Ho:if(!e.contents&&!e.id&&!e.break&&!e.expandedStates)return"";if(e.contents.type===Ho&&e.contents.id===e.id&&e.contents.break===e.break&&e.contents.expandedStates===e.expandedStates)return e.contents;break;case Qu:case Wu:case Zu:case ep:if(!e.contents)return"";break;case Na:if(!e.flatContents&&!e.breakContents)return"";break;case Tc:{let t=[];for(let n of e){if(!n)continue;let[r,...i]=Array.isArray(n)?n:[n];if(typeof r==="string"&&typeof Kd(0,t,-1)==="string")t[t.length-1]+=r;else t.push(r);t.push(...i)}if(t.length===0)return"";if(t.length===1)return t[0];return t}case Jd:case Gd:case Yu:case tp:case Zi:case np:case _l:break;default:throw new iy(e)}return e}function ePe(e){return JD(e,(t)=>ZOe(t))}function tPe(e,t=hJ){return JD(e,(n)=>typeof n==="string"?mJ(t,n.split(` -`)):n)}function nPe(e){if(e.type===Zi)return!0}function rPe(e){return j$(e,nPe,!1)}function VD(e){return vl(e),{type:Wu,contents:e}}function sy(e,t){return sPe(e),vl(t),{type:Qu,contents:t,n:e}}function oPe(e){return sy(Number.NEGATIVE_INFINITY,e)}function aPe(e){return sy({type:"root"},e)}function lPe(e){return sy(-1,e)}function cPe(e,t,n){vl(e);let r=e;if(t>0){for(let i=0;i=i&&cJ<=s)return[i,s];if(s-i>n-t)t=i,n=s}return[t,n]}function GPe(e){if(!e)return 0;if(!JPe.test(e))return e.length;let t=0;e=e.replace(IPe(),(n)=>(t+=KPe(n)?1:2,""));for(let n of e){let r=n.codePointAt(0);if(r<=31||r>=127&&r<=159)continue;if(r>=768&&r<=879)continue;if(r>=65024&&r<=65039)continue;t+=UPe(r)||BPe(r)?2:1}return t}function SJ(e,t,n){let r=t.type===xJ?e.queue.slice(0,-1):[...e.queue,t],i="",s=0,o=0,a=0;for(let m of r)switch(m.type){case _J:if(u(),n.useTabs)l(1);else c(n.tabWidth);break;case DJ:{let{string:y}=m;u(),i+=y,s+=y.length;break}case wJ:{let{width:y}=m;o+=1,a+=y;break}default:throw Error(`Unexpected indent comment '${m.type}'.`)}return d(),{...e,value:i,length:s,queue:r};function l(m){i+="\t".repeat(m),s+=n.tabWidth*m}function c(m){i+=" ".repeat(m),s+=m}function u(){if(n.useTabs)p();else d()}function p(){if(o>0)l(o);f()}function d(){if(a>0)c(a);f()}function f(){o=0,a=0}}function WPe(e,t,n){if(!t)return e;if(t.type==="root")return{...e,root:e};if(t===Number.NEGATIVE_INFINITY)return e.root;let r;if(typeof t==="number")if(t<0)r=zPe;else r={type:wJ,width:t};else r={type:DJ,string:t};return SJ(e,r,n)}function QPe(e,t){return SJ(e,HPe,t)}function YPe(e){let t=0;for(let n=e.length-1;n>=0;n--){let r=e[n];if(r===" "||r==="\t")t++;else break}return t}function EJ(e){let t=YPe(e);return{text:t===0?e:e.slice(0,e.length-t),count:t}}function BD(e,t,n,r,i,s){if(n===Number.POSITIVE_INFINITY)return!0;let o=t.length,a=!1,l=[e],c="";while(n>=0){if(l.length===0){if(o===0)return!0;l.push(t[--o]);continue}let{mode:u,doc:p}=l.pop(),d=Hd(p);switch(d){case Jd:if(p){if(a)c+=" ",n-=1,a=!1;c+=p,n-=vJ(p)}break;case Tc:case Xu:{let f=d===Tc?p:p.parts,m=p[A$]??0;for(let y=f.length-1;y>=m;y--)l.push({mode:u,doc:f[y]});break}case Wu:case Qu:case Zu:case np:l.push({mode:u,doc:p.contents});break;case Yu:{let{text:f,count:m}=EJ(c);c=f,n+=m;break}case Ho:{if(s&&p.break)return!1;let f=p.break?Go:u,m=p.expandedStates&&f===Go?Kd(0,p.expandedStates,-1):p.contents;l.push({mode:f,doc:m});break}case Na:{let m=(p.groupId?i[p.groupId]||bl:u)===Go?p.breakContents:p.flatContents;if(m)l.push({mode:u,doc:m});break}case Zi:if(u===Go||p.hard)return!0;if(!p.soft)a=!0;break;case ep:r=!0;break;case tp:if(r)return!1;break}}return!1}function e$e(e,t){let n=Object.create(null),r=t.printWidth,i=$Pe(t.endOfLine),s=0,o=[{indent:TJ,mode:Go,doc:e}],a=!1,l=[],c=new ZPe;WOe(e);while(o.length>0){let{indent:m,mode:y,doc:h}=o.pop();switch(Hd(h)){case Jd:{let b=i!==` -`?TPe(0,h,` -`,i):h;if(b){if(c.write(b),o.length>0)s+=vJ(b)}break}case Tc:for(let b=h.length-1;b>=0;b--)o.push({indent:m,mode:y,doc:h[b]});break;case Gd:c.markPosition();break;case Wu:o.push({indent:QPe(m,t),mode:y,doc:h.contents});break;case Qu:o.push({indent:WPe(m,h.n,t),mode:y,doc:h.contents});break;case Yu:s-=c.trim();break;case Ho:{let b=function(){if(y===bl&&!a)return{indent:m,mode:h.break?Go:bl,doc:h.contents};a=!1;let x=r-s,v=l.length>0,D={indent:m,mode:bl,doc:h.contents};if(!h.break&&BD(D,o,x,v,n))return D;if(!h.expandedStates)return{indent:m,mode:Go,doc:h.contents};if(!h.break)for(let T=1;T0,n,!0);if(v===1){if(C)o.push(N);else o.push(O);break}let X={indent:m,mode:bl,doc:T},te={indent:m,mode:Go,doc:T};if(v===2){if(C)o.push(X,N);else o.push(te,O);break}let L=x[g+2],Y={indent:m,mode:y,doc:{...h,[A$]:g+2}},I=BD({indent:m,mode:bl,doc:[D,T,L]},[],b,l.length>0,n,!0);if(o.push(Y),I)o.push(X,N);else if(C)o.push(te,N);else o.push(te,O);break}case Na:case Zu:{let b=h.groupId?n[h.groupId]:y;if(b===Go){let g=h.type===Na?h.breakContents:h.negate?h.contents:VD(h.contents);if(g)o.push({indent:m,mode:y,doc:g})}if(b===bl){let g=h.type===Na?h.flatContents:h.negate?VD(h.contents):h.contents;if(g)o.push({indent:m,mode:y,doc:g})}break}case ep:l.push({indent:m,mode:y,doc:h.contents});break;case tp:if(l.length>0)o.push({indent:m,mode:y,doc:C$});break;case Zi:switch(y){case bl:if(!h.hard){if(!h.soft)c.write(" "),s+=1;break}a=!0;case Go:if(l.length>0){o.push({indent:m,mode:y,doc:h},...l.reverse()),l.length=0;break}if(h.literal){if(c.write(i),s=0,m.root){if(m.root.value)c.write(m.root.value);s=m.root.length}}else c.trim(),c.write(i+m.value),s=m.length;break}break;case np:o.push({indent:m,mode:y,doc:h.contents});break;case _l:break;default:throw new iy(h)}if(o.length===0&&l.length>0)o.push(...l.reverse()),l.length=0}let{text:u,positions:p}=c.finish();if(p.length!==2)return{formatted:u};let[d,f]=p;return{formatted:u,cursorNodeStart:d,cursorNodeText:u.slice(d,f)}}var AOe,ROe=(e,t)=>{for(var n in t)AOe(e,n,{get:t[n],enumerable:!0})},jOe,FOe=1,uJ=(e,t)=>(n,r,...i)=>{if(n|FOe&&(r===void 0||r===null))return;return(t.call(r)??r[e]).apply(r,i)},MOe,Kd,LOe=()=>{},KD,Jd="string",Tc="array",Gd="cursor",Wu="indent",Qu="align",Yu="trim",Ho="group",Xu="fill",Na="if-break",Zu="indent-if-break",ep="line-suffix",tp="line-suffix-boundary",Zi="line",np="label",_l="break-parent",pJ,Hd,VOe=(e)=>new Intl.ListFormat("en-US",{type:"disjunction"}).format(e),JOe,iy,oJ,R$,vl,dJ,iPe,sPe,F$,uPe,hPe,gPe,C$,bPe,yJ,hJ,_Pe,xPe,wPe,DPe,TPe,SPe="cr",EPe="crlf",kPe="\r",NPe=`\r -`,OPe=` -`,PPe,IPe=()=>/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E-\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED8\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])))?))?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3C-\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE8A\uDE8E-\uDEC2\uDEC6\uDEC8\uDECD-\uDEDC\uDEDF-\uDEEA\uDEEF]|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g,APe=12288,RPe=65510,jPe,FPe=4352,CPe=262141,gJ,bJ=(e,t)=>{let n=0,r=Math.floor(e.length/2)-1;while(n<=r){let i=Math.floor((n+r)/2),s=i*2;if(te[s+1])n=i+1;else return!0}return!1},cJ=19968,MPe,LPe,UPe=(e)=>{if(eRPe)return!1;return bJ(jPe,e)},BPe=(e)=>{if(e>=MPe&&e<=LPe)return!0;if(eCPe)return!1;return bJ(gJ,e)},VPe,KPe=(e)=>VPe.test(e),JPe,vJ,_J=0,xJ=1,wJ=2,DJ=3,HPe,zPe,TJ,XPe=class{#e=[];#t="";#n=0;#r=[];#i=[];#s(){let e=this.#t;if(e!=="")this.#e.push(e),this.#n+=e.length,this.#t="";for(let t of this.#i)this.#r.push(Math.min(t,this.#n));this.#i.length=0}markPosition(){if(this.#r.length+this.#i.length>=2)throw Error("There are too many 'cursor' in doc.");this.#i.push(this.#n+this.#t.length)}write(e){this.#t+=e}trim(){let{text:e,count:t}=EJ(this.#t);return this.#t=e,this.#s(),t}finish(){return this.#s(),{text:this.#e.join(""),positions:this.#r}}},ZPe,Go,bl,A$,M$,t$e,n$e;var kJ=q(()=>{AOe=Object.defineProperty,jOe={};ROe(jOe,{builders:()=>M$,printer:()=>t$e,utils:()=>n$e});MOe=uJ("at",function(){if(Array.isArray(this)||typeof this==="string")return COe}),Kd=MOe,KD=LOe,pJ=new Set([Gd,Wu,Qu,Yu,Ho,Xu,Na,Zu,ep,tp,Zi,np,_l]);Hd=BOe;JOe=class extends Error{name="InvalidDocError";constructor(e){super(KOe(e));this.doc=e}},iy=JOe,oJ={};R$=GOe;vl=KD,dJ=KD,iPe=KD,sPe=KD;F$={type:_l},uPe={type:Gd};hPe={type:Zi},gPe={type:Zi,soft:!0},C$={type:Zi,hard:!0},bPe=[C$,F$],yJ={type:Zi,hard:!0,literal:!0},hJ=[yJ,F$];_Pe={type:tp},xPe={type:Yu},wPe=String.prototype.replaceAll??function(e,t){if(e.global)return this.replace(e,t);return this.split(e).join(t)},DPe=uJ("replaceAll",function(){if(typeof this==="string")return wPe}),TPe=DPe,PPe=OPe;jPe=[12288,12288,65281,65376,65504,65510],gJ=[4352,4447,8986,8987,9001,9002,9193,9196,9200,9200,9203,9203,9725,9726,9748,9749,9776,9783,9800,9811,9855,9855,9866,9871,9875,9875,9889,9889,9898,9899,9917,9918,9924,9925,9934,9934,9940,9940,9962,9962,9970,9971,9973,9973,9978,9978,9981,9981,9989,9989,9994,9995,10024,10024,10060,10060,10062,10062,10067,10069,10071,10071,10133,10135,10160,10160,10175,10175,11035,11036,11088,11088,11093,11093,11904,11929,11931,12019,12032,12245,12272,12287,12289,12350,12353,12438,12441,12543,12549,12591,12593,12686,12688,12773,12783,12830,12832,12871,12880,42124,42128,42182,43360,43388,44032,55203,63744,64255,65040,65049,65072,65106,65108,65126,65128,65131,94176,94180,94192,94198,94208,101589,101631,101662,101760,101874,110576,110579,110581,110587,110589,110590,110592,110882,110898,110898,110928,110930,110933,110933,110948,110951,110960,111355,119552,119638,119648,119670,126980,126980,127183,127183,127374,127374,127377,127386,127488,127490,127504,127547,127552,127560,127568,127569,127584,127589,127744,127776,127789,127797,127799,127868,127870,127891,127904,127946,127951,127955,127968,127984,127988,127988,127992,128062,128064,128064,128066,128252,128255,128317,128331,128334,128336,128359,128378,128378,128405,128406,128420,128420,128507,128591,128640,128709,128716,128716,128720,128722,128725,128728,128732,128735,128747,128748,128756,128764,128992,129003,129008,129008,129292,129338,129340,129349,129351,129535,129648,129660,129664,129674,129678,129734,129736,129736,129741,129756,129759,129770,129775,129784,131072,196605,196608,262141],[MPe,LPe]=qPe(gJ);VPe=/^(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u2600-\u2604\u260E\u2611\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26B0\u26B1\u26C8\u26CF\u26D1\u26D3\u26E9\u26F0\u26F1\u26F4\u26F7\u26F8\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2763\u2764\u27A1\u2934\u2935\u2B05-\u2B07]|\uD83C[\uDD70\uDD71\uDD7E\uDD7F\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF3\uDFF5\uDFF7]|\uD83D[\uDC3F\uDC41\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3])$/,JPe=/[^\x20-\x7F]/;vJ=GPe,HPe={type:_J},zPe={type:xJ},TJ={value:"",length:0,queue:[],get root(){return TJ}};ZPe=XPe,Go=Symbol("MODE_BREAK"),bl=Symbol("MODE_FLAT"),A$=Symbol("DOC_FILL_PRINTED_LENGTH");M$={join:mJ,line:hPe,softline:gPe,hardline:bPe,literalline:hJ,group:fJ,conditionalGroup:dPe,fill:pPe,lineSuffix:vPe,lineSuffixBoundary:_Pe,cursor:uPe,breakParent:F$,ifBreak:fPe,trim:xPe,indent:VD,indentIfBreak:mPe,align:sy,addAlignmentToDoc:cPe,markAsRoot:aPe,dedentToRoot:oPe,dedent:lPe,hardlineWithoutBreakParent:C$,literallineWithoutBreakParent:yJ,label:yPe,concat:(e)=>e},t$e={printDocToString:e$e},n$e={willBreak:zOe,traverseDoc:R$,findInDoc:j$,mapDoc:JD,removeLines:YOe,stripTrailingHardline:XOe,replaceEndOfLine:tPe,canBreak:rPe}});var L$;var q$=q(()=>{iJ();L$=UD});var NJ=q(()=>{It();q$()});var OJ=q(()=>{It()});var dgt,fgt,mgt,ygt,hgt,ggt,bgt,vgt,_gt,xgt,wgt,Dgt,PJ;var $J=q(()=>{kJ();vt();Mu();It();NJ();OJ();q$();({align:dgt,breakParent:fgt,group:mgt,hardline:ygt,ifBreak:hgt,indent:ggt,join:bgt,line:vgt,softline:_gt,literalline:xgt,markAsRoot:wgt}=M$),{isNextLineEmpty:Dgt}=L$;(function(e){e[e.Leading=2]="Leading",e[e.Trailing=4]="Trailing",e[e.Dangling=8]="Dangling",e[e.Block=16]="Block",e[e.Line=32]="Line",e[e.PrettierIgnore=64]="PrettierIgnore",e[e.First=128]="First",e[e.Last=256]="Last"})(PJ||(PJ={}))});var IJ=q(()=>{$J()});var AJ=q(()=>{sJ();IJ()});var Fb=q(()=>{AJ();mn()});var RJ=q(()=>{yr()});var jJ=()=>{};var GD;var FJ=q(()=>{Gt();(function(e){e[e.None=0]="None",e[e.Input=2]="Input",e[e.Output=4]="Output"})(GD||(GD={}))});var MJ=q(()=>{qm();ic();RJ();jJ();Rw();e$();Mu();cc();FJ()});function LJ(e){return a$e.test(e)}var a$e;var HD=q(()=>{a$e=/^[a-z0-9]+(?:-[a-z0-9]+)*$/});function c$e(e,t){let n={};for(let r of Object.keys(t??{}))n[r]=Symbol.for(`${e}/${r}`);return n}function nr(e){let t;Qe(e.alias===void 0||LJ(e.alias),`Library alias "${e.alias}" for library "${e.name}" is invalid. It must contain only lowercase letters, digits, and hyphens (e.g. "tcgc").`);let{reportDiagnostic:n,createDiagnostic:r}=dw(e.diagnostics,e.name);function i(a){return Symbol.for(`${e.name}.${a}`)}let s=u$e();if(s)l$e.add(s);return{...e,diagnostics:e.diagnostics,stateKeys:c$e(e.name,e.state),reportDiagnostic:n,createDiagnostic:r,createStateSymbol:i,get emitterOptionValidator(){if(!t&&e.emitter?.options)t=Fu(e.emitter.options,{coerceTypes:!0});return t},getTracer:o};function o(a){return a.tracer.sub(e.name)}}function V$(e){return e}function zD(e){return e}function K$(e){return e}function Cb(e){return Qe(!e.name.includes("/"),"Rule name cannot contain a '/'."),e}function zd(e,...t){t.forEach((n)=>n.namespace=e)}function u$e(){let e=p$e()[2];return typeof e==="object"&&"getFileName"in e?e.getFileName():void 0}function p$e(){let e=Error.prepareStackTrace;Error.prepareStackTrace=(n,r)=>r;let t=Error().stack.slice(1);return Error.prepareStackTrace=e,t}var B$,l$e;var oy=q(()=>{HD();FO();vt();km();B$=Symbol.for("TYPESPEC_LIBRARY_URLS_LOADED");if(globalThis[B$]===void 0)globalThis[B$]=new Set;l$e=globalThis[B$]});var qJ=q(()=>{vt()});var WD=q(()=>{qJ();oy()});var UJ=q(()=>{vt()});var QD=q(()=>{UJ();oy();It()});var ay=q(()=>{Gt();Qg();HD();vt();ic();oy();WD();QD();GO();Yn();mn();Vw();km();hb();It()});var BJ={};kf(BJ,{default:()=>m$e});var m$e;var VJ=q(()=>{m$e={version:"1.16.0",commit:"54d93a99737da023ed2cf8479b9573f73683b84d"}});var J$,y$e;var Mb=q(async()=>{try{J$=(await Promise.resolve().then(() => (VJ(),BJ))).default}catch{J$=(await import(["../dist","manifest.js"].join("/"))).default}y$e=J$.version});var Wd=()=>{};var H$=q(()=>{mn();Wd()});var z$=q(()=>{H$();Wd()});var W$=q(()=>{z$();H$();Wd()});var JJ=q(()=>{z$();Wd()});var YD=q(()=>{mn()});var GJ=q(()=>{mn();YD()});var Q$=q(()=>{mn();W$();JJ();Wd();GJ();YD()});var XD=q(()=>{Q$()});var zJ=()=>{};var ly=z(function(YJ){Object.defineProperty(YJ,"__esModule",{value:!0});YJ.boolean=S$e;YJ.string=WJ;YJ.number=E$e;YJ.error=k$e;YJ.func=N$e;YJ.array=QJ;YJ.stringArray=O$e;function S$e(e){return e===!0||e===!1}function WJ(e){return typeof e==="string"||e instanceof String}function E$e(e){return typeof e==="number"||e instanceof Number}function k$e(e){return e instanceof Error}function N$e(e){return typeof e==="function"}function QJ(e){return Array.isArray(e)}function O$e(e){return QJ(e)&&e.every((t)=>WJ(t))}});var Z$=z(function(ot){var C$e=ot&&ot.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),M$e=ot&&ot.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),L$e=ot&&ot.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;in,next:()=>{if(this._state!==e)throw Error("LinkedMap got modified during iteration.");if(t){let r={value:t.key,done:!1};return t=t.next,r}else return{value:void 0,done:!0}}};return n}values(){let e=this._state,t=this._head,n={[Symbol.iterator]:()=>n,next:()=>{if(this._state!==e)throw Error("LinkedMap got modified during iteration.");if(t){let r={value:t.value,done:!1};return t=t.next,r}else return{value:void 0,done:!0}}};return n}entries(){let e=this._state,t=this._head,n={[Symbol.iterator]:()=>n,next:()=>{if(this._state!==e)throw Error("LinkedMap got modified during iteration.");if(t){let r={value:[t.key,t.value],done:!1};return t=t.next,r}else return{value:void 0,done:!0}}};return n}[Symbol.iterator](){return this.entries()}trimOld(e){if(e>=this.size)return;if(e===0){this.clear();return}let t=this._head,n=this.size;while(t&&n>e)this._map.delete(t.key),t=t.next,n--;if(this._head=t,this._size=n,t)t.previous=void 0;this._state++}addItemFirst(e){if(!this._head&&!this._tail)this._tail=e;else if(!this._head)throw Error("Invalid list");else e.next=this._head,this._head.previous=e;this._head=e,this._state++}addItemLast(e){if(!this._head&&!this._tail)this._head=e;else if(!this._tail)throw Error("Invalid list");else e.previous=this._tail,this._tail.next=e;this._tail=e,this._state++}removeItem(e){if(e===this._head&&e===this._tail)this._head=void 0,this._tail=void 0;else if(e===this._head){if(!e.next)throw Error("Invalid list");e.next.previous=void 0,this._head=e.next}else if(e===this._tail){if(!e.previous)throw Error("Invalid list");e.previous.next=void 0,this._tail=e.previous}else{let{next:t,previous:n}=e;if(!t||!n)throw Error("Invalid list");t.previous=n,n.next=t}e.next=void 0,e.previous=void 0,this._state++}touch(e,t){if(!this._head||!this._tail)throw Error("Invalid list");if(t!==Ri.First&&t!==Ri.Last)return;if(t===Ri.First){if(e===this._head)return;let{next:n,previous:r}=e;if(e===this._tail)r.next=void 0,this._tail=r;else n.previous=r,r.next=n;e.previous=void 0,e.next=this._head,this._head.previous=e,this._head=e,this._state++}else if(t===Ri.Last){if(e===this._tail)return;let{next:n,previous:r}=e;if(e===this._head)n.previous=void 0,this._head=n;else n.previous=r,r.next=n;e.next=void 0,e.previous=this._tail,this._tail.next=e,this._tail=e,this._state++}}toJSON(){let e=[];return this.forEach((t,n)=>{e.push([n,t])}),e}fromJSON(e){this.clear();for(let[t,n]of e)this.set(t,n)}}wG.LinkedMap=eI;class xG extends eI{_limit;_ratio;constructor(e,t=1){super();this._limit=e,this._ratio=Math.min(Math.max(0,t),1)}get limit(){return this._limit}set limit(e){this._limit=e,this.checkTrim()}get ratio(){return this._ratio}set ratio(e){this._ratio=Math.min(Math.max(0,e),1),this.checkTrim()}get(e,t=Ri.AsNew){return super.get(e,t)}peek(e){return super.get(e,Ri.None)}set(e,t){return super.set(e,t,Ri.Last),this.checkTrim(),this}checkTrim(){if(this.size>this._limit)this.trimOld(Math.round(this._limit*this._ratio))}}wG.LRUCache=xG});var kG=z(function(SG){Object.defineProperty(SG,"__esModule",{value:!0});SG.Disposable=void 0;var TG;(function(e){function t(n){return{dispose:n}}e.create=t})(TG||(SG.Disposable=TG={}))});var rp=z(function(NG){Object.defineProperty(NG,"__esModule",{value:!0});var nI;function rI(){if(nI===void 0)throw Error("No runtime abstraction layer installed");return nI}(function(e){function t(n){if(n===void 0)throw Error("No runtime abstraction layer provided");nI=n}e.install=t})(rI||(rI={}));NG.default=rI});var cy=z(function(ip){var V$e=ip&&ip.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(ip,"__esModule",{value:!0});ip.Emitter=ip.Event=void 0;var K$e=V$e(rp()),OG;(function(e){let t={dispose(){}};e.None=function(){return t}})(OG||(ip.Event=OG={}));class PG{_callbacks;_contexts;add(e,t=null,n){if(!this._callbacks)this._callbacks=[],this._contexts=[];if(this._callbacks.push(e),this._contexts.push(t),Array.isArray(n))n.push({dispose:()=>this.remove(e,t)})}remove(e,t=null){if(!this._callbacks)return;let n=!1;for(let r=0,i=this._callbacks.length;r{if(!this._callbacks)this._callbacks=new PG;if(this._options&&this._options.onFirstListenerAdd&&this._callbacks.isEmpty())this._options.onFirstListenerAdd(this);this._callbacks.add(e,t);let r={dispose:()=>{if(!this._callbacks)return;if(this._callbacks.remove(e,t),r.dispose=iI._noop,this._options&&this._options.onLastListenerRemove&&this._callbacks.isEmpty())this._options.onLastListenerRemove(this)}};if(Array.isArray(n))n.push(r);return r};return this._event}fire(e){if(this._callbacks)this._callbacks.invoke.call(this._callbacks,e)}dispose(){if(this._callbacks)this._callbacks.dispose(),this._callbacks=void 0}}ip.Emitter=iI});var eT=z(function(Ps){var J$e=Ps&&Ps.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),G$e=Ps&&Ps.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),H$e=Ps&&Ps.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;i{this._waiting.push({thunk:e,resolve:t,reject:n}),this.runNext()})}get active(){return this._active}runNext(){if(this._waiting.length===0||this._active===this._capacity)return;(0,tIe.default)().timer.setImmediate(()=>this.doRunNext())}doRunNext(){if(this._waiting.length===0||this._active===this._capacity)return;let e=this._waiting.shift();if(this._active++,this._active>this._capacity)throw Error("Too many thunks active");try{let t=e.thunk();if(t instanceof Promise)t.then((n)=>{this._active--,e.resolve(n),this.runNext()},(n)=>{this._active--,e.reject(n),this.runNext()});else this._active--,e.resolve(t),this.runNext()}catch(t){this._active--,e.reject(t),this.runNext()}}}uy.Semaphore=LG});var BG=z(function(ji){var nIe=ji&&ji.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),rIe=ji&&ji.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),iIe=ji&&ji.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;i{this.onData(n)});return this.readable.onError((n)=>this.fireError(n)),this.readable.onClose(()=>this.fireClose()),t}onData(e){try{this.buffer.append(e);while(!0){if(this.nextMessageLength===-1){let n=this.buffer.tryReadHeaders(!0);if(!n)return;let r=n.get("content-length");if(!r){this.fireError(Error(`Header must provide a Content-Length property. -${JSON.stringify(Object.fromEntries(n))}`));return}let i=parseInt(r);if(isNaN(i)){this.fireError(Error(`Content-Length value must be a number. Got ${r}`));return}this.nextMessageLength=i}let t=this.buffer.tryReadBody(this.nextMessageLength);if(t===void 0){this.setPartialMessageTimer();return}this.clearPartialMessageTimer(),this.nextMessageLength=-1,this.readSemaphore.lock(async()=>{let n=this.options.contentDecoder!==void 0?await this.options.contentDecoder.decode(t):t,r=await this.options.contentTypeDecoder.decode(n,this.options);this.callback(r)}).catch((n)=>{this.fireError(n)})}}catch(t){this.fireError(t)}}clearPartialMessageTimer(){if(this.partialMessageTimer)this.partialMessageTimer.dispose(),this.partialMessageTimer=void 0}setPartialMessageTimer(){if(this.clearPartialMessageTimer(),this._partialMessageTimeout<=0)return;this.partialMessageTimer=(0,cI.default)().timer.setTimeout((e,t)=>{if(this.partialMessageTimer=void 0,e===this.messageToken)this.firePartialMessage({messageToken:e,waitingTime:t}),this.setPartialMessageTimer()},this._partialMessageTimeout,this.messageToken,this._partialMessageTimeout)}}ji.ReadableStreamMessageReader=UG});var zG=z(function(Fi){var aIe=Fi&&Fi.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),lIe=Fi&&Fi.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),cIe=Fi&&Fi.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;ithis.fireError(n)),this.writable.onClose(()=>this.fireClose())}async write(e){return this.writeSemaphore.lock(async()=>this.options.contentTypeEncoder.encode(e,this.options).then((n)=>{if(this.options.contentEncoder!==void 0)return this.options.contentEncoder.encode(n);else return n}).then((n)=>{let r=[];return r.push(dIe,n.byteLength.toString(),JG),r.push(JG),this.doWrite(e,r,n)},(n)=>{throw this.fireError(n),n}))}async doWrite(e,t,n){try{return await this.writable.write(t.join(""),"ascii"),this.writable.write(n)}catch(r){return this.handleError(r,e),Promise.reject(r)}}handleError(e,t){this.errorCount++,this.fireError(e,t,this.errorCount)}end(){this.writable.end()}}Fi.WriteableStreamMessageWriter=HG});var XG=z(function(QG){Object.defineProperty(QG,"__esModule",{value:!0});QG.AbstractMessageBuffer=void 0;var fIe=13,mIe=10,yIe=`\r -`;class WG{_encoding;_chunks;_totalLength;constructor(e="utf-8"){this._encoding=e,this._chunks=[],this._totalLength=0}get encoding(){return this._encoding}append(e){let t=typeof e==="string"?this.fromString(e,this._encoding):e;this._chunks.push(t),this._totalLength+=t.byteLength}tryReadHeaders(e=!1){if(this._chunks.length===0)return;let t=0,n=0,r=0,i=0;e:while(nthis._totalLength)throw Error("Cannot read so many bytes!");if(this._chunks[0].byteLength===e){let i=this._chunks[0];return this._chunks.shift(),this._totalLength-=e,this.asNative(i)}if(this._chunks[0].byteLength>e){let i=this._chunks[0],s=this.asNative(i,e);return this._chunks[0]=i.slice(e),this._totalLength-=e,s}let t=this.allocNative(e),n=0,r=0;while(e>0){let i=this._chunks[r];if(i.byteLength>e){let s=i.slice(0,e);t.set(s,n),n+=e,this._chunks[r]=i.slice(e),this._totalLength-=e,e-=e}else t.set(i,n),n+=i.byteLength,this._chunks.shift(),this._totalLength-=i.byteLength,e-=i.byteLength}return t}}QG.AbstractMessageBuffer=WG});var rH=z(function(ht){var hIe=ht&&ht.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),gIe=ht&&ht.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),bIe=ht&&ht.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;i{},warn:()=>{},info:()=>{},log:()=>{}});var vn;(function(e){e[e.Off=0]="Off",e[e.Messages=1]="Messages",e[e.Compact=2]="Compact",e[e.Verbose=3]="Verbose"})(vn||(ht.Trace=vn={}));var gI;(function(e){e.Off="off",e.Messages="messages",e.Compact="compact",e.Verbose="verbose"})(gI||(ht.TraceValue=gI={}));ht.TraceValues=gI;(function(e){function t(r){if(!rr.string(r))return e.Off;switch(r=r.toLowerCase(),r){case"off":return e.Off;case"messages":return e.Messages;case"compact":return e.Compact;case"verbose":return e.Verbose;default:return e.Off}}e.fromString=t;function n(r){switch(r){case e.Off:return"off";case e.Messages:return"messages";case e.Compact:return"compact";case e.Verbose:return"verbose";default:return"off"}}e.toString=n})(vn||(ht.Trace=vn={}));var no;(function(e){e.Text="text",e.JSON="json"})(no||(ht.TraceFormat=no={}));(function(e){function t(n){if(!rr.string(n))return e.Text;if(n=n.toLowerCase(),n==="json")return e.JSON;else return e.Text}e.fromString=t})(no||(ht.TraceFormat=no={}));var bI;(function(e){e.type=new Ot.NotificationType("$/setTrace")})(bI||(ht.SetTraceNotification=bI={}));var tT;(function(e){e.type=new Ot.NotificationType("$/logTrace")})(tT||(ht.LogTraceNotification=tT={}));var Kb;(function(e){e[e.Closed=1]="Closed",e[e.Disposed=2]="Disposed",e[e.AlreadyListening=3]="AlreadyListening"})(Kb||(ht.ConnectionErrors=Kb={}));class dy extends Error{code;constructor(e,t){super(t);this.code=e,Object.setPrototypeOf(this,dy.prototype)}}ht.ConnectionError=dy;var vI;(function(e){function t(n){let r=n;return r&&rr.func(r.cancelUndispatched)}e.is=t})(vI||(ht.ConnectionStrategy=vI={}));var nT;(function(e){function t(n){let r=n;return r&&(r.kind===void 0||r.kind==="id")&&rr.func(r.createCancellationTokenSource)&&(r.dispose===void 0||rr.func(r.dispose))}e.is=t})(nT||(ht.IdCancellationReceiverStrategy=nT={}));var _I;(function(e){function t(n){let r=n;return r&&r.kind==="request"&&rr.func(r.createCancellationTokenSource)&&(r.dispose===void 0||rr.func(r.dispose))}e.is=t})(_I||(ht.RequestCancellationReceiverStrategy=_I={}));var rT;(function(e){e.Message=Object.freeze({createCancellationTokenSource(n){return new mI.CancellationTokenSource}});function t(n){return nT.is(n)||_I.is(n)}e.is=t})(rT||(ht.CancellationReceiverStrategy=rT={}));var iT;(function(e){e.Message=Object.freeze({sendCancellation(n,r){return n.sendNotification(Jb.type,{id:r})},cleanup(n){}});function t(n){let r=n;return r&&rr.func(r.sendCancellation)&&rr.func(r.cleanup)}e.is=t})(iT||(ht.CancellationSenderStrategy=iT={}));var sT;(function(e){e.Message=Object.freeze({receiver:rT.Message,sender:iT.Message});function t(n){let r=n;return r&&rT.is(r.receiver)&&iT.is(r.sender)}e.is=t})(sT||(ht.CancellationStrategy=sT={}));var oT;(function(e){function t(n){let r=n;return r&&rr.func(r.handleMessage)}e.is=t})(oT||(ht.MessageStrategy=oT={}));var tH;(function(e){function t(n){let r=n;return r&&(sT.is(r.cancellationStrategy)||vI.is(r.connectionStrategy)||oT.is(r.messageStrategy)||rr.number(r.maxParallelism))}e.is=t})(tH||(ht.ConnectionOptions=tH={}));var Oa;(function(e){e[e.New=1]="New",e[e.Listening=2]="Listening",e[e.Closed=3]="Closed",e[e.Disposed=4]="Disposed"})(Oa||(Oa={}));function _Ie(e,t,n,r){let i=n!==void 0?n:ht.NullLogger,s=0,o=0,a=0,l="2.0",c=r?.maxParallelism??-1,u=0,p=void 0,d=new Map,f=void 0,m=new Map,y=new Map,h,b=new eH.LinkedMap,g=new Map,x=new Set,v=new Map,D=vn.Off,T=no.Text,N,O=Oa.New,C=new Bb.Emitter,X=new Bb.Emitter,te=new Bb.Emitter,L=new Bb.Emitter,Y=new Bb.Emitter,me=r&&r.cancellationStrategy?r.cancellationStrategy:sT.Message;function I(E){return}function Z(){return O===Oa.Listening}function pe(){return O===Oa.Closed}function de(){return O===Oa.Disposed}function je(){if(O===Oa.New||O===Oa.Listening)O=Oa.Closed,X.fire(void 0)}function be(E){C.fire([E,void 0,void 0])}function Ie(E){C.fire(E)}e.onClose(je),e.onError(be),t.onClose(je),t.onError(Ie);function J(E){if(E===null)throw Error("Can't send requests with id null since the response can't be correlated.");return"req-"+E.toString()}function _e(E){if(E===null)return"res-unknown-"+(++a).toString();else return"res-"+E.toString()}function ue(){return"not-"+(++o).toString()}function ce(E,A){if(Ot.Message.isRequest(A))E.set(J(A.id),A);else if(Ot.Message.isResponse(A))if(c===-1)E.set(_e(A.id),A);else se(A);else E.set(ue(),A)}function Le(){if(h||b.size===0)return;if(c!==-1&&u>=c)return;h=(0,ZG.default)().timer.setImmediate(async()=>{if(h=void 0,b.size===0)return;if(c!==-1&&u>=c)return;let E=b.shift(),A;try{u++;let Q=r?.messageStrategy;if(oT.is(Q))A=Q.handleMessage(E,Ke);else A=Ke(E)}catch(Q){i.error(`Processing message queue failed: ${Q.toString()}`)}finally{if(A instanceof Promise)A.then(()=>{u--,Le()}).catch((Q)=>{i.error(`Processing message queue failed: ${Q.toString()}`)});else u--;Le()}})}async function Ke(E){if(Ot.Message.isRequest(E))return lt(E);else if(Ot.Message.isNotification(E))return he(E);else if(Ot.Message.isResponse(E))return se(E);else return ke(E)}let ct=(E)=>{try{if(Ot.Message.isNotification(E)&&E.method===Jb.type.method){let A=E.params.id,Q=J(A),le=b.get(Q);if(Ot.Message.isRequest(le)){let St=r?.connectionStrategy,ut=St&&St.cancelUndispatched?St.cancelUndispatched(le,I):I(le);if(ut&&(ut.error!==void 0||ut.result!==void 0)){b.delete(Q),v.delete(A),ut.id=le.id,V(ut,E.method,Date.now()),t.write(ut).catch(()=>i.error("Sending response for canceled message failed."));return}}let Je=v.get(A);if(Je!==void 0){Je.cancel(),H(E);return}else x.add(A)}ce(b,E)}finally{Le()}};async function lt(E){if(de())return Promise.resolve();function A(xt,At,Ln){let Rn={jsonrpc:l,id:E.id};if(xt instanceof Ot.ResponseError)Rn.error=xt.toJson();else Rn.result=xt===void 0?null:xt;return V(Rn,At,Ln),t.write(Rn)}function Q(xt,At,Ln){let Rn={jsonrpc:l,id:E.id,error:xt.toJson()};return V(Rn,At,Ln),t.write(Rn)}j(E);let le=d.get(E.method),Je,St;if(le)Je=le.type,St=le.handler;let ut=Date.now();if(St||p){let xt=E.id??String(Date.now()),At=nT.is(me.receiver)?me.receiver.createCancellationTokenSource(xt):me.receiver.createCancellationTokenSource(E);if(E.id!==null&&x.has(E.id))At.cancel();if(E.id!==null)v.set(xt,At);try{let Ln;if(St)if(E.params===void 0){if(Je!==void 0&&Je.numberOfParams!==0)return Q(new Ot.ResponseError(Ot.ErrorCodes.InvalidParams,`Request ${E.method} defines ${Je.numberOfParams} params but received none.`),E.method,ut);Ln=St(At.token)}else if(Array.isArray(E.params)){if(Je!==void 0&&Je.parameterStructures===Ot.ParameterStructures.byName)return Q(new Ot.ResponseError(Ot.ErrorCodes.InvalidParams,`Request ${E.method} defines parameters by name but received parameters by position`),E.method,ut);Ln=St(...E.params,At.token)}else{if(Je!==void 0&&Je.parameterStructures===Ot.ParameterStructures.byPosition)return Q(new Ot.ResponseError(Ot.ErrorCodes.InvalidParams,`Request ${E.method} defines parameters by position but received parameters by name`),E.method,ut);Ln=St(E.params,At.token)}else if(p)Ln=p(E.method,E.params,At.token);let Rn=await Ln;await A(Rn,E.method,ut)}catch(Ln){if(Ln instanceof Ot.ResponseError)await A(Ln,E.method,ut);else if(Ln&&rr.string(Ln.message))await Q(new Ot.ResponseError(Ot.ErrorCodes.InternalError,`Request ${E.method} failed with message: ${Ln.message}`),E.method,ut);else await Q(new Ot.ResponseError(Ot.ErrorCodes.InternalError,`Request ${E.method} failed unexpectedly without providing any details.`),E.method,ut)}finally{v.delete(xt)}}else await Q(new Ot.ResponseError(Ot.ErrorCodes.MethodNotFound,`Unhandled method ${E.method}`),E.method,ut)}function se(E){if(de())return;if(E.id===null)if(E.error)i.error(`Received response message without id: Error is: -${JSON.stringify(E.error,void 0,4)}`);else i.error("Received response message without id. No further error information provided.");else{let A=E.id,Q=g.get(A);if(ge(E,Q),Q!==void 0){g.delete(A);try{if(E.error){let le=E.error;Q.reject(new Ot.ResponseError(le.code,le.message,le.data))}else if(E.result!==void 0)Q.resolve(E.result);else throw Error("Should never happen.")}catch(le){if(le.message)i.error(`Response handler '${Q.method}' failed with message: ${le.message}`);else i.error(`Response handler '${Q.method}' failed unexpectedly.`)}}}}async function he(E){if(de())return;let A=void 0,Q;if(E.method===Jb.type.method){let le=E.params.id;x.delete(le),H(E);return}else{let le=m.get(E.method);if(le)Q=le.handler,A=le.type}if(Q||f)try{if(H(E),Q)if(E.params===void 0){if(A!==void 0){if(A.numberOfParams!==0&&A.parameterStructures!==Ot.ParameterStructures.byName)i.error(`Notification ${E.method} defines ${A.numberOfParams} params but received none.`)}await Q()}else if(Array.isArray(E.params)){let le=E.params;if(E.method===Vb.type.method&&le.length===2&&yI.is(le[0]))await Q({token:le[0],value:le[1]});else{if(A!==void 0){if(A.parameterStructures===Ot.ParameterStructures.byName)i.error(`Notification ${E.method} defines parameters by name but received parameters by position`);if(A.numberOfParams!==E.params.length)i.error(`Notification ${E.method} defines ${A.numberOfParams} params but received ${le.length} arguments`)}await Q(...le)}}else{if(A!==void 0&&A.parameterStructures===Ot.ParameterStructures.byPosition)i.error(`Notification ${E.method} defines parameters by position but received parameters by name`);await Q(E.params)}else if(f)await f(E.method,E.params)}catch(le){if(le.message)i.error(`Notification handler '${E.method}' failed with message: ${le.message}`);else i.error(`Notification handler '${E.method}' failed unexpectedly.`)}else te.fire(E)}function ke(E){if(!E){i.error("Received empty message.");return}i.error(`Received message which is neither a response nor a notification message: -${JSON.stringify(E,null,4)}`);let A=E;if(rr.string(A.id)||rr.number(A.id)){let Q=A.id,le=g.get(Q);if(le)le.reject(Error("The received response has neither a result nor an error property."))}}function Re(E){if(E===void 0||E===null)return;switch(D){case vn.Verbose:return JSON.stringify(E,null,4);case vn.Compact:return JSON.stringify(E);default:return}}function Ne(E){if(D===vn.Off||!N)return;if(T===no.Text){let A=void 0;if((D===vn.Verbose||D===vn.Compact)&&E.params)A=`Params: ${Re(E.params)}`;N.log(`Sending request '${E.method} - (${E.id})'.`,A)}else fe("send-request",E)}function G(E){if(D===vn.Off||!N)return;if(T===no.Text){let A=void 0;if(D===vn.Verbose||D===vn.Compact)if(E.params)A=`Params: ${Re(E.params)}`;else A="No parameters provided.";N.log(`Sending notification '${E.method}'.`,A)}else fe("send-notification",E)}function V(E,A,Q){if(D===vn.Off||!N)return;if(T===no.Text){let le=void 0;if(D===vn.Verbose||D===vn.Compact){if(E.error&&E.error.data)le=`Error data: ${Re(E.error.data)}`;else if(E.result)le=`Result: ${Re(E.result)}`;else if(E.error===void 0)le="No result returned."}N.log(`Sending response '${A} - (${E.id})'. Processing request took ${Date.now()-Q}ms`,le)}else fe("send-response",E)}function j(E){if(D===vn.Off||!N)return;if(T===no.Text){let A=void 0;if((D===vn.Verbose||D===vn.Compact)&&E.params)A=`Params: ${Re(E.params)}`;N.log(`Received request '${E.method} - (${E.id})'.`,A)}else fe("receive-request",E)}function H(E){if(D===vn.Off||!N||E.method===tT.type.method)return;if(T===no.Text){let A=void 0;if(D===vn.Verbose||D===vn.Compact)if(E.params)A=`Params: ${Re(E.params)}`;else A="No parameters provided.";N.log(`Received notification '${E.method}'.`,A)}else fe("receive-notification",E)}function ge(E,A){if(D===vn.Off||!N)return;if(T===no.Text){let Q=void 0;if(D===vn.Verbose||D===vn.Compact){if(E.error&&E.error.data)Q=`Error data: ${Re(E.error.data)}`;else if(E.result)Q=`Result: ${Re(E.result)}`;else if(E.error===void 0)Q="No result returned."}if(A){let le=E.error?` Request failed: ${E.error.message} (${E.error.code}).`:"";N.log(`Received response '${A.method} - (${E.id})' in ${Date.now()-A.timerStart}ms.${le}`,Q)}else N.log(`Received response ${E.id} without active response promise.`,Q)}else fe("receive-response",E)}function fe(E,A){if(!N||D===vn.Off)return;let Q={isLSPMessage:!0,type:E,message:A,timestamp:Date.now()};N.log(Q)}function W(){if(pe())throw new dy(Kb.Closed,"Connection is closed.");if(de())throw new dy(Kb.Disposed,"Connection is disposed.")}function ye(){if(Z())throw new dy(Kb.AlreadyListening,"Connection is already listening")}function Oe(){if(!Z())throw Error("Call listen() first.")}function Se(E){if(E===void 0)return null;else return E}function Ce(E){if(E===null)return;else return E}function Bt(E){return E!==void 0&&E!==null&&!Array.isArray(E)&&typeof E==="object"}function _(E,A){switch(E){case Ot.ParameterStructures.auto:if(Bt(A))return Ce(A);else return[Se(A)];case Ot.ParameterStructures.byName:if(!Bt(A))throw Error("Received parameters by name but param is not an object literal.");return Ce(A);case Ot.ParameterStructures.byPosition:return[Se(A)];default:throw Error(`Unknown parameter structure ${E.toString()}`)}}function S(E,A){let Q,le=E.numberOfParams;switch(le){case 0:Q=void 0;break;case 1:Q=_(E.parameterStructures,A[0]);break;default:Q=[];for(let Je=0;Je{W();let Q,le;if(rr.string(E)){Q=E;let St=A[0],ut=0,xt=Ot.ParameterStructures.auto;if(Ot.ParameterStructures.is(St))ut=1,xt=St;let At=A.length,Ln=At-ut;switch(Ln){case 0:le=void 0;break;case 1:le=_(xt,A[ut]);break;default:if(xt===Ot.ParameterStructures.byName)throw Error(`Received ${Ln} parameters for 'by Name' notification parameter structure.`);le=A.slice(ut,At).map((Rn)=>Se(Rn));break}}else{let St=A;Q=E.method,le=S(E,St)}let Je={jsonrpc:l,method:Q,params:le};return G(Je),t.write(Je).catch((St)=>{throw i.error("Sending notification failed."),St})},onNotification:(E,A)=>{W();let Q;if(rr.func(E))f=E;else if(A)if(rr.string(E))Q=E,m.set(E,{type:void 0,handler:A});else Q=E.method,m.set(E.method,{type:E,handler:A});return{dispose:()=>{if(Q!==void 0){if(m.get(Q)?.handler===A)m.delete(Q)}else if(f===E)f=void 0}}},onProgress:(E,A,Q)=>{if(y.has(A))throw Error(`Progress handler for token ${A} already registered`);return y.set(A,Q),{dispose:()=>{if(y.get(A)===Q)y.delete(A)}}},sendProgress:(E,A,Q)=>k.sendNotification(Vb.type,{token:A,value:Q}),onUnhandledProgress:L.event,sendRequest:(E,...A)=>{W(),Oe();function Q(Rn,_i){let qs=me.sender.sendCancellation(Rn,_i);if(qs===void 0)i.log(`Received no promise from cancellation strategy when cancelling id ${_i}`);else qs.catch(()=>{i.log(`Sending cancellation messages for id ${_i} failed.`)})}let le,Je,St=void 0;if(rr.string(E)){le=E;let Rn=A[0],_i=A[A.length-1],qs=0,qa=Ot.ParameterStructures.auto;if(Ot.ParameterStructures.is(Rn))qs=1,qa=Rn;let Us=A.length;if(mI.CancellationToken.is(_i))Us=Us-1,St=_i;let as=Us-qs;switch(as){case 0:Je=void 0;break;case 1:Je=_(qa,A[qs]);break;default:if(qa===Ot.ParameterStructures.byName)throw Error(`Received ${as} parameters for 'by Name' request parameter structure.`);Je=A.slice(qs,Us).map((ah)=>Se(ah));break}}else{let Rn=A;le=E.method,Je=S(E,Rn);let _i=E.numberOfParams;St=mI.CancellationToken.is(Rn[_i])?Rn[_i]:void 0}let ut=s++,xt,At=!1;if(St!==void 0)if(St.isCancellationRequested)At=!0;else xt=St.onCancellationRequested(()=>{Q(k,ut)});let Ln={jsonrpc:l,id:ut,method:le,params:Je};if(Ne(Ln),typeof me.sender.enableCancellation==="function")me.sender.enableCancellation(Ln);return new Promise(async(Rn,_i)=>{let qs=(as)=>{Rn(as),me.sender.cleanup(ut),xt?.dispose()},qa=(as)=>{_i(as),me.sender.cleanup(ut),xt?.dispose()},Us={method:le,timerStart:Date.now(),resolve:qs,reject:qa};try{if(g.set(ut,Us),await t.write(Ln),At)Q(k,ut)}catch(as){throw g.delete(ut),Us.reject(new Ot.ResponseError(Ot.ErrorCodes.MessageWriteError,as.message?as.message:"Unknown reason")),i.error("Sending request failed."),as}})},onRequest:(E,A)=>{W();let Q=null;if(hI.is(E))Q=void 0,p=E;else if(rr.string(E)){if(Q=null,A!==void 0)Q=E,d.set(E,{handler:A,type:void 0})}else if(A!==void 0)Q=E.method,d.set(E.method,{type:E,handler:A});return{dispose:()=>{if(Q===null)return;if(Q!==void 0){if(d.get(Q)?.handler===A)d.delete(Q)}else if(p===E)p=void 0}}},hasPendingResponse:()=>g.size>0,trace:async(E,A,Q)=>{let le=!1,Je=no.Text;if(Q!==void 0)if(rr.boolean(Q))le=Q;else le=Q.sendNotification||!1,Je=Q.traceFormat||no.Text;if(D=E,T=Je,D===vn.Off)N=void 0;else N=A;if(le&&!pe()&&!de())await k.sendNotification(bI.type,{value:vn.toString(E)})},onError:C.event,onClose:X.event,onUnhandledNotification:te.event,onDispose:Y.event,end:()=>{t.end()},dispose:()=>{if(de())return;O=Oa.Disposed,Y.fire(void 0);let E=new Ot.ResponseError(Ot.ErrorCodes.PendingResponseRejected,"Pending response rejected since connection got disposed");for(let A of g.values())A.reject(E);if(g=new Map,v=new Map,x=new Set,b=new eH.LinkedMap,rr.func(t.dispose))t.dispose();if(rr.func(e.dispose))e.dispose()},listen:()=>{W(),ye(),O=Oa.Listening,e.listen(ct)},inspect:()=>{(0,ZG.default)().console.log("inspect")}};return k.onNotification(tT.type,(E)=>{if(D===vn.Off||!N)return;let A=D===vn.Verbose||D===vn.Compact;N.log(E.message,A?E.verbose:void 0)}),k.onNotification(Vb.type,async(E)=>{let A=y.get(E.token);if(A)await A(E.value);else L.fire(E)}),k}});var fy=z(function(ve){var xIe=ve&&ve.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(ve,"__esModule",{value:!0});ve.ProgressType=ve.ProgressToken=ve.createMessageConnection=ve.NullLogger=ve.ConnectionOptions=ve.ConnectionStrategy=ve.AbstractMessageBuffer=ve.WriteableStreamMessageWriter=ve.AbstractMessageWriter=ve.MessageWriter=ve.ReadableStreamMessageReader=ve.AbstractMessageReader=ve.MessageReader=ve.SharedArrayReceiverStrategy=ve.SharedArraySenderStrategy=ve.CancellationToken=ve.CancellationTokenSource=ve.Emitter=ve.Event=ve.Disposable=ve.LRUCache=ve.Touch=ve.LinkedMap=ve.ParameterStructures=ve.NotificationType9=ve.NotificationType8=ve.NotificationType7=ve.NotificationType6=ve.NotificationType5=ve.NotificationType4=ve.NotificationType3=ve.NotificationType2=ve.NotificationType1=ve.NotificationType0=ve.NotificationType=ve.ErrorCodes=ve.ResponseError=ve.RequestType9=ve.RequestType8=ve.RequestType7=ve.RequestType6=ve.RequestType5=ve.RequestType4=ve.RequestType3=ve.RequestType2=ve.RequestType1=ve.RequestType0=ve.RequestType=ve.Message=ve.RAL=void 0;ve.MessageStrategy=ve.CancellationStrategy=ve.CancellationSenderStrategy=ve.RequestCancellationReceiverStrategy=ve.IdCancellationReceiverStrategy=ve.CancellationReceiverStrategy=ve.ConnectionError=ve.ConnectionErrors=ve.LogTraceNotification=ve.SetTraceNotification=ve.TraceFormat=ve.TraceValues=ve.TraceValue=ve.Trace=void 0;var Un=Z$();Object.defineProperty(ve,"Message",{enumerable:!0,get:function(){return Un.Message}});Object.defineProperty(ve,"RequestType",{enumerable:!0,get:function(){return Un.RequestType}});Object.defineProperty(ve,"RequestType0",{enumerable:!0,get:function(){return Un.RequestType0}});Object.defineProperty(ve,"RequestType1",{enumerable:!0,get:function(){return Un.RequestType1}});Object.defineProperty(ve,"RequestType2",{enumerable:!0,get:function(){return Un.RequestType2}});Object.defineProperty(ve,"RequestType3",{enumerable:!0,get:function(){return Un.RequestType3}});Object.defineProperty(ve,"RequestType4",{enumerable:!0,get:function(){return Un.RequestType4}});Object.defineProperty(ve,"RequestType5",{enumerable:!0,get:function(){return Un.RequestType5}});Object.defineProperty(ve,"RequestType6",{enumerable:!0,get:function(){return Un.RequestType6}});Object.defineProperty(ve,"RequestType7",{enumerable:!0,get:function(){return Un.RequestType7}});Object.defineProperty(ve,"RequestType8",{enumerable:!0,get:function(){return Un.RequestType8}});Object.defineProperty(ve,"RequestType9",{enumerable:!0,get:function(){return Un.RequestType9}});Object.defineProperty(ve,"ResponseError",{enumerable:!0,get:function(){return Un.ResponseError}});Object.defineProperty(ve,"ErrorCodes",{enumerable:!0,get:function(){return Un.ErrorCodes}});Object.defineProperty(ve,"NotificationType",{enumerable:!0,get:function(){return Un.NotificationType}});Object.defineProperty(ve,"NotificationType0",{enumerable:!0,get:function(){return Un.NotificationType0}});Object.defineProperty(ve,"NotificationType1",{enumerable:!0,get:function(){return Un.NotificationType1}});Object.defineProperty(ve,"NotificationType2",{enumerable:!0,get:function(){return Un.NotificationType2}});Object.defineProperty(ve,"NotificationType3",{enumerable:!0,get:function(){return Un.NotificationType3}});Object.defineProperty(ve,"NotificationType4",{enumerable:!0,get:function(){return Un.NotificationType4}});Object.defineProperty(ve,"NotificationType5",{enumerable:!0,get:function(){return Un.NotificationType5}});Object.defineProperty(ve,"NotificationType6",{enumerable:!0,get:function(){return Un.NotificationType6}});Object.defineProperty(ve,"NotificationType7",{enumerable:!0,get:function(){return Un.NotificationType7}});Object.defineProperty(ve,"NotificationType8",{enumerable:!0,get:function(){return Un.NotificationType8}});Object.defineProperty(ve,"NotificationType9",{enumerable:!0,get:function(){return Un.NotificationType9}});Object.defineProperty(ve,"ParameterStructures",{enumerable:!0,get:function(){return Un.ParameterStructures}});var xI=tI();Object.defineProperty(ve,"LinkedMap",{enumerable:!0,get:function(){return xI.LinkedMap}});Object.defineProperty(ve,"LRUCache",{enumerable:!0,get:function(){return xI.LRUCache}});Object.defineProperty(ve,"Touch",{enumerable:!0,get:function(){return xI.Touch}});var wIe=kG();Object.defineProperty(ve,"Disposable",{enumerable:!0,get:function(){return wIe.Disposable}});var iH=cy();Object.defineProperty(ve,"Event",{enumerable:!0,get:function(){return iH.Event}});Object.defineProperty(ve,"Emitter",{enumerable:!0,get:function(){return iH.Emitter}});var sH=eT();Object.defineProperty(ve,"CancellationTokenSource",{enumerable:!0,get:function(){return sH.CancellationTokenSource}});Object.defineProperty(ve,"CancellationToken",{enumerable:!0,get:function(){return sH.CancellationToken}});var oH=MG();Object.defineProperty(ve,"SharedArraySenderStrategy",{enumerable:!0,get:function(){return oH.SharedArraySenderStrategy}});Object.defineProperty(ve,"SharedArrayReceiverStrategy",{enumerable:!0,get:function(){return oH.SharedArrayReceiverStrategy}});var wI=BG();Object.defineProperty(ve,"MessageReader",{enumerable:!0,get:function(){return wI.MessageReader}});Object.defineProperty(ve,"AbstractMessageReader",{enumerable:!0,get:function(){return wI.AbstractMessageReader}});Object.defineProperty(ve,"ReadableStreamMessageReader",{enumerable:!0,get:function(){return wI.ReadableStreamMessageReader}});var DI=zG();Object.defineProperty(ve,"MessageWriter",{enumerable:!0,get:function(){return DI.MessageWriter}});Object.defineProperty(ve,"AbstractMessageWriter",{enumerable:!0,get:function(){return DI.AbstractMessageWriter}});Object.defineProperty(ve,"WriteableStreamMessageWriter",{enumerable:!0,get:function(){return DI.WriteableStreamMessageWriter}});var DIe=XG();Object.defineProperty(ve,"AbstractMessageBuffer",{enumerable:!0,get:function(){return DIe.AbstractMessageBuffer}});var Pr=rH();Object.defineProperty(ve,"ConnectionStrategy",{enumerable:!0,get:function(){return Pr.ConnectionStrategy}});Object.defineProperty(ve,"ConnectionOptions",{enumerable:!0,get:function(){return Pr.ConnectionOptions}});Object.defineProperty(ve,"NullLogger",{enumerable:!0,get:function(){return Pr.NullLogger}});Object.defineProperty(ve,"createMessageConnection",{enumerable:!0,get:function(){return Pr.createMessageConnection}});Object.defineProperty(ve,"ProgressToken",{enumerable:!0,get:function(){return Pr.ProgressToken}});Object.defineProperty(ve,"ProgressType",{enumerable:!0,get:function(){return Pr.ProgressType}});Object.defineProperty(ve,"Trace",{enumerable:!0,get:function(){return Pr.Trace}});Object.defineProperty(ve,"TraceValue",{enumerable:!0,get:function(){return Pr.TraceValue}});Object.defineProperty(ve,"TraceFormat",{enumerable:!0,get:function(){return Pr.TraceFormat}});Object.defineProperty(ve,"SetTraceNotification",{enumerable:!0,get:function(){return Pr.SetTraceNotification}});Object.defineProperty(ve,"LogTraceNotification",{enumerable:!0,get:function(){return Pr.LogTraceNotification}});Object.defineProperty(ve,"ConnectionErrors",{enumerable:!0,get:function(){return Pr.ConnectionErrors}});Object.defineProperty(ve,"ConnectionError",{enumerable:!0,get:function(){return Pr.ConnectionError}});Object.defineProperty(ve,"CancellationReceiverStrategy",{enumerable:!0,get:function(){return Pr.CancellationReceiverStrategy}});Object.defineProperty(ve,"IdCancellationReceiverStrategy",{enumerable:!0,get:function(){return Pr.IdCancellationReceiverStrategy}});Object.defineProperty(ve,"RequestCancellationReceiverStrategy",{enumerable:!0,get:function(){return Pr.RequestCancellationReceiverStrategy}});Object.defineProperty(ve,"CancellationSenderStrategy",{enumerable:!0,get:function(){return Pr.CancellationSenderStrategy}});Object.defineProperty(ve,"CancellationStrategy",{enumerable:!0,get:function(){return Pr.CancellationStrategy}});Object.defineProperty(ve,"MessageStrategy",{enumerable:!0,get:function(){return Pr.MessageStrategy}});Object.defineProperty(ve,"TraceValues",{enumerable:!0,get:function(){return Pr.TraceValues}});var TIe=xIe(rp());ve.RAL=TIe.default});var cH={};kf(cH,{AnnotatedTextEdit:()=>Sc,ApplyKind:()=>VI,ChangeAnnotation:()=>sp,ChangeAnnotationIdentifier:()=>ei,CodeAction:()=>sA,CodeActionContext:()=>iA,CodeActionKind:()=>rA,CodeActionTag:()=>fT,CodeActionTriggerKind:()=>Zb,CodeDescription:()=>$I,CodeLens:()=>oA,Color:()=>cT,ColorInformation:()=>SI,ColorPresentation:()=>EI,Command:()=>Yd,CompletionItem:()=>JI,CompletionItemKind:()=>MI,CompletionItemLabelDetails:()=>KI,CompletionItemTag:()=>qI,CompletionList:()=>GI,CreateFile:()=>my,DeleteFile:()=>hy,Diagnostic:()=>Wb,DiagnosticRelatedInformation:()=>uT,DiagnosticSeverity:()=>OI,DiagnosticTag:()=>PI,DocumentHighlight:()=>YI,DocumentHighlightKind:()=>QI,DocumentLink:()=>lA,DocumentSymbol:()=>nA,DocumentUri:()=>aT,EOL:()=>SIe,FoldingRange:()=>NI,FoldingRangeKind:()=>kI,FormattingOptions:()=>aA,Hover:()=>HI,InlayHint:()=>gA,InlayHintKind:()=>mT,InlayHintLabelPart:()=>yT,InlineCompletionContext:()=>wA,InlineCompletionItem:()=>bA,InlineCompletionList:()=>vA,InlineCompletionTriggerKind:()=>_A,InlineValueContext:()=>hA,InlineValueEvaluatableExpression:()=>yA,InlineValueText:()=>fA,InlineValueVariableLookup:()=>mA,InsertReplaceEdit:()=>UI,InsertTextFormat:()=>LI,InsertTextMode:()=>BI,LanguageKind:()=>FI,Location:()=>zb,LocationLink:()=>TI,MarkedString:()=>Xb,MarkupContent:()=>ap,MarkupKind:()=>dT,OptionalVersionedTextDocumentIdentifier:()=>Yb,ParameterInformation:()=>zI,Position:()=>zo,Range:()=>ir,RenameFile:()=>yy,SelectedCompletionInfo:()=>xA,SelectionRange:()=>cA,SemanticTokenModifiers:()=>pA,SemanticTokenTypes:()=>uA,SemanticTokens:()=>dA,SignatureInformation:()=>WI,SnippetTextEdit:()=>II,StringValue:()=>hT,SymbolInformation:()=>eA,SymbolKind:()=>XI,SymbolTag:()=>ZI,TextDocument:()=>DA,TextDocumentEdit:()=>Qb,TextDocumentIdentifier:()=>RI,TextDocumentItem:()=>CI,TextEdit:()=>xl,URI:()=>Hb,VersionedTextDocumentIdentifier:()=>jI,WorkspaceChange:()=>aH,WorkspaceEdit:()=>pT,WorkspaceFolder:()=>gT,WorkspaceSymbol:()=>tA,integer:()=>lT,uinteger:()=>op});class Gb{constructor(e,t){this.edits=e,this.changeAnnotations=t}insert(e,t,n){let r,i;if(n===void 0)r=xl.insert(e,t);else if(ei.is(n))i=n,r=Sc.insert(e,t,n);else this.assertChangeAnnotations(this.changeAnnotations),i=this.changeAnnotations.manage(n),r=Sc.insert(e,t,i);if(this.edits.push(r),i!==void 0)return i}replace(e,t,n){let r,i;if(n===void 0)r=xl.replace(e,t);else if(ei.is(n))i=n,r=Sc.replace(e,t,n);else this.assertChangeAnnotations(this.changeAnnotations),i=this.changeAnnotations.manage(n),r=Sc.replace(e,t,i);if(this.edits.push(r),i!==void 0)return i}delete(e,t){let n,r;if(t===void 0)n=xl.del(e);else if(ei.is(t))r=t,n=Sc.del(e,t);else this.assertChangeAnnotations(this.changeAnnotations),r=this.changeAnnotations.manage(t),n=Sc.del(e,r);if(this.edits.push(n),r!==void 0)return r}add(e){this.edits.push(e)}all(){return this.edits}clear(){this.edits.splice(0,this.edits.length)}assertChangeAnnotations(e){if(e===void 0)throw Error("Text edit change is not configured to manage change annotations.")}}class AI{constructor(e){this._annotations=e===void 0?Object.create(null):e,this._counter=0,this._size=0}all(){return this._annotations}get size(){return this._size}manage(e,t){let n;if(ei.is(e))n=e;else n=this.nextId(),t=e;if(this._annotations[n]!==void 0)throw Error(`Id ${n} is already in use.`);if(t===void 0)throw Error(`No annotation provided for id ${n}`);return this._annotations[n]=t,this._size++,n}nextId(){return this._counter++,this._counter.toString()}}class aH{constructor(e){if(this._textEditChanges=Object.create(null),e!==void 0){if(this._workspaceEdit=e,e.documentChanges)this._changeAnnotations=new AI(e.changeAnnotations),e.changeAnnotations=this._changeAnnotations.all(),e.documentChanges.forEach((t)=>{if(Qb.is(t)){let n=new Gb(t.edits,this._changeAnnotations);this._textEditChanges[t.textDocument.uri]=n}});else if(e.changes)Object.keys(e.changes).forEach((t)=>{let n=new Gb(e.changes[t]);this._textEditChanges[t]=n})}else this._workspaceEdit={}}get edit(){if(this.initDocumentChanges(),this._changeAnnotations!==void 0)if(this._changeAnnotations.size===0)this._workspaceEdit.changeAnnotations=void 0;else this._workspaceEdit.changeAnnotations=this._changeAnnotations.all();return this._workspaceEdit}getTextEditChange(e){if(Yb.is(e)){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error("Workspace edit is not configured for document changes.");let t={uri:e.uri,version:e.version},n=this._textEditChanges[t.uri];if(!n){let r=[],i={textDocument:t,edits:r};this._workspaceEdit.documentChanges.push(i),n=new Gb(r,this._changeAnnotations),this._textEditChanges[t.uri]=n}return n}else{if(this.initChanges(),this._workspaceEdit.changes===void 0)throw Error("Workspace edit is not configured for normal text edit changes.");let t=this._textEditChanges[e];if(!t){let n=[];this._workspaceEdit.changes[e]=n,t=new Gb(n),this._textEditChanges[e]=t}return t}}initDocumentChanges(){if(this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0)this._changeAnnotations=new AI,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()}initChanges(){if(this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0)this._workspaceEdit.changes=Object.create(null)}createFile(e,t,n){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error("Workspace edit is not configured for document changes.");let r;if(sp.is(t)||ei.is(t))r=t;else n=t;let i,s;if(r===void 0)i=my.create(e,n);else s=ei.is(r)?r:this._changeAnnotations.manage(r),i=my.create(e,n,s);if(this._workspaceEdit.documentChanges.push(i),s!==void 0)return s}renameFile(e,t,n,r){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error("Workspace edit is not configured for document changes.");let i;if(sp.is(n)||ei.is(n))i=n;else r=n;let s,o;if(i===void 0)s=yy.create(e,t,r);else o=ei.is(i)?i:this._changeAnnotations.manage(i),s=yy.create(e,t,r,o);if(this._workspaceEdit.documentChanges.push(s),o!==void 0)return o}deleteFile(e,t,n){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error("Workspace edit is not configured for document changes.");let r;if(sp.is(t)||ei.is(t))r=t;else n=t;let i,s;if(r===void 0)i=hy.create(e,n);else s=ei.is(r)?r:this._changeAnnotations.manage(r),i=hy.create(e,n,s);if(this._workspaceEdit.documentChanges.push(i),s!==void 0)return s}}class lH{constructor(e,t,n,r){this._uri=e,this._languageId=t,this._version=n,this._content=r,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(e){if(e){let t=this.offsetAt(e.start),n=this.offsetAt(e.end);return this._content.substring(t,n)}return this._content}update(e,t){this._content=e.text,this._version=t,this._lineOffsets=void 0}getLineOffsets(){if(this._lineOffsets===void 0){let e=[],t=this._content,n=!0;for(let r=0;r/^[$_a-zA-Z][$_a-zA-Z0-9]*$/.test(e)?e:JSON.stringify(e),value(e){if(e===null||typeof e!="object")return JSON.stringify(e);if(Array.isArray(e))return`[${e.map((n)=>ny.value(n)).join(", ")}]`;let t=Object.keys(e);return t.length===0?"{}":`{ ${t.map((n)=>`${ny.key(n)}: ${ny.value(e[n])}`).join(", ")} }`},pair:({key:e,value:t})=>ny.value({[e]:t})},RK=new Proxy(String,{get:()=>RK}),ml=RK,jK=Symbol.for("vnopts.VALUE_NOT_EXIST"),PD=Symbol.for("vnopts.VALUE_UNCHANGED"),C5=" ".repeat(2);ty=[],a$=[];A1e=["default","expected","validate","deprecated","forward","redirect","overlap","preprocess","postprocess"];F1e=class extends Wu{constructor(e){super(e),this._sourceName=e.sourceName}expected(e){return e.schemas[this._sourceName].expected(e)}validate(e,t){return t.schemas[this._sourceName].validate(e,t)}redirect(e,t){return this._sourceName}},C1e=class extends Wu{expected(){return"anything"}validate(){return!0}},M1e=class extends Wu{constructor({valueSchema:e,name:t=e.name,...n}){super({...n,name:t}),this._valueSchema=e}expected(e){let{text:t,list:n}=e.normalizeExpectedResult(this._valueSchema.expected(e));return{text:t&&`an array of ${t}`,list:n&&{title:"an array of the following values",values:[{list:n}]}}}validate(e,t){if(!Array.isArray(e))return!1;let n=[];for(let r of e){let i=t.normalizeValidateResult(this._valueSchema.validate(r,t),r);i!==!0&&n.push(i.value)}return n.length===0?!0:{value:n}}deprecated(e,t){let n=[];for(let r of e){let i=t.normalizeDeprecatedResult(this._valueSchema.deprecated(r,t),r);i!==!1&&n.push(...i.map(({value:s})=>({value:[s]})))}return n}forward(e,t){let n=[];for(let r of e){let i=t.normalizeForwardResult(this._valueSchema.forward(r,t),r);n.push(...i.map(L5))}return n}redirect(e,t){let n=[],r=[];for(let i of e){let s=t.normalizeRedirectResult(this._valueSchema.redirect(i,t),i);"remain"in s&&n.push(s.remain),r.push(...s.redirect.map(L5))}return n.length===0?{redirect:r}:{redirect:r,remain:n}}overlap(e,t){return e.concat(t)}};L1e=class extends Wu{expected(){return"true or false"}validate(e){return typeof e=="boolean"}};z1e=class extends Wu{constructor(e){super(e),this._choices=U1e(e.choices.map((t)=>t&&typeof t=="object"?t:{value:t}),"value")}expected({descriptor:e}){let t=Array.from(this._choices.keys()).map((i)=>this._choices.get(i)).filter(({hidden:i})=>!i).map((i)=>i.value).sort(J1e).map(e.value),n=t.slice(0,-2),r=t.slice(-2);return{text:n.concat(r.join(" or ")).join(", "),list:{title:"one of the following values",values:t}}}validate(e){return this._choices.has(e)}deprecated(e){let t=this._choices.get(e);return t&&t.deprecated?{value:e}:!1}forward(e){let t=this._choices.get(e);return t?t.forward:void 0}redirect(e){let t=this._choices.get(e);return t?t.redirect:void 0}},W1e=class extends Wu{expected(){return"a number"}validate(e,t){return typeof e=="number"}},Q1e=class extends W1e{expected(){return"an integer"}validate(e,t){return t.normalizeValidateResult(super.validate(e,t),e)===!0&&K1e(e)}},J5=class extends Wu{expected(){return"a string"}validate(e){return typeof e=="string"}},Y1e=ny,X1e=MK,Z1e=$1e,eNe=P1e;sNe=nNe,oNe=Array.prototype.findLast??function(e){for(let t=this.length-1;t>=0;t--){let n=this[t];if(e(n,t,this))return n}},aNe=Ib("findLast",function(){if(Array.isArray(this))return oNe}),qK=aNe,lNe=Symbol.for("PRETTIER_IS_FRONT_MATTER"),cNe=[];k$=uNe,UK=new Set(["yaml","toml"]);fNe=dNe;yNe=mNe,VK=new Set(["tokens","comments","parent","enclosingNode","precedingNode","followingNode"]);G5=gNe;xNe=new WeakMap;DNe=["clean","embed","print"],TNe=Object.fromEntries(DNe.map((e)=>[e,!1]));H5={astFormat:"estree",printer:{},originalText:void 0,locStart:null,locEnd:null,getVisitorKeys:null};sy=kNe,z5=/\r\n|[\n\r\u2028\u2029]/;Rb=$Ne;FNe=jNe;HK=CNe;LNe=MNe,qNe=Array.prototype.findLastIndex??function(e){for(let t=this.length-1;t>=0;t--){let n=this[t];if(e(n,t,this))return t}return-1},UNe=Ib("findLastIndex",function(){if(Array.isArray(this))return qNe}),BNe=UNe;zK=new Set(["JsonRoot","ObjectExpression","ArrayExpression","StringLiteral","NumericLiteral","BooleanLiteral","NullLiteral","UnaryExpression","TemplateLiteral"]),GNe=new Set(["OperationDefinition","FragmentDefinition","VariableDefinition","TypeExtensionDefinition","ObjectTypeDefinition","FieldDefinition","DirectiveDefinition","EnumTypeDefinition","EnumValueDefinition","InputValueDefinition","InputObjectTypeDefinition","SchemaDefinition","OperationTypeDefinition","InterfaceTypeDefinition","UnionTypeDefinition","ScalarTypeDefinition"]);X5=Symbol("cursor");ZK={};y$(ZK,{builders:()=>tOe,printer:()=>nOe,utils:()=>rOe});tOe={join:pK,line:dK,softline:bke,hardline:hc,literalline:mK,group:uK,conditionalGroup:mke,fill:fke,lineSuffix:p$,lineSuffixBoundary:vke,cursor:Bd,breakParent:FD,ifBreak:yke,trim:_ke,indent:$D,indentIfBreak:hke,align:iy,addAlignmentToDoc:cK,markAsRoot:lK,dedentToRoot:pke,dedent:dke,hardlineWithoutBreakParent:x$,literallineWithoutBreakParent:fK,label:gke,concat:(e)=>e},nOe={printDocToString:CD},rOe={willBreak:eke,traverseDoc:v$,findInDoc:_$,mapDoc:jD,removeLines:rke,stripTrailingHardline:oK,replaceEndOfLine:oke,canBreak:lke},UD={};y$(UD,{addDanglingComment:()=>qd,addLeadingComment:()=>Pb,addTrailingComment:()=>$b,getAlignmentSize:()=>D$,getIndentSize:()=>uOe,getMaxContinuousCount:()=>fOe,getNextNonSpaceNonCommentCharacter:()=>yOe,getNextNonSpaceNonCommentCharacterIndex:()=>TOe,getPreferredQuote:()=>bOe,getStringWidth:()=>w$,hasNewline:()=>Ju,hasNewlineInRange:()=>_Oe,hasSpaces:()=>wOe,isNextLineEmpty:()=>OOe,isNextLineEmptyAfterIndex:()=>I$,isPreviousLineEmpty:()=>EOe,makeString:()=>NOe,skip:()=>Ab,skipEverythingButNewLine:()=>wK,skipInlineComment:()=>O$,skipNewline:()=>Vd,skipSpaces:()=>Hu,skipToLineEnd:()=>xK,skipTrailingComment:()=>P$,skipWhitespace:()=>Wke});O$=sOe;P$=oOe;$$=aOe;I$=lOe;uOe=cOe;fOe=dOe;yOe=mOe,eJ=Object.freeze({character:"'",codePoint:39}),tJ=Object.freeze({character:'"',codePoint:34}),hOe=Object.freeze({preferred:eJ,alternate:tJ}),gOe=Object.freeze({preferred:tJ,alternate:eJ});_Oe=vOe;wOe=xOe;nJ=Ud(XK);$Oe=Ud($K,0),IOe={parse:Ud(QNe),formatAST:Ud(YNe),formatDoc:Ud(XNe),printToDoc:Ud(ZNe),printDocToString:Ud(eOe)}});var sJ=q(()=>{_t();Zs();It();Gt()});function MOe(e){return this[e<0?this.length+e:e]}function UOe(e){let t=e.length;while(t>0&&(e[t-1]==="\r"||e[t-1]===` +`))t--;return t`'${i}'`));return`Unexpected doc.type '${e.type}'. +Expected it to be ${r}.`}function HOe(e,t,n,r){let i=[e];while(i.length>0){let s=i.pop();if(s===oJ){n(i.pop());continue}if(n)i.push(s,oJ);let o=Wd(s);if(!o)throw new oy(s);if(t?.(s)===!1)continue;switch(o){case Tc:case Zu:{let a=o===Tc?s:s.parts;for(let l=a.length,c=l-1;c>=0;--c)i.push(a[c]);break}case Na:i.push(s.flatContents,s.breakContents);break;case Ho:if(r&&s.expandedStates)for(let a=s.expandedStates.length,l=a-1;l>=0;--l)i.push(s.expandedStates[l]);else i.push(s.contents);break;case Yu:case Qu:case ep:case rp:case tp:i.push(s.contents);break;case Hd:case zd:case Xu:case np:case es:case _l:break;default:throw new oy(s)}}}function JD(e,t){if(typeof e==="string")return t(e);let n=new Map;return r(e);function r(s){return BOe(n,s,i)}function i(s){switch(Wd(s)){case Tc:return t(s.map(r));case Zu:return t({...s,parts:s.parts.map(r)});case Na:return t({...s,breakContents:r(s.breakContents),flatContents:r(s.flatContents)});case Ho:{let{expandedStates:o,contents:a}=s;if(o)o=o.map(r),a=o[0];else a=r(a);return t({...s,contents:a,expandedStates:o})}case Yu:case Qu:case ep:case rp:case tp:return t({...s,contents:r(s.contents)});case Hd:case zd:case Xu:case np:case es:case _l:return t(s);default:throw new oy(s)}}}function j$(e,t,n){let r=n,i=!1;function s(o){if(i)return!1;let a=t(o);if(a!==void 0)i=!0,r=a}return R$(e,s),r}function zOe(e){if(e.type===Ho&&e.break)return!0;if(e.type===es&&e.hard)return!0;if(e.type===_l)return!0}function WOe(e){return j$(e,zOe,!1)}function aJ(e){if(e.length>0){let t=Gd(0,e,-1);if(!t.expandedStates&&!t.break)t.break="propagated"}return null}function QOe(e){let t=new Set,n=[];function r(s){if(s.type===_l)aJ(n);if(s.type===Ho){if(n.push(s),t.has(s))return!1;t.add(s)}}function i(s){if(s.type===Ho){if(n.pop().break)aJ(n)}}R$(e,r,i,!0)}function YOe(e){if(e.type===es&&!e.hard)return e.soft?"":" ";if(e.type===Na)return e.flatContents;return e}function XOe(e){return JD(e,YOe)}function lJ(e){e=[...e];while(e.length>=2&&Gd(0,e,-2).type===es&&Gd(0,e,-1).type===_l)e.length-=2;if(e.length>0){let t=jb(Gd(0,e,-1));e[e.length-1]=t}return e}function jb(e){switch(Wd(e)){case Qu:case ep:case Ho:case tp:case rp:{let t=jb(e.contents);return{...e,contents:t}}case Na:return{...e,breakContents:jb(e.breakContents),flatContents:jb(e.flatContents)};case Zu:return{...e,parts:lJ(e.parts)};case Tc:return lJ(e);case Hd:return UOe(e);case Yu:case zd:case Xu:case np:case es:case _l:break;default:throw new oy(e)}return e}function ZOe(e){return jb(tPe(e))}function ePe(e){switch(Wd(e)){case Zu:{let{parts:t}=e;if(t.every((n)=>n===""))return"";if(t.length===1)return t[0];break}case Ho:if(!e.contents&&!e.id&&!e.break&&!e.expandedStates)return"";if(e.contents.type===Ho&&e.contents.id===e.id&&e.contents.break===e.break&&e.contents.expandedStates===e.expandedStates)return e.contents;break;case Yu:case Qu:case ep:case tp:if(!e.contents)return"";break;case Na:if(!e.flatContents&&!e.breakContents)return"";break;case Tc:{let t=[];for(let n of e){if(!n)continue;let[r,...i]=Array.isArray(n)?n:[n];if(typeof r==="string"&&typeof Gd(0,t,-1)==="string")t[t.length-1]+=r;else t.push(r);t.push(...i)}if(t.length===0)return"";if(t.length===1)return t[0];return t}case Hd:case zd:case Xu:case np:case es:case rp:case _l:break;default:throw new oy(e)}return e}function tPe(e){return JD(e,(t)=>ePe(t))}function nPe(e,t=hJ){return JD(e,(n)=>typeof n==="string"?mJ(t,n.split(` +`)):n)}function rPe(e){if(e.type===es)return!0}function iPe(e){return j$(e,rPe,!1)}function VD(e){return vl(e),{type:Qu,contents:e}}function ay(e,t){return oPe(e),vl(t),{type:Yu,contents:t,n:e}}function aPe(e){return ay(Number.NEGATIVE_INFINITY,e)}function lPe(e){return ay({type:"root"},e)}function cPe(e){return ay(-1,e)}function uPe(e,t,n){vl(e);let r=e;if(t>0){for(let i=0;i=i&&cJ<=s)return[i,s];if(s-i>n-t)t=i,n=s}return[t,n]}function HPe(e){if(!e)return 0;if(!GPe.test(e))return e.length;let t=0;e=e.replace(APe(),(n)=>(t+=JPe(n)?1:2,""));for(let n of e){let r=n.codePointAt(0);if(r<=31||r>=127&&r<=159)continue;if(r>=768&&r<=879)continue;if(r>=65024&&r<=65039)continue;t+=BPe(r)||VPe(r)?2:1}return t}function SJ(e,t,n){let r=t.type===xJ?e.queue.slice(0,-1):[...e.queue,t],i="",s=0,o=0,a=0;for(let m of r)switch(m.type){case _J:if(u(),n.useTabs)l(1);else c(n.tabWidth);break;case DJ:{let{string:y}=m;u(),i+=y,s+=y.length;break}case wJ:{let{width:y}=m;o+=1,a+=y;break}default:throw Error(`Unexpected indent comment '${m.type}'.`)}return d(),{...e,value:i,length:s,queue:r};function l(m){i+="\t".repeat(m),s+=n.tabWidth*m}function c(m){i+=" ".repeat(m),s+=m}function u(){if(n.useTabs)p();else d()}function p(){if(o>0)l(o);f()}function d(){if(a>0)c(a);f()}function f(){o=0,a=0}}function QPe(e,t,n){if(!t)return e;if(t.type==="root")return{...e,root:e};if(t===Number.NEGATIVE_INFINITY)return e.root;let r;if(typeof t==="number")if(t<0)r=WPe;else r={type:wJ,width:t};else r={type:DJ,string:t};return SJ(e,r,n)}function YPe(e,t){return SJ(e,zPe,t)}function XPe(e){let t=0;for(let n=e.length-1;n>=0;n--){let r=e[n];if(r===" "||r==="\t")t++;else break}return t}function EJ(e){let t=XPe(e);return{text:t===0?e:e.slice(0,e.length-t),count:t}}function BD(e,t,n,r,i,s){if(n===Number.POSITIVE_INFINITY)return!0;let o=t.length,a=!1,l=[e],c="";while(n>=0){if(l.length===0){if(o===0)return!0;l.push(t[--o]);continue}let{mode:u,doc:p}=l.pop(),d=Wd(p);switch(d){case Hd:if(p){if(a)c+=" ",n-=1,a=!1;c+=p,n-=vJ(p)}break;case Tc:case Zu:{let f=d===Tc?p:p.parts,m=p[A$]??0;for(let y=f.length-1;y>=m;y--)l.push({mode:u,doc:f[y]});break}case Qu:case Yu:case ep:case rp:l.push({mode:u,doc:p.contents});break;case Xu:{let{text:f,count:m}=EJ(c);c=f,n+=m;break}case Ho:{if(s&&p.break)return!1;let f=p.break?Go:u,m=p.expandedStates&&f===Go?Gd(0,p.expandedStates,-1):p.contents;l.push({mode:f,doc:m});break}case Na:{let m=(p.groupId?i[p.groupId]||bl:u)===Go?p.breakContents:p.flatContents;if(m)l.push({mode:u,doc:m});break}case es:if(u===Go||p.hard)return!0;if(!p.soft)a=!0;break;case tp:r=!0;break;case np:if(r)return!1;break}}return!1}function t$e(e,t){let n=Object.create(null),r=t.printWidth,i=IPe(t.endOfLine),s=0,o=[{indent:TJ,mode:Go,doc:e}],a=!1,l=[],c=new e$e;QOe(e);while(o.length>0){let{indent:m,mode:y,doc:h}=o.pop();switch(Wd(h)){case Hd:{let b=i!==` +`?SPe(0,h,` +`,i):h;if(b){if(c.write(b),o.length>0)s+=vJ(b)}break}case Tc:for(let b=h.length-1;b>=0;b--)o.push({indent:m,mode:y,doc:h[b]});break;case zd:c.markPosition();break;case Qu:o.push({indent:YPe(m,t),mode:y,doc:h.contents});break;case Yu:o.push({indent:QPe(m,h.n,t),mode:y,doc:h.contents});break;case Xu:s-=c.trim();break;case Ho:{let b=function(){if(y===bl&&!a)return{indent:m,mode:h.break?Go:bl,doc:h.contents};a=!1;let x=r-s,v=l.length>0,D={indent:m,mode:bl,doc:h.contents};if(!h.break&&BD(D,o,x,v,n))return D;if(!h.expandedStates)return{indent:m,mode:Go,doc:h.contents};if(!h.break)for(let T=1;T0,n,!0);if(v===1){if(C)o.push(N);else o.push(O);break}let X={indent:m,mode:bl,doc:T},te={indent:m,mode:Go,doc:T};if(v===2){if(C)o.push(X,N);else o.push(te,O);break}let L=x[g+2],Y={indent:m,mode:y,doc:{...h,[A$]:g+2}},I=BD({indent:m,mode:bl,doc:[D,T,L]},[],b,l.length>0,n,!0);if(o.push(Y),I)o.push(X,N);else if(C)o.push(te,N);else o.push(te,O);break}case Na:case ep:{let b=h.groupId?n[h.groupId]:y;if(b===Go){let g=h.type===Na?h.breakContents:h.negate?h.contents:VD(h.contents);if(g)o.push({indent:m,mode:y,doc:g})}if(b===bl){let g=h.type===Na?h.flatContents:h.negate?VD(h.contents):h.contents;if(g)o.push({indent:m,mode:y,doc:g})}break}case tp:l.push({indent:m,mode:y,doc:h.contents});break;case np:if(l.length>0)o.push({indent:m,mode:y,doc:C$});break;case es:switch(y){case bl:if(!h.hard){if(!h.soft)c.write(" "),s+=1;break}a=!0;case Go:if(l.length>0){o.push({indent:m,mode:y,doc:h},...l.reverse()),l.length=0;break}if(h.literal){if(c.write(i),s=0,m.root){if(m.root.value)c.write(m.root.value);s=m.root.length}}else c.trim(),c.write(i+m.value),s=m.length;break}break;case rp:o.push({indent:m,mode:y,doc:h.contents});break;case _l:break;default:throw new oy(h)}if(o.length===0&&l.length>0)o.push(...l.reverse()),l.length=0}let{text:u,positions:p}=c.finish();if(p.length!==2)return{formatted:u};let[d,f]=p;return{formatted:u,cursorNodeStart:d,cursorNodeText:u.slice(d,f)}}var ROe,jOe=(e,t)=>{for(var n in t)ROe(e,n,{get:t[n],enumerable:!0})},FOe,COe=1,uJ=(e,t)=>(n,r,...i)=>{if(n|COe&&(r===void 0||r===null))return;return(t.call(r)??r[e]).apply(r,i)},LOe,Gd,qOe=()=>{},KD,Hd="string",Tc="array",zd="cursor",Qu="indent",Yu="align",Xu="trim",Ho="group",Zu="fill",Na="if-break",ep="indent-if-break",tp="line-suffix",np="line-suffix-boundary",es="line",rp="label",_l="break-parent",pJ,Wd,KOe=(e)=>new Intl.ListFormat("en-US",{type:"disjunction"}).format(e),GOe,oy,oJ,R$,vl,dJ,sPe,oPe,F$,pPe,gPe,bPe,C$,vPe,yJ,hJ,xPe,wPe,DPe,TPe,SPe,EPe="cr",kPe="crlf",NPe="\r",OPe=`\r +`,PPe=` +`,$Pe,APe=()=>/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E-\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED8\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])))?))?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3C-\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE8A\uDE8E-\uDEC2\uDEC6\uDEC8\uDECD-\uDEDC\uDEDF-\uDEEA\uDEEF]|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g,RPe=12288,jPe=65510,FPe,CPe=4352,MPe=262141,gJ,bJ=(e,t)=>{let n=0,r=Math.floor(e.length/2)-1;while(n<=r){let i=Math.floor((n+r)/2),s=i*2;if(te[s+1])n=i+1;else return!0}return!1},cJ=19968,LPe,qPe,BPe=(e)=>{if(ejPe)return!1;return bJ(FPe,e)},VPe=(e)=>{if(e>=LPe&&e<=qPe)return!0;if(eMPe)return!1;return bJ(gJ,e)},KPe,JPe=(e)=>KPe.test(e),GPe,vJ,_J=0,xJ=1,wJ=2,DJ=3,zPe,WPe,TJ,ZPe=class{#e=[];#t="";#n=0;#r=[];#i=[];#s(){let e=this.#t;if(e!=="")this.#e.push(e),this.#n+=e.length,this.#t="";for(let t of this.#i)this.#r.push(Math.min(t,this.#n));this.#i.length=0}markPosition(){if(this.#r.length+this.#i.length>=2)throw Error("There are too many 'cursor' in doc.");this.#i.push(this.#n+this.#t.length)}write(e){this.#t+=e}trim(){let{text:e,count:t}=EJ(this.#t);return this.#t=e,this.#s(),t}finish(){return this.#s(),{text:this.#e.join(""),positions:this.#r}}},e$e,Go,bl,A$,M$,n$e,r$e;var kJ=q(()=>{ROe=Object.defineProperty,FOe={};jOe(FOe,{builders:()=>M$,printer:()=>n$e,utils:()=>r$e});LOe=uJ("at",function(){if(Array.isArray(this)||typeof this==="string")return MOe}),Gd=LOe,KD=qOe,pJ=new Set([zd,Qu,Yu,Xu,Ho,Zu,Na,ep,tp,np,es,rp,_l]);Wd=VOe;GOe=class extends Error{name="InvalidDocError";constructor(e){super(JOe(e));this.doc=e}},oy=GOe,oJ={};R$=HOe;vl=KD,dJ=KD,sPe=KD,oPe=KD;F$={type:_l},pPe={type:zd};gPe={type:es},bPe={type:es,soft:!0},C$={type:es,hard:!0},vPe=[C$,F$],yJ={type:es,hard:!0,literal:!0},hJ=[yJ,F$];xPe={type:np},wPe={type:Xu},DPe=String.prototype.replaceAll??function(e,t){if(e.global)return this.replace(e,t);return this.split(e).join(t)},TPe=uJ("replaceAll",function(){if(typeof this==="string")return DPe}),SPe=TPe,$Pe=PPe;FPe=[12288,12288,65281,65376,65504,65510],gJ=[4352,4447,8986,8987,9001,9002,9193,9196,9200,9200,9203,9203,9725,9726,9748,9749,9776,9783,9800,9811,9855,9855,9866,9871,9875,9875,9889,9889,9898,9899,9917,9918,9924,9925,9934,9934,9940,9940,9962,9962,9970,9971,9973,9973,9978,9978,9981,9981,9989,9989,9994,9995,10024,10024,10060,10060,10062,10062,10067,10069,10071,10071,10133,10135,10160,10160,10175,10175,11035,11036,11088,11088,11093,11093,11904,11929,11931,12019,12032,12245,12272,12287,12289,12350,12353,12438,12441,12543,12549,12591,12593,12686,12688,12773,12783,12830,12832,12871,12880,42124,42128,42182,43360,43388,44032,55203,63744,64255,65040,65049,65072,65106,65108,65126,65128,65131,94176,94180,94192,94198,94208,101589,101631,101662,101760,101874,110576,110579,110581,110587,110589,110590,110592,110882,110898,110898,110928,110930,110933,110933,110948,110951,110960,111355,119552,119638,119648,119670,126980,126980,127183,127183,127374,127374,127377,127386,127488,127490,127504,127547,127552,127560,127568,127569,127584,127589,127744,127776,127789,127797,127799,127868,127870,127891,127904,127946,127951,127955,127968,127984,127988,127988,127992,128062,128064,128064,128066,128252,128255,128317,128331,128334,128336,128359,128378,128378,128405,128406,128420,128420,128507,128591,128640,128709,128716,128716,128720,128722,128725,128728,128732,128735,128747,128748,128756,128764,128992,129003,129008,129008,129292,129338,129340,129349,129351,129535,129648,129660,129664,129674,129678,129734,129736,129736,129741,129756,129759,129770,129775,129784,131072,196605,196608,262141],[LPe,qPe]=UPe(gJ);KPe=/^(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u2600-\u2604\u260E\u2611\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26B0\u26B1\u26C8\u26CF\u26D1\u26D3\u26E9\u26F0\u26F1\u26F4\u26F7\u26F8\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2763\u2764\u27A1\u2934\u2935\u2B05-\u2B07]|\uD83C[\uDD70\uDD71\uDD7E\uDD7F\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF3\uDFF5\uDFF7]|\uD83D[\uDC3F\uDC41\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3])$/,GPe=/[^\x20-\x7F]/;vJ=HPe,zPe={type:_J},WPe={type:xJ},TJ={value:"",length:0,queue:[],get root(){return TJ}};e$e=ZPe,Go=Symbol("MODE_BREAK"),bl=Symbol("MODE_FLAT"),A$=Symbol("DOC_FILL_PRINTED_LENGTH");M$={join:mJ,line:gPe,softline:bPe,hardline:vPe,literalline:hJ,group:fJ,conditionalGroup:fPe,fill:dPe,lineSuffix:_Pe,lineSuffixBoundary:xPe,cursor:pPe,breakParent:F$,ifBreak:mPe,trim:wPe,indent:VD,indentIfBreak:yPe,align:ay,addAlignmentToDoc:uPe,markAsRoot:lPe,dedentToRoot:aPe,dedent:cPe,hardlineWithoutBreakParent:C$,literallineWithoutBreakParent:yJ,label:hPe,concat:(e)=>e},n$e={printDocToString:t$e},r$e={willBreak:WOe,traverseDoc:R$,findInDoc:j$,mapDoc:JD,removeLines:XOe,stripTrailingHardline:ZOe,replaceEndOfLine:nPe,canBreak:iPe}});var L$;var q$=q(()=>{iJ();L$=UD});var NJ=q(()=>{It();q$()});var OJ=q(()=>{It()});var mgt,ygt,hgt,ggt,bgt,vgt,_gt,xgt,wgt,Dgt,Tgt,Sgt,PJ;var $J=q(()=>{kJ();_t();Lu();It();NJ();OJ();q$();({align:mgt,breakParent:ygt,group:hgt,hardline:ggt,ifBreak:bgt,indent:vgt,join:_gt,line:xgt,softline:wgt,literalline:Dgt,markAsRoot:Tgt}=M$),{isNextLineEmpty:Sgt}=L$;(function(e){e[e.Leading=2]="Leading",e[e.Trailing=4]="Trailing",e[e.Dangling=8]="Dangling",e[e.Block=16]="Block",e[e.Line=32]="Line",e[e.PrettierIgnore=64]="PrettierIgnore",e[e.First=128]="First",e[e.Last=256]="Last"})(PJ||(PJ={}))});var IJ=q(()=>{$J()});var AJ=q(()=>{sJ();IJ()});var Fb=q(()=>{AJ();mn()});var RJ=q(()=>{yr()});var jJ=()=>{};var GD;var FJ=q(()=>{Gt();(function(e){e[e.None=0]="None",e[e.Input=2]="Input",e[e.Output=4]="Output"})(GD||(GD={}))});var MJ=q(()=>{Bm();ic();RJ();jJ();Rw();e$();Lu();cc();FJ()});function LJ(e){return l$e.test(e)}var l$e;var HD=q(()=>{l$e=/^[a-z0-9]+(?:-[a-z0-9]+)*$/});function u$e(e,t){let n={};for(let r of Object.keys(t??{}))n[r]=Symbol.for(`${e}/${r}`);return n}function nr(e){let t;Qe(e.alias===void 0||LJ(e.alias),`Library alias "${e.alias}" for library "${e.name}" is invalid. It must contain only lowercase letters, digits, and hyphens (e.g. "tcgc").`);let{reportDiagnostic:n,createDiagnostic:r}=dw(e.diagnostics,e.name);function i(a){return Symbol.for(`${e.name}.${a}`)}let s=p$e();if(s)c$e.add(s);return{...e,diagnostics:e.diagnostics,stateKeys:u$e(e.name,e.state),reportDiagnostic:n,createDiagnostic:r,createStateSymbol:i,get emitterOptionValidator(){if(!t&&e.emitter?.options)t=Cu(e.emitter.options,{coerceTypes:!0});return t},getTracer:o};function o(a){return a.tracer.sub(e.name)}}function V$(e){return e}function zD(e){return e}function K$(e){return e}function Cb(e){return Qe(!e.name.includes("/"),"Rule name cannot contain a '/'."),e}function Qd(e,...t){t.forEach((n)=>n.namespace=e)}function p$e(){let e=d$e()[2];return typeof e==="object"&&"getFileName"in e?e.getFileName():void 0}function d$e(){let e=Error.prepareStackTrace;Error.prepareStackTrace=(n,r)=>r;let t=Error().stack.slice(1);return Error.prepareStackTrace=e,t}var B$,c$e;var ly=q(()=>{HD();FO();_t();Om();B$=Symbol.for("TYPESPEC_LIBRARY_URLS_LOADED");if(globalThis[B$]===void 0)globalThis[B$]=new Set;c$e=globalThis[B$]});var qJ=q(()=>{_t()});var WD=q(()=>{qJ();ly()});var UJ=q(()=>{_t()});var QD=q(()=>{UJ();ly();It()});var cy=q(()=>{Gt();Qg();HD();_t();ic();ly();WD();QD();GO();Yn();mn();Vw();Om();hb();It()});var BJ={};Of(BJ,{default:()=>y$e});var y$e;var VJ=q(()=>{y$e={version:"1.16.0",commit:"54d93a99737da023ed2cf8479b9573f73683b84d"}});var J$,h$e;var Mb=q(async()=>{try{J$=(await Promise.resolve().then(() => (VJ(),BJ))).default}catch{J$=(await import(["../dist","manifest.js"].join("/"))).default}h$e=J$.version});var Yd=()=>{};var H$=q(()=>{mn();Yd()});var z$=q(()=>{H$();Yd()});var W$=q(()=>{z$();H$();Yd()});var JJ=q(()=>{z$();Yd()});var YD=q(()=>{mn()});var GJ=q(()=>{mn();YD()});var Q$=q(()=>{mn();W$();JJ();Yd();GJ();YD()});var XD=q(()=>{Q$()});var zJ=()=>{};var uy=z(function(YJ){Object.defineProperty(YJ,"__esModule",{value:!0});YJ.boolean=E$e;YJ.string=WJ;YJ.number=k$e;YJ.error=N$e;YJ.func=O$e;YJ.array=QJ;YJ.stringArray=P$e;function E$e(e){return e===!0||e===!1}function WJ(e){return typeof e==="string"||e instanceof String}function k$e(e){return typeof e==="number"||e instanceof Number}function N$e(e){return e instanceof Error}function O$e(e){return typeof e==="function"}function QJ(e){return Array.isArray(e)}function P$e(e){return QJ(e)&&e.every((t)=>WJ(t))}});var Z$=z(function(ot){var M$e=ot&&ot.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),L$e=ot&&ot.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),q$e=ot&&ot.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;in,next:()=>{if(this._state!==e)throw Error("LinkedMap got modified during iteration.");if(t){let r={value:t.key,done:!1};return t=t.next,r}else return{value:void 0,done:!0}}};return n}values(){let e=this._state,t=this._head,n={[Symbol.iterator]:()=>n,next:()=>{if(this._state!==e)throw Error("LinkedMap got modified during iteration.");if(t){let r={value:t.value,done:!1};return t=t.next,r}else return{value:void 0,done:!0}}};return n}entries(){let e=this._state,t=this._head,n={[Symbol.iterator]:()=>n,next:()=>{if(this._state!==e)throw Error("LinkedMap got modified during iteration.");if(t){let r={value:[t.key,t.value],done:!1};return t=t.next,r}else return{value:void 0,done:!0}}};return n}[Symbol.iterator](){return this.entries()}trimOld(e){if(e>=this.size)return;if(e===0){this.clear();return}let t=this._head,n=this.size;while(t&&n>e)this._map.delete(t.key),t=t.next,n--;if(this._head=t,this._size=n,t)t.previous=void 0;this._state++}addItemFirst(e){if(!this._head&&!this._tail)this._tail=e;else if(!this._head)throw Error("Invalid list");else e.next=this._head,this._head.previous=e;this._head=e,this._state++}addItemLast(e){if(!this._head&&!this._tail)this._head=e;else if(!this._tail)throw Error("Invalid list");else e.previous=this._tail,this._tail.next=e;this._tail=e,this._state++}removeItem(e){if(e===this._head&&e===this._tail)this._head=void 0,this._tail=void 0;else if(e===this._head){if(!e.next)throw Error("Invalid list");e.next.previous=void 0,this._head=e.next}else if(e===this._tail){if(!e.previous)throw Error("Invalid list");e.previous.next=void 0,this._tail=e.previous}else{let{next:t,previous:n}=e;if(!t||!n)throw Error("Invalid list");t.previous=n,n.next=t}e.next=void 0,e.previous=void 0,this._state++}touch(e,t){if(!this._head||!this._tail)throw Error("Invalid list");if(t!==Ri.First&&t!==Ri.Last)return;if(t===Ri.First){if(e===this._head)return;let{next:n,previous:r}=e;if(e===this._tail)r.next=void 0,this._tail=r;else n.previous=r,r.next=n;e.previous=void 0,e.next=this._head,this._head.previous=e,this._head=e,this._state++}else if(t===Ri.Last){if(e===this._tail)return;let{next:n,previous:r}=e;if(e===this._head)n.previous=void 0,this._head=n;else n.previous=r,r.next=n;e.next=void 0,e.previous=this._tail,this._tail.next=e,this._tail=e,this._state++}}toJSON(){let e=[];return this.forEach((t,n)=>{e.push([n,t])}),e}fromJSON(e){this.clear();for(let[t,n]of e)this.set(t,n)}}wG.LinkedMap=eI;class xG extends eI{_limit;_ratio;constructor(e,t=1){super();this._limit=e,this._ratio=Math.min(Math.max(0,t),1)}get limit(){return this._limit}set limit(e){this._limit=e,this.checkTrim()}get ratio(){return this._ratio}set ratio(e){this._ratio=Math.min(Math.max(0,e),1),this.checkTrim()}get(e,t=Ri.AsNew){return super.get(e,t)}peek(e){return super.get(e,Ri.None)}set(e,t){return super.set(e,t,Ri.Last),this.checkTrim(),this}checkTrim(){if(this.size>this._limit)this.trimOld(Math.round(this._limit*this._ratio))}}wG.LRUCache=xG});var kG=z(function(SG){Object.defineProperty(SG,"__esModule",{value:!0});SG.Disposable=void 0;var TG;(function(e){function t(n){return{dispose:n}}e.create=t})(TG||(SG.Disposable=TG={}))});var ip=z(function(NG){Object.defineProperty(NG,"__esModule",{value:!0});var nI;function rI(){if(nI===void 0)throw Error("No runtime abstraction layer installed");return nI}(function(e){function t(n){if(n===void 0)throw Error("No runtime abstraction layer provided");nI=n}e.install=t})(rI||(rI={}));NG.default=rI});var py=z(function(sp){var K$e=sp&&sp.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(sp,"__esModule",{value:!0});sp.Emitter=sp.Event=void 0;var J$e=K$e(ip()),OG;(function(e){let t={dispose(){}};e.None=function(){return t}})(OG||(sp.Event=OG={}));class PG{_callbacks;_contexts;add(e,t=null,n){if(!this._callbacks)this._callbacks=[],this._contexts=[];if(this._callbacks.push(e),this._contexts.push(t),Array.isArray(n))n.push({dispose:()=>this.remove(e,t)})}remove(e,t=null){if(!this._callbacks)return;let n=!1;for(let r=0,i=this._callbacks.length;r{if(!this._callbacks)this._callbacks=new PG;if(this._options&&this._options.onFirstListenerAdd&&this._callbacks.isEmpty())this._options.onFirstListenerAdd(this);this._callbacks.add(e,t);let r={dispose:()=>{if(!this._callbacks)return;if(this._callbacks.remove(e,t),r.dispose=iI._noop,this._options&&this._options.onLastListenerRemove&&this._callbacks.isEmpty())this._options.onLastListenerRemove(this)}};if(Array.isArray(n))n.push(r);return r};return this._event}fire(e){if(this._callbacks)this._callbacks.invoke.call(this._callbacks,e)}dispose(){if(this._callbacks)this._callbacks.dispose(),this._callbacks=void 0}}sp.Emitter=iI});var eT=z(function($s){var G$e=$s&&$s.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),H$e=$s&&$s.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),z$e=$s&&$s.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;i{this._waiting.push({thunk:e,resolve:t,reject:n}),this.runNext()})}get active(){return this._active}runNext(){if(this._waiting.length===0||this._active===this._capacity)return;(0,nIe.default)().timer.setImmediate(()=>this.doRunNext())}doRunNext(){if(this._waiting.length===0||this._active===this._capacity)return;let e=this._waiting.shift();if(this._active++,this._active>this._capacity)throw Error("Too many thunks active");try{let t=e.thunk();if(t instanceof Promise)t.then((n)=>{this._active--,e.resolve(n),this.runNext()},(n)=>{this._active--,e.reject(n),this.runNext()});else this._active--,e.resolve(t),this.runNext()}catch(t){this._active--,e.reject(t),this.runNext()}}}dy.Semaphore=LG});var BG=z(function(ji){var rIe=ji&&ji.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),iIe=ji&&ji.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),sIe=ji&&ji.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;i{this.onData(n)});return this.readable.onError((n)=>this.fireError(n)),this.readable.onClose(()=>this.fireClose()),t}onData(e){try{this.buffer.append(e);while(!0){if(this.nextMessageLength===-1){let n=this.buffer.tryReadHeaders(!0);if(!n)return;let r=n.get("content-length");if(!r){this.fireError(Error(`Header must provide a Content-Length property. +${JSON.stringify(Object.fromEntries(n))}`));return}let i=parseInt(r);if(isNaN(i)){this.fireError(Error(`Content-Length value must be a number. Got ${r}`));return}this.nextMessageLength=i}let t=this.buffer.tryReadBody(this.nextMessageLength);if(t===void 0){this.setPartialMessageTimer();return}this.clearPartialMessageTimer(),this.nextMessageLength=-1,this.readSemaphore.lock(async()=>{let n=this.options.contentDecoder!==void 0?await this.options.contentDecoder.decode(t):t,r=await this.options.contentTypeDecoder.decode(n,this.options);this.callback(r)}).catch((n)=>{this.fireError(n)})}}catch(t){this.fireError(t)}}clearPartialMessageTimer(){if(this.partialMessageTimer)this.partialMessageTimer.dispose(),this.partialMessageTimer=void 0}setPartialMessageTimer(){if(this.clearPartialMessageTimer(),this._partialMessageTimeout<=0)return;this.partialMessageTimer=(0,cI.default)().timer.setTimeout((e,t)=>{if(this.partialMessageTimer=void 0,e===this.messageToken)this.firePartialMessage({messageToken:e,waitingTime:t}),this.setPartialMessageTimer()},this._partialMessageTimeout,this.messageToken,this._partialMessageTimeout)}}ji.ReadableStreamMessageReader=UG});var zG=z(function(Fi){var lIe=Fi&&Fi.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),cIe=Fi&&Fi.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),uIe=Fi&&Fi.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;ithis.fireError(n)),this.writable.onClose(()=>this.fireClose())}async write(e){return this.writeSemaphore.lock(async()=>this.options.contentTypeEncoder.encode(e,this.options).then((n)=>{if(this.options.contentEncoder!==void 0)return this.options.contentEncoder.encode(n);else return n}).then((n)=>{let r=[];return r.push(fIe,n.byteLength.toString(),JG),r.push(JG),this.doWrite(e,r,n)},(n)=>{throw this.fireError(n),n}))}async doWrite(e,t,n){try{return await this.writable.write(t.join(""),"ascii"),this.writable.write(n)}catch(r){return this.handleError(r,e),Promise.reject(r)}}handleError(e,t){this.errorCount++,this.fireError(e,t,this.errorCount)}end(){this.writable.end()}}Fi.WriteableStreamMessageWriter=HG});var XG=z(function(QG){Object.defineProperty(QG,"__esModule",{value:!0});QG.AbstractMessageBuffer=void 0;var mIe=13,yIe=10,hIe=`\r +`;class WG{_encoding;_chunks;_totalLength;constructor(e="utf-8"){this._encoding=e,this._chunks=[],this._totalLength=0}get encoding(){return this._encoding}append(e){let t=typeof e==="string"?this.fromString(e,this._encoding):e;this._chunks.push(t),this._totalLength+=t.byteLength}tryReadHeaders(e=!1){if(this._chunks.length===0)return;let t=0,n=0,r=0,i=0;e:while(nthis._totalLength)throw Error("Cannot read so many bytes!");if(this._chunks[0].byteLength===e){let i=this._chunks[0];return this._chunks.shift(),this._totalLength-=e,this.asNative(i)}if(this._chunks[0].byteLength>e){let i=this._chunks[0],s=this.asNative(i,e);return this._chunks[0]=i.slice(e),this._totalLength-=e,s}let t=this.allocNative(e),n=0,r=0;while(e>0){let i=this._chunks[r];if(i.byteLength>e){let s=i.slice(0,e);t.set(s,n),n+=e,this._chunks[r]=i.slice(e),this._totalLength-=e,e-=e}else t.set(i,n),n+=i.byteLength,this._chunks.shift(),this._totalLength-=i.byteLength,e-=i.byteLength}return t}}QG.AbstractMessageBuffer=WG});var rH=z(function(gt){var gIe=gt&>.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),bIe=gt&>.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),vIe=gt&>.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;i{},warn:()=>{},info:()=>{},log:()=>{}});var vn;(function(e){e[e.Off=0]="Off",e[e.Messages=1]="Messages",e[e.Compact=2]="Compact",e[e.Verbose=3]="Verbose"})(vn||(gt.Trace=vn={}));var gI;(function(e){e.Off="off",e.Messages="messages",e.Compact="compact",e.Verbose="verbose"})(gI||(gt.TraceValue=gI={}));gt.TraceValues=gI;(function(e){function t(r){if(!rr.string(r))return e.Off;switch(r=r.toLowerCase(),r){case"off":return e.Off;case"messages":return e.Messages;case"compact":return e.Compact;case"verbose":return e.Verbose;default:return e.Off}}e.fromString=t;function n(r){switch(r){case e.Off:return"off";case e.Messages:return"messages";case e.Compact:return"compact";case e.Verbose:return"verbose";default:return"off"}}e.toString=n})(vn||(gt.Trace=vn={}));var ro;(function(e){e.Text="text",e.JSON="json"})(ro||(gt.TraceFormat=ro={}));(function(e){function t(n){if(!rr.string(n))return e.Text;if(n=n.toLowerCase(),n==="json")return e.JSON;else return e.Text}e.fromString=t})(ro||(gt.TraceFormat=ro={}));var bI;(function(e){e.type=new Ot.NotificationType("$/setTrace")})(bI||(gt.SetTraceNotification=bI={}));var tT;(function(e){e.type=new Ot.NotificationType("$/logTrace")})(tT||(gt.LogTraceNotification=tT={}));var Kb;(function(e){e[e.Closed=1]="Closed",e[e.Disposed=2]="Disposed",e[e.AlreadyListening=3]="AlreadyListening"})(Kb||(gt.ConnectionErrors=Kb={}));class my extends Error{code;constructor(e,t){super(t);this.code=e,Object.setPrototypeOf(this,my.prototype)}}gt.ConnectionError=my;var vI;(function(e){function t(n){let r=n;return r&&rr.func(r.cancelUndispatched)}e.is=t})(vI||(gt.ConnectionStrategy=vI={}));var nT;(function(e){function t(n){let r=n;return r&&(r.kind===void 0||r.kind==="id")&&rr.func(r.createCancellationTokenSource)&&(r.dispose===void 0||rr.func(r.dispose))}e.is=t})(nT||(gt.IdCancellationReceiverStrategy=nT={}));var _I;(function(e){function t(n){let r=n;return r&&r.kind==="request"&&rr.func(r.createCancellationTokenSource)&&(r.dispose===void 0||rr.func(r.dispose))}e.is=t})(_I||(gt.RequestCancellationReceiverStrategy=_I={}));var rT;(function(e){e.Message=Object.freeze({createCancellationTokenSource(n){return new mI.CancellationTokenSource}});function t(n){return nT.is(n)||_I.is(n)}e.is=t})(rT||(gt.CancellationReceiverStrategy=rT={}));var iT;(function(e){e.Message=Object.freeze({sendCancellation(n,r){return n.sendNotification(Jb.type,{id:r})},cleanup(n){}});function t(n){let r=n;return r&&rr.func(r.sendCancellation)&&rr.func(r.cleanup)}e.is=t})(iT||(gt.CancellationSenderStrategy=iT={}));var sT;(function(e){e.Message=Object.freeze({receiver:rT.Message,sender:iT.Message});function t(n){let r=n;return r&&rT.is(r.receiver)&&iT.is(r.sender)}e.is=t})(sT||(gt.CancellationStrategy=sT={}));var oT;(function(e){function t(n){let r=n;return r&&rr.func(r.handleMessage)}e.is=t})(oT||(gt.MessageStrategy=oT={}));var tH;(function(e){function t(n){let r=n;return r&&(sT.is(r.cancellationStrategy)||vI.is(r.connectionStrategy)||oT.is(r.messageStrategy)||rr.number(r.maxParallelism))}e.is=t})(tH||(gt.ConnectionOptions=tH={}));var Oa;(function(e){e[e.New=1]="New",e[e.Listening=2]="Listening",e[e.Closed=3]="Closed",e[e.Disposed=4]="Disposed"})(Oa||(Oa={}));function xIe(e,t,n,r){let i=n!==void 0?n:gt.NullLogger,s=0,o=0,a=0,l="2.0",c=r?.maxParallelism??-1,u=0,p=void 0,d=new Map,f=void 0,m=new Map,y=new Map,h,b=new eH.LinkedMap,g=new Map,x=new Set,v=new Map,D=vn.Off,T=ro.Text,N,O=Oa.New,C=new Bb.Emitter,X=new Bb.Emitter,te=new Bb.Emitter,L=new Bb.Emitter,Y=new Bb.Emitter,me=r&&r.cancellationStrategy?r.cancellationStrategy:sT.Message;function I(E){return}function Z(){return O===Oa.Listening}function pe(){return O===Oa.Closed}function de(){return O===Oa.Disposed}function je(){if(O===Oa.New||O===Oa.Listening)O=Oa.Closed,X.fire(void 0)}function be(E){C.fire([E,void 0,void 0])}function Ie(E){C.fire(E)}e.onClose(je),e.onError(be),t.onClose(je),t.onError(Ie);function J(E){if(E===null)throw Error("Can't send requests with id null since the response can't be correlated.");return"req-"+E.toString()}function _e(E){if(E===null)return"res-unknown-"+(++a).toString();else return"res-"+E.toString()}function ue(){return"not-"+(++o).toString()}function ce(E,A){if(Ot.Message.isRequest(A))E.set(J(A.id),A);else if(Ot.Message.isResponse(A))if(c===-1)E.set(_e(A.id),A);else se(A);else E.set(ue(),A)}function Le(){if(h||b.size===0)return;if(c!==-1&&u>=c)return;h=(0,ZG.default)().timer.setImmediate(async()=>{if(h=void 0,b.size===0)return;if(c!==-1&&u>=c)return;let E=b.shift(),A;try{u++;let Q=r?.messageStrategy;if(oT.is(Q))A=Q.handleMessage(E,Ke);else A=Ke(E)}catch(Q){i.error(`Processing message queue failed: ${Q.toString()}`)}finally{if(A instanceof Promise)A.then(()=>{u--,Le()}).catch((Q)=>{i.error(`Processing message queue failed: ${Q.toString()}`)});else u--;Le()}})}async function Ke(E){if(Ot.Message.isRequest(E))return lt(E);else if(Ot.Message.isNotification(E))return he(E);else if(Ot.Message.isResponse(E))return se(E);else return Ne(E)}let ct=(E)=>{try{if(Ot.Message.isNotification(E)&&E.method===Jb.type.method){let A=E.params.id,Q=J(A),le=b.get(Q);if(Ot.Message.isRequest(le)){let Et=r?.connectionStrategy,ut=Et&&Et.cancelUndispatched?Et.cancelUndispatched(le,I):I(le);if(ut&&(ut.error!==void 0||ut.result!==void 0)){b.delete(Q),v.delete(A),ut.id=le.id,V(ut,E.method,Date.now()),t.write(ut).catch(()=>i.error("Sending response for canceled message failed."));return}}let Je=v.get(A);if(Je!==void 0){Je.cancel(),H(E);return}else x.add(A)}ce(b,E)}finally{Le()}};async function lt(E){if(de())return Promise.resolve();function A(wt,At,Ln){let Rn={jsonrpc:l,id:E.id};if(wt instanceof Ot.ResponseError)Rn.error=wt.toJson();else Rn.result=wt===void 0?null:wt;return V(Rn,At,Ln),t.write(Rn)}function Q(wt,At,Ln){let Rn={jsonrpc:l,id:E.id,error:wt.toJson()};return V(Rn,At,Ln),t.write(Rn)}j(E);let le=d.get(E.method),Je,Et;if(le)Je=le.type,Et=le.handler;let ut=Date.now();if(Et||p){let wt=E.id??String(Date.now()),At=nT.is(me.receiver)?me.receiver.createCancellationTokenSource(wt):me.receiver.createCancellationTokenSource(E);if(E.id!==null&&x.has(E.id))At.cancel();if(E.id!==null)v.set(wt,At);try{let Ln;if(Et)if(E.params===void 0){if(Je!==void 0&&Je.numberOfParams!==0)return Q(new Ot.ResponseError(Ot.ErrorCodes.InvalidParams,`Request ${E.method} defines ${Je.numberOfParams} params but received none.`),E.method,ut);Ln=Et(At.token)}else if(Array.isArray(E.params)){if(Je!==void 0&&Je.parameterStructures===Ot.ParameterStructures.byName)return Q(new Ot.ResponseError(Ot.ErrorCodes.InvalidParams,`Request ${E.method} defines parameters by name but received parameters by position`),E.method,ut);Ln=Et(...E.params,At.token)}else{if(Je!==void 0&&Je.parameterStructures===Ot.ParameterStructures.byPosition)return Q(new Ot.ResponseError(Ot.ErrorCodes.InvalidParams,`Request ${E.method} defines parameters by position but received parameters by name`),E.method,ut);Ln=Et(E.params,At.token)}else if(p)Ln=p(E.method,E.params,At.token);let Rn=await Ln;await A(Rn,E.method,ut)}catch(Ln){if(Ln instanceof Ot.ResponseError)await A(Ln,E.method,ut);else if(Ln&&rr.string(Ln.message))await Q(new Ot.ResponseError(Ot.ErrorCodes.InternalError,`Request ${E.method} failed with message: ${Ln.message}`),E.method,ut);else await Q(new Ot.ResponseError(Ot.ErrorCodes.InternalError,`Request ${E.method} failed unexpectedly without providing any details.`),E.method,ut)}finally{v.delete(wt)}}else await Q(new Ot.ResponseError(Ot.ErrorCodes.MethodNotFound,`Unhandled method ${E.method}`),E.method,ut)}function se(E){if(de())return;if(E.id===null)if(E.error)i.error(`Received response message without id: Error is: +${JSON.stringify(E.error,void 0,4)}`);else i.error("Received response message without id. No further error information provided.");else{let A=E.id,Q=g.get(A);if(ge(E,Q),Q!==void 0){g.delete(A);try{if(E.error){let le=E.error;Q.reject(new Ot.ResponseError(le.code,le.message,le.data))}else if(E.result!==void 0)Q.resolve(E.result);else throw Error("Should never happen.")}catch(le){if(le.message)i.error(`Response handler '${Q.method}' failed with message: ${le.message}`);else i.error(`Response handler '${Q.method}' failed unexpectedly.`)}}}}async function he(E){if(de())return;let A=void 0,Q;if(E.method===Jb.type.method){let le=E.params.id;x.delete(le),H(E);return}else{let le=m.get(E.method);if(le)Q=le.handler,A=le.type}if(Q||f)try{if(H(E),Q)if(E.params===void 0){if(A!==void 0){if(A.numberOfParams!==0&&A.parameterStructures!==Ot.ParameterStructures.byName)i.error(`Notification ${E.method} defines ${A.numberOfParams} params but received none.`)}await Q()}else if(Array.isArray(E.params)){let le=E.params;if(E.method===Vb.type.method&&le.length===2&&yI.is(le[0]))await Q({token:le[0],value:le[1]});else{if(A!==void 0){if(A.parameterStructures===Ot.ParameterStructures.byName)i.error(`Notification ${E.method} defines parameters by name but received parameters by position`);if(A.numberOfParams!==E.params.length)i.error(`Notification ${E.method} defines ${A.numberOfParams} params but received ${le.length} arguments`)}await Q(...le)}}else{if(A!==void 0&&A.parameterStructures===Ot.ParameterStructures.byPosition)i.error(`Notification ${E.method} defines parameters by position but received parameters by name`);await Q(E.params)}else if(f)await f(E.method,E.params)}catch(le){if(le.message)i.error(`Notification handler '${E.method}' failed with message: ${le.message}`);else i.error(`Notification handler '${E.method}' failed unexpectedly.`)}else te.fire(E)}function Ne(E){if(!E){i.error("Received empty message.");return}i.error(`Received message which is neither a response nor a notification message: +${JSON.stringify(E,null,4)}`);let A=E;if(rr.string(A.id)||rr.number(A.id)){let Q=A.id,le=g.get(Q);if(le)le.reject(Error("The received response has neither a result nor an error property."))}}function Re(E){if(E===void 0||E===null)return;switch(D){case vn.Verbose:return JSON.stringify(E,null,4);case vn.Compact:return JSON.stringify(E);default:return}}function Oe(E){if(D===vn.Off||!N)return;if(T===ro.Text){let A=void 0;if((D===vn.Verbose||D===vn.Compact)&&E.params)A=`Params: ${Re(E.params)}`;N.log(`Sending request '${E.method} - (${E.id})'.`,A)}else fe("send-request",E)}function G(E){if(D===vn.Off||!N)return;if(T===ro.Text){let A=void 0;if(D===vn.Verbose||D===vn.Compact)if(E.params)A=`Params: ${Re(E.params)}`;else A="No parameters provided.";N.log(`Sending notification '${E.method}'.`,A)}else fe("send-notification",E)}function V(E,A,Q){if(D===vn.Off||!N)return;if(T===ro.Text){let le=void 0;if(D===vn.Verbose||D===vn.Compact){if(E.error&&E.error.data)le=`Error data: ${Re(E.error.data)}`;else if(E.result)le=`Result: ${Re(E.result)}`;else if(E.error===void 0)le="No result returned."}N.log(`Sending response '${A} - (${E.id})'. Processing request took ${Date.now()-Q}ms`,le)}else fe("send-response",E)}function j(E){if(D===vn.Off||!N)return;if(T===ro.Text){let A=void 0;if((D===vn.Verbose||D===vn.Compact)&&E.params)A=`Params: ${Re(E.params)}`;N.log(`Received request '${E.method} - (${E.id})'.`,A)}else fe("receive-request",E)}function H(E){if(D===vn.Off||!N||E.method===tT.type.method)return;if(T===ro.Text){let A=void 0;if(D===vn.Verbose||D===vn.Compact)if(E.params)A=`Params: ${Re(E.params)}`;else A="No parameters provided.";N.log(`Received notification '${E.method}'.`,A)}else fe("receive-notification",E)}function ge(E,A){if(D===vn.Off||!N)return;if(T===ro.Text){let Q=void 0;if(D===vn.Verbose||D===vn.Compact){if(E.error&&E.error.data)Q=`Error data: ${Re(E.error.data)}`;else if(E.result)Q=`Result: ${Re(E.result)}`;else if(E.error===void 0)Q="No result returned."}if(A){let le=E.error?` Request failed: ${E.error.message} (${E.error.code}).`:"";N.log(`Received response '${A.method} - (${E.id})' in ${Date.now()-A.timerStart}ms.${le}`,Q)}else N.log(`Received response ${E.id} without active response promise.`,Q)}else fe("receive-response",E)}function fe(E,A){if(!N||D===vn.Off)return;let Q={isLSPMessage:!0,type:E,message:A,timestamp:Date.now()};N.log(Q)}function W(){if(pe())throw new my(Kb.Closed,"Connection is closed.");if(de())throw new my(Kb.Disposed,"Connection is disposed.")}function ye(){if(Z())throw new my(Kb.AlreadyListening,"Connection is already listening")}function Pe(){if(!Z())throw Error("Call listen() first.")}function Se(E){if(E===void 0)return null;else return E}function Ce(E){if(E===null)return;else return E}function Bt(E){return E!==void 0&&E!==null&&!Array.isArray(E)&&typeof E==="object"}function _(E,A){switch(E){case Ot.ParameterStructures.auto:if(Bt(A))return Ce(A);else return[Se(A)];case Ot.ParameterStructures.byName:if(!Bt(A))throw Error("Received parameters by name but param is not an object literal.");return Ce(A);case Ot.ParameterStructures.byPosition:return[Se(A)];default:throw Error(`Unknown parameter structure ${E.toString()}`)}}function S(E,A){let Q,le=E.numberOfParams;switch(le){case 0:Q=void 0;break;case 1:Q=_(E.parameterStructures,A[0]);break;default:Q=[];for(let Je=0;Je{W();let Q,le;if(rr.string(E)){Q=E;let Et=A[0],ut=0,wt=Ot.ParameterStructures.auto;if(Ot.ParameterStructures.is(Et))ut=1,wt=Et;let At=A.length,Ln=At-ut;switch(Ln){case 0:le=void 0;break;case 1:le=_(wt,A[ut]);break;default:if(wt===Ot.ParameterStructures.byName)throw Error(`Received ${Ln} parameters for 'by Name' notification parameter structure.`);le=A.slice(ut,At).map((Rn)=>Se(Rn));break}}else{let Et=A;Q=E.method,le=S(E,Et)}let Je={jsonrpc:l,method:Q,params:le};return G(Je),t.write(Je).catch((Et)=>{throw i.error("Sending notification failed."),Et})},onNotification:(E,A)=>{W();let Q;if(rr.func(E))f=E;else if(A)if(rr.string(E))Q=E,m.set(E,{type:void 0,handler:A});else Q=E.method,m.set(E.method,{type:E,handler:A});return{dispose:()=>{if(Q!==void 0){if(m.get(Q)?.handler===A)m.delete(Q)}else if(f===E)f=void 0}}},onProgress:(E,A,Q)=>{if(y.has(A))throw Error(`Progress handler for token ${A} already registered`);return y.set(A,Q),{dispose:()=>{if(y.get(A)===Q)y.delete(A)}}},sendProgress:(E,A,Q)=>k.sendNotification(Vb.type,{token:A,value:Q}),onUnhandledProgress:L.event,sendRequest:(E,...A)=>{W(),Pe();function Q(Rn,_i){let Us=me.sender.sendCancellation(Rn,_i);if(Us===void 0)i.log(`Received no promise from cancellation strategy when cancelling id ${_i}`);else Us.catch(()=>{i.log(`Sending cancellation messages for id ${_i} failed.`)})}let le,Je,Et=void 0;if(rr.string(E)){le=E;let Rn=A[0],_i=A[A.length-1],Us=0,qa=Ot.ParameterStructures.auto;if(Ot.ParameterStructures.is(Rn))Us=1,qa=Rn;let Bs=A.length;if(mI.CancellationToken.is(_i))Bs=Bs-1,Et=_i;let ls=Bs-Us;switch(ls){case 0:Je=void 0;break;case 1:Je=_(qa,A[Us]);break;default:if(qa===Ot.ParameterStructures.byName)throw Error(`Received ${ls} parameters for 'by Name' request parameter structure.`);Je=A.slice(Us,Bs).map((ah)=>Se(ah));break}}else{let Rn=A;le=E.method,Je=S(E,Rn);let _i=E.numberOfParams;Et=mI.CancellationToken.is(Rn[_i])?Rn[_i]:void 0}let ut=s++,wt,At=!1;if(Et!==void 0)if(Et.isCancellationRequested)At=!0;else wt=Et.onCancellationRequested(()=>{Q(k,ut)});let Ln={jsonrpc:l,id:ut,method:le,params:Je};if(Oe(Ln),typeof me.sender.enableCancellation==="function")me.sender.enableCancellation(Ln);return new Promise(async(Rn,_i)=>{let Us=(ls)=>{Rn(ls),me.sender.cleanup(ut),wt?.dispose()},qa=(ls)=>{_i(ls),me.sender.cleanup(ut),wt?.dispose()},Bs={method:le,timerStart:Date.now(),resolve:Us,reject:qa};try{if(g.set(ut,Bs),await t.write(Ln),At)Q(k,ut)}catch(ls){throw g.delete(ut),Bs.reject(new Ot.ResponseError(Ot.ErrorCodes.MessageWriteError,ls.message?ls.message:"Unknown reason")),i.error("Sending request failed."),ls}})},onRequest:(E,A)=>{W();let Q=null;if(hI.is(E))Q=void 0,p=E;else if(rr.string(E)){if(Q=null,A!==void 0)Q=E,d.set(E,{handler:A,type:void 0})}else if(A!==void 0)Q=E.method,d.set(E.method,{type:E,handler:A});return{dispose:()=>{if(Q===null)return;if(Q!==void 0){if(d.get(Q)?.handler===A)d.delete(Q)}else if(p===E)p=void 0}}},hasPendingResponse:()=>g.size>0,trace:async(E,A,Q)=>{let le=!1,Je=ro.Text;if(Q!==void 0)if(rr.boolean(Q))le=Q;else le=Q.sendNotification||!1,Je=Q.traceFormat||ro.Text;if(D=E,T=Je,D===vn.Off)N=void 0;else N=A;if(le&&!pe()&&!de())await k.sendNotification(bI.type,{value:vn.toString(E)})},onError:C.event,onClose:X.event,onUnhandledNotification:te.event,onDispose:Y.event,end:()=>{t.end()},dispose:()=>{if(de())return;O=Oa.Disposed,Y.fire(void 0);let E=new Ot.ResponseError(Ot.ErrorCodes.PendingResponseRejected,"Pending response rejected since connection got disposed");for(let A of g.values())A.reject(E);if(g=new Map,v=new Map,x=new Set,b=new eH.LinkedMap,rr.func(t.dispose))t.dispose();if(rr.func(e.dispose))e.dispose()},listen:()=>{W(),ye(),O=Oa.Listening,e.listen(ct)},inspect:()=>{(0,ZG.default)().console.log("inspect")}};return k.onNotification(tT.type,(E)=>{if(D===vn.Off||!N)return;let A=D===vn.Verbose||D===vn.Compact;N.log(E.message,A?E.verbose:void 0)}),k.onNotification(Vb.type,async(E)=>{let A=y.get(E.token);if(A)await A(E.value);else L.fire(E)}),k}});var yy=z(function(ve){var wIe=ve&&ve.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(ve,"__esModule",{value:!0});ve.ProgressType=ve.ProgressToken=ve.createMessageConnection=ve.NullLogger=ve.ConnectionOptions=ve.ConnectionStrategy=ve.AbstractMessageBuffer=ve.WriteableStreamMessageWriter=ve.AbstractMessageWriter=ve.MessageWriter=ve.ReadableStreamMessageReader=ve.AbstractMessageReader=ve.MessageReader=ve.SharedArrayReceiverStrategy=ve.SharedArraySenderStrategy=ve.CancellationToken=ve.CancellationTokenSource=ve.Emitter=ve.Event=ve.Disposable=ve.LRUCache=ve.Touch=ve.LinkedMap=ve.ParameterStructures=ve.NotificationType9=ve.NotificationType8=ve.NotificationType7=ve.NotificationType6=ve.NotificationType5=ve.NotificationType4=ve.NotificationType3=ve.NotificationType2=ve.NotificationType1=ve.NotificationType0=ve.NotificationType=ve.ErrorCodes=ve.ResponseError=ve.RequestType9=ve.RequestType8=ve.RequestType7=ve.RequestType6=ve.RequestType5=ve.RequestType4=ve.RequestType3=ve.RequestType2=ve.RequestType1=ve.RequestType0=ve.RequestType=ve.Message=ve.RAL=void 0;ve.MessageStrategy=ve.CancellationStrategy=ve.CancellationSenderStrategy=ve.RequestCancellationReceiverStrategy=ve.IdCancellationReceiverStrategy=ve.CancellationReceiverStrategy=ve.ConnectionError=ve.ConnectionErrors=ve.LogTraceNotification=ve.SetTraceNotification=ve.TraceFormat=ve.TraceValues=ve.TraceValue=ve.Trace=void 0;var Un=Z$();Object.defineProperty(ve,"Message",{enumerable:!0,get:function(){return Un.Message}});Object.defineProperty(ve,"RequestType",{enumerable:!0,get:function(){return Un.RequestType}});Object.defineProperty(ve,"RequestType0",{enumerable:!0,get:function(){return Un.RequestType0}});Object.defineProperty(ve,"RequestType1",{enumerable:!0,get:function(){return Un.RequestType1}});Object.defineProperty(ve,"RequestType2",{enumerable:!0,get:function(){return Un.RequestType2}});Object.defineProperty(ve,"RequestType3",{enumerable:!0,get:function(){return Un.RequestType3}});Object.defineProperty(ve,"RequestType4",{enumerable:!0,get:function(){return Un.RequestType4}});Object.defineProperty(ve,"RequestType5",{enumerable:!0,get:function(){return Un.RequestType5}});Object.defineProperty(ve,"RequestType6",{enumerable:!0,get:function(){return Un.RequestType6}});Object.defineProperty(ve,"RequestType7",{enumerable:!0,get:function(){return Un.RequestType7}});Object.defineProperty(ve,"RequestType8",{enumerable:!0,get:function(){return Un.RequestType8}});Object.defineProperty(ve,"RequestType9",{enumerable:!0,get:function(){return Un.RequestType9}});Object.defineProperty(ve,"ResponseError",{enumerable:!0,get:function(){return Un.ResponseError}});Object.defineProperty(ve,"ErrorCodes",{enumerable:!0,get:function(){return Un.ErrorCodes}});Object.defineProperty(ve,"NotificationType",{enumerable:!0,get:function(){return Un.NotificationType}});Object.defineProperty(ve,"NotificationType0",{enumerable:!0,get:function(){return Un.NotificationType0}});Object.defineProperty(ve,"NotificationType1",{enumerable:!0,get:function(){return Un.NotificationType1}});Object.defineProperty(ve,"NotificationType2",{enumerable:!0,get:function(){return Un.NotificationType2}});Object.defineProperty(ve,"NotificationType3",{enumerable:!0,get:function(){return Un.NotificationType3}});Object.defineProperty(ve,"NotificationType4",{enumerable:!0,get:function(){return Un.NotificationType4}});Object.defineProperty(ve,"NotificationType5",{enumerable:!0,get:function(){return Un.NotificationType5}});Object.defineProperty(ve,"NotificationType6",{enumerable:!0,get:function(){return Un.NotificationType6}});Object.defineProperty(ve,"NotificationType7",{enumerable:!0,get:function(){return Un.NotificationType7}});Object.defineProperty(ve,"NotificationType8",{enumerable:!0,get:function(){return Un.NotificationType8}});Object.defineProperty(ve,"NotificationType9",{enumerable:!0,get:function(){return Un.NotificationType9}});Object.defineProperty(ve,"ParameterStructures",{enumerable:!0,get:function(){return Un.ParameterStructures}});var xI=tI();Object.defineProperty(ve,"LinkedMap",{enumerable:!0,get:function(){return xI.LinkedMap}});Object.defineProperty(ve,"LRUCache",{enumerable:!0,get:function(){return xI.LRUCache}});Object.defineProperty(ve,"Touch",{enumerable:!0,get:function(){return xI.Touch}});var DIe=kG();Object.defineProperty(ve,"Disposable",{enumerable:!0,get:function(){return DIe.Disposable}});var iH=py();Object.defineProperty(ve,"Event",{enumerable:!0,get:function(){return iH.Event}});Object.defineProperty(ve,"Emitter",{enumerable:!0,get:function(){return iH.Emitter}});var sH=eT();Object.defineProperty(ve,"CancellationTokenSource",{enumerable:!0,get:function(){return sH.CancellationTokenSource}});Object.defineProperty(ve,"CancellationToken",{enumerable:!0,get:function(){return sH.CancellationToken}});var oH=MG();Object.defineProperty(ve,"SharedArraySenderStrategy",{enumerable:!0,get:function(){return oH.SharedArraySenderStrategy}});Object.defineProperty(ve,"SharedArrayReceiverStrategy",{enumerable:!0,get:function(){return oH.SharedArrayReceiverStrategy}});var wI=BG();Object.defineProperty(ve,"MessageReader",{enumerable:!0,get:function(){return wI.MessageReader}});Object.defineProperty(ve,"AbstractMessageReader",{enumerable:!0,get:function(){return wI.AbstractMessageReader}});Object.defineProperty(ve,"ReadableStreamMessageReader",{enumerable:!0,get:function(){return wI.ReadableStreamMessageReader}});var DI=zG();Object.defineProperty(ve,"MessageWriter",{enumerable:!0,get:function(){return DI.MessageWriter}});Object.defineProperty(ve,"AbstractMessageWriter",{enumerable:!0,get:function(){return DI.AbstractMessageWriter}});Object.defineProperty(ve,"WriteableStreamMessageWriter",{enumerable:!0,get:function(){return DI.WriteableStreamMessageWriter}});var TIe=XG();Object.defineProperty(ve,"AbstractMessageBuffer",{enumerable:!0,get:function(){return TIe.AbstractMessageBuffer}});var $r=rH();Object.defineProperty(ve,"ConnectionStrategy",{enumerable:!0,get:function(){return $r.ConnectionStrategy}});Object.defineProperty(ve,"ConnectionOptions",{enumerable:!0,get:function(){return $r.ConnectionOptions}});Object.defineProperty(ve,"NullLogger",{enumerable:!0,get:function(){return $r.NullLogger}});Object.defineProperty(ve,"createMessageConnection",{enumerable:!0,get:function(){return $r.createMessageConnection}});Object.defineProperty(ve,"ProgressToken",{enumerable:!0,get:function(){return $r.ProgressToken}});Object.defineProperty(ve,"ProgressType",{enumerable:!0,get:function(){return $r.ProgressType}});Object.defineProperty(ve,"Trace",{enumerable:!0,get:function(){return $r.Trace}});Object.defineProperty(ve,"TraceValue",{enumerable:!0,get:function(){return $r.TraceValue}});Object.defineProperty(ve,"TraceFormat",{enumerable:!0,get:function(){return $r.TraceFormat}});Object.defineProperty(ve,"SetTraceNotification",{enumerable:!0,get:function(){return $r.SetTraceNotification}});Object.defineProperty(ve,"LogTraceNotification",{enumerable:!0,get:function(){return $r.LogTraceNotification}});Object.defineProperty(ve,"ConnectionErrors",{enumerable:!0,get:function(){return $r.ConnectionErrors}});Object.defineProperty(ve,"ConnectionError",{enumerable:!0,get:function(){return $r.ConnectionError}});Object.defineProperty(ve,"CancellationReceiverStrategy",{enumerable:!0,get:function(){return $r.CancellationReceiverStrategy}});Object.defineProperty(ve,"IdCancellationReceiverStrategy",{enumerable:!0,get:function(){return $r.IdCancellationReceiverStrategy}});Object.defineProperty(ve,"RequestCancellationReceiverStrategy",{enumerable:!0,get:function(){return $r.RequestCancellationReceiverStrategy}});Object.defineProperty(ve,"CancellationSenderStrategy",{enumerable:!0,get:function(){return $r.CancellationSenderStrategy}});Object.defineProperty(ve,"CancellationStrategy",{enumerable:!0,get:function(){return $r.CancellationStrategy}});Object.defineProperty(ve,"MessageStrategy",{enumerable:!0,get:function(){return $r.MessageStrategy}});Object.defineProperty(ve,"TraceValues",{enumerable:!0,get:function(){return $r.TraceValues}});var SIe=wIe(ip());ve.RAL=SIe.default});var cH={};Of(cH,{AnnotatedTextEdit:()=>Sc,ApplyKind:()=>VI,ChangeAnnotation:()=>op,ChangeAnnotationIdentifier:()=>ti,CodeAction:()=>sA,CodeActionContext:()=>iA,CodeActionKind:()=>rA,CodeActionTag:()=>fT,CodeActionTriggerKind:()=>Zb,CodeDescription:()=>$I,CodeLens:()=>oA,Color:()=>cT,ColorInformation:()=>SI,ColorPresentation:()=>EI,Command:()=>Zd,CompletionItem:()=>JI,CompletionItemKind:()=>MI,CompletionItemLabelDetails:()=>KI,CompletionItemTag:()=>qI,CompletionList:()=>GI,CreateFile:()=>hy,DeleteFile:()=>by,Diagnostic:()=>Wb,DiagnosticRelatedInformation:()=>uT,DiagnosticSeverity:()=>OI,DiagnosticTag:()=>PI,DocumentHighlight:()=>YI,DocumentHighlightKind:()=>QI,DocumentLink:()=>lA,DocumentSymbol:()=>nA,DocumentUri:()=>aT,EOL:()=>EIe,FoldingRange:()=>NI,FoldingRangeKind:()=>kI,FormattingOptions:()=>aA,Hover:()=>HI,InlayHint:()=>gA,InlayHintKind:()=>mT,InlayHintLabelPart:()=>yT,InlineCompletionContext:()=>wA,InlineCompletionItem:()=>bA,InlineCompletionList:()=>vA,InlineCompletionTriggerKind:()=>_A,InlineValueContext:()=>hA,InlineValueEvaluatableExpression:()=>yA,InlineValueText:()=>fA,InlineValueVariableLookup:()=>mA,InsertReplaceEdit:()=>UI,InsertTextFormat:()=>LI,InsertTextMode:()=>BI,LanguageKind:()=>FI,Location:()=>zb,LocationLink:()=>TI,MarkedString:()=>Xb,MarkupContent:()=>lp,MarkupKind:()=>dT,OptionalVersionedTextDocumentIdentifier:()=>Yb,ParameterInformation:()=>zI,Position:()=>zo,Range:()=>ir,RenameFile:()=>gy,SelectedCompletionInfo:()=>xA,SelectionRange:()=>cA,SemanticTokenModifiers:()=>pA,SemanticTokenTypes:()=>uA,SemanticTokens:()=>dA,SignatureInformation:()=>WI,SnippetTextEdit:()=>II,StringValue:()=>hT,SymbolInformation:()=>eA,SymbolKind:()=>XI,SymbolTag:()=>ZI,TextDocument:()=>DA,TextDocumentEdit:()=>Qb,TextDocumentIdentifier:()=>RI,TextDocumentItem:()=>CI,TextEdit:()=>xl,URI:()=>Hb,VersionedTextDocumentIdentifier:()=>jI,WorkspaceChange:()=>aH,WorkspaceEdit:()=>pT,WorkspaceFolder:()=>gT,WorkspaceSymbol:()=>tA,integer:()=>lT,uinteger:()=>ap});class Gb{constructor(e,t){this.edits=e,this.changeAnnotations=t}insert(e,t,n){let r,i;if(n===void 0)r=xl.insert(e,t);else if(ti.is(n))i=n,r=Sc.insert(e,t,n);else this.assertChangeAnnotations(this.changeAnnotations),i=this.changeAnnotations.manage(n),r=Sc.insert(e,t,i);if(this.edits.push(r),i!==void 0)return i}replace(e,t,n){let r,i;if(n===void 0)r=xl.replace(e,t);else if(ti.is(n))i=n,r=Sc.replace(e,t,n);else this.assertChangeAnnotations(this.changeAnnotations),i=this.changeAnnotations.manage(n),r=Sc.replace(e,t,i);if(this.edits.push(r),i!==void 0)return i}delete(e,t){let n,r;if(t===void 0)n=xl.del(e);else if(ti.is(t))r=t,n=Sc.del(e,t);else this.assertChangeAnnotations(this.changeAnnotations),r=this.changeAnnotations.manage(t),n=Sc.del(e,r);if(this.edits.push(n),r!==void 0)return r}add(e){this.edits.push(e)}all(){return this.edits}clear(){this.edits.splice(0,this.edits.length)}assertChangeAnnotations(e){if(e===void 0)throw Error("Text edit change is not configured to manage change annotations.")}}class AI{constructor(e){this._annotations=e===void 0?Object.create(null):e,this._counter=0,this._size=0}all(){return this._annotations}get size(){return this._size}manage(e,t){let n;if(ti.is(e))n=e;else n=this.nextId(),t=e;if(this._annotations[n]!==void 0)throw Error(`Id ${n} is already in use.`);if(t===void 0)throw Error(`No annotation provided for id ${n}`);return this._annotations[n]=t,this._size++,n}nextId(){return this._counter++,this._counter.toString()}}class aH{constructor(e){if(this._textEditChanges=Object.create(null),e!==void 0){if(this._workspaceEdit=e,e.documentChanges)this._changeAnnotations=new AI(e.changeAnnotations),e.changeAnnotations=this._changeAnnotations.all(),e.documentChanges.forEach((t)=>{if(Qb.is(t)){let n=new Gb(t.edits,this._changeAnnotations);this._textEditChanges[t.textDocument.uri]=n}});else if(e.changes)Object.keys(e.changes).forEach((t)=>{let n=new Gb(e.changes[t]);this._textEditChanges[t]=n})}else this._workspaceEdit={}}get edit(){if(this.initDocumentChanges(),this._changeAnnotations!==void 0)if(this._changeAnnotations.size===0)this._workspaceEdit.changeAnnotations=void 0;else this._workspaceEdit.changeAnnotations=this._changeAnnotations.all();return this._workspaceEdit}getTextEditChange(e){if(Yb.is(e)){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error("Workspace edit is not configured for document changes.");let t={uri:e.uri,version:e.version},n=this._textEditChanges[t.uri];if(!n){let r=[],i={textDocument:t,edits:r};this._workspaceEdit.documentChanges.push(i),n=new Gb(r,this._changeAnnotations),this._textEditChanges[t.uri]=n}return n}else{if(this.initChanges(),this._workspaceEdit.changes===void 0)throw Error("Workspace edit is not configured for normal text edit changes.");let t=this._textEditChanges[e];if(!t){let n=[];this._workspaceEdit.changes[e]=n,t=new Gb(n),this._textEditChanges[e]=t}return t}}initDocumentChanges(){if(this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0)this._changeAnnotations=new AI,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()}initChanges(){if(this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0)this._workspaceEdit.changes=Object.create(null)}createFile(e,t,n){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error("Workspace edit is not configured for document changes.");let r;if(op.is(t)||ti.is(t))r=t;else n=t;let i,s;if(r===void 0)i=hy.create(e,n);else s=ti.is(r)?r:this._changeAnnotations.manage(r),i=hy.create(e,n,s);if(this._workspaceEdit.documentChanges.push(i),s!==void 0)return s}renameFile(e,t,n,r){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error("Workspace edit is not configured for document changes.");let i;if(op.is(n)||ti.is(n))i=n;else r=n;let s,o;if(i===void 0)s=gy.create(e,t,r);else o=ti.is(i)?i:this._changeAnnotations.manage(i),s=gy.create(e,t,r,o);if(this._workspaceEdit.documentChanges.push(s),o!==void 0)return o}deleteFile(e,t,n){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error("Workspace edit is not configured for document changes.");let r;if(op.is(t)||ti.is(t))r=t;else n=t;let i,s;if(r===void 0)i=by.create(e,n);else s=ti.is(r)?r:this._changeAnnotations.manage(r),i=by.create(e,n,s);if(this._workspaceEdit.documentChanges.push(i),s!==void 0)return s}}class lH{constructor(e,t,n,r){this._uri=e,this._languageId=t,this._version=n,this._content=r,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(e){if(e){let t=this.offsetAt(e.start),n=this.offsetAt(e.end);return this._content.substring(t,n)}return this._content}update(e,t){this._content=e.text,this._version=t,this._lineOffsets=void 0}getLineOffsets(){if(this._lineOffsets===void 0){let e=[],t=this._content,n=!0;for(let r=0;r0)e.push(t.length);this._lineOffsets=e}return this._lineOffsets}positionAt(e){e=Math.max(Math.min(e,this._content.length),0);let t=this.getLineOffsets(),n=0,r=t.length;if(r===0)return zo.create(0,e);while(ne)r=s;else n=s+1}let i=n-1;return zo.create(i,e-t[i])}offsetAt(e){let t=this.getLineOffsets();if(e.line>=t.length)return this._content.length;else if(e.line<0)return 0;let n=t[e.line],r=e.line+1{(function(e){function t(n){return typeof n==="string"}e.is=t})(aT||(aT={}));(function(e){function t(n){return typeof n==="string"}e.is=t})(Hb||(Hb={}));(function(e){e.MIN_VALUE=-2147483648,e.MAX_VALUE=2147483647;function t(n){return typeof n==="number"&&e.MIN_VALUE<=n&&n<=e.MAX_VALUE}e.is=t})(lT||(lT={}));(function(e){e.MIN_VALUE=0,e.MAX_VALUE=2147483647;function t(n){return typeof n==="number"&&e.MIN_VALUE<=n&&n<=e.MAX_VALUE}e.is=t})(op||(op={}));(function(e){function t(r,i){if(r===Number.MAX_VALUE)r=op.MAX_VALUE;if(i===Number.MAX_VALUE)i=op.MAX_VALUE;return{line:r,character:i}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&oe.uinteger(i.line)&&oe.uinteger(i.character)}e.is=n})(zo||(zo={}));(function(e){function t(r,i,s,o){if(oe.uinteger(r)&&oe.uinteger(i)&&oe.uinteger(s)&&oe.uinteger(o))return{start:zo.create(r,i),end:zo.create(s,o)};else if(zo.is(r)&&zo.is(i))return{start:r,end:i};else throw Error(`Range#create called with invalid arguments[${r}, ${i}, ${s}, ${o}]`)}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&zo.is(i.start)&&zo.is(i.end)}e.is=n})(ir||(ir={}));(function(e){function t(r,i){return{uri:r,range:i}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&ir.is(i.range)&&(oe.string(i.uri)||oe.undefined(i.uri))}e.is=n})(zb||(zb={}));(function(e){function t(r,i,s,o){return{targetUri:r,targetRange:i,targetSelectionRange:s,originSelectionRange:o}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&ir.is(i.targetRange)&&oe.string(i.targetUri)&&ir.is(i.targetSelectionRange)&&(ir.is(i.originSelectionRange)||oe.undefined(i.originSelectionRange))}e.is=n})(TI||(TI={}));(function(e){function t(r,i,s,o){return{red:r,green:i,blue:s,alpha:o}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&oe.numberRange(i.red,0,1)&&oe.numberRange(i.green,0,1)&&oe.numberRange(i.blue,0,1)&&oe.numberRange(i.alpha,0,1)}e.is=n})(cT||(cT={}));(function(e){function t(r,i){return{range:r,color:i}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&ir.is(i.range)&&cT.is(i.color)}e.is=n})(SI||(SI={}));(function(e){function t(r,i,s){return{label:r,textEdit:i,additionalTextEdits:s}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&oe.string(i.label)&&(oe.undefined(i.textEdit)||xl.is(i))&&(oe.undefined(i.additionalTextEdits)||oe.typedArray(i.additionalTextEdits,xl.is))}e.is=n})(EI||(EI={}));(function(e){e.Comment="comment",e.Imports="imports",e.Region="region"})(kI||(kI={}));(function(e){function t(r,i,s,o,a,l){let c={startLine:r,endLine:i};if(oe.defined(s))c.startCharacter=s;if(oe.defined(o))c.endCharacter=o;if(oe.defined(a))c.kind=a;if(oe.defined(l))c.collapsedText=l;return c}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&oe.uinteger(i.startLine)&&oe.uinteger(i.startLine)&&(oe.undefined(i.startCharacter)||oe.uinteger(i.startCharacter))&&(oe.undefined(i.endCharacter)||oe.uinteger(i.endCharacter))&&(oe.undefined(i.kind)||oe.string(i.kind))}e.is=n})(NI||(NI={}));(function(e){function t(r,i){return{location:r,message:i}}e.create=t;function n(r){let i=r;return oe.defined(i)&&zb.is(i.location)&&oe.string(i.message)}e.is=n})(uT||(uT={}));(function(e){e.Error=1,e.Warning=2,e.Information=3,e.Hint=4})(OI||(OI={}));(function(e){e.Unnecessary=1,e.Deprecated=2})(PI||(PI={}));(function(e){function t(n){let r=n;return oe.objectLiteral(r)&&oe.string(r.href)}e.is=t})($I||($I={}));(function(e){function t(s,o,a,l,c,u){let p={range:s,message:o};if(oe.defined(a))p.severity=a;if(oe.defined(l))p.code=l;if(oe.defined(c))p.source=c;if(oe.defined(u))p.relatedInformation=u;return p}e.create=t;function n(s){var o;let a=s;return oe.defined(a)&&ir.is(a.range)&&(oe.string(a.message)||ap.is(a.message))&&(oe.number(a.severity)||oe.undefined(a.severity))&&(oe.integer(a.code)||oe.string(a.code)||oe.undefined(a.code))&&(oe.undefined(a.codeDescription)||oe.string((o=a.codeDescription)===null||o===void 0?void 0:o.href))&&(oe.string(a.source)||oe.undefined(a.source))&&(oe.undefined(a.relatedInformation)||oe.typedArray(a.relatedInformation,uT.is))}e.is=n;function r(s){return oe.string(s.message)}e.is3_17=r;function i(s){if(oe.string(s.message))return s.message;else if(ap.is(s.message))return s.message.value;else throw Error(`Unknown message type ${typeof s.message}`)}e.getMessageString=i})(Wb||(Wb={}));(function(e){function t(r,i,...s){let o={title:r,command:i};if(oe.defined(s)&&s.length>0)o.arguments=s;return o}e.create=t;function n(r){let i=r;return oe.defined(i)&&oe.string(i.title)&&(i.tooltip===void 0||oe.string(i.tooltip))&&oe.string(i.command)}e.is=n})(Yd||(Yd={}));(function(e){function t(s,o){return{range:s,newText:o}}e.replace=t;function n(s,o){return{range:{start:s,end:s},newText:o}}e.insert=n;function r(s){return{range:s,newText:""}}e.del=r;function i(s){let o=s;return oe.objectLiteral(o)&&oe.string(o.newText)&&ir.is(o.range)}e.is=i})(xl||(xl={}));(function(e){function t(r,i,s){let o={label:r};if(i!==void 0)o.needsConfirmation=i;if(s!==void 0)o.description=s;return o}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&oe.string(i.label)&&(oe.boolean(i.needsConfirmation)||i.needsConfirmation===void 0)&&(oe.string(i.description)||i.description===void 0)}e.is=n})(sp||(sp={}));(function(e){function t(n){let r=n;return oe.string(r)}e.is=t})(ei||(ei={}));(function(e){function t(s,o,a){return{range:s,newText:o,annotationId:a}}e.replace=t;function n(s,o,a){return{range:{start:s,end:s},newText:o,annotationId:a}}e.insert=n;function r(s,o){return{range:s,newText:"",annotationId:o}}e.del=r;function i(s){let o=s;return xl.is(o)&&(sp.is(o.annotationId)||ei.is(o.annotationId))}e.is=i})(Sc||(Sc={}));(function(e){function t(r,i){return{textDocument:r,edits:i}}e.create=t;function n(r){let i=r;return oe.defined(i)&&Yb.is(i.textDocument)&&Array.isArray(i.edits)}e.is=n})(Qb||(Qb={}));(function(e){function t(r,i,s){let o={kind:"create",uri:r};if(i!==void 0&&(i.overwrite!==void 0||i.ignoreIfExists!==void 0))o.options=i;if(s!==void 0)o.annotationId=s;return o}e.create=t;function n(r){let i=r;return i&&i.kind==="create"&&oe.string(i.uri)&&(i.options===void 0||(i.options.overwrite===void 0||oe.boolean(i.options.overwrite))&&(i.options.ignoreIfExists===void 0||oe.boolean(i.options.ignoreIfExists)))&&(i.annotationId===void 0||ei.is(i.annotationId))}e.is=n})(my||(my={}));(function(e){function t(r,i,s,o){let a={kind:"rename",oldUri:r,newUri:i};if(s!==void 0&&(s.overwrite!==void 0||s.ignoreIfExists!==void 0))a.options=s;if(o!==void 0)a.annotationId=o;return a}e.create=t;function n(r){let i=r;return i&&i.kind==="rename"&&oe.string(i.oldUri)&&oe.string(i.newUri)&&(i.options===void 0||(i.options.overwrite===void 0||oe.boolean(i.options.overwrite))&&(i.options.ignoreIfExists===void 0||oe.boolean(i.options.ignoreIfExists)))&&(i.annotationId===void 0||ei.is(i.annotationId))}e.is=n})(yy||(yy={}));(function(e){function t(r,i,s){let o={kind:"delete",uri:r};if(i!==void 0&&(i.recursive!==void 0||i.ignoreIfNotExists!==void 0))o.options=i;if(s!==void 0)o.annotationId=s;return o}e.create=t;function n(r){let i=r;return i&&i.kind==="delete"&&oe.string(i.uri)&&(i.options===void 0||(i.options.recursive===void 0||oe.boolean(i.options.recursive))&&(i.options.ignoreIfNotExists===void 0||oe.boolean(i.options.ignoreIfNotExists)))&&(i.annotationId===void 0||ei.is(i.annotationId))}e.is=n})(hy||(hy={}));(function(e){function t(n){let r=n;return r&&(r.changes!==void 0||r.documentChanges!==void 0)&&(r.documentChanges===void 0||r.documentChanges.every((i)=>{if(oe.string(i.kind))return my.is(i)||yy.is(i)||hy.is(i);else return Qb.is(i)}))}e.is=t})(pT||(pT={}));(function(e){function t(n){let r=n;return oe.objectLiteral(r)&&ir.is(r.range)&&hT.isSnippet(r.snippet)&&(r.annotationId===void 0||(sp.is(r.annotationId)||ei.is(r.annotationId)))}e.is=t})(II||(II={}));(function(e){function t(r){return{uri:r}}e.create=t;function n(r){let i=r;return oe.defined(i)&&oe.string(i.uri)}e.is=n})(RI||(RI={}));(function(e){function t(r,i){return{uri:r,version:i}}e.create=t;function n(r){let i=r;return oe.defined(i)&&oe.string(i.uri)&&oe.integer(i.version)}e.is=n})(jI||(jI={}));(function(e){function t(r,i){return{uri:r,version:i}}e.create=t;function n(r){let i=r;return oe.defined(i)&&oe.string(i.uri)&&(i.version===null||oe.integer(i.version))}e.is=n})(Yb||(Yb={}));(function(e){e.ABAP="abap",e.WindowsBat="bat",e.BibTeX="bibtex",e.Clojure="clojure",e.Coffeescript="coffeescript",e.C="c",e.CPP="cpp",e.CSharp="csharp",e.CSS="css",e.D="d",e.Delphi="pascal",e.Diff="diff",e.Dart="dart",e.Dockerfile="dockerfile",e.Elixir="elixir",e.Erlang="erlang",e.FSharp="fsharp",e.GitCommit="git-commit",e.GitRebase="git-rebase",e.Go="go",e.Groovy="groovy",e.Handlebars="handlebars",e.Haskell="haskell",e.HTML="html",e.Ini="ini",e.Java="java",e.JavaScript="javascript",e.JavaScriptReact="javascriptreact",e.JSON="json",e.LaTeX="latex",e.Less="less",e.Lua="lua",e.Makefile="makefile",e.Markdown="markdown",e.ObjectiveC="objective-c",e.ObjectiveCPP="objective-cpp",e.Pascal="pascal",e.Perl="perl",e.Perl6="perl6",e.PHP="php",e.Plaintext="plaintext",e.Powershell="powershell",e.Pug="jade",e.Python="python",e.R="r",e.Razor="razor",e.Ruby="ruby",e.Rust="rust",e.SCSS="scss",e.SASS="sass",e.Scala="scala",e.ShaderLab="shaderlab",e.ShellScript="shellscript",e.SQL="sql",e.Swift="swift",e.TypeScript="typescript",e.TypeScriptReact="typescriptreact",e.TeX="tex",e.VisualBasic="vb",e.XML="xml",e.XSL="xsl",e.YAML="yaml"})(FI||(FI={}));(function(e){function t(r,i,s,o){return{uri:r,languageId:i,version:s,text:o}}e.create=t;function n(r){let i=r;return oe.defined(i)&&oe.string(i.uri)&&oe.string(i.languageId)&&oe.integer(i.version)&&oe.string(i.text)}e.is=n})(CI||(CI={}));(function(e){e.PlainText="plaintext",e.Markdown="markdown";function t(n){let r=n;return r===e.PlainText||r===e.Markdown}e.is=t})(dT||(dT={}));(function(e){function t(n){let r=n;return oe.objectLiteral(n)&&dT.is(r.kind)&&oe.string(r.value)}e.is=t})(ap||(ap={}));(function(e){e.Text=1,e.Method=2,e.Function=3,e.Constructor=4,e.Field=5,e.Variable=6,e.Class=7,e.Interface=8,e.Module=9,e.Property=10,e.Unit=11,e.Value=12,e.Enum=13,e.Keyword=14,e.Snippet=15,e.Color=16,e.File=17,e.Reference=18,e.Folder=19,e.EnumMember=20,e.Constant=21,e.Struct=22,e.Event=23,e.Operator=24,e.TypeParameter=25})(MI||(MI={}));(function(e){e.PlainText=1,e.Snippet=2})(LI||(LI={}));(function(e){e.Deprecated=1})(qI||(qI={}));(function(e){function t(r,i,s){return{newText:r,insert:i,replace:s}}e.create=t;function n(r){let i=r;return i&&oe.string(i.newText)&&ir.is(i.insert)&&ir.is(i.replace)}e.is=n})(UI||(UI={}));(function(e){e.asIs=1,e.adjustIndentation=2})(BI||(BI={}));(function(e){e.Replace=1,e.Merge=2})(VI||(VI={}));(function(e){function t(n){let r=n;return r&&(oe.string(r.detail)||r.detail===void 0)&&(oe.string(r.description)||r.description===void 0)}e.is=t})(KI||(KI={}));(function(e){function t(n){return{label:n}}e.create=t})(JI||(JI={}));(function(e){function t(n,r){return{items:n?n:[],isIncomplete:!!r}}e.create=t})(GI||(GI={}));(function(e){function t(r){return r.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}e.fromPlainText=t;function n(r){let i=r;return oe.string(i)||oe.objectLiteral(i)&&oe.string(i.language)&&oe.string(i.value)}e.is=n})(Xb||(Xb={}));(function(e){function t(n){let r=n;return!!r&&oe.objectLiteral(r)&&(ap.is(r.contents)||Xb.is(r.contents)||oe.typedArray(r.contents,Xb.is))&&(n.range===void 0||ir.is(n.range))}e.is=t})(HI||(HI={}));(function(e){function t(n,r){return r?{label:n,documentation:r}:{label:n}}e.create=t})(zI||(zI={}));(function(e){function t(n,r,...i){let s={label:n};if(oe.defined(r))s.documentation=r;if(oe.defined(i))s.parameters=i;else s.parameters=[];return s}e.create=t})(WI||(WI={}));(function(e){e.Text=1,e.Read=2,e.Write=3})(QI||(QI={}));(function(e){function t(n,r){let i={range:n};if(oe.number(r))i.kind=r;return i}e.create=t})(YI||(YI={}));(function(e){e.File=1,e.Module=2,e.Namespace=3,e.Package=4,e.Class=5,e.Method=6,e.Property=7,e.Field=8,e.Constructor=9,e.Enum=10,e.Interface=11,e.Function=12,e.Variable=13,e.Constant=14,e.String=15,e.Number=16,e.Boolean=17,e.Array=18,e.Object=19,e.Key=20,e.Null=21,e.EnumMember=22,e.Struct=23,e.Event=24,e.Operator=25,e.TypeParameter=26})(XI||(XI={}));(function(e){e.Deprecated=1})(ZI||(ZI={}));(function(e){function t(n,r,i,s,o){let a={name:n,kind:r,location:{uri:s,range:i}};if(o)a.containerName=o;return a}e.create=t})(eA||(eA={}));(function(e){function t(n,r,i,s){return s!==void 0?{name:n,kind:r,location:{uri:i,range:s}}:{name:n,kind:r,location:{uri:i}}}e.create=t})(tA||(tA={}));(function(e){function t(r,i,s,o,a,l){let c={name:r,detail:i,kind:s,range:o,selectionRange:a};if(l!==void 0)c.children=l;return c}e.create=t;function n(r){let i=r;return i&&oe.string(i.name)&&oe.number(i.kind)&&ir.is(i.range)&&ir.is(i.selectionRange)&&(i.detail===void 0||oe.string(i.detail))&&(i.deprecated===void 0||oe.boolean(i.deprecated))&&(i.children===void 0||Array.isArray(i.children))&&(i.tags===void 0||Array.isArray(i.tags))}e.is=n})(nA||(nA={}));(function(e){e.Empty="",e.QuickFix="quickfix",e.Refactor="refactor",e.RefactorExtract="refactor.extract",e.RefactorInline="refactor.inline",e.RefactorMove="refactor.move",e.RefactorRewrite="refactor.rewrite",e.Source="source",e.SourceOrganizeImports="source.organizeImports",e.SourceFixAll="source.fixAll",e.Notebook="notebook"})(rA||(rA={}));(function(e){e.Invoked=1,e.Automatic=2})(Zb||(Zb={}));(function(e){function t(r,i,s){let o={diagnostics:r};if(i!==void 0&&i!==null)o.only=i;if(s!==void 0&&s!==null)o.triggerKind=s;return o}e.create=t;function n(r){let i=r;return oe.defined(i)&&oe.typedArray(i.diagnostics,Wb.is)&&(i.only===void 0||oe.typedArray(i.only,oe.string))&&(i.triggerKind===void 0||i.triggerKind===Zb.Invoked||i.triggerKind===Zb.Automatic)}e.is=n})(iA||(iA={}));(function(e){e.LLMGenerated=1;function t(n){return oe.defined(n)&&n===e.LLMGenerated}e.is=t})(fT||(fT={}));(function(e){function t(r,i,s){let o={title:r},a=!0;if(typeof i==="string")a=!1,o.kind=i;else if(Yd.is(i))o.command=i;else o.edit=i;if(a&&s!==void 0)o.kind=s;return o}e.create=t;function n(r){let i=r;return i&&oe.string(i.title)&&(i.diagnostics===void 0||oe.typedArray(i.diagnostics,Wb.is))&&(i.kind===void 0||oe.string(i.kind))&&(i.edit!==void 0||i.command!==void 0)&&(i.command===void 0||Yd.is(i.command))&&(i.isPreferred===void 0||oe.boolean(i.isPreferred))&&(i.edit===void 0||pT.is(i.edit))&&(i.tags===void 0||oe.typedArray(i.tags,fT.is))}e.is=n})(sA||(sA={}));(function(e){function t(r,i){let s={range:r};if(oe.defined(i))s.data=i;return s}e.create=t;function n(r){let i=r;return oe.defined(i)&&ir.is(i.range)&&(oe.undefined(i.command)||Yd.is(i.command))}e.is=n})(oA||(oA={}));(function(e){function t(r,i){return{tabSize:r,insertSpaces:i}}e.create=t;function n(r){let i=r;return oe.defined(i)&&oe.uinteger(i.tabSize)&&oe.boolean(i.insertSpaces)}e.is=n})(aA||(aA={}));(function(e){function t(r,i,s){return{range:r,target:i,data:s}}e.create=t;function n(r){let i=r;return oe.defined(i)&&ir.is(i.range)&&(oe.undefined(i.target)||oe.string(i.target))}e.is=n})(lA||(lA={}));(function(e){function t(r,i){return{range:r,parent:i}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&ir.is(i.range)&&(i.parent===void 0||e.is(i.parent))}e.is=n})(cA||(cA={}));(function(e){e.namespace="namespace",e.type="type",e.class="class",e.enum="enum",e.interface="interface",e.struct="struct",e.typeParameter="typeParameter",e.parameter="parameter",e.variable="variable",e.property="property",e.enumMember="enumMember",e.event="event",e.function="function",e.method="method",e.macro="macro",e.keyword="keyword",e.modifier="modifier",e.comment="comment",e.string="string",e.number="number",e.regexp="regexp",e.operator="operator",e.decorator="decorator",e.label="label"})(uA||(uA={}));(function(e){e.declaration="declaration",e.definition="definition",e.readonly="readonly",e.static="static",e.deprecated="deprecated",e.abstract="abstract",e.async="async",e.modification="modification",e.documentation="documentation",e.defaultLibrary="defaultLibrary"})(pA||(pA={}));(function(e){function t(n){let r=n;return oe.objectLiteral(r)&&(r.resultId===void 0||typeof r.resultId==="string")&&Array.isArray(r.data)&&(r.data.length===0||typeof r.data[0]==="number")}e.is=t})(dA||(dA={}));(function(e){function t(r,i){return{range:r,text:i}}e.create=t;function n(r){let i=r;return i!==void 0&&i!==null&&ir.is(i.range)&&oe.string(i.text)}e.is=n})(fA||(fA={}));(function(e){function t(r,i,s){return{range:r,variableName:i,caseSensitiveLookup:s}}e.create=t;function n(r){let i=r;return i!==void 0&&i!==null&&ir.is(i.range)&&oe.boolean(i.caseSensitiveLookup)&&(oe.string(i.variableName)||i.variableName===void 0)}e.is=n})(mA||(mA={}));(function(e){function t(r,i){return{range:r,expression:i}}e.create=t;function n(r){let i=r;return i!==void 0&&i!==null&&ir.is(i.range)&&(oe.string(i.expression)||i.expression===void 0)}e.is=n})(yA||(yA={}));(function(e){function t(r,i){return{frameId:r,stoppedLocation:i}}e.create=t;function n(r){let i=r;return oe.defined(i)&&ir.is(r.stoppedLocation)}e.is=n})(hA||(hA={}));(function(e){e.Type=1,e.Parameter=2;function t(n){return n===1||n===2}e.is=t})(mT||(mT={}));(function(e){function t(r){return{value:r}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&(i.tooltip===void 0||oe.string(i.tooltip)||ap.is(i.tooltip))&&(i.location===void 0||zb.is(i.location))&&(i.command===void 0||Yd.is(i.command))}e.is=n})(yT||(yT={}));(function(e){function t(r,i,s){let o={position:r,label:i};if(s!==void 0)o.kind=s;return o}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&zo.is(i.position)&&(oe.string(i.label)||oe.typedArray(i.label,yT.is))&&(i.kind===void 0||mT.is(i.kind))&&i.textEdits===void 0||oe.typedArray(i.textEdits,xl.is)&&(i.tooltip===void 0||oe.string(i.tooltip)||ap.is(i.tooltip))&&(i.paddingLeft===void 0||oe.boolean(i.paddingLeft))&&(i.paddingRight===void 0||oe.boolean(i.paddingRight))}e.is=n})(gA||(gA={}));(function(e){function t(r){return{kind:"snippet",value:r}}e.createSnippet=t;function n(r){let i=r;return oe.objectLiteral(i)&&i.kind==="snippet"&&oe.string(i.value)}e.isSnippet=n})(hT||(hT={}));(function(e){function t(n,r,i,s){return{insertText:n,filterText:r,range:i,command:s}}e.create=t})(bA||(bA={}));(function(e){function t(n){return{items:n}}e.create=t})(vA||(vA={}));(function(e){e.Invoked=1,e.Automatic=2})(_A||(_A={}));(function(e){function t(n,r){return{range:n,text:r}}e.create=t})(xA||(xA={}));(function(e){function t(n,r){return{triggerKind:n,selectedCompletionInfo:r}}e.create=t})(wA||(wA={}));(function(e){function t(n){let r=n;return oe.objectLiteral(r)&&Hb.is(r.uri)&&oe.string(r.name)}e.is=t})(gT||(gT={}));SIe=[` +`)r++}if(n&&t.length>0)e.push(t.length);this._lineOffsets=e}return this._lineOffsets}positionAt(e){e=Math.max(Math.min(e,this._content.length),0);let t=this.getLineOffsets(),n=0,r=t.length;if(r===0)return zo.create(0,e);while(ne)r=s;else n=s+1}let i=n-1;return zo.create(i,e-t[i])}offsetAt(e){let t=this.getLineOffsets();if(e.line>=t.length)return this._content.length;else if(e.line<0)return 0;let n=t[e.line],r=e.line+1{(function(e){function t(n){return typeof n==="string"}e.is=t})(aT||(aT={}));(function(e){function t(n){return typeof n==="string"}e.is=t})(Hb||(Hb={}));(function(e){e.MIN_VALUE=-2147483648,e.MAX_VALUE=2147483647;function t(n){return typeof n==="number"&&e.MIN_VALUE<=n&&n<=e.MAX_VALUE}e.is=t})(lT||(lT={}));(function(e){e.MIN_VALUE=0,e.MAX_VALUE=2147483647;function t(n){return typeof n==="number"&&e.MIN_VALUE<=n&&n<=e.MAX_VALUE}e.is=t})(ap||(ap={}));(function(e){function t(r,i){if(r===Number.MAX_VALUE)r=ap.MAX_VALUE;if(i===Number.MAX_VALUE)i=ap.MAX_VALUE;return{line:r,character:i}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&oe.uinteger(i.line)&&oe.uinteger(i.character)}e.is=n})(zo||(zo={}));(function(e){function t(r,i,s,o){if(oe.uinteger(r)&&oe.uinteger(i)&&oe.uinteger(s)&&oe.uinteger(o))return{start:zo.create(r,i),end:zo.create(s,o)};else if(zo.is(r)&&zo.is(i))return{start:r,end:i};else throw Error(`Range#create called with invalid arguments[${r}, ${i}, ${s}, ${o}]`)}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&zo.is(i.start)&&zo.is(i.end)}e.is=n})(ir||(ir={}));(function(e){function t(r,i){return{uri:r,range:i}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&ir.is(i.range)&&(oe.string(i.uri)||oe.undefined(i.uri))}e.is=n})(zb||(zb={}));(function(e){function t(r,i,s,o){return{targetUri:r,targetRange:i,targetSelectionRange:s,originSelectionRange:o}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&ir.is(i.targetRange)&&oe.string(i.targetUri)&&ir.is(i.targetSelectionRange)&&(ir.is(i.originSelectionRange)||oe.undefined(i.originSelectionRange))}e.is=n})(TI||(TI={}));(function(e){function t(r,i,s,o){return{red:r,green:i,blue:s,alpha:o}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&oe.numberRange(i.red,0,1)&&oe.numberRange(i.green,0,1)&&oe.numberRange(i.blue,0,1)&&oe.numberRange(i.alpha,0,1)}e.is=n})(cT||(cT={}));(function(e){function t(r,i){return{range:r,color:i}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&ir.is(i.range)&&cT.is(i.color)}e.is=n})(SI||(SI={}));(function(e){function t(r,i,s){return{label:r,textEdit:i,additionalTextEdits:s}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&oe.string(i.label)&&(oe.undefined(i.textEdit)||xl.is(i))&&(oe.undefined(i.additionalTextEdits)||oe.typedArray(i.additionalTextEdits,xl.is))}e.is=n})(EI||(EI={}));(function(e){e.Comment="comment",e.Imports="imports",e.Region="region"})(kI||(kI={}));(function(e){function t(r,i,s,o,a,l){let c={startLine:r,endLine:i};if(oe.defined(s))c.startCharacter=s;if(oe.defined(o))c.endCharacter=o;if(oe.defined(a))c.kind=a;if(oe.defined(l))c.collapsedText=l;return c}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&oe.uinteger(i.startLine)&&oe.uinteger(i.startLine)&&(oe.undefined(i.startCharacter)||oe.uinteger(i.startCharacter))&&(oe.undefined(i.endCharacter)||oe.uinteger(i.endCharacter))&&(oe.undefined(i.kind)||oe.string(i.kind))}e.is=n})(NI||(NI={}));(function(e){function t(r,i){return{location:r,message:i}}e.create=t;function n(r){let i=r;return oe.defined(i)&&zb.is(i.location)&&oe.string(i.message)}e.is=n})(uT||(uT={}));(function(e){e.Error=1,e.Warning=2,e.Information=3,e.Hint=4})(OI||(OI={}));(function(e){e.Unnecessary=1,e.Deprecated=2})(PI||(PI={}));(function(e){function t(n){let r=n;return oe.objectLiteral(r)&&oe.string(r.href)}e.is=t})($I||($I={}));(function(e){function t(s,o,a,l,c,u){let p={range:s,message:o};if(oe.defined(a))p.severity=a;if(oe.defined(l))p.code=l;if(oe.defined(c))p.source=c;if(oe.defined(u))p.relatedInformation=u;return p}e.create=t;function n(s){var o;let a=s;return oe.defined(a)&&ir.is(a.range)&&(oe.string(a.message)||lp.is(a.message))&&(oe.number(a.severity)||oe.undefined(a.severity))&&(oe.integer(a.code)||oe.string(a.code)||oe.undefined(a.code))&&(oe.undefined(a.codeDescription)||oe.string((o=a.codeDescription)===null||o===void 0?void 0:o.href))&&(oe.string(a.source)||oe.undefined(a.source))&&(oe.undefined(a.relatedInformation)||oe.typedArray(a.relatedInformation,uT.is))}e.is=n;function r(s){return oe.string(s.message)}e.is3_17=r;function i(s){if(oe.string(s.message))return s.message;else if(lp.is(s.message))return s.message.value;else throw Error(`Unknown message type ${typeof s.message}`)}e.getMessageString=i})(Wb||(Wb={}));(function(e){function t(r,i,...s){let o={title:r,command:i};if(oe.defined(s)&&s.length>0)o.arguments=s;return o}e.create=t;function n(r){let i=r;return oe.defined(i)&&oe.string(i.title)&&(i.tooltip===void 0||oe.string(i.tooltip))&&oe.string(i.command)}e.is=n})(Zd||(Zd={}));(function(e){function t(s,o){return{range:s,newText:o}}e.replace=t;function n(s,o){return{range:{start:s,end:s},newText:o}}e.insert=n;function r(s){return{range:s,newText:""}}e.del=r;function i(s){let o=s;return oe.objectLiteral(o)&&oe.string(o.newText)&&ir.is(o.range)}e.is=i})(xl||(xl={}));(function(e){function t(r,i,s){let o={label:r};if(i!==void 0)o.needsConfirmation=i;if(s!==void 0)o.description=s;return o}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&oe.string(i.label)&&(oe.boolean(i.needsConfirmation)||i.needsConfirmation===void 0)&&(oe.string(i.description)||i.description===void 0)}e.is=n})(op||(op={}));(function(e){function t(n){let r=n;return oe.string(r)}e.is=t})(ti||(ti={}));(function(e){function t(s,o,a){return{range:s,newText:o,annotationId:a}}e.replace=t;function n(s,o,a){return{range:{start:s,end:s},newText:o,annotationId:a}}e.insert=n;function r(s,o){return{range:s,newText:"",annotationId:o}}e.del=r;function i(s){let o=s;return xl.is(o)&&(op.is(o.annotationId)||ti.is(o.annotationId))}e.is=i})(Sc||(Sc={}));(function(e){function t(r,i){return{textDocument:r,edits:i}}e.create=t;function n(r){let i=r;return oe.defined(i)&&Yb.is(i.textDocument)&&Array.isArray(i.edits)}e.is=n})(Qb||(Qb={}));(function(e){function t(r,i,s){let o={kind:"create",uri:r};if(i!==void 0&&(i.overwrite!==void 0||i.ignoreIfExists!==void 0))o.options=i;if(s!==void 0)o.annotationId=s;return o}e.create=t;function n(r){let i=r;return i&&i.kind==="create"&&oe.string(i.uri)&&(i.options===void 0||(i.options.overwrite===void 0||oe.boolean(i.options.overwrite))&&(i.options.ignoreIfExists===void 0||oe.boolean(i.options.ignoreIfExists)))&&(i.annotationId===void 0||ti.is(i.annotationId))}e.is=n})(hy||(hy={}));(function(e){function t(r,i,s,o){let a={kind:"rename",oldUri:r,newUri:i};if(s!==void 0&&(s.overwrite!==void 0||s.ignoreIfExists!==void 0))a.options=s;if(o!==void 0)a.annotationId=o;return a}e.create=t;function n(r){let i=r;return i&&i.kind==="rename"&&oe.string(i.oldUri)&&oe.string(i.newUri)&&(i.options===void 0||(i.options.overwrite===void 0||oe.boolean(i.options.overwrite))&&(i.options.ignoreIfExists===void 0||oe.boolean(i.options.ignoreIfExists)))&&(i.annotationId===void 0||ti.is(i.annotationId))}e.is=n})(gy||(gy={}));(function(e){function t(r,i,s){let o={kind:"delete",uri:r};if(i!==void 0&&(i.recursive!==void 0||i.ignoreIfNotExists!==void 0))o.options=i;if(s!==void 0)o.annotationId=s;return o}e.create=t;function n(r){let i=r;return i&&i.kind==="delete"&&oe.string(i.uri)&&(i.options===void 0||(i.options.recursive===void 0||oe.boolean(i.options.recursive))&&(i.options.ignoreIfNotExists===void 0||oe.boolean(i.options.ignoreIfNotExists)))&&(i.annotationId===void 0||ti.is(i.annotationId))}e.is=n})(by||(by={}));(function(e){function t(n){let r=n;return r&&(r.changes!==void 0||r.documentChanges!==void 0)&&(r.documentChanges===void 0||r.documentChanges.every((i)=>{if(oe.string(i.kind))return hy.is(i)||gy.is(i)||by.is(i);else return Qb.is(i)}))}e.is=t})(pT||(pT={}));(function(e){function t(n){let r=n;return oe.objectLiteral(r)&&ir.is(r.range)&&hT.isSnippet(r.snippet)&&(r.annotationId===void 0||(op.is(r.annotationId)||ti.is(r.annotationId)))}e.is=t})(II||(II={}));(function(e){function t(r){return{uri:r}}e.create=t;function n(r){let i=r;return oe.defined(i)&&oe.string(i.uri)}e.is=n})(RI||(RI={}));(function(e){function t(r,i){return{uri:r,version:i}}e.create=t;function n(r){let i=r;return oe.defined(i)&&oe.string(i.uri)&&oe.integer(i.version)}e.is=n})(jI||(jI={}));(function(e){function t(r,i){return{uri:r,version:i}}e.create=t;function n(r){let i=r;return oe.defined(i)&&oe.string(i.uri)&&(i.version===null||oe.integer(i.version))}e.is=n})(Yb||(Yb={}));(function(e){e.ABAP="abap",e.WindowsBat="bat",e.BibTeX="bibtex",e.Clojure="clojure",e.Coffeescript="coffeescript",e.C="c",e.CPP="cpp",e.CSharp="csharp",e.CSS="css",e.D="d",e.Delphi="pascal",e.Diff="diff",e.Dart="dart",e.Dockerfile="dockerfile",e.Elixir="elixir",e.Erlang="erlang",e.FSharp="fsharp",e.GitCommit="git-commit",e.GitRebase="git-rebase",e.Go="go",e.Groovy="groovy",e.Handlebars="handlebars",e.Haskell="haskell",e.HTML="html",e.Ini="ini",e.Java="java",e.JavaScript="javascript",e.JavaScriptReact="javascriptreact",e.JSON="json",e.LaTeX="latex",e.Less="less",e.Lua="lua",e.Makefile="makefile",e.Markdown="markdown",e.ObjectiveC="objective-c",e.ObjectiveCPP="objective-cpp",e.Pascal="pascal",e.Perl="perl",e.Perl6="perl6",e.PHP="php",e.Plaintext="plaintext",e.Powershell="powershell",e.Pug="jade",e.Python="python",e.R="r",e.Razor="razor",e.Ruby="ruby",e.Rust="rust",e.SCSS="scss",e.SASS="sass",e.Scala="scala",e.ShaderLab="shaderlab",e.ShellScript="shellscript",e.SQL="sql",e.Swift="swift",e.TypeScript="typescript",e.TypeScriptReact="typescriptreact",e.TeX="tex",e.VisualBasic="vb",e.XML="xml",e.XSL="xsl",e.YAML="yaml"})(FI||(FI={}));(function(e){function t(r,i,s,o){return{uri:r,languageId:i,version:s,text:o}}e.create=t;function n(r){let i=r;return oe.defined(i)&&oe.string(i.uri)&&oe.string(i.languageId)&&oe.integer(i.version)&&oe.string(i.text)}e.is=n})(CI||(CI={}));(function(e){e.PlainText="plaintext",e.Markdown="markdown";function t(n){let r=n;return r===e.PlainText||r===e.Markdown}e.is=t})(dT||(dT={}));(function(e){function t(n){let r=n;return oe.objectLiteral(n)&&dT.is(r.kind)&&oe.string(r.value)}e.is=t})(lp||(lp={}));(function(e){e.Text=1,e.Method=2,e.Function=3,e.Constructor=4,e.Field=5,e.Variable=6,e.Class=7,e.Interface=8,e.Module=9,e.Property=10,e.Unit=11,e.Value=12,e.Enum=13,e.Keyword=14,e.Snippet=15,e.Color=16,e.File=17,e.Reference=18,e.Folder=19,e.EnumMember=20,e.Constant=21,e.Struct=22,e.Event=23,e.Operator=24,e.TypeParameter=25})(MI||(MI={}));(function(e){e.PlainText=1,e.Snippet=2})(LI||(LI={}));(function(e){e.Deprecated=1})(qI||(qI={}));(function(e){function t(r,i,s){return{newText:r,insert:i,replace:s}}e.create=t;function n(r){let i=r;return i&&oe.string(i.newText)&&ir.is(i.insert)&&ir.is(i.replace)}e.is=n})(UI||(UI={}));(function(e){e.asIs=1,e.adjustIndentation=2})(BI||(BI={}));(function(e){e.Replace=1,e.Merge=2})(VI||(VI={}));(function(e){function t(n){let r=n;return r&&(oe.string(r.detail)||r.detail===void 0)&&(oe.string(r.description)||r.description===void 0)}e.is=t})(KI||(KI={}));(function(e){function t(n){return{label:n}}e.create=t})(JI||(JI={}));(function(e){function t(n,r){return{items:n?n:[],isIncomplete:!!r}}e.create=t})(GI||(GI={}));(function(e){function t(r){return r.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}e.fromPlainText=t;function n(r){let i=r;return oe.string(i)||oe.objectLiteral(i)&&oe.string(i.language)&&oe.string(i.value)}e.is=n})(Xb||(Xb={}));(function(e){function t(n){let r=n;return!!r&&oe.objectLiteral(r)&&(lp.is(r.contents)||Xb.is(r.contents)||oe.typedArray(r.contents,Xb.is))&&(n.range===void 0||ir.is(n.range))}e.is=t})(HI||(HI={}));(function(e){function t(n,r){return r?{label:n,documentation:r}:{label:n}}e.create=t})(zI||(zI={}));(function(e){function t(n,r,...i){let s={label:n};if(oe.defined(r))s.documentation=r;if(oe.defined(i))s.parameters=i;else s.parameters=[];return s}e.create=t})(WI||(WI={}));(function(e){e.Text=1,e.Read=2,e.Write=3})(QI||(QI={}));(function(e){function t(n,r){let i={range:n};if(oe.number(r))i.kind=r;return i}e.create=t})(YI||(YI={}));(function(e){e.File=1,e.Module=2,e.Namespace=3,e.Package=4,e.Class=5,e.Method=6,e.Property=7,e.Field=8,e.Constructor=9,e.Enum=10,e.Interface=11,e.Function=12,e.Variable=13,e.Constant=14,e.String=15,e.Number=16,e.Boolean=17,e.Array=18,e.Object=19,e.Key=20,e.Null=21,e.EnumMember=22,e.Struct=23,e.Event=24,e.Operator=25,e.TypeParameter=26})(XI||(XI={}));(function(e){e.Deprecated=1})(ZI||(ZI={}));(function(e){function t(n,r,i,s,o){let a={name:n,kind:r,location:{uri:s,range:i}};if(o)a.containerName=o;return a}e.create=t})(eA||(eA={}));(function(e){function t(n,r,i,s){return s!==void 0?{name:n,kind:r,location:{uri:i,range:s}}:{name:n,kind:r,location:{uri:i}}}e.create=t})(tA||(tA={}));(function(e){function t(r,i,s,o,a,l){let c={name:r,detail:i,kind:s,range:o,selectionRange:a};if(l!==void 0)c.children=l;return c}e.create=t;function n(r){let i=r;return i&&oe.string(i.name)&&oe.number(i.kind)&&ir.is(i.range)&&ir.is(i.selectionRange)&&(i.detail===void 0||oe.string(i.detail))&&(i.deprecated===void 0||oe.boolean(i.deprecated))&&(i.children===void 0||Array.isArray(i.children))&&(i.tags===void 0||Array.isArray(i.tags))}e.is=n})(nA||(nA={}));(function(e){e.Empty="",e.QuickFix="quickfix",e.Refactor="refactor",e.RefactorExtract="refactor.extract",e.RefactorInline="refactor.inline",e.RefactorMove="refactor.move",e.RefactorRewrite="refactor.rewrite",e.Source="source",e.SourceOrganizeImports="source.organizeImports",e.SourceFixAll="source.fixAll",e.Notebook="notebook"})(rA||(rA={}));(function(e){e.Invoked=1,e.Automatic=2})(Zb||(Zb={}));(function(e){function t(r,i,s){let o={diagnostics:r};if(i!==void 0&&i!==null)o.only=i;if(s!==void 0&&s!==null)o.triggerKind=s;return o}e.create=t;function n(r){let i=r;return oe.defined(i)&&oe.typedArray(i.diagnostics,Wb.is)&&(i.only===void 0||oe.typedArray(i.only,oe.string))&&(i.triggerKind===void 0||i.triggerKind===Zb.Invoked||i.triggerKind===Zb.Automatic)}e.is=n})(iA||(iA={}));(function(e){e.LLMGenerated=1;function t(n){return oe.defined(n)&&n===e.LLMGenerated}e.is=t})(fT||(fT={}));(function(e){function t(r,i,s){let o={title:r},a=!0;if(typeof i==="string")a=!1,o.kind=i;else if(Zd.is(i))o.command=i;else o.edit=i;if(a&&s!==void 0)o.kind=s;return o}e.create=t;function n(r){let i=r;return i&&oe.string(i.title)&&(i.diagnostics===void 0||oe.typedArray(i.diagnostics,Wb.is))&&(i.kind===void 0||oe.string(i.kind))&&(i.edit!==void 0||i.command!==void 0)&&(i.command===void 0||Zd.is(i.command))&&(i.isPreferred===void 0||oe.boolean(i.isPreferred))&&(i.edit===void 0||pT.is(i.edit))&&(i.tags===void 0||oe.typedArray(i.tags,fT.is))}e.is=n})(sA||(sA={}));(function(e){function t(r,i){let s={range:r};if(oe.defined(i))s.data=i;return s}e.create=t;function n(r){let i=r;return oe.defined(i)&&ir.is(i.range)&&(oe.undefined(i.command)||Zd.is(i.command))}e.is=n})(oA||(oA={}));(function(e){function t(r,i){return{tabSize:r,insertSpaces:i}}e.create=t;function n(r){let i=r;return oe.defined(i)&&oe.uinteger(i.tabSize)&&oe.boolean(i.insertSpaces)}e.is=n})(aA||(aA={}));(function(e){function t(r,i,s){return{range:r,target:i,data:s}}e.create=t;function n(r){let i=r;return oe.defined(i)&&ir.is(i.range)&&(oe.undefined(i.target)||oe.string(i.target))}e.is=n})(lA||(lA={}));(function(e){function t(r,i){return{range:r,parent:i}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&ir.is(i.range)&&(i.parent===void 0||e.is(i.parent))}e.is=n})(cA||(cA={}));(function(e){e.namespace="namespace",e.type="type",e.class="class",e.enum="enum",e.interface="interface",e.struct="struct",e.typeParameter="typeParameter",e.parameter="parameter",e.variable="variable",e.property="property",e.enumMember="enumMember",e.event="event",e.function="function",e.method="method",e.macro="macro",e.keyword="keyword",e.modifier="modifier",e.comment="comment",e.string="string",e.number="number",e.regexp="regexp",e.operator="operator",e.decorator="decorator",e.label="label"})(uA||(uA={}));(function(e){e.declaration="declaration",e.definition="definition",e.readonly="readonly",e.static="static",e.deprecated="deprecated",e.abstract="abstract",e.async="async",e.modification="modification",e.documentation="documentation",e.defaultLibrary="defaultLibrary"})(pA||(pA={}));(function(e){function t(n){let r=n;return oe.objectLiteral(r)&&(r.resultId===void 0||typeof r.resultId==="string")&&Array.isArray(r.data)&&(r.data.length===0||typeof r.data[0]==="number")}e.is=t})(dA||(dA={}));(function(e){function t(r,i){return{range:r,text:i}}e.create=t;function n(r){let i=r;return i!==void 0&&i!==null&&ir.is(i.range)&&oe.string(i.text)}e.is=n})(fA||(fA={}));(function(e){function t(r,i,s){return{range:r,variableName:i,caseSensitiveLookup:s}}e.create=t;function n(r){let i=r;return i!==void 0&&i!==null&&ir.is(i.range)&&oe.boolean(i.caseSensitiveLookup)&&(oe.string(i.variableName)||i.variableName===void 0)}e.is=n})(mA||(mA={}));(function(e){function t(r,i){return{range:r,expression:i}}e.create=t;function n(r){let i=r;return i!==void 0&&i!==null&&ir.is(i.range)&&(oe.string(i.expression)||i.expression===void 0)}e.is=n})(yA||(yA={}));(function(e){function t(r,i){return{frameId:r,stoppedLocation:i}}e.create=t;function n(r){let i=r;return oe.defined(i)&&ir.is(r.stoppedLocation)}e.is=n})(hA||(hA={}));(function(e){e.Type=1,e.Parameter=2;function t(n){return n===1||n===2}e.is=t})(mT||(mT={}));(function(e){function t(r){return{value:r}}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&(i.tooltip===void 0||oe.string(i.tooltip)||lp.is(i.tooltip))&&(i.location===void 0||zb.is(i.location))&&(i.command===void 0||Zd.is(i.command))}e.is=n})(yT||(yT={}));(function(e){function t(r,i,s){let o={position:r,label:i};if(s!==void 0)o.kind=s;return o}e.create=t;function n(r){let i=r;return oe.objectLiteral(i)&&zo.is(i.position)&&(oe.string(i.label)||oe.typedArray(i.label,yT.is))&&(i.kind===void 0||mT.is(i.kind))&&i.textEdits===void 0||oe.typedArray(i.textEdits,xl.is)&&(i.tooltip===void 0||oe.string(i.tooltip)||lp.is(i.tooltip))&&(i.paddingLeft===void 0||oe.boolean(i.paddingLeft))&&(i.paddingRight===void 0||oe.boolean(i.paddingRight))}e.is=n})(gA||(gA={}));(function(e){function t(r){return{kind:"snippet",value:r}}e.createSnippet=t;function n(r){let i=r;return oe.objectLiteral(i)&&i.kind==="snippet"&&oe.string(i.value)}e.isSnippet=n})(hT||(hT={}));(function(e){function t(n,r,i,s){return{insertText:n,filterText:r,range:i,command:s}}e.create=t})(bA||(bA={}));(function(e){function t(n){return{items:n}}e.create=t})(vA||(vA={}));(function(e){e.Invoked=1,e.Automatic=2})(_A||(_A={}));(function(e){function t(n,r){return{range:n,text:r}}e.create=t})(xA||(xA={}));(function(e){function t(n,r){return{triggerKind:n,selectedCompletionInfo:r}}e.create=t})(wA||(wA={}));(function(e){function t(n){let r=n;return oe.objectLiteral(r)&&Hb.is(r.uri)&&oe.string(r.name)}e.is=t})(gT||(gT={}));EIe=[` `,`\r -`,"\r"];(function(e){function t(s,o,a,l){return new lH(s,o,a,l)}e.create=t;function n(s){let o=s;return oe.defined(o)&&oe.string(o.uri)&&(oe.undefined(o.languageId)||oe.string(o.languageId))&&oe.uinteger(o.lineCount)&&oe.func(o.getText)&&oe.func(o.positionAt)&&oe.func(o.offsetAt)?!0:!1}e.is=n;function r(s,o){let a=s.getText(),l=i(o,(u,p)=>{let d=u.range.start.line-p.range.start.line;if(d===0)return u.range.start.character-p.range.start.character;return d}),c=a.length;for(let u=l.length-1;u>=0;u--){let p=l[u],d=s.offsetAt(p.range.start),f=s.offsetAt(p.range.end);if(f<=c)a=a.substring(0,d)+p.newText+a.substring(f,a.length);else throw Error("Overlapping edit");c=d}return a}e.applyEdits=r;function i(s,o){if(s.length<=1)return s;let a=s.length/2|0,l=s.slice(0,a),c=s.slice(a);i(l,o),i(c,o);let u=0,p=0,d=0;while(u"u"}e.undefined=r;function i(f){return f===!0||f===!1}e.boolean=i;function s(f){return t.call(f)==="[object String]"}e.string=s;function o(f){return t.call(f)==="[object Number]"}e.number=o;function a(f,m,y){return t.call(f)==="[object Number]"&&m<=f&&f<=y}e.numberRange=a;function l(f){return t.call(f)==="[object Number]"&&-2147483648<=f&&f<=2147483647}e.integer=l;function c(f){return t.call(f)==="[object Number]"&&0<=f&&f<=2147483647}e.uinteger=c;function u(f){return t.call(f)==="[object Function]"}e.func=u;function p(f){return f!==null&&typeof f==="object"}e.objectLiteral=p;function d(f,m){return Array.isArray(f)&&f.every(m)}e.typedArray=d})(oe||(oe={}))});var Hn=z(function(gH){Object.defineProperty(gH,"__esModule",{value:!0});gH.CM=gH.ProtocolNotificationType=gH.ProtocolNotificationType0=gH.ProtocolRequestType=gH.ProtocolRequestType0=gH.RegistrationType=gH.MessageDirection=void 0;var gy=fy(),uH;(function(e){e.clientToServer="clientToServer",e.serverToClient="serverToClient",e.both="both"})(uH||(gH.MessageDirection=uH={}));class dH{____;method;constructor(e){this.method=e}}gH.RegistrationType=dH;class fH extends gy.RequestType0{__;___;____;_pr;constructor(e){super(e)}}gH.ProtocolRequestType0=fH;class mH extends gy.RequestType{__;___;____;_pr;constructor(e){super(e,gy.ParameterStructures.byName)}}gH.ProtocolRequestType=mH;class yH extends gy.NotificationType0{___;____;constructor(e){super(e)}}gH.ProtocolNotificationType0=yH;class hH extends gy.NotificationType{___;____;constructor(e){super(e,gy.ParameterStructures.byName)}}gH.ProtocolNotificationType=hH;var pH;(function(e){function t(n,r){return{client:n,server:r}}e.create=t})(pH||(gH.CM=pH={}))});var vT=z(function(xH){Object.defineProperty(xH,"__esModule",{value:!0});xH.boolean=IIe;xH.string=vH;xH.number=AIe;xH.error=RIe;xH.func=jIe;xH.array=_H;xH.stringArray=FIe;xH.typedArray=CIe;xH.objectLiteral=MIe;function IIe(e){return e===!0||e===!1}function vH(e){return typeof e==="string"||e instanceof String}function AIe(e){return typeof e==="number"||e instanceof Number}function RIe(e){return e instanceof Error}function jIe(e){return typeof e==="function"}function _H(e){return Array.isArray(e)}function FIe(e){return _H(e)&&e.every((t)=>vH(t))}function CIe(e,t){return Array.isArray(e)&&e.every(t)}function MIe(e){return e!==null&&typeof e==="object"}});var SH=z(function(DH){Object.defineProperty(DH,"__esModule",{value:!0});DH.ImplementationRequest=void 0;var TA=Hn(),wH;(function(e){e.method="textDocument/implementation",e.messageDirection=TA.MessageDirection.clientToServer,e.type=new TA.ProtocolRequestType(e.method),e.capabilities=TA.CM.create("textDocument.implementation","implementationProvider")})(wH||(DH.ImplementationRequest=wH={}))});var OH=z(function(kH){Object.defineProperty(kH,"__esModule",{value:!0});kH.TypeDefinitionRequest=void 0;var SA=Hn(),EH;(function(e){e.method="textDocument/typeDefinition",e.messageDirection=SA.MessageDirection.clientToServer,e.type=new SA.ProtocolRequestType(e.method),e.capabilities=SA.CM.create("textDocument.typeDefinition","typeDefinitionProvider")})(EH||(kH.TypeDefinitionRequest=EH={}))});var RH=z(function(IH){Object.defineProperty(IH,"__esModule",{value:!0});IH.DidChangeWorkspaceFoldersNotification=IH.WorkspaceFoldersRequest=void 0;var by=Hn(),PH;(function(e){e.method="workspace/workspaceFolders",e.messageDirection=by.MessageDirection.serverToClient,e.type=new by.ProtocolRequestType0(e.method),e.capabilities=by.CM.create("workspace.workspaceFolders","workspace.workspaceFolders")})(PH||(IH.WorkspaceFoldersRequest=PH={}));var $H;(function(e){e.method="workspace/didChangeWorkspaceFolders",e.messageDirection=by.MessageDirection.clientToServer,e.type=new by.ProtocolNotificationType(e.method),e.capabilities=by.CM.create(void 0,"workspace.workspaceFolders.changeNotifications")})($H||(IH.DidChangeWorkspaceFoldersNotification=$H={}))});var MH=z(function(FH){Object.defineProperty(FH,"__esModule",{value:!0});FH.ConfigurationRequest=void 0;var EA=Hn(),jH;(function(e){e.method="workspace/configuration",e.messageDirection=EA.MessageDirection.serverToClient,e.type=new EA.ProtocolRequestType(e.method),e.capabilities=EA.CM.create("workspace.configuration",void 0)})(jH||(FH.ConfigurationRequest=jH={}))});var VH=z(function(UH){Object.defineProperty(UH,"__esModule",{value:!0});UH.ColorPresentationRequest=UH.DocumentColorRequest=void 0;var vy=Hn(),LH;(function(e){e.method="textDocument/documentColor",e.messageDirection=vy.MessageDirection.clientToServer,e.type=new vy.ProtocolRequestType(e.method),e.capabilities=vy.CM.create("textDocument.colorProvider","colorProvider")})(LH||(UH.DocumentColorRequest=LH={}));var qH;(function(e){e.method="textDocument/colorPresentation",e.messageDirection=vy.MessageDirection.clientToServer,e.type=new vy.ProtocolRequestType(e.method),e.capabilities=vy.CM.create("textDocument.colorProvider","colorProvider")})(qH||(UH.ColorPresentationRequest=qH={}))});var zH=z(function(GH){Object.defineProperty(GH,"__esModule",{value:!0});GH.FoldingRangeRefreshRequest=GH.FoldingRangeRequest=void 0;var _y=Hn(),KH;(function(e){e.method="textDocument/foldingRange",e.messageDirection=_y.MessageDirection.clientToServer,e.type=new _y.ProtocolRequestType(e.method),e.capabilities=_y.CM.create("textDocument.foldingRange","foldingRangeProvider")})(KH||(GH.FoldingRangeRequest=KH={}));var JH;(function(e){e.method="workspace/foldingRange/refresh",e.messageDirection=_y.MessageDirection.serverToClient,e.type=new _y.ProtocolRequestType0(e.method),e.capabilities=_y.CM.create("workspace.foldingRange.refreshSupport",void 0)})(JH||(GH.FoldingRangeRefreshRequest=JH={}))});var XH=z(function(QH){Object.defineProperty(QH,"__esModule",{value:!0});QH.DeclarationRequest=void 0;var kA=Hn(),WH;(function(e){e.method="textDocument/declaration",e.messageDirection=kA.MessageDirection.clientToServer,e.type=new kA.ProtocolRequestType(e.method),e.capabilities=kA.CM.create("textDocument.declaration","declarationProvider")})(WH||(QH.DeclarationRequest=WH={}))});var nz=z(function(ez){Object.defineProperty(ez,"__esModule",{value:!0});ez.SelectionRangeRequest=void 0;var NA=Hn(),ZH;(function(e){e.method="textDocument/selectionRange",e.messageDirection=NA.MessageDirection.clientToServer,e.type=new NA.ProtocolRequestType(e.method),e.capabilities=NA.CM.create("textDocument.selectionRange","selectionRangeProvider")})(ZH||(ez.SelectionRangeRequest=ZH={}))});var lz=z(function(oz){Object.defineProperty(oz,"__esModule",{value:!0});oz.WorkDoneProgressCancelNotification=oz.WorkDoneProgressCreateRequest=oz.WorkDoneProgress=void 0;var YIe=fy(),ev=Hn(),rz;(function(e){e.type=new YIe.ProgressType;function t(n){return n===e.type}e.is=t})(rz||(oz.WorkDoneProgress=rz={}));var iz;(function(e){e.method="window/workDoneProgress/create",e.messageDirection=ev.MessageDirection.serverToClient,e.type=new ev.ProtocolRequestType(e.method),e.capabilities=ev.CM.create("window.workDoneProgress",void 0)})(iz||(oz.WorkDoneProgressCreateRequest=iz={}));var sz;(function(e){e.method="window/workDoneProgress/cancel",e.messageDirection=ev.MessageDirection.clientToServer,e.type=new ev.ProtocolNotificationType(e.method)})(sz||(oz.WorkDoneProgressCancelNotification=sz={}))});var mz=z(function(dz){Object.defineProperty(dz,"__esModule",{value:!0});dz.CallHierarchyOutgoingCallsRequest=dz.CallHierarchyIncomingCallsRequest=dz.CallHierarchyPrepareRequest=void 0;var Ec=Hn(),cz;(function(e){e.method="textDocument/prepareCallHierarchy",e.messageDirection=Ec.MessageDirection.clientToServer,e.type=new Ec.ProtocolRequestType(e.method),e.capabilities=Ec.CM.create("textDocument.callHierarchy","callHierarchyProvider")})(cz||(dz.CallHierarchyPrepareRequest=cz={}));var uz;(function(e){e.method="callHierarchy/incomingCalls",e.messageDirection=Ec.MessageDirection.clientToServer,e.type=new Ec.ProtocolRequestType(e.method),e.capabilities=Ec.CM.create("textDocument.callHierarchy","callHierarchyProvider")})(uz||(dz.CallHierarchyIncomingCallsRequest=uz={}));var pz;(function(e){e.method="callHierarchy/outgoingCalls",e.messageDirection=Ec.MessageDirection.clientToServer,e.type=new Ec.ProtocolRequestType(e.method),e.capabilities=Ec.CM.create("textDocument.callHierarchy","callHierarchyProvider")})(pz||(dz.CallHierarchyOutgoingCallsRequest=pz={}))});var wz=z(function(_z){Object.defineProperty(_z,"__esModule",{value:!0});_z.SemanticTokensRefreshRequest=_z.SemanticTokensRangeRequest=_z.SemanticTokensDeltaRequest=_z.SemanticTokensRequest=_z.SemanticTokensRegistrationType=_z.TokenFormat=void 0;var ro=Hn(),yz;(function(e){e.Relative="relative"})(yz||(_z.TokenFormat=yz={}));var tv;(function(e){e.method="textDocument/semanticTokens",e.type=new ro.RegistrationType(e.method)})(tv||(_z.SemanticTokensRegistrationType=tv={}));var hz;(function(e){e.method="textDocument/semanticTokens/full",e.messageDirection=ro.MessageDirection.clientToServer,e.type=new ro.ProtocolRequestType(e.method),e.registrationMethod=tv.method,e.capabilities=ro.CM.create("textDocument.semanticTokens","semanticTokensProvider")})(hz||(_z.SemanticTokensRequest=hz={}));var gz;(function(e){e.method="textDocument/semanticTokens/full/delta",e.messageDirection=ro.MessageDirection.clientToServer,e.type=new ro.ProtocolRequestType(e.method),e.registrationMethod=tv.method,e.capabilities=ro.CM.create("textDocument.semanticTokens.requests.full.delta","semanticTokensProvider.full.delta")})(gz||(_z.SemanticTokensDeltaRequest=gz={}));var bz;(function(e){e.method="textDocument/semanticTokens/range",e.messageDirection=ro.MessageDirection.clientToServer,e.type=new ro.ProtocolRequestType(e.method),e.registrationMethod=tv.method,e.capabilities=ro.CM.create("textDocument.semanticTokens.requests.range","semanticTokensProvider.range")})(bz||(_z.SemanticTokensRangeRequest=bz={}));var vz;(function(e){e.method="workspace/semanticTokens/refresh",e.messageDirection=ro.MessageDirection.serverToClient,e.type=new ro.ProtocolRequestType0(e.method),e.capabilities=ro.CM.create("workspace.semanticTokens.refreshSupport",void 0)})(vz||(_z.SemanticTokensRefreshRequest=vz={}))});var Ez=z(function(Tz){Object.defineProperty(Tz,"__esModule",{value:!0});Tz.ShowDocumentRequest=void 0;var OA=Hn(),Dz;(function(e){e.method="window/showDocument",e.messageDirection=OA.MessageDirection.serverToClient,e.type=new OA.ProtocolRequestType(e.method),e.capabilities=OA.CM.create("window.showDocument.support",void 0)})(Dz||(Tz.ShowDocumentRequest=Dz={}))});var Pz=z(function(Nz){Object.defineProperty(Nz,"__esModule",{value:!0});Nz.LinkedEditingRangeRequest=void 0;var PA=Hn(),kz;(function(e){e.method="textDocument/linkedEditingRange",e.messageDirection=PA.MessageDirection.clientToServer,e.type=new PA.ProtocolRequestType(e.method),e.capabilities=PA.CM.create("textDocument.linkedEditingRange","linkedEditingRangeProvider")})(kz||(Nz.LinkedEditingRangeRequest=kz={}))});var qz=z(function(Mz){Object.defineProperty(Mz,"__esModule",{value:!0});Mz.WillDeleteFilesRequest=Mz.DidDeleteFilesNotification=Mz.DidRenameFilesNotification=Mz.WillRenameFilesRequest=Mz.DidCreateFilesNotification=Mz.WillCreateFilesRequest=Mz.FileOperationPatternKind=void 0;var ti=Hn(),$z;(function(e){e.file="file",e.folder="folder"})($z||(Mz.FileOperationPatternKind=$z={}));var Iz;(function(e){e.method="workspace/willCreateFiles",e.messageDirection=ti.MessageDirection.clientToServer,e.type=new ti.ProtocolRequestType(e.method),e.capabilities=ti.CM.create("workspace.fileOperations.willCreate","workspace.fileOperations.willCreate")})(Iz||(Mz.WillCreateFilesRequest=Iz={}));var Az;(function(e){e.method="workspace/didCreateFiles",e.messageDirection=ti.MessageDirection.clientToServer,e.type=new ti.ProtocolNotificationType(e.method),e.capabilities=ti.CM.create("workspace.fileOperations.didCreate","workspace.fileOperations.didCreate")})(Az||(Mz.DidCreateFilesNotification=Az={}));var Rz;(function(e){e.method="workspace/willRenameFiles",e.messageDirection=ti.MessageDirection.clientToServer,e.type=new ti.ProtocolRequestType(e.method),e.capabilities=ti.CM.create("workspace.fileOperations.willRename","workspace.fileOperations.willRename")})(Rz||(Mz.WillRenameFilesRequest=Rz={}));var jz;(function(e){e.method="workspace/didRenameFiles",e.messageDirection=ti.MessageDirection.clientToServer,e.type=new ti.ProtocolNotificationType(e.method),e.capabilities=ti.CM.create("workspace.fileOperations.didRename","workspace.fileOperations.didRename")})(jz||(Mz.DidRenameFilesNotification=jz={}));var Fz;(function(e){e.method="workspace/didDeleteFiles",e.messageDirection=ti.MessageDirection.clientToServer,e.type=new ti.ProtocolNotificationType(e.method),e.capabilities=ti.CM.create("workspace.fileOperations.didDelete","workspace.fileOperations.didDelete")})(Fz||(Mz.DidDeleteFilesNotification=Fz={}));var Cz;(function(e){e.method="workspace/willDeleteFiles",e.messageDirection=ti.MessageDirection.clientToServer,e.type=new ti.ProtocolRequestType(e.method),e.capabilities=ti.CM.create("workspace.fileOperations.willDelete","workspace.fileOperations.willDelete")})(Cz||(Mz.WillDeleteFilesRequest=Cz={}))});var Gz=z(function(Kz){Object.defineProperty(Kz,"__esModule",{value:!0});Kz.MonikerRequest=Kz.MonikerKind=Kz.UniquenessLevel=void 0;var $A=Hn(),Uz;(function(e){e.document="document",e.project="project",e.group="group",e.scheme="scheme",e.global="global"})(Uz||(Kz.UniquenessLevel=Uz={}));var Bz;(function(e){e.$import="import",e.$export="export",e.local="local"})(Bz||(Kz.MonikerKind=Bz={}));var Vz;(function(e){e.method="textDocument/moniker",e.messageDirection=$A.MessageDirection.clientToServer,e.type=new $A.ProtocolRequestType(e.method),e.capabilities=$A.CM.create("textDocument.moniker","monikerProvider")})(Vz||(Kz.MonikerRequest=Vz={}))});var Xz=z(function(Qz){Object.defineProperty(Qz,"__esModule",{value:!0});Qz.TypeHierarchySubtypesRequest=Qz.TypeHierarchySupertypesRequest=Qz.TypeHierarchyPrepareRequest=void 0;var Xd=Hn(),Hz;(function(e){e.method="textDocument/prepareTypeHierarchy",e.messageDirection=Xd.MessageDirection.clientToServer,e.type=new Xd.ProtocolRequestType(e.method),e.capabilities=Xd.CM.create("textDocument.typeHierarchy","typeHierarchyProvider")})(Hz||(Qz.TypeHierarchyPrepareRequest=Hz={}));var zz;(function(e){e.method="typeHierarchy/supertypes",e.messageDirection=Xd.MessageDirection.clientToServer,e.type=new Xd.ProtocolRequestType(e.method)})(zz||(Qz.TypeHierarchySupertypesRequest=zz={}));var Wz;(function(e){e.method="typeHierarchy/subtypes",e.messageDirection=Xd.MessageDirection.clientToServer,e.type=new Xd.ProtocolRequestType(e.method)})(Wz||(Qz.TypeHierarchySubtypesRequest=Wz={}))});var rW=z(function(tW){Object.defineProperty(tW,"__esModule",{value:!0});tW.InlineValueRefreshRequest=tW.InlineValueRequest=void 0;var xy=Hn(),Zz;(function(e){e.method="textDocument/inlineValue",e.messageDirection=xy.MessageDirection.clientToServer,e.type=new xy.ProtocolRequestType(e.method),e.capabilities=xy.CM.create("textDocument.inlineValue","inlineValueProvider")})(Zz||(tW.InlineValueRequest=Zz={}));var eW;(function(e){e.method="workspace/inlineValue/refresh",e.messageDirection=xy.MessageDirection.serverToClient,e.type=new xy.ProtocolRequestType0(e.method),e.capabilities=xy.CM.create("workspace.inlineValue.refreshSupport",void 0)})(eW||(tW.InlineValueRefreshRequest=eW={}))});var cW=z(function(aW){Object.defineProperty(aW,"__esModule",{value:!0});aW.InlayHintRefreshRequest=aW.InlayHintResolveRequest=aW.InlayHintRequest=void 0;var kc=Hn(),iW;(function(e){e.method="textDocument/inlayHint",e.messageDirection=kc.MessageDirection.clientToServer,e.type=new kc.ProtocolRequestType(e.method),e.capabilities=kc.CM.create("textDocument.inlayHint","inlayHintProvider")})(iW||(aW.InlayHintRequest=iW={}));var sW;(function(e){e.method="inlayHint/resolve",e.messageDirection=kc.MessageDirection.clientToServer,e.type=new kc.ProtocolRequestType(e.method),e.capabilities=kc.CM.create("textDocument.inlayHint.resolveSupport","inlayHintProvider.resolveProvider")})(sW||(aW.InlayHintResolveRequest=sW={}));var oW;(function(e){e.method="workspace/inlayHint/refresh",e.messageDirection=kc.MessageDirection.serverToClient,e.type=new kc.ProtocolRequestType0(e.method),e.capabilities=kc.CM.create("workspace.inlayHint.refreshSupport",void 0)})(oW||(aW.InlayHintRefreshRequest=oW={}))});var hW=z(function(ni){var _Ae=ni&&ni.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),xAe=ni&&ni.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),wAe=ni&&ni.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;i0}e.hasId=t})(LW||(F.StaticRegistrationOptions=LW={}));var qW;(function(e){function t(n){let r=n;return r&&(r.documentSelector===null||MA.is(r.documentSelector))}e.is=t})(qW||(F.TextDocumentRegistrationOptions=qW={}));var UW;(function(e){function t(r){let i=r;return ri.objectLiteral(i)&&(i.workDoneProgress===void 0||ri.boolean(i.workDoneProgress))}e.is=t;function n(r){let i=r;return i&&ri.boolean(i.workDoneProgress)}e.hasWorkDoneProgress=n})(UW||(F.WorkDoneProgressOptions=UW={}));var BW;(function(e){e.method="initialize",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method)})(BW||(F.InitializeRequest=BW={}));var VW;(function(e){e.unknownProtocolVersion=1})(VW||(F.InitializeErrorCodes=VW={}));var KW;(function(e){e.method="initialized",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method)})(KW||(F.InitializedNotification=KW={}));var JW;(function(e){e.method="shutdown",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType0(e.method)})(JW||(F.ShutdownRequest=JW={}));var GW;(function(e){e.method="exit",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType0(e.method)})(GW||(F.ExitNotification=GW={}));var HW;(function(e){e.method="workspace/didChangeConfiguration",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("workspace.didChangeConfiguration",void 0)})(HW||(F.DidChangeConfigurationNotification=HW={}));var zW;(function(e){e.Error=1,e.Warning=2,e.Info=3,e.Log=4,e.Debug=5})(zW||(F.MessageType=zW={}));var WW;(function(e){e.method="window/showMessage",e.messageDirection=De.MessageDirection.serverToClient,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("window.showMessage",void 0)})(WW||(F.ShowMessageNotification=WW={}));var QW;(function(e){e.method="window/showMessageRequest",e.messageDirection=De.MessageDirection.serverToClient,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("window.showMessage",void 0)})(QW||(F.ShowMessageRequest=QW={}));var YW;(function(e){e.method="window/logMessage",e.messageDirection=De.MessageDirection.serverToClient,e.type=new De.ProtocolNotificationType(e.method)})(YW||(F.LogMessageNotification=YW={}));var XW;(function(e){e.method="telemetry/event",e.messageDirection=De.MessageDirection.serverToClient,e.type=new De.ProtocolNotificationType(e.method)})(XW||(F.TelemetryEventNotification=XW={}));var ZW;(function(e){e.None=0,e.Full=1,e.Incremental=2})(ZW||(F.TextDocumentSyncKind=ZW={}));var eQ;(function(e){e.method="textDocument/didOpen",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("textDocument.synchronization","textDocumentSync.openClose")})(eQ||(F.DidOpenTextDocumentNotification=eQ={}));var tQ;(function(e){function t(r){let i=r;return i!==void 0&&i!==null&&typeof i.text==="string"&&i.range!==void 0&&(i.rangeLength===void 0||typeof i.rangeLength==="number")}e.isIncremental=t;function n(r){let i=r;return i!==void 0&&i!==null&&typeof i.text==="string"&&i.range===void 0&&i.rangeLength===void 0}e.isFull=n})(tQ||(F.TextDocumentContentChangeEvent=tQ={}));var nQ;(function(e){e.method="textDocument/didChange",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("textDocument.synchronization","textDocumentSync")})(nQ||(F.DidChangeTextDocumentNotification=nQ={}));var rQ;(function(e){e.method="textDocument/didClose",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("textDocument.synchronization","textDocumentSync.openClose")})(rQ||(F.DidCloseTextDocumentNotification=rQ={}));var iQ;(function(e){e.method="textDocument/didSave",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("textDocument.synchronization.didSave","textDocumentSync.save")})(iQ||(F.DidSaveTextDocumentNotification=iQ={}));var sQ;(function(e){e.Manual=1,e.AfterDelay=2,e.FocusOut=3})(sQ||(F.TextDocumentSaveReason=sQ={}));var oQ;(function(e){e.method="textDocument/willSave",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("textDocument.synchronization.willSave","textDocumentSync.willSave")})(oQ||(F.WillSaveTextDocumentNotification=oQ={}));var aQ;(function(e){e.method="textDocument/willSaveWaitUntil",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.synchronization.willSaveWaitUntil","textDocumentSync.willSaveWaitUntil")})(aQ||(F.WillSaveTextDocumentWaitUntilRequest=aQ={}));var lQ;(function(e){e.method="workspace/didChangeWatchedFiles",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("workspace.didChangeWatchedFiles",void 0)})(lQ||(F.DidChangeWatchedFilesNotification=lQ={}));var cQ;(function(e){e.Created=1,e.Changed=2,e.Deleted=3})(cQ||(F.FileChangeType=cQ={}));var LA;(function(e){function t(n){let r=n;return ri.objectLiteral(r)&&(Hb.is(r.baseUri)||gT.is(r.baseUri))&&ri.string(r.pattern)}e.is=t})(LA||(F.RelativePattern=LA={}));var qA;(function(e){function t(n){let r=n;return ri.string(r)||LA.is(r)}e.is=t})(qA||(F.GlobPattern=qA={}));var uQ;(function(e){e.Create=1,e.Change=2,e.Delete=4})(uQ||(F.WatchKind=uQ={}));var pQ;(function(e){e.method="textDocument/publishDiagnostics",e.messageDirection=De.MessageDirection.serverToClient,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("textDocument.publishDiagnostics",void 0)})(pQ||(F.PublishDiagnosticsNotification=pQ={}));var dQ;(function(e){e.Invoked=1,e.TriggerCharacter=2,e.TriggerForIncompleteCompletions=3})(dQ||(F.CompletionTriggerKind=dQ={}));var fQ;(function(e){e.method="textDocument/completion",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.completion","completionProvider")})(fQ||(F.CompletionRequest=fQ={}));var mQ;(function(e){e.method="completionItem/resolve",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.completion.completionItem.resolveSupport","completionProvider.resolveProvider")})(mQ||(F.CompletionResolveRequest=mQ={}));var yQ;(function(e){e.method="textDocument/hover",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.hover","hoverProvider")})(yQ||(F.HoverRequest=yQ={}));var hQ;(function(e){e.Invoked=1,e.TriggerCharacter=2,e.ContentChange=3})(hQ||(F.SignatureHelpTriggerKind=hQ={}));var gQ;(function(e){e.method="textDocument/signatureHelp",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.signatureHelp","signatureHelpProvider")})(gQ||(F.SignatureHelpRequest=gQ={}));var bQ;(function(e){e.method="textDocument/definition",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.definition","definitionProvider")})(bQ||(F.DefinitionRequest=bQ={}));var vQ;(function(e){e.method="textDocument/references",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.references","referencesProvider")})(vQ||(F.ReferencesRequest=vQ={}));var _Q;(function(e){e.method="textDocument/documentHighlight",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.documentHighlight","documentHighlightProvider")})(_Q||(F.DocumentHighlightRequest=_Q={}));var xQ;(function(e){e.method="textDocument/documentSymbol",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.documentSymbol","documentSymbolProvider")})(xQ||(F.DocumentSymbolRequest=xQ={}));var wQ;(function(e){e.method="textDocument/codeAction",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.codeAction","codeActionProvider")})(wQ||(F.CodeActionRequest=wQ={}));var DQ;(function(e){e.method="codeAction/resolve",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.codeAction.resolveSupport","codeActionProvider.resolveProvider")})(DQ||(F.CodeActionResolveRequest=DQ={}));var TQ;(function(e){e.method="workspace/symbol",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("workspace.symbol","workspaceSymbolProvider")})(TQ||(F.WorkspaceSymbolRequest=TQ={}));var SQ;(function(e){e.method="workspaceSymbol/resolve",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("workspace.symbol.resolveSupport","workspaceSymbolProvider.resolveProvider")})(SQ||(F.WorkspaceSymbolResolveRequest=SQ={}));var EQ;(function(e){e.method="textDocument/codeLens",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.codeLens","codeLensProvider")})(EQ||(F.CodeLensRequest=EQ={}));var kQ;(function(e){e.method="codeLens/resolve",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.codeLens.resolveSupport","codeLensProvider.resolveProvider")})(kQ||(F.CodeLensResolveRequest=kQ={}));var NQ;(function(e){e.method="workspace/codeLens/refresh",e.messageDirection=De.MessageDirection.serverToClient,e.type=new De.ProtocolRequestType0(e.method),e.capabilities=De.CM.create("workspace.codeLens",void 0)})(NQ||(F.CodeLensRefreshRequest=NQ={}));var OQ;(function(e){e.method="textDocument/documentLink",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.documentLink","documentLinkProvider")})(OQ||(F.DocumentLinkRequest=OQ={}));var PQ;(function(e){e.method="documentLink/resolve",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.documentLink","documentLinkProvider.resolveProvider")})(PQ||(F.DocumentLinkResolveRequest=PQ={}));var $Q;(function(e){e.method="textDocument/formatting",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.formatting","documentFormattingProvider")})($Q||(F.DocumentFormattingRequest=$Q={}));var IQ;(function(e){e.method="textDocument/rangeFormatting",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.rangeFormatting","documentRangeFormattingProvider")})(IQ||(F.DocumentRangeFormattingRequest=IQ={}));var AQ;(function(e){e.method="textDocument/rangesFormatting",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.rangeFormatting.rangesSupport","documentRangeFormattingProvider.rangesSupport")})(AQ||(F.DocumentRangesFormattingRequest=AQ={}));var RQ;(function(e){e.method="textDocument/onTypeFormatting",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.onTypeFormatting","documentOnTypeFormattingProvider")})(RQ||(F.DocumentOnTypeFormattingRequest=RQ={}));var jQ;(function(e){e.Identifier=1})(jQ||(F.PrepareSupportDefaultBehavior=jQ={}));var FQ;(function(e){e.method="textDocument/rename",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.rename","renameProvider")})(FQ||(F.RenameRequest=FQ={}));var CQ;(function(e){e.method="textDocument/prepareRename",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.rename.prepareSupport","renameProvider.prepareProvider")})(CQ||(F.PrepareRenameRequest=CQ={}));var MQ;(function(e){e.method="workspace/executeCommand",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("workspace.executeCommand","executeCommandProvider")})(MQ||(F.ExecuteCommandRequest=MQ={}));var LQ;(function(e){e.method="workspace/applyEdit",e.messageDirection=De.MessageDirection.serverToClient,e.type=new De.ProtocolRequestType("workspace/applyEdit"),e.capabilities=De.CM.create("workspace.applyEdit",void 0)})(LQ||(F.ApplyWorkspaceEditRequest=LQ={}))});var zQ=z(function(HQ){Object.defineProperty(HQ,"__esModule",{value:!0});HQ.createProtocolConnection=LAe;var GQ=fy();function LAe(e,t,n,r){if(GQ.ConnectionStrategy.is(r))r={connectionStrategy:r};return GQ.createMessageConnection(e,t,n,r)}});var gr=z(function($s){var UAe=$s&&$s.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),xT=$s&&$s.__exportStar||function(e,t){for(var n in e)if(n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n))UAe(t,e,n)};Object.defineProperty($s,"__esModule",{value:!0});$s.LSPErrorCodes=$s.createProtocolConnection=void 0;xT(fy(),$s);xT((bT(),Ef(cH)),$s);xT(Hn(),$s);xT(JQ(),$s);var BAe=zQ();Object.defineProperty($s,"createProtocolConnection",{enumerable:!0,get:function(){return BAe.createProtocolConnection}});var WQ;(function(e){e.lspReservedErrorRangeStart=-32899,e.RequestFailed=-32803,e.ServerCancelled=-32802,e.ContentModified=-32801,e.RequestCancelled=-32800,e.lspReservedErrorRangeEnd=-32800})(WQ||($s.LSPErrorCodes=WQ={}))});var HA=z(function(QQ){Object.defineProperty(QQ,"__esModule",{value:!0});QQ.SemanticTokensBuilder=QQ.SemanticTokensDiff=QQ.SemanticTokensFeature=void 0;var DT=gr(),VAe=(e)=>class extends e{get semanticTokens(){return{refresh:()=>this.connection.sendRequest(DT.SemanticTokensRefreshRequest.type),on:(t)=>{let n=DT.SemanticTokensRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onDelta:(t)=>{let n=DT.SemanticTokensDeltaRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onRange:(t)=>{let n=DT.SemanticTokensRangeRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};QQ.SemanticTokensFeature=VAe;class GA{originalSequence;modifiedSequence;constructor(e,t){this.originalSequence=e,this.modifiedSequence=t}computeDiff(){let e=this.originalSequence.length,t=this.modifiedSequence.length,n=0;while(n=n&&i>=n&&this.originalSequence[r]===this.modifiedSequence[i])r--,i--;if(r0){if(s-=this._prevLine,s===0)o-=this._prevChar}let a=this._dataIsSortedAndDeltaEncoded?this._data:this._dataNonDelta;a[this._dataLen++]=s,a[this._dataLen++]=o,a[this._dataLen++]=n,a[this._dataLen++]=r,a[this._dataLen++]=i,this._prevLine=e,this._prevChar=t}get id(){return this._id.toString()}static _deltaDecode(e){let t=e.length/5|0,n=0,r=0,i=[];for(let s=0;s{let l=e[5*o],c=e[5*a];if(l===c){let u=e[5*o+1],p=e[5*a+1];return u-p}return l-c});let r=[],i=0,s=0;for(let o=0;o{let r=n.textDocument,i=this._configuration.create(r.uri,r.languageId,r.version,r.text);this._syncedDocuments.set(r.uri,i);let s=Object.freeze({document:i});this._onDidOpen.fire(s),this._onDidChangeContent.fire(s)})),t.push(e.onDidChangeTextDocument((n)=>{let{textDocument:r,contentChanges:i}=n;if(i.length===0)return;let{version:s}=r;if(s===null||s===void 0)throw Error(`Received document change event for ${r.uri} without valid version identifier`);let o=this._syncedDocuments.get(r.uri);if(o!==void 0)o=this._configuration.update(o,i,s),this._syncedDocuments.set(r.uri,o),this._onDidChangeContent.fire(Object.freeze({document:o}))})),t.push(e.onDidCloseTextDocument((n)=>{let r=this._syncedDocuments.get(n.textDocument.uri);if(r!==void 0)this._syncedDocuments.delete(n.textDocument.uri),this._onDidClose.fire(Object.freeze({document:r}))})),t.push(e.onWillSaveTextDocument((n)=>{let r=this._syncedDocuments.get(n.textDocument.uri);if(r!==void 0)this._onWillSave.fire(Object.freeze({document:r,reason:n.reason}))})),t.push(e.onWillSaveTextDocumentWaitUntil((n,r)=>{let i=this._syncedDocuments.get(n.textDocument.uri);if(i!==void 0&&this._willSaveWaitUntil)return this._willSaveWaitUntil(Object.freeze({document:i,reason:n.reason}),r);else return[]})),t.push(e.onDidSaveTextDocument((n)=>{let r=this._syncedDocuments.get(n.textDocument.uri);if(r!==void 0)this._onDidSave.fire(Object.freeze({document:r}))})),ef.Disposable.create(()=>{t.forEach((n)=>n.dispose())})}}ZQ.TextDocuments=XQ});var WA=z(function(rY){Object.defineProperty(rY,"__esModule",{value:!0});rY.NotebookDocuments=rY.NotebookSyncFeature=void 0;var Wo=gr(),tY=zA(),GAe=(e)=>class extends e{get synchronization(){return{onDidOpenNotebookDocument:(t)=>this.connection.onNotification(Wo.DidOpenNotebookDocumentNotification.type,(n)=>t(n)),onDidChangeNotebookDocument:(t)=>this.connection.onNotification(Wo.DidChangeNotebookDocumentNotification.type,(n)=>t(n)),onDidSaveNotebookDocument:(t)=>this.connection.onNotification(Wo.DidSaveNotebookDocumentNotification.type,(n)=>t(n)),onDidCloseNotebookDocument:(t)=>this.connection.onNotification(Wo.DidCloseNotebookDocumentNotification.type,(n)=>t(n))}}};rY.NotebookSyncFeature=GAe;class iv{static NULL_DISPOSE=Object.freeze({dispose:()=>{}});openHandler;changeHandler;closeHandler;onDidOpenTextDocument(e){return this.openHandler=e,Wo.Disposable.create(()=>{this.openHandler=void 0})}openTextDocument(e){return this.openHandler&&this.openHandler(e)}onDidChangeTextDocument(e){return this.changeHandler=e,Wo.Disposable.create(()=>{this.changeHandler=e})}changeTextDocument(e){return this.changeHandler&&this.changeHandler(e)}onDidCloseTextDocument(e){return this.closeHandler=e,Wo.Disposable.create(()=>{this.closeHandler=void 0})}closeTextDocument(e){return this.closeHandler&&this.closeHandler(e)}onWillSaveTextDocument(){return iv.NULL_DISPOSE}onWillSaveTextDocumentWaitUntil(){return iv.NULL_DISPOSE}onDidSaveTextDocument(){return iv.NULL_DISPOSE}}class nY{notebookDocuments;notebookCellMap;_onDidOpen;_onDidSave;_onDidChange;_onDidClose;_cellTextDocuments;constructor(e){if(e instanceof tY.TextDocuments)this._cellTextDocuments=e;else this._cellTextDocuments=new tY.TextDocuments(e);this.notebookDocuments=new Map,this.notebookCellMap=new Map,this._onDidOpen=new Wo.Emitter,this._onDidChange=new Wo.Emitter,this._onDidSave=new Wo.Emitter,this._onDidClose=new Wo.Emitter}get cellTextDocuments(){return this._cellTextDocuments}getCellTextDocument(e){return this._cellTextDocuments.get(e.document)}getNotebookDocument(e){return this.notebookDocuments.get(e)}getNotebookCell(e){let t=this.notebookCellMap.get(e);return t&&t[0]}findNotebookDocumentForCell(e){let t=typeof e==="string"?e:e.document,n=this.notebookCellMap.get(t);return n&&n[1]}get onDidOpen(){return this._onDidOpen.event}get onDidSave(){return this._onDidSave.event}get onDidChange(){return this._onDidChange.event}get onDidClose(){return this._onDidClose.event}listen(e){let t=new iv,n=[];return n.push(this.cellTextDocuments.listen(t)),n.push(e.notebooks.synchronization.onDidOpenNotebookDocument(async(r)=>{this.notebookDocuments.set(r.notebookDocument.uri,r.notebookDocument);for(let i of r.cellTextDocuments)await t.openTextDocument({textDocument:i});this.updateCellMap(r.notebookDocument),this._onDidOpen.fire(r.notebookDocument)})),n.push(e.notebooks.synchronization.onDidChangeNotebookDocument(async(r)=>{let i=this.notebookDocuments.get(r.notebookDocument.uri);if(i===void 0)return;i.version=r.notebookDocument.version;let s=i.metadata,o=!1,a=r.change;if(a.metadata!==void 0)o=!0,i.metadata=a.metadata;let l=[],c=[],u=[],p=[];if(a.cells!==void 0){let h=a.cells;if(h.structure!==void 0){let b=h.structure.array;if(i.cells.splice(b.start,b.deleteCount,...b.cells!==void 0?b.cells:[]),h.structure.didOpen!==void 0)for(let g of h.structure.didOpen)await t.openTextDocument({textDocument:g}),l.push(g.uri);if(h.structure.didClose)for(let g of h.structure.didClose)await t.closeTextDocument({textDocument:g}),c.push(g.uri)}if(h.data!==void 0){let b=new Map(h.data.map((g)=>[g.document,g]));for(let g=0;g<=i.cells.length;g++){let x=b.get(i.cells[g].document);if(x!==void 0){let v=i.cells.splice(g,1,x);if(u.push({old:v[0],new:x}),b.delete(x.document),b.size===0)break}}}if(h.textContent!==void 0)for(let b of h.textContent)await t.changeTextDocument({textDocument:b.document,contentChanges:b.changes}),p.push(b.document.uri)}this.updateCellMap(i);let d={notebookDocument:i};if(o)d.metadata={old:s,new:i.metadata};let f=[];for(let h of l)f.push(this.getNotebookCell(h));let m=[];for(let h of c)m.push(this.getNotebookCell(h));let y=[];for(let h of p)y.push(this.getNotebookCell(h));if(f.length>0||m.length>0||u.length>0||y.length>0)d.cells={added:f,removed:m,changed:{data:u,textContent:y}};if(d.metadata!==void 0||d.cells!==void 0)this._onDidChange.fire(d)})),n.push(e.notebooks.synchronization.onDidSaveNotebookDocument((r)=>{let i=this.notebookDocuments.get(r.notebookDocument.uri);if(i===void 0)return;this._onDidSave.fire(i)})),n.push(e.notebooks.synchronization.onDidCloseNotebookDocument(async(r)=>{let i=this.notebookDocuments.get(r.notebookDocument.uri);if(i===void 0)return;this._onDidClose.fire(i);for(let s of r.cellTextDocuments)await t.closeTextDocument({textDocument:s});this.notebookDocuments.delete(r.notebookDocument.uri);for(let s of i.cells)this.notebookCellMap.delete(s.document)})),Wo.Disposable.create(()=>{n.forEach((r)=>r.dispose())})}updateCellMap(e){for(let t of e.cells)this.notebookCellMap.set(t.document,[t,e])}}rY.NotebookDocuments=nY});var QA=z(function(lY){Object.defineProperty(lY,"__esModule",{value:!0});lY.boolean=zAe;lY.string=sY;lY.number=WAe;lY.error=QAe;lY.func=oY;lY.array=aY;lY.stringArray=YAe;lY.typedArray=XAe;lY.thenable=ZAe;function zAe(e){return e===!0||e===!1}function sY(e){return typeof e==="string"||e instanceof String}function WAe(e){return typeof e==="number"||e instanceof Number}function QAe(e){return e instanceof Error}function oY(e){return typeof e==="function"}function aY(e){return Array.isArray(e)}function YAe(e){return aY(e)&&e.every((t)=>sY(t))}function XAe(e,t){return Array.isArray(e)&&e.every(t)}function ZAe(e){return e&&oY(e.then)}});var YA=z(function(pY){Object.defineProperty(pY,"__esModule",{value:!0});pY.empty=void 0;pY.v4=cY;pY.isUUID=uY;pY.parse=uRe;pY.generateUuid=pRe;class TT{_value;constructor(e){this._value=e}asHex(){return this._value}equals(e){return this.asHex()===e.asHex()}}class Wt extends TT{static _chars=["0","1","2","3","4","5","6","6","7","8","9","a","b","c","d","e","f"];static _timeHighBits=["8","9","a","b"];static _oneOf(e){return e[Math.floor(e.length*Math.random())]}static _randomHex(){return Wt._oneOf(Wt._chars)}constructor(){super([Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),"-",Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),"-","4",Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),"-",Wt._oneOf(Wt._timeHighBits),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),"-",Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex()].join(""))}}pY.empty=new TT("00000000-0000-0000-0000-000000000000");function cY(){return new Wt}var cRe=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;function uY(e){return cRe.test(e)}function uRe(e){if(!uY(e))throw Error("invalid uuid");return new TT(e)}function pRe(){return cY().asHex()}});var hY=z(function(mY){Object.defineProperty(mY,"__esModule",{value:!0});mY.ProgressFeature=void 0;mY.attachWorkDone=gRe;mY.attachPartialResult=vRe;var lp=gr(),hRe=YA();class tf{_connection;_token;static Instances=new Map;constructor(e,t){this._connection=e,this._token=t,tf.Instances.set(this._token,this)}begin(e,t,n,r){let i={kind:"begin",title:e,message:n,cancellable:r};if(typeof t==="number")i.percentage=Math.round(t);this._connection.sendProgress(lp.WorkDoneProgress.type,this._token,i)}report(e,t){let n={kind:"report"};if(typeof e==="number"){if(n.percentage=Math.round(e),t!==void 0)n.message=t}else n.message=e;this._connection.sendProgress(lp.WorkDoneProgress.type,this._token,n)}done(){tf.Instances.delete(this._token),this._connection.sendProgress(lp.WorkDoneProgress.type,this._token,{kind:"end"})}}class XA extends tf{_source;constructor(e,t){super(e,t);this._source=new lp.CancellationTokenSource}get token(){return this._source.token}done(){this._source.dispose(),super.done()}cancel(){this._source.cancel()}}class ST{constructor(){}begin(){}report(){}done(){}}class ZA extends ST{_source;constructor(){super();this._source=new lp.CancellationTokenSource}get token(){return this._source.token}done(){this._source.dispose()}cancel(){this._source.cancel()}}function gRe(e,t){if(t===void 0||t.workDoneToken===void 0)return new ST;let n=t.workDoneToken;return delete t.workDoneToken,new tf(e,n)}var bRe=(e)=>class extends e{_progressSupported;constructor(){super();this._progressSupported=!1}initialize(t){if(super.initialize(t),t?.window?.workDoneProgress===!0)this._progressSupported=!0,this.connection.onNotification(lp.WorkDoneProgressCancelNotification.type,(n)=>{let r=tf.Instances.get(n.token);if(r instanceof XA||r instanceof ZA)r.cancel()})}attachWorkDoneProgress(t){if(t===void 0)return new ST;else return new tf(this.connection,t)}createWorkDoneProgress(){if(this._progressSupported){let t=hRe.generateUuid();return this.connection.sendRequest(lp.WorkDoneProgressCreateRequest.type,{token:t}).then(()=>new XA(this.connection,t))}else return Promise.resolve(new ZA)}};mY.ProgressFeature=bRe;var eR;(function(e){e.type=new lp.ProgressType})(eR||(eR={}));class fY{_connection;_token;constructor(e,t){this._connection=e,this._token=t}report(e){this._connection.sendProgress(eR.type,this._token,e)}}function vRe(e,t){if(t===void 0||t.partialResultToken===void 0)return;let n=t.partialResultToken;return delete t.partialResultToken,new fY(e,n)}});var gY=z(function(Tl){var wRe=Tl&&Tl.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),DRe=Tl&&Tl.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),TRe=Tl&&Tl.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;iclass extends e{getConfiguration(t){if(!t)return this._getConfiguration({});else if(ERe.string(t))return this._getConfiguration({section:t});else return this._getConfiguration(t)}_getConfiguration(t){let n={items:Array.isArray(t)?t:[t]};return this.connection.sendRequest(SRe.ConfigurationRequest.type,n).then((r)=>{if(Array.isArray(r))return Array.isArray(t)?r:r[0];else return Array.isArray(t)?[]:null})}};Tl.ConfigurationFeature=kRe});var _Y=z(function(bY){Object.defineProperty(bY,"__esModule",{value:!0});bY.WorkspaceFoldersFeature=void 0;var ET=gr(),NRe=(e)=>class extends e{_onDidChangeWorkspaceFolders;_unregistration;_notificationIsAutoRegistered;constructor(){super();this._notificationIsAutoRegistered=!1}initialize(t){super.initialize(t);let n=t.workspace;if(n&&n.workspaceFolders)this._onDidChangeWorkspaceFolders=new ET.Emitter,this.connection.onNotification(ET.DidChangeWorkspaceFoldersNotification.type,(r)=>{this._onDidChangeWorkspaceFolders.fire(r.event)})}fillServerCapabilities(t){super.fillServerCapabilities(t);let n=t.workspace?.workspaceFolders?.changeNotifications;this._notificationIsAutoRegistered=n===!0||typeof n==="string"}getWorkspaceFolders(){return this.connection.sendRequest(ET.WorkspaceFoldersRequest.type)}get onDidChangeWorkspaceFolders(){if(!this._onDidChangeWorkspaceFolders)throw Error("Client doesn't support sending workspace folder change events.");if(!this._notificationIsAutoRegistered&&!this._unregistration)this._unregistration=this.connection.client.register(ET.DidChangeWorkspaceFoldersNotification.type);return this._onDidChangeWorkspaceFolders.event}};bY.WorkspaceFoldersFeature=NRe});var DY=z(function(xY){Object.defineProperty(xY,"__esModule",{value:!0});xY.CallHierarchyFeature=void 0;var tR=gr(),ORe=(e)=>class extends e{get callHierarchy(){return{onPrepare:(t)=>this.connection.onRequest(tR.CallHierarchyPrepareRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),void 0)),onIncomingCalls:(t)=>{let n=tR.CallHierarchyIncomingCallsRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onOutgoingCalls:(t)=>{let n=tR.CallHierarchyOutgoingCallsRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};xY.CallHierarchyFeature=ORe});var EY=z(function(TY){Object.defineProperty(TY,"__esModule",{value:!0});TY.ShowDocumentFeature=void 0;var PRe=gr(),$Re=(e)=>class extends e{showDocument(t){return this.connection.sendRequest(PRe.ShowDocumentRequest.type,t)}};TY.ShowDocumentFeature=$Re});var OY=z(function(kY){Object.defineProperty(kY,"__esModule",{value:!0});kY.FileOperationsFeature=void 0;var Ty=gr(),IRe=(e)=>class extends e{onDidCreateFiles(t){return this.connection.onNotification(Ty.DidCreateFilesNotification.type,(n)=>t(n))}onDidRenameFiles(t){return this.connection.onNotification(Ty.DidRenameFilesNotification.type,(n)=>t(n))}onDidDeleteFiles(t){return this.connection.onNotification(Ty.DidDeleteFilesNotification.type,(n)=>t(n))}onWillCreateFiles(t){return this.connection.onRequest(Ty.WillCreateFilesRequest.type,(n,r)=>t(n,r))}onWillRenameFiles(t){return this.connection.onRequest(Ty.WillRenameFilesRequest.type,(n,r)=>t(n,r))}onWillDeleteFiles(t){return this.connection.onRequest(Ty.WillDeleteFilesRequest.type,(n,r)=>t(n,r))}};kY.FileOperationsFeature=IRe});var IY=z(function(PY){Object.defineProperty(PY,"__esModule",{value:!0});PY.LinkedEditingRangeFeature=void 0;var ARe=gr(),RRe=(e)=>class extends e{onLinkedEditingRange(t){return this.connection.onRequest(ARe.LinkedEditingRangeRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),void 0))}};PY.LinkedEditingRangeFeature=RRe});var jY=z(function(AY){Object.defineProperty(AY,"__esModule",{value:!0});AY.TypeHierarchyFeature=void 0;var nR=gr(),jRe=(e)=>class extends e{get typeHierarchy(){return{onPrepare:(t)=>this.connection.onRequest(nR.TypeHierarchyPrepareRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),void 0)),onSupertypes:(t)=>{let n=nR.TypeHierarchySupertypesRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onSubtypes:(t)=>{let n=nR.TypeHierarchySubtypesRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};AY.TypeHierarchyFeature=jRe});var LY=z(function(CY){Object.defineProperty(CY,"__esModule",{value:!0});CY.InlineValueFeature=void 0;var FY=gr(),FRe=(e)=>class extends e{get inlineValue(){return{refresh:()=>this.connection.sendRequest(FY.InlineValueRefreshRequest.type),on:(t)=>this.connection.onRequest(FY.InlineValueRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n)))}}};CY.InlineValueFeature=FRe});var VY=z(function(UY){Object.defineProperty(UY,"__esModule",{value:!0});UY.FoldingRangeFeature=void 0;var qY=gr(),CRe=(e)=>class extends e{get foldingRange(){return{refresh:()=>this.connection.sendRequest(qY.FoldingRangeRefreshRequest.type),on:(t)=>{let n=qY.FoldingRangeRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};UY.FoldingRangeFeature=CRe});var GY=z(function(KY){Object.defineProperty(KY,"__esModule",{value:!0});KY.InlayHintFeature=void 0;var rR=gr(),MRe=(e)=>class extends e{get inlayHint(){return{refresh:()=>this.connection.sendRequest(rR.InlayHintRefreshRequest.type),on:(t)=>this.connection.onRequest(rR.InlayHintRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n))),resolve:(t)=>this.connection.onRequest(rR.InlayHintResolveRequest.type,(n,r)=>t(n,r))}}};KY.InlayHintFeature=MRe});var WY=z(function(HY){Object.defineProperty(HY,"__esModule",{value:!0});HY.DiagnosticFeature=void 0;var sv=gr(),LRe=(e)=>class extends e{get diagnostics(){return{refresh:()=>this.connection.sendRequest(sv.DiagnosticRefreshRequest.type),on:(t)=>this.connection.onRequest(sv.DocumentDiagnosticRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),this.attachPartialResultProgress(sv.DocumentDiagnosticRequest.partialResult,n))),onWorkspace:(t)=>this.connection.onRequest(sv.WorkspaceDiagnosticRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),this.attachPartialResultProgress(sv.WorkspaceDiagnosticRequest.partialResult,n)))}}};HY.DiagnosticFeature=LRe});var XY=z(function(QY){Object.defineProperty(QY,"__esModule",{value:!0});QY.MonikerFeature=void 0;var qRe=gr(),URe=(e)=>class extends e{get moniker(){return{on:(t)=>{let n=qRe.MonikerRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};QY.MonikerFeature=URe});var tX=z(function(ZY){Object.defineProperty(ZY,"__esModule",{value:!0});ZY.InlineCompletionFeature=void 0;var BRe=gr(),VRe=(e)=>class extends e{get inlineCompletion(){return{on:(t)=>this.connection.onRequest(BRe.InlineCompletionRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n)))}}};ZY.InlineCompletionFeature=VRe});var sX=z(function(rX){Object.defineProperty(rX,"__esModule",{value:!0});rX.TextDocumentContentFeature=void 0;var nX=gr(),KRe=(e)=>class extends e{get textDocumentContent(){return{refresh:(t)=>this.connection.sendRequest(nX.TextDocumentContentRefreshRequest.type,{uri:t}),on:(t)=>this.connection.onRequest(nX.TextDocumentContentRequest.type,(n,r)=>t(n,r))}}};rX.TextDocumentContentFeature=KRe});var TX=z(function($n){var JRe=$n&&$n.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),GRe=$n&&$n.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),dX=$n&&$n.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;i{e.window.showErrorMessage(t)})}}$n.ErrorMessageTracker=fX;class oR{_rawConnection;_connection;constructor(){}rawAttach(e){this._rawConnection=e}attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}fillServerCapabilities(e){}initialize(e){}error(e){this.send(Ve.MessageType.Error,e)}warn(e){this.send(Ve.MessageType.Warning,e)}info(e){this.send(Ve.MessageType.Info,e)}log(e){this.send(Ve.MessageType.Log,e)}debug(e){this.send(Ve.MessageType.Debug,e)}send(e,t){if(this._rawConnection)this._rawConnection.sendNotification(Ve.LogMessageNotification.type,{type:e,message:t}).catch(()=>{Ve.RAL().console.error("Sending log message failed")})}}class mX{_connection;constructor(){}attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}initialize(e){}fillServerCapabilities(e){}showErrorMessage(e,...t){let n={type:Ve.MessageType.Error,message:e,actions:t};return this.connection.sendRequest(Ve.ShowMessageRequest.type,n).then(iR)}showWarningMessage(e,...t){let n={type:Ve.MessageType.Warning,message:e,actions:t};return this.connection.sendRequest(Ve.ShowMessageRequest.type,n).then(iR)}showInformationMessage(e,...t){let n={type:Ve.MessageType.Info,message:e,actions:t};return this.connection.sendRequest(Ve.ShowMessageRequest.type,n).then(iR)}}var oX=YRe.ShowDocumentFeature(kt.ProgressFeature(mX)),aX;(function(e){function t(){return new uR}e.create=t})(aX||($n.BulkRegistration=aX={}));class uR{_registrations=[];_registered=new Set;add(e,t){let n=Qo.string(e)?e:e.method;if(this._registered.has(n))throw Error(`${n} is already added to this registration`);let r=sR.generateUuid();this._registrations.push({id:r,method:n,registerOptions:t||{}}),this._registered.add(n)}asRegistrationParams(){return{registrations:this._registrations}}}var lX;(function(e){function t(){return new kT(void 0,[])}e.create=t})(lX||($n.BulkUnregistration=lX={}));class kT{_connection;_unregistrations=new Map;constructor(e,t){this._connection=e,t.forEach((n)=>{this._unregistrations.set(n.method,n)})}get isAttached(){return!!this._connection}attach(e){this._connection=e}add(e){this._unregistrations.set(e.method,e)}dispose(){let e=[];for(let n of this._unregistrations.values())e.push(n);let t={unregisterations:e};this._connection.sendRequest(Ve.UnregistrationRequest.type,t).catch(()=>{this._connection.console.info("Bulk unregistration failed.")})}disposeSingle(e){let t=Qo.string(e)?e:e.method,n=this._unregistrations.get(t);if(!n)return!1;let r={unregisterations:[n]};return this._connection.sendRequest(Ve.UnregistrationRequest.type,r).then(()=>{this._unregistrations.delete(t)},(i)=>{this._connection.console.info(`Un-registering request handler for ${n.id} failed.`)}),!0}}class aR{_connection;attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}initialize(e){}fillServerCapabilities(e){}register(e,t,n){if(e instanceof uR)return this.registerMany(e);else if(e instanceof kT)return this.registerSingle1(e,t,n);else return this.registerSingle2(e,t)}registerSingle1(e,t,n){let r=Qo.string(t)?t:t.method,i=sR.generateUuid(),s={registrations:[{id:i,method:r,registerOptions:n||{}}]};if(!e.isAttached)e.attach(this.connection);return this.connection.sendRequest(Ve.RegistrationRequest.type,s).then((o)=>(e.add({id:i,method:r}),e),(o)=>(this.connection.console.info(`Registering request handler for ${r} failed.`),Promise.reject(o)))}registerSingle2(e,t){let n=Qo.string(e)?e:e.method,r=sR.generateUuid(),i={registrations:[{id:r,method:n,registerOptions:t||{}}]};return this.connection.sendRequest(Ve.RegistrationRequest.type,i).then((s)=>Ve.Disposable.create(()=>{this.unregisterSingle(r,n).catch(()=>{this.connection.console.info(`Un-registering capability with id ${r} failed.`)})}),(s)=>(this.connection.console.info(`Registering request handler for ${n} failed.`),Promise.reject(s)))}unregisterSingle(e,t){let n={unregisterations:[{id:e,method:t}]};return this.connection.sendRequest(Ve.UnregistrationRequest.type,n).catch(()=>{this.connection.console.info(`Un-registering request handler for ${e} failed.`)})}registerMany(e){let t=e.asRegistrationParams();return this.connection.sendRequest(Ve.RegistrationRequest.type,t).then(()=>new kT(this._connection,t.registrations.map((n)=>({id:n.id,method:n.method}))),(n)=>(this.connection.console.info("Bulk registration failed."),Promise.reject(n)))}}class yX{_connection;constructor(){}attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}initialize(e){}fillServerCapabilities(e){}applyEdit(e){function t(r){return r&&!!r.edit}let n=t(e)?e:{edit:e};return this.connection.sendRequest(Ve.ApplyWorkspaceEditRequest.type,n)}}var cX=lje.TextDocumentContentFeature(XRe.FileOperationsFeature(zRe.WorkspaceFoldersFeature(HRe.ConfigurationFeature(yX))));class lR{_trace;_connection;constructor(){this._trace=Ve.Trace.Off}attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}initialize(e){}fillServerCapabilities(e){}set trace(e){this._trace=e}log(e,t){if(this._trace===Ve.Trace.Off)return;this.connection.sendNotification(Ve.LogTraceNotification.type,{message:e,verbose:this._trace===Ve.Trace.Verbose?t:void 0}).catch(()=>{})}}class cR{_connection;constructor(){}attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}initialize(e){}fillServerCapabilities(e){}logEvent(e){this.connection.sendNotification(Ve.TelemetryEventNotification.type,e).catch(()=>{this.connection.console.log("Sending TelemetryEventNotification failed")})}}class pR{_connection;constructor(){}attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}initialize(e){}fillServerCapabilities(e){}attachWorkDoneProgress(e){return kt.attachWorkDone(this.connection,e)}attachPartialResultProgress(e,t){return kt.attachPartialResult(this.connection,t)}}$n._LanguagesImpl=pR;var uX=aje.InlineCompletionFeature(nje.FoldingRangeFeature(oje.MonikerFeature(ije.DiagnosticFeature(rje.InlayHintFeature(tje.InlineValueFeature(eje.TypeHierarchyFeature(ZRe.LinkedEditingRangeFeature(QRe.SemanticTokensFeature(WRe.CallHierarchyFeature(pR))))))))));class dR{_connection;constructor(){}attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}initialize(e){}fillServerCapabilities(e){}attachWorkDoneProgress(e){return kt.attachWorkDone(this.connection,e)}attachPartialResultProgress(e,t){return kt.attachPartialResult(this.connection,t)}}$n._NotebooksImpl=dR;var pX=sje.NotebookSyncFeature(dR);function hX(e,t){return function(n){return t(e(n))}}function gX(e,t){return function(n){return t(e(n))}}function bX(e,t){return function(n){return t(e(n))}}function vX(e,t){return function(n){return t(e(n))}}function _X(e,t){return function(n){return t(e(n))}}function xX(e,t){return function(n){return t(e(n))}}function wX(e,t){return function(n){return t(e(n))}}function DX(e,t){return function(n){return t(e(n))}}function cje(e,t){function n(i,s,o){if(i&&s)return o(i,s);else if(i)return i;else return s}return{__brand:"features",console:n(e.console,t.console,hX),tracer:n(e.tracer,t.tracer,bX),telemetry:n(e.telemetry,t.telemetry,gX),client:n(e.client,t.client,vX),window:n(e.window,t.window,_X),workspace:n(e.workspace,t.workspace,xX),languages:n(e.languages,t.languages,wX),notebooks:n(e.notebooks,t.notebooks,DX)}}function uje(e,t,n){let r=n&&n.console?new(n.console(oR)):new oR,i=e(r);r.rawAttach(i);let s=n&&n.tracer?new(n.tracer(lR)):new lR,o=n&&n.telemetry?new(n.telemetry(cR)):new cR,a=n&&n.client?new(n.client(aR)):new aR,l=n&&n.window?new(n.window(oX)):new oX,c=n&&n.workspace?new(n.workspace(cX)):new cX,u=n&&n.languages?new(n.languages(uX)):new uX,p=n&&n.notebooks?new(n.notebooks(pX)):new pX,d=[r,s,o,a,l,c,u,p];function f(g){if(g instanceof Promise)return g;else if(Qo.thenable(g))return new Promise((x,v)=>{g.then((D)=>x(D),(D)=>v(D))});else return Promise.resolve(g)}let m=void 0,y=void 0,h=void 0,b={listen:()=>i.listen(),sendRequest:(g,...x)=>i.sendRequest(Qo.string(g)?g:g.method,...x),onRequest:(g,x)=>i.onRequest(g,x),sendNotification:(g,x)=>{let v=Qo.string(g)?g:g.method;return i.sendNotification(v,x)},onNotification:(g,x)=>i.onNotification(g,x),onProgress:i.onProgress,sendProgress:i.sendProgress,onInitialize:(g)=>(y=g,{dispose:()=>{y=void 0}}),onInitialized:(g)=>i.onNotification(Ve.InitializedNotification.type,g),onShutdown:(g)=>(m=g,{dispose:()=>{m=void 0}}),onExit:(g)=>(h=g,{dispose:()=>{h=void 0}}),get console(){return r},get telemetry(){return o},get tracer(){return s},get client(){return a},get window(){return l},get workspace(){return c},get languages(){return u},get notebooks(){return p},onDidChangeConfiguration:(g)=>i.onNotification(Ve.DidChangeConfigurationNotification.type,g),onDidChangeWatchedFiles:(g)=>i.onNotification(Ve.DidChangeWatchedFilesNotification.type,g),__textDocumentSync:void 0,onDidOpenTextDocument:(g)=>i.onNotification(Ve.DidOpenTextDocumentNotification.type,g),onDidChangeTextDocument:(g)=>i.onNotification(Ve.DidChangeTextDocumentNotification.type,g),onDidCloseTextDocument:(g)=>i.onNotification(Ve.DidCloseTextDocumentNotification.type,g),onWillSaveTextDocument:(g)=>i.onNotification(Ve.WillSaveTextDocumentNotification.type,g),onWillSaveTextDocumentWaitUntil:(g)=>i.onRequest(Ve.WillSaveTextDocumentWaitUntilRequest.type,g),onDidSaveTextDocument:(g)=>i.onNotification(Ve.DidSaveTextDocumentNotification.type,g),sendDiagnostics:(g)=>i.sendNotification(Ve.PublishDiagnosticsNotification.type,g),onHover:(g)=>i.onRequest(Ve.HoverRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),void 0)),onCompletion:(g)=>i.onRequest(Ve.CompletionRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onCompletionResolve:(g)=>i.onRequest(Ve.CompletionResolveRequest.type,g),onSignatureHelp:(g)=>i.onRequest(Ve.SignatureHelpRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),void 0)),onDeclaration:(g)=>i.onRequest(Ve.DeclarationRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onDefinition:(g)=>i.onRequest(Ve.DefinitionRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onTypeDefinition:(g)=>i.onRequest(Ve.TypeDefinitionRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onImplementation:(g)=>i.onRequest(Ve.ImplementationRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onReferences:(g)=>i.onRequest(Ve.ReferencesRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onDocumentHighlight:(g)=>i.onRequest(Ve.DocumentHighlightRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onDocumentSymbol:(g)=>i.onRequest(Ve.DocumentSymbolRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onWorkspaceSymbol:(g)=>i.onRequest(Ve.WorkspaceSymbolRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onWorkspaceSymbolResolve:(g)=>i.onRequest(Ve.WorkspaceSymbolResolveRequest.type,g),onCodeAction:(g)=>i.onRequest(Ve.CodeActionRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onCodeActionResolve:(g)=>i.onRequest(Ve.CodeActionResolveRequest.type,(x,v)=>g(x,v)),onCodeLens:(g)=>i.onRequest(Ve.CodeLensRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onCodeLensResolve:(g)=>i.onRequest(Ve.CodeLensResolveRequest.type,(x,v)=>g(x,v)),onDocumentFormatting:(g)=>i.onRequest(Ve.DocumentFormattingRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),void 0)),onDocumentRangeFormatting:(g)=>i.onRequest(Ve.DocumentRangeFormattingRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),void 0)),onDocumentRangesFormatting:(g)=>i.onRequest(Ve.DocumentRangesFormattingRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),void 0)),onDocumentOnTypeFormatting:(g)=>i.onRequest(Ve.DocumentOnTypeFormattingRequest.type,(x,v)=>g(x,v)),onRenameRequest:(g)=>i.onRequest(Ve.RenameRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),void 0)),onPrepareRename:(g)=>i.onRequest(Ve.PrepareRenameRequest.type,(x,v)=>g(x,v)),onDocumentLinks:(g)=>i.onRequest(Ve.DocumentLinkRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onDocumentLinkResolve:(g)=>i.onRequest(Ve.DocumentLinkResolveRequest.type,(x,v)=>g(x,v)),onDocumentColor:(g)=>i.onRequest(Ve.DocumentColorRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onColorPresentation:(g)=>i.onRequest(Ve.ColorPresentationRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onFoldingRanges:(g)=>i.onRequest(Ve.FoldingRangeRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onSelectionRanges:(g)=>i.onRequest(Ve.SelectionRangeRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),kt.attachPartialResult(i,x))),onExecuteCommand:(g)=>i.onRequest(Ve.ExecuteCommandRequest.type,(x,v)=>g(x,v,kt.attachWorkDone(i,x),void 0)),dispose:()=>i.dispose()};for(let g of d)g.attach(b);return i.onRequest(Ve.InitializeRequest.type,(g)=>{if(t.initialize(g),Qo.string(g.trace))s.trace=Ve.Trace.fromString(g.trace);for(let x of d)x.initialize(g.capabilities);if(y){let x=y(g,new Ve.CancellationTokenSource().token,kt.attachWorkDone(i,g),void 0);return f(x).then((v)=>{if(v instanceof Ve.ResponseError)return v;let D=v;if(!D)D={capabilities:{}};let T=D.capabilities;if(!T)T={},D.capabilities=T;if(T.textDocumentSync===void 0||T.textDocumentSync===null)T.textDocumentSync=Qo.number(b.__textDocumentSync)?b.__textDocumentSync:Ve.TextDocumentSyncKind.None;else if(!Qo.number(T.textDocumentSync)&&!Qo.number(T.textDocumentSync.change))T.textDocumentSync.change=Qo.number(b.__textDocumentSync)?b.__textDocumentSync:Ve.TextDocumentSyncKind.None;for(let N of d)N.fillServerCapabilities(T);return D})}else{let x={capabilities:{textDocumentSync:Ve.TextDocumentSyncKind.None}};for(let v of d)v.fillServerCapabilities(x.capabilities);return x}}),i.onRequest(Ve.ShutdownRequest.type,()=>{if(t.shutdownReceived=!0,m)return m(new Ve.CancellationTokenSource().token);else return}),i.onNotification(Ve.ExitNotification.type,()=>{try{if(h)return h()}finally{if(t.shutdownReceived)t.exit(0);else t.exit(1)}}),i.onNotification(Ve.SetTraceNotification.type,(g)=>{s.trace=Ve.Trace.fromString(g.value)}),b}});var cp=z(function(Ci){var pje=Ci&&Ci.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),EX=Ci&&Ci.__exportStar||function(e,t){for(var n in e)if(n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n))pje(t,e,n)};Object.defineProperty(Ci,"__esModule",{value:!0});Ci.ProposedFeatures=Ci.NotebookDocuments=Ci.TextDocuments=Ci.SemanticTokensBuilder=void 0;var dje=HA();Object.defineProperty(Ci,"SemanticTokensBuilder",{enumerable:!0,get:function(){return dje.SemanticTokensBuilder}});EX(gr(),Ci);var fje=zA();Object.defineProperty(Ci,"TextDocuments",{enumerable:!0,get:function(){return fje.TextDocuments}});var mje=WA();Object.defineProperty(Ci,"NotebookDocuments",{enumerable:!0,get:function(){return mje.NotebookDocuments}});EX(TX(),Ci);var SX;(function(e){e.all={__brand:"features"}})(SX||(Ci.ProposedFeatures=SX={}))});var fR=q(()=>{Gt()});var kX=q(()=>{vt()});var NT=q(()=>{kX()});var yR=q(()=>{vt();ay();Yn();Xs();It()});var OT=q(()=>{mn();Gt()});var NX=q(()=>{mn();OT()});var OX=q(()=>{mn();ol();OT()});var PX=q(()=>{NX();OX();OT()});var $X=q(()=>{PX()});var bje,vje;var IX=q(()=>{vw();bje={type:"object",additionalProperties:!1,properties:{name:{type:"string"},version:{type:"string",nullable:!0}},required:["name"]},vje={type:"object",additionalProperties:!1,properties:{title:{type:"string"},description:{type:"string"},target:{type:"string",enum:["library","project"],default:"project",nullable:!0},compilerVersion:{type:"string",nullable:!0},libraries:{type:"array",items:{oneOf:[{type:"string"},bje]},nullable:!0},emitters:{type:"object",nullable:!0,additionalProperties:{type:"object",properties:{label:{type:"string",nullable:!0},description:{type:"string",nullable:!0},selected:{type:"boolean",nullable:!0},options:{},message:{type:"string",nullable:!0},version:{type:"string",nullable:!0}},required:[]},required:[]},skipCompilerPackage:{type:"boolean",nullable:!0},config:{nullable:!0,...Xg},inputs:{type:"object",nullable:!0,additionalProperties:{type:"object",properties:{description:{type:"string"},type:{type:"string",enum:["text"]},initialValue:{}},required:["description","type"]},required:[]},files:{type:"array",nullable:!0,items:{type:"object",properties:{path:{type:"string"},destination:{type:"string"},skipGeneration:{type:"boolean",nullable:!0}},required:["path","destination"]}}},required:["title","description"]}});var AX=q(()=>{km();IX()});var ov=z(function(Rxt,RX){var _je=typeof process==="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{};RX.exports=_je});var PT=z(function(jxt,jX){var xje=Number.MAX_SAFE_INTEGER||9007199254740991,wje=["major","premajor","minor","preminor","patch","prepatch","prerelease"];jX.exports={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:16,MAX_SAFE_BUILD_LENGTH:250,MAX_SAFE_INTEGER:xje,RELEASE_TYPES:wje,SEMVER_SPEC_VERSION:"2.0.0",FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2}});var $T=z(function(Sl,FX){var{MAX_SAFE_COMPONENT_LENGTH:hR,MAX_SAFE_BUILD_LENGTH:Dje,MAX_LENGTH:Tje}=PT(),Sje=ov();Sl=FX.exports={};var Eje=Sl.re=[],kje=Sl.safeRe=[],Ye=Sl.src=[],Nje=Sl.safeSrc=[],Xe=Sl.t={},Oje=0,gR="[a-zA-Z0-9-]",Pje=[["\\s",1],["\\d",Tje],[gR,Dje]],$je=(e)=>{for(let[t,n]of Pje)e=e.split(`${t}*`).join(`${t}{0,${n}}`).split(`${t}+`).join(`${t}{1,${n}}`);return e},$t=(e,t,n)=>{let r=$je(t),i=Oje++;Sje(e,i,t),Xe[e]=i,Ye[i]=t,Nje[i]=r,Eje[i]=new RegExp(t,n?"g":void 0),kje[i]=new RegExp(r,n?"g":void 0)};$t("NUMERICIDENTIFIER","0|[1-9]\\d*");$t("NUMERICIDENTIFIERLOOSE","\\d+");$t("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${gR}*`);$t("MAINVERSION",`(${Ye[Xe.NUMERICIDENTIFIER]})\\.(${Ye[Xe.NUMERICIDENTIFIER]})\\.(${Ye[Xe.NUMERICIDENTIFIER]})`);$t("MAINVERSIONLOOSE",`(${Ye[Xe.NUMERICIDENTIFIERLOOSE]})\\.(${Ye[Xe.NUMERICIDENTIFIERLOOSE]})\\.(${Ye[Xe.NUMERICIDENTIFIERLOOSE]})`);$t("PRERELEASEIDENTIFIER",`(?:${Ye[Xe.NONNUMERICIDENTIFIER]}|${Ye[Xe.NUMERICIDENTIFIER]})`);$t("PRERELEASEIDENTIFIERLOOSE",`(?:${Ye[Xe.NONNUMERICIDENTIFIER]}|${Ye[Xe.NUMERICIDENTIFIERLOOSE]})`);$t("PRERELEASE",`(?:-(${Ye[Xe.PRERELEASEIDENTIFIER]}(?:\\.${Ye[Xe.PRERELEASEIDENTIFIER]})*))`);$t("PRERELEASELOOSE",`(?:-?(${Ye[Xe.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${Ye[Xe.PRERELEASEIDENTIFIERLOOSE]})*))`);$t("BUILDIDENTIFIER",`${gR}+`);$t("BUILD",`(?:\\+(${Ye[Xe.BUILDIDENTIFIER]}(?:\\.${Ye[Xe.BUILDIDENTIFIER]})*))`);$t("FULLPLAIN",`v?${Ye[Xe.MAINVERSION]}${Ye[Xe.PRERELEASE]}?${Ye[Xe.BUILD]}?`);$t("FULL",`^${Ye[Xe.FULLPLAIN]}$`);$t("LOOSEPLAIN",`[v=\\s]*${Ye[Xe.MAINVERSIONLOOSE]}${Ye[Xe.PRERELEASELOOSE]}?${Ye[Xe.BUILD]}?`);$t("LOOSE",`^${Ye[Xe.LOOSEPLAIN]}$`);$t("GTLT","((?:<|>)?=?)");$t("XRANGEIDENTIFIERLOOSE",`${Ye[Xe.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);$t("XRANGEIDENTIFIER",`${Ye[Xe.NUMERICIDENTIFIER]}|x|X|\\*`);$t("XRANGEPLAIN",`[v=\\s]*(${Ye[Xe.XRANGEIDENTIFIER]})(?:\\.(${Ye[Xe.XRANGEIDENTIFIER]})(?:\\.(${Ye[Xe.XRANGEIDENTIFIER]})(?:${Ye[Xe.PRERELEASE]})?${Ye[Xe.BUILD]}?)?)?`);$t("XRANGEPLAINLOOSE",`[v=\\s]*(${Ye[Xe.XRANGEIDENTIFIERLOOSE]})(?:\\.(${Ye[Xe.XRANGEIDENTIFIERLOOSE]})(?:\\.(${Ye[Xe.XRANGEIDENTIFIERLOOSE]})(?:${Ye[Xe.PRERELEASELOOSE]})?${Ye[Xe.BUILD]}?)?)?`);$t("XRANGE",`^${Ye[Xe.GTLT]}\\s*${Ye[Xe.XRANGEPLAIN]}$`);$t("XRANGELOOSE",`^${Ye[Xe.GTLT]}\\s*${Ye[Xe.XRANGEPLAINLOOSE]}$`);$t("COERCEPLAIN",`(^|[^\\d])(\\d{1,${hR}})(?:\\.(\\d{1,${hR}}))?(?:\\.(\\d{1,${hR}}))?`);$t("COERCE",`${Ye[Xe.COERCEPLAIN]}(?:$|[^\\d])`);$t("COERCEFULL",Ye[Xe.COERCEPLAIN]+`(?:${Ye[Xe.PRERELEASE]})?(?:${Ye[Xe.BUILD]})?(?:$|[^\\d])`);$t("COERCERTL",Ye[Xe.COERCE],!0);$t("COERCERTLFULL",Ye[Xe.COERCEFULL],!0);$t("LONETILDE","(?:~>?)");$t("TILDETRIM",`(\\s*)${Ye[Xe.LONETILDE]}\\s+`,!0);Sl.tildeTrimReplace="$1~";$t("TILDE",`^${Ye[Xe.LONETILDE]}${Ye[Xe.XRANGEPLAIN]}$`);$t("TILDELOOSE",`^${Ye[Xe.LONETILDE]}${Ye[Xe.XRANGEPLAINLOOSE]}$`);$t("LONECARET","(?:\\^)");$t("CARETTRIM",`(\\s*)${Ye[Xe.LONECARET]}\\s+`,!0);Sl.caretTrimReplace="$1^";$t("CARET",`^${Ye[Xe.LONECARET]}${Ye[Xe.XRANGEPLAIN]}$`);$t("CARETLOOSE",`^${Ye[Xe.LONECARET]}${Ye[Xe.XRANGEPLAINLOOSE]}$`);$t("COMPARATORLOOSE",`^${Ye[Xe.GTLT]}\\s*(${Ye[Xe.LOOSEPLAIN]})$|^$`);$t("COMPARATOR",`^${Ye[Xe.GTLT]}\\s*(${Ye[Xe.FULLPLAIN]})$|^$`);$t("COMPARATORTRIM",`(\\s*)${Ye[Xe.GTLT]}\\s*(${Ye[Xe.LOOSEPLAIN]}|${Ye[Xe.XRANGEPLAIN]})`,!0);Sl.comparatorTrimReplace="$1$2$3";$t("HYPHENRANGE",`^\\s*(${Ye[Xe.XRANGEPLAIN]})\\s+-\\s+(${Ye[Xe.XRANGEPLAIN]})\\s*$`);$t("HYPHENRANGELOOSE",`^\\s*(${Ye[Xe.XRANGEPLAINLOOSE]})\\s+-\\s+(${Ye[Xe.XRANGEPLAINLOOSE]})\\s*$`);$t("STAR","(<|>)?=?\\s*\\*");$t("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$");$t("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")});var IT=z(function(Fxt,CX){var Ije=Object.freeze({loose:!0}),Aje=Object.freeze({}),Rje=(e)=>{if(!e)return Aje;if(typeof e!=="object")return Ije;return e};CX.exports=Rje});var UX=z(function(Cxt,qX){var MX=/^[0-9]+$/,LX=(e,t)=>{if(typeof e==="number"&&typeof t==="number")return e===t?0:eLX(t,e);qX.exports={compareIdentifiers:LX,rcompareIdentifiers:jje}});var av=z(function(Mxt,VX){var AT=ov(),{MAX_LENGTH:BX,MAX_SAFE_INTEGER:RT}=PT(),{safeRe:jT,t:FT}=$T(),Fje=IT(),{compareIdentifiers:bR}=UX(),Cje=(e,t)=>{let n=t.split(".");if(n.length>e.length)return!1;for(let r=0;rBX)throw TypeError(`version is longer than ${BX} characters`);AT("SemVer",e,t),this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease;let n=e.trim().match(t.loose?jT[FT.LOOSE]:jT[FT.FULL]);if(!n)throw TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+n[1],this.minor=+n[2],this.patch=+n[3],this.major>RT||this.major<0)throw TypeError("Invalid major version");if(this.minor>RT||this.minor<0)throw TypeError("Invalid minor version");if(this.patch>RT||this.patch<0)throw TypeError("Invalid patch version");if(!n[4])this.prerelease=[];else this.prerelease=n[4].split(".").map((r)=>{if(/^[0-9]+$/.test(r)){let i=+r;if(i>=0&&ie.major)return 1;if(this.minore.minor)return 1;if(this.patche.patch)return 1;return 0}comparePre(e){if(!(e instanceof $a))e=new $a(e,this.options);if(this.prerelease.length&&!e.prerelease.length)return-1;else if(!this.prerelease.length&&e.prerelease.length)return 1;else if(!this.prerelease.length&&!e.prerelease.length)return 0;let t=0;do{let n=this.prerelease[t],r=e.prerelease[t];if(AT("prerelease compare",t,n,r),n===void 0&&r===void 0)return 0;else if(r===void 0)return 1;else if(n===void 0)return-1;else if(n===r)continue;else return bR(n,r)}while(++t)}compareBuild(e){if(!(e instanceof $a))e=new $a(e,this.options);let t=0;do{let n=this.build[t],r=e.build[t];if(AT("build compare",t,n,r),n===void 0&&r===void 0)return 0;else if(r===void 0)return 1;else if(n===void 0)return-1;else if(n===r)continue;else return bR(n,r)}while(++t)}inc(e,t,n){if(e.startsWith("pre")){if(!t&&n===!1)throw Error("invalid increment argument: identifier is empty");if(t){let r=`-${t}`.match(this.options.loose?jT[FT.PRERELEASELOOSE]:jT[FT.PRERELEASE]);if(!r||r[1]!==t)throw Error(`invalid identifier: ${t}`)}}switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",t,n);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",t,n);break;case"prepatch":this.prerelease.length=0,this.inc("patch",t,n),this.inc("pre",t,n);break;case"prerelease":if(this.prerelease.length===0)this.inc("patch",t,n);this.inc("pre",t,n);break;case"release":if(this.prerelease.length===0)throw Error(`version ${this.raw} is not a prerelease`);this.prerelease.length=0;break;case"major":if(this.minor!==0||this.patch!==0||this.prerelease.length===0)this.major++;this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":if(this.patch!==0||this.prerelease.length===0)this.minor++;this.patch=0,this.prerelease=[];break;case"patch":if(this.prerelease.length===0)this.patch++;this.prerelease=[];break;case"pre":{let r=Number(n)?1:0;if(this.prerelease.length===0)this.prerelease=[r];else{let i=this.prerelease.length;while(--i>=0)if(typeof this.prerelease[i]==="number")this.prerelease[i]++,i=-2;if(i===-1){if(t===this.prerelease.join(".")&&n===!1)throw Error("invalid increment argument: identifier already exists");this.prerelease.push(r)}}if(t){let i=[t,r];if(n===!1)i=[t];if(Cje(this.prerelease,t)){let s=this.prerelease[t.split(".").length];if(isNaN(s))this.prerelease=i}else this.prerelease=i}break}default:throw Error(`invalid increment argument: ${e}`)}if(this.raw=this.format(),this.build.length)this.raw+=`+${this.build.join(".")}`;return this}}VX.exports=$a});var GX=z(function(Lxt,JX){class KX{constructor(){this.max=1000,this.map=new Map}get(e){let t=this.map.get(e);if(t===void 0)return;else return this.map.delete(e),this.map.set(e,t),t}delete(e){return this.map.delete(e)}set(e,t){if(!this.delete(e)&&t!==void 0){if(this.map.size>=this.max){let r=this.map.keys().next().value;this.delete(r)}this.map.set(e,t)}return this}}JX.exports=KX});var nf=z(function(qxt,zX){var HX=av(),Mje=(e,t,n)=>new HX(e,n).compare(new HX(t,n));zX.exports=Mje});var QX=z(function(Uxt,WX){var Lje=nf(),qje=(e,t,n)=>Lje(e,t,n)===0;WX.exports=qje});var XX=z(function(Bxt,YX){var Uje=nf(),Bje=(e,t,n)=>Uje(e,t,n)!==0;YX.exports=Bje});var eZ=z(function(Vxt,ZX){var Vje=nf(),Kje=(e,t,n)=>Vje(e,t,n)>0;ZX.exports=Kje});var nZ=z(function(Kxt,tZ){var Jje=nf(),Gje=(e,t,n)=>Jje(e,t,n)>=0;tZ.exports=Gje});var iZ=z(function(Jxt,rZ){var Hje=nf(),zje=(e,t,n)=>Hje(e,t,n)<0;rZ.exports=zje});var oZ=z(function(Gxt,sZ){var Wje=nf(),Qje=(e,t,n)=>Wje(e,t,n)<=0;sZ.exports=Qje});var lZ=z(function(Hxt,aZ){var Yje=QX(),Xje=XX(),Zje=eZ(),eFe=nZ(),tFe=iZ(),nFe=oZ(),rFe=(e,t,n,r)=>{switch(t){case"===":if(typeof e==="object")e=e.version;if(typeof n==="object")n=n.version;return e===n;case"!==":if(typeof e==="object")e=e.version;if(typeof n==="object")n=n.version;return e!==n;case"":case"=":case"==":return Yje(e,n,r);case"!=":return Xje(e,n,r);case">":return Zje(e,n,r);case">=":return eFe(e,n,r);case"<":return tFe(e,n,r);case"<=":return nFe(e,n,r);default:throw TypeError(`Invalid operator: ${t}`)}};aZ.exports=rFe});var yZ=z(function(zxt,mZ){var lv=Symbol("SemVer ANY");class CT{static get ANY(){return lv}constructor(e,t){if(t=cZ(t),e instanceof CT)if(e.loose===!!t.loose)return e;else e=e.value;if(e=e.trim().split(/\s+/).join(" "),_R("comparator",e,t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===lv)this.value="";else this.value=this.operator+this.semver.version;_R("comp",this)}parse(e){let t=this.options.loose?uZ[pZ.COMPARATORLOOSE]:uZ[pZ.COMPARATOR],n=e.match(t);if(!n)throw TypeError(`Invalid comparator: ${e}`);if(this.operator=n[1]!==void 0?n[1]:"",this.operator==="=")this.operator="";if(!n[2])this.semver=lv;else this.semver=new dZ(n[2],this.options.loose)}toString(){return this.value}test(e){if(_R("Comparator.test",e,this.options.loose),this.semver===lv||e===lv)return!0;if(typeof e==="string")try{e=new dZ(e,this.options)}catch(t){return!1}return vR(e,this.operator,this.semver,this.options)}intersects(e,t){if(!(e instanceof CT))throw TypeError("a Comparator is required");if(this.operator===""){if(this.value==="")return!0;return new fZ(e.value,t).test(this.value)}else if(e.operator===""){if(e.value==="")return!0;return new fZ(this.value,t).test(e.semver)}if(t=cZ(t),t.includePrerelease&&(this.value==="<0.0.0-0"||e.value==="<0.0.0-0"))return!1;if(!t.includePrerelease&&(this.value.startsWith("<0.0.0")||e.value.startsWith("<0.0.0")))return!1;if(this.operator.startsWith(">")&&e.operator.startsWith(">"))return!0;if(this.operator.startsWith("<")&&e.operator.startsWith("<"))return!0;if(this.semver.version===e.semver.version&&this.operator.includes("=")&&e.operator.includes("="))return!0;if(vR(this.semver,"<",e.semver,t)&&this.operator.startsWith(">")&&e.operator.startsWith("<"))return!0;if(vR(this.semver,">",e.semver,t)&&this.operator.startsWith("<")&&e.operator.startsWith(">"))return!0;return!1}}mZ.exports=CT;var cZ=IT(),{safeRe:uZ,t:pZ}=$T(),vR=lZ(),_R=ov(),dZ=av(),fZ=xR()});var xR=z(function(Wxt,vZ){var iFe=/\s+/g;class cv{constructor(e,t){if(t=oFe(t),e instanceof cv)if(e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease)return e;else return new cv(e.raw,t);if(e instanceof wR)return this.raw=e.value,this.set=[[e]],this.formatted=void 0,this;if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=e.trim().replace(iFe," "),this.set=this.raw.split("||").map((n)=>this.parseRange(n.trim())).filter((n)=>n.length),!this.set.length)throw TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){let n=this.set[0];if(this.set=this.set.filter((r)=>!gZ(r[0])),this.set.length===0)this.set=[n];else if(this.set.length>1){for(let r of this.set)if(r.length===1&&yFe(r[0])){this.set=[r];break}}}this.formatted=void 0}get range(){if(this.formatted===void 0){this.formatted="";for(let e=0;e0)this.formatted+="||";let t=this.set[e];for(let n=0;n0)this.formatted+=" ";this.formatted+=t[n].toString().trim()}}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(e){e=e.replace(mFe,"");let n=((this.options.includePrerelease&&dFe)|(this.options.loose&&fFe))+":"+e,r=hZ.get(n);if(r)return r;let i=this.options.loose,s=i?es[hi.HYPHENRANGELOOSE]:es[hi.HYPHENRANGE];e=e.replace(s,EFe(this.options.includePrerelease)),zn("hyphen replace",e),e=e.replace(es[hi.COMPARATORTRIM],cFe),zn("comparator trim",e),e=e.replace(es[hi.TILDETRIM],uFe),zn("tilde trim",e),e=e.replace(es[hi.CARETTRIM],pFe),zn("caret trim",e);let o=e.split(" ").map((u)=>hFe(u,this.options)).join(" ").split(/\s+/).map((u)=>SFe(u,this.options));if(i)o=o.filter((u)=>(zn("loose invalid filter",u,this.options),!!u.match(es[hi.COMPARATORLOOSE])));zn("range list",o);let a=new Map,l=o.map((u)=>new wR(u,this.options));for(let u of l){if(gZ(u))return[u];a.set(u.value,u)}if(a.size>1&&a.has(""))a.delete("");let c=[...a.values()];return hZ.set(n,c),c}intersects(e,t){if(!(e instanceof cv))throw TypeError("a Range is required");return this.set.some((n)=>bZ(n,t)&&e.set.some((r)=>bZ(r,t)&&n.every((i)=>r.every((s)=>i.intersects(s,t)))))}test(e){if(!e)return!1;if(typeof e==="string")try{e=new aFe(e,this.options)}catch(t){return!1}for(let t=0;te.value==="<0.0.0-0",yFe=(e)=>e.value==="",bZ=(e,t)=>{let n=!0,r=e.slice(),i=r.pop();while(n&&r.length)n=r.every((s)=>i.intersects(s,t)),i=r.pop();return n},hFe=(e,t)=>(e=e.replace(es[hi.BUILD],""),zn("comp",e,t),e=_Fe(e,t),zn("caret",e),e=bFe(e,t),zn("tildes",e),e=wFe(e,t),zn("xrange",e),e=TFe(e,t),zn("stars",e),e),Br=(e)=>!e||e.toLowerCase()==="x"||e==="*",gFe=(e,t,n)=>Br(e)&&!Br(t)||Br(t)&&n&&!Br(n),bFe=(e,t)=>e.trim().split(/\s+/).map((n)=>vFe(n,t)).join(" "),vFe=(e,t)=>{let n=t.loose?es[hi.TILDELOOSE]:es[hi.TILDE],r=t.includePrerelease?"-0":"";return e.replace(n,(i,s,o,a,l)=>{zn("tilde",e,i,s,o,a,l);let c;if(Br(s))c="";else if(Br(o))c=`>=${s}.0.0${r} <${+s+1}.0.0-0`;else if(Br(a))c=`>=${s}.${o}.0${r} <${s}.${+o+1}.0-0`;else if(l)zn("replaceTilde pr",l),c=`>=${s}.${o}.${a}-${l} <${s}.${+o+1}.0-0`;else c=`>=${s}.${o}.${a} <${s}.${+o+1}.0-0`;return zn("tilde return",c),c})},_Fe=(e,t)=>e.trim().split(/\s+/).map((n)=>xFe(n,t)).join(" "),xFe=(e,t)=>{zn("caret",e,t);let n=t.loose?es[hi.CARETLOOSE]:es[hi.CARET],r=t.includePrerelease?"-0":"";return e.replace(n,(i,s,o,a,l)=>{zn("caret",e,i,s,o,a,l);let c;if(Br(s))c="";else if(Br(o))c=`>=${s}.0.0${r} <${+s+1}.0.0-0`;else if(Br(a))if(s==="0")c=`>=${s}.${o}.0${r} <${s}.${+o+1}.0-0`;else c=`>=${s}.${o}.0${r} <${+s+1}.0.0-0`;else if(l)if(zn("replaceCaret pr",l),s==="0")if(o==="0")c=`>=${s}.${o}.${a}-${l} <${s}.${o}.${+a+1}-0`;else c=`>=${s}.${o}.${a}-${l} <${s}.${+o+1}.0-0`;else c=`>=${s}.${o}.${a}-${l} <${+s+1}.0.0-0`;else if(zn("no pr"),s==="0")if(o==="0")c=`>=${s}.${o}.${a} <${s}.${o}.${+a+1}-0`;else c=`>=${s}.${o}.${a} <${s}.${+o+1}.0-0`;else c=`>=${s}.${o}.${a} <${+s+1}.0.0-0`;return zn("caret return",c),c})},wFe=(e,t)=>(zn("replaceXRanges",e,t),e.split(/\s+/).map((n)=>DFe(n,t)).join(" ")),DFe=(e,t)=>{e=e.trim();let n=t.loose?es[hi.XRANGELOOSE]:es[hi.XRANGE];return e.replace(n,(r,i,s,o,a,l)=>{if(zn("xRange",e,r,i,s,o,a,l),gFe(s,o,a))return e;let c=Br(s),u=c||Br(o),p=u||Br(a),d=p;if(i==="="&&d)i="";if(l=t.includePrerelease?"-0":"",c)if(i===">"||i==="<")r="<0.0.0-0";else r="*";else if(i&&d){if(u)o=0;if(a=0,i===">")if(i=">=",u)s=+s+1,o=0,a=0;else o=+o+1,a=0;else if(i==="<=")if(i="<",u)s=+s+1;else o=+o+1;if(i==="<")l="-0";r=`${i+s}.${o}.${a}${l}`}else if(u)r=`>=${s}.0.0${l} <${+s+1}.0.0-0`;else if(p)r=`>=${s}.${o}.0${l} <${s}.${+o+1}.0-0`;return zn("xRange return",r),r})},TFe=(e,t)=>(zn("replaceStars",e,t),e.trim().replace(es[hi.STAR],"")),SFe=(e,t)=>(zn("replaceGTE0",e,t),e.trim().replace(es[t.includePrerelease?hi.GTE0PRE:hi.GTE0],"")),EFe=(e)=>(t,n,r,i,s,o,a,l,c,u,p,d)=>{if(Br(r))n="";else if(Br(i))n=`>=${r}.0.0${e?"-0":""}`;else if(Br(s))n=`>=${r}.${i}.0${e?"-0":""}`;else if(o)n=`>=${n}`;else n=`>=${n}${e?"-0":""}`;if(Br(c))l="";else if(Br(u))l=`<${+c+1}.0.0-0`;else if(Br(p))l=`<${c}.${+u+1}.0-0`;else if(d)l=`<=${c}.${u}.${p}-${d}`;else if(e)l=`<${c}.${u}.${+p+1}-0`;else l=`<=${l}`;return`${n} ${l}`.trim()},kFe=(e,t,n)=>{for(let r=0;r0){let i=e[r].semver;if(i.major===t.major&&i.minor===t.minor&&i.patch===t.patch)return!0}}return!1}return!0}});var xZ=z(function(Qxt,_Z){var NFe=av(),OFe=xR(),PFe=(e,t,n)=>{let r=null,i=null,s=null;try{s=new OFe(t,n)}catch(o){return null}return e.forEach((o)=>{if(s.test(o)){if(!r||i.compare(o)===-1)r=o,i=new NFe(r,n)}}),r};_Z.exports=PFe});var $Fe;var wZ=q(()=>{$Fe=Ar(xZ(),1)});function DZ(e){let t=e.trim();t=t.replace(IFe,"$1\x00$2").replace(AFe,"$1\x00$2"),t=t.replace(jFe,"\x00");let n=0,r=t.length;while(t.charAt(n)==="\x00")n++;if(n===r)return[];while(t.charAt(r-1)==="\x00")r--;return t.slice(n,r).split(/\0/g)}function FFe(e){let t=DZ(e);for(let n=0;n{if(c===0)return s(l);return a(l,c)}).join(t?.delimiter??"")+i}function SZ(e,t){let[n,r,i]=TR(e,t),s=DR(t?.locale),o=kZ(t?.locale),a=t?.mergeAmbiguousCharacters?NZ(s,o):OZ(s,o);return n+r.map(a).join(t?.delimiter??"")+i}function EZ(e,t){return CFe(e,{delimiter:"-",...t})}function DR(e){return e===!1?(t)=>t.toLowerCase():(t)=>t.toLocaleLowerCase(e)}function kZ(e){return e===!1?(t)=>t.toUpperCase():(t)=>t.toLocaleUpperCase(e)}function NZ(e,t){return(n)=>`${t(n[0])}${e(n.slice(1))}`}function OZ(e,t){return(n,r)=>{let i=n[0];return(r>0&&i>="0"&&i<="9"?"_"+i:t(i))+e(n.slice(1))}}function TR(e,t={}){let n=t.split??(t.separateNumbers?FFe:DZ),r=t.prefixCharacters??"",i=t.suffixCharacters??"",s=0,o=e.length;while(ss){let a=o-1,l=e.charAt(a);if(!i.includes(l))break;o=a}return[e.slice(0,s),n(e.slice(s,o)),e.slice(o)]}var IFe,AFe,RFe,jFe;var PZ=q(()=>{IFe=/([\p{Ll}\d])(\p{Lu})/gu,AFe=/(\p{Lu})([\p{Lu}][\p{Ll}])/gu,RFe=/(\d)\p{Ll}|(\p{L})\d/u,jFe=/[^\p{L}\d]+/giu});function ER(e){return typeof e==="function"}function LFe(e){return Ey(e)?"array":typeof e}function SR(e){return e.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function $Z(e,t){return e!=null&&typeof e==="object"&&t in e}function qFe(e,t){return e!=null&&typeof e!=="object"&&e.hasOwnProperty&&e.hasOwnProperty(t)}function BFe(e,t){return UFe.call(e,t)}function KFe(e){return!BFe(VFe,e)}function GFe(e){return String(e).replace(/[&<>"'`=\/]/g,function(n){return JFe[n]})}function YFe(e,t){if(!e)return[];var n=!1,r=[],i=[],s=[],o=!1,a=!1,l="",c=0;function u(){if(o&&!a)while(s.length)delete i[s.pop()];else s=[];o=!1,a=!1}var p,d,f;function m(O){if(typeof O==="string")O=O.split(zFe,2);if(!Ey(O)||O.length!==2)throw Error("Invalid tags: "+O);p=new RegExp(SR(O[0])+"\\s*"),d=new RegExp("\\s*"+SR(O[1])),f=new RegExp("\\s*"+SR("}"+O[1]))}m(t||Ia.tags);var y=new pv(e),h,b,g,x,v,D;while(!y.eos()){if(h=y.pos,g=y.scanUntil(p),g)for(var T=0,N=g.length;T")v=[b,g,h,y.pos,l,c,n];else v=[b,g,h,y.pos];if(c++,i.push(v),b==="#"||b==="^")r.push(v);else if(b==="/"){if(D=r.pop(),!D)throw Error('Unopened section "'+g+'" at '+h);if(D[1]!==g)throw Error('Unclosed section "'+D[1]+'" at '+h)}else if(b==="name"||b==="{"||b==="&")a=!0;else if(b==="=")m(g)}if(u(),D=r.pop(),D)throw Error('Unclosed section "'+D[1]+'" at '+y.pos);return ZFe(XFe(i))}function XFe(e){var t=[],n,r;for(var i=0,s=e.length;i0?r[r.length-1][4]:t;break;default:n.push(i)}return t}function pv(e){this.string=e,this.tail=e,this.pos=0}function Sy(e,t){this.view=e,this.cache={".":this.view},this.parent=t}function ts(){this.templateCache={_cache:{},set:function(t,n){this._cache[t]=n},get:function(t){return this._cache[t]},clear:function(){this._cache={}}}}var MFe,Ey,UFe,VFe,JFe,HFe,zFe,IZ,WFe,QFe,Ia,uv;var AZ=q(()=>{/*! +`,"\r"];(function(e){function t(s,o,a,l){return new lH(s,o,a,l)}e.create=t;function n(s){let o=s;return oe.defined(o)&&oe.string(o.uri)&&(oe.undefined(o.languageId)||oe.string(o.languageId))&&oe.uinteger(o.lineCount)&&oe.func(o.getText)&&oe.func(o.positionAt)&&oe.func(o.offsetAt)?!0:!1}e.is=n;function r(s,o){let a=s.getText(),l=i(o,(u,p)=>{let d=u.range.start.line-p.range.start.line;if(d===0)return u.range.start.character-p.range.start.character;return d}),c=a.length;for(let u=l.length-1;u>=0;u--){let p=l[u],d=s.offsetAt(p.range.start),f=s.offsetAt(p.range.end);if(f<=c)a=a.substring(0,d)+p.newText+a.substring(f,a.length);else throw Error("Overlapping edit");c=d}return a}e.applyEdits=r;function i(s,o){if(s.length<=1)return s;let a=s.length/2|0,l=s.slice(0,a),c=s.slice(a);i(l,o),i(c,o);let u=0,p=0,d=0;while(u"u"}e.undefined=r;function i(f){return f===!0||f===!1}e.boolean=i;function s(f){return t.call(f)==="[object String]"}e.string=s;function o(f){return t.call(f)==="[object Number]"}e.number=o;function a(f,m,y){return t.call(f)==="[object Number]"&&m<=f&&f<=y}e.numberRange=a;function l(f){return t.call(f)==="[object Number]"&&-2147483648<=f&&f<=2147483647}e.integer=l;function c(f){return t.call(f)==="[object Number]"&&0<=f&&f<=2147483647}e.uinteger=c;function u(f){return t.call(f)==="[object Function]"}e.func=u;function p(f){return f!==null&&typeof f==="object"}e.objectLiteral=p;function d(f,m){return Array.isArray(f)&&f.every(m)}e.typedArray=d})(oe||(oe={}))});var Hn=z(function(gH){Object.defineProperty(gH,"__esModule",{value:!0});gH.CM=gH.ProtocolNotificationType=gH.ProtocolNotificationType0=gH.ProtocolRequestType=gH.ProtocolRequestType0=gH.RegistrationType=gH.MessageDirection=void 0;var vy=yy(),uH;(function(e){e.clientToServer="clientToServer",e.serverToClient="serverToClient",e.both="both"})(uH||(gH.MessageDirection=uH={}));class dH{____;method;constructor(e){this.method=e}}gH.RegistrationType=dH;class fH extends vy.RequestType0{__;___;____;_pr;constructor(e){super(e)}}gH.ProtocolRequestType0=fH;class mH extends vy.RequestType{__;___;____;_pr;constructor(e){super(e,vy.ParameterStructures.byName)}}gH.ProtocolRequestType=mH;class yH extends vy.NotificationType0{___;____;constructor(e){super(e)}}gH.ProtocolNotificationType0=yH;class hH extends vy.NotificationType{___;____;constructor(e){super(e,vy.ParameterStructures.byName)}}gH.ProtocolNotificationType=hH;var pH;(function(e){function t(n,r){return{client:n,server:r}}e.create=t})(pH||(gH.CM=pH={}))});var vT=z(function(xH){Object.defineProperty(xH,"__esModule",{value:!0});xH.boolean=AIe;xH.string=vH;xH.number=RIe;xH.error=jIe;xH.func=FIe;xH.array=_H;xH.stringArray=CIe;xH.typedArray=MIe;xH.objectLiteral=LIe;function AIe(e){return e===!0||e===!1}function vH(e){return typeof e==="string"||e instanceof String}function RIe(e){return typeof e==="number"||e instanceof Number}function jIe(e){return e instanceof Error}function FIe(e){return typeof e==="function"}function _H(e){return Array.isArray(e)}function CIe(e){return _H(e)&&e.every((t)=>vH(t))}function MIe(e,t){return Array.isArray(e)&&e.every(t)}function LIe(e){return e!==null&&typeof e==="object"}});var SH=z(function(DH){Object.defineProperty(DH,"__esModule",{value:!0});DH.ImplementationRequest=void 0;var TA=Hn(),wH;(function(e){e.method="textDocument/implementation",e.messageDirection=TA.MessageDirection.clientToServer,e.type=new TA.ProtocolRequestType(e.method),e.capabilities=TA.CM.create("textDocument.implementation","implementationProvider")})(wH||(DH.ImplementationRequest=wH={}))});var OH=z(function(kH){Object.defineProperty(kH,"__esModule",{value:!0});kH.TypeDefinitionRequest=void 0;var SA=Hn(),EH;(function(e){e.method="textDocument/typeDefinition",e.messageDirection=SA.MessageDirection.clientToServer,e.type=new SA.ProtocolRequestType(e.method),e.capabilities=SA.CM.create("textDocument.typeDefinition","typeDefinitionProvider")})(EH||(kH.TypeDefinitionRequest=EH={}))});var RH=z(function(IH){Object.defineProperty(IH,"__esModule",{value:!0});IH.DidChangeWorkspaceFoldersNotification=IH.WorkspaceFoldersRequest=void 0;var _y=Hn(),PH;(function(e){e.method="workspace/workspaceFolders",e.messageDirection=_y.MessageDirection.serverToClient,e.type=new _y.ProtocolRequestType0(e.method),e.capabilities=_y.CM.create("workspace.workspaceFolders","workspace.workspaceFolders")})(PH||(IH.WorkspaceFoldersRequest=PH={}));var $H;(function(e){e.method="workspace/didChangeWorkspaceFolders",e.messageDirection=_y.MessageDirection.clientToServer,e.type=new _y.ProtocolNotificationType(e.method),e.capabilities=_y.CM.create(void 0,"workspace.workspaceFolders.changeNotifications")})($H||(IH.DidChangeWorkspaceFoldersNotification=$H={}))});var MH=z(function(FH){Object.defineProperty(FH,"__esModule",{value:!0});FH.ConfigurationRequest=void 0;var EA=Hn(),jH;(function(e){e.method="workspace/configuration",e.messageDirection=EA.MessageDirection.serverToClient,e.type=new EA.ProtocolRequestType(e.method),e.capabilities=EA.CM.create("workspace.configuration",void 0)})(jH||(FH.ConfigurationRequest=jH={}))});var VH=z(function(UH){Object.defineProperty(UH,"__esModule",{value:!0});UH.ColorPresentationRequest=UH.DocumentColorRequest=void 0;var xy=Hn(),LH;(function(e){e.method="textDocument/documentColor",e.messageDirection=xy.MessageDirection.clientToServer,e.type=new xy.ProtocolRequestType(e.method),e.capabilities=xy.CM.create("textDocument.colorProvider","colorProvider")})(LH||(UH.DocumentColorRequest=LH={}));var qH;(function(e){e.method="textDocument/colorPresentation",e.messageDirection=xy.MessageDirection.clientToServer,e.type=new xy.ProtocolRequestType(e.method),e.capabilities=xy.CM.create("textDocument.colorProvider","colorProvider")})(qH||(UH.ColorPresentationRequest=qH={}))});var zH=z(function(GH){Object.defineProperty(GH,"__esModule",{value:!0});GH.FoldingRangeRefreshRequest=GH.FoldingRangeRequest=void 0;var wy=Hn(),KH;(function(e){e.method="textDocument/foldingRange",e.messageDirection=wy.MessageDirection.clientToServer,e.type=new wy.ProtocolRequestType(e.method),e.capabilities=wy.CM.create("textDocument.foldingRange","foldingRangeProvider")})(KH||(GH.FoldingRangeRequest=KH={}));var JH;(function(e){e.method="workspace/foldingRange/refresh",e.messageDirection=wy.MessageDirection.serverToClient,e.type=new wy.ProtocolRequestType0(e.method),e.capabilities=wy.CM.create("workspace.foldingRange.refreshSupport",void 0)})(JH||(GH.FoldingRangeRefreshRequest=JH={}))});var XH=z(function(QH){Object.defineProperty(QH,"__esModule",{value:!0});QH.DeclarationRequest=void 0;var kA=Hn(),WH;(function(e){e.method="textDocument/declaration",e.messageDirection=kA.MessageDirection.clientToServer,e.type=new kA.ProtocolRequestType(e.method),e.capabilities=kA.CM.create("textDocument.declaration","declarationProvider")})(WH||(QH.DeclarationRequest=WH={}))});var nz=z(function(ez){Object.defineProperty(ez,"__esModule",{value:!0});ez.SelectionRangeRequest=void 0;var NA=Hn(),ZH;(function(e){e.method="textDocument/selectionRange",e.messageDirection=NA.MessageDirection.clientToServer,e.type=new NA.ProtocolRequestType(e.method),e.capabilities=NA.CM.create("textDocument.selectionRange","selectionRangeProvider")})(ZH||(ez.SelectionRangeRequest=ZH={}))});var lz=z(function(oz){Object.defineProperty(oz,"__esModule",{value:!0});oz.WorkDoneProgressCancelNotification=oz.WorkDoneProgressCreateRequest=oz.WorkDoneProgress=void 0;var XIe=yy(),ev=Hn(),rz;(function(e){e.type=new XIe.ProgressType;function t(n){return n===e.type}e.is=t})(rz||(oz.WorkDoneProgress=rz={}));var iz;(function(e){e.method="window/workDoneProgress/create",e.messageDirection=ev.MessageDirection.serverToClient,e.type=new ev.ProtocolRequestType(e.method),e.capabilities=ev.CM.create("window.workDoneProgress",void 0)})(iz||(oz.WorkDoneProgressCreateRequest=iz={}));var sz;(function(e){e.method="window/workDoneProgress/cancel",e.messageDirection=ev.MessageDirection.clientToServer,e.type=new ev.ProtocolNotificationType(e.method)})(sz||(oz.WorkDoneProgressCancelNotification=sz={}))});var mz=z(function(dz){Object.defineProperty(dz,"__esModule",{value:!0});dz.CallHierarchyOutgoingCallsRequest=dz.CallHierarchyIncomingCallsRequest=dz.CallHierarchyPrepareRequest=void 0;var Ec=Hn(),cz;(function(e){e.method="textDocument/prepareCallHierarchy",e.messageDirection=Ec.MessageDirection.clientToServer,e.type=new Ec.ProtocolRequestType(e.method),e.capabilities=Ec.CM.create("textDocument.callHierarchy","callHierarchyProvider")})(cz||(dz.CallHierarchyPrepareRequest=cz={}));var uz;(function(e){e.method="callHierarchy/incomingCalls",e.messageDirection=Ec.MessageDirection.clientToServer,e.type=new Ec.ProtocolRequestType(e.method),e.capabilities=Ec.CM.create("textDocument.callHierarchy","callHierarchyProvider")})(uz||(dz.CallHierarchyIncomingCallsRequest=uz={}));var pz;(function(e){e.method="callHierarchy/outgoingCalls",e.messageDirection=Ec.MessageDirection.clientToServer,e.type=new Ec.ProtocolRequestType(e.method),e.capabilities=Ec.CM.create("textDocument.callHierarchy","callHierarchyProvider")})(pz||(dz.CallHierarchyOutgoingCallsRequest=pz={}))});var wz=z(function(_z){Object.defineProperty(_z,"__esModule",{value:!0});_z.SemanticTokensRefreshRequest=_z.SemanticTokensRangeRequest=_z.SemanticTokensDeltaRequest=_z.SemanticTokensRequest=_z.SemanticTokensRegistrationType=_z.TokenFormat=void 0;var io=Hn(),yz;(function(e){e.Relative="relative"})(yz||(_z.TokenFormat=yz={}));var tv;(function(e){e.method="textDocument/semanticTokens",e.type=new io.RegistrationType(e.method)})(tv||(_z.SemanticTokensRegistrationType=tv={}));var hz;(function(e){e.method="textDocument/semanticTokens/full",e.messageDirection=io.MessageDirection.clientToServer,e.type=new io.ProtocolRequestType(e.method),e.registrationMethod=tv.method,e.capabilities=io.CM.create("textDocument.semanticTokens","semanticTokensProvider")})(hz||(_z.SemanticTokensRequest=hz={}));var gz;(function(e){e.method="textDocument/semanticTokens/full/delta",e.messageDirection=io.MessageDirection.clientToServer,e.type=new io.ProtocolRequestType(e.method),e.registrationMethod=tv.method,e.capabilities=io.CM.create("textDocument.semanticTokens.requests.full.delta","semanticTokensProvider.full.delta")})(gz||(_z.SemanticTokensDeltaRequest=gz={}));var bz;(function(e){e.method="textDocument/semanticTokens/range",e.messageDirection=io.MessageDirection.clientToServer,e.type=new io.ProtocolRequestType(e.method),e.registrationMethod=tv.method,e.capabilities=io.CM.create("textDocument.semanticTokens.requests.range","semanticTokensProvider.range")})(bz||(_z.SemanticTokensRangeRequest=bz={}));var vz;(function(e){e.method="workspace/semanticTokens/refresh",e.messageDirection=io.MessageDirection.serverToClient,e.type=new io.ProtocolRequestType0(e.method),e.capabilities=io.CM.create("workspace.semanticTokens.refreshSupport",void 0)})(vz||(_z.SemanticTokensRefreshRequest=vz={}))});var Ez=z(function(Tz){Object.defineProperty(Tz,"__esModule",{value:!0});Tz.ShowDocumentRequest=void 0;var OA=Hn(),Dz;(function(e){e.method="window/showDocument",e.messageDirection=OA.MessageDirection.serverToClient,e.type=new OA.ProtocolRequestType(e.method),e.capabilities=OA.CM.create("window.showDocument.support",void 0)})(Dz||(Tz.ShowDocumentRequest=Dz={}))});var Pz=z(function(Nz){Object.defineProperty(Nz,"__esModule",{value:!0});Nz.LinkedEditingRangeRequest=void 0;var PA=Hn(),kz;(function(e){e.method="textDocument/linkedEditingRange",e.messageDirection=PA.MessageDirection.clientToServer,e.type=new PA.ProtocolRequestType(e.method),e.capabilities=PA.CM.create("textDocument.linkedEditingRange","linkedEditingRangeProvider")})(kz||(Nz.LinkedEditingRangeRequest=kz={}))});var qz=z(function(Mz){Object.defineProperty(Mz,"__esModule",{value:!0});Mz.WillDeleteFilesRequest=Mz.DidDeleteFilesNotification=Mz.DidRenameFilesNotification=Mz.WillRenameFilesRequest=Mz.DidCreateFilesNotification=Mz.WillCreateFilesRequest=Mz.FileOperationPatternKind=void 0;var ni=Hn(),$z;(function(e){e.file="file",e.folder="folder"})($z||(Mz.FileOperationPatternKind=$z={}));var Iz;(function(e){e.method="workspace/willCreateFiles",e.messageDirection=ni.MessageDirection.clientToServer,e.type=new ni.ProtocolRequestType(e.method),e.capabilities=ni.CM.create("workspace.fileOperations.willCreate","workspace.fileOperations.willCreate")})(Iz||(Mz.WillCreateFilesRequest=Iz={}));var Az;(function(e){e.method="workspace/didCreateFiles",e.messageDirection=ni.MessageDirection.clientToServer,e.type=new ni.ProtocolNotificationType(e.method),e.capabilities=ni.CM.create("workspace.fileOperations.didCreate","workspace.fileOperations.didCreate")})(Az||(Mz.DidCreateFilesNotification=Az={}));var Rz;(function(e){e.method="workspace/willRenameFiles",e.messageDirection=ni.MessageDirection.clientToServer,e.type=new ni.ProtocolRequestType(e.method),e.capabilities=ni.CM.create("workspace.fileOperations.willRename","workspace.fileOperations.willRename")})(Rz||(Mz.WillRenameFilesRequest=Rz={}));var jz;(function(e){e.method="workspace/didRenameFiles",e.messageDirection=ni.MessageDirection.clientToServer,e.type=new ni.ProtocolNotificationType(e.method),e.capabilities=ni.CM.create("workspace.fileOperations.didRename","workspace.fileOperations.didRename")})(jz||(Mz.DidRenameFilesNotification=jz={}));var Fz;(function(e){e.method="workspace/didDeleteFiles",e.messageDirection=ni.MessageDirection.clientToServer,e.type=new ni.ProtocolNotificationType(e.method),e.capabilities=ni.CM.create("workspace.fileOperations.didDelete","workspace.fileOperations.didDelete")})(Fz||(Mz.DidDeleteFilesNotification=Fz={}));var Cz;(function(e){e.method="workspace/willDeleteFiles",e.messageDirection=ni.MessageDirection.clientToServer,e.type=new ni.ProtocolRequestType(e.method),e.capabilities=ni.CM.create("workspace.fileOperations.willDelete","workspace.fileOperations.willDelete")})(Cz||(Mz.WillDeleteFilesRequest=Cz={}))});var Gz=z(function(Kz){Object.defineProperty(Kz,"__esModule",{value:!0});Kz.MonikerRequest=Kz.MonikerKind=Kz.UniquenessLevel=void 0;var $A=Hn(),Uz;(function(e){e.document="document",e.project="project",e.group="group",e.scheme="scheme",e.global="global"})(Uz||(Kz.UniquenessLevel=Uz={}));var Bz;(function(e){e.$import="import",e.$export="export",e.local="local"})(Bz||(Kz.MonikerKind=Bz={}));var Vz;(function(e){e.method="textDocument/moniker",e.messageDirection=$A.MessageDirection.clientToServer,e.type=new $A.ProtocolRequestType(e.method),e.capabilities=$A.CM.create("textDocument.moniker","monikerProvider")})(Vz||(Kz.MonikerRequest=Vz={}))});var Xz=z(function(Qz){Object.defineProperty(Qz,"__esModule",{value:!0});Qz.TypeHierarchySubtypesRequest=Qz.TypeHierarchySupertypesRequest=Qz.TypeHierarchyPrepareRequest=void 0;var ef=Hn(),Hz;(function(e){e.method="textDocument/prepareTypeHierarchy",e.messageDirection=ef.MessageDirection.clientToServer,e.type=new ef.ProtocolRequestType(e.method),e.capabilities=ef.CM.create("textDocument.typeHierarchy","typeHierarchyProvider")})(Hz||(Qz.TypeHierarchyPrepareRequest=Hz={}));var zz;(function(e){e.method="typeHierarchy/supertypes",e.messageDirection=ef.MessageDirection.clientToServer,e.type=new ef.ProtocolRequestType(e.method)})(zz||(Qz.TypeHierarchySupertypesRequest=zz={}));var Wz;(function(e){e.method="typeHierarchy/subtypes",e.messageDirection=ef.MessageDirection.clientToServer,e.type=new ef.ProtocolRequestType(e.method)})(Wz||(Qz.TypeHierarchySubtypesRequest=Wz={}))});var rW=z(function(tW){Object.defineProperty(tW,"__esModule",{value:!0});tW.InlineValueRefreshRequest=tW.InlineValueRequest=void 0;var Dy=Hn(),Zz;(function(e){e.method="textDocument/inlineValue",e.messageDirection=Dy.MessageDirection.clientToServer,e.type=new Dy.ProtocolRequestType(e.method),e.capabilities=Dy.CM.create("textDocument.inlineValue","inlineValueProvider")})(Zz||(tW.InlineValueRequest=Zz={}));var eW;(function(e){e.method="workspace/inlineValue/refresh",e.messageDirection=Dy.MessageDirection.serverToClient,e.type=new Dy.ProtocolRequestType0(e.method),e.capabilities=Dy.CM.create("workspace.inlineValue.refreshSupport",void 0)})(eW||(tW.InlineValueRefreshRequest=eW={}))});var cW=z(function(aW){Object.defineProperty(aW,"__esModule",{value:!0});aW.InlayHintRefreshRequest=aW.InlayHintResolveRequest=aW.InlayHintRequest=void 0;var kc=Hn(),iW;(function(e){e.method="textDocument/inlayHint",e.messageDirection=kc.MessageDirection.clientToServer,e.type=new kc.ProtocolRequestType(e.method),e.capabilities=kc.CM.create("textDocument.inlayHint","inlayHintProvider")})(iW||(aW.InlayHintRequest=iW={}));var sW;(function(e){e.method="inlayHint/resolve",e.messageDirection=kc.MessageDirection.clientToServer,e.type=new kc.ProtocolRequestType(e.method),e.capabilities=kc.CM.create("textDocument.inlayHint.resolveSupport","inlayHintProvider.resolveProvider")})(sW||(aW.InlayHintResolveRequest=sW={}));var oW;(function(e){e.method="workspace/inlayHint/refresh",e.messageDirection=kc.MessageDirection.serverToClient,e.type=new kc.ProtocolRequestType0(e.method),e.capabilities=kc.CM.create("workspace.inlayHint.refreshSupport",void 0)})(oW||(aW.InlayHintRefreshRequest=oW={}))});var hW=z(function(ri){var xAe=ri&&ri.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),wAe=ri&&ri.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),DAe=ri&&ri.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;i0}e.hasId=t})(LW||(F.StaticRegistrationOptions=LW={}));var qW;(function(e){function t(n){let r=n;return r&&(r.documentSelector===null||MA.is(r.documentSelector))}e.is=t})(qW||(F.TextDocumentRegistrationOptions=qW={}));var UW;(function(e){function t(r){let i=r;return ii.objectLiteral(i)&&(i.workDoneProgress===void 0||ii.boolean(i.workDoneProgress))}e.is=t;function n(r){let i=r;return i&&ii.boolean(i.workDoneProgress)}e.hasWorkDoneProgress=n})(UW||(F.WorkDoneProgressOptions=UW={}));var BW;(function(e){e.method="initialize",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method)})(BW||(F.InitializeRequest=BW={}));var VW;(function(e){e.unknownProtocolVersion=1})(VW||(F.InitializeErrorCodes=VW={}));var KW;(function(e){e.method="initialized",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method)})(KW||(F.InitializedNotification=KW={}));var JW;(function(e){e.method="shutdown",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType0(e.method)})(JW||(F.ShutdownRequest=JW={}));var GW;(function(e){e.method="exit",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType0(e.method)})(GW||(F.ExitNotification=GW={}));var HW;(function(e){e.method="workspace/didChangeConfiguration",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("workspace.didChangeConfiguration",void 0)})(HW||(F.DidChangeConfigurationNotification=HW={}));var zW;(function(e){e.Error=1,e.Warning=2,e.Info=3,e.Log=4,e.Debug=5})(zW||(F.MessageType=zW={}));var WW;(function(e){e.method="window/showMessage",e.messageDirection=De.MessageDirection.serverToClient,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("window.showMessage",void 0)})(WW||(F.ShowMessageNotification=WW={}));var QW;(function(e){e.method="window/showMessageRequest",e.messageDirection=De.MessageDirection.serverToClient,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("window.showMessage",void 0)})(QW||(F.ShowMessageRequest=QW={}));var YW;(function(e){e.method="window/logMessage",e.messageDirection=De.MessageDirection.serverToClient,e.type=new De.ProtocolNotificationType(e.method)})(YW||(F.LogMessageNotification=YW={}));var XW;(function(e){e.method="telemetry/event",e.messageDirection=De.MessageDirection.serverToClient,e.type=new De.ProtocolNotificationType(e.method)})(XW||(F.TelemetryEventNotification=XW={}));var ZW;(function(e){e.None=0,e.Full=1,e.Incremental=2})(ZW||(F.TextDocumentSyncKind=ZW={}));var eQ;(function(e){e.method="textDocument/didOpen",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("textDocument.synchronization","textDocumentSync.openClose")})(eQ||(F.DidOpenTextDocumentNotification=eQ={}));var tQ;(function(e){function t(r){let i=r;return i!==void 0&&i!==null&&typeof i.text==="string"&&i.range!==void 0&&(i.rangeLength===void 0||typeof i.rangeLength==="number")}e.isIncremental=t;function n(r){let i=r;return i!==void 0&&i!==null&&typeof i.text==="string"&&i.range===void 0&&i.rangeLength===void 0}e.isFull=n})(tQ||(F.TextDocumentContentChangeEvent=tQ={}));var nQ;(function(e){e.method="textDocument/didChange",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("textDocument.synchronization","textDocumentSync")})(nQ||(F.DidChangeTextDocumentNotification=nQ={}));var rQ;(function(e){e.method="textDocument/didClose",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("textDocument.synchronization","textDocumentSync.openClose")})(rQ||(F.DidCloseTextDocumentNotification=rQ={}));var iQ;(function(e){e.method="textDocument/didSave",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("textDocument.synchronization.didSave","textDocumentSync.save")})(iQ||(F.DidSaveTextDocumentNotification=iQ={}));var sQ;(function(e){e.Manual=1,e.AfterDelay=2,e.FocusOut=3})(sQ||(F.TextDocumentSaveReason=sQ={}));var oQ;(function(e){e.method="textDocument/willSave",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("textDocument.synchronization.willSave","textDocumentSync.willSave")})(oQ||(F.WillSaveTextDocumentNotification=oQ={}));var aQ;(function(e){e.method="textDocument/willSaveWaitUntil",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.synchronization.willSaveWaitUntil","textDocumentSync.willSaveWaitUntil")})(aQ||(F.WillSaveTextDocumentWaitUntilRequest=aQ={}));var lQ;(function(e){e.method="workspace/didChangeWatchedFiles",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("workspace.didChangeWatchedFiles",void 0)})(lQ||(F.DidChangeWatchedFilesNotification=lQ={}));var cQ;(function(e){e.Created=1,e.Changed=2,e.Deleted=3})(cQ||(F.FileChangeType=cQ={}));var LA;(function(e){function t(n){let r=n;return ii.objectLiteral(r)&&(Hb.is(r.baseUri)||gT.is(r.baseUri))&&ii.string(r.pattern)}e.is=t})(LA||(F.RelativePattern=LA={}));var qA;(function(e){function t(n){let r=n;return ii.string(r)||LA.is(r)}e.is=t})(qA||(F.GlobPattern=qA={}));var uQ;(function(e){e.Create=1,e.Change=2,e.Delete=4})(uQ||(F.WatchKind=uQ={}));var pQ;(function(e){e.method="textDocument/publishDiagnostics",e.messageDirection=De.MessageDirection.serverToClient,e.type=new De.ProtocolNotificationType(e.method),e.capabilities=De.CM.create("textDocument.publishDiagnostics",void 0)})(pQ||(F.PublishDiagnosticsNotification=pQ={}));var dQ;(function(e){e.Invoked=1,e.TriggerCharacter=2,e.TriggerForIncompleteCompletions=3})(dQ||(F.CompletionTriggerKind=dQ={}));var fQ;(function(e){e.method="textDocument/completion",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.completion","completionProvider")})(fQ||(F.CompletionRequest=fQ={}));var mQ;(function(e){e.method="completionItem/resolve",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.completion.completionItem.resolveSupport","completionProvider.resolveProvider")})(mQ||(F.CompletionResolveRequest=mQ={}));var yQ;(function(e){e.method="textDocument/hover",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.hover","hoverProvider")})(yQ||(F.HoverRequest=yQ={}));var hQ;(function(e){e.Invoked=1,e.TriggerCharacter=2,e.ContentChange=3})(hQ||(F.SignatureHelpTriggerKind=hQ={}));var gQ;(function(e){e.method="textDocument/signatureHelp",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.signatureHelp","signatureHelpProvider")})(gQ||(F.SignatureHelpRequest=gQ={}));var bQ;(function(e){e.method="textDocument/definition",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.definition","definitionProvider")})(bQ||(F.DefinitionRequest=bQ={}));var vQ;(function(e){e.method="textDocument/references",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.references","referencesProvider")})(vQ||(F.ReferencesRequest=vQ={}));var _Q;(function(e){e.method="textDocument/documentHighlight",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.documentHighlight","documentHighlightProvider")})(_Q||(F.DocumentHighlightRequest=_Q={}));var xQ;(function(e){e.method="textDocument/documentSymbol",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.documentSymbol","documentSymbolProvider")})(xQ||(F.DocumentSymbolRequest=xQ={}));var wQ;(function(e){e.method="textDocument/codeAction",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.codeAction","codeActionProvider")})(wQ||(F.CodeActionRequest=wQ={}));var DQ;(function(e){e.method="codeAction/resolve",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.codeAction.resolveSupport","codeActionProvider.resolveProvider")})(DQ||(F.CodeActionResolveRequest=DQ={}));var TQ;(function(e){e.method="workspace/symbol",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("workspace.symbol","workspaceSymbolProvider")})(TQ||(F.WorkspaceSymbolRequest=TQ={}));var SQ;(function(e){e.method="workspaceSymbol/resolve",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("workspace.symbol.resolveSupport","workspaceSymbolProvider.resolveProvider")})(SQ||(F.WorkspaceSymbolResolveRequest=SQ={}));var EQ;(function(e){e.method="textDocument/codeLens",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.codeLens","codeLensProvider")})(EQ||(F.CodeLensRequest=EQ={}));var kQ;(function(e){e.method="codeLens/resolve",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.codeLens.resolveSupport","codeLensProvider.resolveProvider")})(kQ||(F.CodeLensResolveRequest=kQ={}));var NQ;(function(e){e.method="workspace/codeLens/refresh",e.messageDirection=De.MessageDirection.serverToClient,e.type=new De.ProtocolRequestType0(e.method),e.capabilities=De.CM.create("workspace.codeLens",void 0)})(NQ||(F.CodeLensRefreshRequest=NQ={}));var OQ;(function(e){e.method="textDocument/documentLink",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.documentLink","documentLinkProvider")})(OQ||(F.DocumentLinkRequest=OQ={}));var PQ;(function(e){e.method="documentLink/resolve",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.documentLink","documentLinkProvider.resolveProvider")})(PQ||(F.DocumentLinkResolveRequest=PQ={}));var $Q;(function(e){e.method="textDocument/formatting",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.formatting","documentFormattingProvider")})($Q||(F.DocumentFormattingRequest=$Q={}));var IQ;(function(e){e.method="textDocument/rangeFormatting",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.rangeFormatting","documentRangeFormattingProvider")})(IQ||(F.DocumentRangeFormattingRequest=IQ={}));var AQ;(function(e){e.method="textDocument/rangesFormatting",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.rangeFormatting.rangesSupport","documentRangeFormattingProvider.rangesSupport")})(AQ||(F.DocumentRangesFormattingRequest=AQ={}));var RQ;(function(e){e.method="textDocument/onTypeFormatting",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.onTypeFormatting","documentOnTypeFormattingProvider")})(RQ||(F.DocumentOnTypeFormattingRequest=RQ={}));var jQ;(function(e){e.Identifier=1})(jQ||(F.PrepareSupportDefaultBehavior=jQ={}));var FQ;(function(e){e.method="textDocument/rename",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.rename","renameProvider")})(FQ||(F.RenameRequest=FQ={}));var CQ;(function(e){e.method="textDocument/prepareRename",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("textDocument.rename.prepareSupport","renameProvider.prepareProvider")})(CQ||(F.PrepareRenameRequest=CQ={}));var MQ;(function(e){e.method="workspace/executeCommand",e.messageDirection=De.MessageDirection.clientToServer,e.type=new De.ProtocolRequestType(e.method),e.capabilities=De.CM.create("workspace.executeCommand","executeCommandProvider")})(MQ||(F.ExecuteCommandRequest=MQ={}));var LQ;(function(e){e.method="workspace/applyEdit",e.messageDirection=De.MessageDirection.serverToClient,e.type=new De.ProtocolRequestType("workspace/applyEdit"),e.capabilities=De.CM.create("workspace.applyEdit",void 0)})(LQ||(F.ApplyWorkspaceEditRequest=LQ={}))});var zQ=z(function(HQ){Object.defineProperty(HQ,"__esModule",{value:!0});HQ.createProtocolConnection=qAe;var GQ=yy();function qAe(e,t,n,r){if(GQ.ConnectionStrategy.is(r))r={connectionStrategy:r};return GQ.createMessageConnection(e,t,n,r)}});var gr=z(function(Is){var BAe=Is&&Is.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),xT=Is&&Is.__exportStar||function(e,t){for(var n in e)if(n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n))BAe(t,e,n)};Object.defineProperty(Is,"__esModule",{value:!0});Is.LSPErrorCodes=Is.createProtocolConnection=void 0;xT(yy(),Is);xT((bT(),Nf(cH)),Is);xT(Hn(),Is);xT(JQ(),Is);var VAe=zQ();Object.defineProperty(Is,"createProtocolConnection",{enumerable:!0,get:function(){return VAe.createProtocolConnection}});var WQ;(function(e){e.lspReservedErrorRangeStart=-32899,e.RequestFailed=-32803,e.ServerCancelled=-32802,e.ContentModified=-32801,e.RequestCancelled=-32800,e.lspReservedErrorRangeEnd=-32800})(WQ||(Is.LSPErrorCodes=WQ={}))});var HA=z(function(QQ){Object.defineProperty(QQ,"__esModule",{value:!0});QQ.SemanticTokensBuilder=QQ.SemanticTokensDiff=QQ.SemanticTokensFeature=void 0;var DT=gr(),KAe=(e)=>class extends e{get semanticTokens(){return{refresh:()=>this.connection.sendRequest(DT.SemanticTokensRefreshRequest.type),on:(t)=>{let n=DT.SemanticTokensRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onDelta:(t)=>{let n=DT.SemanticTokensDeltaRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onRange:(t)=>{let n=DT.SemanticTokensRangeRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};QQ.SemanticTokensFeature=KAe;class GA{originalSequence;modifiedSequence;constructor(e,t){this.originalSequence=e,this.modifiedSequence=t}computeDiff(){let e=this.originalSequence.length,t=this.modifiedSequence.length,n=0;while(n=n&&i>=n&&this.originalSequence[r]===this.modifiedSequence[i])r--,i--;if(r0){if(s-=this._prevLine,s===0)o-=this._prevChar}let a=this._dataIsSortedAndDeltaEncoded?this._data:this._dataNonDelta;a[this._dataLen++]=s,a[this._dataLen++]=o,a[this._dataLen++]=n,a[this._dataLen++]=r,a[this._dataLen++]=i,this._prevLine=e,this._prevChar=t}get id(){return this._id.toString()}static _deltaDecode(e){let t=e.length/5|0,n=0,r=0,i=[];for(let s=0;s{let l=e[5*o],c=e[5*a];if(l===c){let u=e[5*o+1],p=e[5*a+1];return u-p}return l-c});let r=[],i=0,s=0;for(let o=0;o{let r=n.textDocument,i=this._configuration.create(r.uri,r.languageId,r.version,r.text);this._syncedDocuments.set(r.uri,i);let s=Object.freeze({document:i});this._onDidOpen.fire(s),this._onDidChangeContent.fire(s)})),t.push(e.onDidChangeTextDocument((n)=>{let{textDocument:r,contentChanges:i}=n;if(i.length===0)return;let{version:s}=r;if(s===null||s===void 0)throw Error(`Received document change event for ${r.uri} without valid version identifier`);let o=this._syncedDocuments.get(r.uri);if(o!==void 0)o=this._configuration.update(o,i,s),this._syncedDocuments.set(r.uri,o),this._onDidChangeContent.fire(Object.freeze({document:o}))})),t.push(e.onDidCloseTextDocument((n)=>{let r=this._syncedDocuments.get(n.textDocument.uri);if(r!==void 0)this._syncedDocuments.delete(n.textDocument.uri),this._onDidClose.fire(Object.freeze({document:r}))})),t.push(e.onWillSaveTextDocument((n)=>{let r=this._syncedDocuments.get(n.textDocument.uri);if(r!==void 0)this._onWillSave.fire(Object.freeze({document:r,reason:n.reason}))})),t.push(e.onWillSaveTextDocumentWaitUntil((n,r)=>{let i=this._syncedDocuments.get(n.textDocument.uri);if(i!==void 0&&this._willSaveWaitUntil)return this._willSaveWaitUntil(Object.freeze({document:i,reason:n.reason}),r);else return[]})),t.push(e.onDidSaveTextDocument((n)=>{let r=this._syncedDocuments.get(n.textDocument.uri);if(r!==void 0)this._onDidSave.fire(Object.freeze({document:r}))})),nf.Disposable.create(()=>{t.forEach((n)=>n.dispose())})}}ZQ.TextDocuments=XQ});var WA=z(function(rY){Object.defineProperty(rY,"__esModule",{value:!0});rY.NotebookDocuments=rY.NotebookSyncFeature=void 0;var Wo=gr(),tY=zA(),HAe=(e)=>class extends e{get synchronization(){return{onDidOpenNotebookDocument:(t)=>this.connection.onNotification(Wo.DidOpenNotebookDocumentNotification.type,(n)=>t(n)),onDidChangeNotebookDocument:(t)=>this.connection.onNotification(Wo.DidChangeNotebookDocumentNotification.type,(n)=>t(n)),onDidSaveNotebookDocument:(t)=>this.connection.onNotification(Wo.DidSaveNotebookDocumentNotification.type,(n)=>t(n)),onDidCloseNotebookDocument:(t)=>this.connection.onNotification(Wo.DidCloseNotebookDocumentNotification.type,(n)=>t(n))}}};rY.NotebookSyncFeature=HAe;class iv{static NULL_DISPOSE=Object.freeze({dispose:()=>{}});openHandler;changeHandler;closeHandler;onDidOpenTextDocument(e){return this.openHandler=e,Wo.Disposable.create(()=>{this.openHandler=void 0})}openTextDocument(e){return this.openHandler&&this.openHandler(e)}onDidChangeTextDocument(e){return this.changeHandler=e,Wo.Disposable.create(()=>{this.changeHandler=e})}changeTextDocument(e){return this.changeHandler&&this.changeHandler(e)}onDidCloseTextDocument(e){return this.closeHandler=e,Wo.Disposable.create(()=>{this.closeHandler=void 0})}closeTextDocument(e){return this.closeHandler&&this.closeHandler(e)}onWillSaveTextDocument(){return iv.NULL_DISPOSE}onWillSaveTextDocumentWaitUntil(){return iv.NULL_DISPOSE}onDidSaveTextDocument(){return iv.NULL_DISPOSE}}class nY{notebookDocuments;notebookCellMap;_onDidOpen;_onDidSave;_onDidChange;_onDidClose;_cellTextDocuments;constructor(e){if(e instanceof tY.TextDocuments)this._cellTextDocuments=e;else this._cellTextDocuments=new tY.TextDocuments(e);this.notebookDocuments=new Map,this.notebookCellMap=new Map,this._onDidOpen=new Wo.Emitter,this._onDidChange=new Wo.Emitter,this._onDidSave=new Wo.Emitter,this._onDidClose=new Wo.Emitter}get cellTextDocuments(){return this._cellTextDocuments}getCellTextDocument(e){return this._cellTextDocuments.get(e.document)}getNotebookDocument(e){return this.notebookDocuments.get(e)}getNotebookCell(e){let t=this.notebookCellMap.get(e);return t&&t[0]}findNotebookDocumentForCell(e){let t=typeof e==="string"?e:e.document,n=this.notebookCellMap.get(t);return n&&n[1]}get onDidOpen(){return this._onDidOpen.event}get onDidSave(){return this._onDidSave.event}get onDidChange(){return this._onDidChange.event}get onDidClose(){return this._onDidClose.event}listen(e){let t=new iv,n=[];return n.push(this.cellTextDocuments.listen(t)),n.push(e.notebooks.synchronization.onDidOpenNotebookDocument(async(r)=>{this.notebookDocuments.set(r.notebookDocument.uri,r.notebookDocument);for(let i of r.cellTextDocuments)await t.openTextDocument({textDocument:i});this.updateCellMap(r.notebookDocument),this._onDidOpen.fire(r.notebookDocument)})),n.push(e.notebooks.synchronization.onDidChangeNotebookDocument(async(r)=>{let i=this.notebookDocuments.get(r.notebookDocument.uri);if(i===void 0)return;i.version=r.notebookDocument.version;let s=i.metadata,o=!1,a=r.change;if(a.metadata!==void 0)o=!0,i.metadata=a.metadata;let l=[],c=[],u=[],p=[];if(a.cells!==void 0){let h=a.cells;if(h.structure!==void 0){let b=h.structure.array;if(i.cells.splice(b.start,b.deleteCount,...b.cells!==void 0?b.cells:[]),h.structure.didOpen!==void 0)for(let g of h.structure.didOpen)await t.openTextDocument({textDocument:g}),l.push(g.uri);if(h.structure.didClose)for(let g of h.structure.didClose)await t.closeTextDocument({textDocument:g}),c.push(g.uri)}if(h.data!==void 0){let b=new Map(h.data.map((g)=>[g.document,g]));for(let g=0;g<=i.cells.length;g++){let x=b.get(i.cells[g].document);if(x!==void 0){let v=i.cells.splice(g,1,x);if(u.push({old:v[0],new:x}),b.delete(x.document),b.size===0)break}}}if(h.textContent!==void 0)for(let b of h.textContent)await t.changeTextDocument({textDocument:b.document,contentChanges:b.changes}),p.push(b.document.uri)}this.updateCellMap(i);let d={notebookDocument:i};if(o)d.metadata={old:s,new:i.metadata};let f=[];for(let h of l)f.push(this.getNotebookCell(h));let m=[];for(let h of c)m.push(this.getNotebookCell(h));let y=[];for(let h of p)y.push(this.getNotebookCell(h));if(f.length>0||m.length>0||u.length>0||y.length>0)d.cells={added:f,removed:m,changed:{data:u,textContent:y}};if(d.metadata!==void 0||d.cells!==void 0)this._onDidChange.fire(d)})),n.push(e.notebooks.synchronization.onDidSaveNotebookDocument((r)=>{let i=this.notebookDocuments.get(r.notebookDocument.uri);if(i===void 0)return;this._onDidSave.fire(i)})),n.push(e.notebooks.synchronization.onDidCloseNotebookDocument(async(r)=>{let i=this.notebookDocuments.get(r.notebookDocument.uri);if(i===void 0)return;this._onDidClose.fire(i);for(let s of r.cellTextDocuments)await t.closeTextDocument({textDocument:s});this.notebookDocuments.delete(r.notebookDocument.uri);for(let s of i.cells)this.notebookCellMap.delete(s.document)})),Wo.Disposable.create(()=>{n.forEach((r)=>r.dispose())})}updateCellMap(e){for(let t of e.cells)this.notebookCellMap.set(t.document,[t,e])}}rY.NotebookDocuments=nY});var QA=z(function(lY){Object.defineProperty(lY,"__esModule",{value:!0});lY.boolean=WAe;lY.string=sY;lY.number=QAe;lY.error=YAe;lY.func=oY;lY.array=aY;lY.stringArray=XAe;lY.typedArray=ZAe;lY.thenable=eRe;function WAe(e){return e===!0||e===!1}function sY(e){return typeof e==="string"||e instanceof String}function QAe(e){return typeof e==="number"||e instanceof Number}function YAe(e){return e instanceof Error}function oY(e){return typeof e==="function"}function aY(e){return Array.isArray(e)}function XAe(e){return aY(e)&&e.every((t)=>sY(t))}function ZAe(e,t){return Array.isArray(e)&&e.every(t)}function eRe(e){return e&&oY(e.then)}});var YA=z(function(pY){Object.defineProperty(pY,"__esModule",{value:!0});pY.empty=void 0;pY.v4=cY;pY.isUUID=uY;pY.parse=pRe;pY.generateUuid=dRe;class TT{_value;constructor(e){this._value=e}asHex(){return this._value}equals(e){return this.asHex()===e.asHex()}}class Wt extends TT{static _chars=["0","1","2","3","4","5","6","6","7","8","9","a","b","c","d","e","f"];static _timeHighBits=["8","9","a","b"];static _oneOf(e){return e[Math.floor(e.length*Math.random())]}static _randomHex(){return Wt._oneOf(Wt._chars)}constructor(){super([Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),"-",Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),"-","4",Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),"-",Wt._oneOf(Wt._timeHighBits),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),"-",Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex(),Wt._randomHex()].join(""))}}pY.empty=new TT("00000000-0000-0000-0000-000000000000");function cY(){return new Wt}var uRe=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;function uY(e){return uRe.test(e)}function pRe(e){if(!uY(e))throw Error("invalid uuid");return new TT(e)}function dRe(){return cY().asHex()}});var hY=z(function(mY){Object.defineProperty(mY,"__esModule",{value:!0});mY.ProgressFeature=void 0;mY.attachWorkDone=bRe;mY.attachPartialResult=_Re;var cp=gr(),gRe=YA();class rf{_connection;_token;static Instances=new Map;constructor(e,t){this._connection=e,this._token=t,rf.Instances.set(this._token,this)}begin(e,t,n,r){let i={kind:"begin",title:e,message:n,cancellable:r};if(typeof t==="number")i.percentage=Math.round(t);this._connection.sendProgress(cp.WorkDoneProgress.type,this._token,i)}report(e,t){let n={kind:"report"};if(typeof e==="number"){if(n.percentage=Math.round(e),t!==void 0)n.message=t}else n.message=e;this._connection.sendProgress(cp.WorkDoneProgress.type,this._token,n)}done(){rf.Instances.delete(this._token),this._connection.sendProgress(cp.WorkDoneProgress.type,this._token,{kind:"end"})}}class XA extends rf{_source;constructor(e,t){super(e,t);this._source=new cp.CancellationTokenSource}get token(){return this._source.token}done(){this._source.dispose(),super.done()}cancel(){this._source.cancel()}}class ST{constructor(){}begin(){}report(){}done(){}}class ZA extends ST{_source;constructor(){super();this._source=new cp.CancellationTokenSource}get token(){return this._source.token}done(){this._source.dispose()}cancel(){this._source.cancel()}}function bRe(e,t){if(t===void 0||t.workDoneToken===void 0)return new ST;let n=t.workDoneToken;return delete t.workDoneToken,new rf(e,n)}var vRe=(e)=>class extends e{_progressSupported;constructor(){super();this._progressSupported=!1}initialize(t){if(super.initialize(t),t?.window?.workDoneProgress===!0)this._progressSupported=!0,this.connection.onNotification(cp.WorkDoneProgressCancelNotification.type,(n)=>{let r=rf.Instances.get(n.token);if(r instanceof XA||r instanceof ZA)r.cancel()})}attachWorkDoneProgress(t){if(t===void 0)return new ST;else return new rf(this.connection,t)}createWorkDoneProgress(){if(this._progressSupported){let t=gRe.generateUuid();return this.connection.sendRequest(cp.WorkDoneProgressCreateRequest.type,{token:t}).then(()=>new XA(this.connection,t))}else return Promise.resolve(new ZA)}};mY.ProgressFeature=vRe;var eR;(function(e){e.type=new cp.ProgressType})(eR||(eR={}));class fY{_connection;_token;constructor(e,t){this._connection=e,this._token=t}report(e){this._connection.sendProgress(eR.type,this._token,e)}}function _Re(e,t){if(t===void 0||t.partialResultToken===void 0)return;let n=t.partialResultToken;return delete t.partialResultToken,new fY(e,n)}});var gY=z(function(Tl){var DRe=Tl&&Tl.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),TRe=Tl&&Tl.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),SRe=Tl&&Tl.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;iclass extends e{getConfiguration(t){if(!t)return this._getConfiguration({});else if(kRe.string(t))return this._getConfiguration({section:t});else return this._getConfiguration(t)}_getConfiguration(t){let n={items:Array.isArray(t)?t:[t]};return this.connection.sendRequest(ERe.ConfigurationRequest.type,n).then((r)=>{if(Array.isArray(r))return Array.isArray(t)?r:r[0];else return Array.isArray(t)?[]:null})}};Tl.ConfigurationFeature=NRe});var _Y=z(function(bY){Object.defineProperty(bY,"__esModule",{value:!0});bY.WorkspaceFoldersFeature=void 0;var ET=gr(),ORe=(e)=>class extends e{_onDidChangeWorkspaceFolders;_unregistration;_notificationIsAutoRegistered;constructor(){super();this._notificationIsAutoRegistered=!1}initialize(t){super.initialize(t);let n=t.workspace;if(n&&n.workspaceFolders)this._onDidChangeWorkspaceFolders=new ET.Emitter,this.connection.onNotification(ET.DidChangeWorkspaceFoldersNotification.type,(r)=>{this._onDidChangeWorkspaceFolders.fire(r.event)})}fillServerCapabilities(t){super.fillServerCapabilities(t);let n=t.workspace?.workspaceFolders?.changeNotifications;this._notificationIsAutoRegistered=n===!0||typeof n==="string"}getWorkspaceFolders(){return this.connection.sendRequest(ET.WorkspaceFoldersRequest.type)}get onDidChangeWorkspaceFolders(){if(!this._onDidChangeWorkspaceFolders)throw Error("Client doesn't support sending workspace folder change events.");if(!this._notificationIsAutoRegistered&&!this._unregistration)this._unregistration=this.connection.client.register(ET.DidChangeWorkspaceFoldersNotification.type);return this._onDidChangeWorkspaceFolders.event}};bY.WorkspaceFoldersFeature=ORe});var DY=z(function(xY){Object.defineProperty(xY,"__esModule",{value:!0});xY.CallHierarchyFeature=void 0;var tR=gr(),PRe=(e)=>class extends e{get callHierarchy(){return{onPrepare:(t)=>this.connection.onRequest(tR.CallHierarchyPrepareRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),void 0)),onIncomingCalls:(t)=>{let n=tR.CallHierarchyIncomingCallsRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onOutgoingCalls:(t)=>{let n=tR.CallHierarchyOutgoingCallsRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};xY.CallHierarchyFeature=PRe});var EY=z(function(TY){Object.defineProperty(TY,"__esModule",{value:!0});TY.ShowDocumentFeature=void 0;var $Re=gr(),IRe=(e)=>class extends e{showDocument(t){return this.connection.sendRequest($Re.ShowDocumentRequest.type,t)}};TY.ShowDocumentFeature=IRe});var OY=z(function(kY){Object.defineProperty(kY,"__esModule",{value:!0});kY.FileOperationsFeature=void 0;var Ey=gr(),ARe=(e)=>class extends e{onDidCreateFiles(t){return this.connection.onNotification(Ey.DidCreateFilesNotification.type,(n)=>t(n))}onDidRenameFiles(t){return this.connection.onNotification(Ey.DidRenameFilesNotification.type,(n)=>t(n))}onDidDeleteFiles(t){return this.connection.onNotification(Ey.DidDeleteFilesNotification.type,(n)=>t(n))}onWillCreateFiles(t){return this.connection.onRequest(Ey.WillCreateFilesRequest.type,(n,r)=>t(n,r))}onWillRenameFiles(t){return this.connection.onRequest(Ey.WillRenameFilesRequest.type,(n,r)=>t(n,r))}onWillDeleteFiles(t){return this.connection.onRequest(Ey.WillDeleteFilesRequest.type,(n,r)=>t(n,r))}};kY.FileOperationsFeature=ARe});var IY=z(function(PY){Object.defineProperty(PY,"__esModule",{value:!0});PY.LinkedEditingRangeFeature=void 0;var RRe=gr(),jRe=(e)=>class extends e{onLinkedEditingRange(t){return this.connection.onRequest(RRe.LinkedEditingRangeRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),void 0))}};PY.LinkedEditingRangeFeature=jRe});var jY=z(function(AY){Object.defineProperty(AY,"__esModule",{value:!0});AY.TypeHierarchyFeature=void 0;var nR=gr(),FRe=(e)=>class extends e{get typeHierarchy(){return{onPrepare:(t)=>this.connection.onRequest(nR.TypeHierarchyPrepareRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),void 0)),onSupertypes:(t)=>{let n=nR.TypeHierarchySupertypesRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onSubtypes:(t)=>{let n=nR.TypeHierarchySubtypesRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};AY.TypeHierarchyFeature=FRe});var LY=z(function(CY){Object.defineProperty(CY,"__esModule",{value:!0});CY.InlineValueFeature=void 0;var FY=gr(),CRe=(e)=>class extends e{get inlineValue(){return{refresh:()=>this.connection.sendRequest(FY.InlineValueRefreshRequest.type),on:(t)=>this.connection.onRequest(FY.InlineValueRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n)))}}};CY.InlineValueFeature=CRe});var VY=z(function(UY){Object.defineProperty(UY,"__esModule",{value:!0});UY.FoldingRangeFeature=void 0;var qY=gr(),MRe=(e)=>class extends e{get foldingRange(){return{refresh:()=>this.connection.sendRequest(qY.FoldingRangeRefreshRequest.type),on:(t)=>{let n=qY.FoldingRangeRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};UY.FoldingRangeFeature=MRe});var GY=z(function(KY){Object.defineProperty(KY,"__esModule",{value:!0});KY.InlayHintFeature=void 0;var rR=gr(),LRe=(e)=>class extends e{get inlayHint(){return{refresh:()=>this.connection.sendRequest(rR.InlayHintRefreshRequest.type),on:(t)=>this.connection.onRequest(rR.InlayHintRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n))),resolve:(t)=>this.connection.onRequest(rR.InlayHintResolveRequest.type,(n,r)=>t(n,r))}}};KY.InlayHintFeature=LRe});var WY=z(function(HY){Object.defineProperty(HY,"__esModule",{value:!0});HY.DiagnosticFeature=void 0;var sv=gr(),qRe=(e)=>class extends e{get diagnostics(){return{refresh:()=>this.connection.sendRequest(sv.DiagnosticRefreshRequest.type),on:(t)=>this.connection.onRequest(sv.DocumentDiagnosticRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),this.attachPartialResultProgress(sv.DocumentDiagnosticRequest.partialResult,n))),onWorkspace:(t)=>this.connection.onRequest(sv.WorkspaceDiagnosticRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),this.attachPartialResultProgress(sv.WorkspaceDiagnosticRequest.partialResult,n)))}}};HY.DiagnosticFeature=qRe});var XY=z(function(QY){Object.defineProperty(QY,"__esModule",{value:!0});QY.MonikerFeature=void 0;var URe=gr(),BRe=(e)=>class extends e{get moniker(){return{on:(t)=>{let n=URe.MonikerRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};QY.MonikerFeature=BRe});var tX=z(function(ZY){Object.defineProperty(ZY,"__esModule",{value:!0});ZY.InlineCompletionFeature=void 0;var VRe=gr(),KRe=(e)=>class extends e{get inlineCompletion(){return{on:(t)=>this.connection.onRequest(VRe.InlineCompletionRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n)))}}};ZY.InlineCompletionFeature=KRe});var sX=z(function(rX){Object.defineProperty(rX,"__esModule",{value:!0});rX.TextDocumentContentFeature=void 0;var nX=gr(),JRe=(e)=>class extends e{get textDocumentContent(){return{refresh:(t)=>this.connection.sendRequest(nX.TextDocumentContentRefreshRequest.type,{uri:t}),on:(t)=>this.connection.onRequest(nX.TextDocumentContentRequest.type,(n,r)=>t(n,r))}}};rX.TextDocumentContentFeature=JRe});var TX=z(function($n){var GRe=$n&&$n.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),HRe=$n&&$n.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),dX=$n&&$n.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(n){var r=[];for(var i in n)if(Object.prototype.hasOwnProperty.call(n,i))r[r.length]=i;return r},e(t)};return function(t){if(t&&t.__esModule)return t;var n={};if(t!=null){for(var r=e(t),i=0;i{e.window.showErrorMessage(t)})}}$n.ErrorMessageTracker=fX;class oR{_rawConnection;_connection;constructor(){}rawAttach(e){this._rawConnection=e}attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}fillServerCapabilities(e){}initialize(e){}error(e){this.send(Ve.MessageType.Error,e)}warn(e){this.send(Ve.MessageType.Warning,e)}info(e){this.send(Ve.MessageType.Info,e)}log(e){this.send(Ve.MessageType.Log,e)}debug(e){this.send(Ve.MessageType.Debug,e)}send(e,t){if(this._rawConnection)this._rawConnection.sendNotification(Ve.LogMessageNotification.type,{type:e,message:t}).catch(()=>{Ve.RAL().console.error("Sending log message failed")})}}class mX{_connection;constructor(){}attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}initialize(e){}fillServerCapabilities(e){}showErrorMessage(e,...t){let n={type:Ve.MessageType.Error,message:e,actions:t};return this.connection.sendRequest(Ve.ShowMessageRequest.type,n).then(iR)}showWarningMessage(e,...t){let n={type:Ve.MessageType.Warning,message:e,actions:t};return this.connection.sendRequest(Ve.ShowMessageRequest.type,n).then(iR)}showInformationMessage(e,...t){let n={type:Ve.MessageType.Info,message:e,actions:t};return this.connection.sendRequest(Ve.ShowMessageRequest.type,n).then(iR)}}var oX=XRe.ShowDocumentFeature(Nt.ProgressFeature(mX)),aX;(function(e){function t(){return new uR}e.create=t})(aX||($n.BulkRegistration=aX={}));class uR{_registrations=[];_registered=new Set;add(e,t){let n=Qo.string(e)?e:e.method;if(this._registered.has(n))throw Error(`${n} is already added to this registration`);let r=sR.generateUuid();this._registrations.push({id:r,method:n,registerOptions:t||{}}),this._registered.add(n)}asRegistrationParams(){return{registrations:this._registrations}}}var lX;(function(e){function t(){return new kT(void 0,[])}e.create=t})(lX||($n.BulkUnregistration=lX={}));class kT{_connection;_unregistrations=new Map;constructor(e,t){this._connection=e,t.forEach((n)=>{this._unregistrations.set(n.method,n)})}get isAttached(){return!!this._connection}attach(e){this._connection=e}add(e){this._unregistrations.set(e.method,e)}dispose(){let e=[];for(let n of this._unregistrations.values())e.push(n);let t={unregisterations:e};this._connection.sendRequest(Ve.UnregistrationRequest.type,t).catch(()=>{this._connection.console.info("Bulk unregistration failed.")})}disposeSingle(e){let t=Qo.string(e)?e:e.method,n=this._unregistrations.get(t);if(!n)return!1;let r={unregisterations:[n]};return this._connection.sendRequest(Ve.UnregistrationRequest.type,r).then(()=>{this._unregistrations.delete(t)},(i)=>{this._connection.console.info(`Un-registering request handler for ${n.id} failed.`)}),!0}}class aR{_connection;attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}initialize(e){}fillServerCapabilities(e){}register(e,t,n){if(e instanceof uR)return this.registerMany(e);else if(e instanceof kT)return this.registerSingle1(e,t,n);else return this.registerSingle2(e,t)}registerSingle1(e,t,n){let r=Qo.string(t)?t:t.method,i=sR.generateUuid(),s={registrations:[{id:i,method:r,registerOptions:n||{}}]};if(!e.isAttached)e.attach(this.connection);return this.connection.sendRequest(Ve.RegistrationRequest.type,s).then((o)=>(e.add({id:i,method:r}),e),(o)=>(this.connection.console.info(`Registering request handler for ${r} failed.`),Promise.reject(o)))}registerSingle2(e,t){let n=Qo.string(e)?e:e.method,r=sR.generateUuid(),i={registrations:[{id:r,method:n,registerOptions:t||{}}]};return this.connection.sendRequest(Ve.RegistrationRequest.type,i).then((s)=>Ve.Disposable.create(()=>{this.unregisterSingle(r,n).catch(()=>{this.connection.console.info(`Un-registering capability with id ${r} failed.`)})}),(s)=>(this.connection.console.info(`Registering request handler for ${n} failed.`),Promise.reject(s)))}unregisterSingle(e,t){let n={unregisterations:[{id:e,method:t}]};return this.connection.sendRequest(Ve.UnregistrationRequest.type,n).catch(()=>{this.connection.console.info(`Un-registering request handler for ${e} failed.`)})}registerMany(e){let t=e.asRegistrationParams();return this.connection.sendRequest(Ve.RegistrationRequest.type,t).then(()=>new kT(this._connection,t.registrations.map((n)=>({id:n.id,method:n.method}))),(n)=>(this.connection.console.info("Bulk registration failed."),Promise.reject(n)))}}class yX{_connection;constructor(){}attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}initialize(e){}fillServerCapabilities(e){}applyEdit(e){function t(r){return r&&!!r.edit}let n=t(e)?e:{edit:e};return this.connection.sendRequest(Ve.ApplyWorkspaceEditRequest.type,n)}}var cX=cje.TextDocumentContentFeature(ZRe.FileOperationsFeature(WRe.WorkspaceFoldersFeature(zRe.ConfigurationFeature(yX))));class lR{_trace;_connection;constructor(){this._trace=Ve.Trace.Off}attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}initialize(e){}fillServerCapabilities(e){}set trace(e){this._trace=e}log(e,t){if(this._trace===Ve.Trace.Off)return;this.connection.sendNotification(Ve.LogTraceNotification.type,{message:e,verbose:this._trace===Ve.Trace.Verbose?t:void 0}).catch(()=>{})}}class cR{_connection;constructor(){}attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}initialize(e){}fillServerCapabilities(e){}logEvent(e){this.connection.sendNotification(Ve.TelemetryEventNotification.type,e).catch(()=>{this.connection.console.log("Sending TelemetryEventNotification failed")})}}class pR{_connection;constructor(){}attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}initialize(e){}fillServerCapabilities(e){}attachWorkDoneProgress(e){return Nt.attachWorkDone(this.connection,e)}attachPartialResultProgress(e,t){return Nt.attachPartialResult(this.connection,t)}}$n._LanguagesImpl=pR;var uX=lje.InlineCompletionFeature(rje.FoldingRangeFeature(aje.MonikerFeature(sje.DiagnosticFeature(ije.InlayHintFeature(nje.InlineValueFeature(tje.TypeHierarchyFeature(eje.LinkedEditingRangeFeature(YRe.SemanticTokensFeature(QRe.CallHierarchyFeature(pR))))))))));class dR{_connection;constructor(){}attach(e){this._connection=e}get connection(){if(!this._connection)throw Error("Remote is not attached to a connection yet.");return this._connection}initialize(e){}fillServerCapabilities(e){}attachWorkDoneProgress(e){return Nt.attachWorkDone(this.connection,e)}attachPartialResultProgress(e,t){return Nt.attachPartialResult(this.connection,t)}}$n._NotebooksImpl=dR;var pX=oje.NotebookSyncFeature(dR);function hX(e,t){return function(n){return t(e(n))}}function gX(e,t){return function(n){return t(e(n))}}function bX(e,t){return function(n){return t(e(n))}}function vX(e,t){return function(n){return t(e(n))}}function _X(e,t){return function(n){return t(e(n))}}function xX(e,t){return function(n){return t(e(n))}}function wX(e,t){return function(n){return t(e(n))}}function DX(e,t){return function(n){return t(e(n))}}function uje(e,t){function n(i,s,o){if(i&&s)return o(i,s);else if(i)return i;else return s}return{__brand:"features",console:n(e.console,t.console,hX),tracer:n(e.tracer,t.tracer,bX),telemetry:n(e.telemetry,t.telemetry,gX),client:n(e.client,t.client,vX),window:n(e.window,t.window,_X),workspace:n(e.workspace,t.workspace,xX),languages:n(e.languages,t.languages,wX),notebooks:n(e.notebooks,t.notebooks,DX)}}function pje(e,t,n){let r=n&&n.console?new(n.console(oR)):new oR,i=e(r);r.rawAttach(i);let s=n&&n.tracer?new(n.tracer(lR)):new lR,o=n&&n.telemetry?new(n.telemetry(cR)):new cR,a=n&&n.client?new(n.client(aR)):new aR,l=n&&n.window?new(n.window(oX)):new oX,c=n&&n.workspace?new(n.workspace(cX)):new cX,u=n&&n.languages?new(n.languages(uX)):new uX,p=n&&n.notebooks?new(n.notebooks(pX)):new pX,d=[r,s,o,a,l,c,u,p];function f(g){if(g instanceof Promise)return g;else if(Qo.thenable(g))return new Promise((x,v)=>{g.then((D)=>x(D),(D)=>v(D))});else return Promise.resolve(g)}let m=void 0,y=void 0,h=void 0,b={listen:()=>i.listen(),sendRequest:(g,...x)=>i.sendRequest(Qo.string(g)?g:g.method,...x),onRequest:(g,x)=>i.onRequest(g,x),sendNotification:(g,x)=>{let v=Qo.string(g)?g:g.method;return i.sendNotification(v,x)},onNotification:(g,x)=>i.onNotification(g,x),onProgress:i.onProgress,sendProgress:i.sendProgress,onInitialize:(g)=>(y=g,{dispose:()=>{y=void 0}}),onInitialized:(g)=>i.onNotification(Ve.InitializedNotification.type,g),onShutdown:(g)=>(m=g,{dispose:()=>{m=void 0}}),onExit:(g)=>(h=g,{dispose:()=>{h=void 0}}),get console(){return r},get telemetry(){return o},get tracer(){return s},get client(){return a},get window(){return l},get workspace(){return c},get languages(){return u},get notebooks(){return p},onDidChangeConfiguration:(g)=>i.onNotification(Ve.DidChangeConfigurationNotification.type,g),onDidChangeWatchedFiles:(g)=>i.onNotification(Ve.DidChangeWatchedFilesNotification.type,g),__textDocumentSync:void 0,onDidOpenTextDocument:(g)=>i.onNotification(Ve.DidOpenTextDocumentNotification.type,g),onDidChangeTextDocument:(g)=>i.onNotification(Ve.DidChangeTextDocumentNotification.type,g),onDidCloseTextDocument:(g)=>i.onNotification(Ve.DidCloseTextDocumentNotification.type,g),onWillSaveTextDocument:(g)=>i.onNotification(Ve.WillSaveTextDocumentNotification.type,g),onWillSaveTextDocumentWaitUntil:(g)=>i.onRequest(Ve.WillSaveTextDocumentWaitUntilRequest.type,g),onDidSaveTextDocument:(g)=>i.onNotification(Ve.DidSaveTextDocumentNotification.type,g),sendDiagnostics:(g)=>i.sendNotification(Ve.PublishDiagnosticsNotification.type,g),onHover:(g)=>i.onRequest(Ve.HoverRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),void 0)),onCompletion:(g)=>i.onRequest(Ve.CompletionRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onCompletionResolve:(g)=>i.onRequest(Ve.CompletionResolveRequest.type,g),onSignatureHelp:(g)=>i.onRequest(Ve.SignatureHelpRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),void 0)),onDeclaration:(g)=>i.onRequest(Ve.DeclarationRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onDefinition:(g)=>i.onRequest(Ve.DefinitionRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onTypeDefinition:(g)=>i.onRequest(Ve.TypeDefinitionRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onImplementation:(g)=>i.onRequest(Ve.ImplementationRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onReferences:(g)=>i.onRequest(Ve.ReferencesRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onDocumentHighlight:(g)=>i.onRequest(Ve.DocumentHighlightRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onDocumentSymbol:(g)=>i.onRequest(Ve.DocumentSymbolRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onWorkspaceSymbol:(g)=>i.onRequest(Ve.WorkspaceSymbolRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onWorkspaceSymbolResolve:(g)=>i.onRequest(Ve.WorkspaceSymbolResolveRequest.type,g),onCodeAction:(g)=>i.onRequest(Ve.CodeActionRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onCodeActionResolve:(g)=>i.onRequest(Ve.CodeActionResolveRequest.type,(x,v)=>g(x,v)),onCodeLens:(g)=>i.onRequest(Ve.CodeLensRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onCodeLensResolve:(g)=>i.onRequest(Ve.CodeLensResolveRequest.type,(x,v)=>g(x,v)),onDocumentFormatting:(g)=>i.onRequest(Ve.DocumentFormattingRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),void 0)),onDocumentRangeFormatting:(g)=>i.onRequest(Ve.DocumentRangeFormattingRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),void 0)),onDocumentRangesFormatting:(g)=>i.onRequest(Ve.DocumentRangesFormattingRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),void 0)),onDocumentOnTypeFormatting:(g)=>i.onRequest(Ve.DocumentOnTypeFormattingRequest.type,(x,v)=>g(x,v)),onRenameRequest:(g)=>i.onRequest(Ve.RenameRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),void 0)),onPrepareRename:(g)=>i.onRequest(Ve.PrepareRenameRequest.type,(x,v)=>g(x,v)),onDocumentLinks:(g)=>i.onRequest(Ve.DocumentLinkRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onDocumentLinkResolve:(g)=>i.onRequest(Ve.DocumentLinkResolveRequest.type,(x,v)=>g(x,v)),onDocumentColor:(g)=>i.onRequest(Ve.DocumentColorRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onColorPresentation:(g)=>i.onRequest(Ve.ColorPresentationRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onFoldingRanges:(g)=>i.onRequest(Ve.FoldingRangeRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onSelectionRanges:(g)=>i.onRequest(Ve.SelectionRangeRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),Nt.attachPartialResult(i,x))),onExecuteCommand:(g)=>i.onRequest(Ve.ExecuteCommandRequest.type,(x,v)=>g(x,v,Nt.attachWorkDone(i,x),void 0)),dispose:()=>i.dispose()};for(let g of d)g.attach(b);return i.onRequest(Ve.InitializeRequest.type,(g)=>{if(t.initialize(g),Qo.string(g.trace))s.trace=Ve.Trace.fromString(g.trace);for(let x of d)x.initialize(g.capabilities);if(y){let x=y(g,new Ve.CancellationTokenSource().token,Nt.attachWorkDone(i,g),void 0);return f(x).then((v)=>{if(v instanceof Ve.ResponseError)return v;let D=v;if(!D)D={capabilities:{}};let T=D.capabilities;if(!T)T={},D.capabilities=T;if(T.textDocumentSync===void 0||T.textDocumentSync===null)T.textDocumentSync=Qo.number(b.__textDocumentSync)?b.__textDocumentSync:Ve.TextDocumentSyncKind.None;else if(!Qo.number(T.textDocumentSync)&&!Qo.number(T.textDocumentSync.change))T.textDocumentSync.change=Qo.number(b.__textDocumentSync)?b.__textDocumentSync:Ve.TextDocumentSyncKind.None;for(let N of d)N.fillServerCapabilities(T);return D})}else{let x={capabilities:{textDocumentSync:Ve.TextDocumentSyncKind.None}};for(let v of d)v.fillServerCapabilities(x.capabilities);return x}}),i.onRequest(Ve.ShutdownRequest.type,()=>{if(t.shutdownReceived=!0,m)return m(new Ve.CancellationTokenSource().token);else return}),i.onNotification(Ve.ExitNotification.type,()=>{try{if(h)return h()}finally{if(t.shutdownReceived)t.exit(0);else t.exit(1)}}),i.onNotification(Ve.SetTraceNotification.type,(g)=>{s.trace=Ve.Trace.fromString(g.value)}),b}});var up=z(function(Ci){var dje=Ci&&Ci.__createBinding||(Object.create?function(e,t,n,r){if(r===void 0)r=n;var i=Object.getOwnPropertyDescriptor(t,n);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable))i={enumerable:!0,get:function(){return t[n]}};Object.defineProperty(e,r,i)}:function(e,t,n,r){if(r===void 0)r=n;e[r]=t[n]}),EX=Ci&&Ci.__exportStar||function(e,t){for(var n in e)if(n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n))dje(t,e,n)};Object.defineProperty(Ci,"__esModule",{value:!0});Ci.ProposedFeatures=Ci.NotebookDocuments=Ci.TextDocuments=Ci.SemanticTokensBuilder=void 0;var fje=HA();Object.defineProperty(Ci,"SemanticTokensBuilder",{enumerable:!0,get:function(){return fje.SemanticTokensBuilder}});EX(gr(),Ci);var mje=zA();Object.defineProperty(Ci,"TextDocuments",{enumerable:!0,get:function(){return mje.TextDocuments}});var yje=WA();Object.defineProperty(Ci,"NotebookDocuments",{enumerable:!0,get:function(){return yje.NotebookDocuments}});EX(TX(),Ci);var SX;(function(e){e.all={__brand:"features"}})(SX||(Ci.ProposedFeatures=SX={}))});var fR=q(()=>{Gt()});var kX=q(()=>{_t()});var NT=q(()=>{kX()});var yR=q(()=>{_t();cy();Yn();Zs();It()});var OT=q(()=>{mn();Gt()});var NX=q(()=>{mn();OT()});var OX=q(()=>{mn();ol();OT()});var PX=q(()=>{NX();OX();OT()});var $X=q(()=>{PX()});var vje,_je;var IX=q(()=>{vw();vje={type:"object",additionalProperties:!1,properties:{name:{type:"string"},version:{type:"string",nullable:!0}},required:["name"]},_je={type:"object",additionalProperties:!1,properties:{title:{type:"string"},description:{type:"string"},target:{type:"string",enum:["library","project"],default:"project",nullable:!0},compilerVersion:{type:"string",nullable:!0},libraries:{type:"array",items:{oneOf:[{type:"string"},vje]},nullable:!0},emitters:{type:"object",nullable:!0,additionalProperties:{type:"object",properties:{label:{type:"string",nullable:!0},description:{type:"string",nullable:!0},selected:{type:"boolean",nullable:!0},options:{},message:{type:"string",nullable:!0},version:{type:"string",nullable:!0}},required:[]},required:[]},skipCompilerPackage:{type:"boolean",nullable:!0},config:{nullable:!0,...Xg},inputs:{type:"object",nullable:!0,additionalProperties:{type:"object",properties:{description:{type:"string"},type:{type:"string",enum:["text"]},initialValue:{}},required:["description","type"]},required:[]},files:{type:"array",nullable:!0,items:{type:"object",properties:{path:{type:"string"},destination:{type:"string"},skipGeneration:{type:"boolean",nullable:!0}},required:["path","destination"]}}},required:["title","description"]}});var AX=q(()=>{Om();IX()});var ov=z(function(Fxt,RX){var xje=typeof process==="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{};RX.exports=xje});var PT=z(function(Cxt,jX){var wje=Number.MAX_SAFE_INTEGER||9007199254740991,Dje=["major","premajor","minor","preminor","patch","prepatch","prerelease"];jX.exports={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:16,MAX_SAFE_BUILD_LENGTH:250,MAX_SAFE_INTEGER:wje,RELEASE_TYPES:Dje,SEMVER_SPEC_VERSION:"2.0.0",FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2}});var $T=z(function(Sl,FX){var{MAX_SAFE_COMPONENT_LENGTH:hR,MAX_SAFE_BUILD_LENGTH:Tje,MAX_LENGTH:Sje}=PT(),Eje=ov();Sl=FX.exports={};var kje=Sl.re=[],Nje=Sl.safeRe=[],Ye=Sl.src=[],Oje=Sl.safeSrc=[],Xe=Sl.t={},Pje=0,gR="[a-zA-Z0-9-]",$je=[["\\s",1],["\\d",Sje],[gR,Tje]],Ije=(e)=>{for(let[t,n]of $je)e=e.split(`${t}*`).join(`${t}{0,${n}}`).split(`${t}+`).join(`${t}{1,${n}}`);return e},$t=(e,t,n)=>{let r=Ije(t),i=Pje++;Eje(e,i,t),Xe[e]=i,Ye[i]=t,Oje[i]=r,kje[i]=new RegExp(t,n?"g":void 0),Nje[i]=new RegExp(r,n?"g":void 0)};$t("NUMERICIDENTIFIER","0|[1-9]\\d*");$t("NUMERICIDENTIFIERLOOSE","\\d+");$t("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${gR}*`);$t("MAINVERSION",`(${Ye[Xe.NUMERICIDENTIFIER]})\\.(${Ye[Xe.NUMERICIDENTIFIER]})\\.(${Ye[Xe.NUMERICIDENTIFIER]})`);$t("MAINVERSIONLOOSE",`(${Ye[Xe.NUMERICIDENTIFIERLOOSE]})\\.(${Ye[Xe.NUMERICIDENTIFIERLOOSE]})\\.(${Ye[Xe.NUMERICIDENTIFIERLOOSE]})`);$t("PRERELEASEIDENTIFIER",`(?:${Ye[Xe.NONNUMERICIDENTIFIER]}|${Ye[Xe.NUMERICIDENTIFIER]})`);$t("PRERELEASEIDENTIFIERLOOSE",`(?:${Ye[Xe.NONNUMERICIDENTIFIER]}|${Ye[Xe.NUMERICIDENTIFIERLOOSE]})`);$t("PRERELEASE",`(?:-(${Ye[Xe.PRERELEASEIDENTIFIER]}(?:\\.${Ye[Xe.PRERELEASEIDENTIFIER]})*))`);$t("PRERELEASELOOSE",`(?:-?(${Ye[Xe.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${Ye[Xe.PRERELEASEIDENTIFIERLOOSE]})*))`);$t("BUILDIDENTIFIER",`${gR}+`);$t("BUILD",`(?:\\+(${Ye[Xe.BUILDIDENTIFIER]}(?:\\.${Ye[Xe.BUILDIDENTIFIER]})*))`);$t("FULLPLAIN",`v?${Ye[Xe.MAINVERSION]}${Ye[Xe.PRERELEASE]}?${Ye[Xe.BUILD]}?`);$t("FULL",`^${Ye[Xe.FULLPLAIN]}$`);$t("LOOSEPLAIN",`[v=\\s]*${Ye[Xe.MAINVERSIONLOOSE]}${Ye[Xe.PRERELEASELOOSE]}?${Ye[Xe.BUILD]}?`);$t("LOOSE",`^${Ye[Xe.LOOSEPLAIN]}$`);$t("GTLT","((?:<|>)?=?)");$t("XRANGEIDENTIFIERLOOSE",`${Ye[Xe.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);$t("XRANGEIDENTIFIER",`${Ye[Xe.NUMERICIDENTIFIER]}|x|X|\\*`);$t("XRANGEPLAIN",`[v=\\s]*(${Ye[Xe.XRANGEIDENTIFIER]})(?:\\.(${Ye[Xe.XRANGEIDENTIFIER]})(?:\\.(${Ye[Xe.XRANGEIDENTIFIER]})(?:${Ye[Xe.PRERELEASE]})?${Ye[Xe.BUILD]}?)?)?`);$t("XRANGEPLAINLOOSE",`[v=\\s]*(${Ye[Xe.XRANGEIDENTIFIERLOOSE]})(?:\\.(${Ye[Xe.XRANGEIDENTIFIERLOOSE]})(?:\\.(${Ye[Xe.XRANGEIDENTIFIERLOOSE]})(?:${Ye[Xe.PRERELEASELOOSE]})?${Ye[Xe.BUILD]}?)?)?`);$t("XRANGE",`^${Ye[Xe.GTLT]}\\s*${Ye[Xe.XRANGEPLAIN]}$`);$t("XRANGELOOSE",`^${Ye[Xe.GTLT]}\\s*${Ye[Xe.XRANGEPLAINLOOSE]}$`);$t("COERCEPLAIN",`(^|[^\\d])(\\d{1,${hR}})(?:\\.(\\d{1,${hR}}))?(?:\\.(\\d{1,${hR}}))?`);$t("COERCE",`${Ye[Xe.COERCEPLAIN]}(?:$|[^\\d])`);$t("COERCEFULL",Ye[Xe.COERCEPLAIN]+`(?:${Ye[Xe.PRERELEASE]})?(?:${Ye[Xe.BUILD]})?(?:$|[^\\d])`);$t("COERCERTL",Ye[Xe.COERCE],!0);$t("COERCERTLFULL",Ye[Xe.COERCEFULL],!0);$t("LONETILDE","(?:~>?)");$t("TILDETRIM",`(\\s*)${Ye[Xe.LONETILDE]}\\s+`,!0);Sl.tildeTrimReplace="$1~";$t("TILDE",`^${Ye[Xe.LONETILDE]}${Ye[Xe.XRANGEPLAIN]}$`);$t("TILDELOOSE",`^${Ye[Xe.LONETILDE]}${Ye[Xe.XRANGEPLAINLOOSE]}$`);$t("LONECARET","(?:\\^)");$t("CARETTRIM",`(\\s*)${Ye[Xe.LONECARET]}\\s+`,!0);Sl.caretTrimReplace="$1^";$t("CARET",`^${Ye[Xe.LONECARET]}${Ye[Xe.XRANGEPLAIN]}$`);$t("CARETLOOSE",`^${Ye[Xe.LONECARET]}${Ye[Xe.XRANGEPLAINLOOSE]}$`);$t("COMPARATORLOOSE",`^${Ye[Xe.GTLT]}\\s*(${Ye[Xe.LOOSEPLAIN]})$|^$`);$t("COMPARATOR",`^${Ye[Xe.GTLT]}\\s*(${Ye[Xe.FULLPLAIN]})$|^$`);$t("COMPARATORTRIM",`(\\s*)${Ye[Xe.GTLT]}\\s*(${Ye[Xe.LOOSEPLAIN]}|${Ye[Xe.XRANGEPLAIN]})`,!0);Sl.comparatorTrimReplace="$1$2$3";$t("HYPHENRANGE",`^\\s*(${Ye[Xe.XRANGEPLAIN]})\\s+-\\s+(${Ye[Xe.XRANGEPLAIN]})\\s*$`);$t("HYPHENRANGELOOSE",`^\\s*(${Ye[Xe.XRANGEPLAINLOOSE]})\\s+-\\s+(${Ye[Xe.XRANGEPLAINLOOSE]})\\s*$`);$t("STAR","(<|>)?=?\\s*\\*");$t("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$");$t("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")});var IT=z(function(Mxt,CX){var Aje=Object.freeze({loose:!0}),Rje=Object.freeze({}),jje=(e)=>{if(!e)return Rje;if(typeof e!=="object")return Aje;return e};CX.exports=jje});var UX=z(function(Lxt,qX){var MX=/^[0-9]+$/,LX=(e,t)=>{if(typeof e==="number"&&typeof t==="number")return e===t?0:eLX(t,e);qX.exports={compareIdentifiers:LX,rcompareIdentifiers:Fje}});var av=z(function(qxt,VX){var AT=ov(),{MAX_LENGTH:BX,MAX_SAFE_INTEGER:RT}=PT(),{safeRe:jT,t:FT}=$T(),Cje=IT(),{compareIdentifiers:bR}=UX(),Mje=(e,t)=>{let n=t.split(".");if(n.length>e.length)return!1;for(let r=0;rBX)throw TypeError(`version is longer than ${BX} characters`);AT("SemVer",e,t),this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease;let n=e.trim().match(t.loose?jT[FT.LOOSE]:jT[FT.FULL]);if(!n)throw TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+n[1],this.minor=+n[2],this.patch=+n[3],this.major>RT||this.major<0)throw TypeError("Invalid major version");if(this.minor>RT||this.minor<0)throw TypeError("Invalid minor version");if(this.patch>RT||this.patch<0)throw TypeError("Invalid patch version");if(!n[4])this.prerelease=[];else this.prerelease=n[4].split(".").map((r)=>{if(/^[0-9]+$/.test(r)){let i=+r;if(i>=0&&ie.major)return 1;if(this.minore.minor)return 1;if(this.patche.patch)return 1;return 0}comparePre(e){if(!(e instanceof $a))e=new $a(e,this.options);if(this.prerelease.length&&!e.prerelease.length)return-1;else if(!this.prerelease.length&&e.prerelease.length)return 1;else if(!this.prerelease.length&&!e.prerelease.length)return 0;let t=0;do{let n=this.prerelease[t],r=e.prerelease[t];if(AT("prerelease compare",t,n,r),n===void 0&&r===void 0)return 0;else if(r===void 0)return 1;else if(n===void 0)return-1;else if(n===r)continue;else return bR(n,r)}while(++t)}compareBuild(e){if(!(e instanceof $a))e=new $a(e,this.options);let t=0;do{let n=this.build[t],r=e.build[t];if(AT("build compare",t,n,r),n===void 0&&r===void 0)return 0;else if(r===void 0)return 1;else if(n===void 0)return-1;else if(n===r)continue;else return bR(n,r)}while(++t)}inc(e,t,n){if(e.startsWith("pre")){if(!t&&n===!1)throw Error("invalid increment argument: identifier is empty");if(t){let r=`-${t}`.match(this.options.loose?jT[FT.PRERELEASELOOSE]:jT[FT.PRERELEASE]);if(!r||r[1]!==t)throw Error(`invalid identifier: ${t}`)}}switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",t,n);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",t,n);break;case"prepatch":this.prerelease.length=0,this.inc("patch",t,n),this.inc("pre",t,n);break;case"prerelease":if(this.prerelease.length===0)this.inc("patch",t,n);this.inc("pre",t,n);break;case"release":if(this.prerelease.length===0)throw Error(`version ${this.raw} is not a prerelease`);this.prerelease.length=0;break;case"major":if(this.minor!==0||this.patch!==0||this.prerelease.length===0)this.major++;this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":if(this.patch!==0||this.prerelease.length===0)this.minor++;this.patch=0,this.prerelease=[];break;case"patch":if(this.prerelease.length===0)this.patch++;this.prerelease=[];break;case"pre":{let r=Number(n)?1:0;if(this.prerelease.length===0)this.prerelease=[r];else{let i=this.prerelease.length;while(--i>=0)if(typeof this.prerelease[i]==="number")this.prerelease[i]++,i=-2;if(i===-1){if(t===this.prerelease.join(".")&&n===!1)throw Error("invalid increment argument: identifier already exists");this.prerelease.push(r)}}if(t){let i=[t,r];if(n===!1)i=[t];if(Mje(this.prerelease,t)){let s=this.prerelease[t.split(".").length];if(isNaN(s))this.prerelease=i}else this.prerelease=i}break}default:throw Error(`invalid increment argument: ${e}`)}if(this.raw=this.format(),this.build.length)this.raw+=`+${this.build.join(".")}`;return this}}VX.exports=$a});var GX=z(function(Uxt,JX){class KX{constructor(){this.max=1000,this.map=new Map}get(e){let t=this.map.get(e);if(t===void 0)return;else return this.map.delete(e),this.map.set(e,t),t}delete(e){return this.map.delete(e)}set(e,t){if(!this.delete(e)&&t!==void 0){if(this.map.size>=this.max){let r=this.map.keys().next().value;this.delete(r)}this.map.set(e,t)}return this}}JX.exports=KX});var sf=z(function(Bxt,zX){var HX=av(),Lje=(e,t,n)=>new HX(e,n).compare(new HX(t,n));zX.exports=Lje});var QX=z(function(Vxt,WX){var qje=sf(),Uje=(e,t,n)=>qje(e,t,n)===0;WX.exports=Uje});var XX=z(function(Kxt,YX){var Bje=sf(),Vje=(e,t,n)=>Bje(e,t,n)!==0;YX.exports=Vje});var eZ=z(function(Jxt,ZX){var Kje=sf(),Jje=(e,t,n)=>Kje(e,t,n)>0;ZX.exports=Jje});var nZ=z(function(Gxt,tZ){var Gje=sf(),Hje=(e,t,n)=>Gje(e,t,n)>=0;tZ.exports=Hje});var iZ=z(function(Hxt,rZ){var zje=sf(),Wje=(e,t,n)=>zje(e,t,n)<0;rZ.exports=Wje});var oZ=z(function(zxt,sZ){var Qje=sf(),Yje=(e,t,n)=>Qje(e,t,n)<=0;sZ.exports=Yje});var lZ=z(function(Wxt,aZ){var Xje=QX(),Zje=XX(),eFe=eZ(),tFe=nZ(),nFe=iZ(),rFe=oZ(),iFe=(e,t,n,r)=>{switch(t){case"===":if(typeof e==="object")e=e.version;if(typeof n==="object")n=n.version;return e===n;case"!==":if(typeof e==="object")e=e.version;if(typeof n==="object")n=n.version;return e!==n;case"":case"=":case"==":return Xje(e,n,r);case"!=":return Zje(e,n,r);case">":return eFe(e,n,r);case">=":return tFe(e,n,r);case"<":return nFe(e,n,r);case"<=":return rFe(e,n,r);default:throw TypeError(`Invalid operator: ${t}`)}};aZ.exports=iFe});var yZ=z(function(Qxt,mZ){var lv=Symbol("SemVer ANY");class CT{static get ANY(){return lv}constructor(e,t){if(t=cZ(t),e instanceof CT)if(e.loose===!!t.loose)return e;else e=e.value;if(e=e.trim().split(/\s+/).join(" "),_R("comparator",e,t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===lv)this.value="";else this.value=this.operator+this.semver.version;_R("comp",this)}parse(e){let t=this.options.loose?uZ[pZ.COMPARATORLOOSE]:uZ[pZ.COMPARATOR],n=e.match(t);if(!n)throw TypeError(`Invalid comparator: ${e}`);if(this.operator=n[1]!==void 0?n[1]:"",this.operator==="=")this.operator="";if(!n[2])this.semver=lv;else this.semver=new dZ(n[2],this.options.loose)}toString(){return this.value}test(e){if(_R("Comparator.test",e,this.options.loose),this.semver===lv||e===lv)return!0;if(typeof e==="string")try{e=new dZ(e,this.options)}catch(t){return!1}return vR(e,this.operator,this.semver,this.options)}intersects(e,t){if(!(e instanceof CT))throw TypeError("a Comparator is required");if(this.operator===""){if(this.value==="")return!0;return new fZ(e.value,t).test(this.value)}else if(e.operator===""){if(e.value==="")return!0;return new fZ(this.value,t).test(e.semver)}if(t=cZ(t),t.includePrerelease&&(this.value==="<0.0.0-0"||e.value==="<0.0.0-0"))return!1;if(!t.includePrerelease&&(this.value.startsWith("<0.0.0")||e.value.startsWith("<0.0.0")))return!1;if(this.operator.startsWith(">")&&e.operator.startsWith(">"))return!0;if(this.operator.startsWith("<")&&e.operator.startsWith("<"))return!0;if(this.semver.version===e.semver.version&&this.operator.includes("=")&&e.operator.includes("="))return!0;if(vR(this.semver,"<",e.semver,t)&&this.operator.startsWith(">")&&e.operator.startsWith("<"))return!0;if(vR(this.semver,">",e.semver,t)&&this.operator.startsWith("<")&&e.operator.startsWith(">"))return!0;return!1}}mZ.exports=CT;var cZ=IT(),{safeRe:uZ,t:pZ}=$T(),vR=lZ(),_R=ov(),dZ=av(),fZ=xR()});var xR=z(function(Yxt,vZ){var sFe=/\s+/g;class cv{constructor(e,t){if(t=aFe(t),e instanceof cv)if(e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease)return e;else return new cv(e.raw,t);if(e instanceof wR)return this.raw=e.value,this.set=[[e]],this.formatted=void 0,this;if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=e.trim().replace(sFe," "),this.set=this.raw.split("||").map((n)=>this.parseRange(n.trim())).filter((n)=>n.length),!this.set.length)throw TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){let n=this.set[0];if(this.set=this.set.filter((r)=>!gZ(r[0])),this.set.length===0)this.set=[n];else if(this.set.length>1){for(let r of this.set)if(r.length===1&&hFe(r[0])){this.set=[r];break}}}this.formatted=void 0}get range(){if(this.formatted===void 0){this.formatted="";for(let e=0;e0)this.formatted+="||";let t=this.set[e];for(let n=0;n0)this.formatted+=" ";this.formatted+=t[n].toString().trim()}}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(e){e=e.replace(yFe,"");let n=((this.options.includePrerelease&&fFe)|(this.options.loose&&mFe))+":"+e,r=hZ.get(n);if(r)return r;let i=this.options.loose,s=i?ts[gi.HYPHENRANGELOOSE]:ts[gi.HYPHENRANGE];e=e.replace(s,kFe(this.options.includePrerelease)),zn("hyphen replace",e),e=e.replace(ts[gi.COMPARATORTRIM],uFe),zn("comparator trim",e),e=e.replace(ts[gi.TILDETRIM],pFe),zn("tilde trim",e),e=e.replace(ts[gi.CARETTRIM],dFe),zn("caret trim",e);let o=e.split(" ").map((u)=>gFe(u,this.options)).join(" ").split(/\s+/).map((u)=>EFe(u,this.options));if(i)o=o.filter((u)=>(zn("loose invalid filter",u,this.options),!!u.match(ts[gi.COMPARATORLOOSE])));zn("range list",o);let a=new Map,l=o.map((u)=>new wR(u,this.options));for(let u of l){if(gZ(u))return[u];a.set(u.value,u)}if(a.size>1&&a.has(""))a.delete("");let c=[...a.values()];return hZ.set(n,c),c}intersects(e,t){if(!(e instanceof cv))throw TypeError("a Range is required");return this.set.some((n)=>bZ(n,t)&&e.set.some((r)=>bZ(r,t)&&n.every((i)=>r.every((s)=>i.intersects(s,t)))))}test(e){if(!e)return!1;if(typeof e==="string")try{e=new lFe(e,this.options)}catch(t){return!1}for(let t=0;te.value==="<0.0.0-0",hFe=(e)=>e.value==="",bZ=(e,t)=>{let n=!0,r=e.slice(),i=r.pop();while(n&&r.length)n=r.every((s)=>i.intersects(s,t)),i=r.pop();return n},gFe=(e,t)=>(e=e.replace(ts[gi.BUILD],""),zn("comp",e,t),e=xFe(e,t),zn("caret",e),e=vFe(e,t),zn("tildes",e),e=DFe(e,t),zn("xrange",e),e=SFe(e,t),zn("stars",e),e),Vr=(e)=>!e||e.toLowerCase()==="x"||e==="*",bFe=(e,t,n)=>Vr(e)&&!Vr(t)||Vr(t)&&n&&!Vr(n),vFe=(e,t)=>e.trim().split(/\s+/).map((n)=>_Fe(n,t)).join(" "),_Fe=(e,t)=>{let n=t.loose?ts[gi.TILDELOOSE]:ts[gi.TILDE],r=t.includePrerelease?"-0":"";return e.replace(n,(i,s,o,a,l)=>{zn("tilde",e,i,s,o,a,l);let c;if(Vr(s))c="";else if(Vr(o))c=`>=${s}.0.0${r} <${+s+1}.0.0-0`;else if(Vr(a))c=`>=${s}.${o}.0${r} <${s}.${+o+1}.0-0`;else if(l)zn("replaceTilde pr",l),c=`>=${s}.${o}.${a}-${l} <${s}.${+o+1}.0-0`;else c=`>=${s}.${o}.${a} <${s}.${+o+1}.0-0`;return zn("tilde return",c),c})},xFe=(e,t)=>e.trim().split(/\s+/).map((n)=>wFe(n,t)).join(" "),wFe=(e,t)=>{zn("caret",e,t);let n=t.loose?ts[gi.CARETLOOSE]:ts[gi.CARET],r=t.includePrerelease?"-0":"";return e.replace(n,(i,s,o,a,l)=>{zn("caret",e,i,s,o,a,l);let c;if(Vr(s))c="";else if(Vr(o))c=`>=${s}.0.0${r} <${+s+1}.0.0-0`;else if(Vr(a))if(s==="0")c=`>=${s}.${o}.0${r} <${s}.${+o+1}.0-0`;else c=`>=${s}.${o}.0${r} <${+s+1}.0.0-0`;else if(l)if(zn("replaceCaret pr",l),s==="0")if(o==="0")c=`>=${s}.${o}.${a}-${l} <${s}.${o}.${+a+1}-0`;else c=`>=${s}.${o}.${a}-${l} <${s}.${+o+1}.0-0`;else c=`>=${s}.${o}.${a}-${l} <${+s+1}.0.0-0`;else if(zn("no pr"),s==="0")if(o==="0")c=`>=${s}.${o}.${a} <${s}.${o}.${+a+1}-0`;else c=`>=${s}.${o}.${a} <${s}.${+o+1}.0-0`;else c=`>=${s}.${o}.${a} <${+s+1}.0.0-0`;return zn("caret return",c),c})},DFe=(e,t)=>(zn("replaceXRanges",e,t),e.split(/\s+/).map((n)=>TFe(n,t)).join(" ")),TFe=(e,t)=>{e=e.trim();let n=t.loose?ts[gi.XRANGELOOSE]:ts[gi.XRANGE];return e.replace(n,(r,i,s,o,a,l)=>{if(zn("xRange",e,r,i,s,o,a,l),bFe(s,o,a))return e;let c=Vr(s),u=c||Vr(o),p=u||Vr(a),d=p;if(i==="="&&d)i="";if(l=t.includePrerelease?"-0":"",c)if(i===">"||i==="<")r="<0.0.0-0";else r="*";else if(i&&d){if(u)o=0;if(a=0,i===">")if(i=">=",u)s=+s+1,o=0,a=0;else o=+o+1,a=0;else if(i==="<=")if(i="<",u)s=+s+1;else o=+o+1;if(i==="<")l="-0";r=`${i+s}.${o}.${a}${l}`}else if(u)r=`>=${s}.0.0${l} <${+s+1}.0.0-0`;else if(p)r=`>=${s}.${o}.0${l} <${s}.${+o+1}.0-0`;return zn("xRange return",r),r})},SFe=(e,t)=>(zn("replaceStars",e,t),e.trim().replace(ts[gi.STAR],"")),EFe=(e,t)=>(zn("replaceGTE0",e,t),e.trim().replace(ts[t.includePrerelease?gi.GTE0PRE:gi.GTE0],"")),kFe=(e)=>(t,n,r,i,s,o,a,l,c,u,p,d)=>{if(Vr(r))n="";else if(Vr(i))n=`>=${r}.0.0${e?"-0":""}`;else if(Vr(s))n=`>=${r}.${i}.0${e?"-0":""}`;else if(o)n=`>=${n}`;else n=`>=${n}${e?"-0":""}`;if(Vr(c))l="";else if(Vr(u))l=`<${+c+1}.0.0-0`;else if(Vr(p))l=`<${c}.${+u+1}.0-0`;else if(d)l=`<=${c}.${u}.${p}-${d}`;else if(e)l=`<${c}.${u}.${+p+1}-0`;else l=`<=${l}`;return`${n} ${l}`.trim()},NFe=(e,t,n)=>{for(let r=0;r0){let i=e[r].semver;if(i.major===t.major&&i.minor===t.minor&&i.patch===t.patch)return!0}}return!1}return!0}});var xZ=z(function(Xxt,_Z){var OFe=av(),PFe=xR(),$Fe=(e,t,n)=>{let r=null,i=null,s=null;try{s=new PFe(t,n)}catch(o){return null}return e.forEach((o)=>{if(s.test(o)){if(!r||i.compare(o)===-1)r=o,i=new OFe(r,n)}}),r};_Z.exports=$Fe});var IFe;var wZ=q(()=>{IFe=Rr(xZ(),1)});function DZ(e){let t=e.trim();t=t.replace(AFe,"$1\x00$2").replace(RFe,"$1\x00$2"),t=t.replace(FFe,"\x00");let n=0,r=t.length;while(t.charAt(n)==="\x00")n++;if(n===r)return[];while(t.charAt(r-1)==="\x00")r--;return t.slice(n,r).split(/\0/g)}function CFe(e){let t=DZ(e);for(let n=0;n{if(c===0)return s(l);return a(l,c)}).join(t?.delimiter??"")+i}function SZ(e,t){let[n,r,i]=TR(e,t),s=DR(t?.locale),o=kZ(t?.locale),a=t?.mergeAmbiguousCharacters?NZ(s,o):OZ(s,o);return n+r.map(a).join(t?.delimiter??"")+i}function EZ(e,t){return MFe(e,{delimiter:"-",...t})}function DR(e){return e===!1?(t)=>t.toLowerCase():(t)=>t.toLocaleLowerCase(e)}function kZ(e){return e===!1?(t)=>t.toUpperCase():(t)=>t.toLocaleUpperCase(e)}function NZ(e,t){return(n)=>`${t(n[0])}${e(n.slice(1))}`}function OZ(e,t){return(n,r)=>{let i=n[0];return(r>0&&i>="0"&&i<="9"?"_"+i:t(i))+e(n.slice(1))}}function TR(e,t={}){let n=t.split??(t.separateNumbers?CFe:DZ),r=t.prefixCharacters??"",i=t.suffixCharacters??"",s=0,o=e.length;while(ss){let a=o-1,l=e.charAt(a);if(!i.includes(l))break;o=a}return[e.slice(0,s),n(e.slice(s,o)),e.slice(o)]}var AFe,RFe,jFe,FFe;var PZ=q(()=>{AFe=/([\p{Ll}\d])(\p{Lu})/gu,RFe=/(\p{Lu})([\p{Lu}][\p{Ll}])/gu,jFe=/(\d)\p{Ll}|(\p{L})\d/u,FFe=/[^\p{L}\d]+/giu});function ER(e){return typeof e==="function"}function qFe(e){return Ny(e)?"array":typeof e}function SR(e){return e.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function $Z(e,t){return e!=null&&typeof e==="object"&&t in e}function UFe(e,t){return e!=null&&typeof e!=="object"&&e.hasOwnProperty&&e.hasOwnProperty(t)}function VFe(e,t){return BFe.call(e,t)}function JFe(e){return!VFe(KFe,e)}function HFe(e){return String(e).replace(/[&<>"'`=\/]/g,function(n){return GFe[n]})}function XFe(e,t){if(!e)return[];var n=!1,r=[],i=[],s=[],o=!1,a=!1,l="",c=0;function u(){if(o&&!a)while(s.length)delete i[s.pop()];else s=[];o=!1,a=!1}var p,d,f;function m(O){if(typeof O==="string")O=O.split(WFe,2);if(!Ny(O)||O.length!==2)throw Error("Invalid tags: "+O);p=new RegExp(SR(O[0])+"\\s*"),d=new RegExp("\\s*"+SR(O[1])),f=new RegExp("\\s*"+SR("}"+O[1]))}m(t||Ia.tags);var y=new pv(e),h,b,g,x,v,D;while(!y.eos()){if(h=y.pos,g=y.scanUntil(p),g)for(var T=0,N=g.length;T")v=[b,g,h,y.pos,l,c,n];else v=[b,g,h,y.pos];if(c++,i.push(v),b==="#"||b==="^")r.push(v);else if(b==="/"){if(D=r.pop(),!D)throw Error('Unopened section "'+g+'" at '+h);if(D[1]!==g)throw Error('Unclosed section "'+D[1]+'" at '+h)}else if(b==="name"||b==="{"||b==="&")a=!0;else if(b==="=")m(g)}if(u(),D=r.pop(),D)throw Error('Unclosed section "'+D[1]+'" at '+y.pos);return eCe(ZFe(i))}function ZFe(e){var t=[],n,r;for(var i=0,s=e.length;i0?r[r.length-1][4]:t;break;default:n.push(i)}return t}function pv(e){this.string=e,this.tail=e,this.pos=0}function ky(e,t){this.view=e,this.cache={".":this.view},this.parent=t}function ns(){this.templateCache={_cache:{},set:function(t,n){this._cache[t]=n},get:function(t){return this._cache[t]},clear:function(){this._cache={}}}}var LFe,Ny,BFe,KFe,GFe,zFe,WFe,IZ,QFe,YFe,Ia,uv;var AZ=q(()=>{/*! * mustache.js - Logic-less {{mustache}} templates with JavaScript * http://github.com/janl/mustache.js - */MFe=Object.prototype.toString,Ey=Array.isArray||function(t){return MFe.call(t)==="[object Array]"};UFe=RegExp.prototype.test;VFe=/\S/;JFe={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/","`":"`","=":"="};HFe=/\s*/,zFe=/\s+/,IZ=/\s*=/,WFe=/\s*\}/,QFe=/#|\^|\/|>|\{|&|=|!/;pv.prototype.eos=function(){return this.tail===""};pv.prototype.scan=function(t){var n=this.tail.match(t);if(!n||n.index!==0)return"";var r=n[0];return this.tail=this.tail.substring(r.length),this.pos+=r.length,r};pv.prototype.scanUntil=function(t){var n=this.tail.search(t),r;switch(n){case-1:r=this.tail,this.tail="";break;case 0:r="";break;default:r=this.tail.substring(0,n),this.tail=this.tail.substring(n)}return this.pos+=r.length,r};Sy.prototype.push=function(t){return new Sy(t,this)};Sy.prototype.lookup=function(t){var n=this.cache,r;if(n.hasOwnProperty(t))r=n[t];else{var i=this,s,o,a,l=!1;while(i){if(t.indexOf(".")>0){s=i.view,o=t.split("."),a=0;while(s!=null&&a")c=this.renderPartial(a,n,r,s);else if(l==="&")c=this.unescapedValue(a,n);else if(l==="name")c=this.escapedValue(a,n,s);else if(l==="text")c=this.rawValue(a);if(c!==void 0)o+=c}return o};ts.prototype.renderSection=function(t,n,r,i,s){var o=this,a="",l=n.lookup(t[1]);function c(d){return o.render(d,n,r,s)}if(!l)return;if(Ey(l))for(var u=0,p=l.length;u":">",'"':""","'":"'","/":"/","`":"`","=":"="};zFe=/\s*/,WFe=/\s+/,IZ=/\s*=/,QFe=/\s*\}/,YFe=/#|\^|\/|>|\{|&|=|!/;pv.prototype.eos=function(){return this.tail===""};pv.prototype.scan=function(t){var n=this.tail.match(t);if(!n||n.index!==0)return"";var r=n[0];return this.tail=this.tail.substring(r.length),this.pos+=r.length,r};pv.prototype.scanUntil=function(t){var n=this.tail.search(t),r;switch(n){case-1:r=this.tail,this.tail="";break;case 0:r="";break;default:r=this.tail.substring(0,n),this.tail=this.tail.substring(n)}return this.pos+=r.length,r};ky.prototype.push=function(t){return new ky(t,this)};ky.prototype.lookup=function(t){var n=this.cache,r;if(n.hasOwnProperty(t))r=n[t];else{var i=this,s,o,a,l=!1;while(i){if(t.indexOf(".")>0){s=i.view,o=t.split("."),a=0;while(s!=null&&a")c=this.renderPartial(a,n,r,s);else if(l==="&")c=this.unescapedValue(a,n);else if(l==="name")c=this.escapedValue(a,n,s);else if(l==="text")c=this.rawValue(a);if(c!==void 0)o+=c}return o};ns.prototype.renderSection=function(t,n,r,i,s){var o=this,a="",l=n.lookup(t[1]);function c(d){return o.render(d,n,r,s)}if(!l)return;if(Ny(l))for(var u=0,p=l.length;u0||!r))s[o]=i+s[o];return s.join(` -`)};ts.prototype.renderPartial=function(t,n,r,i){if(!r)return;var s=this.getConfigTags(i),o=ER(r)?r(t[1]):r[t[1]];if(o!=null){var a=t[6],l=t[5],c=t[4],u=o;if(l==0&&c)u=this.indentPartial(o,c,a);var p=this.parse(u,s);return this.renderTokens(p,n,r,u,i)}};ts.prototype.unescapedValue=function(t,n){var r=n.lookup(t[1]);if(r!=null)return r};ts.prototype.escapedValue=function(t,n,r){var i=this.getConfigEscape(r)||Ia.escape,s=n.lookup(t[1]);if(s!=null)return typeof s==="number"&&i===Ia.escape?String(s):i(s)};ts.prototype.rawValue=function(t){return t[1]};ts.prototype.getConfigTags=function(t){if(Ey(t))return t;else if(t&&typeof t==="object")return t.tags;else return};ts.prototype.getConfigEscape=function(t){if(t&&typeof t==="object"&&!Ey(t))return t.escape;else return};Ia={name:"mustache.js",version:"4.2.0",tags:["{{","}}"],clearCache:void 0,escape:void 0,parse:void 0,render:void 0,Scanner:void 0,Context:void 0,Writer:void 0,set templateCache(e){uv.templateCache=e},get templateCache(){return uv.templateCache}},uv=new ts;Ia.clearCache=function(){return uv.clearCache()};Ia.parse=function(t,n){return uv.parse(t,n)};Ia.render=function(t,n,r,i){if(typeof t!=="string")throw TypeError('Invalid template! Template should be a "string" but "'+LFe(t)+'" was given as the first argument for mustache#render(template, view, partials)');return uv.render(t,n,r,i)};Ia.escape=GFe;Ia.Scanner=pv;Ia.Context=Sy;Ia.Writer=ts});function kR(e){return()=>(t,n)=>e(n(t))}var i0t;var RZ=q(()=>{PZ();AZ();mn();i0t={camelCase:kR(TZ),kebabCase:kR(EZ),pascalCase:kR(SZ)}});var eCe=`# entrypoint: main.tsp # Main TypeSpec file (default: main.tsp) +`)};ns.prototype.renderPartial=function(t,n,r,i){if(!r)return;var s=this.getConfigTags(i),o=ER(r)?r(t[1]):r[t[1]];if(o!=null){var a=t[6],l=t[5],c=t[4],u=o;if(l==0&&c)u=this.indentPartial(o,c,a);var p=this.parse(u,s);return this.renderTokens(p,n,r,u,i)}};ns.prototype.unescapedValue=function(t,n){var r=n.lookup(t[1]);if(r!=null)return r};ns.prototype.escapedValue=function(t,n,r){var i=this.getConfigEscape(r)||Ia.escape,s=n.lookup(t[1]);if(s!=null)return typeof s==="number"&&i===Ia.escape?String(s):i(s)};ns.prototype.rawValue=function(t){return t[1]};ns.prototype.getConfigTags=function(t){if(Ny(t))return t;else if(t&&typeof t==="object")return t.tags;else return};ns.prototype.getConfigEscape=function(t){if(t&&typeof t==="object"&&!Ny(t))return t.escape;else return};Ia={name:"mustache.js",version:"4.2.0",tags:["{{","}}"],clearCache:void 0,escape:void 0,parse:void 0,render:void 0,Scanner:void 0,Context:void 0,Writer:void 0,set templateCache(e){uv.templateCache=e},get templateCache(){return uv.templateCache}},uv=new ns;Ia.clearCache=function(){return uv.clearCache()};Ia.parse=function(t,n){return uv.parse(t,n)};Ia.render=function(t,n,r,i){if(typeof t!=="string")throw TypeError('Invalid template! Template should be a "string" but "'+qFe(t)+'" was given as the first argument for mustache#render(template, view, partials)');return uv.render(t,n,r,i)};Ia.escape=HFe;Ia.Scanner=pv;Ia.Context=ky;Ia.Writer=ns});function kR(e){return()=>(t,n)=>e(n(t))}var o0t;var RZ=q(()=>{PZ();AZ();mn();o0t={camelCase:kR(TZ),kebabCase:kR(EZ),pascalCase:kR(SZ)}});var tCe=`# entrypoint: main.tsp # Main TypeSpec file (default: main.tsp) # extends: ../tspconfig.yaml # Extend another config file # emit: # Emitter name # - "" # warn-as-error: true # Treat warnings as errors -# output-dir: "{project-root}/_generated" # Configure the base output directory for all emitters`,f0t,m0t;var jZ=q(()=>{bo();mn();wZ();RZ();f0t=`kind: project # Marks this as a TypeSpec project -${eCe}`,m0t=` +# output-dir: "{project-root}/_generated" # Configure the base output directory for all emitters`,y0t,h0t;var jZ=q(()=>{bo();mn();wZ();RZ();y0t=`kind: project # Marks this as a TypeSpec project +${tCe}`,h0t=` # MacOS .DS_Store @@ -286,26 +286,26 @@ dist/ # Dependency directories node_modules/ -`.trim()});var FZ=q(()=>{mn()});var MT;var NR=q(()=>{(function(e){e[e.Namespace=0]="Namespace",e[e.Type=1]="Type",e[e.Class=2]="Class",e[e.Enum=3]="Enum",e[e.Interface=4]="Interface",e[e.Struct=5]="Struct",e[e.TypeParameter=6]="TypeParameter",e[e.Parameter=7]="Parameter",e[e.Variable=8]="Variable",e[e.Property=9]="Property",e[e.EnumMember=10]="EnumMember",e[e.Event=11]="Event",e[e.Function=12]="Function",e[e.Method=13]="Method",e[e.Macro=14]="Macro",e[e.Keyword=15]="Keyword",e[e.Comment=16]="Comment",e[e.String=17]="String",e[e.Number=18]="Number",e[e.Regexp=19]="Regexp",e[e.Operator=20]="Operator",e[e.DocCommentTag=21]="DocCommentTag"})(MT||(MT={}))});var CZ=q(()=>{vt();Xs();ub();It();NR()});var MZ=()=>{};function PR(e){let t=y9("TYPESPEC_DEBUG");if(!t)return!1;return t.split(",").map((r)=>r.trim()).some((r)=>{if(r===e)return!0;if(r.includes("*")){let i=r.replace(/\*/g,".*");return new RegExp(`^${i}$`).test(e)}return!1})}var OR,LT;var dv=q(()=>{Gt();OR={serverCompile:"server.compile",updateManager:"update.manager",compileConfig:"compile.config"};LT={serverCompile:{enabled:PR(OR.serverCompile)},updateManager:{enabled:PR(OR.updateManager)},compileConfig:{enabled:PR(OR.compileConfig)}}});var UZ=q(()=>{Nd();mn();sc();Gt();dv()});var BZ=()=>{};var VZ=q(async()=>{NT();dv();BZ();await st()});var GZ;var HZ=q(async()=>{Nd();zO();WD();QD();ay();Xs();mn();Gt();Qg();zg();MZ();dv();UZ();await VZ();GZ=Ar(cp(),1)});var zZ=q(async()=>{Vu();vt();Fb();Rw();Mu();cc();yr();It();await st()});var $R=q(async()=>{Vu();vt();lc();yr();It();await zZ()});var UT;var WZ=q(async()=>{Vu();sb();vt();ic();Mu();Xs();mn();It();sc();Gt();await $R();UT=Ar(cp(),1)});var uCe;var QZ=q(()=>{vt();cc();Gt();uCe=Ar(cp(),1)});var YZ=q(()=>{Gt()});var XZ=q(()=>{mn()});var IR=q(()=>{Nd();W$();Wd();YD();sc();Gt();mn()});var BT=q(()=>{Nd();XD();sc();Gt();vt();IR();Yn();Xs();mn();ol();It()});var ZZ=q(async()=>{mn();BT();It();Gt();await st()});var AR;var tee=q(()=>{vt();mn();AR=Ar(cp(),1)});var RR;var nee=q(()=>{It();Gt();RR=Ar(cp(),1)});var ree=q(()=>{bo();Gt()});var VT;var iee=q(()=>{bo();vw();Hg();mn();Gt();ree();VT=Ar(cp(),1)});var see=q(()=>{dv()});var Yo;var aee=q(async()=>{Vu();rc();fR();vt();Fb();cc();WD();QD();ay();NT();Fw();Xs();mn();ub();ol();yR();It();$X();AX();jZ();XD();FZ();Gt();CZ();QZ();YZ();XZ();tee();nee();iee();NR();see();await hh([Mb(),HZ(),WZ(),ZZ(),$R()]);Yo=Ar(cp(),1)});var lee=q(async()=>{zJ();await aee()});var cee;var jR=q(()=>{nP();cee={TypeSpec:{indexer:n7,docFromComment:tP},"TypeSpec.Prototypes":{getter:r7}}});var uee,pee;var FR=q(()=>{ul();vb();EP();uee={TypeSpec:{applyVisibilityFilter:TP,applyLifecycleUpdate:SP}},pee={TypeSpec:{encode:_D,mediaTypeHint:CP,doc:Ys,withOptionalProperties:MP,withUpdateableProperties:DP,withoutOmittedProperties:LP,withPickedProperties:qP,withoutDefaultValues:UP,summary:OP,returnsDoc:PP,errorsDoc:IP,service:Yw,error:pD,format:fD,pattern:mD,minLength:yD,maxLength:hD,minItems:gD,maxItems:bD,minValue:Wm,maxValue:Qm,minValueExclusive:Ym,maxValueExclusive:Xm,secret:vD,tag:BP,friendlyName:KP,key:JP,overload:HP,encodedName:Jw,discriminated:zP,discriminator:WP,example:wD,opExample:DD,inspectType:RP,inspectTypeName:jP,visibility:jd,removeVisibility:Hm,invisible:zm,defaultVisibility:rD,withVisibility:wP,withVisibilityFilter:iD,withLifecycleUpdate:sD,withDefaultKeyVisibility:bP,parameterVisibility:Db,returnTypeVisibility:xP,list:$7,offset:I7,pageIndex:A7,pageSize:R7,pageItems:j7,continuationToken:F7,nextLink:C7,prevLink:M7,firstLink:L7,lastLink:q7}}});var CR=q(()=>{rc()});var dee=q(()=>{vt();CR()});var mSt;var MR=q(()=>{vt();It();CR();mSt=Map.groupBy??((e,t)=>{let n=new Map,r=0;for(let i of e){let s=t(i,r++),o=n.get(s);if(o)o.push(i);else n.set(s,[i])}return n})});var mee=q(async()=>{await Mb()});var yee=q(()=>{Gt();Vu();vt();Xs();It()});var hee=()=>{};var gee=q(async()=>{Gw();vb();Q$();sc();Gt();Vu();Eb();MR();HD();vt();i$();IR();oy();ay();NT();Yn();yee();Xs();mn();Vw();BT();hee();yR();It();await hh([Mb(),mee()])});var bee=q(()=>{yP();tD()});var pkt,dkt;var st=q(async()=>{R9();YO();Eb();Od();sb();vt();i$();k5();Fb();MJ();lc();oy();ay();ac();Fw();ul();pP();XD();jR();FR();fR();dee();MR();mn();hb();ol();yr();It();bee();await hh([Mb(),lee(),gee()]);pkt={TypeSpec:{...pee.TypeSpec},"TypeSpec.Prototypes":{...cee["TypeSpec.Prototypes"]}},dkt={TypeSpec:{...uee.TypeSpec}}});var hj,CAt,MAt,Fte;var tS=q(async()=>{await st();hj=nr({name:"@typespec/streams",diagnostics:{},state:{streamOf:{description:"State for the @streamOf decorator."}}}),{reportDiagnostic:CAt,createDiagnostic:MAt,stateKeys:Fte}=hj});var gj,BAt;var bj=q(async()=>{Nn();await tS();[gj,BAt]=ze(Fte.streamOf)});var vj=q(async()=>{await hh([bj(),tS()])});var Cte={};kf(Cte,{getStreamOf:()=>gj});var _j=q(async()=>{await hh([tS(),bj(),vj()])});var Fie=z(function(o3t,o3e){o3e.exports={$schema:"https://json-schema.org/draft/2019-09/schema",$id:"https://json-schema.org/draft/2019-09/schema",$vocabulary:{"https://json-schema.org/draft/2019-09/vocab/core":!0,"https://json-schema.org/draft/2019-09/vocab/applicator":!0,"https://json-schema.org/draft/2019-09/vocab/validation":!0,"https://json-schema.org/draft/2019-09/vocab/meta-data":!0,"https://json-schema.org/draft/2019-09/vocab/format":!1,"https://json-schema.org/draft/2019-09/vocab/content":!0},$recursiveAnchor:!0,title:"Core and Validation specifications meta-schema",allOf:[{$ref:"meta/core"},{$ref:"meta/applicator"},{$ref:"meta/validation"},{$ref:"meta/meta-data"},{$ref:"meta/format"},{$ref:"meta/content"}],type:["object","boolean"],properties:{definitions:{$comment:"While no longer an official keyword as it is replaced by $defs, this keyword is retained in the meta-schema to prevent incompatible extensions as it remains in common use.",type:"object",additionalProperties:{$recursiveRef:"#"},default:{}},dependencies:{$comment:'"dependencies" is no longer a keyword, but schema authors should avoid redefining it to facilitate a smooth transition to "dependentSchemas" and "dependentRequired"',type:"object",additionalProperties:{anyOf:[{$recursiveRef:"#"},{$ref:"meta/validation#/$defs/stringArray"}]}}}}});var Cie=z(function(a3t,a3e){a3e.exports={$schema:"https://json-schema.org/draft/2019-09/schema",$id:"https://json-schema.org/draft/2019-09/meta/applicator",$vocabulary:{"https://json-schema.org/draft/2019-09/vocab/applicator":!0},$recursiveAnchor:!0,title:"Applicator vocabulary meta-schema",type:["object","boolean"],properties:{additionalItems:{$recursiveRef:"#"},unevaluatedItems:{$recursiveRef:"#"},items:{anyOf:[{$recursiveRef:"#"},{$ref:"#/$defs/schemaArray"}]},contains:{$recursiveRef:"#"},additionalProperties:{$recursiveRef:"#"},unevaluatedProperties:{$recursiveRef:"#"},properties:{type:"object",additionalProperties:{$recursiveRef:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$recursiveRef:"#"},propertyNames:{format:"regex"},default:{}},dependentSchemas:{type:"object",additionalProperties:{$recursiveRef:"#"}},propertyNames:{$recursiveRef:"#"},if:{$recursiveRef:"#"},then:{$recursiveRef:"#"},else:{$recursiveRef:"#"},allOf:{$ref:"#/$defs/schemaArray"},anyOf:{$ref:"#/$defs/schemaArray"},oneOf:{$ref:"#/$defs/schemaArray"},not:{$recursiveRef:"#"}},$defs:{schemaArray:{type:"array",minItems:1,items:{$recursiveRef:"#"}}}}});var Mie=z(function(l3t,l3e){l3e.exports={$schema:"https://json-schema.org/draft/2019-09/schema",$id:"https://json-schema.org/draft/2019-09/meta/content",$vocabulary:{"https://json-schema.org/draft/2019-09/vocab/content":!0},$recursiveAnchor:!0,title:"Content vocabulary meta-schema",type:["object","boolean"],properties:{contentMediaType:{type:"string"},contentEncoding:{type:"string"},contentSchema:{$recursiveRef:"#"}}}});var Lie=z(function(c3t,c3e){c3e.exports={$schema:"https://json-schema.org/draft/2019-09/schema",$id:"https://json-schema.org/draft/2019-09/meta/core",$vocabulary:{"https://json-schema.org/draft/2019-09/vocab/core":!0},$recursiveAnchor:!0,title:"Core vocabulary meta-schema",type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference",$comment:"Non-empty fragments not allowed.",pattern:"^[^#]*#?$"},$schema:{type:"string",format:"uri"},$anchor:{type:"string",pattern:"^[A-Za-z][-A-Za-z0-9.:_]*$"},$ref:{type:"string",format:"uri-reference"},$recursiveRef:{type:"string",format:"uri-reference"},$recursiveAnchor:{type:"boolean",default:!1},$vocabulary:{type:"object",propertyNames:{type:"string",format:"uri"},additionalProperties:{type:"boolean"}},$comment:{type:"string"},$defs:{type:"object",additionalProperties:{$recursiveRef:"#"},default:{}}}}});var qie=z(function(u3t,u3e){u3e.exports={$schema:"https://json-schema.org/draft/2019-09/schema",$id:"https://json-schema.org/draft/2019-09/meta/format",$vocabulary:{"https://json-schema.org/draft/2019-09/vocab/format":!0},$recursiveAnchor:!0,title:"Format vocabulary meta-schema",type:["object","boolean"],properties:{format:{type:"string"}}}});var Uie=z(function(p3t,p3e){p3e.exports={$schema:"https://json-schema.org/draft/2019-09/schema",$id:"https://json-schema.org/draft/2019-09/meta/meta-data",$vocabulary:{"https://json-schema.org/draft/2019-09/vocab/meta-data":!0},$recursiveAnchor:!0,title:"Meta-data vocabulary meta-schema",type:["object","boolean"],properties:{title:{type:"string"},description:{type:"string"},default:!0,deprecated:{type:"boolean",default:!1},readOnly:{type:"boolean",default:!1},writeOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0}}}});var Bie=z(function(d3t,d3e){d3e.exports={$schema:"https://json-schema.org/draft/2019-09/schema",$id:"https://json-schema.org/draft/2019-09/meta/validation",$vocabulary:{"https://json-schema.org/draft/2019-09/vocab/validation":!0},$recursiveAnchor:!0,title:"Validation vocabulary meta-schema",type:["object","boolean"],properties:{multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/$defs/nonNegativeInteger"},minLength:{$ref:"#/$defs/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},maxItems:{$ref:"#/$defs/nonNegativeInteger"},minItems:{$ref:"#/$defs/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},maxContains:{$ref:"#/$defs/nonNegativeInteger"},minContains:{$ref:"#/$defs/nonNegativeInteger",default:1},maxProperties:{$ref:"#/$defs/nonNegativeInteger"},minProperties:{$ref:"#/$defs/nonNegativeIntegerDefault0"},required:{$ref:"#/$defs/stringArray"},dependentRequired:{type:"object",additionalProperties:{$ref:"#/$defs/stringArray"}},const:!0,enum:{type:"array",items:!0},type:{anyOf:[{$ref:"#/$defs/simpleTypes"},{type:"array",items:{$ref:"#/$defs/simpleTypes"},minItems:1,uniqueItems:!0}]}},$defs:{nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{$ref:"#/$defs/nonNegativeInteger",default:0},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}}}});var Kie=z(function(Vie){Object.defineProperty(Vie,"__esModule",{value:!0});var f3e=Fie(),m3e=Cie(),y3e=Mie(),h3e=Lie(),g3e=qie(),b3e=Uie(),v3e=Bie(),_3e=["/properties"];function x3e(e){return[f3e,m3e,y3e,h3e,t(this,g3e),b3e,t(this,v3e)].forEach((n)=>this.addMetaSchema(n,void 0,!1)),this;function t(n,r){return e?n.$dataMetaSchema(r,_3e):r}}Vie.default=x3e});var bF=z(function(As,gF){Object.defineProperty(As,"__esModule",{value:!0});As.MissingRefError=As.ValidationError=As.CodeGen=As.Name=As.nil=As.stringify=As.str=As._=As.KeywordCxt=As.Ajv2019=void 0;var D3e=lu(),T3e=VO(),S3e=P1(),E3e=$1(),k3e=I1(),N3e=ig(),O3e=Kie(),hF="https://json-schema.org/draft/2019-09/schema";class Vv extends D3e.default{constructor(e={}){super({...e,dynamicRef:!0,next:!0,unevaluated:!0})}_addVocabularies(){if(super._addVocabularies(),this.addVocabulary(S3e.default),T3e.default.forEach((e)=>this.addVocabulary(e)),this.addVocabulary(E3e.default),this.addVocabulary(k3e.default),this.opts.discriminator)this.addKeyword(N3e.default)}_addDefaultMetaSchema(){super._addDefaultMetaSchema();let{$data:e,meta:t}=this.opts;if(!t)return;O3e.default.call(this,e),this.refs["http://json-schema.org/schema"]=hF}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(hF)?hF:void 0)}}As.Ajv2019=Vv;gF.exports=As=Vv;gF.exports.Ajv2019=Vv;Object.defineProperty(As,"__esModule",{value:!0});As.default=Vv;var P3e=Cp();Object.defineProperty(As,"KeywordCxt",{enumerable:!0,get:function(){return P3e.KeywordCxt}});var My=Et();Object.defineProperty(As,"_",{enumerable:!0,get:function(){return My._}});Object.defineProperty(As,"str",{enumerable:!0,get:function(){return My.str}});Object.defineProperty(As,"stringify",{enumerable:!0,get:function(){return My.stringify}});Object.defineProperty(As,"nil",{enumerable:!0,get:function(){return My.nil}});Object.defineProperty(As,"Name",{enumerable:!0,get:function(){return My.Name}});Object.defineProperty(As,"CodeGen",{enumerable:!0,get:function(){return My.CodeGen}});var $3e=zf();Object.defineProperty(As,"ValidationError",{enumerable:!0,get:function(){return $3e.default}});var I3e=Mp();Object.defineProperty(As,"MissingRefError",{enumerable:!0,get:function(){return I3e.default}})});var TS=z(function(Y3t,pse){pse.exports=class e{constructor(t,n=new Map,r=0){this.prefix=t,this._existing=n,this.counter=r}clone(){let{prefix:t,_existing:n,counter:r}=this;return new e(t,new Map(n),r)}getId(t){let n=t&&this._existing.get(t);if(n)return n;let r=this.prefix+this.counter;if(this.counter++,t)this._existing.set(t,r);return r}hasId(t){return this._existing.has(t)}getOldIds(){return[...this._existing.keys()]}}});var fse=z(function(dse){(function(e,t){if(e.setImmediate)return;var n=1,r={},i=!1,s=e.document,o;function a(g){if(typeof g!=="function")g=Function(""+g);var x=Array(arguments.length-1);for(var v=0;v"u"?typeof global>"u"?dse:global:self)});var vF=z(function(Q3e){/*! +`.trim()});var FZ=q(()=>{mn()});var MT;var NR=q(()=>{(function(e){e[e.Namespace=0]="Namespace",e[e.Type=1]="Type",e[e.Class=2]="Class",e[e.Enum=3]="Enum",e[e.Interface=4]="Interface",e[e.Struct=5]="Struct",e[e.TypeParameter=6]="TypeParameter",e[e.Parameter=7]="Parameter",e[e.Variable=8]="Variable",e[e.Property=9]="Property",e[e.EnumMember=10]="EnumMember",e[e.Event=11]="Event",e[e.Function=12]="Function",e[e.Method=13]="Method",e[e.Macro=14]="Macro",e[e.Keyword=15]="Keyword",e[e.Comment=16]="Comment",e[e.String=17]="String",e[e.Number=18]="Number",e[e.Regexp=19]="Regexp",e[e.Operator=20]="Operator",e[e.DocCommentTag=21]="DocCommentTag"})(MT||(MT={}))});var CZ=q(()=>{_t();Zs();ub();It();NR()});var MZ=()=>{};function PR(e){let t=y9("TYPESPEC_DEBUG");if(!t)return!1;return t.split(",").map((r)=>r.trim()).some((r)=>{if(r===e)return!0;if(r.includes("*")){let i=r.replace(/\*/g,".*");return new RegExp(`^${i}$`).test(e)}return!1})}var OR,LT;var dv=q(()=>{Gt();OR={serverCompile:"server.compile",updateManager:"update.manager",compileConfig:"compile.config"};LT={serverCompile:{enabled:PR(OR.serverCompile)},updateManager:{enabled:PR(OR.updateManager)},compileConfig:{enabled:PR(OR.compileConfig)}}});var UZ=q(()=>{Pd();mn();sc();Gt();dv()});var BZ=()=>{};var VZ=q(async()=>{NT();dv();BZ();await st()});var GZ;var HZ=q(async()=>{Pd();zO();WD();QD();cy();Zs();mn();Gt();Qg();zg();MZ();dv();UZ();await VZ();GZ=Rr(up(),1)});var zZ=q(async()=>{Ku();_t();Fb();Rw();Lu();cc();yr();It();await st()});var $R=q(async()=>{Ku();_t();lc();yr();It();await zZ()});var UT;var WZ=q(async()=>{Ku();sb();_t();ic();Lu();Zs();mn();It();sc();Gt();await $R();UT=Rr(up(),1)});var pCe;var QZ=q(()=>{_t();cc();Gt();pCe=Rr(up(),1)});var YZ=q(()=>{Gt()});var XZ=q(()=>{mn()});var IR=q(()=>{Pd();W$();Yd();YD();sc();Gt();mn()});var BT=q(()=>{Pd();XD();sc();Gt();_t();IR();Yn();Zs();mn();ol();It()});var ZZ=q(async()=>{mn();BT();It();Gt();await st()});var AR;var tee=q(()=>{_t();mn();AR=Rr(up(),1)});var RR;var nee=q(()=>{It();Gt();RR=Rr(up(),1)});var ree=q(()=>{bo();Gt()});var VT;var iee=q(()=>{bo();vw();Hg();mn();Gt();ree();VT=Rr(up(),1)});var see=q(()=>{dv()});var Yo;var aee=q(async()=>{Ku();rc();fR();_t();Fb();cc();WD();QD();cy();NT();Fw();Zs();mn();ub();ol();yR();It();$X();AX();jZ();XD();FZ();Gt();CZ();QZ();YZ();XZ();tee();nee();iee();NR();see();await hh([Mb(),HZ(),WZ(),ZZ(),$R()]);Yo=Rr(up(),1)});var lee=q(async()=>{zJ();await aee()});var cee;var jR=q(()=>{nP();cee={TypeSpec:{indexer:n7,docFromComment:tP},"TypeSpec.Prototypes":{getter:r7}}});var uee,pee;var FR=q(()=>{ul();vb();EP();uee={TypeSpec:{applyVisibilityFilter:TP,applyLifecycleUpdate:SP}},pee={TypeSpec:{encode:_D,mediaTypeHint:CP,doc:Xs,withOptionalProperties:MP,withUpdateableProperties:DP,withoutOmittedProperties:LP,withPickedProperties:qP,withoutDefaultValues:UP,summary:OP,returnsDoc:PP,errorsDoc:IP,service:Yw,error:pD,format:fD,pattern:mD,minLength:yD,maxLength:hD,minItems:gD,maxItems:bD,minValue:Ym,maxValue:Xm,minValueExclusive:Zm,maxValueExclusive:ey,secret:vD,tag:BP,friendlyName:KP,key:JP,overload:HP,encodedName:Jw,discriminated:zP,discriminator:WP,example:wD,opExample:DD,inspectType:RP,inspectTypeName:jP,visibility:Cd,removeVisibility:Wm,invisible:Qm,defaultVisibility:rD,withVisibility:wP,withVisibilityFilter:iD,withLifecycleUpdate:sD,withDefaultKeyVisibility:bP,parameterVisibility:Db,returnTypeVisibility:xP,list:$7,offset:I7,pageIndex:A7,pageSize:R7,pageItems:j7,continuationToken:F7,nextLink:C7,prevLink:M7,firstLink:L7,lastLink:q7}}});var CR=q(()=>{rc()});var dee=q(()=>{_t();CR()});var hSt;var MR=q(()=>{_t();It();CR();hSt=Map.groupBy??((e,t)=>{let n=new Map,r=0;for(let i of e){let s=t(i,r++),o=n.get(s);if(o)o.push(i);else n.set(s,[i])}return n})});var mee=q(async()=>{await Mb()});var yee=q(()=>{Gt();Ku();_t();Zs();It()});var hee=()=>{};var gee=q(async()=>{Gw();vb();Q$();sc();Gt();Ku();Eb();MR();HD();_t();i$();IR();ly();cy();NT();Yn();yee();Zs();mn();Vw();BT();hee();yR();It();await hh([Mb(),mee()])});var bee=q(()=>{yP();tD()});var fkt,mkt;var st=q(async()=>{R9();YO();Eb();$d();sb();_t();i$();k5();Fb();MJ();lc();ly();cy();ac();Fw();ul();pP();XD();jR();FR();fR();dee();MR();mn();hb();ol();yr();It();bee();await hh([Mb(),lee(),gee()]);fkt={TypeSpec:{...pee.TypeSpec},"TypeSpec.Prototypes":{...cee["TypeSpec.Prototypes"]}},mkt={TypeSpec:{...uee.TypeSpec}}});var hj,LAt,qAt,Fte;var tS=q(async()=>{await st();hj=nr({name:"@typespec/streams",diagnostics:{},state:{streamOf:{description:"State for the @streamOf decorator."}}}),{reportDiagnostic:LAt,createDiagnostic:qAt,stateKeys:Fte}=hj});var gj,KAt;var bj=q(async()=>{Nn();await tS();[gj,KAt]=ze(Fte.streamOf)});var vj=q(async()=>{await hh([bj(),tS()])});var Cte={};Of(Cte,{getStreamOf:()=>gj});var _j=q(async()=>{await hh([tS(),bj(),vj()])});var Fie=z(function(l3t,a3e){a3e.exports={$schema:"https://json-schema.org/draft/2019-09/schema",$id:"https://json-schema.org/draft/2019-09/schema",$vocabulary:{"https://json-schema.org/draft/2019-09/vocab/core":!0,"https://json-schema.org/draft/2019-09/vocab/applicator":!0,"https://json-schema.org/draft/2019-09/vocab/validation":!0,"https://json-schema.org/draft/2019-09/vocab/meta-data":!0,"https://json-schema.org/draft/2019-09/vocab/format":!1,"https://json-schema.org/draft/2019-09/vocab/content":!0},$recursiveAnchor:!0,title:"Core and Validation specifications meta-schema",allOf:[{$ref:"meta/core"},{$ref:"meta/applicator"},{$ref:"meta/validation"},{$ref:"meta/meta-data"},{$ref:"meta/format"},{$ref:"meta/content"}],type:["object","boolean"],properties:{definitions:{$comment:"While no longer an official keyword as it is replaced by $defs, this keyword is retained in the meta-schema to prevent incompatible extensions as it remains in common use.",type:"object",additionalProperties:{$recursiveRef:"#"},default:{}},dependencies:{$comment:'"dependencies" is no longer a keyword, but schema authors should avoid redefining it to facilitate a smooth transition to "dependentSchemas" and "dependentRequired"',type:"object",additionalProperties:{anyOf:[{$recursiveRef:"#"},{$ref:"meta/validation#/$defs/stringArray"}]}}}}});var Cie=z(function(c3t,l3e){l3e.exports={$schema:"https://json-schema.org/draft/2019-09/schema",$id:"https://json-schema.org/draft/2019-09/meta/applicator",$vocabulary:{"https://json-schema.org/draft/2019-09/vocab/applicator":!0},$recursiveAnchor:!0,title:"Applicator vocabulary meta-schema",type:["object","boolean"],properties:{additionalItems:{$recursiveRef:"#"},unevaluatedItems:{$recursiveRef:"#"},items:{anyOf:[{$recursiveRef:"#"},{$ref:"#/$defs/schemaArray"}]},contains:{$recursiveRef:"#"},additionalProperties:{$recursiveRef:"#"},unevaluatedProperties:{$recursiveRef:"#"},properties:{type:"object",additionalProperties:{$recursiveRef:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$recursiveRef:"#"},propertyNames:{format:"regex"},default:{}},dependentSchemas:{type:"object",additionalProperties:{$recursiveRef:"#"}},propertyNames:{$recursiveRef:"#"},if:{$recursiveRef:"#"},then:{$recursiveRef:"#"},else:{$recursiveRef:"#"},allOf:{$ref:"#/$defs/schemaArray"},anyOf:{$ref:"#/$defs/schemaArray"},oneOf:{$ref:"#/$defs/schemaArray"},not:{$recursiveRef:"#"}},$defs:{schemaArray:{type:"array",minItems:1,items:{$recursiveRef:"#"}}}}});var Mie=z(function(u3t,c3e){c3e.exports={$schema:"https://json-schema.org/draft/2019-09/schema",$id:"https://json-schema.org/draft/2019-09/meta/content",$vocabulary:{"https://json-schema.org/draft/2019-09/vocab/content":!0},$recursiveAnchor:!0,title:"Content vocabulary meta-schema",type:["object","boolean"],properties:{contentMediaType:{type:"string"},contentEncoding:{type:"string"},contentSchema:{$recursiveRef:"#"}}}});var Lie=z(function(p3t,u3e){u3e.exports={$schema:"https://json-schema.org/draft/2019-09/schema",$id:"https://json-schema.org/draft/2019-09/meta/core",$vocabulary:{"https://json-schema.org/draft/2019-09/vocab/core":!0},$recursiveAnchor:!0,title:"Core vocabulary meta-schema",type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference",$comment:"Non-empty fragments not allowed.",pattern:"^[^#]*#?$"},$schema:{type:"string",format:"uri"},$anchor:{type:"string",pattern:"^[A-Za-z][-A-Za-z0-9.:_]*$"},$ref:{type:"string",format:"uri-reference"},$recursiveRef:{type:"string",format:"uri-reference"},$recursiveAnchor:{type:"boolean",default:!1},$vocabulary:{type:"object",propertyNames:{type:"string",format:"uri"},additionalProperties:{type:"boolean"}},$comment:{type:"string"},$defs:{type:"object",additionalProperties:{$recursiveRef:"#"},default:{}}}}});var qie=z(function(d3t,p3e){p3e.exports={$schema:"https://json-schema.org/draft/2019-09/schema",$id:"https://json-schema.org/draft/2019-09/meta/format",$vocabulary:{"https://json-schema.org/draft/2019-09/vocab/format":!0},$recursiveAnchor:!0,title:"Format vocabulary meta-schema",type:["object","boolean"],properties:{format:{type:"string"}}}});var Uie=z(function(f3t,d3e){d3e.exports={$schema:"https://json-schema.org/draft/2019-09/schema",$id:"https://json-schema.org/draft/2019-09/meta/meta-data",$vocabulary:{"https://json-schema.org/draft/2019-09/vocab/meta-data":!0},$recursiveAnchor:!0,title:"Meta-data vocabulary meta-schema",type:["object","boolean"],properties:{title:{type:"string"},description:{type:"string"},default:!0,deprecated:{type:"boolean",default:!1},readOnly:{type:"boolean",default:!1},writeOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0}}}});var Bie=z(function(m3t,f3e){f3e.exports={$schema:"https://json-schema.org/draft/2019-09/schema",$id:"https://json-schema.org/draft/2019-09/meta/validation",$vocabulary:{"https://json-schema.org/draft/2019-09/vocab/validation":!0},$recursiveAnchor:!0,title:"Validation vocabulary meta-schema",type:["object","boolean"],properties:{multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/$defs/nonNegativeInteger"},minLength:{$ref:"#/$defs/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},maxItems:{$ref:"#/$defs/nonNegativeInteger"},minItems:{$ref:"#/$defs/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},maxContains:{$ref:"#/$defs/nonNegativeInteger"},minContains:{$ref:"#/$defs/nonNegativeInteger",default:1},maxProperties:{$ref:"#/$defs/nonNegativeInteger"},minProperties:{$ref:"#/$defs/nonNegativeIntegerDefault0"},required:{$ref:"#/$defs/stringArray"},dependentRequired:{type:"object",additionalProperties:{$ref:"#/$defs/stringArray"}},const:!0,enum:{type:"array",items:!0},type:{anyOf:[{$ref:"#/$defs/simpleTypes"},{type:"array",items:{$ref:"#/$defs/simpleTypes"},minItems:1,uniqueItems:!0}]}},$defs:{nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{$ref:"#/$defs/nonNegativeInteger",default:0},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}}}});var Kie=z(function(Vie){Object.defineProperty(Vie,"__esModule",{value:!0});var m3e=Fie(),y3e=Cie(),h3e=Mie(),g3e=Lie(),b3e=qie(),v3e=Uie(),_3e=Bie(),x3e=["/properties"];function w3e(e){return[m3e,y3e,h3e,g3e,t(this,b3e),v3e,t(this,_3e)].forEach((n)=>this.addMetaSchema(n,void 0,!1)),this;function t(n,r){return e?n.$dataMetaSchema(r,x3e):r}}Vie.default=w3e});var bF=z(function(Rs,gF){Object.defineProperty(Rs,"__esModule",{value:!0});Rs.MissingRefError=Rs.ValidationError=Rs.CodeGen=Rs.Name=Rs.nil=Rs.stringify=Rs.str=Rs._=Rs.KeywordCxt=Rs.Ajv2019=void 0;var T3e=cu(),S3e=VO(),E3e=P1(),k3e=$1(),N3e=I1(),O3e=ig(),P3e=Kie(),hF="https://json-schema.org/draft/2019-09/schema";class Vv extends T3e.default{constructor(e={}){super({...e,dynamicRef:!0,next:!0,unevaluated:!0})}_addVocabularies(){if(super._addVocabularies(),this.addVocabulary(E3e.default),S3e.default.forEach((e)=>this.addVocabulary(e)),this.addVocabulary(k3e.default),this.addVocabulary(N3e.default),this.opts.discriminator)this.addKeyword(O3e.default)}_addDefaultMetaSchema(){super._addDefaultMetaSchema();let{$data:e,meta:t}=this.opts;if(!t)return;P3e.default.call(this,e),this.refs["http://json-schema.org/schema"]=hF}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(hF)?hF:void 0)}}Rs.Ajv2019=Vv;gF.exports=Rs=Vv;gF.exports.Ajv2019=Vv;Object.defineProperty(Rs,"__esModule",{value:!0});Rs.default=Vv;var $3e=Lp();Object.defineProperty(Rs,"KeywordCxt",{enumerable:!0,get:function(){return $3e.KeywordCxt}});var qy=kt();Object.defineProperty(Rs,"_",{enumerable:!0,get:function(){return qy._}});Object.defineProperty(Rs,"str",{enumerable:!0,get:function(){return qy.str}});Object.defineProperty(Rs,"stringify",{enumerable:!0,get:function(){return qy.stringify}});Object.defineProperty(Rs,"nil",{enumerable:!0,get:function(){return qy.nil}});Object.defineProperty(Rs,"Name",{enumerable:!0,get:function(){return qy.Name}});Object.defineProperty(Rs,"CodeGen",{enumerable:!0,get:function(){return qy.CodeGen}});var I3e=Qf();Object.defineProperty(Rs,"ValidationError",{enumerable:!0,get:function(){return I3e.default}});var A3e=qp();Object.defineProperty(Rs,"MissingRefError",{enumerable:!0,get:function(){return A3e.default}})});var TS=z(function(Z3t,pse){pse.exports=class e{constructor(t,n=new Map,r=0){this.prefix=t,this._existing=n,this.counter=r}clone(){let{prefix:t,_existing:n,counter:r}=this;return new e(t,new Map(n),r)}getId(t){let n=t&&this._existing.get(t);if(n)return n;let r=this.prefix+this.counter;if(this.counter++,t)this._existing.set(t,r);return r}hasId(t){return this._existing.has(t)}getOldIds(){return[...this._existing.keys()]}}});var fse=z(function(dse){(function(e,t){if(e.setImmediate)return;var n=1,r={},i=!1,s=e.document,o;function a(g){if(typeof g!=="function")g=Function(""+g);var x=Array(arguments.length-1);for(var v=0;v"u"?typeof global>"u"?dse:global:self)});var vF=z(function(Y3e){/*! * Copyright (c) 2023 Digital Bazaar, Inc. All rights reserved. - */fse();Q3e.setImmediate=setImmediate;Q3e.crypto=globalThis.crypto;var mse=[];for(let e=0;e<=255;++e)mse.push(e.toString(16).padStart(2,"0"));Q3e.bufferToHex=function(t){let n="",r=new Uint8Array(t);for(let i=0;ii)&&(c&&a>0&&l>t[a-1]||!c&&at[a+1]))i=l,s=a}if(i===null)this.done=!0;else{let a=n.get(i)?s-1:s+1;t[s]=t[a],t[a]=i;for(let l of t)if(l>i)n.set(l,!n.get(l))}return r}}});var kS=z(function(nBt,wse){/*! + */gse.exports=class{constructor(t){this.current=t.sort(),this.done=!1,this.dir=new Map;for(let n=0;ni)&&(c&&a>0&&l>t[a-1]||!c&&at[a+1]))i=l,s=a}if(i===null)this.done=!0;else{let a=n.get(i)?s-1:s+1;t[s]=t[a],t[a]=i;for(let l of t)if(l>i)n.set(l,!n.get(l))}return r}}});var kS=z(function(iBt,wse){/*! * Copyright (c) 2016-2022 Digital Bazaar, Inc. All rights reserved. - */var bse="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString",Ly={};(()=>{let t="A-Za-z"+"À-Ö"+"Ø-ö"+"ø-˿"+"Ͱ-ͽ"+"Ϳ-῿"+"‌-‍"+"⁰-↏"+"Ⰰ-⿯"+"、-퟿"+"豈-﷏"+"ﷰ-�"+"_",n=t+"0-9-"+"·"+"̀-ͯ"+"‿-⁀",r="_:((?:["+t+"0-9])(?:(?:["+n+".])*(?:["+n+"]))?)",i="\\\\u[0-9A-Fa-f]{4}",s="\\\\U[0-9A-Fa-f]{8}",o='(?:<((?:[^\x00- <>"{}|^`\\\\]|\\\\u[0-9A-Fa-f]{4}|\\\\U[0-9A-Fa-f]{8})*)>)',a=r,l='"([^"\\\\]*(?:\\\\.[^"\\\\]*)*)"',c="(?:\\^\\^"+o+")",u="(?:@([a-zA-Z]+(?:-[a-zA-Z0-9]+)*))",p='(?:"([^"\\\\]*(?:\\\\.[^"\\\\]*)*)"(?:'+c+"|(?:@([a-zA-Z]+(?:-[a-zA-Z0-9]+)*)))?)",d="[ \\t]+",f="[ \\t]*",m="(?:"+o+"|"+a+")[ \\t]+",y=o+"[ \\t]+",h="(?:"+o+"|"+a+"|"+p+")[ \\t]*",b="(?:\\.|(?:(?:"+o+"|"+a+")[ \\t]*\\.))";Ly.eoln=/(?:\r\n)|(?:\n)|(?:\r)/g,Ly.empty=new RegExp("^[ \\t]*$"),Ly.quad=new RegExp("^[ \\t]*"+m+y+h+b+"[ \\t]*$")})();wse.exports=class e{static parse(t){let n=[],r={},i=t.split(Ly.eoln),s=0;for(let o of i){if(s++,Ly.empty.test(o))continue;let a=o.match(Ly.quad);if(a===null)throw Error("N-Quads parse error on line "+s+".");let l={subject:null,predicate:null,object:null,graph:null};if(a[1]!==void 0)l.subject={termType:"NamedNode",value:Jv(a[1])};else l.subject={termType:"BlankNode",value:a[2]};if(l.predicate={termType:"NamedNode",value:Jv(a[3])},a[4]!==void 0)l.object={termType:"NamedNode",value:Jv(a[4])};else if(a[5]!==void 0)l.object={termType:"BlankNode",value:a[5]};else{if(l.object={termType:"Literal",value:void 0,datatype:{termType:"NamedNode"}},a[7]!==void 0)l.object.datatype.value=Jv(a[7]);else if(a[8]!==void 0)l.object.datatype.value=bse,l.object.language=a[8];else l.object.datatype.value="http://www.w3.org/2001/XMLSchema#string";l.object.value=rBe(a[6])}if(a[9]!==void 0)l.graph={termType:"NamedNode",value:Jv(a[9])};else if(a[10]!==void 0)l.graph={termType:"BlankNode",value:a[10]};else l.graph={termType:"DefaultGraph",value:""};if(!(l.graph.value in r))r[l.graph.value]=[l],n.push(l);else{let c=!0,u=r[l.graph.value];for(let p of u)if(tBe(p,l)){c=!1;break}if(c)u.push(l),n.push(l)}}return n}static serialize(t){let n=[];for(let r of t)n.push(e.serializeQuad(r));return n.sort().join("")}static serializeQuadComponents(t,n,r,i){let s="";if(t.termType==="NamedNode")s+=`<${Kv(t.value)}>`;else s+=`_:${t.value}`;if(n.termType==="NamedNode")s+=` <${Kv(n.value)}> `;else s+=` _:${n.value} `;if(r.termType==="NamedNode")s+=`<${Kv(r.value)}>`;else if(r.termType==="BlankNode")s+=`_:${r.value}`;else if(s+=`"${nBe(r.value)}"`,r.datatype.value===bse){if(r.language)s+=`@${r.language}`}else if(r.datatype.value!=="http://www.w3.org/2001/XMLSchema#string")s+=`^^<${Kv(r.datatype.value)}>`;if(i.termType==="NamedNode")s+=` <${Kv(i.value)}>`;else if(i.termType==="BlankNode")s+=` _:${i.value}`;return s+=` . -`,s}static serializeQuad(t){return e.serializeQuadComponents(t.subject,t.predicate,t.object,t.graph)}};function tBe(e,t){if(!(e.subject.termType===t.subject.termType&&e.object.termType===t.object.termType))return!1;if(!(e.subject.value===t.subject.value&&e.predicate.value===t.predicate.value&&e.object.value===t.object.value))return!1;if(e.object.termType!=="Literal")return!0;return e.object.datatype.termType===t.object.datatype.termType&&e.object.language===t.object.language&&e.object.datatype.value===t.object.datatype.value}var SS=/[\u0000-\u001F\u007F"\\]/g,Ac=[];for(let e=0;e<=127;++e)if(SS.test(String.fromCharCode(e)))Ac[e]="\\u"+e.toString(16).toUpperCase().padStart(4,"0"),SS.lastIndex=0;Ac["\b".codePointAt(0)]="\\b";Ac["\t".codePointAt(0)]="\\t";Ac[` -`.codePointAt(0)]="\\n";Ac["\f".codePointAt(0)]="\\f";Ac["\r".codePointAt(0)]="\\r";Ac['"'.codePointAt(0)]="\\\"";Ac["\\".codePointAt(0)]="\\\\";function nBe(e){if(!SS.test(e))return e;return e.replace(SS,function(t){return Ac[t.codePointAt(0)]})}var vse=/(?:\\([btnfr"'\\]))|(?:\\u([0-9A-Fa-f]{4}))|(?:\\U([0-9A-Fa-f]{8}))/g;function rBe(e){if(!vse.test(e))return e;return e.replace(vse,function(t,n,r,i){if(n)switch(n){case"b":return"\b";case"t":return"\t";case"n":return` -`;case"f":return"\f";case"r":return"\r";case'"':return'"';case"'":return"'";case"\\":return"\\"}if(r)return String.fromCharCode(parseInt(r,16));if(i)return String.fromCodePoint(parseInt(i,16))})}var ES=/[\u0000-\u0020<>"{}|^`\\]/g,xse=[];for(let e=0;e<=127;++e)if(ES.test(String.fromCharCode(e)))xse[e]="\\u"+e.toString(16).toUpperCase().padStart(4,"0"),ES.lastIndex=0;function Kv(e){if(!ES.test(e))return e;return e.replace(ES,function(t){return xse[t.codePointAt(0)]})}var _se=/(?:\\u([0-9A-Fa-f]{4}))|(?:\\U([0-9A-Fa-f]{8}))/g;function Jv(e){if(!_se.test(e))return e;return e.replace(_se,function(t,n,r){if(n)return String.fromCharCode(parseInt(n,16));if(r)return String.fromCodePoint(parseInt(r,16))})}});var Ese=z(function(rBt,Sse){/*! + */var bse="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString",Uy={};(()=>{let t="A-Za-z"+"À-Ö"+"Ø-ö"+"ø-˿"+"Ͱ-ͽ"+"Ϳ-῿"+"‌-‍"+"⁰-↏"+"Ⰰ-⿯"+"、-퟿"+"豈-﷏"+"ﷰ-�"+"_",n=t+"0-9-"+"·"+"̀-ͯ"+"‿-⁀",r="_:((?:["+t+"0-9])(?:(?:["+n+".])*(?:["+n+"]))?)",i="\\\\u[0-9A-Fa-f]{4}",s="\\\\U[0-9A-Fa-f]{8}",o='(?:<((?:[^\x00- <>"{}|^`\\\\]|\\\\u[0-9A-Fa-f]{4}|\\\\U[0-9A-Fa-f]{8})*)>)',a=r,l='"([^"\\\\]*(?:\\\\.[^"\\\\]*)*)"',c="(?:\\^\\^"+o+")",u="(?:@([a-zA-Z]+(?:-[a-zA-Z0-9]+)*))",p='(?:"([^"\\\\]*(?:\\\\.[^"\\\\]*)*)"(?:'+c+"|(?:@([a-zA-Z]+(?:-[a-zA-Z0-9]+)*)))?)",d="[ \\t]+",f="[ \\t]*",m="(?:"+o+"|"+a+")[ \\t]+",y=o+"[ \\t]+",h="(?:"+o+"|"+a+"|"+p+")[ \\t]*",b="(?:\\.|(?:(?:"+o+"|"+a+")[ \\t]*\\.))";Uy.eoln=/(?:\r\n)|(?:\n)|(?:\r)/g,Uy.empty=new RegExp("^[ \\t]*$"),Uy.quad=new RegExp("^[ \\t]*"+m+y+h+b+"[ \\t]*$")})();wse.exports=class e{static parse(t){let n=[],r={},i=t.split(Uy.eoln),s=0;for(let o of i){if(s++,Uy.empty.test(o))continue;let a=o.match(Uy.quad);if(a===null)throw Error("N-Quads parse error on line "+s+".");let l={subject:null,predicate:null,object:null,graph:null};if(a[1]!==void 0)l.subject={termType:"NamedNode",value:Jv(a[1])};else l.subject={termType:"BlankNode",value:a[2]};if(l.predicate={termType:"NamedNode",value:Jv(a[3])},a[4]!==void 0)l.object={termType:"NamedNode",value:Jv(a[4])};else if(a[5]!==void 0)l.object={termType:"BlankNode",value:a[5]};else{if(l.object={termType:"Literal",value:void 0,datatype:{termType:"NamedNode"}},a[7]!==void 0)l.object.datatype.value=Jv(a[7]);else if(a[8]!==void 0)l.object.datatype.value=bse,l.object.language=a[8];else l.object.datatype.value="http://www.w3.org/2001/XMLSchema#string";l.object.value=iBe(a[6])}if(a[9]!==void 0)l.graph={termType:"NamedNode",value:Jv(a[9])};else if(a[10]!==void 0)l.graph={termType:"BlankNode",value:a[10]};else l.graph={termType:"DefaultGraph",value:""};if(!(l.graph.value in r))r[l.graph.value]=[l],n.push(l);else{let c=!0,u=r[l.graph.value];for(let p of u)if(nBe(p,l)){c=!1;break}if(c)u.push(l),n.push(l)}}return n}static serialize(t){let n=[];for(let r of t)n.push(e.serializeQuad(r));return n.sort().join("")}static serializeQuadComponents(t,n,r,i){let s="";if(t.termType==="NamedNode")s+=`<${Kv(t.value)}>`;else s+=`_:${t.value}`;if(n.termType==="NamedNode")s+=` <${Kv(n.value)}> `;else s+=` _:${n.value} `;if(r.termType==="NamedNode")s+=`<${Kv(r.value)}>`;else if(r.termType==="BlankNode")s+=`_:${r.value}`;else if(s+=`"${rBe(r.value)}"`,r.datatype.value===bse){if(r.language)s+=`@${r.language}`}else if(r.datatype.value!=="http://www.w3.org/2001/XMLSchema#string")s+=`^^<${Kv(r.datatype.value)}>`;if(i.termType==="NamedNode")s+=` <${Kv(i.value)}>`;else if(i.termType==="BlankNode")s+=` _:${i.value}`;return s+=` . +`,s}static serializeQuad(t){return e.serializeQuadComponents(t.subject,t.predicate,t.object,t.graph)}};function nBe(e,t){if(!(e.subject.termType===t.subject.termType&&e.object.termType===t.object.termType))return!1;if(!(e.subject.value===t.subject.value&&e.predicate.value===t.predicate.value&&e.object.value===t.object.value))return!1;if(e.object.termType!=="Literal")return!0;return e.object.datatype.termType===t.object.datatype.termType&&e.object.language===t.object.language&&e.object.datatype.value===t.object.datatype.value}var SS=/[\u0000-\u001F\u007F"\\]/g,Ac=[];for(let e=0;e<=127;++e)if(SS.test(String.fromCharCode(e)))Ac[e]="\\u"+e.toString(16).toUpperCase().padStart(4,"0"),SS.lastIndex=0;Ac["\b".codePointAt(0)]="\\b";Ac["\t".codePointAt(0)]="\\t";Ac[` +`.codePointAt(0)]="\\n";Ac["\f".codePointAt(0)]="\\f";Ac["\r".codePointAt(0)]="\\r";Ac['"'.codePointAt(0)]="\\\"";Ac["\\".codePointAt(0)]="\\\\";function rBe(e){if(!SS.test(e))return e;return e.replace(SS,function(t){return Ac[t.codePointAt(0)]})}var vse=/(?:\\([btnfr"'\\]))|(?:\\u([0-9A-Fa-f]{4}))|(?:\\U([0-9A-Fa-f]{8}))/g;function iBe(e){if(!vse.test(e))return e;return e.replace(vse,function(t,n,r,i){if(n)switch(n){case"b":return"\b";case"t":return"\t";case"n":return` +`;case"f":return"\f";case"r":return"\r";case'"':return'"';case"'":return"'";case"\\":return"\\"}if(r)return String.fromCharCode(parseInt(r,16));if(i)return String.fromCodePoint(parseInt(i,16))})}var ES=/[\u0000-\u0020<>"{}|^`\\]/g,xse=[];for(let e=0;e<=127;++e)if(ES.test(String.fromCharCode(e)))xse[e]="\\u"+e.toString(16).toUpperCase().padStart(4,"0"),ES.lastIndex=0;function Kv(e){if(!ES.test(e))return e;return e.replace(ES,function(t){return xse[t.codePointAt(0)]})}var _se=/(?:\\u([0-9A-Fa-f]{4}))|(?:\\U([0-9A-Fa-f]{8}))/g;function Jv(e){if(!_se.test(e))return e;return e.replace(_se,function(t,n,r){if(n)return String.fromCharCode(parseInt(n,16));if(r)return String.fromCodePoint(parseInt(r,16))})}});var Ese=z(function(sBt,Sse){/*! * Copyright (c) 2016-2023 Digital Bazaar, Inc. All rights reserved. - */var Dse=TS(),iBe=xF(),sBe=wF(),Tse=kS(),{setImmediate:oBe}=vF();Sse.exports=class{constructor({createMessageDigest:t=null,messageDigestAlgorithm:n="sha256",canonicalIdMap:r=new Map,maxWorkFactor:i=1,maxDeepIterations:s=-1,signal:o=null}={}){this.name="RDFC-1.0",this.blankNodeInfo=new Map,this.canonicalIssuer=new Dse("c14n",r),this.createMessageDigest=t||(()=>new iBe(n)),this.maxWorkFactor=i,this.maxDeepIterations=s,this.remainingDeepIterations=0,this.signal=o,this.quads=null}async main(t){this.quads=t;for(let l of t)this._addBlankNodeQuadInfo({quad:l,component:l.subject}),this._addBlankNodeQuadInfo({quad:l,component:l.object}),this._addBlankNodeQuadInfo({quad:l,component:l.graph});let n=new Map,r=[...this.blankNodeInfo.keys()],i=0;for(let l of r){if(++i%100===0)await this._yield();await this._hashAndTrackBlankNode({id:l,hashToBlankNodes:n})}let s=[...n.keys()].sort(),o=[];for(let l of s){let c=n.get(l);if(c.length>1){o.push(c);continue}let u=c[0];this.canonicalIssuer.getId(u)}if(this.maxDeepIterations<0)if(this.maxWorkFactor===0)this.maxDeepIterations=0;else if(this.maxWorkFactor===1/0)this.maxDeepIterations=1/0;else{let l=o.reduce((c,u)=>c+u.length,0);this.maxDeepIterations=l**this.maxWorkFactor}if(this.maxDeepIterations>Number.MAX_SAFE_INTEGER)this.maxDeepIterations=1/0;this.remainingDeepIterations=this.maxDeepIterations;for(let l of o){let c=[];for(let u of l){if(this.canonicalIssuer.hasId(u))continue;let p=new Dse("b");p.getId(u);let d=await this.hashNDegreeQuads(u,p);c.push(d)}c.sort(aBe);for(let u of c){let p=u.issuer.getOldIds();for(let d of p)this.canonicalIssuer.getId(d)}}let a=[];for(let l of this.quads){let c=Tse.serializeQuadComponents(this._componentWithCanonicalId(l.subject),l.predicate,this._componentWithCanonicalId(l.object),this._componentWithCanonicalId(l.graph));a.push(c)}return a.sort(),a.join("")}async hashFirstDegreeQuads(t){let n=[],r=this.blankNodeInfo.get(t),i=r.quads;for(let o of i)n.push(Tse.serializeQuadComponents(this.modifyFirstDegreeComponent(t,o.subject,"subject"),o.predicate,this.modifyFirstDegreeComponent(t,o.object,"object"),this.modifyFirstDegreeComponent(t,o.graph,"graph")));n.sort();let s=this.createMessageDigest();for(let o of n)s.update(o);return r.hash=await s.digest(),r.hash}async hashRelatedBlankNode(t,n,r,i){let s=this.createMessageDigest();if(s.update(i),i!=="g")s.update(this.getRelatedPredicate(n));let o;if(this.canonicalIssuer.hasId(t))o="_:"+this.canonicalIssuer.getId(t);else if(r.hasId(t))o="_:"+r.getId(t);else o=this.blankNodeInfo.get(t).hash;return s.update(o),s.digest()}async hashNDegreeQuads(t,n){if(this.remainingDeepIterations===0)throw Error(`Maximum deep iterations exceeded (${this.maxDeepIterations}).`);this.remainingDeepIterations--;let r=this.createMessageDigest(),i=await this.createHashToRelated(t,n),s=[...i.keys()].sort();for(let o of s){r.update(o);let a="",l,c=new sBe(i.get(o)),u=0;while(c.hasNext()){let p=c.next();if(++u%3===0){if(this.signal&&this.signal.aborted)throw Error(`Abort signal received: "${this.signal.reason}".`);await this._yield()}let d=n.clone(),f="",m=[],y=!1;for(let h of p){if(this.canonicalIssuer.hasId(h))f+="_:"+this.canonicalIssuer.getId(h);else{if(!d.hasId(h))m.push(h);f+="_:"+d.getId(h)}if(a.length!==0&&f>a){y=!0;break}}if(y)continue;for(let h of m){let b=await this.hashNDegreeQuads(h,d);if(f+="_:"+d.getId(h),f+=`<${b.hash}>`,d=b.issuer,a.length!==0&&f>a){y=!0;break}}if(y)continue;if(a.length===0||f`}async createHashToRelated(t,n){let r=new Map,i=this.blankNodeInfo.get(t).quads,s=0;for(let o of i){if(++s%100===0)await this._yield();await Promise.all([this._addRelatedBlankNodeHash({quad:o,component:o.subject,position:"s",id:t,issuer:n,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:o,component:o.object,position:"o",id:t,issuer:n,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:o,component:o.graph,position:"g",id:t,issuer:n,hashToRelated:r})])}return r}async _hashAndTrackBlankNode({id:t,hashToBlankNodes:n}){let r=await this.hashFirstDegreeQuads(t),i=n.get(r);if(!i)n.set(r,[t]);else i.push(t)}_addBlankNodeQuadInfo({quad:t,component:n}){if(n.termType!=="BlankNode")return;let r=n.value,i=this.blankNodeInfo.get(r);if(i)i.quads.add(t);else this.blankNodeInfo.set(r,{quads:new Set([t]),hash:null})}async _addRelatedBlankNodeHash({quad:t,component:n,position:r,id:i,issuer:s,hashToRelated:o}){if(!(n.termType==="BlankNode"&&n.value!==i))return;let a=n.value,l=await this.hashRelatedBlankNode(a,t,s,r),c=o.get(l);if(c)c.push(a);else o.set(l,[a])}_componentWithCanonicalId(t){if(t.termType==="BlankNode"&&!t.value.startsWith(this.canonicalIssuer.prefix))return{termType:"BlankNode",value:this.canonicalIssuer.getId(t.value)};return t}async _yield(){return new Promise((t)=>oBe(t))}};function aBe(e,t){return e.hasht.hash?1:0}});var Pse=z(function(iBt,Ose){/*! + */var Dse=TS(),sBe=xF(),oBe=wF(),Tse=kS(),{setImmediate:aBe}=vF();Sse.exports=class{constructor({createMessageDigest:t=null,messageDigestAlgorithm:n="sha256",canonicalIdMap:r=new Map,maxWorkFactor:i=1,maxDeepIterations:s=-1,signal:o=null}={}){this.name="RDFC-1.0",this.blankNodeInfo=new Map,this.canonicalIssuer=new Dse("c14n",r),this.createMessageDigest=t||(()=>new sBe(n)),this.maxWorkFactor=i,this.maxDeepIterations=s,this.remainingDeepIterations=0,this.signal=o,this.quads=null}async main(t){this.quads=t;for(let l of t)this._addBlankNodeQuadInfo({quad:l,component:l.subject}),this._addBlankNodeQuadInfo({quad:l,component:l.object}),this._addBlankNodeQuadInfo({quad:l,component:l.graph});let n=new Map,r=[...this.blankNodeInfo.keys()],i=0;for(let l of r){if(++i%100===0)await this._yield();await this._hashAndTrackBlankNode({id:l,hashToBlankNodes:n})}let s=[...n.keys()].sort(),o=[];for(let l of s){let c=n.get(l);if(c.length>1){o.push(c);continue}let u=c[0];this.canonicalIssuer.getId(u)}if(this.maxDeepIterations<0)if(this.maxWorkFactor===0)this.maxDeepIterations=0;else if(this.maxWorkFactor===1/0)this.maxDeepIterations=1/0;else{let l=o.reduce((c,u)=>c+u.length,0);this.maxDeepIterations=l**this.maxWorkFactor}if(this.maxDeepIterations>Number.MAX_SAFE_INTEGER)this.maxDeepIterations=1/0;this.remainingDeepIterations=this.maxDeepIterations;for(let l of o){let c=[];for(let u of l){if(this.canonicalIssuer.hasId(u))continue;let p=new Dse("b");p.getId(u);let d=await this.hashNDegreeQuads(u,p);c.push(d)}c.sort(lBe);for(let u of c){let p=u.issuer.getOldIds();for(let d of p)this.canonicalIssuer.getId(d)}}let a=[];for(let l of this.quads){let c=Tse.serializeQuadComponents(this._componentWithCanonicalId(l.subject),l.predicate,this._componentWithCanonicalId(l.object),this._componentWithCanonicalId(l.graph));a.push(c)}return a.sort(),a.join("")}async hashFirstDegreeQuads(t){let n=[],r=this.blankNodeInfo.get(t),i=r.quads;for(let o of i)n.push(Tse.serializeQuadComponents(this.modifyFirstDegreeComponent(t,o.subject,"subject"),o.predicate,this.modifyFirstDegreeComponent(t,o.object,"object"),this.modifyFirstDegreeComponent(t,o.graph,"graph")));n.sort();let s=this.createMessageDigest();for(let o of n)s.update(o);return r.hash=await s.digest(),r.hash}async hashRelatedBlankNode(t,n,r,i){let s=this.createMessageDigest();if(s.update(i),i!=="g")s.update(this.getRelatedPredicate(n));let o;if(this.canonicalIssuer.hasId(t))o="_:"+this.canonicalIssuer.getId(t);else if(r.hasId(t))o="_:"+r.getId(t);else o=this.blankNodeInfo.get(t).hash;return s.update(o),s.digest()}async hashNDegreeQuads(t,n){if(this.remainingDeepIterations===0)throw Error(`Maximum deep iterations exceeded (${this.maxDeepIterations}).`);this.remainingDeepIterations--;let r=this.createMessageDigest(),i=await this.createHashToRelated(t,n),s=[...i.keys()].sort();for(let o of s){r.update(o);let a="",l,c=new oBe(i.get(o)),u=0;while(c.hasNext()){let p=c.next();if(++u%3===0){if(this.signal&&this.signal.aborted)throw Error(`Abort signal received: "${this.signal.reason}".`);await this._yield()}let d=n.clone(),f="",m=[],y=!1;for(let h of p){if(this.canonicalIssuer.hasId(h))f+="_:"+this.canonicalIssuer.getId(h);else{if(!d.hasId(h))m.push(h);f+="_:"+d.getId(h)}if(a.length!==0&&f>a){y=!0;break}}if(y)continue;for(let h of m){let b=await this.hashNDegreeQuads(h,d);if(f+="_:"+d.getId(h),f+=`<${b.hash}>`,d=b.issuer,a.length!==0&&f>a){y=!0;break}}if(y)continue;if(a.length===0||f`}async createHashToRelated(t,n){let r=new Map,i=this.blankNodeInfo.get(t).quads,s=0;for(let o of i){if(++s%100===0)await this._yield();await Promise.all([this._addRelatedBlankNodeHash({quad:o,component:o.subject,position:"s",id:t,issuer:n,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:o,component:o.object,position:"o",id:t,issuer:n,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:o,component:o.graph,position:"g",id:t,issuer:n,hashToRelated:r})])}return r}async _hashAndTrackBlankNode({id:t,hashToBlankNodes:n}){let r=await this.hashFirstDegreeQuads(t),i=n.get(r);if(!i)n.set(r,[t]);else i.push(t)}_addBlankNodeQuadInfo({quad:t,component:n}){if(n.termType!=="BlankNode")return;let r=n.value,i=this.blankNodeInfo.get(r);if(i)i.quads.add(t);else this.blankNodeInfo.set(r,{quads:new Set([t]),hash:null})}async _addRelatedBlankNodeHash({quad:t,component:n,position:r,id:i,issuer:s,hashToRelated:o}){if(!(n.termType==="BlankNode"&&n.value!==i))return;let a=n.value,l=await this.hashRelatedBlankNode(a,t,s,r),c=o.get(l);if(c)c.push(a);else o.set(l,[a])}_componentWithCanonicalId(t){if(t.termType==="BlankNode"&&!t.value.startsWith(this.canonicalIssuer.prefix))return{termType:"BlankNode",value:this.canonicalIssuer.getId(t.value)};return t}async _yield(){return new Promise((t)=>aBe(t))}};function lBe(e,t){return e.hasht.hash?1:0}});var Pse=z(function(oBt,Ose){/*! * Copyright (c) 2016-2023 Digital Bazaar, Inc. All rights reserved. - */var kse=TS(),lBe=xF(),cBe=wF(),Nse=kS();Ose.exports=class{constructor({createMessageDigest:t=null,messageDigestAlgorithm:n="sha256",canonicalIdMap:r=new Map,maxWorkFactor:i=1,maxDeepIterations:s=-1,timeout:o=0}={}){if(this.name="RDFC-1.0",this.blankNodeInfo=new Map,this.canonicalIssuer=new kse("c14n",r),this.createMessageDigest=t||(()=>new lBe(n)),this.maxWorkFactor=i,this.maxDeepIterations=s,this.remainingDeepIterations=0,this.timeout=o,o>0)this.startTime=Date.now();this.quads=null}main(t){this.quads=t;for(let a of t)this._addBlankNodeQuadInfo({quad:a,component:a.subject}),this._addBlankNodeQuadInfo({quad:a,component:a.object}),this._addBlankNodeQuadInfo({quad:a,component:a.graph});let n=new Map,r=[...this.blankNodeInfo.keys()];for(let a of r)this._hashAndTrackBlankNode({id:a,hashToBlankNodes:n});let i=[...n.keys()].sort(),s=[];for(let a of i){let l=n.get(a);if(l.length>1){s.push(l);continue}let c=l[0];this.canonicalIssuer.getId(c)}if(this.maxDeepIterations<0)if(this.maxWorkFactor===0)this.maxDeepIterations=0;else if(this.maxWorkFactor===1/0)this.maxDeepIterations=1/0;else{let a=s.reduce((l,c)=>l+c.length,0);this.maxDeepIterations=a**this.maxWorkFactor}if(this.maxDeepIterations>Number.MAX_SAFE_INTEGER)this.maxDeepIterations=1/0;this.remainingDeepIterations=this.maxDeepIterations;for(let a of s){let l=[];for(let c of a){if(this.canonicalIssuer.hasId(c))continue;let u=new kse("b");u.getId(c);let p=this.hashNDegreeQuads(c,u);l.push(p)}l.sort(uBe);for(let c of l){let u=c.issuer.getOldIds();for(let p of u)this.canonicalIssuer.getId(p)}}let o=[];for(let a of this.quads){let l=Nse.serializeQuadComponents(this._componentWithCanonicalId(a.subject),a.predicate,this._componentWithCanonicalId(a.object),this._componentWithCanonicalId(a.graph));o.push(l)}return o.sort(),o.join("")}hashFirstDegreeQuads(t){let n=[],r=this.blankNodeInfo.get(t),i=r.quads;for(let o of i)n.push(Nse.serializeQuadComponents(this.modifyFirstDegreeComponent(t,o.subject,"subject"),o.predicate,this.modifyFirstDegreeComponent(t,o.object,"object"),this.modifyFirstDegreeComponent(t,o.graph,"graph")));n.sort();let s=this.createMessageDigest();for(let o of n)s.update(o);return r.hash=s.digest(),r.hash}hashRelatedBlankNode(t,n,r,i){let s=this.createMessageDigest();if(s.update(i),i!=="g")s.update(this.getRelatedPredicate(n));let o;if(this.canonicalIssuer.hasId(t))o="_:"+this.canonicalIssuer.getId(t);else if(r.hasId(t))o="_:"+r.getId(t);else o=this.blankNodeInfo.get(t).hash;return s.update(o),s.digest()}hashNDegreeQuads(t,n){if(this.remainingDeepIterations===0)throw Error(`Maximum deep iterations exceeded (${this.maxDeepIterations}).`);this.remainingDeepIterations--;let r=this.createMessageDigest(),i=this.createHashToRelated(t,n),s=[...i.keys()].sort();for(let o of s){r.update(o);let a="",l,c=new cBe(i.get(o)),u=0;while(c.hasNext()){let p=c.next();if(++u%3===0){if(this.timeout>0&&Date.now()-this.startTime>this.timeout)throw Error("Canonize timeout.")}let d=n.clone(),f="",m=[],y=!1;for(let h of p){if(this.canonicalIssuer.hasId(h))f+="_:"+this.canonicalIssuer.getId(h);else{if(!d.hasId(h))m.push(h);f+="_:"+d.getId(h)}if(a.length!==0&&f>a){y=!0;break}}if(y)continue;for(let h of m){let b=this.hashNDegreeQuads(h,d);if(f+="_:"+d.getId(h),f+=`<${b.hash}>`,d=b.issuer,a.length!==0&&f>a){y=!0;break}}if(y)continue;if(a.length===0||f`}createHashToRelated(t,n){let r=new Map,i=this.blankNodeInfo.get(t).quads;for(let s of i)this._addRelatedBlankNodeHash({quad:s,component:s.subject,position:"s",id:t,issuer:n,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:s,component:s.object,position:"o",id:t,issuer:n,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:s,component:s.graph,position:"g",id:t,issuer:n,hashToRelated:r});return r}_hashAndTrackBlankNode({id:t,hashToBlankNodes:n}){let r=this.hashFirstDegreeQuads(t),i=n.get(r);if(!i)n.set(r,[t]);else i.push(t)}_addBlankNodeQuadInfo({quad:t,component:n}){if(n.termType!=="BlankNode")return;let r=n.value,i=this.blankNodeInfo.get(r);if(i)i.quads.add(t);else this.blankNodeInfo.set(r,{quads:new Set([t]),hash:null})}_addRelatedBlankNodeHash({quad:t,component:n,position:r,id:i,issuer:s,hashToRelated:o}){if(!(n.termType==="BlankNode"&&n.value!==i))return;let a=n.value,l=this.hashRelatedBlankNode(a,t,s,r),c=o.get(l);if(c)c.push(a);else o.set(l,[a])}_componentWithCanonicalId(t){if(t.termType==="BlankNode"&&!t.value.startsWith(this.canonicalIssuer.prefix))return{termType:"BlankNode",value:this.canonicalIssuer.getId(t.value)};return t}};function uBe(e,t){return e.hasht.hash?1:0}});var NS=z(function(pBe){var $se=Ese(),Ise=Pse();function Ase(e,t){if(t.inputFormat){if(t.inputFormat==="application/n-quads"){if(typeof e!=="string")throw Error("N-Quads input must be a string.");return pBe.NQuads.parse(e)}throw Error(`Unknown canonicalization input format: "${t.inputFormat}".`)}return e}function Rse(e){if(e.format){if(e.format!=="application/n-quads")throw Error(`Unknown canonicalization output format: "${e.format}".`)}}function jse(){if(globalThis.RDF_CANONIZE_TRACE_URDNA2015)console.trace("[rdf-canonize] URDNA2015 is deprecated, use RDFC-1.0")}pBe.NQuads=kS();pBe.IdentifierIssuer=TS();pBe.canonize=async function(e,t={}){let n=Ase(e,t);if(Rse(t),!("algorithm"in t))throw Error("No RDF Dataset Canonicalization algorithm specified.");if(t.algorithm==="RDFC-1.0")return new $se(t).main(n);if(t.algorithm==="URDNA2015"&&!t.rejectURDNA2015)return jse(),new $se(t).main(n);throw Error("Invalid RDF Dataset Canonicalization algorithm: "+t.algorithm)};pBe._canonizeSync=function(e,t={}){let n=Ase(e,t);if(Rse(t),!("algorithm"in t))throw Error("No RDF Dataset Canonicalization algorithm specified.");if(t.algorithm==="RDFC-1.0")return new Ise(t).main(n);if(t.algorithm==="URDNA2015"&&!t.rejectURDNA2015)return jse(),new Ise(t).main(n);throw Error("Invalid RDF Dataset Canonicalization algorithm: "+t.algorithm)}});var Rs=z(function(oBt,Fse){var ea={};Fse.exports=ea;ea.isArray=Array.isArray;ea.isBoolean=(e)=>typeof e==="boolean"||Object.prototype.toString.call(e)==="[object Boolean]";ea.isDouble=(e)=>ea.isNumber(e)&&(String(e).indexOf(".")!==-1||Math.abs(e)>=1000000000000000000000);ea.isEmptyObject=(e)=>ea.isObject(e)&&Object.keys(e).length===0;ea.isNumber=(e)=>typeof e==="number"||Object.prototype.toString.call(e)==="[object Number]";ea.isNumeric=(e)=>!isNaN(parseFloat(e))&&isFinite(e);ea.isObject=(e)=>Object.prototype.toString.call(e)==="[object Object]";ea.isString=(e)=>typeof e==="string"||Object.prototype.toString.call(e)==="[object String]";ea.isUndefined=(e)=>typeof e>"u"});var El=z(function(aBt,Cse){var cf=Rs(),Rc={};Cse.exports=Rc;Rc.isSubject=(e)=>{if(cf.isObject(e)&&!(("@value"in e)||("@set"in e)||("@list"in e)))return Object.keys(e).length>1||!("@id"in e);return!1};Rc.isSubjectReference=(e)=>cf.isObject(e)&&Object.keys(e).length===1&&("@id"in e);Rc.isValue=(e)=>cf.isObject(e)&&("@value"in e);Rc.isList=(e)=>cf.isObject(e)&&("@list"in e);Rc.isGraph=(e)=>cf.isObject(e)&&("@graph"in e)&&Object.keys(e).filter((t)=>t!=="@id"&&t!=="@index").length===1;Rc.isSimpleGraph=(e)=>Rc.isGraph(e)&&!("@id"in e);Rc.isBlankNode=(e)=>{if(cf.isObject(e)){if("@id"in e){let t=e["@id"];return!cf.isString(t)||t.indexOf("_:")===0}return Object.keys(e).length===0||!(("@value"in e)||("@set"in e)||("@list"in e))}return!1}});var io=z(function(lBt,Mse){Mse.exports=class extends Error{constructor(t="An unspecified JSON-LD error occurred.",n="jsonld.Error",r={}){super(t);this.name=n,this.message=t,this.details=r}}});var so=z(function(cBt,Vse){var Gv=El(),bi=Rs(),qse=NS().IdentifierIssuer,hBe=io(),gBe=/^[a-zA-Z]{1,8}(-[a-zA-Z0-9]{1,8})*$/,bBe=/(?:<[^>]*?>|"[^"]*?"|[^,])+/g,vBe=/\s*<([^>]*?)>\s*(?:;\s*(.*))?/,_Be=/(.*?)=(?:(?:"([^"]*?)")|([^"]*?))\s*(?:(?:;\s*)|$)/g,xBe=/^@[a-zA-Z]+$/,Lse={headers:{accept:"application/ld+json, application/json"}},_n={};Vse.exports=_n;_n.IdentifierIssuer=qse;_n.REGEX_BCP47=gBe;_n.REGEX_KEYWORD=xBe;_n.clone=function(e){if(e&&typeof e==="object"){if(bi.isNumber(e)&&Object.isFrozen(e)&&e[Symbol.for("umf.jsonld.exact-number")]===!0)return e;let t;if(bi.isArray(e)){t=[];for(let n=0;n{if(Object.keys(e).some((n)=>n.toLowerCase()==="accept"))throw RangeError('Accept header may not be specified; only "'+Lse.headers.accept+'" is supported.');return Object.assign({Accept:Lse.headers.accept},e)};_n.parseLinkHeader=(e)=>{let t={},n=e.match(bBe);for(let r=0;r{if(bi.isString(e))return;if(bi.isArray(e)&&e.every((n)=>bi.isString(n)))return;if(t&&bi.isObject(e))switch(Object.keys(e).length){case 0:return;case 1:if("@default"in e&&_n.asArray(e["@default"]).every((n)=>bi.isString(n)))return}throw new hBe('Invalid JSON-LD syntax; "@type" value must a string, an array of strings, an empty object, or a default object.',"jsonld.SyntaxError",{code:"invalid type value",value:e})};_n.hasProperty=(e,t)=>{if(e.hasOwnProperty(t)){let n=e[t];return!bi.isArray(n)||n.length>0}return!1};_n.hasValue=(e,t,n)=>{if(_n.hasProperty(e,t)){let r=e[t],i=Gv.isList(r);if(bi.isArray(r)||i){if(i)r=r["@list"];for(let s=0;s{if(r=r||{},!("propertyIsArray"in r))r.propertyIsArray=!1;if(!("valueIsArray"in r))r.valueIsArray=!1;if(!("allowDuplicate"in r))r.allowDuplicate=!0;if(!("prependValue"in r))r.prependValue=!1;if(r.valueIsArray)e[t]=n;else if(bi.isArray(n)){if(n.length===0&&r.propertyIsArray&&!e.hasOwnProperty(t))e[t]=[];if(r.prependValue)n=n.concat(e[t]),e[t]=[];for(let i=0;i[].concat(e[t]||[]);_n.removeProperty=(e,t)=>{delete e[t]};_n.removeValue=(e,t,n,r)=>{if(r=r||{},!("propertyIsArray"in r))r.propertyIsArray=!1;let i=_n.getValues(e,t).filter((s)=>!_n.compareValues(s,n));if(i.length===0)_n.removeProperty(e,t);else if(i.length===1&&!r.propertyIsArray)e[t]=i[0];else e[t]=i};_n.relabelBlankNodes=(e,t)=>{t=t||{};let n=t.issuer||new qse("_:b");return OS(n,e)};function Use(e,t){if(Bse(e,t))return!0;if(!e||!t||typeof e!=="object"||typeof t!=="object"||e instanceof Number||t instanceof Number)return!1;if(Array.isArray(e)!==Array.isArray(t))return!1;let n=Object.keys(e);return n.length===Object.keys(t).length&&n.every((r)=>Object.prototype.hasOwnProperty.call(t,r)&&Use(e[r],t[r]))}function Bse(e,t){let n=Symbol.for("umf.jsonld.number-equals");if(e instanceof Number&&Object.isFrozen(e)&&typeof e[n]==="function")return e[n](t);if(t instanceof Number&&Object.isFrozen(t)&&typeof t[n]==="function")return t[n](e);return e===t}_n.compareValues=(e,t)=>{if(e===t)return!0;if(Gv.isValue(e)&&Gv.isValue(t)&&(e["@type"]==="@json"?Use(e["@value"],t["@value"]):Bse(e["@value"],t["@value"]))&&e["@type"]===t["@type"]&&e["@language"]===t["@language"]&&e["@direction"]===t["@direction"]&&e["@index"]===t["@index"])return!0;if(bi.isObject(e)&&"@id"in e&&bi.isObject(t)&&"@id"in t)return e["@id"]===t["@id"];return!1};_n.compareShortestLeast=(e,t)=>{if(e.length{let n={},r=Li.parsers[t||"full"],i=r.regex.exec(e),s=r.keys.length;while(s--)n[r.keys[s]]=i[s]===void 0?null:i[s];if(n.scheme==="https"&&n.port==="443"||n.scheme==="http"&&n.port==="80")n.href=n.href.replace(":"+n.port,""),n.authority=n.authority.replace(":"+n.port,""),n.port=null;return n.normalizedPath=Li.removeDotSegments(n.path),n};Li.prependBase=(e,t)=>{if(e===null)return t;if(Li.isAbsolute(t))return t;if(!e||$S.isString(e))e=Li.parse(e||"");let n=Li.parse(t),r={protocol:e.protocol||""};if(n.authority!==null)r.authority=n.authority,r.path=n.path,r.query=n.query;else if(r.authority=e.authority,n.path==="")if(r.path=e.path,n.query!==null)r.query=n.query;else r.query=e.query;else{if(n.path.indexOf("/")===0)r.path=n.path;else{let s=e.path;if(s=s.substr(0,s.lastIndexOf("/")+1),(s.length>0||e.authority)&&s.substr(-1)!=="/")s+="/";s+=n.path,r.path=s}r.query=n.query}if(n.path!=="")r.path=Li.removeDotSegments(r.path);let i=r.protocol;if(r.authority!==null)i+="//"+r.authority;if(i+=r.path,r.query!==null)i+="?"+r.query;if(n.fragment!==null)i+="#"+n.fragment;if(i==="")i="./";return i};Li.removeBase=(e,t)=>{if(e===null)return t;if(!e||$S.isString(e))e=Li.parse(e||"");let n="";if(e.href!=="")n+=(e.protocol||"")+"//"+(e.authority||"");else if(t.indexOf("//"))n+="//";if(t.indexOf(n)!==0)return t;let r=Li.parse(t.substr(n.length)),i=e.normalizedPath.split("/"),s=r.normalizedPath.split("/"),o=r.fragment||r.query?0:1;while(i.length>0&&s.length>o){if(i[0]!==s[0])break;i.shift(),s.shift()}let a="";if(i.length>0){i.pop();for(let l=0;l{if(e.length===0)return"";let t=e.split("/"),n=[];while(t.length>0){let r=t.shift(),i=t.length===0;if(r==="."){if(i)n.push("");continue}if(r===".."){if(n.pop(),i)n.push("");continue}n.push(r)}if(e[0]==="/"&&n.length>0&&n[0]!=="")n.unshift("");if(n.length===1&&n[0]==="")return"/";return n.join("/")};var wBe=/^([A-Za-z][A-Za-z0-9+-.]*|_):[^\u0009-\u000d\u0020]*(?![\s\S])/;Li.isAbsolute=(e)=>$S.isString(e)&&wBe.test(e);Li.isRelative=(e)=>$S.isString(e)});var zse=z(function(fBt,Hse){var{parseLinkHeader:DBe,buildHeaders:TBe}=so(),{LINK_HEADER_CONTEXT:SBe}=PS(),Hv=io(),EBe=DF(),{prependBase:kBe}=jc(),NBe=/(^|(\r\n))link:/i;Hse.exports=({secure:e,headers:t={},xhr:n}={headers:{}})=>{return t=TBe(t),new EBe().wrapLoader(i);async function i(s){if(s.indexOf("http:")!==0&&s.indexOf("https:")!==0)throw new Hv('URL could not be dereferenced; only "http" and "https" URLs are supported.',"jsonld.InvalidUrl",{code:"loading document failed",url:s});if(e&&s.indexOf("https")!==0)throw new Hv(`URL could not be dereferenced; secure mode is enabled and the URL's scheme is not "https".`,"jsonld.InvalidUrl",{code:"loading document failed",url:s});let o;try{o=await OBe(n,s,t)}catch(p){throw new Hv("URL could not be dereferenced, an error occurred.","jsonld.LoadDocumentError",{code:"loading document failed",url:s,cause:p})}if(o.status>=400)throw new Hv("URL could not be dereferenced: "+o.statusText,"jsonld.LoadDocumentError",{code:"loading document failed",url:s,httpStatusCode:o.status});let a={contextUrl:null,documentUrl:s,document:o.response},l=null,c=o.getResponseHeader("Content-Type"),u;if(NBe.test(o.getAllResponseHeaders()))u=o.getResponseHeader("Link");if(u&&c!=="application/ld+json"){let p=DBe(u),d=p[SBe];if(Array.isArray(d))throw new Hv("URL could not be dereferenced, it has more than one associated HTTP Link Header.","jsonld.InvalidUrl",{code:"multiple context link headers",url:s});if(d)a.contextUrl=d.target;if(l=p.alternate,l&&l.type=="application/ld+json"&&!(c||"").match(/^application\/(\w*\+)?json$/))a=await i(kBe(s,l.target))}return a}};function OBe(e,t,n){e=e||XMLHttpRequest;let r=new e;return new Promise((i,s)=>{r.onload=()=>i(r),r.onerror=(o)=>s(o),r.open("GET",t,!0);for(let o in n)r.setRequestHeader(o,n[o]);r.send()})}});var Qse=z(function(mBt,Wse){var PBe=zse(),TF={};Wse.exports=TF;TF.setupDocumentLoaders=function(e){if(typeof XMLHttpRequest<"u")e.documentLoaders.xhr=PBe,e.useDocumentLoader("xhr")};TF.setupGlobals=function(e){if(typeof globalThis.JsonLdProcessor>"u")Object.defineProperty(globalThis,"JsonLdProcessor",{writable:!0,enumerable:!1,configurable:!0,value:e.JsonLdProcessor})}});var Xse=z(function(yBt,Yse){Yse.exports=function(e){e.prototype[Symbol.iterator]=function*(){for(let t=this.head;t;t=t.next)yield t.value}}});var eoe=z(function(hBt,Zse){Zse.exports=yn;yn.Node=uf;yn.create=yn;function yn(e){var t=this;if(!(t instanceof yn))t=new yn;if(t.tail=null,t.head=null,t.length=0,e&&typeof e.forEach==="function")e.forEach(function(i){t.push(i)});else if(arguments.length>0)for(var n=0,r=arguments.length;n1)n=t;else if(this.head)r=this.head.next,n=this.head.value;else throw TypeError("Reduce of empty list with no initial value");for(var i=0;r!==null;i++)n=e(n,r.value,i),r=r.next;return n};yn.prototype.reduceReverse=function(e,t){var n,r=this.tail;if(arguments.length>1)n=t;else if(this.tail)r=this.tail.prev,n=this.tail.value;else throw TypeError("Reduce of empty list with no initial value");for(var i=this.length-1;r!==null;i--)n=e(n,r.value,i),r=r.prev;return n};yn.prototype.toArray=function(){var e=Array(this.length);for(var t=0,n=this.head;n!==null;t++)e[t]=n.value,n=n.next;return e};yn.prototype.toArrayReverse=function(){var e=Array(this.length);for(var t=0,n=this.tail;n!==null;t++)e[t]=n.value,n=n.prev;return e};yn.prototype.slice=function(e,t){if(t=t||this.length,t<0)t+=this.length;if(e=e||0,e<0)e+=this.length;var n=new yn;if(tthis.length)t=this.length;for(var r=0,i=this.head;i!==null&&rthis.length)t=this.length;for(var r=this.length,i=this.tail;i!==null&&r>t;r--)i=i.prev;for(;i!==null&&r>e;r--,i=i.prev)n.push(i.value);return n};yn.prototype.splice=function(e,t,...n){if(e>this.length)e=this.length-1;if(e<0)e=this.length+e;for(var r=0,i=this.head;i!==null&&r1;class ioe{constructor(e){if(typeof e==="number")e={max:e};if(!e)e={};if(e.max&&(typeof e.max!=="number"||e.max<0))throw TypeError("max must be a non-negative number");let t=this[pf]=e.max||1/0,n=e.length||SF;if(this[qy]=typeof n!=="function"?SF:n,this[Wv]=e.stale||!1,e.maxAge&&typeof e.maxAge!=="number")throw TypeError("maxAge must be a number");this[df]=e.maxAge||0,this[Fc]=e.dispose,this[toe]=e.noDisposeOnSet||!1,this[roe]=e.updateAgeOnGet||!1,this.reset()}set max(e){if(typeof e!=="number"||e<0)throw TypeError("max must be a non-negative number");this[pf]=e||1/0,zv(this)}get max(){return this[pf]}set allowStale(e){this[Wv]=!!e}get allowStale(){return this[Wv]}set maxAge(e){if(typeof e!=="number")throw TypeError("maxAge must be a non-negative number");this[df]=e,zv(this)}get maxAge(){return this[df]}set lengthCalculator(e){if(typeof e!=="function")e=SF;if(e!==this[qy])this[qy]=e,this[Cc]=0,this[ii].forEach((t)=>{t.length=this[qy](t.value,t.key),this[Cc]+=t.length});zv(this)}get lengthCalculator(){return this[qy]}get length(){return this[Cc]}get itemCount(){return this[ii].length}rforEach(e,t){t=t||this;for(let n=this[ii].tail;n!==null;){let r=n.prev;noe(this,e,n,t),n=r}}forEach(e,t){t=t||this;for(let n=this[ii].head;n!==null;){let r=n.next;noe(this,e,n,t),n=r}}keys(){return this[ii].toArray().map((e)=>e.key)}values(){return this[ii].toArray().map((e)=>e.value)}reset(){if(this[Fc]&&this[ii]&&this[ii].length)this[ii].forEach((e)=>this[Fc](e.key,e.value));this[Ma]=new Map,this[ii]=new RBe,this[Cc]=0}dump(){return this[ii].map((e)=>IS(this,e)?!1:{k:e.key,v:e.value,e:e.now+(e.maxAge||0)}).toArray().filter((e)=>e)}dumpLru(){return this[ii]}set(e,t,n){if(n=n||this[df],n&&typeof n!=="number")throw TypeError("maxAge must be a number");let r=n?Date.now():0,i=this[qy](t,e);if(this[Ma].has(e)){if(i>this[pf])return Uy(this,this[Ma].get(e)),!1;let a=this[Ma].get(e).value;if(this[Fc]){if(!this[toe])this[Fc](e,a.value)}return a.now=r,a.maxAge=n,a.value=t,this[Cc]+=i-a.length,a.length=i,this.get(e),zv(this),!0}let s=new soe(e,t,i,r,n);if(s.length>this[pf]){if(this[Fc])this[Fc](e,t);return!1}return this[Cc]+=s.length,this[ii].unshift(s),this[Ma].set(e,this[ii].head),zv(this),!0}has(e){if(!this[Ma].has(e))return!1;let t=this[Ma].get(e).value;return!IS(this,t)}get(e){return EF(this,e,!0)}peek(e){return EF(this,e,!1)}pop(){let e=this[ii].tail;if(!e)return null;return Uy(this,e),e.value}del(e){Uy(this,this[Ma].get(e))}load(e){this.reset();let t=Date.now();for(let n=e.length-1;n>=0;n--){let r=e[n],i=r.e||0;if(i===0)this.set(r.k,r.v);else{let s=i-t;if(s>0)this.set(r.k,r.v,s)}}}prune(){this[Ma].forEach((e,t)=>EF(this,t,!1))}}var EF=(e,t,n)=>{let r=e[Ma].get(t);if(r){let i=r.value;if(IS(e,i)){if(Uy(e,r),!e[Wv])return}else if(n){if(e[roe])r.value.now=Date.now();e[ii].unshiftNode(r)}return i.value}},IS=(e,t)=>{if(!t||!t.maxAge&&!e[df])return!1;let n=Date.now()-t.now;return t.maxAge?n>t.maxAge:e[df]&&n>e[df]},zv=(e)=>{if(e[Cc]>e[pf])for(let t=e[ii].tail;e[Cc]>e[pf]&&t!==null;){let n=t.prev;Uy(e,t),t=n}},Uy=(e,t)=>{if(t){let n=t.value;if(e[Fc])e[Fc](n.key,n.value);e[Cc]-=n.length,e[Ma].delete(n.key),e[ii].removeNode(t)}};class soe{constructor(e,t,n,r,i){this.key=e,this.value=t,this.length=n,this.now=r,this.maxAge=i||0}}var noe=(e,t,n,r)=>{let i=n.value;if(IS(e,i)){if(Uy(e,n),!e[Wv])i=void 0}if(i)t.call(r,i.value,i.key,e)};ooe.exports=ioe});var loe=z(function(bBt,aoe){var jBe=kF();aoe.exports=class{constructor({document:t}){this.document=t,this.cache=new jBe({max:10})}getProcessed(t){return this.cache.get(t)}setProcessed(t,n){this.cache.set(t,n)}}});var poe=z(function(vBt,uoe){var{isArray:NF,isObject:Yv,isString:AS}=Rs(),{asArray:FBe}=so(),{prependBase:OF}=jc(),Qv=io(),coe=loe();uoe.exports=class{constructor({sharedCache:t}){this.perOpCache=new Map,this.sharedCache=t}async resolve({activeCtx:t,context:n,documentLoader:r,base:i,cycles:s=new Set}){if(n&&Yv(n)&&n["@context"])n=n["@context"];n=FBe(n);let o=[];for(let a of n){if(AS(a)){let u=this._get(a);if(!u)u=await this._resolveRemoteContext({activeCtx:t,url:a,documentLoader:r,base:i,cycles:s});if(NF(u))o.push(...u);else o.push(u);continue}if(a===null){o.push(new coe({document:null}));continue}if(!Yv(a))CBe(n);let l=JSON.stringify(a),c=this._get(l);if(!c)c=new coe({document:a}),this._cacheResolvedContext({key:l,resolved:c,tag:"static"});o.push(c)}return o}_get(t){let n=this.perOpCache.get(t);if(!n){let r=this.sharedCache.get(t);if(r){if(n=r.get("static"),n)this.perOpCache.set(t,n)}}return n}_cacheResolvedContext({key:t,resolved:n,tag:r}){if(this.perOpCache.set(t,n),r!==void 0){let i=this.sharedCache.get(t);if(!i)i=new Map,this.sharedCache.set(t,i);i.set(r,n)}return n}async _resolveRemoteContext({activeCtx:t,url:n,documentLoader:r,base:i,cycles:s}){n=OF(i,n);let{context:o,remoteDoc:a}=await this._fetchContext({activeCtx:t,url:n,documentLoader:r,cycles:s});i=a.documentUrl||n,PF({context:o,base:i});let l=await this.resolve({activeCtx:t,context:o,documentLoader:r,base:i,cycles:s});return this._cacheResolvedContext({key:n,resolved:l,tag:a.tag}),l}async _fetchContext({activeCtx:t,url:n,documentLoader:r,cycles:i}){if(i.size>10)throw new Qv("Maximum number of @context URLs exceeded.","jsonld.ContextUrlError",{code:t.processingMode==="json-ld-1.0"?"loading remote context failed":"context overflow",max:10});if(i.has(n))throw new Qv("Cyclical @context URLs detected.","jsonld.ContextUrlError",{code:t.processingMode==="json-ld-1.0"?"recursive context inclusion":"context overflow",url:n});i.add(n);let s,o;try{if(o=await r(n),s=o.document||null,AS(s))s=JSON.parse(s)}catch(a){throw new Qv(`Dereferencing a URL did not result in a valid JSON-LD object. Possible causes are an inaccessible URL perhaps due to a same-origin policy (ensure the server uses CORS if you are using client-side JavaScript), too many redirects, a non-JSON response, or more than one HTTP Link Header was provided for a remote context. URL: "${n}".`,"jsonld.InvalidUrl",{code:"loading remote context failed",url:n,cause:a})}if(!Yv(s))throw new Qv(`Dereferencing a URL did not result in a JSON object. The response was valid JSON, but it was not a JSON object. URL: "${n}".`,"jsonld.InvalidUrl",{code:"invalid remote context",url:n});if(!("@context"in s))s={"@context":{}};else s={"@context":s["@context"]};if(o.contextUrl){if(!NF(s["@context"]))s["@context"]=[s["@context"]];s["@context"].push(o.contextUrl)}return{context:s,remoteDoc:o}}};function CBe(e){throw new Qv("Invalid JSON-LD syntax; @context must be an object.","jsonld.SyntaxError",{code:"invalid local context",context:e})}function PF({context:e,base:t}){if(!e)return;let n=e["@context"];if(AS(n)){e["@context"]=OF(t,n);return}if(NF(n)){for(let r=0;r{let t=[].concat(e.safe?oo.safeEventHandler:[],e.eventHandler?moe(e.eventHandler):[],oo.defaultEventHandler?oo.defaultEventHandler:[]);return t.length===0?null:t};oo.handleEvent=({event:e,options:t})=>{yoe({event:e,handlers:t.eventHandler})};function yoe({event:e,handlers:t}){let n=!0;for(let r=0;n&&r{n=!0}});else if(typeof i==="object")if(e.code in i)i[e.code]({event:e,next:()=>{n=!0}});else n=!0;else throw new $F("Invalid event handler.","jsonld.InvalidEventHandler",{event:e})}return n}var LBe=new Set(["empty object","free-floating scalar","invalid @language value","invalid property","null @id value","null @value value","object with only @id","object with only @language","object with only @list","object with only @value","relative @id reference","relative @type reference","relative @vocab reference","reserved @id value","reserved @reverse value","reserved term","blank node predicate","relative graph reference","relative object reference","relative predicate reference","relative subject reference","rdfDirection not set"]);oo.safeEventHandler=function({event:t,next:n}){if(t.level==="warning"&&LBe.has(t.code))throw new $F("Safe mode validation error.","jsonld.ValidationError",{event:t});n()};oo.logEventHandler=function({event:t,next:n}){console.log(`EVENT: ${t.message}`,{event:t}),n()};oo.logWarningEventHandler=function({event:t,next:n}){if(t.level==="warning")console.warn(`WARNING: ${t.message}`,{event:t});n()};oo.unhandledEventHandler=function({event:t}){throw new $F("No handler for event.","jsonld.UnhandledEvent",{event:t})};oo.setDefaultEventHandler=function({eventHandler:e}={}){oo.defaultEventHandler=e?moe(e):null}});var mp=z(function(wBt,_oe){var goe=so(),_t=io(),{isArray:boe,isObject:fp,isString:js,isUndefined:qBe}=Rs(),{isAbsolute:ff,isRelative:UBe,prependBase:Xv}=jc(),{handleEvent:Ky}=By(),{REGEX_BCP47:BBe,REGEX_KEYWORD:jS,asArray:voe,compareShortestLeast:VBe}=so(),RS=new Map,Mn={};_oe.exports=Mn;Mn.process=async({activeCtx:e,localCtx:t,options:n,propagate:r=!0,overrideProtected:i=!1,cycles:s=new Set})=>{if(fp(t)&&"@context"in t&&boe(t["@context"]))t=t["@context"];if(voe(t).length===0)return e;let a=[],l=[({event:d,next:f})=>{a.push(d),f()}];if(n.eventHandler)l.push(n.eventHandler);let c=n;n={...n,eventHandler:l};let u=await n.contextResolver.resolve({activeCtx:e,context:t,documentLoader:n.documentLoader,base:n.base});if(fp(u[0].document)&&typeof u[0].document["@propagate"]==="boolean")r=u[0].document["@propagate"];let p=e;if(!r&&!p.previousContext)p=p.clone(),p.previousContext=e;for(let d of u){let{document:f}=d;if(e=p,f===null){if(!i&&Object.keys(e.protected).length!==0)throw new _t("Tried to nullify a context with protected terms outside of a term definition.","jsonld.SyntaxError",{code:"invalid context nullification"});p=e=Mn.getInitialContext(n).clone();continue}let m=d.getProcessed(e);if(m){if(c.eventHandler)for(let h of m.events)Ky({event:h,options:c});p=e=m.context;continue}if(fp(f)&&"@context"in f)f=f["@context"];if(!fp(f))throw new _t("Invalid JSON-LD syntax; @context must be an object.","jsonld.SyntaxError",{code:"invalid local context",context:f});p=p.clone();let y=new Map;if("@version"in f){if(f["@version"]!==1.1)throw new _t("Unsupported JSON-LD version: "+f["@version"],"jsonld.UnsupportedVersion",{code:"invalid @version value",context:f});if(e.processingMode&&e.processingMode==="json-ld-1.0")throw new _t("@version: "+f["@version"]+" not compatible with "+e.processingMode,"jsonld.ProcessingModeConflict",{code:"processing mode conflict",context:f});p.processingMode="json-ld-1.1",p["@version"]=f["@version"],y.set("@version",!0)}if(p.processingMode=p.processingMode||e.processingMode,"@base"in f){let h=f["@base"];if(h===null||ff(h));else if(UBe(h))h=Xv(p["@base"],h);else throw new _t('Invalid JSON-LD syntax; the value of "@base" in a @context must be an absolute IRI, a relative IRI, or null.',"jsonld.SyntaxError",{code:"invalid base IRI",context:f});p["@base"]=h,y.set("@base",!0)}if("@vocab"in f){let h=f["@vocab"];if(h===null)delete p["@vocab"];else if(!js(h))throw new _t('Invalid JSON-LD syntax; the value of "@vocab" in a @context must be a string or null.',"jsonld.SyntaxError",{code:"invalid vocab mapping",context:f});else if(!ff(h)&&Mn.processingMode(p,1))throw new _t('Invalid JSON-LD syntax; the value of "@vocab" in a @context must be an absolute IRI.',"jsonld.SyntaxError",{code:"invalid vocab mapping",context:f});else{let b=Vy(p,h,{vocab:!0,base:!0},void 0,void 0,n);if(!ff(b)){if(n.eventHandler)Ky({event:{type:["JsonLdEvent"],code:"relative @vocab reference",level:"warning",message:"Relative @vocab reference found.",details:{vocab:b}},options:n})}p["@vocab"]=b}y.set("@vocab",!0)}if("@language"in f){let h=f["@language"];if(h===null)delete p["@language"];else if(!js(h))throw new _t('Invalid JSON-LD syntax; the value of "@language" in a @context must be a string or null.',"jsonld.SyntaxError",{code:"invalid default language",context:f});else{if(!h.match(BBe)){if(n.eventHandler)Ky({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:h}},options:n})}p["@language"]=h.toLowerCase()}y.set("@language",!0)}if("@direction"in f){let h=f["@direction"];if(e.processingMode==="json-ld-1.0")throw new _t("Invalid JSON-LD syntax; @direction not compatible with "+e.processingMode,"jsonld.SyntaxError",{code:"invalid context member",context:f});if(h===null)delete p["@direction"];else if(h!=="ltr"&&h!=="rtl")throw new _t('Invalid JSON-LD syntax; the value of "@direction" in a @context must be null, "ltr", or "rtl".',"jsonld.SyntaxError",{code:"invalid base direction",context:f});else p["@direction"]=h;y.set("@direction",!0)}if("@propagate"in f){let h=f["@propagate"];if(e.processingMode==="json-ld-1.0")throw new _t("Invalid JSON-LD syntax; @propagate not compatible with "+e.processingMode,"jsonld.SyntaxError",{code:"invalid context entry",context:f});if(typeof h!=="boolean")throw new _t("Invalid JSON-LD syntax; @propagate value must be a boolean.","jsonld.SyntaxError",{code:"invalid @propagate value",context:t});y.set("@propagate",!0)}if("@import"in f){let h=f["@import"];if(e.processingMode==="json-ld-1.0")throw new _t("Invalid JSON-LD syntax; @import not compatible with "+e.processingMode,"jsonld.SyntaxError",{code:"invalid context entry",context:f});if(!js(h))throw new _t("Invalid JSON-LD syntax; @import must be a string.","jsonld.SyntaxError",{code:"invalid @import value",context:t});let b=await n.contextResolver.resolve({activeCtx:e,context:h,documentLoader:n.documentLoader,base:n.base});if(b.length!==1)throw new _t("Invalid JSON-LD syntax; @import must reference a single context.","jsonld.SyntaxError",{code:"invalid remote context",context:t});let g=b[0].getProcessed(e);if(g)f=g;else{let x=b[0].document;if("@import"in x)throw new _t("Invalid JSON-LD syntax: imported context must not include @import.","jsonld.SyntaxError",{code:"invalid context entry",context:t});for(let v in x)if(!f.hasOwnProperty(v))f[v]=x[v];b[0].setProcessed(e,f)}y.set("@import",!0)}y.set("@protected",f["@protected"]||!1);for(let h in f)if(Mn.createTermDefinition({activeCtx:p,localCtx:f,term:h,defined:y,options:n,overrideProtected:i}),fp(f[h])&&"@context"in f[h]){let b=f[h]["@context"],g=!0;if(js(b)){let x=Xv(n.base,b);if(s.has(x))g=!1;else s.add(x)}if(g)try{await Mn.process({activeCtx:p.clone(),localCtx:f[h]["@context"],overrideProtected:!0,options:n,cycles:s})}catch(x){throw new _t("Invalid JSON-LD syntax; invalid scoped context.","jsonld.SyntaxError",{code:"invalid scoped context",context:f[h]["@context"],term:h})}}d.setProcessed(e,{context:p,events:a})}return p};Mn.createTermDefinition=({activeCtx:e,localCtx:t,term:n,defined:r,options:i,overrideProtected:s=!1})=>{if(r.has(n)){if(r.get(n))return;throw new _t("Cyclical context definition detected.","jsonld.CyclicalContext",{code:"cyclic IRI mapping",context:t,term:n})}r.set(n,!1);let o;if(t.hasOwnProperty(n))o=t[n];if(n==="@type"&&fp(o)&&(o["@container"]||"@set")==="@set"&&Mn.processingMode(e,1.1)){let f=["@container","@id","@protected"],m=Object.keys(o);if(m.length===0||m.some((y)=>!f.includes(y)))throw new _t("Invalid JSON-LD syntax; keywords cannot be overridden.","jsonld.SyntaxError",{code:"keyword redefinition",context:t,term:n})}else if(Mn.isKeyword(n))throw new _t("Invalid JSON-LD syntax; keywords cannot be overridden.","jsonld.SyntaxError",{code:"keyword redefinition",context:t,term:n});else if(n.match(jS)){if(i.eventHandler)Ky({event:{type:["JsonLdEvent"],code:"reserved term",level:"warning",message:'Terms beginning with "@" are reserved for future use and dropped.',details:{term:n}},options:i});return}else if(n==="")throw new _t("Invalid JSON-LD syntax; a term cannot be an empty string.","jsonld.SyntaxError",{code:"invalid term definition",context:t});let a=e.mappings.get(n);if(e.mappings.has(n))e.mappings.delete(n);let l=!1;if(js(o)||o===null)l=!0,o={"@id":o};if(!fp(o))throw new _t("Invalid JSON-LD syntax; @context term values must be strings or objects.","jsonld.SyntaxError",{code:"invalid term definition",context:t});let c={};e.mappings.set(n,c),c.reverse=!1;let u=["@container","@id","@language","@reverse","@type"];if(Mn.processingMode(e,1.1))u.push("@context","@direction","@index","@nest","@prefix","@protected");for(let f in o)if(!u.includes(f))throw new _t("Invalid JSON-LD syntax; a term definition must not contain "+f,"jsonld.SyntaxError",{code:"invalid term definition",context:t});let p=n.indexOf(":");if(c._termHasColon=p>0,"@reverse"in o){if("@id"in o)throw new _t("Invalid JSON-LD syntax; a @reverse term definition must not contain @id.","jsonld.SyntaxError",{code:"invalid reverse property",context:t});if("@nest"in o)throw new _t("Invalid JSON-LD syntax; a @reverse term definition must not contain @nest.","jsonld.SyntaxError",{code:"invalid reverse property",context:t});let f=o["@reverse"];if(!js(f))throw new _t("Invalid JSON-LD syntax; a @context @reverse value must be a string.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});if(f.match(jS)){if(i.eventHandler)Ky({event:{type:["JsonLdEvent"],code:"reserved @reverse value",level:"warning",message:'@reverse values beginning with "@" are reserved for future use and dropped.',details:{reverse:f}},options:i});if(a)e.mappings.set(n,a);else e.mappings.delete(n);return}let m=Vy(e,f,{vocab:!0,base:!1},t,r,i);if(!ff(m))throw new _t("Invalid JSON-LD syntax; a @context @reverse value must be an absolute IRI or a blank node identifier.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});c["@id"]=m,c.reverse=!0}else if("@id"in o){let f=o["@id"];if(f&&!js(f))throw new _t("Invalid JSON-LD syntax; a @context @id value must be an array of strings or a string.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});if(f===null)c["@id"]=null;else if(!Mn.isKeyword(f)&&f.match(jS)){if(i.eventHandler)Ky({event:{type:["JsonLdEvent"],code:"reserved @id value",level:"warning",message:'@id values beginning with "@" are reserved for future use and dropped.',details:{id:f}},options:i});if(a)e.mappings.set(n,a);else e.mappings.delete(n);return}else if(f!==n){if(f=Vy(e,f,{vocab:!0,base:!1},t,r,i),!ff(f)&&!Mn.isKeyword(f))throw new _t("Invalid JSON-LD syntax; a @context @id value must be an absolute IRI, a blank node identifier, or a keyword.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});if(Mn.processingMode(e,1.1)&&n.match(/(?::[^:])|\//)){let m=new Map(r).set(n,!0);if(Vy(e,n,{vocab:!0,base:!1},t,m,i)!==f)throw new _t("Invalid JSON-LD syntax; term in form of IRI must expand to definition.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t})}c["@id"]=f,c._prefix=!c._termHasColon&&(Mn.processingMode(e,1)||l&&f.match(/[:\/\?#\[\]@]$/)!==null)}}if(!("@id"in c))if(c._termHasColon){let f=n.substr(0,p);if(t.hasOwnProperty(f))Mn.createTermDefinition({activeCtx:e,localCtx:t,term:f,defined:r,options:i});if(e.mappings.has(f)){let m=n.substr(p+1);c["@id"]=e.mappings.get(f)["@id"]+m}else c["@id"]=n}else if(n==="@type")c["@id"]=n;else{if(!("@vocab"in e))throw new _t("Invalid JSON-LD syntax; @context terms must define an @id.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t,term:n});c["@id"]=e["@vocab"]+n}if(o["@protected"]===!0||r.get("@protected")===!0&&o["@protected"]!==!1)e.protected[n]=!0,c.protected=!0;if(r.set(n,!0),"@type"in o){let f=o["@type"];if(!js(f))throw new _t("Invalid JSON-LD syntax; an @context @type value must be a string.","jsonld.SyntaxError",{code:"invalid type mapping",context:t});if(f==="@json"||f==="@none"){if(Mn.processingMode(e,1))throw new _t(`Invalid JSON-LD syntax; an @context @type value must not be "${f}" in JSON-LD 1.0 mode.`,"jsonld.SyntaxError",{code:"invalid type mapping",context:t})}else if(f!=="@id"&&f!=="@vocab"){if(f=Vy(e,f,{vocab:!0,base:!1},t,r,i),!ff(f))throw new _t("Invalid JSON-LD syntax; an @context @type value must be an absolute IRI.","jsonld.SyntaxError",{code:"invalid type mapping",context:t});if(f.indexOf("_:")===0)throw new _t("Invalid JSON-LD syntax; an @context @type value must be an IRI, not a blank node identifier.","jsonld.SyntaxError",{code:"invalid type mapping",context:t})}c["@type"]=f}if("@container"in o){let f=js(o["@container"])?[o["@container"]]:o["@container"]||[],m=["@list","@set","@index","@language"],y=!0,h=f.includes("@set");if(Mn.processingMode(e,1.1)){if(m.push("@graph","@id","@type"),f.includes("@list")){if(f.length!==1)throw new _t("Invalid JSON-LD syntax; @context @container with @list must have no other values","jsonld.SyntaxError",{code:"invalid container mapping",context:t})}else if(f.includes("@graph")){if(f.some((b)=>b!=="@graph"&&b!=="@id"&&b!=="@index"&&b!=="@set"))throw new _t("Invalid JSON-LD syntax; @context @container with @graph must have no other values other than @id, @index, and @set","jsonld.SyntaxError",{code:"invalid container mapping",context:t})}else y&=f.length<=(h?2:1);if(f.includes("@type")){if(c["@type"]=c["@type"]||"@id",!["@id","@vocab"].includes(c["@type"]))throw new _t("Invalid JSON-LD syntax; container: @type requires @type to be @id or @vocab.","jsonld.SyntaxError",{code:"invalid type mapping",context:t})}}else y&=!boe(o["@container"]),y&=f.length<=1;if(y&=f.every((b)=>m.includes(b)),y&=!(h&&f.includes("@list")),!y)throw new _t("Invalid JSON-LD syntax; @context @container value must be one of the following: "+m.join(", "),"jsonld.SyntaxError",{code:"invalid container mapping",context:t});if(c.reverse&&!f.every((b)=>["@index","@set"].includes(b)))throw new _t("Invalid JSON-LD syntax; @context @container value for a @reverse type definition must be @index or @set.","jsonld.SyntaxError",{code:"invalid reverse property",context:t});c["@container"]=f}if("@index"in o){if(!("@container"in o)||!c["@container"].includes("@index"))throw new _t(`Invalid JSON-LD syntax; @index without @index in @container: "${o["@index"]}" on term "${n}".`,"jsonld.SyntaxError",{code:"invalid term definition",context:t});if(!js(o["@index"])||o["@index"].indexOf("@")===0)throw new _t(`Invalid JSON-LD syntax; @index must expand to an IRI: "${o["@index"]}" on term "${n}".`,"jsonld.SyntaxError",{code:"invalid term definition",context:t});c["@index"]=o["@index"]}if("@context"in o)c["@context"]=o["@context"];if("@language"in o&&!("@type"in o)){let f=o["@language"];if(f!==null&&!js(f))throw new _t("Invalid JSON-LD syntax; @context @language value must be a string or null.","jsonld.SyntaxError",{code:"invalid language mapping",context:t});if(f!==null)f=f.toLowerCase();c["@language"]=f}if("@prefix"in o){if(n.match(/:|\//))throw new _t("Invalid JSON-LD syntax; @context @prefix used on a compact IRI term","jsonld.SyntaxError",{code:"invalid term definition",context:t});if(Mn.isKeyword(c["@id"]))throw new _t("Invalid JSON-LD syntax; keywords may not be used as prefixes","jsonld.SyntaxError",{code:"invalid term definition",context:t});if(typeof o["@prefix"]==="boolean")c._prefix=o["@prefix"]===!0;else throw new _t("Invalid JSON-LD syntax; @context value for @prefix must be boolean","jsonld.SyntaxError",{code:"invalid @prefix value",context:t})}if("@direction"in o){let f=o["@direction"];if(f!==null&&f!=="ltr"&&f!=="rtl")throw new _t('Invalid JSON-LD syntax; @direction value must be null, "ltr", or "rtl".',"jsonld.SyntaxError",{code:"invalid base direction",context:t});c["@direction"]=f}if("@nest"in o){let f=o["@nest"];if(!js(f)||f!=="@nest"&&f.indexOf("@")===0)throw new _t("Invalid JSON-LD syntax; @context @nest value must be a string which is not a keyword other than @nest.","jsonld.SyntaxError",{code:"invalid @nest value",context:t});c["@nest"]=f}let d=c["@id"];if(d==="@context"||d==="@preserve")throw new _t("Invalid JSON-LD syntax; @context and @preserve cannot be aliased.","jsonld.SyntaxError",{code:"invalid keyword alias",context:t});if(a&&a.protected&&!s){if(e.protected[n]=!0,c.protected=!0,!IF(a,c))throw new _t("Invalid JSON-LD syntax; tried to redefine a protected term.","jsonld.SyntaxError",{code:"protected term redefinition",context:t,term:n})}};Mn.expandIri=(e,t,n,r)=>Vy(e,t,n,void 0,void 0,r);function Vy(e,t,n,r,i,s){if(t===null||!js(t)||Mn.isKeyword(t))return t;if(t.match(jS))return null;if(r&&r.hasOwnProperty(t)&&i.get(t)!==!0)Mn.createTermDefinition({activeCtx:e,localCtx:r,term:t,defined:i,options:s});if(n=n||{},n.vocab){let a=e.mappings.get(t);if(a===null)return null;if(fp(a)&&"@id"in a)return a["@id"]}let o=t.indexOf(":");if(o>0){let a=t.substr(0,o),l=t.substr(o+1);if(a==="_"||l.indexOf("//")===0)return t;if(r&&r.hasOwnProperty(a))Mn.createTermDefinition({activeCtx:e,localCtx:r,term:a,defined:i,options:s});let c=e.mappings.get(a);if(c&&c._prefix)return c["@id"]+l;if(ff(t))return t}if(n.vocab&&"@vocab"in e)t=e["@vocab"]+t;else if(n.base){let a,l;if("@base"in e)if(e["@base"])l=Xv(s.base,e["@base"]),a=Xv(l,t);else l=e["@base"],a=t;else l=s.base,a=Xv(s.base,t);t=a}return t}Mn.getInitialContext=(e)=>{let t=JSON.stringify({processingMode:e.processingMode}),n=RS.get(t);if(n)return n;let r={processingMode:e.processingMode,mappings:new Map,inverse:null,getInverse:i,clone:a,revertToPreviousContext:l,protected:{}};if(RS.size===1e4)RS.clear();return RS.set(t,r),r;function i(){let c=this;if(c.inverse)return c.inverse;let u=c.inverse={},p=c.fastCurieMap={},d={},f=(c["@language"]||"@none").toLowerCase(),m=c["@direction"],y=c.mappings,h=[...y.keys()].sort(VBe);for(let b of h){let g=y.get(b);if(g===null)continue;let x=g["@container"]||"@none";if(x=[].concat(x).sort().join(""),g["@id"]===null)continue;let v=voe(g["@id"]);for(let D of v){let T=u[D],N=Mn.isKeyword(D);if(!T){if(u[D]=T={},!N&&!g._termHasColon){d[D]=[b];let O={iri:D,terms:d[D]};if(D[0]in p)p[D[0]].push(O);else p[D[0]]=[O]}}else if(!N&&!g._termHasColon)d[D].push(b);if(!T[x])T[x]={"@language":{},"@type":{},"@any":{}};if(T=T[x],o(b,T["@any"],"@none"),g.reverse)o(b,T["@type"],"@reverse");else if(g["@type"]==="@none")o(b,T["@any"],"@none"),o(b,T["@language"],"@none"),o(b,T["@type"],"@none");else if("@type"in g)o(b,T["@type"],g["@type"]);else if("@language"in g&&"@direction"in g){let O=g["@language"],C=g["@direction"];if(O&&C)o(b,T["@language"],`${O}_${C}`.toLowerCase());else if(O)o(b,T["@language"],O.toLowerCase());else if(C)o(b,T["@language"],`_${C}`);else o(b,T["@language"],"@null")}else if("@language"in g)o(b,T["@language"],(g["@language"]||"@null").toLowerCase());else if("@direction"in g)if(g["@direction"])o(b,T["@language"],`_${g["@direction"]}`);else o(b,T["@language"],"@none");else if(m)o(b,T["@language"],`_${m}`),o(b,T["@language"],"@none"),o(b,T["@type"],"@none");else o(b,T["@language"],f),o(b,T["@language"],"@none"),o(b,T["@type"],"@none")}}for(let b in p)s(p,b,1);return u}function s(c,u,p){let d=c[u],f=c[u]={},m,y;for(let h of d){if(m=h.iri,p>=m.length)y="";else y=m[p];if(y in f)f[y].push(h);else f[y]=[h]}for(let h in f){if(h==="")continue;s(f,h,p+1)}}function o(c,u,p){if(!u.hasOwnProperty(p))u[p]=c}function a(){let c={};if(c.mappings=goe.clone(this.mappings),c.clone=this.clone,c.inverse=null,c.getInverse=this.getInverse,c.protected=goe.clone(this.protected),this.previousContext)c.previousContext=this.previousContext.clone();if(c.revertToPreviousContext=this.revertToPreviousContext,"@base"in this)c["@base"]=this["@base"];if("@language"in this)c["@language"]=this["@language"];if("@vocab"in this)c["@vocab"]=this["@vocab"];return c}function l(){if(!this.previousContext)return this;return this.previousContext.clone()}};Mn.getContextValue=(e,t,n)=>{if(t===null){if(n==="@context")return;return null}if(e.mappings.has(t)){let r=e.mappings.get(t);if(qBe(n))return r;if(r.hasOwnProperty(n))return r[n]}if(n==="@language"&&n in e)return e[n];if(n==="@direction"&&n in e)return e[n];if(n==="@context")return;return null};Mn.processingMode=(e,t)=>{if(t.toString()>="1.1")return!e.processingMode||e.processingMode>="json-ld-"+t.toString();else return e.processingMode==="json-ld-1.0"};Mn.isKeyword=(e)=>{if(!js(e)||e[0]!=="@")return!1;switch(e){case"@base":case"@container":case"@context":case"@default":case"@direction":case"@embed":case"@explicit":case"@graph":case"@id":case"@included":case"@index":case"@json":case"@language":case"@list":case"@nest":case"@none":case"@omitDefault":case"@prefix":case"@preserve":case"@protected":case"@requireAll":case"@reverse":case"@set":case"@type":case"@value":case"@version":case"@vocab":return!0}return!1};function IF(e,t){if(!(e&&typeof e==="object")||!(t&&typeof t==="object"))return e===t;let n=Array.isArray(e);if(n!==Array.isArray(t))return!1;if(n){if(e.length!==t.length)return!1;for(let s=0;s{if(n===null||n===void 0)return null;if(t==="@default")r=Object.assign({},r,{isFrame:!1});if(!lo(n)&&!ta(n)){if(!i&&(t===null||$r(e,t,{vocab:!0},r)==="@graph")){if(r.eventHandler)na({event:{type:["JsonLdEvent"],code:"free-floating scalar",level:"warning",message:"Dropping free-floating scalar not in a list.",details:{value:n}},options:r});return null}return Toe({activeCtx:e,activeProperty:t,value:n,options:r})}if(lo(n)){let m=[],y=Fs(e,t,"@container")||[];i=i||y.includes("@list");for(let h=0;h1?h.slice().sort():h:[h];for(let g of b){let x=Fs(o,g,"@context");if(!Zv(x))e=await Jy({activeCtx:e,localCtx:x,options:r,propagate:!1})}}let d={};await Doe({activeCtx:e,activeProperty:t,expandedActiveProperty:a,element:n,expandedParent:d,options:r,insideList:i,typeKey:p,typeScopedContext:o}),c=Object.keys(d);let f=c.length;if("@value"in d){if("@type"in d&&(("@language"in d)||("@direction"in d)))throw new Wn('Invalid JSON-LD syntax; an element containing "@value" may not contain both "@type" and either "@language" or "@direction".',"jsonld.SyntaxError",{code:"invalid value object",element:d});let m=f-1;if("@type"in d)m-=1;if("@index"in d)m-=1;if("@language"in d)m-=1;if("@direction"in d)m-=1;if(m!==0)throw new Wn('Invalid JSON-LD syntax; an element containing "@value" may only have an "@index" property and either "@type" or either or both "@language" or "@direction".',"jsonld.SyntaxError",{code:"invalid value object",element:d});let y=d["@value"]===null?[]:La(d["@value"]),h=HBe(d,"@type");if(FS(e,1.1)&&h.includes("@json")&&h.length===1);else if(y.length===0){if(r.eventHandler)na({event:{type:["JsonLdEvent"],code:"null @value value",level:"warning",message:"Dropping null @value value.",details:{value:d}},options:r});d=null}else if(!y.every((b)=>qi(b)||jF(b))&&"@language"in d)throw new Wn("Invalid JSON-LD syntax; only strings may be language-tagged.","jsonld.SyntaxError",{code:"invalid language-tagged value",element:d});else if(!h.every((b)=>CS(b)&&!(qi(b)&&b.indexOf("_:")===0)||jF(b)))throw new Wn('Invalid JSON-LD syntax; an element containing "@value" and "@type" must have an absolute IRI for the value of "@type".',"jsonld.SyntaxError",{code:"invalid typed value",element:d})}else if("@type"in d&&!lo(d["@type"]))d["@type"]=[d["@type"]];else if("@set"in d||"@list"in d){if(f>1&&!(f===2&&("@index"in d)))throw new Wn('Invalid JSON-LD syntax; if an element has the property "@set" or "@list", then it can have at most one other property that is "@index".',"jsonld.SyntaxError",{code:"invalid set or list object",element:d});if("@set"in d)d=d["@set"],c=Object.keys(d),f=c.length}else if(f===1&&"@language"in d){if(r.eventHandler)na({event:{type:["JsonLdEvent"],code:"object with only @language",level:"warning",message:"Dropping object with only @language.",details:{value:d}},options:r});d=null}if(ta(d)&&!r.keepFreeFloatingNodes&&!i&&(t===null||a==="@graph"||(Fs(e,t,"@container")||[]).includes("@graph")))d=woe({value:d,count:f,options:r});return d};function woe({value:e,count:t,options:n}){if(t===0||"@value"in e||"@list"in e||t===1&&"@id"in e){if(n.eventHandler){let r,i;if(t===0)r="empty object",i="Dropping empty object.";else if("@value"in e)r="object with only @value",i="Dropping object with only @value.";else if("@list"in e)r="object with only @list",i="Dropping object with only @list.";else if(t===1&&"@id"in e)r="object with only @id",i="Dropping object with only @id.";na({event:{type:["JsonLdEvent"],code:r,level:"warning",message:i,details:{value:e}},options:n})}return null}return e}async function Doe({activeCtx:e,activeProperty:t,expandedActiveProperty:n,element:r,expandedParent:i,options:s={},insideList:o,typeKey:a,typeScopedContext:l}){let c=Object.keys(r).sort(),u=[],p,d=r[a]&&$r(e,lo(r[a])?r[a][0]:r[a],{vocab:!0},{...s,typeExpansion:!0})==="@json";for(let f of c){let m=r[f],y;if(f==="@context")continue;let h=$r(e,f,{vocab:!0},s);if(s.isFrame&&["@embed","@explicit","@requireAll","@omitDefault"].includes(h)){let v=lo(m)?m:[m];if(v.length!==1||(h==="@embed"?typeof v[0]!=="string"&&typeof v[0]!=="boolean":typeof v[0]!=="boolean"))throw new Wn("Invalid frame flag value.","jsonld.SyntaxError",{code:h==="@embed"?"invalid @embed value":"invalid frame",value:m})}if(h===null||!(CS(h)||CF(h))){if(s.eventHandler)na({event:{type:["JsonLdEvent"],code:"invalid property",level:"warning",message:"Dropping property that did not expand into an absolute IRI or keyword.",details:{property:f,expandedProperty:h}},options:s});continue}if(CF(h)){if(n==="@reverse")throw new Wn("Invalid JSON-LD syntax; a keyword cannot be used as a @reverse property.","jsonld.SyntaxError",{code:"invalid reverse property map",value:m});if(h in i&&h!=="@included"&&h!=="@type")throw new Wn("Invalid JSON-LD syntax; colliding keywords detected.","jsonld.SyntaxError",{code:"colliding keywords",keyword:h})}if(h==="@id"){if(!qi(m)){if(!s.isFrame)throw new Wn('Invalid JSON-LD syntax; "@id" value must a string.',"jsonld.SyntaxError",{code:"invalid @id value",value:m});if(ta(m)){if(!jF(m))throw new Wn('Invalid JSON-LD syntax; "@id" value an empty object or array of strings, if framing',"jsonld.SyntaxError",{code:"invalid @id value",value:m})}else if(lo(m)){if(!m.every((v)=>qi(v)))throw new Wn('Invalid JSON-LD syntax; "@id" value an empty object or array of strings, if framing',"jsonld.SyntaxError",{code:"invalid @id value",value:m})}else throw new Wn('Invalid JSON-LD syntax; "@id" value an empty object or array of strings, if framing',"jsonld.SyntaxError",{code:"invalid @id value",value:m})}ao(i,"@id",La(m).map((v)=>{if(qi(v)){let D=$r(e,v,{base:!0},s);if(s.eventHandler){if(D===null)if(v===null)na({event:{type:["JsonLdEvent"],code:"null @id value",level:"warning",message:"Null @id found.",details:{id:v}},options:s});else na({event:{type:["JsonLdEvent"],code:"reserved @id value",level:"warning",message:"Reserved @id found.",details:{id:v}},options:s});else if(!CS(D))na({event:{type:["JsonLdEvent"],code:"relative @id reference",level:"warning",message:"Relative @id reference found.",details:{id:v,expandedId:D}},options:s})}return D}return v}),{propertyIsArray:s.isFrame});continue}if(h==="@type"){if(ta(m))m=Object.fromEntries(Object.entries(m).map(([v,D])=>[$r(l,v,{vocab:!0}),La(D).map((T)=>$r(l,T,{base:!0,vocab:!0},{...s,typeExpansion:!0}))]));zBe(m,s.isFrame),ao(i,"@type",La(m).map((v)=>{if(qi(v)){let D=$r(l,v,{base:!0,vocab:!0},{...s,typeExpansion:!0});if(D!=="@json"&&!CS(D)){if(s.eventHandler)na({event:{type:["JsonLdEvent"],code:"relative @type reference",level:"warning",message:"Relative @type reference found.",details:{type:v}},options:s})}return D}return v}),{propertyIsArray:!!s.isFrame});continue}if(h==="@included"&&FS(e,1.1)){let v=La(await yp.expand({activeCtx:e,activeProperty:t,element:m,options:s}));if(!v.every((D)=>JBe(D)))throw new Wn("Invalid JSON-LD syntax; values of @included must expand to node objects.","jsonld.SyntaxError",{code:"invalid @included value",value:m});ao(i,"@included",v,{propertyIsArray:!0});continue}if(h==="@graph"&&!(ta(m)||lo(m)))throw new Wn('Invalid JSON-LD syntax; "@graph" value must not be an object or an array.',"jsonld.SyntaxError",{code:"invalid @graph value",value:m});if(h==="@value"){if(p=m,d&&FS(e,1.1))i["@value"]=m;else ao(i,"@value",m,{propertyIsArray:s.isFrame});continue}if(h==="@language"){if(m===null)continue;if(!qi(m)&&!s.isFrame)throw new Wn('Invalid JSON-LD syntax; "@language" value must be a string.',"jsonld.SyntaxError",{code:"invalid language-tagged string",value:m});m=La(m).map((v)=>qi(v)?v.toLowerCase():v);for(let v of m)if(qi(v)&&!v.match(xoe)){if(s.eventHandler)na({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:v}},options:s})}ao(i,"@language",m,{propertyIsArray:s.isFrame});continue}if(h==="@direction"){if(!qi(m)&&!s.isFrame)throw new Wn('Invalid JSON-LD syntax; "@direction" value must be a string.',"jsonld.SyntaxError",{code:"invalid base direction",value:m});m=La(m);for(let v of m)if(qi(v)&&v!=="ltr"&&v!=="rtl")throw new Wn('Invalid JSON-LD syntax; "@direction" must be "ltr" or "rtl".',"jsonld.SyntaxError",{code:"invalid base direction",value:m});ao(i,"@direction",m,{propertyIsArray:s.isFrame});continue}if(h==="@index"){if(!qi(m))throw new Wn('Invalid JSON-LD syntax; "@index" value must be a string.',"jsonld.SyntaxError",{code:"invalid @index value",value:m});ao(i,"@index",m);continue}if(h==="@reverse"){if(!ta(m))throw new Wn('Invalid JSON-LD syntax; "@reverse" value must be an object.',"jsonld.SyntaxError",{code:"invalid @reverse value",value:m});if(y=await yp.expand({activeCtx:e,activeProperty:"@reverse",element:m,options:s}),"@reverse"in y)for(let D in y["@reverse"])ao(i,D,y["@reverse"][D],{propertyIsArray:!0});let v=i["@reverse"]||null;for(let D in y){if(D==="@reverse")continue;if(v===null)v=i["@reverse"]={};ao(v,D,[],{propertyIsArray:!0});let T=y[D];for(let N=0;Nv==="@id"||v==="@index")){if(y=La(y),!s.isFrame)y=y.filter((v)=>{let D=Object.keys(v).length;return woe({value:v,count:D,options:s})!==null});if(y.length===0)continue;y=y.map((v)=>({"@graph":La(v)}))}if(b.mappings.has(f)&&b.mappings.get(f).reverse){let v=i["@reverse"]=i["@reverse"]||{};y=La(y);for(let D=0;D$r(m,g,{vocab:!0},s)==="@value"))throw new Wn("Invalid JSON-LD syntax; nested value must be a node object.","jsonld.SyntaxError",{code:"invalid @nest value",value:b});await Doe({activeCtx:m,activeProperty:t,expandedActiveProperty:n,element:b,expandedParent:i,options:s,insideList:o,typeScopedContext:l,typeKey:a})}}}function Toe({activeCtx:e,activeProperty:t,value:n,options:r}){if(n===null||n===void 0)return null;let i=$r(e,t,{vocab:!0},r);if(i==="@id")return $r(e,n,{base:!0},r);else if(i==="@type")return $r(e,n,{vocab:!0,base:!0},{...r,typeExpansion:!0});let s=Fs(e,t,"@type");if((s==="@id"||i==="@graph")&&qi(n)){let a=$r(e,n,{base:!0},r);if(a===null&&n.match(GBe)){if(r.eventHandler)na({event:{type:["JsonLdEvent"],code:"reserved @id value",level:"warning",message:"Reserved @id found.",details:{id:t}},options:r})}return{"@id":a}}if(s==="@vocab"&&qi(n))return{"@id":$r(e,n,{vocab:!0,base:!0},r)};if(CF(i))return n;let o={};if(s&&!["@id","@vocab","@none"].includes(s))o["@type"]=s;else if(qi(n)){let a=Fs(e,t,"@language");if(a!==null)o["@language"]=a;let l=Fs(e,t,"@direction");if(l!==null)o["@direction"]=l}if(!["boolean","number","string"].includes(typeof n)&&!(n&&Object.isFrozen(n)&&Object.prototype.toString.call(n)==="[object Number]"&&n[Symbol.for("umf.jsonld.exact-number")]===!0))n=n.toString();return o["@value"]=n,o}function WBe(e,t,n,r){let i=[],s=Object.keys(t).sort();for(let o of s){let a=$r(e,o,{vocab:!0},r),l=t[o];if(!lo(l))l=[l];for(let c of l){if(c===null)continue;if(!qi(c))throw new Wn("Invalid JSON-LD syntax; language map values must be strings.","jsonld.SyntaxError",{code:"invalid language map value",languageMap:t});let u={"@value":c};if(a!=="@none"){if(!o.match(xoe)){if(r.eventHandler)na({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:o}},options:r})}u["@language"]=o.toLowerCase()}if(n)u["@direction"]=n;i.push(u)}}return i}async function RF({activeCtx:e,options:t,activeProperty:n,value:r,asGraph:i,indexKey:s,propertyIndex:o}){let a=[],l=Object.keys(r).sort(),c=s==="@type";for(let u of l){if(c){let f=Fs(e,u,"@context");if(!Zv(f))e=await Jy({activeCtx:e,localCtx:f,propagate:!1,options:t})}let p=r[u];if(!lo(p))p=[p];p=await yp.expand({activeCtx:e,activeProperty:n,element:p,options:t,insideList:!1,insideIndex:!0});let d;if(o)if(u==="@none")d="@none";else d=Toe({activeCtx:e,activeProperty:s,value:u,options:t});else d=$r(e,u,{vocab:!0},t);if(s==="@id")u=$r(e,u,{base:!0},t);else if(c)u=d;for(let f of p){if(i&&!KBe(f))f={"@graph":[f]};if(s==="@type")if(d==="@none");else if(f["@type"])f["@type"]=[u].concat(f["@type"]);else f["@type"]=[u];else if(FF(f)&&!["@language","@type","@index"].includes(s))throw new Wn(`Invalid JSON-LD syntax; Attempt to add illegal key to value object: "${s}".`,"jsonld.SyntaxError",{code:"invalid value object",value:f});else if(o){if(d!=="@none")ao(f,o,d,{propertyIsArray:!0,prependValue:!0})}else if(d!=="@none"&&!(s in f))f[s]=u;a.push(f)}}return a}});var e_=z(function(TBt,Noe){var{isKeyword:koe}=mp(),Nl=El(),MF=Rs(),kl=so(),QBe=io(),ns={};Noe.exports=ns;ns.createMergedNodeMap=(e,t)=>{t=t||{};let n=t.issuer||new kl.IdentifierIssuer("_:b"),r={"@default":{}};return ns.createNodeMap(e,r,"@default",n),ns.mergeNodeMaps(r)};ns.createNodeMap=(e,t,n,r,i,s)=>{if(MF.isArray(e)){for(let c of e)ns.createNodeMap(c,t,n,r,void 0,s);return}if(!MF.isObject(e)){if(s)s.push(e);return}if(Nl.isValue(e)){if("@type"in e){let c=e["@type"];if(c.indexOf("_:")===0)e["@type"]=c=r.getId(c)}if(s)s.push(e);return}else if(s&&Nl.isList(e)){let c=[];ns.createNodeMap(e["@list"],t,n,r,i,c),s.push({"@list":c});return}if("@type"in e){let c=e["@type"];for(let u of c)if(u.indexOf("_:")===0)r.getId(u)}if(MF.isUndefined(i))i=Nl.isBlankNode(e)?r.getId(e["@id"]):e["@id"];if(s)s.push({"@id":i});let o=t[n],a=o[i]=o[i]||{};a["@id"]=i;let l=Object.keys(e).sort();for(let c of l){if(c==="@id")continue;if(c==="@reverse"){let p={"@id":i},d=e["@reverse"];for(let f in d){let m=d[f];for(let y of m){let h=y["@id"];if(Nl.isBlankNode(y))h=r.getId(h);ns.createNodeMap(y,t,n,r,h),kl.addValue(o[h],f,p,{propertyIsArray:!0,allowDuplicate:!1})}}continue}if(c==="@graph"){if(!(i in t))t[i]={};ns.createNodeMap(e[c],t,i,r);continue}if(c==="@included"){ns.createNodeMap(e[c],t,n,r);continue}if(c!=="@type"&&koe(c)){if(c==="@index"&&c in a&&(e[c]!==a[c]||e[c]["@id"]!==a[c]["@id"]))throw new QBe("Invalid JSON-LD syntax; conflicting @index property detected.","jsonld.SyntaxError",{code:"conflicting indexes",subject:a});a[c]=e[c];continue}let u=e[c];if(c.indexOf("_:")===0)c=r.getId(c);if(u.length===0){kl.addValue(a,c,[],{propertyIsArray:!0});continue}for(let p of u){if(c==="@type")p=p.indexOf("_:")===0?r.getId(p):p;if(Nl.isSubject(p)||Nl.isSubjectReference(p)){if("@id"in p&&!p["@id"])continue;let d=Nl.isBlankNode(p)?r.getId(p["@id"]):p["@id"];kl.addValue(a,c,{"@id":d},{propertyIsArray:!0,allowDuplicate:!1}),ns.createNodeMap(p,t,n,r,d)}else if(Nl.isValue(p))kl.addValue(a,c,p,{propertyIsArray:!0,allowDuplicate:!1});else if(Nl.isList(p)){let d=[];ns.createNodeMap(p["@list"],t,n,r,i,d),p={"@list":d},kl.addValue(a,c,p,{propertyIsArray:!0,allowDuplicate:!1})}else ns.createNodeMap(p,t,n,r,i),kl.addValue(a,c,p,{propertyIsArray:!0,allowDuplicate:!1})}}};ns.mergeNodeMapGraphs=(e)=>{let t={};for(let n of Object.keys(e).sort())for(let r of Object.keys(e[n]).sort()){let i=e[n][r];if(!(r in t))t[r]={"@id":r};let s=t[r];for(let o of Object.keys(i).sort())if(koe(o)&&o!=="@type")s[o]=kl.clone(i[o]);else for(let a of i[o])kl.addValue(s,o,kl.clone(a),{propertyIsArray:!0,allowDuplicate:!1})}return t};ns.mergeNodeMaps=(e)=>{let t=e["@default"],n=Object.keys(e).sort();for(let r of n){if(r==="@default")continue;let i=e[r],s=t[r];if(!s)t[r]=s={"@id":r,"@graph":[]};else if(!("@graph"in s))s["@graph"]=[];let o=s["@graph"];for(let a of Object.keys(i).sort()){let l=i[a];if(!Nl.isSubjectReference(l))o.push(l)}}return t}});var LF=z(function(SBt,Poe){var{isSubjectReference:YBe}=El(),{createMergedNodeMap:XBe}=e_(),Ooe={};Poe.exports=Ooe;Ooe.flatten=(e)=>{let t=XBe(e),n=[],r=Object.keys(t).sort();for(let i=0;i{let{useRdfType:n=!1,useNativeTypes:r=!1,rdfDirection:i=null}=t,s={},o={"@default":s},a={};if(i){if(!["compound-literal","i18n-datatype"].includes(i))throw new t_("Unknown rdfDirection value.","jsonld.InvalidRdfDirection",{value:i})}for(let u of e){let p=u.graph.termType==="DefaultGraph"?"@default":u.graph.value;if(!(p in o))o[p]={};if(p!=="@default"&&!(p in s))s[p]={"@id":p};let d=o[p],f=US(u.subject),m=US(u.predicate),y=u.object;if(!(f in d))d[f]={"@id":f};let h=d[f],b=US(y),g=!!b;if(g&&!(b in d))d[b]={"@id":b};if(m===e8e&&!n&&g){$oe(h,"@type",b,{propertyIsArray:!0});continue}let x=n8e(y,r,i,t);if($oe(h,m,x,{propertyIsArray:!0}),g)if(b===qS){let v=d[b];if(!("usages"in v))v.usages=[];v.usages.push({node:h,property:m,value:x})}else if(b in a)a[b]=!1;else a[b]={node:h,property:m,value:x}}for(let u in o){let p=o[u];if(i==="compound-literal")for(let[m,y]of Object.entries(p)){if(!m.startsWith("_:")||!("http://www.w3.org/1999/02/22-rdf-syntax-ns#direction"in y)||!mf.isObject(a[m]))continue;let h=(D,T=!1)=>{let N=y["http://www.w3.org/1999/02/22-rdf-syntax-ns#"+D];if(T&&N===void 0)return;if(!Array.isArray(N)||N.length!==1||Object.keys(N[0]).length!==1||typeof N[0]["@value"]!=="string")throw new t_("Invalid compound literal property.","jsonld.InvalidCompoundLiteral",{code:"invalid compound literal",property:D});return N[0]["@value"]},b=h("value"),g=h("language",!0),x=h("direction");if(g!==void 0&&!BF.test(g))throw new t_("Invalid compound literal language.","jsonld.InvalidCompoundLiteral",{code:"invalid language-tagged string"});if(!["ltr","rtl"].includes(x))throw new t_("Invalid compound literal direction.","jsonld.InvalidCompoundLiteral",{code:"invalid base direction"});if(Object.keys(y).some((D)=>!["@id","http://www.w3.org/1999/02/22-rdf-syntax-ns#value","http://www.w3.org/1999/02/22-rdf-syntax-ns#language","http://www.w3.org/1999/02/22-rdf-syntax-ns#direction"].includes(D))&&t.eventHandler)VF({event:{type:["JsonLdEvent"],code:"compound literal additional properties",level:"warning",message:"Compound literal conversion omits additional node properties.",details:{id:m}},options:t});let v=a[m];for(let D of v.node[v.property]){if(D["@id"]!==m)continue;if(delete D["@id"],D["@value"]=b,D["@direction"]=x,g!==void 0)D["@language"]=g}delete p[m]}if(!(qS in p))continue;let d=p[qS];if(!d.usages)continue;for(let f of d.usages){let m=f.node,y=f.property,h=f.value,b=[],g=[],x=Object.keys(m).length;while(y===LS&&mf.isObject(a[m["@id"]])&&mf.isArray(m[MS])&&m[MS].length===1&&mf.isArray(m[LS])&&m[LS].length===1&&(x===3||x===4&&mf.isArray(m["@type"])&&m["@type"].length===1&&m["@type"][0]===ZBe))if(b.push(m[MS][0]),g.push(m["@id"]),f=a[m["@id"]],m=f.node,y=f.property,h=f.value,x=Object.keys(m).length,!UF.isBlankNode(m))break;if(t.processingMode==="json-ld-1.0"&&y===MS){if(h["@id"]===qS)continue;h=p[h["@id"]][LS][0],b.pop(),g.pop()}delete h["@id"],h["@list"]=b.reverse();for(let v of g)delete p[v]}delete d.usages}let l=[],c=Object.keys(s).sort();for(let u of c){let p=s[u];if(u in o){let d=p["@graph"]=[],f=o[u],m=Object.keys(f).sort();for(let y of m){let h=f[y];if(!UF.isSubjectReference(h))d.push(h)}}if(!UF.isSubjectReference(p))l.push(p)}return l};function n8e(e,t,n,r){let i=US(e);if(i)return{"@id":i};if(!e.language&&r.umfRdfLiteral){let o=r.umfRdfLiteral(e,t);if(o!==void 0)return o}let s={"@value":e.value};if(e.language){if(!e.language.match(BF)){if(r.eventHandler)VF({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:e.language}},options:r})}s["@language"]=e.language}else{let o=e.datatype.value;if(!o)o=qF;if(o===t8e){o="@json";try{s["@value"]=JSON.parse(s["@value"])}catch(a){throw new t_("JSON literal could not be parsed.","jsonld.InvalidJsonLiteral",{code:"invalid JSON literal",value:s["@value"],cause:a})}}if(t&&[Ioe,Aoe,Roe,qF].includes(o))if(o===Ioe)if(s["@value"]==="true"||s["@value"]==="1")s["@value"]=!0;else if(s["@value"]==="false"||s["@value"]==="0")s["@value"]=!1;else s["@type"]=o;else if(o===Roe)if(mf.isNumeric(s["@value"])){let a=parseInt(s["@value"],10);if(a.toFixed(0)===s["@value"])s["@value"]=a}else s["@type"]=o;else if(o===Aoe)if(mf.isNumeric(s["@value"]))s["@value"]=parseFloat(s["@value"]);else s["@type"]=o;else s["@type"]=o;else if(n==="i18n-datatype"&&o.startsWith("https://www.w3.org/ns/i18n#")){let[,a,l]=o.split(/[#_]/);if(a.length>0){if(s["@language"]=a,!a.match(BF)){if(r.eventHandler)VF({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:a}},options:r})}}s["@direction"]=l}else if(o!==qF)s["@type"]=o}return s}function US(e){if(e.termType==="NamedNode")return e.value;else if(e.termType==="BlankNode")return"_:"+e.value;return null}});var Loe=z(function(kBt,Moe){Moe.exports=function e(t){if(typeof t==="number"&&isNaN(t))throw Error("NaN is not allowed");if(typeof t==="number"&&!isFinite(t))throw Error("Infinity is not allowed");if(t===null||typeof t!=="object")return JSON.stringify(t);if(t.toJSON instanceof Function)return e(t.toJSON());if(Array.isArray(t))return`[${t.reduce((i,s,o)=>`${i}${o===0?"":","}${e(s===void 0||typeof s==="symbol"?null:s)}`,"")}]`;return`{${Object.keys(t).sort().reduce((r,i)=>{if(t[i]===void 0||typeof t[i]==="symbol")return r;let s=r.length===0?"":",";return`${r}${s}${e(i)}:${e(t[i])}`},"")}}`}});var Joe=z(function(NBt,Koe){var{createNodeMap:r8e}=e_(),{isKeyword:i8e}=mp(),Boe=El(),s8e=Loe(),o8e=io(),BS=Rs(),a8e=so(),{handleEvent:yf}=By(),{RDF_FIRST:l8e,RDF_REST:c8e,RDF_NIL:u8e,RDF_TYPE:p8e,RDF_JSON_LITERAL:d8e,RDF_LANGSTRING:f8e,XSD_BOOLEAN:m8e,XSD_DOUBLE:qoe,XSD_INTEGER:y8e,XSD_STRING:Uoe}=PS(),{isAbsolute:VS}=jc(),Voe={};Koe.exports=Voe;Voe.toRDF=(e,t)=>{let n=new a8e.IdentifierIssuer("_:b"),r={"@default":{}};r8e(e,r,"@default",n);let i=[],s=Object.keys(r).sort();for(let o of s){let a;if(o==="@default")a={termType:"DefaultGraph",value:""};else if(VS(o))a=Gy(o);else{if(t.eventHandler)yf({event:{type:["JsonLdEvent"],code:"relative graph reference",level:"warning",message:"Relative graph reference found.",details:{graph:o}},options:t});continue}if(t.umfRdfTerm&&!t.umfRdfTerm(a))continue;h8e(i,r[o],a,n,t)}return i.filter((o)=>o.object!==null)};function h8e(e,t,n,r,i){let s=Object.keys(t).sort();for(let o of s){let a=t[o],l=Object.keys(a).sort();for(let c of l){let u=a[c];if(c==="@type")c=p8e;else if(i8e(c))continue;for(let p of u){let d=Gy(o);if(!VS(o)){if(i.eventHandler)yf({event:{type:["JsonLdEvent"],code:"relative subject reference",level:"warning",message:"Relative subject reference found.",details:{subject:o}},options:i});continue}if(i.umfRdfTerm&&!i.umfRdfTerm(d))continue;let f=Gy(c);if(!VS(c)){if(i.eventHandler)yf({event:{type:["JsonLdEvent"],code:"relative predicate reference",level:"warning",message:"Relative predicate reference found.",details:{predicate:c}},options:i});continue}if(f.termType==="BlankNode"&&!i.produceGeneralizedRdf){if(i.eventHandler)yf({event:{type:["JsonLdEvent"],code:"blank node predicate",level:"warning",message:"Dropping blank node predicate.",details:{property:r.getOldIds().find((y)=>r.getId(y)===c)}},options:i});continue}if(i.umfRdfTerm&&!i.umfRdfTerm(f))continue;let m=KF(p,r,e,n,i.rdfDirection,i);if(m)e.push({subject:d,predicate:f,object:m,graph:n})}}}}function g8e(e,t,n,r,i,s){let o={termType:"NamedNode",value:l8e},a={termType:"NamedNode",value:c8e},l={termType:"NamedNode",value:u8e},c=e.pop(),u=c?{termType:"BlankNode",value:t.getId().slice(2)}:l,p=u;for(let d of e){let f=KF(d,t,n,r,i,s),m={termType:"BlankNode",value:t.getId().slice(2)};n.push({subject:p,predicate:o,object:f,graph:r}),n.push({subject:p,predicate:a,object:m,graph:r}),p=m}if(c){let d=KF(c,t,n,r,i,s);n.push({subject:p,predicate:o,object:d,graph:r}),n.push({subject:p,predicate:a,object:l,graph:r})}return u}function KF(e,t,n,r,i,s){let o;if(Boe.isValue(e)){o={termType:"Literal",value:void 0,datatype:{termType:"NamedNode"}};let a=e["@value"],l=e["@type"]||null;if(s.umfRdfLanguage&&"@language"in e&&!s.umfRdfLanguage(e["@language"]))return null;if(l&&l!=="@json"&&s.umfRdfTerm&&!s.umfRdfTerm({termType:"NamedNode",value:l}))return null;if(l==="@json")o.value=s8e(a),o.datatype.value=d8e;else if(BS.isBoolean(a))o.value=a.toString(),o.datatype.value=l||m8e;else if(BS.isNumber(a)&&(a%1!==0||Math.abs(a)>=1000000000000000000000||l===qoe))o.value=a.toExponential(15).replace(/(\d)0*e\+?/,"$1E"),o.datatype.value=l||qoe;else if(BS.isNumber(a))o.value=a.toFixed(0),o.datatype.value=l||y8e;else if("@direction"in e&&i==="i18n-datatype"){let c=(e["@language"]||"").toLowerCase(),u=e["@direction"],p=`https://www.w3.org/ns/i18n#${c}_${u}`;o.datatype.value=p,o.value=a}else if("@direction"in e&&i==="compound-literal"){o=Gy(t.getId());let c=[["value",a],["direction",e["@direction"]]];if("@language"in e)c.push(["language",e["@language"].toLowerCase()]);for(let[u,p]of c)n.push({subject:o,predicate:Gy("http://www.w3.org/1999/02/22-rdf-syntax-ns#"+u),object:{termType:"Literal",value:p,datatype:{termType:"NamedNode",value:Uoe}},graph:r})}else if("@direction"in e&&i)throw new o8e("Unknown rdfDirection value.","jsonld.InvalidRdfDirection",{value:i});else if("@language"in e){if("@direction"in e&&!i){if(s.eventHandler)yf({event:{type:["JsonLdEvent"],code:"rdfDirection not set",level:"warning",message:"rdfDirection not set for @direction.",details:{object:o.value}},options:s})}o.value=a,o.datatype.value=l||f8e,o.language=e["@language"]}else{if("@direction"in e&&!i){if(s.eventHandler)yf({event:{type:["JsonLdEvent"],code:"rdfDirection not set",level:"warning",message:"rdfDirection not set for @direction.",details:{object:o.value}},options:s})}o.value=a,o.datatype.value=l||Uoe}}else if(Boe.isList(e)){let a=g8e(e["@list"],t,n,r,i,s);o={termType:a.termType,value:a.value}}else{let a=BS.isObject(e)?e["@id"]:e;o=Gy(a)}if(o.termType==="NamedNode"&&!VS(o.value)){if(s.eventHandler)yf({event:{type:["JsonLdEvent"],code:"relative object reference",level:"warning",message:"Relative object reference found.",details:{object:o.value}},options:s});return null}if(s.umfRdfTerm&&!s.umfRdfTerm(o))return null;return o}function Gy(e){if(e.startsWith("_:"))return{termType:"BlankNode",value:e.slice(2)};return{termType:"NamedNode",value:e}}});var Yoe=z(function(OBt,Qoe){var{isKeyword:JF}=mp(),ia=El(),En=Rs(),Kr=so(),Goe=jc(),gf=io(),{createNodeMap:b8e,mergeNodeMapGraphs:v8e}=e_(),ra={};Qoe.exports=ra;ra.frameMergedOrDefault=(e,t,n)=>{GF(t,n);let r={options:n,embedded:!1,graph:"@default",graphMap:{"@default":{}},subjectStack:[],link:{},bnodeMap:{}},i=new Kr.IdentifierIssuer("_:b");if(b8e(e,r.graphMap,"@default",i),n.merged)r.graphMap["@merged"]=v8e(r.graphMap),r.graph="@merged";r.subjects=r.graphMap[r.graph];let s=[];if(ra.frame(r,Object.keys(r.subjects).sort(),t,s),n.pruneBlankNodeIdentifiers)n.bnodesToClear=Object.keys(r.bnodeMap).filter((o)=>r.bnodeMap[o].length===1);return n.link={},KS(s,n)};ra.frame=(e,t,n,r,i=null)=>{zF(n),n=n[0];let s=e.options,o={embed:n_(n,s,"embed"),explicit:n_(n,s,"explicit"),requireAll:n_(n,s,"requireAll")};if(!e.link.hasOwnProperty(e.graph))e.link[e.graph]={};let a=e.link[e.graph],l=x8e(e,t,n,o),c=Object.keys(l).sort();for(let u of c){let p=l[u];if(i===null)e.uniqueEmbeds={[e.graph]:{}};else e.uniqueEmbeds[e.graph]=e.uniqueEmbeds[e.graph]||{};if(o.embed==="@link"&&u in a){hf(r,i,a[u]);continue}let d={"@id":u};if(u.indexOf("_:")===0)Kr.addValue(e.bnodeMap,u,d,{propertyIsArray:!0});if(a[u]=d,(o.embed==="@first"||o.embed==="@last")&&e.is11)throw new gf("Invalid JSON-LD syntax; invalid value of @embed.","jsonld.SyntaxError",{code:"invalid @embed value",frame:n});if(!e.embedded&&e.uniqueEmbeds[e.graph].hasOwnProperty(u))continue;if(e.embedded&&(o.embed==="@never"||_8e(p,e.graph,e.subjectStack))){hf(r,i,d);continue}if(e.embedded&&(o.embed=="@first"||o.embed=="@once")&&e.uniqueEmbeds[e.graph].hasOwnProperty(u)){hf(r,i,d);continue}if(o.embed==="@last"){if(u in e.uniqueEmbeds[e.graph])w8e(e,u)}if(e.uniqueEmbeds[e.graph][u]={parent:r,property:i},e.subjectStack.push({subject:p,graph:e.graph}),u in e.graphMap){let f=!1,m=null;if(!("@graph"in n))f=e.graph!=="@merged",m={};else if(m=n["@graph"][0],f=!(u==="@merged"||u==="@default"),!En.isObject(m))m={};if(f)ra.frame({...e,graph:u,embedded:!1},Object.keys(e.graphMap[u]).sort(),[m],d,"@graph")}if("@included"in n)ra.frame({...e,embedded:!1},t,n["@included"],d,"@included");for(let f of Object.keys(p).sort()){if(JF(f)){if(d[f]=Kr.clone(p[f]),f==="@type"){for(let m of p["@type"])if(m.indexOf("_:")===0)Kr.addValue(e.bnodeMap,m,d,{propertyIsArray:!0})}continue}if(o.explicit&&!(f in n))continue;for(let m of p[f]){let y=f in n?n[f]:Hoe(o);if(ia.isList(m)){let h=n[f]&&n[f][0]&&n[f][0]["@list"]?n[f][0]["@list"]:Hoe(o),b={"@list":[]};hf(d,f,b);let g=m["@list"];for(let x of g)if(ia.isSubjectReference(x))ra.frame({...e,embedded:!0},[x["@id"]],h,b,"@list");else hf(b,"@list",Kr.clone(x))}else if(ia.isSubjectReference(m))ra.frame({...e,embedded:!0},[m["@id"]],y,d,f);else if(HF(y[0],m))hf(d,f,Kr.clone(m))}}for(let f of Object.keys(n).sort()){if(f==="@type"){if(!En.isObject(n[f][0])||!("@default"in n[f][0]))continue}else if(JF(f))continue;let m=n[f][0]||{};if(!n_(m,s,"omitDefault")&&!(f in d)){let h="@null";if("@default"in m)h=Kr.clone(m["@default"]);if(!En.isArray(h))h=[h];d[f]=[{"@preserve":h}]}}for(let f of Object.keys(n["@reverse"]||{}).sort()){let m=n["@reverse"][f];for(let y of Object.keys(e.subjects))if(Kr.getValues(e.subjects[y],f).some((b)=>b["@id"]===u))d["@reverse"]=d["@reverse"]||{},Kr.addValue(d["@reverse"],f,[],{propertyIsArray:!0}),ra.frame({...e,embedded:!0},[y],m,d["@reverse"][f],i)}hf(r,i,d),e.subjectStack.pop()}};ra.cleanupNull=(e,t)=>{if(En.isArray(e))return e.map((r)=>ra.cleanupNull(r,t)).filter((r)=>r);if(e==="@null")return null;if(En.isObject(e)){if("@id"in e){let n=e["@id"];if(t.link.hasOwnProperty(n)){let r=t.link[n].indexOf(e);if(r!==-1)return t.link[n][r];t.link[n].push(e)}else t.link[n]=[e]}for(let n in e)e[n]=ra.cleanupNull(e[n],t)}return e};function Hoe(e){let t={};for(let n in e)if(e[n]!==void 0)t["@"+n]=[e[n]];return[t]}function _8e(e,t,n){for(let r=n.length-1;r>=0;--r){let i=n[r];if(i.graph===t&&i.subject["@id"]===e["@id"])return!0}return!1}function GF(e,t){if(En.isArray(e)){e.forEach((r)=>GF(r,t));return}if(!En.isObject(e))return;zF([e]);for(let r of["@embed","@explicit","@requireAll","@omitDefault"]){if(!(r in e))continue;let i=e[r];if(!En.isArray(i)||i.length!==1||r!=="@embed"&&typeof i[0]!=="boolean")throw new gf("Invalid frame flag value.","jsonld.SyntaxError",{code:r==="@embed"?"invalid @embed value":"invalid frame",frame:e})}let n=n_(e,t,"embed");if(n==="@link"||t.is11&&(n==="@first"||n==="@last"))throw new gf("Invalid value of @embed for processing mode.","jsonld.SyntaxError",{code:"invalid @embed value",frame:e});for(let[r,i]of Object.entries(e))if(!["@value","@default","@id","@type","@language","@direction"].includes(r))GF(i,t)}function n_(e,t,n){let r="@"+n,i=r in e?e[r][0]:t[n];if(n==="embed"){if(i===!0)i="@once";else if(i===!1)i="@never";else if(i!=="@always"&&i!=="@never"&&i!=="@link"&&i!=="@first"&&i!=="@last"&&i!=="@once")throw new gf("Invalid JSON-LD syntax; invalid value of @embed.","jsonld.SyntaxError",{code:"invalid @embed value",frame:e})}return i}function zF(e){if(!En.isArray(e)||e.length!==1||!En.isObject(e[0]))throw new gf("Invalid JSON-LD syntax; a JSON-LD frame must be a single object.","jsonld.SyntaxError",{frame:e});if("@id"in e[0]){for(let t of Kr.asArray(e[0]["@id"]))if(!(En.isObject(t)||Goe.isAbsolute(t))||En.isString(t)&&t.indexOf("_:")===0)throw new gf("Invalid JSON-LD syntax; invalid @id in frame.","jsonld.SyntaxError",{code:"invalid frame",frame:e})}if("@type"in e[0]){for(let t of Kr.asArray(e[0]["@type"]))if(!(En.isObject(t)||Goe.isAbsolute(t)||t==="@json")||En.isString(t)&&t.indexOf("_:")===0)throw new gf("Invalid JSON-LD syntax; invalid @type in frame.","jsonld.SyntaxError",{code:"invalid frame",frame:e})}}function x8e(e,t,n,r){let i={};for(let s of t){let o=e.graphMap[e.graph][s];if(Woe(e,o,n,r))i[s]=o}return i}function Woe(e,t,n,r){let i=!0,s=!1;for(let o in n){let a=!1,l=Kr.getValues(t,o),c=Kr.getValues(n,o).length===0;if(o==="@id"){if(En.isEmptyObject(n["@id"][0]||{}))a=!0;else if(n["@id"].length>=0)a=n["@id"].includes(l[0]);if(!r.requireAll)return a}else if(o==="@type"){if(i=!1,c){if(l.length>0)return!1;a=!0}else if(n["@type"].length===1&&En.isEmptyObject(n["@type"][0]))a=l.length>0;else for(let u of n["@type"])if(En.isObject(u)&&"@default"in u)a=!0;else a=a||l.some((p)=>p===u);if(!r.requireAll)return a}else if(JF(o))continue;else{let u=Kr.getValues(n,o)[0],p=!1;if(u)zF([u]),p="@default"in u;if(i=!1,l.length===0&&p)continue;if(l.length>0&&c)return!1;if(u===void 0){if(l.length>0)return!1;a=!0}else if(ia.isList(u)){let d=u["@list"][0];if(ia.isList(l[0])){let f=l[0]["@list"];if(ia.isValue(d))a=f.some((m)=>HF(d,m));else if(ia.isSubject(d)||ia.isSubjectReference(d))a=f.some((m)=>zoe(e,d,m,r))}}else if(ia.isValue(u))a=l.some((d)=>HF(u,d));else if(ia.isSubjectReference(u))a=l.some((d)=>zoe(e,u,d,r));else if(En.isObject(u))a=l.length>0;else a=!1}if(!a&&r.requireAll)return!1;s=s||a}return i||s}function w8e(e,t){let n=e.uniqueEmbeds[e.graph],r=n[t],{parent:i,property:s}=r,o={"@id":t};if(En.isArray(i)){for(let l=0;l{let c=Object.keys(n);for(let u of c)if(u in n&&En.isObject(n[u].parent)&&n[u].parent["@id"]===l)delete n[u],a(u)};a(t)}function KS(e,t){if(En.isArray(e))return e.map((n)=>KS(n,t));if(En.isObject(e)){if("@preserve"in e)return e["@preserve"][0];if(ia.isValue(e))return e;if(ia.isList(e))return e["@list"]=KS(e["@list"],t),e;if("@id"in e){let n=e["@id"];if(t.link.hasOwnProperty(n)){let r=t.link[n].indexOf(e);if(r!==-1)return t.link[n][r];t.link[n].push(e)}else t.link[n]=[e]}for(let n in e){if(n==="@id"&&t.bnodesToClear.includes(e[n])){delete e["@id"];continue}e[n]=KS(e[n],t)}}return e}function hf(e,t,n){if(En.isObject(e))Kr.addValue(e,t,n,{propertyIsArray:!0});else e.push(n)}function zoe(e,t,n,r){if(!("@id"in n))return!1;let i=e.subjects[n["@id"]];return i&&Woe(e,i,t,r)}function HF(e,t){let n=t["@value"],r=t["@type"],i=t["@language"],s=Object.prototype.hasOwnProperty.call(e,"@value")?En.isArray(e["@value"])?e["@value"]:[e["@value"]]:[],o=e["@type"]?En.isArray(e["@type"])?e["@type"]:[e["@type"]]:[],a=e["@language"]?En.isArray(e["@language"])?e["@language"]:[e["@language"]]:[];if(s.length===0&&o.length===0&&a.length===0)return!0;if(!(s.some((l)=>Kr.compareValues({"@value":n,"@type":r},{"@value":l,"@type":r}))||En.isEmptyObject(s[0])))return!1;if(!(!r&&o.length===0||o.includes(r)||r&&En.isEmptyObject(o[0])))return!1;if(!(!i&&a.length===0||a.includes(i)||i&&En.isEmptyObject(a[0])))return!1;return!0}});var sae=z(function(PBt,iae){var ZF=io(),{isArray:hp,isObject:gp,isString:tae,isUndefined:WF}=Rs(),{isList:XF,isValue:Mc,isGraph:nae,isSimpleGraph:Xoe,isSubjectReference:QF}=El(),{expandIri:eC,getContextValue:rs,isKeyword:rae,process:YF,processingMode:D8e}=mp(),{removeBase:Zoe,prependBase:T8e}=jc(),{REGEX_KEYWORD:S8e,addValue:co,asArray:JS,compareShortestLeast:E8e}=so(),Ut={};iae.exports=Ut;Ut.compact=async({activeCtx:e,activeProperty:t=null,element:n,options:r={}})=>{if(hp(n)){let s=[];for(let o=0;o1)c=Array.from(c).sort();let u=e;for(let d of c){let f=Ut.compactIri({activeCtx:u,iri:d,relativeTo:{vocab:!0}}),m=rs(a,f,"@context");if(!WF(m))e=await YF({activeCtx:e,localCtx:m,options:r,propagate:!1})}let p=Object.keys(n).sort();for(let d of p){let f=n[d];if(d==="@id"){let m=JS(f).map((h)=>Ut.compactIri({activeCtx:e,iri:h,relativeTo:{vocab:!1},base:r.base}));if(m.length===1)m=m[0];let y=Ut.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}});o[y]=m;continue}if(d==="@type"){let m=JS(f).map((x)=>Ut.compactIri({activeCtx:a,iri:x,relativeTo:{vocab:!0}}));if(m.length===1)m=m[0];let y=Ut.compactIri({activeCtx:e,iri:"@type",relativeTo:{vocab:!0}}),g=(rs(e,y,"@container")||[]).includes("@set")&&D8e(e,1.1)||hp(m)&&f.length===0;co(o,y,m,{propertyIsArray:g});continue}if(d==="@reverse"){let m=await Ut.compact({activeCtx:e,activeProperty:"@reverse",element:f,options:r});for(let y in m)if(e.mappings.has(y)&&e.mappings.get(y).reverse){let h=m[y],g=(rs(e,y,"@container")||[]).includes("@set")||!r.compactArrays;co(o,y,h,{propertyIsArray:g}),delete m[y]}if(Object.keys(m).length>0){let y=Ut.compactIri({activeCtx:e,iri:d,relativeTo:{vocab:!0}});co(o,y,m)}continue}if(d==="@preserve"){let m=await Ut.compact({activeCtx:e,activeProperty:t,element:f,options:r});if(!(hp(m)&&m.length===0))co(o,d,m);continue}if(d==="@index"){if((rs(e,t,"@container")||[]).includes("@index"))continue;let y=Ut.compactIri({activeCtx:e,iri:d,relativeTo:{vocab:!0}});co(o,y,f);continue}if(d!=="@graph"&&d!=="@list"&&d!=="@included"&&rae(d)){let m=Ut.compactIri({activeCtx:e,iri:d,relativeTo:{vocab:!0}});co(o,m,f);continue}if(!hp(f))throw new ZF("JSON-LD expansion error; expanded value must be an array.","jsonld.SyntaxError");if(f.length===0){let m=Ut.compactIri({activeCtx:e,iri:d,value:f,relativeTo:{vocab:!0},reverse:s}),y=e.mappings.has(m)?e.mappings.get(m)["@nest"]:null,h=o;if(y){if(eae(e,y,r),!gp(o[y]))o[y]={};h=o[y]}co(h,m,f,{propertyIsArray:!0})}for(let m of f){let y=Ut.compactIri({activeCtx:e,iri:d,value:m,relativeTo:{vocab:!0},reverse:s}),h=e.mappings.has(y)?e.mappings.get(y)["@nest"]:null,b=o;if(h){if(eae(e,h,r),!gp(o[h]))o[h]={};b=o[h]}let g=rs(e,y,"@container")||[],x=nae(m),v=XF(m),D;if(v)D=m["@list"];else if(x)D=m["@graph"];let T=await Ut.compact({activeCtx:e,activeProperty:y,element:v||x?D:m,options:r});if(v){if(!hp(T))T=[T];if(!g.includes("@list")){if(T={[Ut.compactIri({activeCtx:e,iri:"@list",relativeTo:{vocab:!0}})]:T},"@index"in m)T[Ut.compactIri({activeCtx:e,iri:"@index",relativeTo:{vocab:!0}})]=m["@index"]}else{co(b,y,T,{valueIsArray:!0,allowDuplicate:!0});continue}}if(x)if(g.includes("@graph")&&(g.includes("@id")||g.includes("@index")&&Xoe(m))){let N;if(b.hasOwnProperty(y))N=b[y];else b[y]=N={};let O=(g.includes("@id")?m["@id"]:m["@index"])||Ut.compactIri({activeCtx:e,iri:"@none",relativeTo:{vocab:!0}});co(N,O,T,{propertyIsArray:!r.compactArrays||g.includes("@set")})}else if(g.includes("@graph")&&Xoe(m)){if(hp(T)&&T.length>1)T={"@included":T};co(b,y,T,{propertyIsArray:!r.compactArrays||g.includes("@set")})}else{if(hp(T)&&T.length===1&&r.compactArrays)T=T[0];if(T={[Ut.compactIri({activeCtx:e,iri:"@graph",relativeTo:{vocab:!0}})]:T},"@id"in m)T[Ut.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}})]=m["@id"];if("@index"in m)T[Ut.compactIri({activeCtx:e,iri:"@index",relativeTo:{vocab:!0}})]=m["@index"];co(b,y,T,{propertyIsArray:!r.compactArrays||g.includes("@set")})}else if(g.includes("@language")||g.includes("@index")||g.includes("@id")||g.includes("@type")){let N;if(b.hasOwnProperty(y))N=b[y];else b[y]=N={};let O;if(g.includes("@language")){if(Mc(T))T=T["@value"];O=m["@language"]}else if(g.includes("@index")){let C=rs(e,y,"@index")||"@index",X=eC(e,C,{vocab:!0},r),te=Ut.compactIri({activeCtx:e,iri:X,value:C==="@index"?null:(m[X]||[])[0],relativeTo:{vocab:!0}});if(C==="@index")O=m["@index"],delete T[te];else{let L;if([O,...L]=JS(T[te]??[]),!tae(O))O=null;else switch(L.length){case 0:delete T[te];break;case 1:T[te]=r.compactArrays?L[0]:L;break;default:T[te]=L;break}}}else if(g.includes("@id")){let C=Ut.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}});O=T[C],delete T[C]}else if(g.includes("@type")){let C=Ut.compactIri({activeCtx:e,iri:"@type",relativeTo:{vocab:!0}}),X;switch([O,...X]=JS(T[C]||[]),X.length){case 0:delete T[C];break;case 1:T[C]=X[0];break;default:T[C]=X;break}if(Object.keys(T).length===1&&"@id"in m)T=await Ut.compact({activeCtx:e,activeProperty:y,element:{"@id":m["@id"]},options:r})}if(O===null||O===void 0)O=Ut.compactIri({activeCtx:e,iri:"@none",relativeTo:{vocab:!0}});co(N,O,T,{propertyIsArray:!r.compactArrays||g.includes("@set")})}else{let N=!r.compactArrays||g.includes("@set")||g.includes("@list")||hp(T)&&T.length===0||d==="@list"||d==="@graph";co(b,y,T,{propertyIsArray:N})}}}return o}return n};Ut.compactIri=({activeCtx:e,iri:t,value:n=null,relativeTo:r={vocab:!1},reverse:i=!1,base:s=null})=>{if(t===null)return t;if(e.isPropertyTermScoped&&e.previousContext)e=e.previousContext;let o=e.getInverse();if(rae(t)&&t in o&&"@none"in o[t]&&"@type"in o[t]["@none"]&&"@none"in o[t]["@none"]["@type"])return o[t]["@none"]["@type"]["@none"];if(r.vocab&&t in o){let p=e["@language"]||"@none",d=[];if(gp(n)&&"@index"in n&&!("@graph"in n))d.push("@index","@index@set");if(gp(n)&&"@preserve"in n)n=n["@preserve"][0];if(nae(n)){if("@index"in n)d.push("@graph@index","@graph@index@set","@index","@index@set");if("@id"in n)d.push("@graph@id","@graph@id@set");if(d.push("@graph","@graph@set","@set"),!("@index"in n))d.push("@graph@index","@graph@index@set","@index","@index@set");if(!("@id"in n))d.push("@graph@id","@graph@id@set")}else if(gp(n)&&!Mc(n))d.push("@id","@id@set","@type","@set@type");let f="@language",m="@null";if(i)f="@type",m="@reverse",d.push("@set");else if(XF(n)){if(!("@index"in n))d.push("@list");let h=n["@list"];if(h.length===0)f="@any",m="@none";else{let b=h.length===0?p:null,g=null;for(let x=0;x=0;--p){let d=l[p],f=d.terms;for(let m of f){let y=m+":"+t.substr(d.iri.length);if(e.mappings.get(m)._prefix&&(!e.mappings.has(y)||n===null&&e.mappings.get(y)["@id"]===t)&&(a===null||E8e(y,a)<0))a=y}}if(a!==null)return a;for(let[p,d]of e.mappings)if(d&&d._prefix&&t.startsWith(p+":"))throw new ZF(`Absolute IRI "${t}" confused with prefix "${p}".`,"jsonld.SyntaxError",{code:"IRI confused with prefix",context:e});if(!r.vocab)if("@base"in e)if(!e["@base"])return t;else{let p=Zoe(T8e(s,e["@base"]),t);return S8e.test(p)?`./${p}`:p}else return Zoe(s,t);return t};Ut.compactValue=({activeCtx:e,activeProperty:t,value:n,options:r})=>{if(Mc(n)){let a=rs(e,t,"@type"),l=rs(e,t,"@language"),c=rs(e,t,"@direction"),u=rs(e,t,"@container")||[],p="@index"in n&&!u.includes("@index");if(!p&&a!=="@none"){if(n["@type"]===a)return n["@value"];if("@language"in n&&n["@language"]===l&&"@direction"in n&&n["@direction"]===c)return n["@value"];if("@language"in n&&n["@language"]===l)return n["@value"];if("@direction"in n&&n["@direction"]===c)return n["@value"]}let d=Object.keys(n).length,f=d===1||d===2&&"@index"in n&&!p,m="@language"in e,y=tae(n["@value"]),h=e.mappings.has(t)&&e.mappings.get(t)["@language"]===null;if(f&&a!=="@none"&&(!m||!y||h))return n["@value"];let b={};if(p)b[Ut.compactIri({activeCtx:e,iri:"@index",relativeTo:{vocab:!0}})]=n["@index"];if("@type"in n)b[Ut.compactIri({activeCtx:e,iri:"@type",relativeTo:{vocab:!0}})]=Ut.compactIri({activeCtx:e,iri:n["@type"],relativeTo:{vocab:!0}});else if("@language"in n)b[Ut.compactIri({activeCtx:e,iri:"@language",relativeTo:{vocab:!0}})]=n["@language"];if("@direction"in n)b[Ut.compactIri({activeCtx:e,iri:"@direction",relativeTo:{vocab:!0}})]=n["@direction"];return b[Ut.compactIri({activeCtx:e,iri:"@value",relativeTo:{vocab:!0}})]=n["@value"],b}let i=eC(e,t,{vocab:!0},r),s=rs(e,t,"@type"),o=Ut.compactIri({activeCtx:e,iri:n["@id"],relativeTo:{vocab:s==="@vocab"},base:r.base});if(s==="@id"||s==="@vocab"||i==="@graph")return o;return{[Ut.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}})]:o}};function k8e(e,t,n,r,i,s){if(s===null)s="@null";let o=[];if((s==="@id"||s==="@reverse")&&gp(n)&&"@id"in n){if(s==="@reverse")o.push("@reverse");let l=Ut.compactIri({activeCtx:e,iri:n["@id"],relativeTo:{vocab:!0}});if(e.mappings.has(l)&&e.mappings.get(l)&&e.mappings.get(l)["@id"]===n["@id"])o.push.apply(o,["@vocab","@id"]);else o.push.apply(o,["@id","@vocab"])}else{o.push(s);let l=o.find((c)=>c.includes("_"));if(l)o.push(l.replace(/^[^_]+_/,"_"))}o.push("@none");let a=e.inverse[t];for(let l of r){if(!(l in a))continue;let c=a[l][i];for(let u of o){if(!(u in c))continue;return c[u]}}return null}function eae(e,t,n){if(eC(e,t,{vocab:!0},n)!=="@nest")throw new ZF("JSON-LD compact error; nested property must have an @nest value resolving to @nest.","jsonld.SyntaxError",{code:"invalid @nest value"})}});var aae=z(function($Bt,oae){oae.exports=(e)=>{class t{toString(){return"[object JsonLdProcessor]"}}return Object.defineProperty(t,"prototype",{writable:!1,enumerable:!1}),Object.defineProperty(t.prototype,"constructor",{writable:!0,enumerable:!1,configurable:!0,value:t}),t.compact=function(n,r){if(arguments.length<2)return Promise.reject(TypeError("Could not compact, too few arguments."));return e.compact(n,r)},t.expand=function(n){if(arguments.length<1)return Promise.reject(TypeError("Could not expand, too few arguments."));return e.expand(n)},t.flatten=function(n){if(arguments.length<1)return Promise.reject(TypeError("Could not flatten, too few arguments."));return e.flatten(n)},t}});var fae=z(function(IBt,dae){var lae=NS(),uae=Qse(),vp=so(),Lc=poe(),tC=vp.IdentifierIssuer,Ol=io(),N8e=kF(),rC=foe(),{expand:O8e}=Eoe(),{flatten:P8e}=LF(),{fromRDF:$8e}=Coe(),{toRDF:I8e}=Joe(),{frameMergedOrDefault:A8e,cleanupNull:R8e}=Yoe(),{isArray:Hy,isObject:bf,isString:bp}=Rs(),{isSubjectReference:j8e}=El(),{expandIri:F8e,getInitialContext:GS,process:cae,processingMode:nC}=mp(),{compact:C8e,compactIri:M8e}=sae(),{createNodeMap:L8e,createMergedNodeMap:q8e,mergeNodeMaps:U8e}=e_(),{logEventHandler:B8e,logWarningEventHandler:V8e,safeEventHandler:K8e,setDefaultEventHandler:J8e,setupEventHandler:G8e,strictEventHandler:H8e,unhandledEventHandler:z8e}=By(),pae=function(e){let t={},n=100,r=new N8e({max:100});e.compact=async function(s,o,a){if(arguments.length<2)throw TypeError("Could not compact, too few arguments.");if(o===null)throw new Ol("The compaction context must not be null.","jsonld.CompactError",{code:"invalid local context"});if(s===null)return null;if(a=i(a,{base:bp(s)?s:"",compactArrays:!0,compactToRelative:!0,graph:!1,skipExpansion:!1,link:!1,issuer:new tC("_:b"),contextResolver:new Lc({sharedCache:r})}),a.link)a.skipExpansion=!0;if(!a.compactToRelative)delete a.base;let l;if(a.skipExpansion)l=s;else l=await e.expand(s,a);let c=await e.processContext(GS(a),o,a),u=await C8e({activeCtx:c,element:l,options:a});if(a.compactArrays&&!a.graph&&Hy(u)){if(u.length===1)u=u[0];else if(u.length===0)u={}}else if(a.graph&&bf(u))u=[u];if(bf(o)&&"@context"in o)o=o["@context"];if(o=vp.clone(o),!Hy(o))o=[o];let p=o;o=[];for(let f=0;f0)o.push(p[f]);let d=o.length>0;if(o.length===1)o=o[0];if(Hy(u)){let f=M8e({activeCtx:c,iri:"@graph",relativeTo:{vocab:!0}}),m=u;if(u={},d)u["@context"]=o;u[f]=m}else if(bf(u)&&d){let f=u;u={"@context":o};for(let m in f)u[m]=f[m]}return u},e.expand=async function(s,o){if(arguments.length<1)throw TypeError("Could not expand, too few arguments.");o=i(o,{keepFreeFloatingNodes:!1,contextResolver:new Lc({sharedCache:r})});let a={},l=[];if("expandContext"in o){let d=vp.clone(o.expandContext);if(bf(d)&&"@context"in d)a.expandContext=d;else a.expandContext={"@context":d};l.push(a.expandContext)}let c;if(!bp(s))a.input=vp.clone(s);else{let d=await e.get(s,o);if(c=d.documentUrl,a.input=d.document,d.contextUrl)a.remoteContext={"@context":d.contextUrl},l.push(a.remoteContext)}if(!("base"in o))o.base=c||"";let u=GS(o);for(let d of l)u=await cae({activeCtx:u,localCtx:d,options:o});let p=await O8e({activeCtx:u,element:a.input,options:o});if(bf(p)&&"@graph"in p&&Object.keys(p).length===1)p=p["@graph"];else if(p===null)p=[];if(!Hy(p))p=[p];return p},e.flatten=async function(s,o,a){if(arguments.length<1)return TypeError("Could not flatten, too few arguments.");if(typeof o==="function")o=null;else o=o||null;a=i(a,{base:bp(s)?s:"",contextResolver:new Lc({sharedCache:r})});let l=await e.expand(s,a),c=P8e(l);if(o===null)return c;return a.graph=!0,a.skipExpansion=!0,await e.compact(c,o,a)},e.frame=async function(s,o,a){if(arguments.length<2)throw TypeError("Could not frame, too few arguments.");if(a=i(a,{base:bp(s)?s:"",embed:"@once",explicit:!1,requireAll:!1,omitDefault:!1,bnodesToClear:[],contextResolver:new Lc({sharedCache:r})}),bp(o)){let h=await e.get(o,a);if(o=h.document,h.contextUrl){let b=o["@context"];if(!b)b=h.contextUrl;else if(Hy(b))b.push(h.contextUrl);else b=[b,h.contextUrl];o["@context"]=b}}let l=o?o["@context"]||{}:{},c=await e.processContext(GS(a),l,a);if(!a.hasOwnProperty("omitGraph"))a.omitGraph=nC(c,1.1);if(!a.hasOwnProperty("pruneBlankNodeIdentifiers"))a.pruneBlankNodeIdentifiers=nC(c,1.1);let u=await e.expand(s,a),p={...a};p.isFrame=!0,p.keepFreeFloatingNodes=!0;let d=await e.expand(o,p),f=Object.keys(o).map((h)=>F8e(c,h,{vocab:!0}));p.merged=!a.frameDefault&&!f.includes("@graph"),p.is11=nC(c,1.1);let m=A8e(u,d,p);p.graph=!a.omitGraph,p.skipExpansion=!0,p.link={},p.framing=!0;let y=await e.compact(m,l,p);return p.link={},y=R8e(y,p),y},e.link=async function(s,o,a){let l={};if(o)l["@context"]=o;return l["@embed"]="@link",e.frame(s,l,a)},e.normalize=e.canonize=async function(s,o){if(arguments.length<1)throw TypeError("Could not canonize, too few arguments.");o=i(o,{skipExpansion:!1,safe:!0,contextResolver:new Lc({sharedCache:r})});let a=Object.assign({},{algorithm:"RDFC-1.0"},o.canonizeOptions||null);if("inputFormat"in o){if(o.inputFormat!=="application/n-quads")throw new Ol("Unknown canonicalization input format.","jsonld.CanonizeError");let u=rC.parse(s);return lae.canonize(u,a)}let l={...o};delete l.format,delete l.canonizeOptions,l.produceGeneralizedRdf=!1;let c=await e.toRDF(s,l);return lae.canonize(c,a)},e.fromRDF=async function(s,o){if(arguments.length<1)throw TypeError("Could not convert from RDF, too few arguments.");o=i(o,{format:bp(s)?"application/n-quads":void 0});let{format:a}=o,{rdfParser:l}=o;if(a){if(l=l||t[a],!l)throw new Ol("Unknown input format.","jsonld.UnknownFormat",{format:a})}else l=()=>s;let c=await l(s);return $8e(c,o)},e.toRDF=async function(s,o){if(arguments.length<1)throw TypeError("Could not convert to RDF, too few arguments.");o=i(o,{skipExpansion:!1,contextResolver:new Lc({sharedCache:r})});let a;if(o.skipExpansion)a=s;else a=await e.expand(s,o);let l=I8e(a,o);if(o.format){if(o.format==="application/n-quads")return rC.serialize(l);throw new Ol("Unknown output format.","jsonld.UnknownFormat",{format:o.format})}return l},e.createNodeMap=async function(s,o){if(arguments.length<1)throw TypeError("Could not create node map, too few arguments.");o=i(o,{base:bp(s)?s:"",contextResolver:new Lc({sharedCache:r})});let a=await e.expand(s,o);return q8e(a,o)},e.merge=async function(s,o,a){if(arguments.length<1)throw TypeError("Could not merge, too few arguments.");if(!Hy(s))throw TypeError('Could not merge, "docs" must be an array.');if(typeof o==="function")o=null;else o=o||null;a=i(a,{contextResolver:new Lc({sharedCache:r})});let l=await Promise.all(s.map((h)=>{let b={...a};return e.expand(h,b)})),c=!0;if("mergeNodes"in a)c=a.mergeNodes;let u=a.issuer||new tC("_:b"),p={"@default":{}};for(let h=0;he._documentLoader,set:(s)=>e._documentLoader=s}),e.documentLoader=async(s)=>{throw new Ol("Could not retrieve a JSON-LD document from the URL. URL dereferencing not implemented.","jsonld.LoadDocumentError",{code:"loading document failed",url:s})},e.get=async function(s,o){let a;if(typeof o.documentLoader==="function")a=o.documentLoader;else a=e.documentLoader;let l=await a(s);try{if(!l.document)throw new Ol("No remote document found at the given URL.","jsonld.NullRemoteDocument");if(bp(l.document))l.document=JSON.parse(l.document)}catch(c){throw new Ol("Could not retrieve a JSON-LD document from the URL.","jsonld.LoadDocumentError",{code:"loading document failed",cause:c,remoteDoc:l})}return l},e.processContext=async function(s,o,a){if(a=i(a,{base:"",contextResolver:new Lc({sharedCache:r})}),o===null)return GS(a);if(o=vp.clone(o),!(bf(o)&&("@context"in o)))o={"@context":o};return cae({activeCtx:s,localCtx:o,options:a})},e.getContextValue=mp().getContextValue,e.documentLoaders={},e.useDocumentLoader=function(s){if(!(s in e.documentLoaders))throw new Ol('Unknown document loader type: "'+s+'"',"jsonld.UnknownDocumentLoader",{type:s});e.documentLoader=e.documentLoaders[s].apply(e,Array.prototype.slice.call(arguments,1))},e.registerRDFParser=function(s,o){t[s]=o},e.unregisterRDFParser=function(s){delete t[s]},e.registerRDFParser("application/n-quads",rC.parse),e.url=jc(),e.logEventHandler=B8e,e.logWarningEventHandler=V8e,e.safeEventHandler=K8e,e.setDefaultEventHandler=J8e,e.strictEventHandler=H8e,e.unhandledEventHandler=z8e,e.util=vp,Object.assign(e,vp),e.promises=e,e.RequestQueue=DF(),e.JsonLdProcessor=aae()(e),uae.setupGlobals(e),uae.setupDocumentLoaders(e);function i(s,{documentLoader:o=e.documentLoader,...a}){if(s&&"compactionMap"in s)throw new Ol('"compactionMap" not supported.',"jsonld.OptionsError");if(s&&"expansionMap"in s)throw new Ol('"expansionMap" not supported.',"jsonld.OptionsError");return Object.assign({},{documentLoader:o},a,s,{eventHandler:G8e({options:s})})}return e},iC=function(){return pae(function(){return iC()})};pae(iC);dae.exports=iC});bo();bo();var xB=Ar(og(),1);var C3={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:json-schema:0.1.0",type:"object",required:["dialect","baseUri","root","resources"],properties:{dialect:{const:"https://json-schema.org/draft/2020-12/schema"},baseUri:{type:"string",minLength:1},root:{$ref:"#/$defs/node"},resources:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}},$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}};var M3={id:"umf.json-schema",version:"0.1.0",coreVersion:"0.1.0",description:"JSON Schema Draft 2020-12 syntax, scoped validation, and lossless-number native interchange",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:json-schema:0.1.0",type:"object",required:["dialect","baseUri","root","resources"],properties:{dialect:{const:"https://json-schema.org/draft/2020-12/schema"},baseUri:{type:"string",minLength:1},root:{$ref:"#/$defs/node"},resources:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}},$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"docs/helix/02-design/contracts/CONTRACT-002-json-schema.md",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"JSON Schema",version:"2020-12",subset:"Native JSON tree preservation; semantic validation limited to known dialect/keywords and JavaScript-compatible numerics, format annotation-only; see CONTRACT-002 and evidence."},evidence:["tests/json-schema/native.test.ts","tests/json-schema/upstream.test.ts"]}};var t0={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.7.0",title:"UMF 0.7.0 relationship envelope",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.7.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}},kind:{type:"string",minLength:1,description:"UMF role; unknown labels remain uninterpreted. Missing is unspecified, never inferred from scalarType."},nullability:{type:"string",minLength:1,description:"Ideal value availability. Unknown labels remain uninterpreted. Missing and unspecified assert no availability constraint. Native absence carriers require explicit bindings."},cardinality:{type:"string",minLength:1,description:"One ideal value, finite ordered sequence with duplicates allowed, finite exact string-key mapping with unique keys, or no assertion. Unknown labels remain uninterpreted."},itemType:{$ref:"#/$defs/itemType"},facets:{$ref:"#/$defs/facets"},members:{type:"array",uniqueItems:!0,items:{$ref:"#/$defs/keyFieldReference"}},keys:{type:"array",minItems:1,items:{$ref:"#/$defs/key"}}},allOf:[{if:{required:["kind"],properties:{kind:{enum:["record","group"]}}},then:{properties:{scalarType:!1}}},{if:{required:["nullability"],properties:{nullability:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{enum:["array","map"]}}},then:{not:{required:["scalarType"]}}},{if:{required:["itemType"],properties:{itemType:{}}},then:{required:["kind","cardinality"],properties:{kind:{const:"field"},cardinality:{enum:["array","map"]}}}},{if:{required:["facets"],properties:{facets:{}}},then:{required:["kind"],properties:{kind:{const:"field"},cardinality:{enum:["one","unspecified"]},references:{type:"array",not:{contains:{type:"object",required:["role"],properties:{role:{const:"record-type"}}}}}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{}}}}},then:{required:["scalarType"],properties:{scalarType:{enum:["string","binary"]}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"unicode-scalar"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"string"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"byte"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"binary"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["precision"],properties:{precision:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"decimal"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["integerWidth"],properties:{integerWidth:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"integer"}}}},{if:{properties:{members:{}},required:["members"]},then:{required:["kind"],properties:{kind:{const:"record"}}}},{if:{properties:{keys:{}},required:["keys"]},then:{required:["kind","members"],properties:{kind:{const:"record"},members:{}}}}]},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"},relationships:{type:"array",items:{$ref:"#/$defs/relationship"}}}},knownElementKind:{enum:["field","record","group"]},knownNullability:{enum:["required","absent-allowed","unspecified"]},knownCardinality:{enum:["one","array","map","unspecified"]},itemType:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},facets:{type:"object",description:"Missing members impose no bound. Unknown members and qualifiers are retained without interpretation.",properties:{length:{type:"object",required:["max","unit"],properties:{max:{type:"integer",minimum:0,maximum:9007199254740991},unit:{type:"string",minLength:1,description:"Known units: unicode-scalar for string, byte for binary. Unknown units remain uninterpreted."}}},precision:{type:"integer",minimum:1,maximum:9007199254740991,description:"Decimal coefficient digit bound; requires scale. Absolute coefficient is less than 10^precision. No implicit rounding."},scale:{type:"integer",minimum:0,maximum:9007199254740991,description:"Fixed fractional digit count; requires precision. Semantic validation requires scale <= precision. Value equals integer coefficient times 10^-scale."},integerWidth:{type:"object",required:["bits","signed"],properties:{bits:{type:"integer",minimum:1,maximum:9007199254740991},signed:{type:"boolean"}},description:"Signed [-2^(bits-1),2^(bits-1)-1] or unsigned [0,2^bits-1]; mathematical domain, not a physical storage-width assertion."}},dependentRequired:{precision:["scale"],scale:["precision"]}},keyFieldReference:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}},additionalProperties:!0},key:{type:"object",required:["id","name","fields"],properties:{id:{$ref:"#/$defs/id"},name:{$ref:"#/$defs/id"},fields:{type:"array",minItems:1,uniqueItems:!0,items:{$ref:"#/$defs/keyFieldReference"}},primary:{type:"boolean"}},additionalProperties:!0},relationshipEndpoint:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}},additionalProperties:!0},relationshipTarget:{type:"object",required:["module","element","key"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"},key:{$ref:"#/$defs/id"}},additionalProperties:!0},relationshipMultiplicity:{type:"object",required:["min","max"],properties:{min:{type:"integer",minimum:0,maximum:9007199254740991},max:{anyOf:[{type:"integer",minimum:1,maximum:9007199254740991},{const:"*"}]}},additionalProperties:!0},relationship:{type:"object",required:["id","name","source","target","sourceMultiplicity","targetMultiplicity","targetLifecycle","directed"],properties:{id:{$ref:"#/$defs/id"},name:{$ref:"#/$defs/id"},source:{type:"array",minItems:1,items:{$ref:"#/$defs/relationshipEndpoint"}},target:{type:"array",minItems:1,items:{$ref:"#/$defs/relationshipTarget"}},sourceMultiplicity:{$ref:"#/$defs/relationshipMultiplicity"},targetMultiplicity:{$ref:"#/$defs/relationshipMultiplicity"},targetLifecycle:{type:"string",minLength:1},directed:{type:"boolean"},inverse:{$ref:"#/$defs/id"},associationRecord:{$ref:"#/$defs/relationshipEndpoint"}},additionalProperties:!0}},description:"Authored schema-level relationships between keyed Records; native enforcement and storage are not inferred. Unknown qualifiers are retained.",$comment:"Exact endpoint/key resolution, unique IDs/names, inverse collisions, multiplicity bounds and lifecycle coherence require portable semantic validation."};var n0={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.6.0",title:"UMF 0.6.0 key envelope",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.6.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}},kind:{type:"string",minLength:1,description:"UMF role; unknown labels remain uninterpreted. Missing is unspecified, never inferred from scalarType."},nullability:{type:"string",minLength:1,description:"Ideal value availability. Unknown labels remain uninterpreted. Missing and unspecified assert no availability constraint. Native absence carriers require explicit bindings."},cardinality:{type:"string",minLength:1,description:"One ideal value, finite ordered sequence with duplicates allowed, finite exact string-key mapping with unique keys, or no assertion. Unknown labels remain uninterpreted."},itemType:{$ref:"#/$defs/itemType"},facets:{$ref:"#/$defs/facets"},members:{type:"array",uniqueItems:!0,items:{$ref:"#/$defs/keyFieldReference"}},keys:{type:"array",minItems:1,items:{$ref:"#/$defs/key"}}},allOf:[{if:{required:["kind"],properties:{kind:{enum:["record","group"]}}},then:{properties:{scalarType:!1}}},{if:{required:["nullability"],properties:{nullability:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{enum:["array","map"]}}},then:{not:{required:["scalarType"]}}},{if:{required:["itemType"],properties:{itemType:{}}},then:{required:["kind","cardinality"],properties:{kind:{const:"field"},cardinality:{enum:["array","map"]}}}},{if:{required:["facets"],properties:{facets:{}}},then:{required:["kind"],properties:{kind:{const:"field"},cardinality:{enum:["one","unspecified"]},references:{type:"array",not:{contains:{type:"object",required:["role"],properties:{role:{const:"record-type"}}}}}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{}}}}},then:{required:["scalarType"],properties:{scalarType:{enum:["string","binary"]}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"unicode-scalar"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"string"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"byte"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"binary"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["precision"],properties:{precision:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"decimal"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["integerWidth"],properties:{integerWidth:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"integer"}}}},{if:{properties:{members:{}},required:["members"]},then:{required:["kind"],properties:{kind:{const:"record"}}}},{if:{properties:{keys:{}},required:["keys"]},then:{required:["kind","members"],properties:{kind:{const:"record"},members:{}}}}]},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"}}},knownElementKind:{enum:["field","record","group"]},knownNullability:{enum:["required","absent-allowed","unspecified"]},knownCardinality:{enum:["one","array","map","unspecified"]},itemType:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},facets:{type:"object",description:"Missing members impose no bound. Unknown members and qualifiers are retained without interpretation.",properties:{length:{type:"object",required:["max","unit"],properties:{max:{type:"integer",minimum:0,maximum:9007199254740991},unit:{type:"string",minLength:1,description:"Known units: unicode-scalar for string, byte for binary. Unknown units remain uninterpreted."}}},precision:{type:"integer",minimum:1,maximum:9007199254740991,description:"Decimal coefficient digit bound; requires scale. Absolute coefficient is less than 10^precision. No implicit rounding."},scale:{type:"integer",minimum:0,maximum:9007199254740991,description:"Fixed fractional digit count; requires precision. Semantic validation requires scale <= precision. Value equals integer coefficient times 10^-scale."},integerWidth:{type:"object",required:["bits","signed"],properties:{bits:{type:"integer",minimum:1,maximum:9007199254740991},signed:{type:"boolean"}},description:"Signed [-2^(bits-1),2^(bits-1)-1] or unsigned [0,2^bits-1]; mathematical domain, not a physical storage-width assertion."}},dependentRequired:{precision:["scale"],scale:["precision"]}},keyFieldReference:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}},additionalProperties:!0},key:{type:"object",required:["id","name","fields"],properties:{id:{$ref:"#/$defs/id"},name:{$ref:"#/$defs/id"},fields:{type:"array",minItems:1,uniqueItems:!0,items:{$ref:"#/$defs/keyFieldReference"}},primary:{type:"boolean"}},additionalProperties:!0}},description:"Candidate envelope for authored named primary/alternate keys and explicit Record membership, retaining earlier Field, availability, cardinality and facet ideals. Cross-reference and equality semantics require portable validation; native enforcement is not inferred.",$comment:"Key membership resolution, unique ownership, key IDs/names/component sets, primary count and component domains require portable semantic validation. Native enforcement is not inferred."};var K3=Ar(og(),1);var L3={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.1.0",title:"UMF 0.1.0 document envelope",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.1.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}}}},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"}}}}};var q3={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.2.0",title:"UMF 0.2.0 field envelope",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.2.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}},kind:{type:"string",minLength:1,description:"UMF role; unknown labels remain uninterpreted. Missing is unspecified, never inferred from scalarType."}},allOf:[{if:{required:["kind"],properties:{kind:{enum:["record","group"]}}},then:{properties:{scalarType:!1}}}]},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"}}},knownElementKind:{enum:["field","record","group"]}},description:"Opt-in field/record/group roles. No implicit upgrade from 0.1.0. Provenance, migration and binding evidence remain required."};var U3={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.3.0",title:"UMF 0.3.0 nullability envelope",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.3.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}},kind:{type:"string",minLength:1,description:"UMF role; unknown labels remain uninterpreted. Missing is unspecified, never inferred from scalarType."},nullability:{type:"string",minLength:1,description:"Ideal value availability. Unknown labels remain uninterpreted. Missing and unspecified assert no availability constraint. Native absence carriers require explicit bindings."}},allOf:[{if:{required:["kind"],properties:{kind:{enum:["record","group"]}}},then:{properties:{scalarType:!1}}},{if:{required:["nullability"],properties:{nullability:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}}]},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"}}},knownElementKind:{enum:["field","record","group"]},knownNullability:{enum:["required","absent-allowed","unspecified"]}},description:"Explicit ideal value availability on Fields. No implicit upgrade from older envelopes, native NULL mapping, or default execution."};var B3={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.4.0",title:"UMF 0.4.0 cardinality envelope",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.4.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}},kind:{type:"string",minLength:1,description:"UMF role; unknown labels remain uninterpreted. Missing is unspecified, never inferred from scalarType."},nullability:{type:"string",minLength:1,description:"Ideal value availability. Unknown labels remain uninterpreted. Missing and unspecified assert no availability constraint. Native absence carriers require explicit bindings."},cardinality:{type:"string",minLength:1,description:"One ideal value, finite ordered sequence with duplicates allowed, finite exact string-key mapping with unique keys, or no assertion. Unknown labels remain uninterpreted."},itemType:{$ref:"#/$defs/itemType"}},allOf:[{if:{required:["kind"],properties:{kind:{enum:["record","group"]}}},then:{properties:{scalarType:!1}}},{if:{required:["nullability"],properties:{nullability:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{enum:["array","map"]}}},then:{not:{required:["scalarType"]}}},{if:{required:["itemType"],properties:{itemType:{}}},then:{required:["kind","cardinality"],properties:{kind:{const:"field"},cardinality:{enum:["array","map"]}}}}]},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"}}},knownElementKind:{enum:["field","record","group"]},knownNullability:{enum:["required","absent-allowed","unspecified"]},knownCardinality:{enum:["one","array","map","unspecified"]},itemType:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}}},description:"Explicit Field shape and optional array-item/map-value Field reference; no native repetition, dimension or physical encoding inference."};var r0={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.5.0",title:"UMF 0.5.0 facet envelope",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.5.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}},kind:{type:"string",minLength:1,description:"UMF role; unknown labels remain uninterpreted. Missing is unspecified, never inferred from scalarType."},nullability:{type:"string",minLength:1,description:"Ideal value availability. Unknown labels remain uninterpreted. Missing and unspecified assert no availability constraint. Native absence carriers require explicit bindings."},cardinality:{type:"string",minLength:1,description:"One ideal value, finite ordered sequence with duplicates allowed, finite exact string-key mapping with unique keys, or no assertion. Unknown labels remain uninterpreted."},itemType:{$ref:"#/$defs/itemType"},facets:{$ref:"#/$defs/facets"}},allOf:[{if:{required:["kind"],properties:{kind:{enum:["record","group"]}}},then:{properties:{scalarType:!1}}},{if:{required:["nullability"],properties:{nullability:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{enum:["array","map"]}}},then:{not:{required:["scalarType"]}}},{if:{required:["itemType"],properties:{itemType:{}}},then:{required:["kind","cardinality"],properties:{kind:{const:"field"},cardinality:{enum:["array","map"]}}}},{if:{required:["facets"],properties:{facets:{}}},then:{required:["kind"],properties:{kind:{const:"field"},cardinality:{enum:["one","unspecified"]},references:{type:"array",not:{contains:{type:"object",required:["role"],properties:{role:{const:"record-type"}}}}}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{}}}}},then:{required:["scalarType"],properties:{scalarType:{enum:["string","binary"]}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"unicode-scalar"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"string"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"byte"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"binary"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["precision"],properties:{precision:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"decimal"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["integerWidth"],properties:{integerWidth:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"integer"}}}}]},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"}}},knownElementKind:{enum:["field","record","group"]},knownNullability:{enum:["required","absent-allowed","unspecified"]},knownCardinality:{enum:["one","array","map","unspecified"]},itemType:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},facets:{type:"object",description:"Missing members impose no bound. Unknown members and qualifiers are retained without interpretation.",properties:{length:{type:"object",required:["max","unit"],properties:{max:{type:"integer",minimum:0,maximum:9007199254740991},unit:{type:"string",minLength:1,description:"Known units: unicode-scalar for string, byte for binary. Unknown units remain uninterpreted."}}},precision:{type:"integer",minimum:1,maximum:9007199254740991,description:"Decimal coefficient digit bound; requires scale. Absolute coefficient is less than 10^precision. No implicit rounding."},scale:{type:"integer",minimum:0,maximum:9007199254740991,description:"Fixed fractional digit count; requires precision. Semantic validation requires scale <= precision. Value equals integer coefficient times 10^-scale."},integerWidth:{type:"object",required:["bits","signed"],properties:{bits:{type:"integer",minimum:1,maximum:9007199254740991},signed:{type:"boolean"}},description:"Signed [-2^(bits-1),2^(bits-1)-1] or unsigned [0,2^bits-1]; mathematical domain, not a physical storage-width assertion."}},dependentRequired:{precision:["scale"],scale:["precision"]}}},description:"Candidate facet envelope: author-stated scalar bounds with explicit units. Requires semantic validation of scale <= precision, identities and references. Native enforcement, encoding and exactness require separate bindings."};var V3={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:extension-package:0.1.0",title:"UMF extension package declaration",type:"object",required:["id","version","coreVersion","description","schema","semantics","scopes","capabilities"],properties:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},coreVersion:{const:"0.1.0"},description:{type:"string",minLength:1},schema:{type:["object","boolean"]},semantics:{type:"string",minLength:1},scopes:{type:"array",minItems:1,uniqueItems:!0,items:{enum:["document","module","element"]}},capabilities:{type:"object",required:["validation","directions","evidence"],properties:{validation:{enum:["structural","semantic"]},directions:{type:"array",uniqueItems:!0,items:{enum:["import","export"]}},evidence:{type:"array",items:{type:"string",minLength:1}},native:{type:"object",required:["system","version","subset"],properties:{system:{type:"string",minLength:1},version:{type:"string",minLength:1},subset:{type:"string",minLength:1}}}},allOf:[{if:{properties:{directions:{type:"array",minItems:1}}},then:{properties:{native:!0},required:["native"]}}]}}};function Jp(e){if(Array.isArray(e))return"a["+e.map(Jp).join(",")+"]";if(e!==null&&typeof e==="object")return"o{"+Object.keys(e).sort().map((t)=>JSON.stringify(t)+":"+Jp(e[t])).join(",")+"}";return JSON.stringify(e)}function mt(e=!0){let t=new K3.default({allErrors:!0,strict:e,allowUnionTypes:!0,ownProperties:!0,validateFormats:!1});return Gp(t),t}function Gp(e){e.removeKeyword("uniqueItems").addKeyword({keyword:"uniqueItems",type:"array",schemaType:"boolean",errors:!1,validate:(t,n)=>!t||new Set(n.map(Jp)).size===n.length}),e.removeKeyword("const").addKeyword({keyword:"const",errors:!1,validate:(t,n)=>Jp(t)===Jp(n)}),e.removeKeyword("enum").addKeyword({keyword:"enum",schemaType:"array",errors:!1,validate:(t,n)=>t.some((r)=>Jp(r)===Jp(n))})}var pu=mt(),J3=pu.compile(L3),G3=pu.compile(q3),H3=pu.compile(U3),z3=pu.compile(B3),W3=pu.compile(r0),C1=pu.compile(V3),Q3=pu.compile(n0),Y3=pu.compile(t0);var X3=["boolean","integer","decimal","float","string","binary","date","time","timestamp"],Z3=["field","record","group"],eB=["required","absent-allowed","unspecified"],tB=["one","array","map","unspecified"];class U extends Error{code;path;constructor(e,t,n=""){super(t);this.code=e;this.path=n;this.name="UmfError"}}var Pe=(e)=>e.replace(/~/g,"~0").replace(/\//g,"~1");var Zt={maxDepth:128,maxValues:1e5,maxTextLength:4000000};function Ae(e){let t=new Set,n=0;function r(i,s,o){if(++n>Zt.maxValues||o>Zt.maxDepth)throw new U("LIMIT","JSON structural limit exceeded",s);if(i===null||typeof i==="string"||typeof i==="boolean")return i;if(typeof i==="number"){if(!Number.isFinite(i)||Object.is(i,-0)||Number.isInteger(i)&&!Number.isSafeInteger(i))throw new U("NUMBER","Number outside the core interoperable numeric profile",s);return i}if(typeof i!=="object")throw new U("NON_JSON","Value is not JSON-compatible",s);if(t.has(i))throw new U("CYCLE","Cyclic value",s);let a=Object.getPrototypeOf(i);if(Array.isArray(i)?a!==Array.prototype:a!==Object.prototype&&a!==null)throw new U("NON_JSON","Custom object prototype",s);if(Object.getOwnPropertySymbols(i).length)throw new U("NON_JSON","Symbol keys are not JSON-compatible",s);t.add(i);let l=Object.getOwnPropertyDescriptors(i),c=Array.isArray(i)?[]:Object.create(null);for(let[u,p]of Object.entries(l)){if(Array.isArray(i)&&u==="length")continue;if(!p.enumerable||!("value"in p))throw new U("NON_JSON","Hidden fields and accessors cannot be serialized faithfully",s+"/"+Pe(u));if(Array.isArray(i)&&!/^(0|[1-9][0-9]*)$/.test(u))throw new U("NON_JSON","Non-index array property",s);let d=r(p.value,s+"/"+Pe(u),o+1);Object.defineProperty(c,u,{value:d,enumerable:!0,writable:!0,configurable:!0})}if(Array.isArray(i)&&Object.keys(i).length!==i.length)throw new U("NON_JSON","Sparse arrays are not JSON values",s);return t.delete(i),c}return r(e,"",0)}function nB(e){if(e&&typeof e==="object"){Object.freeze(e);for(let t of Object.values(e))nB(t)}}class nt{#e=new Map;register(e,t){let n=Ae(e);if(!C1(n))throw new U("PACKAGE_STRUCTURE",JSON.stringify(C1.errors));if(this.get(n.id,n.version))throw new U("DUPLICATE_VERSION","Extension version is already registered");let r;try{r=mt().compile(n.schema)}catch(s){throw new U("PACKAGE_SCHEMA",String(s))}nB(n);let i={manifest:n,structure:r,...t?{semantics:t}:{}};if(Object.freeze(i),!this.#e.has(n.id))this.#e.set(n.id,new Map);return this.#e.get(n.id).set(n.version,i),this}get(e,t){return this.#e.get(e)?.get(t)}}bo();function rB(e){let t=/^([+-]?)(\d*)(?:\.(\d*))?(?:[eE]([+-]?\d+))?$/.exec(e);if(!t)throw new U("NUMBER","Unsupported numeric spelling");let n=((t[2]||"")+(t[3]||"")).replace(/^0+/,"");if(!n)return"0";let r=n.replace(/0+$/,""),i=BigInt(t[4]||"0")-BigInt((t[3]||"").length)+BigInt(n.length-r.length);return`${t[1]==="-"?"-":""}${r}e${i}`}function ms(e,t="yaml"){if(e.length>Zt.maxTextLength)throw new U("LIMIT","Source text exceeds limit");if(t==="json")try{JSON.parse(e)}catch{throw new U("SYNTAX","Invalid JSON syntax")}let n=go(e,{version:"1.2",schema:"core",uniqueKeys:!0,intAsBigInt:!0,strict:!0});if(n.errors.length||n.warnings.length)throw new U("SYNTAX",[...n.errors,...n.warnings].map((s)=>s.message).join("; "));if(n.directives?.yaml.version!=="1.2")throw new U("SYNTAX","Only YAML 1.2 is supported");let r=0;function i(s,o,a){if(++r>Zt.maxValues||a>Zt.maxDepth)throw new U("LIMIT","Source structural limit exceeded",o);if(s===null)return null;if(Vs(s))throw new U("ALIAS","YAML aliases are outside the JSON-compatible profile",o);if((ft(s)||dr(s)||Gr(s))&&s.tag)throw new U("TAG","Explicit YAML tags are outside the profile",o);if(ft(s)){let l=s.value;if(typeof l==="bigint"){let c=Number(l);if(!Number.isSafeInteger(c))throw new U("NUMBER","Integer exceeds exact JavaScript range",o);l=c}if(typeof l==="number"&&s.source){if(Number.isFinite(l)&&!/^[-+]?0[xo]/i.test(s.source)&&rB(s.source)!==rB(String(l)))throw new U("NUMBER","Parsing would change the decimal value",o);if(/^-0(?:\.0*)?(?:[eE][+-]?\d+)?$/.test(s.source))throw new U("NUMBER","Negative zero is outside the numeric profile",o)}return Ae(l)}if(Gr(s))return s.items.map((l,c)=>i(l,`${o}/${c}`,a+1));if(dr(s)){let l=Object.create(null);for(let c of s.items){if(!ft(c.key)||typeof c.key.value!=="string"||c.key.tag)throw new U("KEY","Mappings require untagged string keys",o);let u=c.key.value;if(Object.hasOwn(l,u))throw new U("DUPLICATE_KEY","Duplicate mapping key",o);l[u]=i(c.value,`${o}/${Pe(u)}`,a+1)}return l}throw new U("NON_JSON","Unsupported YAML node",o)}return i(n.contents,"",0)}function M1(e,t="yaml"){let n=Ae(e),r=t==="json"?JSON.stringify(n,null,2)+` -`:Ul(n,{version:"1.2",aliasDuplicateObjects:!1,lineWidth:0});if(r.length>Zt.maxTextLength)throw new U("LIMIT","Serialized text exceeds limit");return r}var i0={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.8.0",title:"UMF 0.8.0 schema properties",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.8.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"},title:{type:"string"},aliases:{type:"array",uniqueItems:!0,items:{type:"string",minLength:1}}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}},kind:{type:"string",minLength:1,description:"UMF role; unknown labels remain uninterpreted. Missing is unspecified, never inferred from scalarType."},nullability:{type:"string",minLength:1,description:"Ideal value availability. Unknown labels remain uninterpreted. Missing and unspecified assert no availability constraint. Native absence carriers require explicit bindings."},cardinality:{type:"string",minLength:1,description:"One ideal value, finite ordered sequence with duplicates allowed, finite exact string-key mapping with unique keys, or no assertion. Unknown labels remain uninterpreted."},itemType:{$ref:"#/$defs/itemType"},facets:{$ref:"#/$defs/facets"},members:{type:"array",uniqueItems:!0,items:{$ref:"#/$defs/keyFieldReference"}},keys:{type:"array",minItems:1,items:{$ref:"#/$defs/key"}},title:{type:"string"},aliases:{type:"array",uniqueItems:!0,items:{type:"string",minLength:1}},examples:{type:"array",items:{$ref:"#/$defs/literal"}},allowedValues:{type:"array",minItems:1,items:{$ref:"#/$defs/literal"}},default:{type:"object",required:["value","on"],properties:{value:{$ref:"#/$defs/literal"},on:{enum:["missing","null","missing-or-null"]}},additionalProperties:!0}},allOf:[{if:{required:["kind"],properties:{kind:{enum:["record","group"]}}},then:{properties:{scalarType:!1}}},{if:{required:["nullability"],properties:{nullability:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{enum:["array","map"]}}},then:{not:{required:["scalarType"]}}},{if:{required:["itemType"],properties:{itemType:{}}},then:{required:["kind","cardinality"],properties:{kind:{const:"field"},cardinality:{enum:["array","map"]}}}},{if:{required:["facets"],properties:{facets:{}}},then:{required:["kind"],properties:{kind:{const:"field"},references:{type:"array",not:{contains:{type:"object",required:["role"],properties:{role:{const:"record-type"}}}}}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{}}}}},then:{required:["scalarType"],properties:{scalarType:{enum:["string","binary"]}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"unicode-scalar"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"string"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"byte"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"binary"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["precision"],properties:{precision:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"decimal"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["integerWidth"],properties:{integerWidth:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"integer"}}}},{if:{properties:{members:{}},required:["members"]},then:{required:["kind"],properties:{kind:{const:"record"}}}},{if:{properties:{keys:{}},required:["keys"]},then:{required:["kind","members"],properties:{kind:{const:"record"},members:{}}}},{if:{required:["examples"],properties:{examples:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["allowedValues"],properties:{allowedValues:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["default"],properties:{default:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}}]},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"},relationships:{type:"array",items:{$ref:"#/$defs/relationship"}},title:{type:"string"},aliases:{type:"array",uniqueItems:!0,items:{type:"string",minLength:1}}}},knownElementKind:{enum:["field","record","group"]},knownNullability:{enum:["required","absent-allowed","unspecified"]},knownCardinality:{enum:["one","array","map","unspecified"]},itemType:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},facets:{type:"object",description:"Missing members impose no bound. Unknown members and qualifiers are retained without interpretation.",properties:{length:{type:"object",required:["unit"],anyOf:[{required:["min"],properties:{min:{}}},{required:["max"],properties:{max:{}}}],properties:{min:{type:"integer",minimum:0,maximum:9007199254740991},max:{type:"integer",minimum:0,maximum:9007199254740991},unit:{type:"string",minLength:1}},additionalProperties:!0},precision:{type:"integer",minimum:1,maximum:9007199254740991,description:"Decimal coefficient digit bound; requires scale. Absolute coefficient is less than 10^precision. No implicit rounding."},scale:{type:"integer",minimum:0,maximum:9007199254740991,description:"Fixed fractional digit count; requires precision. Semantic validation requires scale <= precision. Value equals integer coefficient times 10^-scale."},integerWidth:{type:"object",required:["bits","signed"],properties:{bits:{type:"integer",minimum:1,maximum:9007199254740991},signed:{type:"boolean"}},description:"Signed [-2^(bits-1),2^(bits-1)-1] or unsigned [0,2^bits-1]; mathematical domain, not a physical storage-width assertion."},collectionSize:{type:"object",anyOf:[{required:["min"],properties:{min:{}}},{required:["max"],properties:{max:{}}}],properties:{min:{type:"integer",minimum:0,maximum:9007199254740991},max:{type:"integer",minimum:0,maximum:9007199254740991}},additionalProperties:!0},range:{type:"object",anyOf:[{required:["min"],properties:{min:{}}},{required:["max"],properties:{max:{}}}],properties:{min:{$ref:"#/$defs/literal"},max:{$ref:"#/$defs/literal"},minInclusive:{type:"boolean"},maxInclusive:{type:"boolean"}},additionalProperties:!0}},dependentRequired:{precision:["scale"],scale:["precision"]}},keyFieldReference:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}},additionalProperties:!0},key:{type:"object",required:["id","name","fields"],properties:{id:{$ref:"#/$defs/id"},name:{$ref:"#/$defs/id"},fields:{type:"array",minItems:1,uniqueItems:!0,items:{$ref:"#/$defs/keyFieldReference"}},primary:{type:"boolean"}},additionalProperties:!0},relationshipEndpoint:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}},additionalProperties:!0},relationshipTarget:{type:"object",required:["module","element","key"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"},key:{$ref:"#/$defs/id"}},additionalProperties:!0},relationshipMultiplicity:{type:"object",required:["min","max"],properties:{min:{type:"integer",minimum:0,maximum:9007199254740991},max:{anyOf:[{type:"integer",minimum:1,maximum:9007199254740991},{const:"*"}]}},additionalProperties:!0},relationship:{type:"object",required:["id","name","source","target","sourceMultiplicity","targetMultiplicity","targetLifecycle","directed"],properties:{id:{$ref:"#/$defs/id"},name:{$ref:"#/$defs/id"},source:{type:"array",minItems:1,items:{$ref:"#/$defs/relationshipEndpoint"}},target:{type:"array",minItems:1,items:{$ref:"#/$defs/relationshipTarget"}},sourceMultiplicity:{$ref:"#/$defs/relationshipMultiplicity"},targetMultiplicity:{$ref:"#/$defs/relationshipMultiplicity"},targetLifecycle:{type:"string",minLength:1},directed:{type:"boolean"},inverse:{$ref:"#/$defs/id"},associationRecord:{$ref:"#/$defs/relationshipEndpoint"}},additionalProperties:!0},literal:{oneOf:[{type:"null"},{type:"object",required:["boolean"],properties:{boolean:{type:"boolean"}},additionalProperties:!1},{type:"object",required:["integerToken"],properties:{integerToken:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$(?![\\s\\S])"}},additionalProperties:!1},{type:"object",required:["decimalToken"],properties:{decimalToken:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$(?![\\s\\S])"}},additionalProperties:!1},{type:"object",required:["string"],properties:{string:{type:"string"}},additionalProperties:!1},{type:"object",required:["binaryHex"],properties:{binaryHex:{type:"string",pattern:"^([0-9a-fA-F]{2})*$(?![\\s\\S])"}},additionalProperties:!1},{type:"object",required:["floatToken"],properties:{floatToken:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$(?![\\s\\S])"}},additionalProperties:!1},{type:"object",required:["date"],properties:{date:{type:"string"}},additionalProperties:!1},{type:"object",required:["time"],properties:{time:{type:"string"}},additionalProperties:!1},{type:"object",required:["timestamp"],properties:{timestamp:{type:"string"}},additionalProperties:!1},{type:"object",required:["array"],properties:{array:{type:"array",items:{$ref:"#/$defs/literal"}}},additionalProperties:!1},{type:"object",required:["map"],properties:{map:{type:"object",additionalProperties:{$ref:"#/$defs/literal"}}},additionalProperties:!1}]}},description:"Shared annotations, literal defaults and exact value/collection bounds; semantic validator required.",$comment:"Exact endpoint/key resolution, unique IDs/names, inverse collisions, multiplicity bounds and lifecycle coherence require portable semantic validation."};var iB=["title","aliases","examples","allowedValues","default"],sB=["collectionSize","range"];function on(e,t=""){throw new U("CORE_SCHEMA_PROPERTIES",e,t)}var em=(e)=>e;function Hp(e,t,n){if(e===null||typeof e!=="object"||Array.isArray(e))on("Expected object",n);for(let r of Object.keys(e))if(!t.includes(r))throw new U("CORE_SCHEMA_PROPERTY_UNKNOWN","Unknown relevant qualifier: "+r,n+"/"+r)}function du(e,t,n){let r=/^(-?)(0|[1-9][0-9]*)(?:\.([0-9]+))?(?:[eE]([+-]?[0-9]+))?$/.exec(e);if(!r||r[0]!==e)on("Expected exact JSON numeric token");let i=(r[2]+(r[3]??"")).replace(/^0+/,"");if(!i)return 0n;let s=r[4]??"0";if(s.length>32)on("Numeric exponent exceeds bounded domain");let o=BigInt(s)-BigInt((r[3]??"").length)+BigInt(t),a=i;if(o<0n){let l=-o;if(l>BigInt(i.length))on("Numeric value would require rounding");let c=i.length-Number(l);if(/[^0]/.test(i.slice(c)))on("Numeric value would require rounding");a=i.slice(0,c)}else{if(BigInt(i.length)+o>BigInt(Math.min(n??Zt.maxTextLength,Zt.maxTextLength)))on("Numeric value exceeds precision/resource limit");a+="0".repeat(Number(o))}if(n!==void 0&&a.length>n)on("Numeric value exceeds precision");return BigInt((r[1]??"")+(a||"0"))}function oB(e){let t=0;for(let n=0;n=55296&&r<=56319){let i=e.charCodeAt(++n);if(!(i>=56320&&i<=57343))on("Unpaired Unicode surrogate")}else if(r>=56320&&r<=57343)on("Unpaired Unicode surrogate")}return t}function ag(e,t){if(t===null)on("Null has no allowed-value equality");let n=em(t),r=Object.keys(n),i=e.scalarType,s={boolean:"boolean",integer:"integerToken",decimal:"decimalToken",string:"string",binary:"binaryHex"}[i];if(!s||r.length!==1||r[0]!==s)on("No exact equality for this literal/domain");let o=em(e.facets??{});if(i==="integer")return"integer:"+du(n[s],0);if(i==="decimal"){if(!Number.isSafeInteger(o.scale)||!Number.isSafeInteger(o.precision))on("Decimal requires explicit precision/scale");return"decimal:"+du(n[s],o.scale,o.precision)}if(i==="string")return oB(n.string),"string:"+JSON.stringify(n.string);if(i==="binary"){if(typeof n.binaryHex!=="string"||!/^(?:[0-9a-fA-F]{2})*$(?![\s\S])/.test(n.binaryHex))on("Expected hexadecimal bytes");return"binary:"+n.binaryHex.toLowerCase()}if(typeof n.boolean!=="boolean")on("Expected boolean literal");return"boolean:"+n.boolean}function tm(e,t,n,r=!0,i=0){if(i>Zt.maxDepth)on("Literal recursion exceeds limit");if(t.kind!=="field")on("Literal target must be a Field");if(t.references?.some((a)=>a.role==="record-type"))on("Record-valued literals require a separate contract");if(t.itemType)Hp(t.itemType,["module","element"],"/itemType");let s=em(t.facets??{});Hp(s,["length","precision","scale","integerWidth","range","collectionSize"],"/facets");for(let[a,l]of Object.entries({length:["min","max","unit"],integerWidth:["bits","signed"],range:["min","max","minInclusive","maxInclusive"],collectionSize:["min","max"]}))if(s[a])Hp(s[a],l,"/facets/"+a);if(n===null){if(t.nullability!=="absent-allowed")on("Null requires explicit absent-allowed");return}let o=em(n);if(!o||typeof o!=="object"||Array.isArray(o)||Object.keys(o).length!==1)on("Expected one typed literal wrapper");if(t.cardinality==="array"||t.cardinality==="map"){let a=t.cardinality,l=o[a];if(a==="array"?!Array.isArray(l):!l||typeof l!=="object"||Array.isArray(l))on("Container literal does not match Field");let c=em(t.itemType);if(!c)on("Container literal requires explicit itemType");let u=e.modules.find((f)=>f.id===c.module)?.elements.find((f)=>f.id===c.element);if(!u)on("Unresolved itemType");let p=a==="array"?l:Object.values(l),d=s.collectionSize;if(d){if(Hp(d,["min","max"],"/facets/collectionSize"),d.min!==void 0&&p.lengthd.max)on("Collection size outside bounds")}for(let f of p)tm(e,u,f,r,i+1)}else{if(t.cardinality!==void 0&&!["one","unspecified"].includes(t.cardinality))on("Unknown cardinality");let a=t.scalarType,l={boolean:"boolean",integer:"integerToken",decimal:"decimalToken",string:"string",binary:"binaryHex",float:"floatToken",date:"date",time:"time",timestamp:"timestamp"}[a];if(!l||!Object.hasOwn(o,l))on("Literal does not match scalar family");if(["float","date","time","timestamp"].includes(a)){if(r)on("Value/default semantics for float/temporal domain are not defined");if(typeof o[l]!=="string")on("Expected literal text");return}ag(t,n);let c;if(a==="string")c=oB(o.string);if(a==="binary")c=o.binaryHex.length/2;if(s.length){if(Hp(s.length,["min","max","unit"],"/facets/length"),s.length.unit!==(a==="string"?"unicode-scalar":"byte"))on("Unknown/incompatible length unit");if(c===void 0)on("Length requires string/binary");if(s.length.min!==void 0&&cs.length.max)on("Literal length outside bounds")}if(s.integerWidth){Hp(s.integerWidth,["bits","signed"],"/facets/integerWidth");let u=s.integerWidth,p=du(o.integerToken,0),d=p<0n?-p:p,f=d===0n?0:d.toString(2).length;if(!(u.signed?p<0n?f=0n&&f<=u.bits))on("Integer outside width/signedness")}if(r&&s.range){Hp(s.range,["min","max","minInclusive","maxInclusive"],"/facets/range");let u=s.range,p=a==="decimal"?s.scale:0,d=du(o[l],p,s.precision);for(let f of["min","max"])if(u[f]!==void 0){if(u[f]===null)on("Numeric bounds cannot be null","/facets/range/"+f);let m=du(em(u[f])[l],p,s.precision);if(f==="min"?dm||d===m&&u.maxInclusive===!1)on("Literal outside numeric range")}}}if(r&&t.allowedValues){if(!t.allowedValues.some((a)=>ag(t,a)===ag(t,n)))on("Literal is not an allowed value")}}var cB=mt(),aB=cB.compile(i0),bze=cB.compile({$defs:i0.$defs,$ref:"#/$defs/literal"});function pve(e){let t=Ae(e);t.umf="0.7.0";for(let n of[t,...t.modules])for(let r of["title","aliases"])delete n[r];for(let n of t.modules.flatMap((r)=>r.elements))for(let r of iB)delete n[r];for(let n of t.modules)for(let r of n.elements){let i=r.facets;if(!i)continue;for(let s of sB)delete i[s];if(i.length){if(delete i.length.min,i.length.max===void 0||i.length.max===0)delete i.length}if(["array","map"].includes(r.cardinality))delete r.facets}return t}function lB(e,t,n){let r=e.facets;if(e.scalarType==="decimal"){if(n==="min"?t>=0n:t<=0n)return!1;let o=(t<0n?-t:t).toString();return o.length===r.precision&&/^9+$/.test(o)}let i=r.integerWidth;if(!i)return!1;if(n==="min"){if(!i.signed)return t===0n;let o=-t;return t<0n&&o.toString(2).length===i.bits&&(o&o-1n)===0n}if(t<0n)return!1;return(t===0n?0:t.toString(2).length)===i.bits-(i.signed?1:0)&&(t&t+1n)===0n}function uB(e,t=new nt){let n=[],r=(a,l,c="error",u="CORE_SCHEMA_PROPERTIES")=>n.push({code:u,path:l,message:a,severity:c}),i;try{i=Ae(e)}catch(a){if(!(a instanceof U))throw a;return r(a.message,a.path),{valid:!1,complete:!1,diagnostics:n}}if(!aB(i)){for(let a of aB.errors??[])r(a.message??"Invalid schema properties",a.instancePath);return{valid:!1,complete:!1,diagnostics:n}}let s=new class extends nt{get(a,l){let c=t.get(a,l);if(!c?.semantics)return c;let u=c.semantics;return{...c,semantics:(p,d)=>u(p,{...d,document:Ae(i)})}}};n.push(...We(pve(i),s).diagnostics);let o=(a,l,c)=>{for(let u of Object.keys(a))if(!l.includes(u))r("Qualifier retained without interpretation",c+"/"+Pe(u),"warning","UNKNOWN_SCHEMA_PROPERTY")};return i.modules.forEach((a,l)=>a.elements.forEach((c,u)=>{let p=`/modules/${l}/elements/${u}`,d=c.facets,f=(m,y)=>{try{m()}catch(h){if(!(h instanceof U))throw h;r(h.message,y+(h.path||""),h.code==="CORE_SCHEMA_PROPERTY_UNKNOWN"?"warning":"error",h.code)}};if(d){if(["array","map"].includes(c.cardinality))o(d,["length","precision","scale","integerWidth","collectionSize","range"],p+"/facets");for(let m of["length","collectionSize"])if(d[m]){let y=d[m];o(y,m==="length"?["min","max","unit"]:["min","max"],p+"/facets/"+m);let h=p+"/facets/length/unit";if(m==="length"&&!["unicode-scalar","byte"].includes(y.unit)&&!n.some((b)=>b.code==="UNKNOWN_FACET_UNIT"&&b.path===h))r("Length unit retained without interpretation",h,"warning","UNKNOWN_FACET_UNIT");if(y.min!==void 0&&y.max!==void 0&&y.min>y.max)r("Minimum exceeds maximum",p+"/facets/"+m);if(m==="collectionSize"&&(c.kind!=="field"||!["array","map"].includes(c.cardinality)))r("Collection bounds require array/map Field",p+"/facets/"+m)}if(d.range){let m=d.range;if(o(m,["min","max","minInclusive","maxInclusive"],p+"/facets/range"),c.kind!=="field"||!["integer","decimal"].includes(c.scalarType))r("Range requires integer/decimal Field",p+"/facets/range");else f(()=>{let y={};for(let D of["precision","scale"])if(Object.hasOwn(d,D))y[D]=d[D];if(d.integerWidth)y.integerWidth={bits:d.integerWidth.bits,signed:d.integerWidth.signed};let h={...c,facets:y};delete h.allowedValues,delete h.default;for(let D of["min","max"])if(m[D]!==void 0){if(m[D]===null)throw new U("CORE_SCHEMA_PROPERTIES","Numeric bounds cannot be null","/"+D);tm(i,h,m[D])}else if(m[D+"Inclusive"]!==void 0)r("Inclusive flag requires its bound",p+"/facets/range/"+D+"Inclusive");let b=c.scalarType==="integer"?"integerToken":"decimalToken",g=c.scalarType==="integer"?0:d.scale,x=m.min===void 0?void 0:du(m.min[b],g,d.precision),v=m.max===void 0?void 0:du(m.max[b],g,d.precision);if(x!==void 0&&v!==void 0&&x+(m.minInclusive===!1?1n:0n)>v-(m.maxInclusive===!1?1n:0n)||x!==void 0&&m.minInclusive===!1&&lB(c,x,"max")||v!==void 0&&m.maxInclusive===!1&&lB(c,v,"min"))r("Empty or inverted numeric interval",p+"/facets/range")},p+"/facets/range")}}if(c.allowedValues)f(()=>{let m=new Set;for(let[y,h]of c.allowedValues.entries()){let b={...c};delete b.allowedValues,tm(i,b,h);let g=ag(b,h);if(m.has(g))r("Duplicate equal allowed value",p+"/allowedValues/"+y);m.add(g)}},p+"/allowedValues");if(c.examples)for(let[m,y]of c.examples.entries())f(()=>tm(i,c,y,!1),p+"/examples/"+m);if(c.default){let m=c.default;o(m,["value","on"],p+"/default"),f(()=>tm(i,c,m.value),p+"/default/value")}})),{valid:!n.some((a)=>a.severity==="error"),complete:n.length===0,diagnostics:n}}var pB=mt().compile(n0),s0=(e)=>JSON.stringify([e.module,e.element]);function o0(e,t=!0){let n=[],r=(c,u,p,d="error")=>n.push({code:c,path:u,message:p,severity:d}),i;try{i=Ae(e)}catch(c){if(!(c instanceof U))throw c;return r(c.code,c.path,c.message),{valid:!1,complete:!1,diagnostics:n}}if(!pB(i)){for(let c of pB.errors??[])r("KEY_STRUCTURE",c.instancePath,c.message??"Invalid key envelope");return{valid:!1,complete:!1,diagnostics:n}}let s=Ae(i);s.umf="0.5.0";for(let c of s.modules)for(let u of c.elements)delete u.members,delete u.keys;if(t)n.push(...We(s).diagnostics);let o=(c,u,p)=>{for(let d of Object.keys(c))if(!u.includes(d))r("UNKNOWN_KEY_QUALIFIER",p+"/"+Pe(d),"Qualifier retained without interpretation","warning")},a=new Map,l=new Map;for(let c of i.modules)for(let u of c.elements)a.set(s0({module:c.id,element:u.id}),u);return i.modules.forEach((c,u)=>c.elements.forEach((p,d)=>{let f=`/modules/${u}/elements/${d}`,m=p.members;if(!m)return;let y=new Set;m.forEach((v,D)=>{let T=f+`/members/${D}`,N=s0(v),O=a.get(N);if(o(v,["module","element"],T),y.has(N))r("KEY_DUPLICATE_MEMBER",T,"Record membership repeats a Field identity");if(y.add(N),!O)r("KEY_MEMBER_MISSING",T,"Member Field does not exist");else if(O.kind!=="field")r("KEY_MEMBER_KIND",T,"Record members must be explicit Fields");let C=l.get(N);if(C&&C!==f)r("KEY_MEMBER_OWNER",T,"Field already belongs to another Record: "+C);else l.set(N,f)});let h=new Set,b=new Set,g=new Set,x=0;p.keys?.forEach((v,D)=>{let T=f+`/keys/${D}`;if(o(v,["id","name","fields","primary"],T),h.has(v.id))r("KEY_DUPLICATE_ID",T+"/id","Key ID is not unique within the Record");if(h.add(v.id),b.has(v.name))r("KEY_DUPLICATE_NAME",T+"/name","Key name is not unique within the Record");if(b.add(v.name),v.primary===!0&&++x>1)r("KEY_PRIMARY_COUNT",T+"/primary","At most one key may be primary");let N=v.fields.map(s0),O=JSON.stringify([...N].sort());if(new Set(N).size!==N.length)r("KEY_DUPLICATE_FIELD",T+"/fields","Key repeats a Field identity");if(g.has(O))r("KEY_DUPLICATE_SET",T+"/fields","Key component set duplicates another key, regardless of order");g.add(O),v.fields.forEach((C,X)=>{let te=T+`/fields/${X}`,L=s0(C),Y=a.get(L);if(o(C,["module","element"],te),!y.has(L))r("KEY_FIELD_OWNER",te,"Key component is not a member of its owning Record");if(!Y){r("KEY_FIELD_MISSING",te,"Key Field does not exist");return}if(Y.kind!=="field")r("KEY_FIELD_KIND",te,"Key component must be an explicit Field");if(Y.nullability!=="required")r("KEY_FIELD_REQUIRED",te,"Key component must explicitly supply a value");if(Y.cardinality!=="one")r("KEY_FIELD_SINGULAR",te,"Key component must explicitly be singular");if(!["boolean","integer","decimal","string","binary"].includes(Y.scalarType??"")||Y.references?.some((me)=>me.role==="record-type"))r("KEY_EQUALITY",te,"Key equality is undefined for this component");if(Y.scalarType==="decimal"){let me=Y.facets;if(!me||me.precision===void 0||me.scale===void 0)r("KEY_DECIMAL_DOMAIN",te,"Decimal key equality requires explicit precision and scale")}})})})),{valid:!n.some((c)=>c.severity==="error"),complete:n.length===0,diagnostics:n}}var dB=mt().compile(t0),L1=(e)=>JSON.stringify([e.module,e.element]);function fB(e,t=!0){let n=[],r=(p,d,f,m="error")=>n.push({code:p,path:d,message:f,severity:m}),i;try{i=Ae(e)}catch(p){if(!(p instanceof U))throw p;return r(p.code,p.path,p.message),{valid:!1,complete:!1,diagnostics:n}}if(!dB(i)){for(let p of dB.errors??[])r("RELATIONSHIP_STRUCTURE",p.instancePath,p.message??"Invalid relationship envelope");return{valid:!1,complete:!1,diagnostics:n}}let s=Ae(i);s.umf="0.6.0";for(let p of s.modules)delete p.relationships;n.push(...o0(s,t).diagnostics);let o=(p,d,f)=>{for(let m of Object.keys(p))if(!d.includes(m))r("UNKNOWN_RELATIONSHIP_QUALIFIER",f+"/"+Pe(m),"Qualifier retained without interpretation","warning")},a=new Map;for(let p of i.modules)for(let d of p.elements)a.set(L1({module:p.id,element:d.id}),d);let l=new Map,c=(p,d,f,m)=>{let y=JSON.stringify([p.module,p.element,d]),h=l.get(y)??[],b=h.find((g)=>m||g.inverse);if(b)r("RELATIONSHIP_PRESENTATION_COLLISION",f,"Inverse presentation collides on this endpoint with "+b.path);h.push({path:f,inverse:m}),l.set(y,h)},u=(p,d)=>{let f=a.get(L1(p));if(!f){r("RELATIONSHIP_ENDPOINT_MISSING",d,"Endpoint does not resolve by exact module and element IDs");return}if(f.kind!=="record"){r("RELATIONSHIP_ENDPOINT_KIND",d,"Endpoint must be a Record");return}if(!Array.isArray(f.keys)||!f.keys.length)r("RELATIONSHIP_ENDPOINT_KEY",d,"Endpoint must have authored Keys");return f};return i.modules.forEach((p,d)=>{let f=new Set,m=new Set;(p.relationships??[]).forEach((y,h)=>{let b=`/modules/${d}/relationships/${h}`;if(o(y,["id","name","source","target","sourceMultiplicity","targetMultiplicity","targetLifecycle","directed","inverse","associationRecord"],b),f.has(y.id))r("RELATIONSHIP_DUPLICATE_ID",b+"/id","Relationship ID must be unique in its module");if(f.add(y.id),m.has(y.name))r("RELATIONSHIP_DUPLICATE_NAME",b+"/name","Relationship name must be unique in its module");m.add(y.name);for(let g of["source","target"]){let x=new Set;y[g].forEach((D,T)=>{let N=b+`/${g}/${T}`;o(D,g==="target"?["module","element","key"]:["module","element"],N);let O=L1(D);if(x.has(O))r("RELATIONSHIP_DUPLICATE_ENDPOINT",N,"Endpoint Record repeats, regardless of qualifiers or target key");x.add(O);let C=u(D,N);if(g==="target"&&C&&!(C.keys??[]).some((X)=>X.id===D.key))r("RELATIONSHIP_TARGET_KEY",N+"/key","Target key must resolve by its stable ID");if(g==="source")c(D,y.name,N,!1);else if(y.inverse)c(D,y.inverse,b+"/inverse",!0)});let v=y[g+"Multiplicity"];if(o(v,["min","max"],b+"/"+g+"Multiplicity"),v.max!=="*"&&v.maxp.severity==="error"),complete:n.length===0,diagnostics:n}}var mB=mt().compile({$defs:r0.$defs,$ref:"#/$defs/element"});function yB(e,t=""){let n=[],r=(s,o,a,l="error")=>n.push({code:s,path:t+o,message:a,severity:l}),i;try{i=Ae(e)}catch(s){if(!(s instanceof U))throw s;return r(s.code,s.path,s.message),{valid:!1,complete:!1,diagnostics:n}}if(!mB(i)){for(let s of mB.errors??[])r("FACET_STRUCTURE",s.instancePath,s.message??"Invalid facet element");return{valid:!1,complete:!1,diagnostics:n}}if(Object.hasOwn(i,"facets")){let s=i.facets,o=(a,l,c)=>{for(let u of Object.keys(a))if(!l.includes(u))r("UNKNOWN_FACET",c+"/"+Pe(u),"Facet member retained without interpretation","warning")};if(o(s,["length","precision","scale","integerWidth"],"/facets"),Object.hasOwn(s,"precision")&&s.scale>s.precision)r("FACET_SCALE","/facets/scale","Scale must not exceed precision");if(Object.hasOwn(s,"length")){let a=s.length;if(o(a,["max","unit"],"/facets/length"),a.unit!=="unicode-scalar"&&a.unit!=="byte")r("UNKNOWN_FACET_UNIT","/facets/length/unit","Length unit retained without interpretation","warning")}if(Object.hasOwn(s,"integerWidth"))o(s.integerWidth,["bits","signed"],"/facets/integerWidth")}return{valid:!n.some((s)=>s.severity==="error"),complete:n.length===0,diagnostics:n}}function We(e,t=new nt){let n=[],r=(b,g,x,v="error")=>n.push({code:b,path:g,message:x,severity:v}),i;try{i=Ae(e)}catch(b){if(!(b instanceof U))throw b;return r(b.code,b.path,b.message),{valid:!1,complete:!1,diagnostics:n}}let s=i?.umf;if(s==="0.8.0")return uB(i,t);let o=s==="0.7.0"?Y3:s==="0.6.0"?Q3:s==="0.5.0"?W3:s==="0.4.0"?z3:s==="0.3.0"?H3:s==="0.2.0"?G3:J3;if(!o(i)){for(let b of o.errors||[])r("STRUCTURE",b.instancePath,b.message||"Invalid structure");return{valid:!1,complete:!1,diagnostics:n}}let a=i,l=a.umf==="0.7.0",c=a.umf==="0.6.0"||l,u=a.umf==="0.5.0"||c,p=a.umf==="0.4.0"||u,d=a.umf==="0.3.0"||p,f=(b,g,x)=>{for(let v of Object.keys(b))if(!g.includes(v))r("UNKNOWN_CORE_FIELD",`${x}/${Pe(v)}`,"Field retained without interpretation","warning")};f(a,["umf","id","vocabularies","modules","extensions"],"");for(let[b,g]of Object.entries(a.vocabularies))if(f(g,["version"],`/vocabularies/${Pe(b)}`),!t.get(b,g.version))r("UNKNOWN_EXTENSION",`/vocabularies/${Pe(b)}`,"Exact extension version unavailable; content retained","warning");let m=(b,g,x)=>{for(let[v,D]of Object.entries(b||{})){let T=`${x}/extensions/${Pe(v)}`;if(!Object.hasOwn(a.vocabularies,v)){r("UNDECLARED_EXTENSION",T,"Extension has no version declaration");continue}let N=a.vocabularies[v],O=t.get(v,N.version);if(!O)continue;if(!O.manifest.scopes.includes(g)){r("EXTENSION_SCOPE",T,"Extension not permitted at this scope");continue}if(!O.structure(D)){for(let C of O.structure.errors||[])r("EXTENSION_STRUCTURE",T+C.instancePath,C.message||"Invalid payload");continue}if(O.manifest.capabilities.validation!=="semantic"||!O.semantics)r("SEMANTICS_UNCHECKED",T,"Structure checked; semantics not validated","warning");else try{n.push(...O.semantics(Ae(D),{document:Ae(a),path:T,scope:g}))}catch(C){r("VALIDATOR_FAILURE",T,String(C))}}};m(a.extensions,"document","");let y=new Map,h=new Map;if(a.modules.forEach((b,g)=>{let x=`/modules/${g}`;if(f(b,["id","namespace","elements","extensions",...l?["relationships"]:[]],x),y.has(b.id))r("DUPLICATE_MODULE",x+"/id","Module id is not unique");let v=new Set;y.set(b.id,v),h.set(b.id,new Map(b.elements.map((D)=>[D.id,D]))),m(b.extensions,"module",x),b.elements.forEach((D,T)=>{let N=`${x}/elements/${T}`;if(f(D,["id","name","description","scalarType","extensions","references",...a.umf!=="0.1.0"?["kind"]:[],...d?["nullability"]:[],...p?["cardinality","itemType"]:[],...u?["facets"]:[],...c?["keys","members"]:[]],N),a.umf!=="0.1.0"&&D.kind!==void 0&&!Z3.includes(D.kind))r("UNKNOWN_ELEMENT_KIND",N+"/kind","Kind retained without interpretation","warning");if(d&&D.nullability!==void 0&&!eB.includes(D.nullability))r("UNKNOWN_NULLABILITY",N+"/nullability","Availability label retained without interpretation","warning");if(p&&D.cardinality!==void 0&&!tB.includes(D.cardinality))r("UNKNOWN_CARDINALITY",N+"/cardinality","Container label retained without interpretation","warning");if(p&&D.itemType)f(D.itemType,["module","element"],N+"/itemType");if(u&&Object.hasOwn(D,"facets"))n.push(...yB(D,N).diagnostics);if(D.scalarType!==void 0&&!X3.includes(D.scalarType))r("UNKNOWN_SCALAR_TYPE",N+"/scalarType","Scalar family retained without interpretation","warning");if(v.has(D.id))r("DUPLICATE_ELEMENT",N+"/id","Element id is not unique within module");v.add(D.id),m(D.extensions,"element",N),D.references?.forEach((O,C)=>f(O,["role","module","element"],`${N}/references/${C}`))})}),a.modules.forEach((b,g)=>b.elements.forEach((x,v)=>x.references?.forEach((D,T)=>{if(!y.get(D.module)?.has(D.element))r("UNRESOLVED_REFERENCE",`/modules/${g}/elements/${v}/references/${T}`,"Target element does not exist in supplied document")}))),p)a.modules.forEach((b,g)=>b.elements.forEach((x,v)=>{if(!Object.hasOwn(x,"itemType"))return;let D=x.itemType,T=h.get(D.module)?.get(D.element),N=`/modules/${g}/elements/${v}/itemType`;if(!T)r("UNRESOLVED_ITEM_TYPE",N,"Item/value Field does not exist in supplied document");else if(T.kind!=="field")r("ITEM_TYPE_ROLE",N,"Item/value definition must be an explicit Field")}));if(l)n.push(...fB(a,!1).diagnostics);else if(c)n.push(...o0(a,!1).diagnostics);return{valid:!n.some((b)=>b.severity==="error"),complete:n.length===0,diagnostics:n}}function hB(e,t="yaml"){let n=ms(e,t),r=We(n);if(!r.valid)throw new U("INVALID_DOCUMENT",JSON.stringify(r.diagnostics));return n}bo();function Jt(e){if(e.length>Zt.maxTextLength)throw new U("LIMIT","Native JSON exceeds text limit");try{JSON.parse(e)}catch{throw new U("JSON_SCHEMA_SYNTAX","Invalid native JSON")}let t=go(e,{version:"1.2",schema:"core",intAsBigInt:!0,uniqueKeys:!0,strict:!0});if(t.errors.length||t.warnings.length)throw new U("JSON_SCHEMA_SYNTAX",[...t.errors,...t.warnings].map((i)=>i.message).join("; "));let n=0;function r(i,s){if(s>Zt.maxDepth||++n>Zt.maxValues)throw new U("LIMIT","Native JSON structural limit exceeded");if(ft(i)){if(i.value===null)return{kind:"null"};if(typeof i.value==="number"||typeof i.value==="bigint")return{kind:"number",value:i.source};if(typeof i.value==="string")return{kind:"string",value:i.value};if(typeof i.value==="boolean")return{kind:"boolean",value:i.value}}if(Gr(i))return{kind:"array",items:i.items.map((o)=>r(o,s+1))};if(dr(i)){let o=Object.create(null);for(let a of i.items){if(!ft(a.key)||typeof a.key.value!=="string")throw new U("JSON_SCHEMA_SYNTAX","Non-string JSON key");o[a.key.value]=r(a.value,s+1)}return{kind:"object",members:o}}throw new U("JSON_SCHEMA_SYNTAX","Unexpected native JSON node")}return r(t.contents,0)}function Be(e){switch(e.kind){case"null":return"null";case"number":return e.value;case"boolean":case"string":return JSON.stringify(e.value);case"array":return"["+e.items.map(Be).join(",")+"]";case"object":return"{"+Object.entries(e.members).map(([t,n])=>JSON.stringify(t)+":"+Be(n)).join(",")+"}"}}function wr(e){if(e==="")return[];if(!e.startsWith("/")||/~(?![01])/u.test(e))throw new U("JSON_SCHEMA_POINTER","Invalid JSON Pointer");return e.slice(1).split("/").map((t)=>t.replace(/~1/g,"/").replace(/~0/g,"~"))}function Dr(e,t){if(e.kind==="object"&&Object.hasOwn(e.members,t))return e.members[t];if(e.kind==="array"&&/^(0|[1-9][0-9]*)$/.test(t)&&Number(t)Zt.maxTextLength)throw new U("LIMIT","Native YAML exceeds text limit");let r=go(e,{version:n,schema:n==="1.1"?"yaml-1.1":"core",intAsBigInt:!0,uniqueKeys:!0,strict:!0,...t.booleanLexicon==="pyyaml"?{customTags:(o)=>o.map((a)=>a.tag==="tag:yaml.org,2002:bool"?{...a,test:new RegExp("^(?![yYnN]$)"+a.test.source,a.test.flags)}:a)}:{}});if(r.errors.length||r.warnings.length)throw new U("NATIVE_YAML_SYNTAX",[...r.errors,...r.warnings].map((o)=>o.message).join("; "));let i=0;function s(o,a){if(a>Zt.maxDepth||++i>Zt.maxValues)throw new U("LIMIT","Native YAML structural limit exceeded");if(o?.tag)throw new U("NATIVE_YAML_TAG","Explicit YAML tags are outside the JSON-compatible profile");if(ft(o)){if(o.value===null)return{kind:"null"};if(typeof o.value==="string")return{kind:"string",value:o.value};if(typeof o.value==="boolean")return{kind:"boolean",value:o.value};if(o.value instanceof Date&&t.dateOnly==="string"&&/^\d{4}-\d{2}-\d{2}$/.test(o.source??""))return{kind:"string",value:o.source};if(typeof o.value==="bigint")return{kind:"number",value:o.source==="-0"?"-0":o.value.toString()};if(typeof o.value==="number"){let l=n==="1.1"?o.source.replaceAll("_",""):o.source;if(l=l.replace(/^\+/,"").replace(/^(-?)\./,"$10.").replace(/\.(?=e|$)/i,".0").replace(/^(-?)0+(?=[0-9])/,"$1"),!/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$/.test(l))throw new U("NATIVE_YAML_NUMBER","Unsupported exact numeric spelling");return{kind:"number",value:l}}}if(Gr(o))return{kind:"array",items:o.items.map((l)=>s(l,a+1))};if(dr(o)){let l=Object.create(null);for(let c of o.items){if(!ft(c.key)||typeof c.key.value!=="string"||c.key.tag)throw new U("NATIVE_YAML_KEY","JSON-compatible YAML requires untagged string keys");l[c.key.value]=s(c.value,a+1)}return{kind:"object",members:l}}if(o===null)return{kind:"null"};throw new U("NATIVE_YAML_NODE","Aliases and non-JSON YAML nodes are unsupported")}return s(r.contents,0)}var dve="https://json-schema.org/draft/2020-12/schema",gB="umf.json-schema",fve=M3,bB=mt().compile(C3),wB=new Set(["items","additionalProperties","contains","not","if","then","else","unevaluatedItems","unevaluatedProperties","propertyNames","contentSchema"]),DB=new Set(["properties","patternProperties","$defs","dependentSchemas","definitions"]),TB=new Set(["allOf","anyOf","oneOf","prefixItems"]),mve=new Set(["$id","$schema","$ref","$anchor","$dynamicRef","$dynamicAnchor","$vocabulary","$comment","$defs","definitions","type","enum","const","multipleOf","maximum","exclusiveMaximum","minimum","exclusiveMinimum","maxLength","minLength","pattern","maxItems","minItems","uniqueItems","maxContains","minContains","maxProperties","minProperties","required","dependentRequired","title","description","default","deprecated","readOnly","writeOnly","examples","format","contentEncoding","contentMediaType",...wB,...DB,...TB]),yve=new Set(["core","applicator","unevaluated","validation","meta-data","format-annotation","content"].map((e)=>"https://json-schema.org/draft/2020-12/vocab/"+e));function a0(e,t=""){let n=[{pointer:t,node:e}];if(e.kind!=="object")return n;for(let[r,i]of Object.entries(e.members)){let s=t+"/"+Pe(r);if(wB.has(r))n.push(...a0(i,s));if(DB.has(r)&&i.kind==="object")for(let[o,a]of Object.entries(i.members))n.push(...a0(a,s+"/"+Pe(o)));if(TB.has(r)&&i.kind==="array")i.items.forEach((o,a)=>n.push(...a0(o,s+"/"+a)))}return n}function vB(e){try{if(new URL(e).hash||e.includes("#"))throw Error()}catch{throw new U("JSON_SCHEMA_URI","Retrieval URI must be absolute and fragment-free")}}function hve(e){let t=[];for(let r of Object.keys(e))if(!["dialect","baseUri","root","resources"].includes(r))t.push("/"+Pe(r));function n(r,i){let s=r.kind==="null"?["kind"]:r.kind==="object"?["kind","members"]:r.kind==="array"?["kind","items"]:["kind","value"];for(let o of Object.keys(r))if(!s.includes(o))t.push(i+"/"+Pe(o));if(r.kind==="object")for(let[o,a]of Object.entries(r.members))n(a,i+"/members/"+Pe(o));if(r.kind==="array")r.items.forEach((o,a)=>n(o,i+"/items/"+a))}n(e.root,"/root");for(let[r,i]of Object.entries(e.resources))n(i,"/resources/"+Pe(r));return t}function SB(e,t){let n=[],r=(l,c,u,p="warning")=>n.push({code:l,path:t+c,message:u,severity:p});try{vB(e.baseUri);for(let l of Object.keys(e.resources))vB(l)}catch(l){return r("JSON_SCHEMA_URI","",String(l),"error"),n}for(let l of hve(e))r("JSON_SCHEMA_REPRESENTATION",l,"Unknown representation field cannot be emitted natively");let i=!1,s=!1;for(let[l,c]of[[e.baseUri,e.root],...Object.entries(e.resources)]){if(c.kind!=="object"&&c.kind!=="boolean"){r("JSON_SCHEMA_ROOT","",`Resource ${l} must be object or boolean`,"error");continue}for(let u of a0(c)){if(u.node.kind!=="object")continue;for(let[p,d]of Object.entries(u.node.members)){if(!mve.has(p))i=!0,r("JSON_SCHEMA_KEYWORD",u.pointer+"/"+Pe(p),`Uninterpreted keyword in ${l}`);if(["$dynamicRef","unevaluatedItems","unevaluatedProperties"].includes(p))r("JSON_SCHEMA_VALIDATOR_LIMIT",u.pointer+"/"+Pe(p),"Pinned JavaScript oracle has known failures for this construct; native meaning retained, full semantic evaluation not certified");if(p==="properties"&&d.kind==="object"&&Object.hasOwn(d.members,"__proto__"))r("JSON_SCHEMA_VALIDATOR_LIMIT",u.pointer+"/properties/__proto__","Pinned JavaScript oracle does not reliably assert this property");if(p==="$schema"&&d.kind==="string"&&d.value!==dve)i=!0,s=!0,r("JSON_SCHEMA_DIALECT",u.pointer,`Uninterpreted dialect ${d.value}`);if(p==="$vocabulary"&&d.kind==="object"){for(let f of Object.keys(d.members))if(!yve.has(f))i=!0,r("JSON_SCHEMA_VOCABULARY",u.pointer,`Uninterpreted vocabulary ${f}`)}}}}if(n.some((l)=>l.severity==="error"))return n;let o=new Map;for(let[l,c]of[[e.baseUri,e.root],...Object.entries(e.resources)])try{o.set(l,ms(Be(c),"json"))}catch(u){r("JSON_SCHEMA_NUMERIC","",`Resource ${l}: native values retained but JavaScript validation unavailable: ${String(u)}`)}if(o.size!==Object.keys(e.resources).length+1){if(Object.hasOwn(e.resources,e.baseUri))r("JSON_SCHEMA_RESOURCE_COLLISION","","Root retrieval URI also appears in resources","error");return n}if(s)return n;let a=new xB.default({strict:!1,allErrors:!0,validateFormats:!1,ownProperties:!0,addUsedSchema:!1});try{for(let[c,u]of o)if(!a.validateSchema(u))r("JSON_SCHEMA_META","",`Resource ${c}: ${JSON.stringify(a.errors)}`,"error");if(n.some((c)=>c.severity==="error")||i)return n;for(let[c,u]of o)a.addSchema(u,c);if(!a.getSchema(e.baseUri))throw Error("Root resource not compiled")}catch(l){r("JSON_SCHEMA_COMPILE","",`Native compiler could not establish validity: ${String(l)}`)}return n}function gve(){return new nt().register(fve,(e,t)=>SB(e,t.path))}function bve(e){let t=We(e);if(!t.valid)throw new U("INVALID_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((i)=>i.id==="schema")?.elements.find((i)=>i.id==="schema"),r=Ae(n?.extensions[gB]);if(!bB(r))throw new U("JSON_SCHEMA_PAYLOAD",JSON.stringify(bB.errors));if(e.vocabularies[gB]?.version!=="0.1.0")throw new U("JSON_SCHEMA_VERSION","Unsupported native extension version");return r}function vve(e){return We(e,gve())}function EB(e){let t=bve(e),n=SB(t,"");if(n.some((r)=>r.severity==="error"||r.code==="JSON_SCHEMA_REPRESENTATION"))throw new U("JSON_SCHEMA_EXPORT",JSON.stringify(n));return t}function q1(e){let t=Be(e)+` -`;if(t.length>Zt.maxTextLength)throw new U("LIMIT","Native output exceeds text limit");return t}function kB(e){return q1(EB(e).root)}function NB(e){let t=EB(e),n=Object.create(null);for(let[r,i]of Object.entries(t.resources))n[r]=q1(i);return{schema:q1(t.root),resources:n,source:Ae(e),diagnostics:[...vve(e).diagnostics,{code:"SOURCE_ARTIFACT_REQUIRED",path:"",severity:"warning",message:"Standalone native root does not carry UMF metadata or supplied resource files; retain this bundle for full source recovery."}]}}var E8=Ar(w8(),1);var Wl=(e)=>e?.kind==="string"?e.value:void 0,_N=(e)=>{if(e?.kind!=="number")return;try{let t=ms(e.value,"json");return typeof t==="number"&&Number.isSafeInteger(t)?t:void 0}catch{return}},D8={boolean:"boolean",int:"integer",long:"integer",float:"float",double:"float",bytes:"binary",string:"string",fixed:"binary",enum:"string"};function T8(e){let t=new Map,n=[];function r(s,o,a,l){if(s.kind==="array"){s.items.forEach((f,m)=>r(f,o+"/"+m,a,l));return}if(s.kind!=="object")return;let c=s.members,u=Wl(c.type),p="",d=a;if(u&&["record","error","enum","fixed"].includes(u)){let f=Wl(c.name);if(!f)return;let m=Wl(c.namespace)??a;p=f.includes(".")?f:m?m+"."+f:f,d=p.includes(".")?p.slice(0,p.lastIndexOf(".")):"",t.set(p,t.has(p)?null:{node:s,namespace:d})}if((u==="record"||u==="error")&&c.fields?.kind==="array")c.fields.items.forEach((f,m)=>{if(f.kind!=="object"||!Wl(f.members.name)||!f.members.type)return;let y=o+"/fields/"+m;n.push({node:f,path:y,record:p,namespace:d,...l!==void 0?{dependencyId:l}:{}}),r(f.members.type,y+"/type",d,l)});if(u==="array"&&c.items)r(c.items,o+"/items",d,l);if(u==="map"&&c.values)r(c.values,o+"/values",d,l);if(c.type&&c.type.kind!=="string")r(c.type,o+"/type",d,l)}for(let s of e.dependencies??[])r(s.root,"","",s.id);r(e.root,"","");function i(s,o,a=new Set){if(s.kind==="array"){let d=s.items.filter((f)=>!(f.kind==="string"&&f.value==="null")&&!(f.kind==="object"&&Wl(f.members.type)==="null")).map((f)=>i(f,o,new Set(a)));return d.length&&d[0]&&d.every((f)=>f===d[0])?d[0]:void 0}let l=s.kind==="string"?s.value:s.kind==="object"?Wl(s.members.type):void 0;if(!l)return;if(s.kind==="object"&&Object.hasOwn(s.members,"logicalType")){let p=s.members,d=Wl(p.logicalType);if(d==="date"&&l==="int")return"date";if(d==="time-millis"&&l==="int"||d==="time-micros"&&l==="long")return"time";if(d&&/^(local-)?timestamp-(millis|micros|nanos)(?![\s\S])/.test(d)&&l==="long")return"timestamp";if(d==="big-decimal"&&l==="bytes")return"decimal";if(d==="decimal"&&(l==="bytes"||l==="fixed")){let f=_N(p.precision),m=p.scale===void 0?0:_N(p.scale);if(f===void 0||f<=0||m===void 0||m<0||m>f)return;if(l==="fixed"){let y=_N(p.size);if(y===void 0||y<1||y>4096)return;let h=((1n<h)return}return"decimal"}return}if(Object.hasOwn(D8,l))return D8[l];let c=l.includes(".")?l:o?o+"."+l:l;if(a.has(c))return;a.add(c);let u=t.get(c);return u?i(u.node,u.namespace,a):void 0}return n.map((s)=>{let o=Ae(s.node),a=s.node.members,l=i(a.type,s.namespace),c=Wl(a.doc);return{path:s.path,record:s.record,...s.dependencyId!==void 0?{dependencyId:s.dependencyId}:{},nativeField:o,element:{id:JSON.stringify([s.dependencyId??null,s.path]),name:Wl(a.name),...c!==void 0?{description:c}:{},...l?{scalarType:l}:{},extensions:{}}}})}var xN={id:"umf.avro",version:"0.1.0",coreVersion:"0.1.0",description:"Avro JSON schema preservation and typed tree access",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:avro:0.1.0",title:"UMF Avro native schema tree",type:"object",required:["version","root"],properties:{version:{const:"1.12.0"},root:{$ref:"#/$defs/node"},dependencies:{type:"array",items:{type:"object",required:["id","root"],properties:{id:{type:"string",minLength:1},root:{$ref:"#/$defs/node"}}}}},$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-007. Native JSON tokens preserve exact numbers, order, defaults, aliases, logical types and unknown metadata. Pinned JavaScript validator limitations remain explicit; no parsing-canonical-form reduction is used for retention.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Apache Avro JSON schema",version:"1.12.0; avsc 5.7.9 validation profile",subset:"JSON schema artifacts with explicit ordered named-schema dependencies; native IDL, protocols, RPC and container formats remain separate work. Logical types and host-unsafe numbers are preserved without complete browser interpretation."},evidence:["tests/avro/native.test.ts","tests/avro/corpus.test.ts","fixtures/avro/corpus-oracle-results.json","tests/avro/bundle.test.ts","fixtures/avro/dependency-oracle-results.json","tests/avro/native-schema.test.ts","fixtures/avro/native-schema-oracle.json","fixtures/avro/native-schema-browser.json"]}};var S8="umf.avro",nxe=xN,rxe=mt().compile(xN.schema);function wN(e,t,n){let r=e.kind==="object"?["kind","members"]:e.kind==="array"?["kind","items"]:e.kind==="null"?["kind"]:["kind","value"];for(let i of Object.keys(e))if(!r.includes(i))n.push({code:"AVRO_REPRESENTATION",path:t+"/"+Pe(i),severity:"warning",message:"Unknown representation field has no native destination"});if(e.kind==="object")for(let[i,s]of Object.entries(e.members))wN(s,t+"/members/"+Pe(i),n);if(e.kind==="array")e.items.forEach((i,s)=>wN(i,t+"/items/"+s,n))}function ixe(e){let t=e,n=[],r=(l,c,u)=>n.push({code:l,path:c,message:u,severity:"warning"});for(let l of Object.keys(t))if(!["version","root","dependencies"].includes(l))r("AVRO_REPRESENTATION","/"+Pe(l),"Unknown payload field has no native destination");let i=[...(t.dependencies??[]).map((l,c)=>({node:l.root,path:"/dependencies/"+c+"/root"})),{node:t.root,path:"/root"}],s=new Set;(t.dependencies??[]).forEach((l,c)=>{if(s.has(l.id))n.push({code:"AVRO_DEPENDENCY_ID",path:"/dependencies/"+c+"/id",severity:"error",message:"Dependency IDs must be unique"});s.add(l.id);for(let u of Object.keys(l))if(!["id","root"].includes(u))r("AVRO_REPRESENTATION","/dependencies/"+c+"/"+Pe(u),"Unknown dependency representation field has no native destination")});for(let{node:l,path:c}of i)wN(l,c,n);if(!["string","object","array"].includes(t.root.kind))return[...n,{code:"AVRO_ROOT",path:"/root",severity:"error",message:"Avro schemas must be strings, objects or union arrays"}];function o(l,c){if(l.kind==="array"){l.items.forEach((f,m)=>o(f,c+"/"+m));return}if(l.kind!=="object")return;let u=l.members,p=u.type?.kind==="string"?u.type.value:void 0,d=["type","name","namespace","aliases","doc","logicalType",...p==="record"||p==="error"?["fields"]:p==="enum"?["symbols","default"]:p==="fixed"?["size","precision","scale"]:p==="array"?["items"]:p==="map"?["values"]:["precision","scale"]];for(let f of Object.keys(u))if(!d.includes(f))r("AVRO_METADATA",c+"/"+Pe(f),"Uninterpreted native metadata retained");if(u.logicalType)r("AVRO_LOGICAL_TYPE",c+"/logicalType","Logical type retained; this browser profile validates its underlying carrier only");if(u.fields?.kind==="array")u.fields.items.forEach((f,m)=>{if(f.kind!=="object")return;let y=f.members;for(let h of Object.keys(y))if(!["name","type","default","order","aliases","doc"].includes(h))r("AVRO_METADATA",c+"/fields/"+m+"/"+Pe(h),"Uninterpreted field metadata retained");if(y.type)o(y.type,c+"/fields/"+m+"/type")});for(let f of["items","values"])if(u[f])o(u[f],c+"/"+f);if(u.type&&u.type.kind!=="string")o(u.type,c+"/type")}let a=Object.create(null);for(let{node:l,path:c}of i){o(l,c);let u;try{u=ms(Be(l),"json")}catch(p){r("AVRO_NUMERIC",c,"Exact native tokens retained; host interpretation is unavailable: "+String(p));continue}try{E8.Type.forSchema(u,{wrapUnions:!0,registry:a})}catch(p){r("AVRO_VALIDATOR_LIMIT",c,"Native schema could not be interpreted by avsc 5.7.9: "+String(p))}}return n}function sxe(){return new nt().register(nxe,ixe)}function DN(e){return We(e,sxe())}function x0(e){let t=DN(e);if(!t.valid)throw new U("AVRO_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[S8];if(e.vocabularies[S8]?.version!=="0.1.0"||!rxe(n))throw new U("AVRO_PAYLOAD","Missing or malformed Avro payload");return Ae(n)}function oxe(e){return T8(x0(e))}function axe(e){let t=e.modules.find((r)=>r.id==="avro.fields");if(!t)return;let n=oxe(e).map((r)=>r.element);if(t.namespace!==""||t.elements.length!==n.length||n.some((r,i)=>["id","name","description","scalarType"].some((s)=>t.elements[i]?.[s]!==r[s])))throw new U("AVRO_FIELD_METADATA","Native fields and core metadata disagree")}function k8(e){axe(e);let t=x0(e);if(DN(e).diagnostics.some((i)=>i.code==="AVRO_REPRESENTATION"))throw new U("AVRO_REPRESENTATION","Unknown representation content cannot be discarded");let r=Be(t.root)+` + */var kse=TS(),cBe=xF(),uBe=wF(),Nse=kS();Ose.exports=class{constructor({createMessageDigest:t=null,messageDigestAlgorithm:n="sha256",canonicalIdMap:r=new Map,maxWorkFactor:i=1,maxDeepIterations:s=-1,timeout:o=0}={}){if(this.name="RDFC-1.0",this.blankNodeInfo=new Map,this.canonicalIssuer=new kse("c14n",r),this.createMessageDigest=t||(()=>new cBe(n)),this.maxWorkFactor=i,this.maxDeepIterations=s,this.remainingDeepIterations=0,this.timeout=o,o>0)this.startTime=Date.now();this.quads=null}main(t){this.quads=t;for(let a of t)this._addBlankNodeQuadInfo({quad:a,component:a.subject}),this._addBlankNodeQuadInfo({quad:a,component:a.object}),this._addBlankNodeQuadInfo({quad:a,component:a.graph});let n=new Map,r=[...this.blankNodeInfo.keys()];for(let a of r)this._hashAndTrackBlankNode({id:a,hashToBlankNodes:n});let i=[...n.keys()].sort(),s=[];for(let a of i){let l=n.get(a);if(l.length>1){s.push(l);continue}let c=l[0];this.canonicalIssuer.getId(c)}if(this.maxDeepIterations<0)if(this.maxWorkFactor===0)this.maxDeepIterations=0;else if(this.maxWorkFactor===1/0)this.maxDeepIterations=1/0;else{let a=s.reduce((l,c)=>l+c.length,0);this.maxDeepIterations=a**this.maxWorkFactor}if(this.maxDeepIterations>Number.MAX_SAFE_INTEGER)this.maxDeepIterations=1/0;this.remainingDeepIterations=this.maxDeepIterations;for(let a of s){let l=[];for(let c of a){if(this.canonicalIssuer.hasId(c))continue;let u=new kse("b");u.getId(c);let p=this.hashNDegreeQuads(c,u);l.push(p)}l.sort(pBe);for(let c of l){let u=c.issuer.getOldIds();for(let p of u)this.canonicalIssuer.getId(p)}}let o=[];for(let a of this.quads){let l=Nse.serializeQuadComponents(this._componentWithCanonicalId(a.subject),a.predicate,this._componentWithCanonicalId(a.object),this._componentWithCanonicalId(a.graph));o.push(l)}return o.sort(),o.join("")}hashFirstDegreeQuads(t){let n=[],r=this.blankNodeInfo.get(t),i=r.quads;for(let o of i)n.push(Nse.serializeQuadComponents(this.modifyFirstDegreeComponent(t,o.subject,"subject"),o.predicate,this.modifyFirstDegreeComponent(t,o.object,"object"),this.modifyFirstDegreeComponent(t,o.graph,"graph")));n.sort();let s=this.createMessageDigest();for(let o of n)s.update(o);return r.hash=s.digest(),r.hash}hashRelatedBlankNode(t,n,r,i){let s=this.createMessageDigest();if(s.update(i),i!=="g")s.update(this.getRelatedPredicate(n));let o;if(this.canonicalIssuer.hasId(t))o="_:"+this.canonicalIssuer.getId(t);else if(r.hasId(t))o="_:"+r.getId(t);else o=this.blankNodeInfo.get(t).hash;return s.update(o),s.digest()}hashNDegreeQuads(t,n){if(this.remainingDeepIterations===0)throw Error(`Maximum deep iterations exceeded (${this.maxDeepIterations}).`);this.remainingDeepIterations--;let r=this.createMessageDigest(),i=this.createHashToRelated(t,n),s=[...i.keys()].sort();for(let o of s){r.update(o);let a="",l,c=new uBe(i.get(o)),u=0;while(c.hasNext()){let p=c.next();if(++u%3===0){if(this.timeout>0&&Date.now()-this.startTime>this.timeout)throw Error("Canonize timeout.")}let d=n.clone(),f="",m=[],y=!1;for(let h of p){if(this.canonicalIssuer.hasId(h))f+="_:"+this.canonicalIssuer.getId(h);else{if(!d.hasId(h))m.push(h);f+="_:"+d.getId(h)}if(a.length!==0&&f>a){y=!0;break}}if(y)continue;for(let h of m){let b=this.hashNDegreeQuads(h,d);if(f+="_:"+d.getId(h),f+=`<${b.hash}>`,d=b.issuer,a.length!==0&&f>a){y=!0;break}}if(y)continue;if(a.length===0||f`}createHashToRelated(t,n){let r=new Map,i=this.blankNodeInfo.get(t).quads;for(let s of i)this._addRelatedBlankNodeHash({quad:s,component:s.subject,position:"s",id:t,issuer:n,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:s,component:s.object,position:"o",id:t,issuer:n,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:s,component:s.graph,position:"g",id:t,issuer:n,hashToRelated:r});return r}_hashAndTrackBlankNode({id:t,hashToBlankNodes:n}){let r=this.hashFirstDegreeQuads(t),i=n.get(r);if(!i)n.set(r,[t]);else i.push(t)}_addBlankNodeQuadInfo({quad:t,component:n}){if(n.termType!=="BlankNode")return;let r=n.value,i=this.blankNodeInfo.get(r);if(i)i.quads.add(t);else this.blankNodeInfo.set(r,{quads:new Set([t]),hash:null})}_addRelatedBlankNodeHash({quad:t,component:n,position:r,id:i,issuer:s,hashToRelated:o}){if(!(n.termType==="BlankNode"&&n.value!==i))return;let a=n.value,l=this.hashRelatedBlankNode(a,t,s,r),c=o.get(l);if(c)c.push(a);else o.set(l,[a])}_componentWithCanonicalId(t){if(t.termType==="BlankNode"&&!t.value.startsWith(this.canonicalIssuer.prefix))return{termType:"BlankNode",value:this.canonicalIssuer.getId(t.value)};return t}};function pBe(e,t){return e.hasht.hash?1:0}});var NS=z(function(dBe){var $se=Ese(),Ise=Pse();function Ase(e,t){if(t.inputFormat){if(t.inputFormat==="application/n-quads"){if(typeof e!=="string")throw Error("N-Quads input must be a string.");return dBe.NQuads.parse(e)}throw Error(`Unknown canonicalization input format: "${t.inputFormat}".`)}return e}function Rse(e){if(e.format){if(e.format!=="application/n-quads")throw Error(`Unknown canonicalization output format: "${e.format}".`)}}function jse(){if(globalThis.RDF_CANONIZE_TRACE_URDNA2015)console.trace("[rdf-canonize] URDNA2015 is deprecated, use RDFC-1.0")}dBe.NQuads=kS();dBe.IdentifierIssuer=TS();dBe.canonize=async function(e,t={}){let n=Ase(e,t);if(Rse(t),!("algorithm"in t))throw Error("No RDF Dataset Canonicalization algorithm specified.");if(t.algorithm==="RDFC-1.0")return new $se(t).main(n);if(t.algorithm==="URDNA2015"&&!t.rejectURDNA2015)return jse(),new $se(t).main(n);throw Error("Invalid RDF Dataset Canonicalization algorithm: "+t.algorithm)};dBe._canonizeSync=function(e,t={}){let n=Ase(e,t);if(Rse(t),!("algorithm"in t))throw Error("No RDF Dataset Canonicalization algorithm specified.");if(t.algorithm==="RDFC-1.0")return new Ise(t).main(n);if(t.algorithm==="URDNA2015"&&!t.rejectURDNA2015)return jse(),new Ise(t).main(n);throw Error("Invalid RDF Dataset Canonicalization algorithm: "+t.algorithm)}});var js=z(function(lBt,Fse){var ea={};Fse.exports=ea;ea.isArray=Array.isArray;ea.isBoolean=(e)=>typeof e==="boolean"||Object.prototype.toString.call(e)==="[object Boolean]";ea.isDouble=(e)=>ea.isNumber(e)&&(String(e).indexOf(".")!==-1||Math.abs(e)>=1000000000000000000000);ea.isEmptyObject=(e)=>ea.isObject(e)&&Object.keys(e).length===0;ea.isNumber=(e)=>typeof e==="number"||Object.prototype.toString.call(e)==="[object Number]";ea.isNumeric=(e)=>!isNaN(parseFloat(e))&&isFinite(e);ea.isObject=(e)=>Object.prototype.toString.call(e)==="[object Object]";ea.isString=(e)=>typeof e==="string"||Object.prototype.toString.call(e)==="[object String]";ea.isUndefined=(e)=>typeof e>"u"});var El=z(function(cBt,Cse){var pf=js(),Rc={};Cse.exports=Rc;Rc.isSubject=(e)=>{if(pf.isObject(e)&&!(("@value"in e)||("@set"in e)||("@list"in e)))return Object.keys(e).length>1||!("@id"in e);return!1};Rc.isSubjectReference=(e)=>pf.isObject(e)&&Object.keys(e).length===1&&("@id"in e);Rc.isValue=(e)=>pf.isObject(e)&&("@value"in e);Rc.isList=(e)=>pf.isObject(e)&&("@list"in e);Rc.isGraph=(e)=>pf.isObject(e)&&("@graph"in e)&&Object.keys(e).filter((t)=>t!=="@id"&&t!=="@index").length===1;Rc.isSimpleGraph=(e)=>Rc.isGraph(e)&&!("@id"in e);Rc.isBlankNode=(e)=>{if(pf.isObject(e)){if("@id"in e){let t=e["@id"];return!pf.isString(t)||t.indexOf("_:")===0}return Object.keys(e).length===0||!(("@value"in e)||("@set"in e)||("@list"in e))}return!1}});var so=z(function(uBt,Mse){Mse.exports=class extends Error{constructor(t="An unspecified JSON-LD error occurred.",n="jsonld.Error",r={}){super(t);this.name=n,this.message=t,this.details=r}}});var oo=z(function(pBt,Vse){var Gv=El(),vi=js(),qse=NS().IdentifierIssuer,gBe=so(),bBe=/^[a-zA-Z]{1,8}(-[a-zA-Z0-9]{1,8})*$/,vBe=/(?:<[^>]*?>|"[^"]*?"|[^,])+/g,_Be=/\s*<([^>]*?)>\s*(?:;\s*(.*))?/,xBe=/(.*?)=(?:(?:"([^"]*?)")|([^"]*?))\s*(?:(?:;\s*)|$)/g,wBe=/^@[a-zA-Z]+$/,Lse={headers:{accept:"application/ld+json, application/json"}},_n={};Vse.exports=_n;_n.IdentifierIssuer=qse;_n.REGEX_BCP47=bBe;_n.REGEX_KEYWORD=wBe;_n.clone=function(e){if(e&&typeof e==="object"){if(vi.isNumber(e)&&Object.isFrozen(e)&&e[Symbol.for("umf.jsonld.exact-number")]===!0)return e;let t;if(vi.isArray(e)){t=[];for(let n=0;n{if(Object.keys(e).some((n)=>n.toLowerCase()==="accept"))throw RangeError('Accept header may not be specified; only "'+Lse.headers.accept+'" is supported.');return Object.assign({Accept:Lse.headers.accept},e)};_n.parseLinkHeader=(e)=>{let t={},n=e.match(vBe);for(let r=0;r{if(vi.isString(e))return;if(vi.isArray(e)&&e.every((n)=>vi.isString(n)))return;if(t&&vi.isObject(e))switch(Object.keys(e).length){case 0:return;case 1:if("@default"in e&&_n.asArray(e["@default"]).every((n)=>vi.isString(n)))return}throw new gBe('Invalid JSON-LD syntax; "@type" value must a string, an array of strings, an empty object, or a default object.',"jsonld.SyntaxError",{code:"invalid type value",value:e})};_n.hasProperty=(e,t)=>{if(e.hasOwnProperty(t)){let n=e[t];return!vi.isArray(n)||n.length>0}return!1};_n.hasValue=(e,t,n)=>{if(_n.hasProperty(e,t)){let r=e[t],i=Gv.isList(r);if(vi.isArray(r)||i){if(i)r=r["@list"];for(let s=0;s{if(r=r||{},!("propertyIsArray"in r))r.propertyIsArray=!1;if(!("valueIsArray"in r))r.valueIsArray=!1;if(!("allowDuplicate"in r))r.allowDuplicate=!0;if(!("prependValue"in r))r.prependValue=!1;if(r.valueIsArray)e[t]=n;else if(vi.isArray(n)){if(n.length===0&&r.propertyIsArray&&!e.hasOwnProperty(t))e[t]=[];if(r.prependValue)n=n.concat(e[t]),e[t]=[];for(let i=0;i[].concat(e[t]||[]);_n.removeProperty=(e,t)=>{delete e[t]};_n.removeValue=(e,t,n,r)=>{if(r=r||{},!("propertyIsArray"in r))r.propertyIsArray=!1;let i=_n.getValues(e,t).filter((s)=>!_n.compareValues(s,n));if(i.length===0)_n.removeProperty(e,t);else if(i.length===1&&!r.propertyIsArray)e[t]=i[0];else e[t]=i};_n.relabelBlankNodes=(e,t)=>{t=t||{};let n=t.issuer||new qse("_:b");return OS(n,e)};function Use(e,t){if(Bse(e,t))return!0;if(!e||!t||typeof e!=="object"||typeof t!=="object"||e instanceof Number||t instanceof Number)return!1;if(Array.isArray(e)!==Array.isArray(t))return!1;let n=Object.keys(e);return n.length===Object.keys(t).length&&n.every((r)=>Object.prototype.hasOwnProperty.call(t,r)&&Use(e[r],t[r]))}function Bse(e,t){let n=Symbol.for("umf.jsonld.number-equals");if(e instanceof Number&&Object.isFrozen(e)&&typeof e[n]==="function")return e[n](t);if(t instanceof Number&&Object.isFrozen(t)&&typeof t[n]==="function")return t[n](e);return e===t}_n.compareValues=(e,t)=>{if(e===t)return!0;if(Gv.isValue(e)&&Gv.isValue(t)&&(e["@type"]==="@json"?Use(e["@value"],t["@value"]):Bse(e["@value"],t["@value"]))&&e["@type"]===t["@type"]&&e["@language"]===t["@language"]&&e["@direction"]===t["@direction"]&&e["@index"]===t["@index"])return!0;if(vi.isObject(e)&&"@id"in e&&vi.isObject(t)&&"@id"in t)return e["@id"]===t["@id"];return!1};_n.compareShortestLeast=(e,t)=>{if(e.length{let n={},r=Li.parsers[t||"full"],i=r.regex.exec(e),s=r.keys.length;while(s--)n[r.keys[s]]=i[s]===void 0?null:i[s];if(n.scheme==="https"&&n.port==="443"||n.scheme==="http"&&n.port==="80")n.href=n.href.replace(":"+n.port,""),n.authority=n.authority.replace(":"+n.port,""),n.port=null;return n.normalizedPath=Li.removeDotSegments(n.path),n};Li.prependBase=(e,t)=>{if(e===null)return t;if(Li.isAbsolute(t))return t;if(!e||$S.isString(e))e=Li.parse(e||"");let n=Li.parse(t),r={protocol:e.protocol||""};if(n.authority!==null)r.authority=n.authority,r.path=n.path,r.query=n.query;else if(r.authority=e.authority,n.path==="")if(r.path=e.path,n.query!==null)r.query=n.query;else r.query=e.query;else{if(n.path.indexOf("/")===0)r.path=n.path;else{let s=e.path;if(s=s.substr(0,s.lastIndexOf("/")+1),(s.length>0||e.authority)&&s.substr(-1)!=="/")s+="/";s+=n.path,r.path=s}r.query=n.query}if(n.path!=="")r.path=Li.removeDotSegments(r.path);let i=r.protocol;if(r.authority!==null)i+="//"+r.authority;if(i+=r.path,r.query!==null)i+="?"+r.query;if(n.fragment!==null)i+="#"+n.fragment;if(i==="")i="./";return i};Li.removeBase=(e,t)=>{if(e===null)return t;if(!e||$S.isString(e))e=Li.parse(e||"");let n="";if(e.href!=="")n+=(e.protocol||"")+"//"+(e.authority||"");else if(t.indexOf("//"))n+="//";if(t.indexOf(n)!==0)return t;let r=Li.parse(t.substr(n.length)),i=e.normalizedPath.split("/"),s=r.normalizedPath.split("/"),o=r.fragment||r.query?0:1;while(i.length>0&&s.length>o){if(i[0]!==s[0])break;i.shift(),s.shift()}let a="";if(i.length>0){i.pop();for(let l=0;l{if(e.length===0)return"";let t=e.split("/"),n=[];while(t.length>0){let r=t.shift(),i=t.length===0;if(r==="."){if(i)n.push("");continue}if(r===".."){if(n.pop(),i)n.push("");continue}n.push(r)}if(e[0]==="/"&&n.length>0&&n[0]!=="")n.unshift("");if(n.length===1&&n[0]==="")return"/";return n.join("/")};var DBe=/^([A-Za-z][A-Za-z0-9+-.]*|_):[^\u0009-\u000d\u0020]*(?![\s\S])/;Li.isAbsolute=(e)=>$S.isString(e)&&DBe.test(e);Li.isRelative=(e)=>$S.isString(e)});var zse=z(function(yBt,Hse){var{parseLinkHeader:TBe,buildHeaders:SBe}=oo(),{LINK_HEADER_CONTEXT:EBe}=PS(),Hv=so(),kBe=DF(),{prependBase:NBe}=jc(),OBe=/(^|(\r\n))link:/i;Hse.exports=({secure:e,headers:t={},xhr:n}={headers:{}})=>{return t=SBe(t),new kBe().wrapLoader(i);async function i(s){if(s.indexOf("http:")!==0&&s.indexOf("https:")!==0)throw new Hv('URL could not be dereferenced; only "http" and "https" URLs are supported.',"jsonld.InvalidUrl",{code:"loading document failed",url:s});if(e&&s.indexOf("https")!==0)throw new Hv(`URL could not be dereferenced; secure mode is enabled and the URL's scheme is not "https".`,"jsonld.InvalidUrl",{code:"loading document failed",url:s});let o;try{o=await PBe(n,s,t)}catch(p){throw new Hv("URL could not be dereferenced, an error occurred.","jsonld.LoadDocumentError",{code:"loading document failed",url:s,cause:p})}if(o.status>=400)throw new Hv("URL could not be dereferenced: "+o.statusText,"jsonld.LoadDocumentError",{code:"loading document failed",url:s,httpStatusCode:o.status});let a={contextUrl:null,documentUrl:s,document:o.response},l=null,c=o.getResponseHeader("Content-Type"),u;if(OBe.test(o.getAllResponseHeaders()))u=o.getResponseHeader("Link");if(u&&c!=="application/ld+json"){let p=TBe(u),d=p[EBe];if(Array.isArray(d))throw new Hv("URL could not be dereferenced, it has more than one associated HTTP Link Header.","jsonld.InvalidUrl",{code:"multiple context link headers",url:s});if(d)a.contextUrl=d.target;if(l=p.alternate,l&&l.type=="application/ld+json"&&!(c||"").match(/^application\/(\w*\+)?json$/))a=await i(NBe(s,l.target))}return a}};function PBe(e,t,n){e=e||XMLHttpRequest;let r=new e;return new Promise((i,s)=>{r.onload=()=>i(r),r.onerror=(o)=>s(o),r.open("GET",t,!0);for(let o in n)r.setRequestHeader(o,n[o]);r.send()})}});var Qse=z(function(hBt,Wse){var $Be=zse(),TF={};Wse.exports=TF;TF.setupDocumentLoaders=function(e){if(typeof XMLHttpRequest<"u")e.documentLoaders.xhr=$Be,e.useDocumentLoader("xhr")};TF.setupGlobals=function(e){if(typeof globalThis.JsonLdProcessor>"u")Object.defineProperty(globalThis,"JsonLdProcessor",{writable:!0,enumerable:!1,configurable:!0,value:e.JsonLdProcessor})}});var Xse=z(function(gBt,Yse){Yse.exports=function(e){e.prototype[Symbol.iterator]=function*(){for(let t=this.head;t;t=t.next)yield t.value}}});var eoe=z(function(bBt,Zse){Zse.exports=yn;yn.Node=df;yn.create=yn;function yn(e){var t=this;if(!(t instanceof yn))t=new yn;if(t.tail=null,t.head=null,t.length=0,e&&typeof e.forEach==="function")e.forEach(function(i){t.push(i)});else if(arguments.length>0)for(var n=0,r=arguments.length;n1)n=t;else if(this.head)r=this.head.next,n=this.head.value;else throw TypeError("Reduce of empty list with no initial value");for(var i=0;r!==null;i++)n=e(n,r.value,i),r=r.next;return n};yn.prototype.reduceReverse=function(e,t){var n,r=this.tail;if(arguments.length>1)n=t;else if(this.tail)r=this.tail.prev,n=this.tail.value;else throw TypeError("Reduce of empty list with no initial value");for(var i=this.length-1;r!==null;i--)n=e(n,r.value,i),r=r.prev;return n};yn.prototype.toArray=function(){var e=Array(this.length);for(var t=0,n=this.head;n!==null;t++)e[t]=n.value,n=n.next;return e};yn.prototype.toArrayReverse=function(){var e=Array(this.length);for(var t=0,n=this.tail;n!==null;t++)e[t]=n.value,n=n.prev;return e};yn.prototype.slice=function(e,t){if(t=t||this.length,t<0)t+=this.length;if(e=e||0,e<0)e+=this.length;var n=new yn;if(tthis.length)t=this.length;for(var r=0,i=this.head;i!==null&&rthis.length)t=this.length;for(var r=this.length,i=this.tail;i!==null&&r>t;r--)i=i.prev;for(;i!==null&&r>e;r--,i=i.prev)n.push(i.value);return n};yn.prototype.splice=function(e,t,...n){if(e>this.length)e=this.length-1;if(e<0)e=this.length+e;for(var r=0,i=this.head;i!==null&&r1;class ioe{constructor(e){if(typeof e==="number")e={max:e};if(!e)e={};if(e.max&&(typeof e.max!=="number"||e.max<0))throw TypeError("max must be a non-negative number");let t=this[ff]=e.max||1/0,n=e.length||SF;if(this[By]=typeof n!=="function"?SF:n,this[Wv]=e.stale||!1,e.maxAge&&typeof e.maxAge!=="number")throw TypeError("maxAge must be a number");this[mf]=e.maxAge||0,this[Fc]=e.dispose,this[toe]=e.noDisposeOnSet||!1,this[roe]=e.updateAgeOnGet||!1,this.reset()}set max(e){if(typeof e!=="number"||e<0)throw TypeError("max must be a non-negative number");this[ff]=e||1/0,zv(this)}get max(){return this[ff]}set allowStale(e){this[Wv]=!!e}get allowStale(){return this[Wv]}set maxAge(e){if(typeof e!=="number")throw TypeError("maxAge must be a non-negative number");this[mf]=e,zv(this)}get maxAge(){return this[mf]}set lengthCalculator(e){if(typeof e!=="function")e=SF;if(e!==this[By])this[By]=e,this[Cc]=0,this[si].forEach((t)=>{t.length=this[By](t.value,t.key),this[Cc]+=t.length});zv(this)}get lengthCalculator(){return this[By]}get length(){return this[Cc]}get itemCount(){return this[si].length}rforEach(e,t){t=t||this;for(let n=this[si].tail;n!==null;){let r=n.prev;noe(this,e,n,t),n=r}}forEach(e,t){t=t||this;for(let n=this[si].head;n!==null;){let r=n.next;noe(this,e,n,t),n=r}}keys(){return this[si].toArray().map((e)=>e.key)}values(){return this[si].toArray().map((e)=>e.value)}reset(){if(this[Fc]&&this[si]&&this[si].length)this[si].forEach((e)=>this[Fc](e.key,e.value));this[Ma]=new Map,this[si]=new jBe,this[Cc]=0}dump(){return this[si].map((e)=>IS(this,e)?!1:{k:e.key,v:e.value,e:e.now+(e.maxAge||0)}).toArray().filter((e)=>e)}dumpLru(){return this[si]}set(e,t,n){if(n=n||this[mf],n&&typeof n!=="number")throw TypeError("maxAge must be a number");let r=n?Date.now():0,i=this[By](t,e);if(this[Ma].has(e)){if(i>this[ff])return Vy(this,this[Ma].get(e)),!1;let a=this[Ma].get(e).value;if(this[Fc]){if(!this[toe])this[Fc](e,a.value)}return a.now=r,a.maxAge=n,a.value=t,this[Cc]+=i-a.length,a.length=i,this.get(e),zv(this),!0}let s=new soe(e,t,i,r,n);if(s.length>this[ff]){if(this[Fc])this[Fc](e,t);return!1}return this[Cc]+=s.length,this[si].unshift(s),this[Ma].set(e,this[si].head),zv(this),!0}has(e){if(!this[Ma].has(e))return!1;let t=this[Ma].get(e).value;return!IS(this,t)}get(e){return EF(this,e,!0)}peek(e){return EF(this,e,!1)}pop(){let e=this[si].tail;if(!e)return null;return Vy(this,e),e.value}del(e){Vy(this,this[Ma].get(e))}load(e){this.reset();let t=Date.now();for(let n=e.length-1;n>=0;n--){let r=e[n],i=r.e||0;if(i===0)this.set(r.k,r.v);else{let s=i-t;if(s>0)this.set(r.k,r.v,s)}}}prune(){this[Ma].forEach((e,t)=>EF(this,t,!1))}}var EF=(e,t,n)=>{let r=e[Ma].get(t);if(r){let i=r.value;if(IS(e,i)){if(Vy(e,r),!e[Wv])return}else if(n){if(e[roe])r.value.now=Date.now();e[si].unshiftNode(r)}return i.value}},IS=(e,t)=>{if(!t||!t.maxAge&&!e[mf])return!1;let n=Date.now()-t.now;return t.maxAge?n>t.maxAge:e[mf]&&n>e[mf]},zv=(e)=>{if(e[Cc]>e[ff])for(let t=e[si].tail;e[Cc]>e[ff]&&t!==null;){let n=t.prev;Vy(e,t),t=n}},Vy=(e,t)=>{if(t){let n=t.value;if(e[Fc])e[Fc](n.key,n.value);e[Cc]-=n.length,e[Ma].delete(n.key),e[si].removeNode(t)}};class soe{constructor(e,t,n,r,i){this.key=e,this.value=t,this.length=n,this.now=r,this.maxAge=i||0}}var noe=(e,t,n,r)=>{let i=n.value;if(IS(e,i)){if(Vy(e,n),!e[Wv])i=void 0}if(i)t.call(r,i.value,i.key,e)};ooe.exports=ioe});var loe=z(function(_Bt,aoe){var FBe=kF();aoe.exports=class{constructor({document:t}){this.document=t,this.cache=new FBe({max:10})}getProcessed(t){return this.cache.get(t)}setProcessed(t,n){this.cache.set(t,n)}}});var poe=z(function(xBt,uoe){var{isArray:NF,isObject:Yv,isString:AS}=js(),{asArray:CBe}=oo(),{prependBase:OF}=jc(),Qv=so(),coe=loe();uoe.exports=class{constructor({sharedCache:t}){this.perOpCache=new Map,this.sharedCache=t}async resolve({activeCtx:t,context:n,documentLoader:r,base:i,cycles:s=new Set}){if(n&&Yv(n)&&n["@context"])n=n["@context"];n=CBe(n);let o=[];for(let a of n){if(AS(a)){let u=this._get(a);if(!u)u=await this._resolveRemoteContext({activeCtx:t,url:a,documentLoader:r,base:i,cycles:s});if(NF(u))o.push(...u);else o.push(u);continue}if(a===null){o.push(new coe({document:null}));continue}if(!Yv(a))MBe(n);let l=JSON.stringify(a),c=this._get(l);if(!c)c=new coe({document:a}),this._cacheResolvedContext({key:l,resolved:c,tag:"static"});o.push(c)}return o}_get(t){let n=this.perOpCache.get(t);if(!n){let r=this.sharedCache.get(t);if(r){if(n=r.get("static"),n)this.perOpCache.set(t,n)}}return n}_cacheResolvedContext({key:t,resolved:n,tag:r}){if(this.perOpCache.set(t,n),r!==void 0){let i=this.sharedCache.get(t);if(!i)i=new Map,this.sharedCache.set(t,i);i.set(r,n)}return n}async _resolveRemoteContext({activeCtx:t,url:n,documentLoader:r,base:i,cycles:s}){n=OF(i,n);let{context:o,remoteDoc:a}=await this._fetchContext({activeCtx:t,url:n,documentLoader:r,cycles:s});i=a.documentUrl||n,PF({context:o,base:i});let l=await this.resolve({activeCtx:t,context:o,documentLoader:r,base:i,cycles:s});return this._cacheResolvedContext({key:n,resolved:l,tag:a.tag}),l}async _fetchContext({activeCtx:t,url:n,documentLoader:r,cycles:i}){if(i.size>10)throw new Qv("Maximum number of @context URLs exceeded.","jsonld.ContextUrlError",{code:t.processingMode==="json-ld-1.0"?"loading remote context failed":"context overflow",max:10});if(i.has(n))throw new Qv("Cyclical @context URLs detected.","jsonld.ContextUrlError",{code:t.processingMode==="json-ld-1.0"?"recursive context inclusion":"context overflow",url:n});i.add(n);let s,o;try{if(o=await r(n),s=o.document||null,AS(s))s=JSON.parse(s)}catch(a){throw new Qv(`Dereferencing a URL did not result in a valid JSON-LD object. Possible causes are an inaccessible URL perhaps due to a same-origin policy (ensure the server uses CORS if you are using client-side JavaScript), too many redirects, a non-JSON response, or more than one HTTP Link Header was provided for a remote context. URL: "${n}".`,"jsonld.InvalidUrl",{code:"loading remote context failed",url:n,cause:a})}if(!Yv(s))throw new Qv(`Dereferencing a URL did not result in a JSON object. The response was valid JSON, but it was not a JSON object. URL: "${n}".`,"jsonld.InvalidUrl",{code:"invalid remote context",url:n});if(!("@context"in s))s={"@context":{}};else s={"@context":s["@context"]};if(o.contextUrl){if(!NF(s["@context"]))s["@context"]=[s["@context"]];s["@context"].push(o.contextUrl)}return{context:s,remoteDoc:o}}};function MBe(e){throw new Qv("Invalid JSON-LD syntax; @context must be an object.","jsonld.SyntaxError",{code:"invalid local context",context:e})}function PF({context:e,base:t}){if(!e)return;let n=e["@context"];if(AS(n)){e["@context"]=OF(t,n);return}if(NF(n)){for(let r=0;r{let t=[].concat(e.safe?ao.safeEventHandler:[],e.eventHandler?moe(e.eventHandler):[],ao.defaultEventHandler?ao.defaultEventHandler:[]);return t.length===0?null:t};ao.handleEvent=({event:e,options:t})=>{yoe({event:e,handlers:t.eventHandler})};function yoe({event:e,handlers:t}){let n=!0;for(let r=0;n&&r{n=!0}});else if(typeof i==="object")if(e.code in i)i[e.code]({event:e,next:()=>{n=!0}});else n=!0;else throw new $F("Invalid event handler.","jsonld.InvalidEventHandler",{event:e})}return n}var qBe=new Set(["empty object","free-floating scalar","invalid @language value","invalid property","null @id value","null @value value","object with only @id","object with only @language","object with only @list","object with only @value","relative @id reference","relative @type reference","relative @vocab reference","reserved @id value","reserved @reverse value","reserved term","blank node predicate","relative graph reference","relative object reference","relative predicate reference","relative subject reference","rdfDirection not set"]);ao.safeEventHandler=function({event:t,next:n}){if(t.level==="warning"&&qBe.has(t.code))throw new $F("Safe mode validation error.","jsonld.ValidationError",{event:t});n()};ao.logEventHandler=function({event:t,next:n}){console.log(`EVENT: ${t.message}`,{event:t}),n()};ao.logWarningEventHandler=function({event:t,next:n}){if(t.level==="warning")console.warn(`WARNING: ${t.message}`,{event:t});n()};ao.unhandledEventHandler=function({event:t}){throw new $F("No handler for event.","jsonld.UnhandledEvent",{event:t})};ao.setDefaultEventHandler=function({eventHandler:e}={}){ao.defaultEventHandler=e?moe(e):null}});var yp=z(function(TBt,_oe){var goe=oo(),xt=so(),{isArray:boe,isObject:mp,isString:Fs,isUndefined:UBe}=js(),{isAbsolute:yf,isRelative:BBe,prependBase:Xv}=jc(),{handleEvent:Gy}=Ky(),{REGEX_BCP47:VBe,REGEX_KEYWORD:jS,asArray:voe,compareShortestLeast:KBe}=oo(),RS=new Map,Mn={};_oe.exports=Mn;Mn.process=async({activeCtx:e,localCtx:t,options:n,propagate:r=!0,overrideProtected:i=!1,cycles:s=new Set})=>{if(mp(t)&&"@context"in t&&boe(t["@context"]))t=t["@context"];if(voe(t).length===0)return e;let a=[],l=[({event:d,next:f})=>{a.push(d),f()}];if(n.eventHandler)l.push(n.eventHandler);let c=n;n={...n,eventHandler:l};let u=await n.contextResolver.resolve({activeCtx:e,context:t,documentLoader:n.documentLoader,base:n.base});if(mp(u[0].document)&&typeof u[0].document["@propagate"]==="boolean")r=u[0].document["@propagate"];let p=e;if(!r&&!p.previousContext)p=p.clone(),p.previousContext=e;for(let d of u){let{document:f}=d;if(e=p,f===null){if(!i&&Object.keys(e.protected).length!==0)throw new xt("Tried to nullify a context with protected terms outside of a term definition.","jsonld.SyntaxError",{code:"invalid context nullification"});p=e=Mn.getInitialContext(n).clone();continue}let m=d.getProcessed(e);if(m){if(c.eventHandler)for(let h of m.events)Gy({event:h,options:c});p=e=m.context;continue}if(mp(f)&&"@context"in f)f=f["@context"];if(!mp(f))throw new xt("Invalid JSON-LD syntax; @context must be an object.","jsonld.SyntaxError",{code:"invalid local context",context:f});p=p.clone();let y=new Map;if("@version"in f){if(f["@version"]!==1.1)throw new xt("Unsupported JSON-LD version: "+f["@version"],"jsonld.UnsupportedVersion",{code:"invalid @version value",context:f});if(e.processingMode&&e.processingMode==="json-ld-1.0")throw new xt("@version: "+f["@version"]+" not compatible with "+e.processingMode,"jsonld.ProcessingModeConflict",{code:"processing mode conflict",context:f});p.processingMode="json-ld-1.1",p["@version"]=f["@version"],y.set("@version",!0)}if(p.processingMode=p.processingMode||e.processingMode,"@base"in f){let h=f["@base"];if(h===null||yf(h));else if(BBe(h))h=Xv(p["@base"],h);else throw new xt('Invalid JSON-LD syntax; the value of "@base" in a @context must be an absolute IRI, a relative IRI, or null.',"jsonld.SyntaxError",{code:"invalid base IRI",context:f});p["@base"]=h,y.set("@base",!0)}if("@vocab"in f){let h=f["@vocab"];if(h===null)delete p["@vocab"];else if(!Fs(h))throw new xt('Invalid JSON-LD syntax; the value of "@vocab" in a @context must be a string or null.',"jsonld.SyntaxError",{code:"invalid vocab mapping",context:f});else if(!yf(h)&&Mn.processingMode(p,1))throw new xt('Invalid JSON-LD syntax; the value of "@vocab" in a @context must be an absolute IRI.',"jsonld.SyntaxError",{code:"invalid vocab mapping",context:f});else{let b=Jy(p,h,{vocab:!0,base:!0},void 0,void 0,n);if(!yf(b)){if(n.eventHandler)Gy({event:{type:["JsonLdEvent"],code:"relative @vocab reference",level:"warning",message:"Relative @vocab reference found.",details:{vocab:b}},options:n})}p["@vocab"]=b}y.set("@vocab",!0)}if("@language"in f){let h=f["@language"];if(h===null)delete p["@language"];else if(!Fs(h))throw new xt('Invalid JSON-LD syntax; the value of "@language" in a @context must be a string or null.',"jsonld.SyntaxError",{code:"invalid default language",context:f});else{if(!h.match(VBe)){if(n.eventHandler)Gy({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:h}},options:n})}p["@language"]=h.toLowerCase()}y.set("@language",!0)}if("@direction"in f){let h=f["@direction"];if(e.processingMode==="json-ld-1.0")throw new xt("Invalid JSON-LD syntax; @direction not compatible with "+e.processingMode,"jsonld.SyntaxError",{code:"invalid context member",context:f});if(h===null)delete p["@direction"];else if(h!=="ltr"&&h!=="rtl")throw new xt('Invalid JSON-LD syntax; the value of "@direction" in a @context must be null, "ltr", or "rtl".',"jsonld.SyntaxError",{code:"invalid base direction",context:f});else p["@direction"]=h;y.set("@direction",!0)}if("@propagate"in f){let h=f["@propagate"];if(e.processingMode==="json-ld-1.0")throw new xt("Invalid JSON-LD syntax; @propagate not compatible with "+e.processingMode,"jsonld.SyntaxError",{code:"invalid context entry",context:f});if(typeof h!=="boolean")throw new xt("Invalid JSON-LD syntax; @propagate value must be a boolean.","jsonld.SyntaxError",{code:"invalid @propagate value",context:t});y.set("@propagate",!0)}if("@import"in f){let h=f["@import"];if(e.processingMode==="json-ld-1.0")throw new xt("Invalid JSON-LD syntax; @import not compatible with "+e.processingMode,"jsonld.SyntaxError",{code:"invalid context entry",context:f});if(!Fs(h))throw new xt("Invalid JSON-LD syntax; @import must be a string.","jsonld.SyntaxError",{code:"invalid @import value",context:t});let b=await n.contextResolver.resolve({activeCtx:e,context:h,documentLoader:n.documentLoader,base:n.base});if(b.length!==1)throw new xt("Invalid JSON-LD syntax; @import must reference a single context.","jsonld.SyntaxError",{code:"invalid remote context",context:t});let g=b[0].getProcessed(e);if(g)f=g;else{let x=b[0].document;if("@import"in x)throw new xt("Invalid JSON-LD syntax: imported context must not include @import.","jsonld.SyntaxError",{code:"invalid context entry",context:t});for(let v in x)if(!f.hasOwnProperty(v))f[v]=x[v];b[0].setProcessed(e,f)}y.set("@import",!0)}y.set("@protected",f["@protected"]||!1);for(let h in f)if(Mn.createTermDefinition({activeCtx:p,localCtx:f,term:h,defined:y,options:n,overrideProtected:i}),mp(f[h])&&"@context"in f[h]){let b=f[h]["@context"],g=!0;if(Fs(b)){let x=Xv(n.base,b);if(s.has(x))g=!1;else s.add(x)}if(g)try{await Mn.process({activeCtx:p.clone(),localCtx:f[h]["@context"],overrideProtected:!0,options:n,cycles:s})}catch(x){throw new xt("Invalid JSON-LD syntax; invalid scoped context.","jsonld.SyntaxError",{code:"invalid scoped context",context:f[h]["@context"],term:h})}}d.setProcessed(e,{context:p,events:a})}return p};Mn.createTermDefinition=({activeCtx:e,localCtx:t,term:n,defined:r,options:i,overrideProtected:s=!1})=>{if(r.has(n)){if(r.get(n))return;throw new xt("Cyclical context definition detected.","jsonld.CyclicalContext",{code:"cyclic IRI mapping",context:t,term:n})}r.set(n,!1);let o;if(t.hasOwnProperty(n))o=t[n];if(n==="@type"&&mp(o)&&(o["@container"]||"@set")==="@set"&&Mn.processingMode(e,1.1)){let f=["@container","@id","@protected"],m=Object.keys(o);if(m.length===0||m.some((y)=>!f.includes(y)))throw new xt("Invalid JSON-LD syntax; keywords cannot be overridden.","jsonld.SyntaxError",{code:"keyword redefinition",context:t,term:n})}else if(Mn.isKeyword(n))throw new xt("Invalid JSON-LD syntax; keywords cannot be overridden.","jsonld.SyntaxError",{code:"keyword redefinition",context:t,term:n});else if(n.match(jS)){if(i.eventHandler)Gy({event:{type:["JsonLdEvent"],code:"reserved term",level:"warning",message:'Terms beginning with "@" are reserved for future use and dropped.',details:{term:n}},options:i});return}else if(n==="")throw new xt("Invalid JSON-LD syntax; a term cannot be an empty string.","jsonld.SyntaxError",{code:"invalid term definition",context:t});let a=e.mappings.get(n);if(e.mappings.has(n))e.mappings.delete(n);let l=!1;if(Fs(o)||o===null)l=!0,o={"@id":o};if(!mp(o))throw new xt("Invalid JSON-LD syntax; @context term values must be strings or objects.","jsonld.SyntaxError",{code:"invalid term definition",context:t});let c={};e.mappings.set(n,c),c.reverse=!1;let u=["@container","@id","@language","@reverse","@type"];if(Mn.processingMode(e,1.1))u.push("@context","@direction","@index","@nest","@prefix","@protected");for(let f in o)if(!u.includes(f))throw new xt("Invalid JSON-LD syntax; a term definition must not contain "+f,"jsonld.SyntaxError",{code:"invalid term definition",context:t});let p=n.indexOf(":");if(c._termHasColon=p>0,"@reverse"in o){if("@id"in o)throw new xt("Invalid JSON-LD syntax; a @reverse term definition must not contain @id.","jsonld.SyntaxError",{code:"invalid reverse property",context:t});if("@nest"in o)throw new xt("Invalid JSON-LD syntax; a @reverse term definition must not contain @nest.","jsonld.SyntaxError",{code:"invalid reverse property",context:t});let f=o["@reverse"];if(!Fs(f))throw new xt("Invalid JSON-LD syntax; a @context @reverse value must be a string.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});if(f.match(jS)){if(i.eventHandler)Gy({event:{type:["JsonLdEvent"],code:"reserved @reverse value",level:"warning",message:'@reverse values beginning with "@" are reserved for future use and dropped.',details:{reverse:f}},options:i});if(a)e.mappings.set(n,a);else e.mappings.delete(n);return}let m=Jy(e,f,{vocab:!0,base:!1},t,r,i);if(!yf(m))throw new xt("Invalid JSON-LD syntax; a @context @reverse value must be an absolute IRI or a blank node identifier.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});c["@id"]=m,c.reverse=!0}else if("@id"in o){let f=o["@id"];if(f&&!Fs(f))throw new xt("Invalid JSON-LD syntax; a @context @id value must be an array of strings or a string.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});if(f===null)c["@id"]=null;else if(!Mn.isKeyword(f)&&f.match(jS)){if(i.eventHandler)Gy({event:{type:["JsonLdEvent"],code:"reserved @id value",level:"warning",message:'@id values beginning with "@" are reserved for future use and dropped.',details:{id:f}},options:i});if(a)e.mappings.set(n,a);else e.mappings.delete(n);return}else if(f!==n){if(f=Jy(e,f,{vocab:!0,base:!1},t,r,i),!yf(f)&&!Mn.isKeyword(f))throw new xt("Invalid JSON-LD syntax; a @context @id value must be an absolute IRI, a blank node identifier, or a keyword.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});if(Mn.processingMode(e,1.1)&&n.match(/(?::[^:])|\//)){let m=new Map(r).set(n,!0);if(Jy(e,n,{vocab:!0,base:!1},t,m,i)!==f)throw new xt("Invalid JSON-LD syntax; term in form of IRI must expand to definition.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t})}c["@id"]=f,c._prefix=!c._termHasColon&&(Mn.processingMode(e,1)||l&&f.match(/[:\/\?#\[\]@]$/)!==null)}}if(!("@id"in c))if(c._termHasColon){let f=n.substr(0,p);if(t.hasOwnProperty(f))Mn.createTermDefinition({activeCtx:e,localCtx:t,term:f,defined:r,options:i});if(e.mappings.has(f)){let m=n.substr(p+1);c["@id"]=e.mappings.get(f)["@id"]+m}else c["@id"]=n}else if(n==="@type")c["@id"]=n;else{if(!("@vocab"in e))throw new xt("Invalid JSON-LD syntax; @context terms must define an @id.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t,term:n});c["@id"]=e["@vocab"]+n}if(o["@protected"]===!0||r.get("@protected")===!0&&o["@protected"]!==!1)e.protected[n]=!0,c.protected=!0;if(r.set(n,!0),"@type"in o){let f=o["@type"];if(!Fs(f))throw new xt("Invalid JSON-LD syntax; an @context @type value must be a string.","jsonld.SyntaxError",{code:"invalid type mapping",context:t});if(f==="@json"||f==="@none"){if(Mn.processingMode(e,1))throw new xt(`Invalid JSON-LD syntax; an @context @type value must not be "${f}" in JSON-LD 1.0 mode.`,"jsonld.SyntaxError",{code:"invalid type mapping",context:t})}else if(f!=="@id"&&f!=="@vocab"){if(f=Jy(e,f,{vocab:!0,base:!1},t,r,i),!yf(f))throw new xt("Invalid JSON-LD syntax; an @context @type value must be an absolute IRI.","jsonld.SyntaxError",{code:"invalid type mapping",context:t});if(f.indexOf("_:")===0)throw new xt("Invalid JSON-LD syntax; an @context @type value must be an IRI, not a blank node identifier.","jsonld.SyntaxError",{code:"invalid type mapping",context:t})}c["@type"]=f}if("@container"in o){let f=Fs(o["@container"])?[o["@container"]]:o["@container"]||[],m=["@list","@set","@index","@language"],y=!0,h=f.includes("@set");if(Mn.processingMode(e,1.1)){if(m.push("@graph","@id","@type"),f.includes("@list")){if(f.length!==1)throw new xt("Invalid JSON-LD syntax; @context @container with @list must have no other values","jsonld.SyntaxError",{code:"invalid container mapping",context:t})}else if(f.includes("@graph")){if(f.some((b)=>b!=="@graph"&&b!=="@id"&&b!=="@index"&&b!=="@set"))throw new xt("Invalid JSON-LD syntax; @context @container with @graph must have no other values other than @id, @index, and @set","jsonld.SyntaxError",{code:"invalid container mapping",context:t})}else y&=f.length<=(h?2:1);if(f.includes("@type")){if(c["@type"]=c["@type"]||"@id",!["@id","@vocab"].includes(c["@type"]))throw new xt("Invalid JSON-LD syntax; container: @type requires @type to be @id or @vocab.","jsonld.SyntaxError",{code:"invalid type mapping",context:t})}}else y&=!boe(o["@container"]),y&=f.length<=1;if(y&=f.every((b)=>m.includes(b)),y&=!(h&&f.includes("@list")),!y)throw new xt("Invalid JSON-LD syntax; @context @container value must be one of the following: "+m.join(", "),"jsonld.SyntaxError",{code:"invalid container mapping",context:t});if(c.reverse&&!f.every((b)=>["@index","@set"].includes(b)))throw new xt("Invalid JSON-LD syntax; @context @container value for a @reverse type definition must be @index or @set.","jsonld.SyntaxError",{code:"invalid reverse property",context:t});c["@container"]=f}if("@index"in o){if(!("@container"in o)||!c["@container"].includes("@index"))throw new xt(`Invalid JSON-LD syntax; @index without @index in @container: "${o["@index"]}" on term "${n}".`,"jsonld.SyntaxError",{code:"invalid term definition",context:t});if(!Fs(o["@index"])||o["@index"].indexOf("@")===0)throw new xt(`Invalid JSON-LD syntax; @index must expand to an IRI: "${o["@index"]}" on term "${n}".`,"jsonld.SyntaxError",{code:"invalid term definition",context:t});c["@index"]=o["@index"]}if("@context"in o)c["@context"]=o["@context"];if("@language"in o&&!("@type"in o)){let f=o["@language"];if(f!==null&&!Fs(f))throw new xt("Invalid JSON-LD syntax; @context @language value must be a string or null.","jsonld.SyntaxError",{code:"invalid language mapping",context:t});if(f!==null)f=f.toLowerCase();c["@language"]=f}if("@prefix"in o){if(n.match(/:|\//))throw new xt("Invalid JSON-LD syntax; @context @prefix used on a compact IRI term","jsonld.SyntaxError",{code:"invalid term definition",context:t});if(Mn.isKeyword(c["@id"]))throw new xt("Invalid JSON-LD syntax; keywords may not be used as prefixes","jsonld.SyntaxError",{code:"invalid term definition",context:t});if(typeof o["@prefix"]==="boolean")c._prefix=o["@prefix"]===!0;else throw new xt("Invalid JSON-LD syntax; @context value for @prefix must be boolean","jsonld.SyntaxError",{code:"invalid @prefix value",context:t})}if("@direction"in o){let f=o["@direction"];if(f!==null&&f!=="ltr"&&f!=="rtl")throw new xt('Invalid JSON-LD syntax; @direction value must be null, "ltr", or "rtl".',"jsonld.SyntaxError",{code:"invalid base direction",context:t});c["@direction"]=f}if("@nest"in o){let f=o["@nest"];if(!Fs(f)||f!=="@nest"&&f.indexOf("@")===0)throw new xt("Invalid JSON-LD syntax; @context @nest value must be a string which is not a keyword other than @nest.","jsonld.SyntaxError",{code:"invalid @nest value",context:t});c["@nest"]=f}let d=c["@id"];if(d==="@context"||d==="@preserve")throw new xt("Invalid JSON-LD syntax; @context and @preserve cannot be aliased.","jsonld.SyntaxError",{code:"invalid keyword alias",context:t});if(a&&a.protected&&!s){if(e.protected[n]=!0,c.protected=!0,!IF(a,c))throw new xt("Invalid JSON-LD syntax; tried to redefine a protected term.","jsonld.SyntaxError",{code:"protected term redefinition",context:t,term:n})}};Mn.expandIri=(e,t,n,r)=>Jy(e,t,n,void 0,void 0,r);function Jy(e,t,n,r,i,s){if(t===null||!Fs(t)||Mn.isKeyword(t))return t;if(t.match(jS))return null;if(r&&r.hasOwnProperty(t)&&i.get(t)!==!0)Mn.createTermDefinition({activeCtx:e,localCtx:r,term:t,defined:i,options:s});if(n=n||{},n.vocab){let a=e.mappings.get(t);if(a===null)return null;if(mp(a)&&"@id"in a)return a["@id"]}let o=t.indexOf(":");if(o>0){let a=t.substr(0,o),l=t.substr(o+1);if(a==="_"||l.indexOf("//")===0)return t;if(r&&r.hasOwnProperty(a))Mn.createTermDefinition({activeCtx:e,localCtx:r,term:a,defined:i,options:s});let c=e.mappings.get(a);if(c&&c._prefix)return c["@id"]+l;if(yf(t))return t}if(n.vocab&&"@vocab"in e)t=e["@vocab"]+t;else if(n.base){let a,l;if("@base"in e)if(e["@base"])l=Xv(s.base,e["@base"]),a=Xv(l,t);else l=e["@base"],a=t;else l=s.base,a=Xv(s.base,t);t=a}return t}Mn.getInitialContext=(e)=>{let t=JSON.stringify({processingMode:e.processingMode}),n=RS.get(t);if(n)return n;let r={processingMode:e.processingMode,mappings:new Map,inverse:null,getInverse:i,clone:a,revertToPreviousContext:l,protected:{}};if(RS.size===1e4)RS.clear();return RS.set(t,r),r;function i(){let c=this;if(c.inverse)return c.inverse;let u=c.inverse={},p=c.fastCurieMap={},d={},f=(c["@language"]||"@none").toLowerCase(),m=c["@direction"],y=c.mappings,h=[...y.keys()].sort(KBe);for(let b of h){let g=y.get(b);if(g===null)continue;let x=g["@container"]||"@none";if(x=[].concat(x).sort().join(""),g["@id"]===null)continue;let v=voe(g["@id"]);for(let D of v){let T=u[D],N=Mn.isKeyword(D);if(!T){if(u[D]=T={},!N&&!g._termHasColon){d[D]=[b];let O={iri:D,terms:d[D]};if(D[0]in p)p[D[0]].push(O);else p[D[0]]=[O]}}else if(!N&&!g._termHasColon)d[D].push(b);if(!T[x])T[x]={"@language":{},"@type":{},"@any":{}};if(T=T[x],o(b,T["@any"],"@none"),g.reverse)o(b,T["@type"],"@reverse");else if(g["@type"]==="@none")o(b,T["@any"],"@none"),o(b,T["@language"],"@none"),o(b,T["@type"],"@none");else if("@type"in g)o(b,T["@type"],g["@type"]);else if("@language"in g&&"@direction"in g){let O=g["@language"],C=g["@direction"];if(O&&C)o(b,T["@language"],`${O}_${C}`.toLowerCase());else if(O)o(b,T["@language"],O.toLowerCase());else if(C)o(b,T["@language"],`_${C}`);else o(b,T["@language"],"@null")}else if("@language"in g)o(b,T["@language"],(g["@language"]||"@null").toLowerCase());else if("@direction"in g)if(g["@direction"])o(b,T["@language"],`_${g["@direction"]}`);else o(b,T["@language"],"@none");else if(m)o(b,T["@language"],`_${m}`),o(b,T["@language"],"@none"),o(b,T["@type"],"@none");else o(b,T["@language"],f),o(b,T["@language"],"@none"),o(b,T["@type"],"@none")}}for(let b in p)s(p,b,1);return u}function s(c,u,p){let d=c[u],f=c[u]={},m,y;for(let h of d){if(m=h.iri,p>=m.length)y="";else y=m[p];if(y in f)f[y].push(h);else f[y]=[h]}for(let h in f){if(h==="")continue;s(f,h,p+1)}}function o(c,u,p){if(!u.hasOwnProperty(p))u[p]=c}function a(){let c={};if(c.mappings=goe.clone(this.mappings),c.clone=this.clone,c.inverse=null,c.getInverse=this.getInverse,c.protected=goe.clone(this.protected),this.previousContext)c.previousContext=this.previousContext.clone();if(c.revertToPreviousContext=this.revertToPreviousContext,"@base"in this)c["@base"]=this["@base"];if("@language"in this)c["@language"]=this["@language"];if("@vocab"in this)c["@vocab"]=this["@vocab"];return c}function l(){if(!this.previousContext)return this;return this.previousContext.clone()}};Mn.getContextValue=(e,t,n)=>{if(t===null){if(n==="@context")return;return null}if(e.mappings.has(t)){let r=e.mappings.get(t);if(UBe(n))return r;if(r.hasOwnProperty(n))return r[n]}if(n==="@language"&&n in e)return e[n];if(n==="@direction"&&n in e)return e[n];if(n==="@context")return;return null};Mn.processingMode=(e,t)=>{if(t.toString()>="1.1")return!e.processingMode||e.processingMode>="json-ld-"+t.toString();else return e.processingMode==="json-ld-1.0"};Mn.isKeyword=(e)=>{if(!Fs(e)||e[0]!=="@")return!1;switch(e){case"@base":case"@container":case"@context":case"@default":case"@direction":case"@embed":case"@explicit":case"@graph":case"@id":case"@included":case"@index":case"@json":case"@language":case"@list":case"@nest":case"@none":case"@omitDefault":case"@prefix":case"@preserve":case"@protected":case"@requireAll":case"@reverse":case"@set":case"@type":case"@value":case"@version":case"@vocab":return!0}return!1};function IF(e,t){if(!(e&&typeof e==="object")||!(t&&typeof t==="object"))return e===t;let n=Array.isArray(e);if(n!==Array.isArray(t))return!1;if(n){if(e.length!==t.length)return!1;for(let s=0;s{if(n===null||n===void 0)return null;if(t==="@default")r=Object.assign({},r,{isFrame:!1});if(!co(n)&&!ta(n)){if(!i&&(t===null||Ir(e,t,{vocab:!0},r)==="@graph")){if(r.eventHandler)na({event:{type:["JsonLdEvent"],code:"free-floating scalar",level:"warning",message:"Dropping free-floating scalar not in a list.",details:{value:n}},options:r});return null}return Toe({activeCtx:e,activeProperty:t,value:n,options:r})}if(co(n)){let m=[],y=Cs(e,t,"@container")||[];i=i||y.includes("@list");for(let h=0;h1?h.slice().sort():h:[h];for(let g of b){let x=Cs(o,g,"@context");if(!Zv(x))e=await Hy({activeCtx:e,localCtx:x,options:r,propagate:!1})}}let d={};await Doe({activeCtx:e,activeProperty:t,expandedActiveProperty:a,element:n,expandedParent:d,options:r,insideList:i,typeKey:p,typeScopedContext:o}),c=Object.keys(d);let f=c.length;if("@value"in d){if("@type"in d&&(("@language"in d)||("@direction"in d)))throw new Wn('Invalid JSON-LD syntax; an element containing "@value" may not contain both "@type" and either "@language" or "@direction".',"jsonld.SyntaxError",{code:"invalid value object",element:d});let m=f-1;if("@type"in d)m-=1;if("@index"in d)m-=1;if("@language"in d)m-=1;if("@direction"in d)m-=1;if(m!==0)throw new Wn('Invalid JSON-LD syntax; an element containing "@value" may only have an "@index" property and either "@type" or either or both "@language" or "@direction".',"jsonld.SyntaxError",{code:"invalid value object",element:d});let y=d["@value"]===null?[]:La(d["@value"]),h=zBe(d,"@type");if(FS(e,1.1)&&h.includes("@json")&&h.length===1);else if(y.length===0){if(r.eventHandler)na({event:{type:["JsonLdEvent"],code:"null @value value",level:"warning",message:"Dropping null @value value.",details:{value:d}},options:r});d=null}else if(!y.every((b)=>qi(b)||jF(b))&&"@language"in d)throw new Wn("Invalid JSON-LD syntax; only strings may be language-tagged.","jsonld.SyntaxError",{code:"invalid language-tagged value",element:d});else if(!h.every((b)=>CS(b)&&!(qi(b)&&b.indexOf("_:")===0)||jF(b)))throw new Wn('Invalid JSON-LD syntax; an element containing "@value" and "@type" must have an absolute IRI for the value of "@type".',"jsonld.SyntaxError",{code:"invalid typed value",element:d})}else if("@type"in d&&!co(d["@type"]))d["@type"]=[d["@type"]];else if("@set"in d||"@list"in d){if(f>1&&!(f===2&&("@index"in d)))throw new Wn('Invalid JSON-LD syntax; if an element has the property "@set" or "@list", then it can have at most one other property that is "@index".',"jsonld.SyntaxError",{code:"invalid set or list object",element:d});if("@set"in d)d=d["@set"],c=Object.keys(d),f=c.length}else if(f===1&&"@language"in d){if(r.eventHandler)na({event:{type:["JsonLdEvent"],code:"object with only @language",level:"warning",message:"Dropping object with only @language.",details:{value:d}},options:r});d=null}if(ta(d)&&!r.keepFreeFloatingNodes&&!i&&(t===null||a==="@graph"||(Cs(e,t,"@container")||[]).includes("@graph")))d=woe({value:d,count:f,options:r});return d};function woe({value:e,count:t,options:n}){if(t===0||"@value"in e||"@list"in e||t===1&&"@id"in e){if(n.eventHandler){let r,i;if(t===0)r="empty object",i="Dropping empty object.";else if("@value"in e)r="object with only @value",i="Dropping object with only @value.";else if("@list"in e)r="object with only @list",i="Dropping object with only @list.";else if(t===1&&"@id"in e)r="object with only @id",i="Dropping object with only @id.";na({event:{type:["JsonLdEvent"],code:r,level:"warning",message:i,details:{value:e}},options:n})}return null}return e}async function Doe({activeCtx:e,activeProperty:t,expandedActiveProperty:n,element:r,expandedParent:i,options:s={},insideList:o,typeKey:a,typeScopedContext:l}){let c=Object.keys(r).sort(),u=[],p,d=r[a]&&Ir(e,co(r[a])?r[a][0]:r[a],{vocab:!0},{...s,typeExpansion:!0})==="@json";for(let f of c){let m=r[f],y;if(f==="@context")continue;let h=Ir(e,f,{vocab:!0},s);if(s.isFrame&&["@embed","@explicit","@requireAll","@omitDefault"].includes(h)){let v=co(m)?m:[m];if(v.length!==1||(h==="@embed"?typeof v[0]!=="string"&&typeof v[0]!=="boolean":typeof v[0]!=="boolean"))throw new Wn("Invalid frame flag value.","jsonld.SyntaxError",{code:h==="@embed"?"invalid @embed value":"invalid frame",value:m})}if(h===null||!(CS(h)||CF(h))){if(s.eventHandler)na({event:{type:["JsonLdEvent"],code:"invalid property",level:"warning",message:"Dropping property that did not expand into an absolute IRI or keyword.",details:{property:f,expandedProperty:h}},options:s});continue}if(CF(h)){if(n==="@reverse")throw new Wn("Invalid JSON-LD syntax; a keyword cannot be used as a @reverse property.","jsonld.SyntaxError",{code:"invalid reverse property map",value:m});if(h in i&&h!=="@included"&&h!=="@type")throw new Wn("Invalid JSON-LD syntax; colliding keywords detected.","jsonld.SyntaxError",{code:"colliding keywords",keyword:h})}if(h==="@id"){if(!qi(m)){if(!s.isFrame)throw new Wn('Invalid JSON-LD syntax; "@id" value must a string.',"jsonld.SyntaxError",{code:"invalid @id value",value:m});if(ta(m)){if(!jF(m))throw new Wn('Invalid JSON-LD syntax; "@id" value an empty object or array of strings, if framing',"jsonld.SyntaxError",{code:"invalid @id value",value:m})}else if(co(m)){if(!m.every((v)=>qi(v)))throw new Wn('Invalid JSON-LD syntax; "@id" value an empty object or array of strings, if framing',"jsonld.SyntaxError",{code:"invalid @id value",value:m})}else throw new Wn('Invalid JSON-LD syntax; "@id" value an empty object or array of strings, if framing',"jsonld.SyntaxError",{code:"invalid @id value",value:m})}lo(i,"@id",La(m).map((v)=>{if(qi(v)){let D=Ir(e,v,{base:!0},s);if(s.eventHandler){if(D===null)if(v===null)na({event:{type:["JsonLdEvent"],code:"null @id value",level:"warning",message:"Null @id found.",details:{id:v}},options:s});else na({event:{type:["JsonLdEvent"],code:"reserved @id value",level:"warning",message:"Reserved @id found.",details:{id:v}},options:s});else if(!CS(D))na({event:{type:["JsonLdEvent"],code:"relative @id reference",level:"warning",message:"Relative @id reference found.",details:{id:v,expandedId:D}},options:s})}return D}return v}),{propertyIsArray:s.isFrame});continue}if(h==="@type"){if(ta(m))m=Object.fromEntries(Object.entries(m).map(([v,D])=>[Ir(l,v,{vocab:!0}),La(D).map((T)=>Ir(l,T,{base:!0,vocab:!0},{...s,typeExpansion:!0}))]));WBe(m,s.isFrame),lo(i,"@type",La(m).map((v)=>{if(qi(v)){let D=Ir(l,v,{base:!0,vocab:!0},{...s,typeExpansion:!0});if(D!=="@json"&&!CS(D)){if(s.eventHandler)na({event:{type:["JsonLdEvent"],code:"relative @type reference",level:"warning",message:"Relative @type reference found.",details:{type:v}},options:s})}return D}return v}),{propertyIsArray:!!s.isFrame});continue}if(h==="@included"&&FS(e,1.1)){let v=La(await hp.expand({activeCtx:e,activeProperty:t,element:m,options:s}));if(!v.every((D)=>GBe(D)))throw new Wn("Invalid JSON-LD syntax; values of @included must expand to node objects.","jsonld.SyntaxError",{code:"invalid @included value",value:m});lo(i,"@included",v,{propertyIsArray:!0});continue}if(h==="@graph"&&!(ta(m)||co(m)))throw new Wn('Invalid JSON-LD syntax; "@graph" value must not be an object or an array.',"jsonld.SyntaxError",{code:"invalid @graph value",value:m});if(h==="@value"){if(p=m,d&&FS(e,1.1))i["@value"]=m;else lo(i,"@value",m,{propertyIsArray:s.isFrame});continue}if(h==="@language"){if(m===null)continue;if(!qi(m)&&!s.isFrame)throw new Wn('Invalid JSON-LD syntax; "@language" value must be a string.',"jsonld.SyntaxError",{code:"invalid language-tagged string",value:m});m=La(m).map((v)=>qi(v)?v.toLowerCase():v);for(let v of m)if(qi(v)&&!v.match(xoe)){if(s.eventHandler)na({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:v}},options:s})}lo(i,"@language",m,{propertyIsArray:s.isFrame});continue}if(h==="@direction"){if(!qi(m)&&!s.isFrame)throw new Wn('Invalid JSON-LD syntax; "@direction" value must be a string.',"jsonld.SyntaxError",{code:"invalid base direction",value:m});m=La(m);for(let v of m)if(qi(v)&&v!=="ltr"&&v!=="rtl")throw new Wn('Invalid JSON-LD syntax; "@direction" must be "ltr" or "rtl".',"jsonld.SyntaxError",{code:"invalid base direction",value:m});lo(i,"@direction",m,{propertyIsArray:s.isFrame});continue}if(h==="@index"){if(!qi(m))throw new Wn('Invalid JSON-LD syntax; "@index" value must be a string.',"jsonld.SyntaxError",{code:"invalid @index value",value:m});lo(i,"@index",m);continue}if(h==="@reverse"){if(!ta(m))throw new Wn('Invalid JSON-LD syntax; "@reverse" value must be an object.',"jsonld.SyntaxError",{code:"invalid @reverse value",value:m});if(y=await hp.expand({activeCtx:e,activeProperty:"@reverse",element:m,options:s}),"@reverse"in y)for(let D in y["@reverse"])lo(i,D,y["@reverse"][D],{propertyIsArray:!0});let v=i["@reverse"]||null;for(let D in y){if(D==="@reverse")continue;if(v===null)v=i["@reverse"]={};lo(v,D,[],{propertyIsArray:!0});let T=y[D];for(let N=0;Nv==="@id"||v==="@index")){if(y=La(y),!s.isFrame)y=y.filter((v)=>{let D=Object.keys(v).length;return woe({value:v,count:D,options:s})!==null});if(y.length===0)continue;y=y.map((v)=>({"@graph":La(v)}))}if(b.mappings.has(f)&&b.mappings.get(f).reverse){let v=i["@reverse"]=i["@reverse"]||{};y=La(y);for(let D=0;DIr(m,g,{vocab:!0},s)==="@value"))throw new Wn("Invalid JSON-LD syntax; nested value must be a node object.","jsonld.SyntaxError",{code:"invalid @nest value",value:b});await Doe({activeCtx:m,activeProperty:t,expandedActiveProperty:n,element:b,expandedParent:i,options:s,insideList:o,typeScopedContext:l,typeKey:a})}}}function Toe({activeCtx:e,activeProperty:t,value:n,options:r}){if(n===null||n===void 0)return null;let i=Ir(e,t,{vocab:!0},r);if(i==="@id")return Ir(e,n,{base:!0},r);else if(i==="@type")return Ir(e,n,{vocab:!0,base:!0},{...r,typeExpansion:!0});let s=Cs(e,t,"@type");if((s==="@id"||i==="@graph")&&qi(n)){let a=Ir(e,n,{base:!0},r);if(a===null&&n.match(HBe)){if(r.eventHandler)na({event:{type:["JsonLdEvent"],code:"reserved @id value",level:"warning",message:"Reserved @id found.",details:{id:t}},options:r})}return{"@id":a}}if(s==="@vocab"&&qi(n))return{"@id":Ir(e,n,{vocab:!0,base:!0},r)};if(CF(i))return n;let o={};if(s&&!["@id","@vocab","@none"].includes(s))o["@type"]=s;else if(qi(n)){let a=Cs(e,t,"@language");if(a!==null)o["@language"]=a;let l=Cs(e,t,"@direction");if(l!==null)o["@direction"]=l}if(!["boolean","number","string"].includes(typeof n)&&!(n&&Object.isFrozen(n)&&Object.prototype.toString.call(n)==="[object Number]"&&n[Symbol.for("umf.jsonld.exact-number")]===!0))n=n.toString();return o["@value"]=n,o}function QBe(e,t,n,r){let i=[],s=Object.keys(t).sort();for(let o of s){let a=Ir(e,o,{vocab:!0},r),l=t[o];if(!co(l))l=[l];for(let c of l){if(c===null)continue;if(!qi(c))throw new Wn("Invalid JSON-LD syntax; language map values must be strings.","jsonld.SyntaxError",{code:"invalid language map value",languageMap:t});let u={"@value":c};if(a!=="@none"){if(!o.match(xoe)){if(r.eventHandler)na({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:o}},options:r})}u["@language"]=o.toLowerCase()}if(n)u["@direction"]=n;i.push(u)}}return i}async function RF({activeCtx:e,options:t,activeProperty:n,value:r,asGraph:i,indexKey:s,propertyIndex:o}){let a=[],l=Object.keys(r).sort(),c=s==="@type";for(let u of l){if(c){let f=Cs(e,u,"@context");if(!Zv(f))e=await Hy({activeCtx:e,localCtx:f,propagate:!1,options:t})}let p=r[u];if(!co(p))p=[p];p=await hp.expand({activeCtx:e,activeProperty:n,element:p,options:t,insideList:!1,insideIndex:!0});let d;if(o)if(u==="@none")d="@none";else d=Toe({activeCtx:e,activeProperty:s,value:u,options:t});else d=Ir(e,u,{vocab:!0},t);if(s==="@id")u=Ir(e,u,{base:!0},t);else if(c)u=d;for(let f of p){if(i&&!JBe(f))f={"@graph":[f]};if(s==="@type")if(d==="@none");else if(f["@type"])f["@type"]=[u].concat(f["@type"]);else f["@type"]=[u];else if(FF(f)&&!["@language","@type","@index"].includes(s))throw new Wn(`Invalid JSON-LD syntax; Attempt to add illegal key to value object: "${s}".`,"jsonld.SyntaxError",{code:"invalid value object",value:f});else if(o){if(d!=="@none")lo(f,o,d,{propertyIsArray:!0,prependValue:!0})}else if(d!=="@none"&&!(s in f))f[s]=u;a.push(f)}}return a}});var e_=z(function(EBt,Noe){var{isKeyword:koe}=yp(),Nl=El(),MF=js(),kl=oo(),YBe=so(),rs={};Noe.exports=rs;rs.createMergedNodeMap=(e,t)=>{t=t||{};let n=t.issuer||new kl.IdentifierIssuer("_:b"),r={"@default":{}};return rs.createNodeMap(e,r,"@default",n),rs.mergeNodeMaps(r)};rs.createNodeMap=(e,t,n,r,i,s)=>{if(MF.isArray(e)){for(let c of e)rs.createNodeMap(c,t,n,r,void 0,s);return}if(!MF.isObject(e)){if(s)s.push(e);return}if(Nl.isValue(e)){if("@type"in e){let c=e["@type"];if(c.indexOf("_:")===0)e["@type"]=c=r.getId(c)}if(s)s.push(e);return}else if(s&&Nl.isList(e)){let c=[];rs.createNodeMap(e["@list"],t,n,r,i,c),s.push({"@list":c});return}if("@type"in e){let c=e["@type"];for(let u of c)if(u.indexOf("_:")===0)r.getId(u)}if(MF.isUndefined(i))i=Nl.isBlankNode(e)?r.getId(e["@id"]):e["@id"];if(s)s.push({"@id":i});let o=t[n],a=o[i]=o[i]||{};a["@id"]=i;let l=Object.keys(e).sort();for(let c of l){if(c==="@id")continue;if(c==="@reverse"){let p={"@id":i},d=e["@reverse"];for(let f in d){let m=d[f];for(let y of m){let h=y["@id"];if(Nl.isBlankNode(y))h=r.getId(h);rs.createNodeMap(y,t,n,r,h),kl.addValue(o[h],f,p,{propertyIsArray:!0,allowDuplicate:!1})}}continue}if(c==="@graph"){if(!(i in t))t[i]={};rs.createNodeMap(e[c],t,i,r);continue}if(c==="@included"){rs.createNodeMap(e[c],t,n,r);continue}if(c!=="@type"&&koe(c)){if(c==="@index"&&c in a&&(e[c]!==a[c]||e[c]["@id"]!==a[c]["@id"]))throw new YBe("Invalid JSON-LD syntax; conflicting @index property detected.","jsonld.SyntaxError",{code:"conflicting indexes",subject:a});a[c]=e[c];continue}let u=e[c];if(c.indexOf("_:")===0)c=r.getId(c);if(u.length===0){kl.addValue(a,c,[],{propertyIsArray:!0});continue}for(let p of u){if(c==="@type")p=p.indexOf("_:")===0?r.getId(p):p;if(Nl.isSubject(p)||Nl.isSubjectReference(p)){if("@id"in p&&!p["@id"])continue;let d=Nl.isBlankNode(p)?r.getId(p["@id"]):p["@id"];kl.addValue(a,c,{"@id":d},{propertyIsArray:!0,allowDuplicate:!1}),rs.createNodeMap(p,t,n,r,d)}else if(Nl.isValue(p))kl.addValue(a,c,p,{propertyIsArray:!0,allowDuplicate:!1});else if(Nl.isList(p)){let d=[];rs.createNodeMap(p["@list"],t,n,r,i,d),p={"@list":d},kl.addValue(a,c,p,{propertyIsArray:!0,allowDuplicate:!1})}else rs.createNodeMap(p,t,n,r,i),kl.addValue(a,c,p,{propertyIsArray:!0,allowDuplicate:!1})}}};rs.mergeNodeMapGraphs=(e)=>{let t={};for(let n of Object.keys(e).sort())for(let r of Object.keys(e[n]).sort()){let i=e[n][r];if(!(r in t))t[r]={"@id":r};let s=t[r];for(let o of Object.keys(i).sort())if(koe(o)&&o!=="@type")s[o]=kl.clone(i[o]);else for(let a of i[o])kl.addValue(s,o,kl.clone(a),{propertyIsArray:!0,allowDuplicate:!1})}return t};rs.mergeNodeMaps=(e)=>{let t=e["@default"],n=Object.keys(e).sort();for(let r of n){if(r==="@default")continue;let i=e[r],s=t[r];if(!s)t[r]=s={"@id":r,"@graph":[]};else if(!("@graph"in s))s["@graph"]=[];let o=s["@graph"];for(let a of Object.keys(i).sort()){let l=i[a];if(!Nl.isSubjectReference(l))o.push(l)}}return t}});var LF=z(function(kBt,Poe){var{isSubjectReference:XBe}=El(),{createMergedNodeMap:ZBe}=e_(),Ooe={};Poe.exports=Ooe;Ooe.flatten=(e)=>{let t=ZBe(e),n=[],r=Object.keys(t).sort();for(let i=0;i{let{useRdfType:n=!1,useNativeTypes:r=!1,rdfDirection:i=null}=t,s={},o={"@default":s},a={};if(i){if(!["compound-literal","i18n-datatype"].includes(i))throw new t_("Unknown rdfDirection value.","jsonld.InvalidRdfDirection",{value:i})}for(let u of e){let p=u.graph.termType==="DefaultGraph"?"@default":u.graph.value;if(!(p in o))o[p]={};if(p!=="@default"&&!(p in s))s[p]={"@id":p};let d=o[p],f=US(u.subject),m=US(u.predicate),y=u.object;if(!(f in d))d[f]={"@id":f};let h=d[f],b=US(y),g=!!b;if(g&&!(b in d))d[b]={"@id":b};if(m===t8e&&!n&&g){$oe(h,"@type",b,{propertyIsArray:!0});continue}let x=r8e(y,r,i,t);if($oe(h,m,x,{propertyIsArray:!0}),g)if(b===qS){let v=d[b];if(!("usages"in v))v.usages=[];v.usages.push({node:h,property:m,value:x})}else if(b in a)a[b]=!1;else a[b]={node:h,property:m,value:x}}for(let u in o){let p=o[u];if(i==="compound-literal")for(let[m,y]of Object.entries(p)){if(!m.startsWith("_:")||!("http://www.w3.org/1999/02/22-rdf-syntax-ns#direction"in y)||!hf.isObject(a[m]))continue;let h=(D,T=!1)=>{let N=y["http://www.w3.org/1999/02/22-rdf-syntax-ns#"+D];if(T&&N===void 0)return;if(!Array.isArray(N)||N.length!==1||Object.keys(N[0]).length!==1||typeof N[0]["@value"]!=="string")throw new t_("Invalid compound literal property.","jsonld.InvalidCompoundLiteral",{code:"invalid compound literal",property:D});return N[0]["@value"]},b=h("value"),g=h("language",!0),x=h("direction");if(g!==void 0&&!BF.test(g))throw new t_("Invalid compound literal language.","jsonld.InvalidCompoundLiteral",{code:"invalid language-tagged string"});if(!["ltr","rtl"].includes(x))throw new t_("Invalid compound literal direction.","jsonld.InvalidCompoundLiteral",{code:"invalid base direction"});if(Object.keys(y).some((D)=>!["@id","http://www.w3.org/1999/02/22-rdf-syntax-ns#value","http://www.w3.org/1999/02/22-rdf-syntax-ns#language","http://www.w3.org/1999/02/22-rdf-syntax-ns#direction"].includes(D))&&t.eventHandler)VF({event:{type:["JsonLdEvent"],code:"compound literal additional properties",level:"warning",message:"Compound literal conversion omits additional node properties.",details:{id:m}},options:t});let v=a[m];for(let D of v.node[v.property]){if(D["@id"]!==m)continue;if(delete D["@id"],D["@value"]=b,D["@direction"]=x,g!==void 0)D["@language"]=g}delete p[m]}if(!(qS in p))continue;let d=p[qS];if(!d.usages)continue;for(let f of d.usages){let m=f.node,y=f.property,h=f.value,b=[],g=[],x=Object.keys(m).length;while(y===LS&&hf.isObject(a[m["@id"]])&&hf.isArray(m[MS])&&m[MS].length===1&&hf.isArray(m[LS])&&m[LS].length===1&&(x===3||x===4&&hf.isArray(m["@type"])&&m["@type"].length===1&&m["@type"][0]===e8e))if(b.push(m[MS][0]),g.push(m["@id"]),f=a[m["@id"]],m=f.node,y=f.property,h=f.value,x=Object.keys(m).length,!UF.isBlankNode(m))break;if(t.processingMode==="json-ld-1.0"&&y===MS){if(h["@id"]===qS)continue;h=p[h["@id"]][LS][0],b.pop(),g.pop()}delete h["@id"],h["@list"]=b.reverse();for(let v of g)delete p[v]}delete d.usages}let l=[],c=Object.keys(s).sort();for(let u of c){let p=s[u];if(u in o){let d=p["@graph"]=[],f=o[u],m=Object.keys(f).sort();for(let y of m){let h=f[y];if(!UF.isSubjectReference(h))d.push(h)}}if(!UF.isSubjectReference(p))l.push(p)}return l};function r8e(e,t,n,r){let i=US(e);if(i)return{"@id":i};if(!e.language&&r.umfRdfLiteral){let o=r.umfRdfLiteral(e,t);if(o!==void 0)return o}let s={"@value":e.value};if(e.language){if(!e.language.match(BF)){if(r.eventHandler)VF({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:e.language}},options:r})}s["@language"]=e.language}else{let o=e.datatype.value;if(!o)o=qF;if(o===n8e){o="@json";try{s["@value"]=JSON.parse(s["@value"])}catch(a){throw new t_("JSON literal could not be parsed.","jsonld.InvalidJsonLiteral",{code:"invalid JSON literal",value:s["@value"],cause:a})}}if(t&&[Ioe,Aoe,Roe,qF].includes(o))if(o===Ioe)if(s["@value"]==="true"||s["@value"]==="1")s["@value"]=!0;else if(s["@value"]==="false"||s["@value"]==="0")s["@value"]=!1;else s["@type"]=o;else if(o===Roe)if(hf.isNumeric(s["@value"])){let a=parseInt(s["@value"],10);if(a.toFixed(0)===s["@value"])s["@value"]=a}else s["@type"]=o;else if(o===Aoe)if(hf.isNumeric(s["@value"]))s["@value"]=parseFloat(s["@value"]);else s["@type"]=o;else s["@type"]=o;else if(n==="i18n-datatype"&&o.startsWith("https://www.w3.org/ns/i18n#")){let[,a,l]=o.split(/[#_]/);if(a.length>0){if(s["@language"]=a,!a.match(BF)){if(r.eventHandler)VF({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:a}},options:r})}}s["@direction"]=l}else if(o!==qF)s["@type"]=o}return s}function US(e){if(e.termType==="NamedNode")return e.value;else if(e.termType==="BlankNode")return"_:"+e.value;return null}});var Loe=z(function(OBt,Moe){Moe.exports=function e(t){if(typeof t==="number"&&isNaN(t))throw Error("NaN is not allowed");if(typeof t==="number"&&!isFinite(t))throw Error("Infinity is not allowed");if(t===null||typeof t!=="object")return JSON.stringify(t);if(t.toJSON instanceof Function)return e(t.toJSON());if(Array.isArray(t))return`[${t.reduce((i,s,o)=>`${i}${o===0?"":","}${e(s===void 0||typeof s==="symbol"?null:s)}`,"")}]`;return`{${Object.keys(t).sort().reduce((r,i)=>{if(t[i]===void 0||typeof t[i]==="symbol")return r;let s=r.length===0?"":",";return`${r}${s}${e(i)}:${e(t[i])}`},"")}}`}});var Joe=z(function(PBt,Koe){var{createNodeMap:i8e}=e_(),{isKeyword:s8e}=yp(),Boe=El(),o8e=Loe(),a8e=so(),BS=js(),l8e=oo(),{handleEvent:gf}=Ky(),{RDF_FIRST:c8e,RDF_REST:u8e,RDF_NIL:p8e,RDF_TYPE:d8e,RDF_JSON_LITERAL:f8e,RDF_LANGSTRING:m8e,XSD_BOOLEAN:y8e,XSD_DOUBLE:qoe,XSD_INTEGER:h8e,XSD_STRING:Uoe}=PS(),{isAbsolute:VS}=jc(),Voe={};Koe.exports=Voe;Voe.toRDF=(e,t)=>{let n=new l8e.IdentifierIssuer("_:b"),r={"@default":{}};i8e(e,r,"@default",n);let i=[],s=Object.keys(r).sort();for(let o of s){let a;if(o==="@default")a={termType:"DefaultGraph",value:""};else if(VS(o))a=zy(o);else{if(t.eventHandler)gf({event:{type:["JsonLdEvent"],code:"relative graph reference",level:"warning",message:"Relative graph reference found.",details:{graph:o}},options:t});continue}if(t.umfRdfTerm&&!t.umfRdfTerm(a))continue;g8e(i,r[o],a,n,t)}return i.filter((o)=>o.object!==null)};function g8e(e,t,n,r,i){let s=Object.keys(t).sort();for(let o of s){let a=t[o],l=Object.keys(a).sort();for(let c of l){let u=a[c];if(c==="@type")c=d8e;else if(s8e(c))continue;for(let p of u){let d=zy(o);if(!VS(o)){if(i.eventHandler)gf({event:{type:["JsonLdEvent"],code:"relative subject reference",level:"warning",message:"Relative subject reference found.",details:{subject:o}},options:i});continue}if(i.umfRdfTerm&&!i.umfRdfTerm(d))continue;let f=zy(c);if(!VS(c)){if(i.eventHandler)gf({event:{type:["JsonLdEvent"],code:"relative predicate reference",level:"warning",message:"Relative predicate reference found.",details:{predicate:c}},options:i});continue}if(f.termType==="BlankNode"&&!i.produceGeneralizedRdf){if(i.eventHandler)gf({event:{type:["JsonLdEvent"],code:"blank node predicate",level:"warning",message:"Dropping blank node predicate.",details:{property:r.getOldIds().find((y)=>r.getId(y)===c)}},options:i});continue}if(i.umfRdfTerm&&!i.umfRdfTerm(f))continue;let m=KF(p,r,e,n,i.rdfDirection,i);if(m)e.push({subject:d,predicate:f,object:m,graph:n})}}}}function b8e(e,t,n,r,i,s){let o={termType:"NamedNode",value:c8e},a={termType:"NamedNode",value:u8e},l={termType:"NamedNode",value:p8e},c=e.pop(),u=c?{termType:"BlankNode",value:t.getId().slice(2)}:l,p=u;for(let d of e){let f=KF(d,t,n,r,i,s),m={termType:"BlankNode",value:t.getId().slice(2)};n.push({subject:p,predicate:o,object:f,graph:r}),n.push({subject:p,predicate:a,object:m,graph:r}),p=m}if(c){let d=KF(c,t,n,r,i,s);n.push({subject:p,predicate:o,object:d,graph:r}),n.push({subject:p,predicate:a,object:l,graph:r})}return u}function KF(e,t,n,r,i,s){let o;if(Boe.isValue(e)){o={termType:"Literal",value:void 0,datatype:{termType:"NamedNode"}};let a=e["@value"],l=e["@type"]||null;if(s.umfRdfLanguage&&"@language"in e&&!s.umfRdfLanguage(e["@language"]))return null;if(l&&l!=="@json"&&s.umfRdfTerm&&!s.umfRdfTerm({termType:"NamedNode",value:l}))return null;if(l==="@json")o.value=o8e(a),o.datatype.value=f8e;else if(BS.isBoolean(a))o.value=a.toString(),o.datatype.value=l||y8e;else if(BS.isNumber(a)&&(a%1!==0||Math.abs(a)>=1000000000000000000000||l===qoe))o.value=a.toExponential(15).replace(/(\d)0*e\+?/,"$1E"),o.datatype.value=l||qoe;else if(BS.isNumber(a))o.value=a.toFixed(0),o.datatype.value=l||h8e;else if("@direction"in e&&i==="i18n-datatype"){let c=(e["@language"]||"").toLowerCase(),u=e["@direction"],p=`https://www.w3.org/ns/i18n#${c}_${u}`;o.datatype.value=p,o.value=a}else if("@direction"in e&&i==="compound-literal"){o=zy(t.getId());let c=[["value",a],["direction",e["@direction"]]];if("@language"in e)c.push(["language",e["@language"].toLowerCase()]);for(let[u,p]of c)n.push({subject:o,predicate:zy("http://www.w3.org/1999/02/22-rdf-syntax-ns#"+u),object:{termType:"Literal",value:p,datatype:{termType:"NamedNode",value:Uoe}},graph:r})}else if("@direction"in e&&i)throw new a8e("Unknown rdfDirection value.","jsonld.InvalidRdfDirection",{value:i});else if("@language"in e){if("@direction"in e&&!i){if(s.eventHandler)gf({event:{type:["JsonLdEvent"],code:"rdfDirection not set",level:"warning",message:"rdfDirection not set for @direction.",details:{object:o.value}},options:s})}o.value=a,o.datatype.value=l||m8e,o.language=e["@language"]}else{if("@direction"in e&&!i){if(s.eventHandler)gf({event:{type:["JsonLdEvent"],code:"rdfDirection not set",level:"warning",message:"rdfDirection not set for @direction.",details:{object:o.value}},options:s})}o.value=a,o.datatype.value=l||Uoe}}else if(Boe.isList(e)){let a=b8e(e["@list"],t,n,r,i,s);o={termType:a.termType,value:a.value}}else{let a=BS.isObject(e)?e["@id"]:e;o=zy(a)}if(o.termType==="NamedNode"&&!VS(o.value)){if(s.eventHandler)gf({event:{type:["JsonLdEvent"],code:"relative object reference",level:"warning",message:"Relative object reference found.",details:{object:o.value}},options:s});return null}if(s.umfRdfTerm&&!s.umfRdfTerm(o))return null;return o}function zy(e){if(e.startsWith("_:"))return{termType:"BlankNode",value:e.slice(2)};return{termType:"NamedNode",value:e}}});var Yoe=z(function($Bt,Qoe){var{isKeyword:JF}=yp(),ia=El(),En=js(),Jr=oo(),Goe=jc(),vf=so(),{createNodeMap:v8e,mergeNodeMapGraphs:_8e}=e_(),ra={};Qoe.exports=ra;ra.frameMergedOrDefault=(e,t,n)=>{GF(t,n);let r={options:n,embedded:!1,graph:"@default",graphMap:{"@default":{}},subjectStack:[],link:{},bnodeMap:{}},i=new Jr.IdentifierIssuer("_:b");if(v8e(e,r.graphMap,"@default",i),n.merged)r.graphMap["@merged"]=_8e(r.graphMap),r.graph="@merged";r.subjects=r.graphMap[r.graph];let s=[];if(ra.frame(r,Object.keys(r.subjects).sort(),t,s),n.pruneBlankNodeIdentifiers)n.bnodesToClear=Object.keys(r.bnodeMap).filter((o)=>r.bnodeMap[o].length===1);return n.link={},KS(s,n)};ra.frame=(e,t,n,r,i=null)=>{zF(n),n=n[0];let s=e.options,o={embed:n_(n,s,"embed"),explicit:n_(n,s,"explicit"),requireAll:n_(n,s,"requireAll")};if(!e.link.hasOwnProperty(e.graph))e.link[e.graph]={};let a=e.link[e.graph],l=w8e(e,t,n,o),c=Object.keys(l).sort();for(let u of c){let p=l[u];if(i===null)e.uniqueEmbeds={[e.graph]:{}};else e.uniqueEmbeds[e.graph]=e.uniqueEmbeds[e.graph]||{};if(o.embed==="@link"&&u in a){bf(r,i,a[u]);continue}let d={"@id":u};if(u.indexOf("_:")===0)Jr.addValue(e.bnodeMap,u,d,{propertyIsArray:!0});if(a[u]=d,(o.embed==="@first"||o.embed==="@last")&&e.is11)throw new vf("Invalid JSON-LD syntax; invalid value of @embed.","jsonld.SyntaxError",{code:"invalid @embed value",frame:n});if(!e.embedded&&e.uniqueEmbeds[e.graph].hasOwnProperty(u))continue;if(e.embedded&&(o.embed==="@never"||x8e(p,e.graph,e.subjectStack))){bf(r,i,d);continue}if(e.embedded&&(o.embed=="@first"||o.embed=="@once")&&e.uniqueEmbeds[e.graph].hasOwnProperty(u)){bf(r,i,d);continue}if(o.embed==="@last"){if(u in e.uniqueEmbeds[e.graph])D8e(e,u)}if(e.uniqueEmbeds[e.graph][u]={parent:r,property:i},e.subjectStack.push({subject:p,graph:e.graph}),u in e.graphMap){let f=!1,m=null;if(!("@graph"in n))f=e.graph!=="@merged",m={};else if(m=n["@graph"][0],f=!(u==="@merged"||u==="@default"),!En.isObject(m))m={};if(f)ra.frame({...e,graph:u,embedded:!1},Object.keys(e.graphMap[u]).sort(),[m],d,"@graph")}if("@included"in n)ra.frame({...e,embedded:!1},t,n["@included"],d,"@included");for(let f of Object.keys(p).sort()){if(JF(f)){if(d[f]=Jr.clone(p[f]),f==="@type"){for(let m of p["@type"])if(m.indexOf("_:")===0)Jr.addValue(e.bnodeMap,m,d,{propertyIsArray:!0})}continue}if(o.explicit&&!(f in n))continue;for(let m of p[f]){let y=f in n?n[f]:Hoe(o);if(ia.isList(m)){let h=n[f]&&n[f][0]&&n[f][0]["@list"]?n[f][0]["@list"]:Hoe(o),b={"@list":[]};bf(d,f,b);let g=m["@list"];for(let x of g)if(ia.isSubjectReference(x))ra.frame({...e,embedded:!0},[x["@id"]],h,b,"@list");else bf(b,"@list",Jr.clone(x))}else if(ia.isSubjectReference(m))ra.frame({...e,embedded:!0},[m["@id"]],y,d,f);else if(HF(y[0],m))bf(d,f,Jr.clone(m))}}for(let f of Object.keys(n).sort()){if(f==="@type"){if(!En.isObject(n[f][0])||!("@default"in n[f][0]))continue}else if(JF(f))continue;let m=n[f][0]||{};if(!n_(m,s,"omitDefault")&&!(f in d)){let h="@null";if("@default"in m)h=Jr.clone(m["@default"]);if(!En.isArray(h))h=[h];d[f]=[{"@preserve":h}]}}for(let f of Object.keys(n["@reverse"]||{}).sort()){let m=n["@reverse"][f];for(let y of Object.keys(e.subjects))if(Jr.getValues(e.subjects[y],f).some((b)=>b["@id"]===u))d["@reverse"]=d["@reverse"]||{},Jr.addValue(d["@reverse"],f,[],{propertyIsArray:!0}),ra.frame({...e,embedded:!0},[y],m,d["@reverse"][f],i)}bf(r,i,d),e.subjectStack.pop()}};ra.cleanupNull=(e,t)=>{if(En.isArray(e))return e.map((r)=>ra.cleanupNull(r,t)).filter((r)=>r);if(e==="@null")return null;if(En.isObject(e)){if("@id"in e){let n=e["@id"];if(t.link.hasOwnProperty(n)){let r=t.link[n].indexOf(e);if(r!==-1)return t.link[n][r];t.link[n].push(e)}else t.link[n]=[e]}for(let n in e)e[n]=ra.cleanupNull(e[n],t)}return e};function Hoe(e){let t={};for(let n in e)if(e[n]!==void 0)t["@"+n]=[e[n]];return[t]}function x8e(e,t,n){for(let r=n.length-1;r>=0;--r){let i=n[r];if(i.graph===t&&i.subject["@id"]===e["@id"])return!0}return!1}function GF(e,t){if(En.isArray(e)){e.forEach((r)=>GF(r,t));return}if(!En.isObject(e))return;zF([e]);for(let r of["@embed","@explicit","@requireAll","@omitDefault"]){if(!(r in e))continue;let i=e[r];if(!En.isArray(i)||i.length!==1||r!=="@embed"&&typeof i[0]!=="boolean")throw new vf("Invalid frame flag value.","jsonld.SyntaxError",{code:r==="@embed"?"invalid @embed value":"invalid frame",frame:e})}let n=n_(e,t,"embed");if(n==="@link"||t.is11&&(n==="@first"||n==="@last"))throw new vf("Invalid value of @embed for processing mode.","jsonld.SyntaxError",{code:"invalid @embed value",frame:e});for(let[r,i]of Object.entries(e))if(!["@value","@default","@id","@type","@language","@direction"].includes(r))GF(i,t)}function n_(e,t,n){let r="@"+n,i=r in e?e[r][0]:t[n];if(n==="embed"){if(i===!0)i="@once";else if(i===!1)i="@never";else if(i!=="@always"&&i!=="@never"&&i!=="@link"&&i!=="@first"&&i!=="@last"&&i!=="@once")throw new vf("Invalid JSON-LD syntax; invalid value of @embed.","jsonld.SyntaxError",{code:"invalid @embed value",frame:e})}return i}function zF(e){if(!En.isArray(e)||e.length!==1||!En.isObject(e[0]))throw new vf("Invalid JSON-LD syntax; a JSON-LD frame must be a single object.","jsonld.SyntaxError",{frame:e});if("@id"in e[0]){for(let t of Jr.asArray(e[0]["@id"]))if(!(En.isObject(t)||Goe.isAbsolute(t))||En.isString(t)&&t.indexOf("_:")===0)throw new vf("Invalid JSON-LD syntax; invalid @id in frame.","jsonld.SyntaxError",{code:"invalid frame",frame:e})}if("@type"in e[0]){for(let t of Jr.asArray(e[0]["@type"]))if(!(En.isObject(t)||Goe.isAbsolute(t)||t==="@json")||En.isString(t)&&t.indexOf("_:")===0)throw new vf("Invalid JSON-LD syntax; invalid @type in frame.","jsonld.SyntaxError",{code:"invalid frame",frame:e})}}function w8e(e,t,n,r){let i={};for(let s of t){let o=e.graphMap[e.graph][s];if(Woe(e,o,n,r))i[s]=o}return i}function Woe(e,t,n,r){let i=!0,s=!1;for(let o in n){let a=!1,l=Jr.getValues(t,o),c=Jr.getValues(n,o).length===0;if(o==="@id"){if(En.isEmptyObject(n["@id"][0]||{}))a=!0;else if(n["@id"].length>=0)a=n["@id"].includes(l[0]);if(!r.requireAll)return a}else if(o==="@type"){if(i=!1,c){if(l.length>0)return!1;a=!0}else if(n["@type"].length===1&&En.isEmptyObject(n["@type"][0]))a=l.length>0;else for(let u of n["@type"])if(En.isObject(u)&&"@default"in u)a=!0;else a=a||l.some((p)=>p===u);if(!r.requireAll)return a}else if(JF(o))continue;else{let u=Jr.getValues(n,o)[0],p=!1;if(u)zF([u]),p="@default"in u;if(i=!1,l.length===0&&p)continue;if(l.length>0&&c)return!1;if(u===void 0){if(l.length>0)return!1;a=!0}else if(ia.isList(u)){let d=u["@list"][0];if(ia.isList(l[0])){let f=l[0]["@list"];if(ia.isValue(d))a=f.some((m)=>HF(d,m));else if(ia.isSubject(d)||ia.isSubjectReference(d))a=f.some((m)=>zoe(e,d,m,r))}}else if(ia.isValue(u))a=l.some((d)=>HF(u,d));else if(ia.isSubjectReference(u))a=l.some((d)=>zoe(e,u,d,r));else if(En.isObject(u))a=l.length>0;else a=!1}if(!a&&r.requireAll)return!1;s=s||a}return i||s}function D8e(e,t){let n=e.uniqueEmbeds[e.graph],r=n[t],{parent:i,property:s}=r,o={"@id":t};if(En.isArray(i)){for(let l=0;l{let c=Object.keys(n);for(let u of c)if(u in n&&En.isObject(n[u].parent)&&n[u].parent["@id"]===l)delete n[u],a(u)};a(t)}function KS(e,t){if(En.isArray(e))return e.map((n)=>KS(n,t));if(En.isObject(e)){if("@preserve"in e)return e["@preserve"][0];if(ia.isValue(e))return e;if(ia.isList(e))return e["@list"]=KS(e["@list"],t),e;if("@id"in e){let n=e["@id"];if(t.link.hasOwnProperty(n)){let r=t.link[n].indexOf(e);if(r!==-1)return t.link[n][r];t.link[n].push(e)}else t.link[n]=[e]}for(let n in e){if(n==="@id"&&t.bnodesToClear.includes(e[n])){delete e["@id"];continue}e[n]=KS(e[n],t)}}return e}function bf(e,t,n){if(En.isObject(e))Jr.addValue(e,t,n,{propertyIsArray:!0});else e.push(n)}function zoe(e,t,n,r){if(!("@id"in n))return!1;let i=e.subjects[n["@id"]];return i&&Woe(e,i,t,r)}function HF(e,t){let n=t["@value"],r=t["@type"],i=t["@language"],s=Object.prototype.hasOwnProperty.call(e,"@value")?En.isArray(e["@value"])?e["@value"]:[e["@value"]]:[],o=e["@type"]?En.isArray(e["@type"])?e["@type"]:[e["@type"]]:[],a=e["@language"]?En.isArray(e["@language"])?e["@language"]:[e["@language"]]:[];if(s.length===0&&o.length===0&&a.length===0)return!0;if(!(s.some((l)=>Jr.compareValues({"@value":n,"@type":r},{"@value":l,"@type":r}))||En.isEmptyObject(s[0])))return!1;if(!(!r&&o.length===0||o.includes(r)||r&&En.isEmptyObject(o[0])))return!1;if(!(!i&&a.length===0||a.includes(i)||i&&En.isEmptyObject(a[0])))return!1;return!0}});var sae=z(function(IBt,iae){var ZF=so(),{isArray:gp,isObject:bp,isString:tae,isUndefined:WF}=js(),{isList:XF,isValue:Mc,isGraph:nae,isSimpleGraph:Xoe,isSubjectReference:QF}=El(),{expandIri:eC,getContextValue:is,isKeyword:rae,process:YF,processingMode:T8e}=yp(),{removeBase:Zoe,prependBase:S8e}=jc(),{REGEX_KEYWORD:E8e,addValue:uo,asArray:JS,compareShortestLeast:k8e}=oo(),Ut={};iae.exports=Ut;Ut.compact=async({activeCtx:e,activeProperty:t=null,element:n,options:r={}})=>{if(gp(n)){let s=[];for(let o=0;o1)c=Array.from(c).sort();let u=e;for(let d of c){let f=Ut.compactIri({activeCtx:u,iri:d,relativeTo:{vocab:!0}}),m=is(a,f,"@context");if(!WF(m))e=await YF({activeCtx:e,localCtx:m,options:r,propagate:!1})}let p=Object.keys(n).sort();for(let d of p){let f=n[d];if(d==="@id"){let m=JS(f).map((h)=>Ut.compactIri({activeCtx:e,iri:h,relativeTo:{vocab:!1},base:r.base}));if(m.length===1)m=m[0];let y=Ut.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}});o[y]=m;continue}if(d==="@type"){let m=JS(f).map((x)=>Ut.compactIri({activeCtx:a,iri:x,relativeTo:{vocab:!0}}));if(m.length===1)m=m[0];let y=Ut.compactIri({activeCtx:e,iri:"@type",relativeTo:{vocab:!0}}),g=(is(e,y,"@container")||[]).includes("@set")&&T8e(e,1.1)||gp(m)&&f.length===0;uo(o,y,m,{propertyIsArray:g});continue}if(d==="@reverse"){let m=await Ut.compact({activeCtx:e,activeProperty:"@reverse",element:f,options:r});for(let y in m)if(e.mappings.has(y)&&e.mappings.get(y).reverse){let h=m[y],g=(is(e,y,"@container")||[]).includes("@set")||!r.compactArrays;uo(o,y,h,{propertyIsArray:g}),delete m[y]}if(Object.keys(m).length>0){let y=Ut.compactIri({activeCtx:e,iri:d,relativeTo:{vocab:!0}});uo(o,y,m)}continue}if(d==="@preserve"){let m=await Ut.compact({activeCtx:e,activeProperty:t,element:f,options:r});if(!(gp(m)&&m.length===0))uo(o,d,m);continue}if(d==="@index"){if((is(e,t,"@container")||[]).includes("@index"))continue;let y=Ut.compactIri({activeCtx:e,iri:d,relativeTo:{vocab:!0}});uo(o,y,f);continue}if(d!=="@graph"&&d!=="@list"&&d!=="@included"&&rae(d)){let m=Ut.compactIri({activeCtx:e,iri:d,relativeTo:{vocab:!0}});uo(o,m,f);continue}if(!gp(f))throw new ZF("JSON-LD expansion error; expanded value must be an array.","jsonld.SyntaxError");if(f.length===0){let m=Ut.compactIri({activeCtx:e,iri:d,value:f,relativeTo:{vocab:!0},reverse:s}),y=e.mappings.has(m)?e.mappings.get(m)["@nest"]:null,h=o;if(y){if(eae(e,y,r),!bp(o[y]))o[y]={};h=o[y]}uo(h,m,f,{propertyIsArray:!0})}for(let m of f){let y=Ut.compactIri({activeCtx:e,iri:d,value:m,relativeTo:{vocab:!0},reverse:s}),h=e.mappings.has(y)?e.mappings.get(y)["@nest"]:null,b=o;if(h){if(eae(e,h,r),!bp(o[h]))o[h]={};b=o[h]}let g=is(e,y,"@container")||[],x=nae(m),v=XF(m),D;if(v)D=m["@list"];else if(x)D=m["@graph"];let T=await Ut.compact({activeCtx:e,activeProperty:y,element:v||x?D:m,options:r});if(v){if(!gp(T))T=[T];if(!g.includes("@list")){if(T={[Ut.compactIri({activeCtx:e,iri:"@list",relativeTo:{vocab:!0}})]:T},"@index"in m)T[Ut.compactIri({activeCtx:e,iri:"@index",relativeTo:{vocab:!0}})]=m["@index"]}else{uo(b,y,T,{valueIsArray:!0,allowDuplicate:!0});continue}}if(x)if(g.includes("@graph")&&(g.includes("@id")||g.includes("@index")&&Xoe(m))){let N;if(b.hasOwnProperty(y))N=b[y];else b[y]=N={};let O=(g.includes("@id")?m["@id"]:m["@index"])||Ut.compactIri({activeCtx:e,iri:"@none",relativeTo:{vocab:!0}});uo(N,O,T,{propertyIsArray:!r.compactArrays||g.includes("@set")})}else if(g.includes("@graph")&&Xoe(m)){if(gp(T)&&T.length>1)T={"@included":T};uo(b,y,T,{propertyIsArray:!r.compactArrays||g.includes("@set")})}else{if(gp(T)&&T.length===1&&r.compactArrays)T=T[0];if(T={[Ut.compactIri({activeCtx:e,iri:"@graph",relativeTo:{vocab:!0}})]:T},"@id"in m)T[Ut.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}})]=m["@id"];if("@index"in m)T[Ut.compactIri({activeCtx:e,iri:"@index",relativeTo:{vocab:!0}})]=m["@index"];uo(b,y,T,{propertyIsArray:!r.compactArrays||g.includes("@set")})}else if(g.includes("@language")||g.includes("@index")||g.includes("@id")||g.includes("@type")){let N;if(b.hasOwnProperty(y))N=b[y];else b[y]=N={};let O;if(g.includes("@language")){if(Mc(T))T=T["@value"];O=m["@language"]}else if(g.includes("@index")){let C=is(e,y,"@index")||"@index",X=eC(e,C,{vocab:!0},r),te=Ut.compactIri({activeCtx:e,iri:X,value:C==="@index"?null:(m[X]||[])[0],relativeTo:{vocab:!0}});if(C==="@index")O=m["@index"],delete T[te];else{let L;if([O,...L]=JS(T[te]??[]),!tae(O))O=null;else switch(L.length){case 0:delete T[te];break;case 1:T[te]=r.compactArrays?L[0]:L;break;default:T[te]=L;break}}}else if(g.includes("@id")){let C=Ut.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}});O=T[C],delete T[C]}else if(g.includes("@type")){let C=Ut.compactIri({activeCtx:e,iri:"@type",relativeTo:{vocab:!0}}),X;switch([O,...X]=JS(T[C]||[]),X.length){case 0:delete T[C];break;case 1:T[C]=X[0];break;default:T[C]=X;break}if(Object.keys(T).length===1&&"@id"in m)T=await Ut.compact({activeCtx:e,activeProperty:y,element:{"@id":m["@id"]},options:r})}if(O===null||O===void 0)O=Ut.compactIri({activeCtx:e,iri:"@none",relativeTo:{vocab:!0}});uo(N,O,T,{propertyIsArray:!r.compactArrays||g.includes("@set")})}else{let N=!r.compactArrays||g.includes("@set")||g.includes("@list")||gp(T)&&T.length===0||d==="@list"||d==="@graph";uo(b,y,T,{propertyIsArray:N})}}}return o}return n};Ut.compactIri=({activeCtx:e,iri:t,value:n=null,relativeTo:r={vocab:!1},reverse:i=!1,base:s=null})=>{if(t===null)return t;if(e.isPropertyTermScoped&&e.previousContext)e=e.previousContext;let o=e.getInverse();if(rae(t)&&t in o&&"@none"in o[t]&&"@type"in o[t]["@none"]&&"@none"in o[t]["@none"]["@type"])return o[t]["@none"]["@type"]["@none"];if(r.vocab&&t in o){let p=e["@language"]||"@none",d=[];if(bp(n)&&"@index"in n&&!("@graph"in n))d.push("@index","@index@set");if(bp(n)&&"@preserve"in n)n=n["@preserve"][0];if(nae(n)){if("@index"in n)d.push("@graph@index","@graph@index@set","@index","@index@set");if("@id"in n)d.push("@graph@id","@graph@id@set");if(d.push("@graph","@graph@set","@set"),!("@index"in n))d.push("@graph@index","@graph@index@set","@index","@index@set");if(!("@id"in n))d.push("@graph@id","@graph@id@set")}else if(bp(n)&&!Mc(n))d.push("@id","@id@set","@type","@set@type");let f="@language",m="@null";if(i)f="@type",m="@reverse",d.push("@set");else if(XF(n)){if(!("@index"in n))d.push("@list");let h=n["@list"];if(h.length===0)f="@any",m="@none";else{let b=h.length===0?p:null,g=null;for(let x=0;x=0;--p){let d=l[p],f=d.terms;for(let m of f){let y=m+":"+t.substr(d.iri.length);if(e.mappings.get(m)._prefix&&(!e.mappings.has(y)||n===null&&e.mappings.get(y)["@id"]===t)&&(a===null||k8e(y,a)<0))a=y}}if(a!==null)return a;for(let[p,d]of e.mappings)if(d&&d._prefix&&t.startsWith(p+":"))throw new ZF(`Absolute IRI "${t}" confused with prefix "${p}".`,"jsonld.SyntaxError",{code:"IRI confused with prefix",context:e});if(!r.vocab)if("@base"in e)if(!e["@base"])return t;else{let p=Zoe(S8e(s,e["@base"]),t);return E8e.test(p)?`./${p}`:p}else return Zoe(s,t);return t};Ut.compactValue=({activeCtx:e,activeProperty:t,value:n,options:r})=>{if(Mc(n)){let a=is(e,t,"@type"),l=is(e,t,"@language"),c=is(e,t,"@direction"),u=is(e,t,"@container")||[],p="@index"in n&&!u.includes("@index");if(!p&&a!=="@none"){if(n["@type"]===a)return n["@value"];if("@language"in n&&n["@language"]===l&&"@direction"in n&&n["@direction"]===c)return n["@value"];if("@language"in n&&n["@language"]===l)return n["@value"];if("@direction"in n&&n["@direction"]===c)return n["@value"]}let d=Object.keys(n).length,f=d===1||d===2&&"@index"in n&&!p,m="@language"in e,y=tae(n["@value"]),h=e.mappings.has(t)&&e.mappings.get(t)["@language"]===null;if(f&&a!=="@none"&&(!m||!y||h))return n["@value"];let b={};if(p)b[Ut.compactIri({activeCtx:e,iri:"@index",relativeTo:{vocab:!0}})]=n["@index"];if("@type"in n)b[Ut.compactIri({activeCtx:e,iri:"@type",relativeTo:{vocab:!0}})]=Ut.compactIri({activeCtx:e,iri:n["@type"],relativeTo:{vocab:!0}});else if("@language"in n)b[Ut.compactIri({activeCtx:e,iri:"@language",relativeTo:{vocab:!0}})]=n["@language"];if("@direction"in n)b[Ut.compactIri({activeCtx:e,iri:"@direction",relativeTo:{vocab:!0}})]=n["@direction"];return b[Ut.compactIri({activeCtx:e,iri:"@value",relativeTo:{vocab:!0}})]=n["@value"],b}let i=eC(e,t,{vocab:!0},r),s=is(e,t,"@type"),o=Ut.compactIri({activeCtx:e,iri:n["@id"],relativeTo:{vocab:s==="@vocab"},base:r.base});if(s==="@id"||s==="@vocab"||i==="@graph")return o;return{[Ut.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}})]:o}};function N8e(e,t,n,r,i,s){if(s===null)s="@null";let o=[];if((s==="@id"||s==="@reverse")&&bp(n)&&"@id"in n){if(s==="@reverse")o.push("@reverse");let l=Ut.compactIri({activeCtx:e,iri:n["@id"],relativeTo:{vocab:!0}});if(e.mappings.has(l)&&e.mappings.get(l)&&e.mappings.get(l)["@id"]===n["@id"])o.push.apply(o,["@vocab","@id"]);else o.push.apply(o,["@id","@vocab"])}else{o.push(s);let l=o.find((c)=>c.includes("_"));if(l)o.push(l.replace(/^[^_]+_/,"_"))}o.push("@none");let a=e.inverse[t];for(let l of r){if(!(l in a))continue;let c=a[l][i];for(let u of o){if(!(u in c))continue;return c[u]}}return null}function eae(e,t,n){if(eC(e,t,{vocab:!0},n)!=="@nest")throw new ZF("JSON-LD compact error; nested property must have an @nest value resolving to @nest.","jsonld.SyntaxError",{code:"invalid @nest value"})}});var aae=z(function(ABt,oae){oae.exports=(e)=>{class t{toString(){return"[object JsonLdProcessor]"}}return Object.defineProperty(t,"prototype",{writable:!1,enumerable:!1}),Object.defineProperty(t.prototype,"constructor",{writable:!0,enumerable:!1,configurable:!0,value:t}),t.compact=function(n,r){if(arguments.length<2)return Promise.reject(TypeError("Could not compact, too few arguments."));return e.compact(n,r)},t.expand=function(n){if(arguments.length<1)return Promise.reject(TypeError("Could not expand, too few arguments."));return e.expand(n)},t.flatten=function(n){if(arguments.length<1)return Promise.reject(TypeError("Could not flatten, too few arguments."));return e.flatten(n)},t}});var fae=z(function(RBt,dae){var lae=NS(),uae=Qse(),_p=oo(),Lc=poe(),tC=_p.IdentifierIssuer,Ol=so(),O8e=kF(),rC=foe(),{expand:P8e}=Eoe(),{flatten:$8e}=LF(),{fromRDF:I8e}=Coe(),{toRDF:A8e}=Joe(),{frameMergedOrDefault:R8e,cleanupNull:j8e}=Yoe(),{isArray:Wy,isObject:_f,isString:vp}=js(),{isSubjectReference:F8e}=El(),{expandIri:C8e,getInitialContext:GS,process:cae,processingMode:nC}=yp(),{compact:M8e,compactIri:L8e}=sae(),{createNodeMap:q8e,createMergedNodeMap:U8e,mergeNodeMaps:B8e}=e_(),{logEventHandler:V8e,logWarningEventHandler:K8e,safeEventHandler:J8e,setDefaultEventHandler:G8e,setupEventHandler:H8e,strictEventHandler:z8e,unhandledEventHandler:W8e}=Ky(),pae=function(e){let t={},n=100,r=new O8e({max:100});e.compact=async function(s,o,a){if(arguments.length<2)throw TypeError("Could not compact, too few arguments.");if(o===null)throw new Ol("The compaction context must not be null.","jsonld.CompactError",{code:"invalid local context"});if(s===null)return null;if(a=i(a,{base:vp(s)?s:"",compactArrays:!0,compactToRelative:!0,graph:!1,skipExpansion:!1,link:!1,issuer:new tC("_:b"),contextResolver:new Lc({sharedCache:r})}),a.link)a.skipExpansion=!0;if(!a.compactToRelative)delete a.base;let l;if(a.skipExpansion)l=s;else l=await e.expand(s,a);let c=await e.processContext(GS(a),o,a),u=await M8e({activeCtx:c,element:l,options:a});if(a.compactArrays&&!a.graph&&Wy(u)){if(u.length===1)u=u[0];else if(u.length===0)u={}}else if(a.graph&&_f(u))u=[u];if(_f(o)&&"@context"in o)o=o["@context"];if(o=_p.clone(o),!Wy(o))o=[o];let p=o;o=[];for(let f=0;f0)o.push(p[f]);let d=o.length>0;if(o.length===1)o=o[0];if(Wy(u)){let f=L8e({activeCtx:c,iri:"@graph",relativeTo:{vocab:!0}}),m=u;if(u={},d)u["@context"]=o;u[f]=m}else if(_f(u)&&d){let f=u;u={"@context":o};for(let m in f)u[m]=f[m]}return u},e.expand=async function(s,o){if(arguments.length<1)throw TypeError("Could not expand, too few arguments.");o=i(o,{keepFreeFloatingNodes:!1,contextResolver:new Lc({sharedCache:r})});let a={},l=[];if("expandContext"in o){let d=_p.clone(o.expandContext);if(_f(d)&&"@context"in d)a.expandContext=d;else a.expandContext={"@context":d};l.push(a.expandContext)}let c;if(!vp(s))a.input=_p.clone(s);else{let d=await e.get(s,o);if(c=d.documentUrl,a.input=d.document,d.contextUrl)a.remoteContext={"@context":d.contextUrl},l.push(a.remoteContext)}if(!("base"in o))o.base=c||"";let u=GS(o);for(let d of l)u=await cae({activeCtx:u,localCtx:d,options:o});let p=await P8e({activeCtx:u,element:a.input,options:o});if(_f(p)&&"@graph"in p&&Object.keys(p).length===1)p=p["@graph"];else if(p===null)p=[];if(!Wy(p))p=[p];return p},e.flatten=async function(s,o,a){if(arguments.length<1)return TypeError("Could not flatten, too few arguments.");if(typeof o==="function")o=null;else o=o||null;a=i(a,{base:vp(s)?s:"",contextResolver:new Lc({sharedCache:r})});let l=await e.expand(s,a),c=$8e(l);if(o===null)return c;return a.graph=!0,a.skipExpansion=!0,await e.compact(c,o,a)},e.frame=async function(s,o,a){if(arguments.length<2)throw TypeError("Could not frame, too few arguments.");if(a=i(a,{base:vp(s)?s:"",embed:"@once",explicit:!1,requireAll:!1,omitDefault:!1,bnodesToClear:[],contextResolver:new Lc({sharedCache:r})}),vp(o)){let h=await e.get(o,a);if(o=h.document,h.contextUrl){let b=o["@context"];if(!b)b=h.contextUrl;else if(Wy(b))b.push(h.contextUrl);else b=[b,h.contextUrl];o["@context"]=b}}let l=o?o["@context"]||{}:{},c=await e.processContext(GS(a),l,a);if(!a.hasOwnProperty("omitGraph"))a.omitGraph=nC(c,1.1);if(!a.hasOwnProperty("pruneBlankNodeIdentifiers"))a.pruneBlankNodeIdentifiers=nC(c,1.1);let u=await e.expand(s,a),p={...a};p.isFrame=!0,p.keepFreeFloatingNodes=!0;let d=await e.expand(o,p),f=Object.keys(o).map((h)=>C8e(c,h,{vocab:!0}));p.merged=!a.frameDefault&&!f.includes("@graph"),p.is11=nC(c,1.1);let m=R8e(u,d,p);p.graph=!a.omitGraph,p.skipExpansion=!0,p.link={},p.framing=!0;let y=await e.compact(m,l,p);return p.link={},y=j8e(y,p),y},e.link=async function(s,o,a){let l={};if(o)l["@context"]=o;return l["@embed"]="@link",e.frame(s,l,a)},e.normalize=e.canonize=async function(s,o){if(arguments.length<1)throw TypeError("Could not canonize, too few arguments.");o=i(o,{skipExpansion:!1,safe:!0,contextResolver:new Lc({sharedCache:r})});let a=Object.assign({},{algorithm:"RDFC-1.0"},o.canonizeOptions||null);if("inputFormat"in o){if(o.inputFormat!=="application/n-quads")throw new Ol("Unknown canonicalization input format.","jsonld.CanonizeError");let u=rC.parse(s);return lae.canonize(u,a)}let l={...o};delete l.format,delete l.canonizeOptions,l.produceGeneralizedRdf=!1;let c=await e.toRDF(s,l);return lae.canonize(c,a)},e.fromRDF=async function(s,o){if(arguments.length<1)throw TypeError("Could not convert from RDF, too few arguments.");o=i(o,{format:vp(s)?"application/n-quads":void 0});let{format:a}=o,{rdfParser:l}=o;if(a){if(l=l||t[a],!l)throw new Ol("Unknown input format.","jsonld.UnknownFormat",{format:a})}else l=()=>s;let c=await l(s);return I8e(c,o)},e.toRDF=async function(s,o){if(arguments.length<1)throw TypeError("Could not convert to RDF, too few arguments.");o=i(o,{skipExpansion:!1,contextResolver:new Lc({sharedCache:r})});let a;if(o.skipExpansion)a=s;else a=await e.expand(s,o);let l=A8e(a,o);if(o.format){if(o.format==="application/n-quads")return rC.serialize(l);throw new Ol("Unknown output format.","jsonld.UnknownFormat",{format:o.format})}return l},e.createNodeMap=async function(s,o){if(arguments.length<1)throw TypeError("Could not create node map, too few arguments.");o=i(o,{base:vp(s)?s:"",contextResolver:new Lc({sharedCache:r})});let a=await e.expand(s,o);return U8e(a,o)},e.merge=async function(s,o,a){if(arguments.length<1)throw TypeError("Could not merge, too few arguments.");if(!Wy(s))throw TypeError('Could not merge, "docs" must be an array.');if(typeof o==="function")o=null;else o=o||null;a=i(a,{contextResolver:new Lc({sharedCache:r})});let l=await Promise.all(s.map((h)=>{let b={...a};return e.expand(h,b)})),c=!0;if("mergeNodes"in a)c=a.mergeNodes;let u=a.issuer||new tC("_:b"),p={"@default":{}};for(let h=0;he._documentLoader,set:(s)=>e._documentLoader=s}),e.documentLoader=async(s)=>{throw new Ol("Could not retrieve a JSON-LD document from the URL. URL dereferencing not implemented.","jsonld.LoadDocumentError",{code:"loading document failed",url:s})},e.get=async function(s,o){let a;if(typeof o.documentLoader==="function")a=o.documentLoader;else a=e.documentLoader;let l=await a(s);try{if(!l.document)throw new Ol("No remote document found at the given URL.","jsonld.NullRemoteDocument");if(vp(l.document))l.document=JSON.parse(l.document)}catch(c){throw new Ol("Could not retrieve a JSON-LD document from the URL.","jsonld.LoadDocumentError",{code:"loading document failed",cause:c,remoteDoc:l})}return l},e.processContext=async function(s,o,a){if(a=i(a,{base:"",contextResolver:new Lc({sharedCache:r})}),o===null)return GS(a);if(o=_p.clone(o),!(_f(o)&&("@context"in o)))o={"@context":o};return cae({activeCtx:s,localCtx:o,options:a})},e.getContextValue=yp().getContextValue,e.documentLoaders={},e.useDocumentLoader=function(s){if(!(s in e.documentLoaders))throw new Ol('Unknown document loader type: "'+s+'"',"jsonld.UnknownDocumentLoader",{type:s});e.documentLoader=e.documentLoaders[s].apply(e,Array.prototype.slice.call(arguments,1))},e.registerRDFParser=function(s,o){t[s]=o},e.unregisterRDFParser=function(s){delete t[s]},e.registerRDFParser("application/n-quads",rC.parse),e.url=jc(),e.logEventHandler=V8e,e.logWarningEventHandler=K8e,e.safeEventHandler=J8e,e.setDefaultEventHandler=G8e,e.strictEventHandler=z8e,e.unhandledEventHandler=W8e,e.util=_p,Object.assign(e,_p),e.promises=e,e.RequestQueue=DF(),e.JsonLdProcessor=aae()(e),uae.setupGlobals(e),uae.setupDocumentLoaders(e);function i(s,{documentLoader:o=e.documentLoader,...a}){if(s&&"compactionMap"in s)throw new Ol('"compactionMap" not supported.',"jsonld.OptionsError");if(s&&"expansionMap"in s)throw new Ol('"expansionMap" not supported.',"jsonld.OptionsError");return Object.assign({},{documentLoader:o},a,s,{eventHandler:H8e({options:s})})}return e},iC=function(){return pae(function(){return iC()})};pae(iC);dae.exports=iC});bo();bo();var xB=Rr(og(),1);var C3={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:json-schema:0.1.0",type:"object",required:["dialect","baseUri","root","resources"],properties:{dialect:{const:"https://json-schema.org/draft/2020-12/schema"},baseUri:{type:"string",minLength:1},root:{$ref:"#/$defs/node"},resources:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}},$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}};var M3={id:"umf.json-schema",version:"0.1.0",coreVersion:"0.1.0",description:"JSON Schema Draft 2020-12 syntax, scoped validation, and lossless-number native interchange",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:json-schema:0.1.0",type:"object",required:["dialect","baseUri","root","resources"],properties:{dialect:{const:"https://json-schema.org/draft/2020-12/schema"},baseUri:{type:"string",minLength:1},root:{$ref:"#/$defs/node"},resources:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}},$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"docs/helix/02-design/contracts/CONTRACT-002-json-schema.md",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"JSON Schema",version:"2020-12",subset:"Native JSON tree preservation; semantic validation limited to known dialect/keywords and JavaScript-compatible numerics, format annotation-only; see CONTRACT-002 and evidence."},evidence:["tests/json-schema/native.test.ts","tests/json-schema/upstream.test.ts"]}};var t0={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.7.0",title:"UMF 0.7.0 relationship envelope",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.7.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}},kind:{type:"string",minLength:1,description:"UMF role; unknown labels remain uninterpreted. Missing is unspecified, never inferred from scalarType."},nullability:{type:"string",minLength:1,description:"Ideal value availability. Unknown labels remain uninterpreted. Missing and unspecified assert no availability constraint. Native absence carriers require explicit bindings."},cardinality:{type:"string",minLength:1,description:"One ideal value, finite ordered sequence with duplicates allowed, finite exact string-key mapping with unique keys, or no assertion. Unknown labels remain uninterpreted."},itemType:{$ref:"#/$defs/itemType"},facets:{$ref:"#/$defs/facets"},members:{type:"array",uniqueItems:!0,items:{$ref:"#/$defs/keyFieldReference"}},keys:{type:"array",minItems:1,items:{$ref:"#/$defs/key"}}},allOf:[{if:{required:["kind"],properties:{kind:{enum:["record","group"]}}},then:{properties:{scalarType:!1}}},{if:{required:["nullability"],properties:{nullability:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{enum:["array","map"]}}},then:{not:{required:["scalarType"]}}},{if:{required:["itemType"],properties:{itemType:{}}},then:{required:["kind","cardinality"],properties:{kind:{const:"field"},cardinality:{enum:["array","map"]}}}},{if:{required:["facets"],properties:{facets:{}}},then:{required:["kind"],properties:{kind:{const:"field"},cardinality:{enum:["one","unspecified"]},references:{type:"array",not:{contains:{type:"object",required:["role"],properties:{role:{const:"record-type"}}}}}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{}}}}},then:{required:["scalarType"],properties:{scalarType:{enum:["string","binary"]}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"unicode-scalar"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"string"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"byte"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"binary"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["precision"],properties:{precision:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"decimal"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["integerWidth"],properties:{integerWidth:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"integer"}}}},{if:{properties:{members:{}},required:["members"]},then:{required:["kind"],properties:{kind:{const:"record"}}}},{if:{properties:{keys:{}},required:["keys"]},then:{required:["kind","members"],properties:{kind:{const:"record"},members:{}}}}]},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"},relationships:{type:"array",items:{$ref:"#/$defs/relationship"}}}},knownElementKind:{enum:["field","record","group"]},knownNullability:{enum:["required","absent-allowed","unspecified"]},knownCardinality:{enum:["one","array","map","unspecified"]},itemType:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},facets:{type:"object",description:"Missing members impose no bound. Unknown members and qualifiers are retained without interpretation.",properties:{length:{type:"object",required:["max","unit"],properties:{max:{type:"integer",minimum:0,maximum:9007199254740991},unit:{type:"string",minLength:1,description:"Known units: unicode-scalar for string, byte for binary. Unknown units remain uninterpreted."}}},precision:{type:"integer",minimum:1,maximum:9007199254740991,description:"Decimal coefficient digit bound; requires scale. Absolute coefficient is less than 10^precision. No implicit rounding."},scale:{type:"integer",minimum:0,maximum:9007199254740991,description:"Fixed fractional digit count; requires precision. Semantic validation requires scale <= precision. Value equals integer coefficient times 10^-scale."},integerWidth:{type:"object",required:["bits","signed"],properties:{bits:{type:"integer",minimum:1,maximum:9007199254740991},signed:{type:"boolean"}},description:"Signed [-2^(bits-1),2^(bits-1)-1] or unsigned [0,2^bits-1]; mathematical domain, not a physical storage-width assertion."}},dependentRequired:{precision:["scale"],scale:["precision"]}},keyFieldReference:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}},additionalProperties:!0},key:{type:"object",required:["id","name","fields"],properties:{id:{$ref:"#/$defs/id"},name:{$ref:"#/$defs/id"},fields:{type:"array",minItems:1,uniqueItems:!0,items:{$ref:"#/$defs/keyFieldReference"}},primary:{type:"boolean"}},additionalProperties:!0},relationshipEndpoint:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}},additionalProperties:!0},relationshipTarget:{type:"object",required:["module","element","key"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"},key:{$ref:"#/$defs/id"}},additionalProperties:!0},relationshipMultiplicity:{type:"object",required:["min","max"],properties:{min:{type:"integer",minimum:0,maximum:9007199254740991},max:{anyOf:[{type:"integer",minimum:1,maximum:9007199254740991},{const:"*"}]}},additionalProperties:!0},relationship:{type:"object",required:["id","name","source","target","sourceMultiplicity","targetMultiplicity","targetLifecycle","directed"],properties:{id:{$ref:"#/$defs/id"},name:{$ref:"#/$defs/id"},source:{type:"array",minItems:1,items:{$ref:"#/$defs/relationshipEndpoint"}},target:{type:"array",minItems:1,items:{$ref:"#/$defs/relationshipTarget"}},sourceMultiplicity:{$ref:"#/$defs/relationshipMultiplicity"},targetMultiplicity:{$ref:"#/$defs/relationshipMultiplicity"},targetLifecycle:{type:"string",minLength:1},directed:{type:"boolean"},inverse:{$ref:"#/$defs/id"},associationRecord:{$ref:"#/$defs/relationshipEndpoint"}},additionalProperties:!0}},description:"Authored schema-level relationships between keyed Records; native enforcement and storage are not inferred. Unknown qualifiers are retained.",$comment:"Exact endpoint/key resolution, unique IDs/names, inverse collisions, multiplicity bounds and lifecycle coherence require portable semantic validation."};var n0={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.6.0",title:"UMF 0.6.0 key envelope",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.6.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}},kind:{type:"string",minLength:1,description:"UMF role; unknown labels remain uninterpreted. Missing is unspecified, never inferred from scalarType."},nullability:{type:"string",minLength:1,description:"Ideal value availability. Unknown labels remain uninterpreted. Missing and unspecified assert no availability constraint. Native absence carriers require explicit bindings."},cardinality:{type:"string",minLength:1,description:"One ideal value, finite ordered sequence with duplicates allowed, finite exact string-key mapping with unique keys, or no assertion. Unknown labels remain uninterpreted."},itemType:{$ref:"#/$defs/itemType"},facets:{$ref:"#/$defs/facets"},members:{type:"array",uniqueItems:!0,items:{$ref:"#/$defs/keyFieldReference"}},keys:{type:"array",minItems:1,items:{$ref:"#/$defs/key"}}},allOf:[{if:{required:["kind"],properties:{kind:{enum:["record","group"]}}},then:{properties:{scalarType:!1}}},{if:{required:["nullability"],properties:{nullability:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{enum:["array","map"]}}},then:{not:{required:["scalarType"]}}},{if:{required:["itemType"],properties:{itemType:{}}},then:{required:["kind","cardinality"],properties:{kind:{const:"field"},cardinality:{enum:["array","map"]}}}},{if:{required:["facets"],properties:{facets:{}}},then:{required:["kind"],properties:{kind:{const:"field"},cardinality:{enum:["one","unspecified"]},references:{type:"array",not:{contains:{type:"object",required:["role"],properties:{role:{const:"record-type"}}}}}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{}}}}},then:{required:["scalarType"],properties:{scalarType:{enum:["string","binary"]}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"unicode-scalar"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"string"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"byte"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"binary"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["precision"],properties:{precision:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"decimal"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["integerWidth"],properties:{integerWidth:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"integer"}}}},{if:{properties:{members:{}},required:["members"]},then:{required:["kind"],properties:{kind:{const:"record"}}}},{if:{properties:{keys:{}},required:["keys"]},then:{required:["kind","members"],properties:{kind:{const:"record"},members:{}}}}]},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"}}},knownElementKind:{enum:["field","record","group"]},knownNullability:{enum:["required","absent-allowed","unspecified"]},knownCardinality:{enum:["one","array","map","unspecified"]},itemType:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},facets:{type:"object",description:"Missing members impose no bound. Unknown members and qualifiers are retained without interpretation.",properties:{length:{type:"object",required:["max","unit"],properties:{max:{type:"integer",minimum:0,maximum:9007199254740991},unit:{type:"string",minLength:1,description:"Known units: unicode-scalar for string, byte for binary. Unknown units remain uninterpreted."}}},precision:{type:"integer",minimum:1,maximum:9007199254740991,description:"Decimal coefficient digit bound; requires scale. Absolute coefficient is less than 10^precision. No implicit rounding."},scale:{type:"integer",minimum:0,maximum:9007199254740991,description:"Fixed fractional digit count; requires precision. Semantic validation requires scale <= precision. Value equals integer coefficient times 10^-scale."},integerWidth:{type:"object",required:["bits","signed"],properties:{bits:{type:"integer",minimum:1,maximum:9007199254740991},signed:{type:"boolean"}},description:"Signed [-2^(bits-1),2^(bits-1)-1] or unsigned [0,2^bits-1]; mathematical domain, not a physical storage-width assertion."}},dependentRequired:{precision:["scale"],scale:["precision"]}},keyFieldReference:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}},additionalProperties:!0},key:{type:"object",required:["id","name","fields"],properties:{id:{$ref:"#/$defs/id"},name:{$ref:"#/$defs/id"},fields:{type:"array",minItems:1,uniqueItems:!0,items:{$ref:"#/$defs/keyFieldReference"}},primary:{type:"boolean"}},additionalProperties:!0}},description:"Candidate envelope for authored named primary/alternate keys and explicit Record membership, retaining earlier Field, availability, cardinality and facet ideals. Cross-reference and equality semantics require portable validation; native enforcement is not inferred.",$comment:"Key membership resolution, unique ownership, key IDs/names/component sets, primary count and component domains require portable semantic validation. Native enforcement is not inferred."};var K3=Rr(og(),1);var L3={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.1.0",title:"UMF 0.1.0 document envelope",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.1.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}}}},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"}}}}};var q3={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.2.0",title:"UMF 0.2.0 field envelope",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.2.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}},kind:{type:"string",minLength:1,description:"UMF role; unknown labels remain uninterpreted. Missing is unspecified, never inferred from scalarType."}},allOf:[{if:{required:["kind"],properties:{kind:{enum:["record","group"]}}},then:{properties:{scalarType:!1}}}]},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"}}},knownElementKind:{enum:["field","record","group"]}},description:"Opt-in field/record/group roles. No implicit upgrade from 0.1.0. Provenance, migration and binding evidence remain required."};var U3={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.3.0",title:"UMF 0.3.0 nullability envelope",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.3.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}},kind:{type:"string",minLength:1,description:"UMF role; unknown labels remain uninterpreted. Missing is unspecified, never inferred from scalarType."},nullability:{type:"string",minLength:1,description:"Ideal value availability. Unknown labels remain uninterpreted. Missing and unspecified assert no availability constraint. Native absence carriers require explicit bindings."}},allOf:[{if:{required:["kind"],properties:{kind:{enum:["record","group"]}}},then:{properties:{scalarType:!1}}},{if:{required:["nullability"],properties:{nullability:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}}]},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"}}},knownElementKind:{enum:["field","record","group"]},knownNullability:{enum:["required","absent-allowed","unspecified"]}},description:"Explicit ideal value availability on Fields. No implicit upgrade from older envelopes, native NULL mapping, or default execution."};var B3={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.4.0",title:"UMF 0.4.0 cardinality envelope",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.4.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}},kind:{type:"string",minLength:1,description:"UMF role; unknown labels remain uninterpreted. Missing is unspecified, never inferred from scalarType."},nullability:{type:"string",minLength:1,description:"Ideal value availability. Unknown labels remain uninterpreted. Missing and unspecified assert no availability constraint. Native absence carriers require explicit bindings."},cardinality:{type:"string",minLength:1,description:"One ideal value, finite ordered sequence with duplicates allowed, finite exact string-key mapping with unique keys, or no assertion. Unknown labels remain uninterpreted."},itemType:{$ref:"#/$defs/itemType"}},allOf:[{if:{required:["kind"],properties:{kind:{enum:["record","group"]}}},then:{properties:{scalarType:!1}}},{if:{required:["nullability"],properties:{nullability:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{enum:["array","map"]}}},then:{not:{required:["scalarType"]}}},{if:{required:["itemType"],properties:{itemType:{}}},then:{required:["kind","cardinality"],properties:{kind:{const:"field"},cardinality:{enum:["array","map"]}}}}]},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"}}},knownElementKind:{enum:["field","record","group"]},knownNullability:{enum:["required","absent-allowed","unspecified"]},knownCardinality:{enum:["one","array","map","unspecified"]},itemType:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}}},description:"Explicit Field shape and optional array-item/map-value Field reference; no native repetition, dimension or physical encoding inference."};var r0={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.5.0",title:"UMF 0.5.0 facet envelope",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.5.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}},kind:{type:"string",minLength:1,description:"UMF role; unknown labels remain uninterpreted. Missing is unspecified, never inferred from scalarType."},nullability:{type:"string",minLength:1,description:"Ideal value availability. Unknown labels remain uninterpreted. Missing and unspecified assert no availability constraint. Native absence carriers require explicit bindings."},cardinality:{type:"string",minLength:1,description:"One ideal value, finite ordered sequence with duplicates allowed, finite exact string-key mapping with unique keys, or no assertion. Unknown labels remain uninterpreted."},itemType:{$ref:"#/$defs/itemType"},facets:{$ref:"#/$defs/facets"}},allOf:[{if:{required:["kind"],properties:{kind:{enum:["record","group"]}}},then:{properties:{scalarType:!1}}},{if:{required:["nullability"],properties:{nullability:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{enum:["array","map"]}}},then:{not:{required:["scalarType"]}}},{if:{required:["itemType"],properties:{itemType:{}}},then:{required:["kind","cardinality"],properties:{kind:{const:"field"},cardinality:{enum:["array","map"]}}}},{if:{required:["facets"],properties:{facets:{}}},then:{required:["kind"],properties:{kind:{const:"field"},cardinality:{enum:["one","unspecified"]},references:{type:"array",not:{contains:{type:"object",required:["role"],properties:{role:{const:"record-type"}}}}}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{}}}}},then:{required:["scalarType"],properties:{scalarType:{enum:["string","binary"]}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"unicode-scalar"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"string"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"byte"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"binary"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["precision"],properties:{precision:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"decimal"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["integerWidth"],properties:{integerWidth:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"integer"}}}}]},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"}}},knownElementKind:{enum:["field","record","group"]},knownNullability:{enum:["required","absent-allowed","unspecified"]},knownCardinality:{enum:["one","array","map","unspecified"]},itemType:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},facets:{type:"object",description:"Missing members impose no bound. Unknown members and qualifiers are retained without interpretation.",properties:{length:{type:"object",required:["max","unit"],properties:{max:{type:"integer",minimum:0,maximum:9007199254740991},unit:{type:"string",minLength:1,description:"Known units: unicode-scalar for string, byte for binary. Unknown units remain uninterpreted."}}},precision:{type:"integer",minimum:1,maximum:9007199254740991,description:"Decimal coefficient digit bound; requires scale. Absolute coefficient is less than 10^precision. No implicit rounding."},scale:{type:"integer",minimum:0,maximum:9007199254740991,description:"Fixed fractional digit count; requires precision. Semantic validation requires scale <= precision. Value equals integer coefficient times 10^-scale."},integerWidth:{type:"object",required:["bits","signed"],properties:{bits:{type:"integer",minimum:1,maximum:9007199254740991},signed:{type:"boolean"}},description:"Signed [-2^(bits-1),2^(bits-1)-1] or unsigned [0,2^bits-1]; mathematical domain, not a physical storage-width assertion."}},dependentRequired:{precision:["scale"],scale:["precision"]}}},description:"Candidate facet envelope: author-stated scalar bounds with explicit units. Requires semantic validation of scale <= precision, identities and references. Native enforcement, encoding and exactness require separate bindings."};var V3={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:extension-package:0.1.0",title:"UMF extension package declaration",type:"object",required:["id","version","coreVersion","description","schema","semantics","scopes","capabilities"],properties:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},coreVersion:{const:"0.1.0"},description:{type:"string",minLength:1},schema:{type:["object","boolean"]},semantics:{type:"string",minLength:1},scopes:{type:"array",minItems:1,uniqueItems:!0,items:{enum:["document","module","element"]}},capabilities:{type:"object",required:["validation","directions","evidence"],properties:{validation:{enum:["structural","semantic"]},directions:{type:"array",uniqueItems:!0,items:{enum:["import","export"]}},evidence:{type:"array",items:{type:"string",minLength:1}},native:{type:"object",required:["system","version","subset"],properties:{system:{type:"string",minLength:1},version:{type:"string",minLength:1},subset:{type:"string",minLength:1}}}},allOf:[{if:{properties:{directions:{type:"array",minItems:1}}},then:{properties:{native:!0},required:["native"]}}]}}};function Hp(e){if(Array.isArray(e))return"a["+e.map(Hp).join(",")+"]";if(e!==null&&typeof e==="object")return"o{"+Object.keys(e).sort().map((t)=>JSON.stringify(t)+":"+Hp(e[t])).join(",")+"}";return JSON.stringify(e)}function mt(e=!0){let t=new K3.default({allErrors:!0,strict:e,allowUnionTypes:!0,ownProperties:!0,validateFormats:!1});return zp(t),t}function zp(e){e.removeKeyword("uniqueItems").addKeyword({keyword:"uniqueItems",type:"array",schemaType:"boolean",errors:!1,validate:(t,n)=>!t||new Set(n.map(Hp)).size===n.length}),e.removeKeyword("const").addKeyword({keyword:"const",errors:!1,validate:(t,n)=>Hp(t)===Hp(n)}),e.removeKeyword("enum").addKeyword({keyword:"enum",schemaType:"array",errors:!1,validate:(t,n)=>t.some((r)=>Hp(r)===Hp(n))})}var du=mt(),J3=du.compile(L3),G3=du.compile(q3),H3=du.compile(U3),z3=du.compile(B3),W3=du.compile(r0),C1=du.compile(V3),Q3=du.compile(n0),Y3=du.compile(t0);var X3=["boolean","integer","decimal","float","string","binary","date","time","timestamp"],Z3=["field","record","group"],eB=["required","absent-allowed","unspecified"],tB=["one","array","map","unspecified"];class U extends Error{code;path;constructor(e,t,n=""){super(t);this.code=e;this.path=n;this.name="UmfError"}}var $e=(e)=>e.replace(/~/g,"~0").replace(/\//g,"~1");var Zt={maxDepth:128,maxValues:1e5,maxTextLength:4000000};function Ae(e){let t=new Set,n=0;function r(i,s,o){if(++n>Zt.maxValues||o>Zt.maxDepth)throw new U("LIMIT","JSON structural limit exceeded",s);if(i===null||typeof i==="string"||typeof i==="boolean")return i;if(typeof i==="number"){if(!Number.isFinite(i)||Object.is(i,-0)||Number.isInteger(i)&&!Number.isSafeInteger(i))throw new U("NUMBER","Number outside the core interoperable numeric profile",s);return i}if(typeof i!=="object")throw new U("NON_JSON","Value is not JSON-compatible",s);if(t.has(i))throw new U("CYCLE","Cyclic value",s);let a=Object.getPrototypeOf(i);if(Array.isArray(i)?a!==Array.prototype:a!==Object.prototype&&a!==null)throw new U("NON_JSON","Custom object prototype",s);if(Object.getOwnPropertySymbols(i).length)throw new U("NON_JSON","Symbol keys are not JSON-compatible",s);t.add(i);let l=Object.getOwnPropertyDescriptors(i),c=Array.isArray(i)?[]:Object.create(null);for(let[u,p]of Object.entries(l)){if(Array.isArray(i)&&u==="length")continue;if(!p.enumerable||!("value"in p))throw new U("NON_JSON","Hidden fields and accessors cannot be serialized faithfully",s+"/"+$e(u));if(Array.isArray(i)&&!/^(0|[1-9][0-9]*)$/.test(u))throw new U("NON_JSON","Non-index array property",s);let d=r(p.value,s+"/"+$e(u),o+1);Object.defineProperty(c,u,{value:d,enumerable:!0,writable:!0,configurable:!0})}if(Array.isArray(i)&&Object.keys(i).length!==i.length)throw new U("NON_JSON","Sparse arrays are not JSON values",s);return t.delete(i),c}return r(e,"",0)}function nB(e){if(e&&typeof e==="object"){Object.freeze(e);for(let t of Object.values(e))nB(t)}}class nt{#e=new Map;register(e,t){let n=Ae(e);if(!C1(n))throw new U("PACKAGE_STRUCTURE",JSON.stringify(C1.errors));if(this.get(n.id,n.version))throw new U("DUPLICATE_VERSION","Extension version is already registered");let r;try{r=mt().compile(n.schema)}catch(s){throw new U("PACKAGE_SCHEMA",String(s))}nB(n);let i={manifest:n,structure:r,...t?{semantics:t}:{}};if(Object.freeze(i),!this.#e.has(n.id))this.#e.set(n.id,new Map);return this.#e.get(n.id).set(n.version,i),this}get(e,t){return this.#e.get(e)?.get(t)}}bo();function rB(e){let t=/^([+-]?)(\d*)(?:\.(\d*))?(?:[eE]([+-]?\d+))?$/.exec(e);if(!t)throw new U("NUMBER","Unsupported numeric spelling");let n=((t[2]||"")+(t[3]||"")).replace(/^0+/,"");if(!n)return"0";let r=n.replace(/0+$/,""),i=BigInt(t[4]||"0")-BigInt((t[3]||"").length)+BigInt(n.length-r.length);return`${t[1]==="-"?"-":""}${r}e${i}`}function ys(e,t="yaml"){if(e.length>Zt.maxTextLength)throw new U("LIMIT","Source text exceeds limit");if(t==="json")try{JSON.parse(e)}catch{throw new U("SYNTAX","Invalid JSON syntax")}let n=go(e,{version:"1.2",schema:"core",uniqueKeys:!0,intAsBigInt:!0,strict:!0});if(n.errors.length||n.warnings.length)throw new U("SYNTAX",[...n.errors,...n.warnings].map((s)=>s.message).join("; "));if(n.directives?.yaml.version!=="1.2")throw new U("SYNTAX","Only YAML 1.2 is supported");let r=0;function i(s,o,a){if(++r>Zt.maxValues||a>Zt.maxDepth)throw new U("LIMIT","Source structural limit exceeded",o);if(s===null)return null;if(Ks(s))throw new U("ALIAS","YAML aliases are outside the JSON-compatible profile",o);if((ft(s)||dr(s)||Hr(s))&&s.tag)throw new U("TAG","Explicit YAML tags are outside the profile",o);if(ft(s)){let l=s.value;if(typeof l==="bigint"){let c=Number(l);if(!Number.isSafeInteger(c))throw new U("NUMBER","Integer exceeds exact JavaScript range",o);l=c}if(typeof l==="number"&&s.source){if(Number.isFinite(l)&&!/^[-+]?0[xo]/i.test(s.source)&&rB(s.source)!==rB(String(l)))throw new U("NUMBER","Parsing would change the decimal value",o);if(/^-0(?:\.0*)?(?:[eE][+-]?\d+)?$/.test(s.source))throw new U("NUMBER","Negative zero is outside the numeric profile",o)}return Ae(l)}if(Hr(s))return s.items.map((l,c)=>i(l,`${o}/${c}`,a+1));if(dr(s)){let l=Object.create(null);for(let c of s.items){if(!ft(c.key)||typeof c.key.value!=="string"||c.key.tag)throw new U("KEY","Mappings require untagged string keys",o);let u=c.key.value;if(Object.hasOwn(l,u))throw new U("DUPLICATE_KEY","Duplicate mapping key",o);l[u]=i(c.value,`${o}/${$e(u)}`,a+1)}return l}throw new U("NON_JSON","Unsupported YAML node",o)}return i(n.contents,"",0)}function M1(e,t="yaml"){let n=Ae(e),r=t==="json"?JSON.stringify(n,null,2)+` +`:Ul(n,{version:"1.2",aliasDuplicateObjects:!1,lineWidth:0});if(r.length>Zt.maxTextLength)throw new U("LIMIT","Serialized text exceeds limit");return r}var i0={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:core:0.8.0",title:"UMF 0.8.0 schema properties",type:"object",required:["umf","id","vocabularies","modules"],properties:{umf:{const:"0.8.0"},id:{$ref:"#/$defs/id"},vocabularies:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:{type:"object",required:["version"],properties:{version:{$ref:"#/$defs/version"}}}},modules:{type:"array",items:{$ref:"#/$defs/module"}},extensions:{$ref:"#/$defs/extensions"},title:{type:"string"},aliases:{type:"array",uniqueItems:!0,items:{type:"string",minLength:1}}},$defs:{id:{type:"string",minLength:1},version:{type:"string",pattern:"^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"},knownScalarType:{enum:["boolean","integer","decimal","float","string","binary","date","time","timestamp"],description:"Basic value families; native refinements remain authoritative for ranges, precision, encoding and temporal behavior."},scalarType:{anyOf:[{$ref:"#/$defs/knownScalarType"},{type:"string",minLength:1,not:{$ref:"#/$defs/knownScalarType"},description:"Unknown family retained with incomplete semantic validation."}]},extensions:{type:"object",propertyNames:{$ref:"#/$defs/id"},additionalProperties:!0},reference:{type:"object",required:["role","module","element"],properties:{role:{$ref:"#/$defs/id"},module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},element:{type:"object",required:["id","extensions"],properties:{id:{$ref:"#/$defs/id"},name:{type:"string"},description:{type:"string"},scalarType:{$ref:"#/$defs/scalarType"},extensions:{$ref:"#/$defs/extensions"},references:{type:"array",items:{$ref:"#/$defs/reference"}},kind:{type:"string",minLength:1,description:"UMF role; unknown labels remain uninterpreted. Missing is unspecified, never inferred from scalarType."},nullability:{type:"string",minLength:1,description:"Ideal value availability. Unknown labels remain uninterpreted. Missing and unspecified assert no availability constraint. Native absence carriers require explicit bindings."},cardinality:{type:"string",minLength:1,description:"One ideal value, finite ordered sequence with duplicates allowed, finite exact string-key mapping with unique keys, or no assertion. Unknown labels remain uninterpreted."},itemType:{$ref:"#/$defs/itemType"},facets:{$ref:"#/$defs/facets"},members:{type:"array",uniqueItems:!0,items:{$ref:"#/$defs/keyFieldReference"}},keys:{type:"array",minItems:1,items:{$ref:"#/$defs/key"}},title:{type:"string"},aliases:{type:"array",uniqueItems:!0,items:{type:"string",minLength:1}},examples:{type:"array",items:{$ref:"#/$defs/literal"}},allowedValues:{type:"array",minItems:1,items:{$ref:"#/$defs/literal"}},default:{type:"object",required:["value","on"],properties:{value:{$ref:"#/$defs/literal"},on:{enum:["missing","null","missing-or-null"]}},additionalProperties:!0}},allOf:[{if:{required:["kind"],properties:{kind:{enum:["record","group"]}}},then:{properties:{scalarType:!1}}},{if:{required:["nullability"],properties:{nullability:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["cardinality"],properties:{cardinality:{enum:["array","map"]}}},then:{not:{required:["scalarType"]}}},{if:{required:["itemType"],properties:{itemType:{}}},then:{required:["kind","cardinality"],properties:{kind:{const:"field"},cardinality:{enum:["array","map"]}}}},{if:{required:["facets"],properties:{facets:{}}},then:{required:["kind"],properties:{kind:{const:"field"},references:{type:"array",not:{contains:{type:"object",required:["role"],properties:{role:{const:"record-type"}}}}}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{}}}}},then:{required:["scalarType"],properties:{scalarType:{enum:["string","binary"]}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"unicode-scalar"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"string"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["length"],properties:{length:{type:"object",required:["unit"],properties:{unit:{const:"byte"}}}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"binary"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["precision"],properties:{precision:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"decimal"}}}},{if:{required:["facets"],properties:{facets:{type:"object",required:["integerWidth"],properties:{integerWidth:{}}}}},then:{required:["scalarType"],properties:{scalarType:{const:"integer"}}}},{if:{properties:{members:{}},required:["members"]},then:{required:["kind"],properties:{kind:{const:"record"}}}},{if:{properties:{keys:{}},required:["keys"]},then:{required:["kind","members"],properties:{kind:{const:"record"},members:{}}}},{if:{required:["examples"],properties:{examples:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["allowedValues"],properties:{allowedValues:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}},{if:{required:["default"],properties:{default:{}}},then:{required:["kind"],properties:{kind:{const:"field"}}}}]},module:{type:"object",required:["id","namespace","elements"],properties:{id:{$ref:"#/$defs/id"},namespace:{type:"string"},elements:{type:"array",items:{$ref:"#/$defs/element"}},extensions:{$ref:"#/$defs/extensions"},relationships:{type:"array",items:{$ref:"#/$defs/relationship"}},title:{type:"string"},aliases:{type:"array",uniqueItems:!0,items:{type:"string",minLength:1}}}},knownElementKind:{enum:["field","record","group"]},knownNullability:{enum:["required","absent-allowed","unspecified"]},knownCardinality:{enum:["one","array","map","unspecified"]},itemType:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}}},facets:{type:"object",description:"Missing members impose no bound. Unknown members and qualifiers are retained without interpretation.",properties:{length:{type:"object",required:["unit"],anyOf:[{required:["min"],properties:{min:{}}},{required:["max"],properties:{max:{}}}],properties:{min:{type:"integer",minimum:0,maximum:9007199254740991},max:{type:"integer",minimum:0,maximum:9007199254740991},unit:{type:"string",minLength:1}},additionalProperties:!0},precision:{type:"integer",minimum:1,maximum:9007199254740991,description:"Decimal coefficient digit bound; requires scale. Absolute coefficient is less than 10^precision. No implicit rounding."},scale:{type:"integer",minimum:0,maximum:9007199254740991,description:"Fixed fractional digit count; requires precision. Semantic validation requires scale <= precision. Value equals integer coefficient times 10^-scale."},integerWidth:{type:"object",required:["bits","signed"],properties:{bits:{type:"integer",minimum:1,maximum:9007199254740991},signed:{type:"boolean"}},description:"Signed [-2^(bits-1),2^(bits-1)-1] or unsigned [0,2^bits-1]; mathematical domain, not a physical storage-width assertion."},collectionSize:{type:"object",anyOf:[{required:["min"],properties:{min:{}}},{required:["max"],properties:{max:{}}}],properties:{min:{type:"integer",minimum:0,maximum:9007199254740991},max:{type:"integer",minimum:0,maximum:9007199254740991}},additionalProperties:!0},range:{type:"object",anyOf:[{required:["min"],properties:{min:{}}},{required:["max"],properties:{max:{}}}],properties:{min:{$ref:"#/$defs/literal"},max:{$ref:"#/$defs/literal"},minInclusive:{type:"boolean"},maxInclusive:{type:"boolean"}},additionalProperties:!0}},dependentRequired:{precision:["scale"],scale:["precision"]}},keyFieldReference:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}},additionalProperties:!0},key:{type:"object",required:["id","name","fields"],properties:{id:{$ref:"#/$defs/id"},name:{$ref:"#/$defs/id"},fields:{type:"array",minItems:1,uniqueItems:!0,items:{$ref:"#/$defs/keyFieldReference"}},primary:{type:"boolean"}},additionalProperties:!0},relationshipEndpoint:{type:"object",required:["module","element"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"}},additionalProperties:!0},relationshipTarget:{type:"object",required:["module","element","key"],properties:{module:{$ref:"#/$defs/id"},element:{$ref:"#/$defs/id"},key:{$ref:"#/$defs/id"}},additionalProperties:!0},relationshipMultiplicity:{type:"object",required:["min","max"],properties:{min:{type:"integer",minimum:0,maximum:9007199254740991},max:{anyOf:[{type:"integer",minimum:1,maximum:9007199254740991},{const:"*"}]}},additionalProperties:!0},relationship:{type:"object",required:["id","name","source","target","sourceMultiplicity","targetMultiplicity","targetLifecycle","directed"],properties:{id:{$ref:"#/$defs/id"},name:{$ref:"#/$defs/id"},source:{type:"array",minItems:1,items:{$ref:"#/$defs/relationshipEndpoint"}},target:{type:"array",minItems:1,items:{$ref:"#/$defs/relationshipTarget"}},sourceMultiplicity:{$ref:"#/$defs/relationshipMultiplicity"},targetMultiplicity:{$ref:"#/$defs/relationshipMultiplicity"},targetLifecycle:{type:"string",minLength:1},directed:{type:"boolean"},inverse:{$ref:"#/$defs/id"},associationRecord:{$ref:"#/$defs/relationshipEndpoint"}},additionalProperties:!0},literal:{oneOf:[{type:"null"},{type:"object",required:["boolean"],properties:{boolean:{type:"boolean"}},additionalProperties:!1},{type:"object",required:["integerToken"],properties:{integerToken:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$(?![\\s\\S])"}},additionalProperties:!1},{type:"object",required:["decimalToken"],properties:{decimalToken:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$(?![\\s\\S])"}},additionalProperties:!1},{type:"object",required:["string"],properties:{string:{type:"string"}},additionalProperties:!1},{type:"object",required:["binaryHex"],properties:{binaryHex:{type:"string",pattern:"^([0-9a-fA-F]{2})*$(?![\\s\\S])"}},additionalProperties:!1},{type:"object",required:["floatToken"],properties:{floatToken:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$(?![\\s\\S])"}},additionalProperties:!1},{type:"object",required:["date"],properties:{date:{type:"string"}},additionalProperties:!1},{type:"object",required:["time"],properties:{time:{type:"string"}},additionalProperties:!1},{type:"object",required:["timestamp"],properties:{timestamp:{type:"string"}},additionalProperties:!1},{type:"object",required:["array"],properties:{array:{type:"array",items:{$ref:"#/$defs/literal"}}},additionalProperties:!1},{type:"object",required:["map"],properties:{map:{type:"object",additionalProperties:{$ref:"#/$defs/literal"}}},additionalProperties:!1}]}},description:"Shared annotations, literal defaults and exact value/collection bounds; semantic validator required.",$comment:"Exact endpoint/key resolution, unique IDs/names, inverse collisions, multiplicity bounds and lifecycle coherence require portable semantic validation."};var iB=["title","aliases","examples","allowedValues","default"],sB=["collectionSize","range"];function on(e,t=""){throw new U("CORE_SCHEMA_PROPERTIES",e,t)}var nm=(e)=>e;function Wp(e,t,n){if(e===null||typeof e!=="object"||Array.isArray(e))on("Expected object",n);for(let r of Object.keys(e))if(!t.includes(r))throw new U("CORE_SCHEMA_PROPERTY_UNKNOWN","Unknown relevant qualifier: "+r,n+"/"+r)}function fu(e,t,n){let r=/^(-?)(0|[1-9][0-9]*)(?:\.([0-9]+))?(?:[eE]([+-]?[0-9]+))?$/.exec(e);if(!r||r[0]!==e)on("Expected exact JSON numeric token");let i=(r[2]+(r[3]??"")).replace(/^0+/,"");if(!i)return 0n;let s=r[4]??"0";if(s.length>32)on("Numeric exponent exceeds bounded domain");let o=BigInt(s)-BigInt((r[3]??"").length)+BigInt(t),a=i;if(o<0n){let l=-o;if(l>BigInt(i.length))on("Numeric value would require rounding");let c=i.length-Number(l);if(/[^0]/.test(i.slice(c)))on("Numeric value would require rounding");a=i.slice(0,c)}else{if(BigInt(i.length)+o>BigInt(Math.min(n??Zt.maxTextLength,Zt.maxTextLength)))on("Numeric value exceeds precision/resource limit");a+="0".repeat(Number(o))}if(n!==void 0&&a.length>n)on("Numeric value exceeds precision");return BigInt((r[1]??"")+(a||"0"))}function oB(e){let t=0;for(let n=0;n=55296&&r<=56319){let i=e.charCodeAt(++n);if(!(i>=56320&&i<=57343))on("Unpaired Unicode surrogate")}else if(r>=56320&&r<=57343)on("Unpaired Unicode surrogate")}return t}function ag(e,t){if(t===null)on("Null has no allowed-value equality");let n=nm(t),r=Object.keys(n),i=e.scalarType,s={boolean:"boolean",integer:"integerToken",decimal:"decimalToken",string:"string",binary:"binaryHex"}[i];if(!s||r.length!==1||r[0]!==s)on("No exact equality for this literal/domain");let o=nm(e.facets??{});if(i==="integer")return"integer:"+fu(n[s],0);if(i==="decimal"){if(!Number.isSafeInteger(o.scale)||!Number.isSafeInteger(o.precision))on("Decimal requires explicit precision/scale");return"decimal:"+fu(n[s],o.scale,o.precision)}if(i==="string")return oB(n.string),"string:"+JSON.stringify(n.string);if(i==="binary"){if(typeof n.binaryHex!=="string"||!/^(?:[0-9a-fA-F]{2})*$(?![\s\S])/.test(n.binaryHex))on("Expected hexadecimal bytes");return"binary:"+n.binaryHex.toLowerCase()}if(typeof n.boolean!=="boolean")on("Expected boolean literal");return"boolean:"+n.boolean}function rm(e,t,n,r=!0,i=0){if(i>Zt.maxDepth)on("Literal recursion exceeds limit");if(t.kind!=="field")on("Literal target must be a Field");if(t.references?.some((a)=>a.role==="record-type"))on("Record-valued literals require a separate contract");if(t.itemType)Wp(t.itemType,["module","element"],"/itemType");let s=nm(t.facets??{});Wp(s,["length","precision","scale","integerWidth","range","collectionSize"],"/facets");for(let[a,l]of Object.entries({length:["min","max","unit"],integerWidth:["bits","signed"],range:["min","max","minInclusive","maxInclusive"],collectionSize:["min","max"]}))if(s[a])Wp(s[a],l,"/facets/"+a);if(n===null){if(t.nullability!=="absent-allowed")on("Null requires explicit absent-allowed");return}let o=nm(n);if(!o||typeof o!=="object"||Array.isArray(o)||Object.keys(o).length!==1)on("Expected one typed literal wrapper");if(t.cardinality==="array"||t.cardinality==="map"){let a=t.cardinality,l=o[a];if(a==="array"?!Array.isArray(l):!l||typeof l!=="object"||Array.isArray(l))on("Container literal does not match Field");let c=nm(t.itemType);if(!c)on("Container literal requires explicit itemType");let u=e.modules.find((f)=>f.id===c.module)?.elements.find((f)=>f.id===c.element);if(!u)on("Unresolved itemType");let p=a==="array"?l:Object.values(l),d=s.collectionSize;if(d){if(Wp(d,["min","max"],"/facets/collectionSize"),d.min!==void 0&&p.lengthd.max)on("Collection size outside bounds")}for(let f of p)rm(e,u,f,r,i+1)}else{if(t.cardinality!==void 0&&!["one","unspecified"].includes(t.cardinality))on("Unknown cardinality");let a=t.scalarType,l={boolean:"boolean",integer:"integerToken",decimal:"decimalToken",string:"string",binary:"binaryHex",float:"floatToken",date:"date",time:"time",timestamp:"timestamp"}[a];if(!l||!Object.hasOwn(o,l))on("Literal does not match scalar family");if(["float","date","time","timestamp"].includes(a)){if(r)on("Value/default semantics for float/temporal domain are not defined");if(typeof o[l]!=="string")on("Expected literal text");return}ag(t,n);let c;if(a==="string")c=oB(o.string);if(a==="binary")c=o.binaryHex.length/2;if(s.length){if(Wp(s.length,["min","max","unit"],"/facets/length"),s.length.unit!==(a==="string"?"unicode-scalar":"byte"))on("Unknown/incompatible length unit");if(c===void 0)on("Length requires string/binary");if(s.length.min!==void 0&&cs.length.max)on("Literal length outside bounds")}if(s.integerWidth){Wp(s.integerWidth,["bits","signed"],"/facets/integerWidth");let u=s.integerWidth,p=fu(o.integerToken,0),d=p<0n?-p:p,f=d===0n?0:d.toString(2).length;if(!(u.signed?p<0n?f=0n&&f<=u.bits))on("Integer outside width/signedness")}if(r&&s.range){Wp(s.range,["min","max","minInclusive","maxInclusive"],"/facets/range");let u=s.range,p=a==="decimal"?s.scale:0,d=fu(o[l],p,s.precision);for(let f of["min","max"])if(u[f]!==void 0){if(u[f]===null)on("Numeric bounds cannot be null","/facets/range/"+f);let m=fu(nm(u[f])[l],p,s.precision);if(f==="min"?dm||d===m&&u.maxInclusive===!1)on("Literal outside numeric range")}}}if(r&&t.allowedValues){if(!t.allowedValues.some((a)=>ag(t,a)===ag(t,n)))on("Literal is not an allowed value")}}var cB=mt(),aB=cB.compile(i0),_ze=cB.compile({$defs:i0.$defs,$ref:"#/$defs/literal"});function dve(e){let t=Ae(e);t.umf="0.7.0";for(let n of[t,...t.modules])for(let r of["title","aliases"])delete n[r];for(let n of t.modules.flatMap((r)=>r.elements))for(let r of iB)delete n[r];for(let n of t.modules)for(let r of n.elements){let i=r.facets;if(!i)continue;for(let s of sB)delete i[s];if(i.length){if(delete i.length.min,i.length.max===void 0||i.length.max===0)delete i.length}if(["array","map"].includes(r.cardinality))delete r.facets}return t}function lB(e,t,n){let r=e.facets;if(e.scalarType==="decimal"){if(n==="min"?t>=0n:t<=0n)return!1;let o=(t<0n?-t:t).toString();return o.length===r.precision&&/^9+$/.test(o)}let i=r.integerWidth;if(!i)return!1;if(n==="min"){if(!i.signed)return t===0n;let o=-t;return t<0n&&o.toString(2).length===i.bits&&(o&o-1n)===0n}if(t<0n)return!1;return(t===0n?0:t.toString(2).length)===i.bits-(i.signed?1:0)&&(t&t+1n)===0n}function uB(e,t=new nt){let n=[],r=(a,l,c="error",u="CORE_SCHEMA_PROPERTIES")=>n.push({code:u,path:l,message:a,severity:c}),i;try{i=Ae(e)}catch(a){if(!(a instanceof U))throw a;return r(a.message,a.path),{valid:!1,complete:!1,diagnostics:n}}if(!aB(i)){for(let a of aB.errors??[])r(a.message??"Invalid schema properties",a.instancePath);return{valid:!1,complete:!1,diagnostics:n}}let s=new class extends nt{get(a,l){let c=t.get(a,l);if(!c?.semantics)return c;let u=c.semantics;return{...c,semantics:(p,d)=>u(p,{...d,document:Ae(i)})}}};n.push(...We(dve(i),s).diagnostics);let o=(a,l,c)=>{for(let u of Object.keys(a))if(!l.includes(u))r("Qualifier retained without interpretation",c+"/"+$e(u),"warning","UNKNOWN_SCHEMA_PROPERTY")};return i.modules.forEach((a,l)=>a.elements.forEach((c,u)=>{let p=`/modules/${l}/elements/${u}`,d=c.facets,f=(m,y)=>{try{m()}catch(h){if(!(h instanceof U))throw h;r(h.message,y+(h.path||""),h.code==="CORE_SCHEMA_PROPERTY_UNKNOWN"?"warning":"error",h.code)}};if(d){if(["array","map"].includes(c.cardinality))o(d,["length","precision","scale","integerWidth","collectionSize","range"],p+"/facets");for(let m of["length","collectionSize"])if(d[m]){let y=d[m];o(y,m==="length"?["min","max","unit"]:["min","max"],p+"/facets/"+m);let h=p+"/facets/length/unit";if(m==="length"&&!["unicode-scalar","byte"].includes(y.unit)&&!n.some((b)=>b.code==="UNKNOWN_FACET_UNIT"&&b.path===h))r("Length unit retained without interpretation",h,"warning","UNKNOWN_FACET_UNIT");if(y.min!==void 0&&y.max!==void 0&&y.min>y.max)r("Minimum exceeds maximum",p+"/facets/"+m);if(m==="collectionSize"&&(c.kind!=="field"||!["array","map"].includes(c.cardinality)))r("Collection bounds require array/map Field",p+"/facets/"+m)}if(d.range){let m=d.range;if(o(m,["min","max","minInclusive","maxInclusive"],p+"/facets/range"),c.kind!=="field"||!["integer","decimal"].includes(c.scalarType))r("Range requires integer/decimal Field",p+"/facets/range");else f(()=>{let y={};for(let D of["precision","scale"])if(Object.hasOwn(d,D))y[D]=d[D];if(d.integerWidth)y.integerWidth={bits:d.integerWidth.bits,signed:d.integerWidth.signed};let h={...c,facets:y};delete h.allowedValues,delete h.default;for(let D of["min","max"])if(m[D]!==void 0){if(m[D]===null)throw new U("CORE_SCHEMA_PROPERTIES","Numeric bounds cannot be null","/"+D);rm(i,h,m[D])}else if(m[D+"Inclusive"]!==void 0)r("Inclusive flag requires its bound",p+"/facets/range/"+D+"Inclusive");let b=c.scalarType==="integer"?"integerToken":"decimalToken",g=c.scalarType==="integer"?0:d.scale,x=m.min===void 0?void 0:fu(m.min[b],g,d.precision),v=m.max===void 0?void 0:fu(m.max[b],g,d.precision);if(x!==void 0&&v!==void 0&&x+(m.minInclusive===!1?1n:0n)>v-(m.maxInclusive===!1?1n:0n)||x!==void 0&&m.minInclusive===!1&&lB(c,x,"max")||v!==void 0&&m.maxInclusive===!1&&lB(c,v,"min"))r("Empty or inverted numeric interval",p+"/facets/range")},p+"/facets/range")}}if(c.allowedValues)f(()=>{let m=new Set;for(let[y,h]of c.allowedValues.entries()){let b={...c};delete b.allowedValues,rm(i,b,h);let g=ag(b,h);if(m.has(g))r("Duplicate equal allowed value",p+"/allowedValues/"+y);m.add(g)}},p+"/allowedValues");if(c.examples)for(let[m,y]of c.examples.entries())f(()=>rm(i,c,y,!1),p+"/examples/"+m);if(c.default){let m=c.default;o(m,["value","on"],p+"/default"),f(()=>rm(i,c,m.value),p+"/default/value")}})),{valid:!n.some((a)=>a.severity==="error"),complete:n.length===0,diagnostics:n}}var pB=mt().compile(n0),s0=(e)=>JSON.stringify([e.module,e.element]);function o0(e,t=!0){let n=[],r=(c,u,p,d="error")=>n.push({code:c,path:u,message:p,severity:d}),i;try{i=Ae(e)}catch(c){if(!(c instanceof U))throw c;return r(c.code,c.path,c.message),{valid:!1,complete:!1,diagnostics:n}}if(!pB(i)){for(let c of pB.errors??[])r("KEY_STRUCTURE",c.instancePath,c.message??"Invalid key envelope");return{valid:!1,complete:!1,diagnostics:n}}let s=Ae(i);s.umf="0.5.0";for(let c of s.modules)for(let u of c.elements)delete u.members,delete u.keys;if(t)n.push(...We(s).diagnostics);let o=(c,u,p)=>{for(let d of Object.keys(c))if(!u.includes(d))r("UNKNOWN_KEY_QUALIFIER",p+"/"+$e(d),"Qualifier retained without interpretation","warning")},a=new Map,l=new Map;for(let c of i.modules)for(let u of c.elements)a.set(s0({module:c.id,element:u.id}),u);return i.modules.forEach((c,u)=>c.elements.forEach((p,d)=>{let f=`/modules/${u}/elements/${d}`,m=p.members;if(!m)return;let y=new Set;m.forEach((v,D)=>{let T=f+`/members/${D}`,N=s0(v),O=a.get(N);if(o(v,["module","element"],T),y.has(N))r("KEY_DUPLICATE_MEMBER",T,"Record membership repeats a Field identity");if(y.add(N),!O)r("KEY_MEMBER_MISSING",T,"Member Field does not exist");else if(O.kind!=="field")r("KEY_MEMBER_KIND",T,"Record members must be explicit Fields");let C=l.get(N);if(C&&C!==f)r("KEY_MEMBER_OWNER",T,"Field already belongs to another Record: "+C);else l.set(N,f)});let h=new Set,b=new Set,g=new Set,x=0;p.keys?.forEach((v,D)=>{let T=f+`/keys/${D}`;if(o(v,["id","name","fields","primary"],T),h.has(v.id))r("KEY_DUPLICATE_ID",T+"/id","Key ID is not unique within the Record");if(h.add(v.id),b.has(v.name))r("KEY_DUPLICATE_NAME",T+"/name","Key name is not unique within the Record");if(b.add(v.name),v.primary===!0&&++x>1)r("KEY_PRIMARY_COUNT",T+"/primary","At most one key may be primary");let N=v.fields.map(s0),O=JSON.stringify([...N].sort());if(new Set(N).size!==N.length)r("KEY_DUPLICATE_FIELD",T+"/fields","Key repeats a Field identity");if(g.has(O))r("KEY_DUPLICATE_SET",T+"/fields","Key component set duplicates another key, regardless of order");g.add(O),v.fields.forEach((C,X)=>{let te=T+`/fields/${X}`,L=s0(C),Y=a.get(L);if(o(C,["module","element"],te),!y.has(L))r("KEY_FIELD_OWNER",te,"Key component is not a member of its owning Record");if(!Y){r("KEY_FIELD_MISSING",te,"Key Field does not exist");return}if(Y.kind!=="field")r("KEY_FIELD_KIND",te,"Key component must be an explicit Field");if(Y.nullability!=="required")r("KEY_FIELD_REQUIRED",te,"Key component must explicitly supply a value");if(Y.cardinality!=="one")r("KEY_FIELD_SINGULAR",te,"Key component must explicitly be singular");if(!["boolean","integer","decimal","string","binary"].includes(Y.scalarType??"")||Y.references?.some((me)=>me.role==="record-type"))r("KEY_EQUALITY",te,"Key equality is undefined for this component");if(Y.scalarType==="decimal"){let me=Y.facets;if(!me||me.precision===void 0||me.scale===void 0)r("KEY_DECIMAL_DOMAIN",te,"Decimal key equality requires explicit precision and scale")}})})})),{valid:!n.some((c)=>c.severity==="error"),complete:n.length===0,diagnostics:n}}var dB=mt().compile(t0),L1=(e)=>JSON.stringify([e.module,e.element]);function fB(e,t=!0){let n=[],r=(p,d,f,m="error")=>n.push({code:p,path:d,message:f,severity:m}),i;try{i=Ae(e)}catch(p){if(!(p instanceof U))throw p;return r(p.code,p.path,p.message),{valid:!1,complete:!1,diagnostics:n}}if(!dB(i)){for(let p of dB.errors??[])r("RELATIONSHIP_STRUCTURE",p.instancePath,p.message??"Invalid relationship envelope");return{valid:!1,complete:!1,diagnostics:n}}let s=Ae(i);s.umf="0.6.0";for(let p of s.modules)delete p.relationships;n.push(...o0(s,t).diagnostics);let o=(p,d,f)=>{for(let m of Object.keys(p))if(!d.includes(m))r("UNKNOWN_RELATIONSHIP_QUALIFIER",f+"/"+$e(m),"Qualifier retained without interpretation","warning")},a=new Map;for(let p of i.modules)for(let d of p.elements)a.set(L1({module:p.id,element:d.id}),d);let l=new Map,c=(p,d,f,m)=>{let y=JSON.stringify([p.module,p.element,d]),h=l.get(y)??[],b=h.find((g)=>m||g.inverse);if(b)r("RELATIONSHIP_PRESENTATION_COLLISION",f,"Inverse presentation collides on this endpoint with "+b.path);h.push({path:f,inverse:m}),l.set(y,h)},u=(p,d)=>{let f=a.get(L1(p));if(!f){r("RELATIONSHIP_ENDPOINT_MISSING",d,"Endpoint does not resolve by exact module and element IDs");return}if(f.kind!=="record"){r("RELATIONSHIP_ENDPOINT_KIND",d,"Endpoint must be a Record");return}if(!Array.isArray(f.keys)||!f.keys.length)r("RELATIONSHIP_ENDPOINT_KEY",d,"Endpoint must have authored Keys");return f};return i.modules.forEach((p,d)=>{let f=new Set,m=new Set;(p.relationships??[]).forEach((y,h)=>{let b=`/modules/${d}/relationships/${h}`;if(o(y,["id","name","source","target","sourceMultiplicity","targetMultiplicity","targetLifecycle","directed","inverse","associationRecord"],b),f.has(y.id))r("RELATIONSHIP_DUPLICATE_ID",b+"/id","Relationship ID must be unique in its module");if(f.add(y.id),m.has(y.name))r("RELATIONSHIP_DUPLICATE_NAME",b+"/name","Relationship name must be unique in its module");m.add(y.name);for(let g of["source","target"]){let x=new Set;y[g].forEach((D,T)=>{let N=b+`/${g}/${T}`;o(D,g==="target"?["module","element","key"]:["module","element"],N);let O=L1(D);if(x.has(O))r("RELATIONSHIP_DUPLICATE_ENDPOINT",N,"Endpoint Record repeats, regardless of qualifiers or target key");x.add(O);let C=u(D,N);if(g==="target"&&C&&!(C.keys??[]).some((X)=>X.id===D.key))r("RELATIONSHIP_TARGET_KEY",N+"/key","Target key must resolve by its stable ID");if(g==="source")c(D,y.name,N,!1);else if(y.inverse)c(D,y.inverse,b+"/inverse",!0)});let v=y[g+"Multiplicity"];if(o(v,["min","max"],b+"/"+g+"Multiplicity"),v.max!=="*"&&v.maxp.severity==="error"),complete:n.length===0,diagnostics:n}}var mB=mt().compile({$defs:r0.$defs,$ref:"#/$defs/element"});function yB(e,t=""){let n=[],r=(s,o,a,l="error")=>n.push({code:s,path:t+o,message:a,severity:l}),i;try{i=Ae(e)}catch(s){if(!(s instanceof U))throw s;return r(s.code,s.path,s.message),{valid:!1,complete:!1,diagnostics:n}}if(!mB(i)){for(let s of mB.errors??[])r("FACET_STRUCTURE",s.instancePath,s.message??"Invalid facet element");return{valid:!1,complete:!1,diagnostics:n}}if(Object.hasOwn(i,"facets")){let s=i.facets,o=(a,l,c)=>{for(let u of Object.keys(a))if(!l.includes(u))r("UNKNOWN_FACET",c+"/"+$e(u),"Facet member retained without interpretation","warning")};if(o(s,["length","precision","scale","integerWidth"],"/facets"),Object.hasOwn(s,"precision")&&s.scale>s.precision)r("FACET_SCALE","/facets/scale","Scale must not exceed precision");if(Object.hasOwn(s,"length")){let a=s.length;if(o(a,["max","unit"],"/facets/length"),a.unit!=="unicode-scalar"&&a.unit!=="byte")r("UNKNOWN_FACET_UNIT","/facets/length/unit","Length unit retained without interpretation","warning")}if(Object.hasOwn(s,"integerWidth"))o(s.integerWidth,["bits","signed"],"/facets/integerWidth")}return{valid:!n.some((s)=>s.severity==="error"),complete:n.length===0,diagnostics:n}}function We(e,t=new nt){let n=[],r=(b,g,x,v="error")=>n.push({code:b,path:g,message:x,severity:v}),i;try{i=Ae(e)}catch(b){if(!(b instanceof U))throw b;return r(b.code,b.path,b.message),{valid:!1,complete:!1,diagnostics:n}}let s=i?.umf;if(s==="0.8.0")return uB(i,t);let o=s==="0.7.0"?Y3:s==="0.6.0"?Q3:s==="0.5.0"?W3:s==="0.4.0"?z3:s==="0.3.0"?H3:s==="0.2.0"?G3:J3;if(!o(i)){for(let b of o.errors||[])r("STRUCTURE",b.instancePath,b.message||"Invalid structure");return{valid:!1,complete:!1,diagnostics:n}}let a=i,l=a.umf==="0.7.0",c=a.umf==="0.6.0"||l,u=a.umf==="0.5.0"||c,p=a.umf==="0.4.0"||u,d=a.umf==="0.3.0"||p,f=(b,g,x)=>{for(let v of Object.keys(b))if(!g.includes(v))r("UNKNOWN_CORE_FIELD",`${x}/${$e(v)}`,"Field retained without interpretation","warning")};f(a,["umf","id","vocabularies","modules","extensions"],"");for(let[b,g]of Object.entries(a.vocabularies))if(f(g,["version"],`/vocabularies/${$e(b)}`),!t.get(b,g.version))r("UNKNOWN_EXTENSION",`/vocabularies/${$e(b)}`,"Exact extension version unavailable; content retained","warning");let m=(b,g,x)=>{for(let[v,D]of Object.entries(b||{})){let T=`${x}/extensions/${$e(v)}`;if(!Object.hasOwn(a.vocabularies,v)){r("UNDECLARED_EXTENSION",T,"Extension has no version declaration");continue}let N=a.vocabularies[v],O=t.get(v,N.version);if(!O)continue;if(!O.manifest.scopes.includes(g)){r("EXTENSION_SCOPE",T,"Extension not permitted at this scope");continue}if(!O.structure(D)){for(let C of O.structure.errors||[])r("EXTENSION_STRUCTURE",T+C.instancePath,C.message||"Invalid payload");continue}if(O.manifest.capabilities.validation!=="semantic"||!O.semantics)r("SEMANTICS_UNCHECKED",T,"Structure checked; semantics not validated","warning");else try{n.push(...O.semantics(Ae(D),{document:Ae(a),path:T,scope:g}))}catch(C){r("VALIDATOR_FAILURE",T,String(C))}}};m(a.extensions,"document","");let y=new Map,h=new Map;if(a.modules.forEach((b,g)=>{let x=`/modules/${g}`;if(f(b,["id","namespace","elements","extensions",...l?["relationships"]:[]],x),y.has(b.id))r("DUPLICATE_MODULE",x+"/id","Module id is not unique");let v=new Set;y.set(b.id,v),h.set(b.id,new Map(b.elements.map((D)=>[D.id,D]))),m(b.extensions,"module",x),b.elements.forEach((D,T)=>{let N=`${x}/elements/${T}`;if(f(D,["id","name","description","scalarType","extensions","references",...a.umf!=="0.1.0"?["kind"]:[],...d?["nullability"]:[],...p?["cardinality","itemType"]:[],...u?["facets"]:[],...c?["keys","members"]:[]],N),a.umf!=="0.1.0"&&D.kind!==void 0&&!Z3.includes(D.kind))r("UNKNOWN_ELEMENT_KIND",N+"/kind","Kind retained without interpretation","warning");if(d&&D.nullability!==void 0&&!eB.includes(D.nullability))r("UNKNOWN_NULLABILITY",N+"/nullability","Availability label retained without interpretation","warning");if(p&&D.cardinality!==void 0&&!tB.includes(D.cardinality))r("UNKNOWN_CARDINALITY",N+"/cardinality","Container label retained without interpretation","warning");if(p&&D.itemType)f(D.itemType,["module","element"],N+"/itemType");if(u&&Object.hasOwn(D,"facets"))n.push(...yB(D,N).diagnostics);if(D.scalarType!==void 0&&!X3.includes(D.scalarType))r("UNKNOWN_SCALAR_TYPE",N+"/scalarType","Scalar family retained without interpretation","warning");if(v.has(D.id))r("DUPLICATE_ELEMENT",N+"/id","Element id is not unique within module");v.add(D.id),m(D.extensions,"element",N),D.references?.forEach((O,C)=>f(O,["role","module","element"],`${N}/references/${C}`))})}),a.modules.forEach((b,g)=>b.elements.forEach((x,v)=>x.references?.forEach((D,T)=>{if(!y.get(D.module)?.has(D.element))r("UNRESOLVED_REFERENCE",`/modules/${g}/elements/${v}/references/${T}`,"Target element does not exist in supplied document")}))),p)a.modules.forEach((b,g)=>b.elements.forEach((x,v)=>{if(!Object.hasOwn(x,"itemType"))return;let D=x.itemType,T=h.get(D.module)?.get(D.element),N=`/modules/${g}/elements/${v}/itemType`;if(!T)r("UNRESOLVED_ITEM_TYPE",N,"Item/value Field does not exist in supplied document");else if(T.kind!=="field")r("ITEM_TYPE_ROLE",N,"Item/value definition must be an explicit Field")}));if(l)n.push(...fB(a,!1).diagnostics);else if(c)n.push(...o0(a,!1).diagnostics);return{valid:!n.some((b)=>b.severity==="error"),complete:n.length===0,diagnostics:n}}function hB(e,t="yaml"){let n=ys(e,t),r=We(n);if(!r.valid)throw new U("INVALID_DOCUMENT",JSON.stringify(r.diagnostics));return n}bo();function Jt(e){if(e.length>Zt.maxTextLength)throw new U("LIMIT","Native JSON exceeds text limit");try{JSON.parse(e)}catch{throw new U("JSON_SCHEMA_SYNTAX","Invalid native JSON")}let t=go(e,{version:"1.2",schema:"core",intAsBigInt:!0,uniqueKeys:!0,strict:!0});if(t.errors.length||t.warnings.length)throw new U("JSON_SCHEMA_SYNTAX",[...t.errors,...t.warnings].map((i)=>i.message).join("; "));let n=0;function r(i,s){if(s>Zt.maxDepth||++n>Zt.maxValues)throw new U("LIMIT","Native JSON structural limit exceeded");if(ft(i)){if(i.value===null)return{kind:"null"};if(typeof i.value==="number"||typeof i.value==="bigint")return{kind:"number",value:i.source};if(typeof i.value==="string")return{kind:"string",value:i.value};if(typeof i.value==="boolean")return{kind:"boolean",value:i.value}}if(Hr(i))return{kind:"array",items:i.items.map((o)=>r(o,s+1))};if(dr(i)){let o=Object.create(null);for(let a of i.items){if(!ft(a.key)||typeof a.key.value!=="string")throw new U("JSON_SCHEMA_SYNTAX","Non-string JSON key");o[a.key.value]=r(a.value,s+1)}return{kind:"object",members:o}}throw new U("JSON_SCHEMA_SYNTAX","Unexpected native JSON node")}return r(t.contents,0)}function Be(e){switch(e.kind){case"null":return"null";case"number":return e.value;case"boolean":case"string":return JSON.stringify(e.value);case"array":return"["+e.items.map(Be).join(",")+"]";case"object":return"{"+Object.entries(e.members).map(([t,n])=>JSON.stringify(t)+":"+Be(n)).join(",")+"}"}}function Dr(e){if(e==="")return[];if(!e.startsWith("/")||/~(?![01])/u.test(e))throw new U("JSON_SCHEMA_POINTER","Invalid JSON Pointer");return e.slice(1).split("/").map((t)=>t.replace(/~1/g,"/").replace(/~0/g,"~"))}function Tr(e,t){if(e.kind==="object"&&Object.hasOwn(e.members,t))return e.members[t];if(e.kind==="array"&&/^(0|[1-9][0-9]*)$/.test(t)&&Number(t)Zt.maxTextLength)throw new U("LIMIT","Native YAML exceeds text limit");let r=go(e,{version:n,schema:n==="1.1"?"yaml-1.1":"core",intAsBigInt:!0,uniqueKeys:!0,strict:!0,...t.booleanLexicon==="pyyaml"?{customTags:(o)=>o.map((a)=>a.tag==="tag:yaml.org,2002:bool"?{...a,test:new RegExp("^(?![yYnN]$)"+a.test.source,a.test.flags)}:a)}:{}});if(r.errors.length||r.warnings.length)throw new U("NATIVE_YAML_SYNTAX",[...r.errors,...r.warnings].map((o)=>o.message).join("; "));let i=0;function s(o,a){if(a>Zt.maxDepth||++i>Zt.maxValues)throw new U("LIMIT","Native YAML structural limit exceeded");if(o?.tag)throw new U("NATIVE_YAML_TAG","Explicit YAML tags are outside the JSON-compatible profile");if(ft(o)){if(o.value===null)return{kind:"null"};if(typeof o.value==="string")return{kind:"string",value:o.value};if(typeof o.value==="boolean")return{kind:"boolean",value:o.value};if(o.value instanceof Date&&t.dateOnly==="string"&&/^\d{4}-\d{2}-\d{2}$/.test(o.source??""))return{kind:"string",value:o.source};if(typeof o.value==="bigint")return{kind:"number",value:o.source==="-0"?"-0":o.value.toString()};if(typeof o.value==="number"){let l=n==="1.1"?o.source.replaceAll("_",""):o.source;if(l=l.replace(/^\+/,"").replace(/^(-?)\./,"$10.").replace(/\.(?=e|$)/i,".0").replace(/^(-?)0+(?=[0-9])/,"$1"),!/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$/.test(l))throw new U("NATIVE_YAML_NUMBER","Unsupported exact numeric spelling");return{kind:"number",value:l}}}if(Hr(o))return{kind:"array",items:o.items.map((l)=>s(l,a+1))};if(dr(o)){let l=Object.create(null);for(let c of o.items){if(!ft(c.key)||typeof c.key.value!=="string"||c.key.tag)throw new U("NATIVE_YAML_KEY","JSON-compatible YAML requires untagged string keys");l[c.key.value]=s(c.value,a+1)}return{kind:"object",members:l}}if(o===null)return{kind:"null"};throw new U("NATIVE_YAML_NODE","Aliases and non-JSON YAML nodes are unsupported")}return s(r.contents,0)}var fve="https://json-schema.org/draft/2020-12/schema",gB="umf.json-schema",mve=M3,bB=mt().compile(C3),wB=new Set(["items","additionalProperties","contains","not","if","then","else","unevaluatedItems","unevaluatedProperties","propertyNames","contentSchema"]),DB=new Set(["properties","patternProperties","$defs","dependentSchemas","definitions"]),TB=new Set(["allOf","anyOf","oneOf","prefixItems"]),yve=new Set(["$id","$schema","$ref","$anchor","$dynamicRef","$dynamicAnchor","$vocabulary","$comment","$defs","definitions","type","enum","const","multipleOf","maximum","exclusiveMaximum","minimum","exclusiveMinimum","maxLength","minLength","pattern","maxItems","minItems","uniqueItems","maxContains","minContains","maxProperties","minProperties","required","dependentRequired","title","description","default","deprecated","readOnly","writeOnly","examples","format","contentEncoding","contentMediaType",...wB,...DB,...TB]),hve=new Set(["core","applicator","unevaluated","validation","meta-data","format-annotation","content"].map((e)=>"https://json-schema.org/draft/2020-12/vocab/"+e));function a0(e,t=""){let n=[{pointer:t,node:e}];if(e.kind!=="object")return n;for(let[r,i]of Object.entries(e.members)){let s=t+"/"+$e(r);if(wB.has(r))n.push(...a0(i,s));if(DB.has(r)&&i.kind==="object")for(let[o,a]of Object.entries(i.members))n.push(...a0(a,s+"/"+$e(o)));if(TB.has(r)&&i.kind==="array")i.items.forEach((o,a)=>n.push(...a0(o,s+"/"+a)))}return n}function vB(e){try{if(new URL(e).hash||e.includes("#"))throw Error()}catch{throw new U("JSON_SCHEMA_URI","Retrieval URI must be absolute and fragment-free")}}function gve(e){let t=[];for(let r of Object.keys(e))if(!["dialect","baseUri","root","resources"].includes(r))t.push("/"+$e(r));function n(r,i){let s=r.kind==="null"?["kind"]:r.kind==="object"?["kind","members"]:r.kind==="array"?["kind","items"]:["kind","value"];for(let o of Object.keys(r))if(!s.includes(o))t.push(i+"/"+$e(o));if(r.kind==="object")for(let[o,a]of Object.entries(r.members))n(a,i+"/members/"+$e(o));if(r.kind==="array")r.items.forEach((o,a)=>n(o,i+"/items/"+a))}n(e.root,"/root");for(let[r,i]of Object.entries(e.resources))n(i,"/resources/"+$e(r));return t}function SB(e,t){let n=[],r=(l,c,u,p="warning")=>n.push({code:l,path:t+c,message:u,severity:p});try{vB(e.baseUri);for(let l of Object.keys(e.resources))vB(l)}catch(l){return r("JSON_SCHEMA_URI","",String(l),"error"),n}for(let l of gve(e))r("JSON_SCHEMA_REPRESENTATION",l,"Unknown representation field cannot be emitted natively");let i=!1,s=!1;for(let[l,c]of[[e.baseUri,e.root],...Object.entries(e.resources)]){if(c.kind!=="object"&&c.kind!=="boolean"){r("JSON_SCHEMA_ROOT","",`Resource ${l} must be object or boolean`,"error");continue}for(let u of a0(c)){if(u.node.kind!=="object")continue;for(let[p,d]of Object.entries(u.node.members)){if(!yve.has(p))i=!0,r("JSON_SCHEMA_KEYWORD",u.pointer+"/"+$e(p),`Uninterpreted keyword in ${l}`);if(["$dynamicRef","unevaluatedItems","unevaluatedProperties"].includes(p))r("JSON_SCHEMA_VALIDATOR_LIMIT",u.pointer+"/"+$e(p),"Pinned JavaScript oracle has known failures for this construct; native meaning retained, full semantic evaluation not certified");if(p==="properties"&&d.kind==="object"&&Object.hasOwn(d.members,"__proto__"))r("JSON_SCHEMA_VALIDATOR_LIMIT",u.pointer+"/properties/__proto__","Pinned JavaScript oracle does not reliably assert this property");if(p==="$schema"&&d.kind==="string"&&d.value!==fve)i=!0,s=!0,r("JSON_SCHEMA_DIALECT",u.pointer,`Uninterpreted dialect ${d.value}`);if(p==="$vocabulary"&&d.kind==="object"){for(let f of Object.keys(d.members))if(!hve.has(f))i=!0,r("JSON_SCHEMA_VOCABULARY",u.pointer,`Uninterpreted vocabulary ${f}`)}}}}if(n.some((l)=>l.severity==="error"))return n;let o=new Map;for(let[l,c]of[[e.baseUri,e.root],...Object.entries(e.resources)])try{o.set(l,ys(Be(c),"json"))}catch(u){r("JSON_SCHEMA_NUMERIC","",`Resource ${l}: native values retained but JavaScript validation unavailable: ${String(u)}`)}if(o.size!==Object.keys(e.resources).length+1){if(Object.hasOwn(e.resources,e.baseUri))r("JSON_SCHEMA_RESOURCE_COLLISION","","Root retrieval URI also appears in resources","error");return n}if(s)return n;let a=new xB.default({strict:!1,allErrors:!0,validateFormats:!1,ownProperties:!0,addUsedSchema:!1});try{for(let[c,u]of o)if(!a.validateSchema(u))r("JSON_SCHEMA_META","",`Resource ${c}: ${JSON.stringify(a.errors)}`,"error");if(n.some((c)=>c.severity==="error")||i)return n;for(let[c,u]of o)a.addSchema(u,c);if(!a.getSchema(e.baseUri))throw Error("Root resource not compiled")}catch(l){r("JSON_SCHEMA_COMPILE","",`Native compiler could not establish validity: ${String(l)}`)}return n}function bve(){return new nt().register(mve,(e,t)=>SB(e,t.path))}function vve(e){let t=We(e);if(!t.valid)throw new U("INVALID_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((i)=>i.id==="schema")?.elements.find((i)=>i.id==="schema"),r=Ae(n?.extensions[gB]);if(!bB(r))throw new U("JSON_SCHEMA_PAYLOAD",JSON.stringify(bB.errors));if(e.vocabularies[gB]?.version!=="0.1.0")throw new U("JSON_SCHEMA_VERSION","Unsupported native extension version");return r}function _ve(e){return We(e,bve())}function EB(e){let t=vve(e),n=SB(t,"");if(n.some((r)=>r.severity==="error"||r.code==="JSON_SCHEMA_REPRESENTATION"))throw new U("JSON_SCHEMA_EXPORT",JSON.stringify(n));return t}function q1(e){let t=Be(e)+` +`;if(t.length>Zt.maxTextLength)throw new U("LIMIT","Native output exceeds text limit");return t}function kB(e){return q1(EB(e).root)}function NB(e){let t=EB(e),n=Object.create(null);for(let[r,i]of Object.entries(t.resources))n[r]=q1(i);return{schema:q1(t.root),resources:n,source:Ae(e),diagnostics:[..._ve(e).diagnostics,{code:"SOURCE_ARTIFACT_REQUIRED",path:"",severity:"warning",message:"Standalone native root does not carry UMF metadata or supplied resource files; retain this bundle for full source recovery."}]}}var E8=Rr(w8(),1);var Wl=(e)=>e?.kind==="string"?e.value:void 0,_N=(e)=>{if(e?.kind!=="number")return;try{let t=ys(e.value,"json");return typeof t==="number"&&Number.isSafeInteger(t)?t:void 0}catch{return}},D8={boolean:"boolean",int:"integer",long:"integer",float:"float",double:"float",bytes:"binary",string:"string",fixed:"binary",enum:"string"};function T8(e){let t=new Map,n=[];function r(s,o,a,l){if(s.kind==="array"){s.items.forEach((f,m)=>r(f,o+"/"+m,a,l));return}if(s.kind!=="object")return;let c=s.members,u=Wl(c.type),p="",d=a;if(u&&["record","error","enum","fixed"].includes(u)){let f=Wl(c.name);if(!f)return;let m=Wl(c.namespace)??a;p=f.includes(".")?f:m?m+"."+f:f,d=p.includes(".")?p.slice(0,p.lastIndexOf(".")):"",t.set(p,t.has(p)?null:{node:s,namespace:d})}if((u==="record"||u==="error")&&c.fields?.kind==="array")c.fields.items.forEach((f,m)=>{if(f.kind!=="object"||!Wl(f.members.name)||!f.members.type)return;let y=o+"/fields/"+m;n.push({node:f,path:y,record:p,namespace:d,...l!==void 0?{dependencyId:l}:{}}),r(f.members.type,y+"/type",d,l)});if(u==="array"&&c.items)r(c.items,o+"/items",d,l);if(u==="map"&&c.values)r(c.values,o+"/values",d,l);if(c.type&&c.type.kind!=="string")r(c.type,o+"/type",d,l)}for(let s of e.dependencies??[])r(s.root,"","",s.id);r(e.root,"","");function i(s,o,a=new Set){if(s.kind==="array"){let d=s.items.filter((f)=>!(f.kind==="string"&&f.value==="null")&&!(f.kind==="object"&&Wl(f.members.type)==="null")).map((f)=>i(f,o,new Set(a)));return d.length&&d[0]&&d.every((f)=>f===d[0])?d[0]:void 0}let l=s.kind==="string"?s.value:s.kind==="object"?Wl(s.members.type):void 0;if(!l)return;if(s.kind==="object"&&Object.hasOwn(s.members,"logicalType")){let p=s.members,d=Wl(p.logicalType);if(d==="date"&&l==="int")return"date";if(d==="time-millis"&&l==="int"||d==="time-micros"&&l==="long")return"time";if(d&&/^(local-)?timestamp-(millis|micros|nanos)(?![\s\S])/.test(d)&&l==="long")return"timestamp";if(d==="big-decimal"&&l==="bytes")return"decimal";if(d==="decimal"&&(l==="bytes"||l==="fixed")){let f=_N(p.precision),m=p.scale===void 0?0:_N(p.scale);if(f===void 0||f<=0||m===void 0||m<0||m>f)return;if(l==="fixed"){let y=_N(p.size);if(y===void 0||y<1||y>4096)return;let h=((1n<h)return}return"decimal"}return}if(Object.hasOwn(D8,l))return D8[l];let c=l.includes(".")?l:o?o+"."+l:l;if(a.has(c))return;a.add(c);let u=t.get(c);return u?i(u.node,u.namespace,a):void 0}return n.map((s)=>{let o=Ae(s.node),a=s.node.members,l=i(a.type,s.namespace),c=Wl(a.doc);return{path:s.path,record:s.record,...s.dependencyId!==void 0?{dependencyId:s.dependencyId}:{},nativeField:o,element:{id:JSON.stringify([s.dependencyId??null,s.path]),name:Wl(a.name),...c!==void 0?{description:c}:{},...l?{scalarType:l}:{},extensions:{}}}})}var xN={id:"umf.avro",version:"0.1.0",coreVersion:"0.1.0",description:"Avro JSON schema preservation and typed tree access",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:avro:0.1.0",title:"UMF Avro native schema tree",type:"object",required:["version","root"],properties:{version:{const:"1.12.0"},root:{$ref:"#/$defs/node"},dependencies:{type:"array",items:{type:"object",required:["id","root"],properties:{id:{type:"string",minLength:1},root:{$ref:"#/$defs/node"}}}}},$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-007. Native JSON tokens preserve exact numbers, order, defaults, aliases, logical types and unknown metadata. Pinned JavaScript validator limitations remain explicit; no parsing-canonical-form reduction is used for retention.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Apache Avro JSON schema",version:"1.12.0; avsc 5.7.9 validation profile",subset:"JSON schema artifacts with explicit ordered named-schema dependencies; native IDL, protocols, RPC and container formats remain separate work. Logical types and host-unsafe numbers are preserved without complete browser interpretation."},evidence:["tests/avro/native.test.ts","tests/avro/corpus.test.ts","fixtures/avro/corpus-oracle-results.json","tests/avro/bundle.test.ts","fixtures/avro/dependency-oracle-results.json","tests/avro/native-schema.test.ts","fixtures/avro/native-schema-oracle.json","fixtures/avro/native-schema-browser.json"]}};var S8="umf.avro",rxe=xN,ixe=mt().compile(xN.schema);function wN(e,t,n){let r=e.kind==="object"?["kind","members"]:e.kind==="array"?["kind","items"]:e.kind==="null"?["kind"]:["kind","value"];for(let i of Object.keys(e))if(!r.includes(i))n.push({code:"AVRO_REPRESENTATION",path:t+"/"+$e(i),severity:"warning",message:"Unknown representation field has no native destination"});if(e.kind==="object")for(let[i,s]of Object.entries(e.members))wN(s,t+"/members/"+$e(i),n);if(e.kind==="array")e.items.forEach((i,s)=>wN(i,t+"/items/"+s,n))}function sxe(e){let t=e,n=[],r=(l,c,u)=>n.push({code:l,path:c,message:u,severity:"warning"});for(let l of Object.keys(t))if(!["version","root","dependencies"].includes(l))r("AVRO_REPRESENTATION","/"+$e(l),"Unknown payload field has no native destination");let i=[...(t.dependencies??[]).map((l,c)=>({node:l.root,path:"/dependencies/"+c+"/root"})),{node:t.root,path:"/root"}],s=new Set;(t.dependencies??[]).forEach((l,c)=>{if(s.has(l.id))n.push({code:"AVRO_DEPENDENCY_ID",path:"/dependencies/"+c+"/id",severity:"error",message:"Dependency IDs must be unique"});s.add(l.id);for(let u of Object.keys(l))if(!["id","root"].includes(u))r("AVRO_REPRESENTATION","/dependencies/"+c+"/"+$e(u),"Unknown dependency representation field has no native destination")});for(let{node:l,path:c}of i)wN(l,c,n);if(!["string","object","array"].includes(t.root.kind))return[...n,{code:"AVRO_ROOT",path:"/root",severity:"error",message:"Avro schemas must be strings, objects or union arrays"}];function o(l,c){if(l.kind==="array"){l.items.forEach((f,m)=>o(f,c+"/"+m));return}if(l.kind!=="object")return;let u=l.members,p=u.type?.kind==="string"?u.type.value:void 0,d=["type","name","namespace","aliases","doc","logicalType",...p==="record"||p==="error"?["fields"]:p==="enum"?["symbols","default"]:p==="fixed"?["size","precision","scale"]:p==="array"?["items"]:p==="map"?["values"]:["precision","scale"]];for(let f of Object.keys(u))if(!d.includes(f))r("AVRO_METADATA",c+"/"+$e(f),"Uninterpreted native metadata retained");if(u.logicalType)r("AVRO_LOGICAL_TYPE",c+"/logicalType","Logical type retained; this browser profile validates its underlying carrier only");if(u.fields?.kind==="array")u.fields.items.forEach((f,m)=>{if(f.kind!=="object")return;let y=f.members;for(let h of Object.keys(y))if(!["name","type","default","order","aliases","doc"].includes(h))r("AVRO_METADATA",c+"/fields/"+m+"/"+$e(h),"Uninterpreted field metadata retained");if(y.type)o(y.type,c+"/fields/"+m+"/type")});for(let f of["items","values"])if(u[f])o(u[f],c+"/"+f);if(u.type&&u.type.kind!=="string")o(u.type,c+"/type")}let a=Object.create(null);for(let{node:l,path:c}of i){o(l,c);let u;try{u=ys(Be(l),"json")}catch(p){r("AVRO_NUMERIC",c,"Exact native tokens retained; host interpretation is unavailable: "+String(p));continue}try{E8.Type.forSchema(u,{wrapUnions:!0,registry:a})}catch(p){r("AVRO_VALIDATOR_LIMIT",c,"Native schema could not be interpreted by avsc 5.7.9: "+String(p))}}return n}function oxe(){return new nt().register(rxe,sxe)}function DN(e){return We(e,oxe())}function x0(e){let t=DN(e);if(!t.valid)throw new U("AVRO_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[S8];if(e.vocabularies[S8]?.version!=="0.1.0"||!ixe(n))throw new U("AVRO_PAYLOAD","Missing or malformed Avro payload");return Ae(n)}function axe(e){return T8(x0(e))}function lxe(e){let t=e.modules.find((r)=>r.id==="avro.fields");if(!t)return;let n=axe(e).map((r)=>r.element);if(t.namespace!==""||t.elements.length!==n.length||n.some((r,i)=>["id","name","description","scalarType"].some((s)=>t.elements[i]?.[s]!==r[s])))throw new U("AVRO_FIELD_METADATA","Native fields and core metadata disagree")}function k8(e){lxe(e);let t=x0(e);if(DN(e).diagnostics.some((i)=>i.code==="AVRO_REPRESENTATION"))throw new U("AVRO_REPRESENTATION","Unknown representation content cannot be discarded");let r=Be(t.root)+` `;if(r.length>Zt.maxTextLength)throw new U("LIMIT","Native output exceeds limit");return r}function N8(e){if(x0(e).dependencies?.length)throw new U("AVRO_DEPENDENCIES_REQUIRED","Export the Avro bundle to retain named-schema dependencies");return k8(e)}function O8(e){return{schema:k8(e),dependencies:(x0(e).dependencies??[]).map((t)=>({id:t.id,schema:Be(t.root)+` -`})),source:Ae(e),diagnostics:[...DN(e).diagnostics,{code:"SOURCE_ARTIFACT_REQUIRED",path:"",severity:"warning",message:"Retain source UMF for unrelated metadata and uninterpreted content"}]}}function qe(e){return w0(e,[])}function w0(e,t){switch(typeof e){case"string":return JSON.stringify(e);case"function":return e.name?`[function ${e.name}]`:"[function]";case"object":return lxe(e,t);default:return String(e)}}function lxe(e,t){if(e===null)return"null";if(t.includes(e))return"[Circular]";let n=[...t,e];if(cxe(e)){let r=e.toJSON();if(r!==e)return typeof r==="string"?r:w0(r,n)}else if(Array.isArray(e))return pxe(e,n);return uxe(e,n)}function cxe(e){return typeof e.toJSON==="function"}function uxe(e,t){let n=Object.entries(e);if(n.length===0)return"{}";if(t.length>2)return"["+dxe(e)+"]";return"{ "+n.map(([i,s])=>i+": "+w0(s,t)).join(", ")+" }"}function pxe(e,t){if(e.length===0)return"[]";if(t.length>2)return"[Array]";let n=Math.min(10,e.length),r=e.length-n,i=[];for(let s=0;s1)i.push(`... ${r} more items`);return"["+i.join(", ")+"]"}function dxe(e){let t=Object.prototype.toString.call(e).replace(/^\[object /,"").replace(/]$/,"");if(t==="Object"&&typeof e.constructor==="function"){let n=e.constructor.name;if(typeof n==="string"&&n!=="")return n}return t}function fxe(e,t,n){if(e?.__kind===t)return!0;if(typeof e==="object"&&e!==null){let r=n.prototype[Symbol.toStringTag],i=Symbol.toStringTag in e?e[Symbol.toStringTag]:e.constructor?.name;if(r===i){let s=qe(e);throw Error(`Cannot use ${r} "${s}" from another module or realm. +`})),source:Ae(e),diagnostics:[...DN(e).diagnostics,{code:"SOURCE_ARTIFACT_REQUIRED",path:"",severity:"warning",message:"Retain source UMF for unrelated metadata and uninterpreted content"}]}}function qe(e){return w0(e,[])}function w0(e,t){switch(typeof e){case"string":return JSON.stringify(e);case"function":return e.name?`[function ${e.name}]`:"[function]";case"object":return cxe(e,t);default:return String(e)}}function cxe(e,t){if(e===null)return"null";if(t.includes(e))return"[Circular]";let n=[...t,e];if(uxe(e)){let r=e.toJSON();if(r!==e)return typeof r==="string"?r:w0(r,n)}else if(Array.isArray(e))return dxe(e,n);return pxe(e,n)}function uxe(e){return typeof e.toJSON==="function"}function pxe(e,t){let n=Object.entries(e);if(n.length===0)return"{}";if(t.length>2)return"["+fxe(e)+"]";return"{ "+n.map(([i,s])=>i+": "+w0(s,t)).join(", ")+" }"}function dxe(e,t){if(e.length===0)return"[]";if(t.length>2)return"[Array]";let n=Math.min(10,e.length),r=e.length-n,i=[];for(let s=0;s1)i.push(`... ${r} more items`);return"["+i.join(", ")+"]"}function fxe(e){let t=Object.prototype.toString.call(e).replace(/^\[object /,"").replace(/]$/,"");if(t==="Object"&&typeof e.constructor==="function"){let n=e.constructor.name;if(typeof n==="string"&&n!=="")return n}return t}function mxe(e,t,n){if(e?.__kind===t)return!0;if(typeof e==="object"&&e!==null){let r=n.prototype[Symbol.toStringTag],i=Symbol.toStringTag in e?e[Symbol.toStringTag]:e.constructor?.name;if(r===i){let s=qe(e);throw Error(`Cannot use ${r} "${s}" from another module or realm. Ensure that there is only one instance of "graphql" in the node_modules directory. If different versions of "graphql" are the dependencies of other @@ -316,65 +316,65 @@ https://yarnpkg.com/en/docs/selective-version-resolutions Duplicate "graphql" modules cannot be used at the same time since different versions may have different capabilities and behavior. The data from one version used in the function from another could produce confusing and -spurious results.`)}}return!1}function mxe(e,t){return e?.__kind===t}var ci=mxe;function P8(){ci=fxe}var yxe=!1;function $8(){yxe=!0,P8()}function I8(e){return e instanceof Error?e:new A8(e)}class A8 extends Error{constructor(e){super("Unexpected error value: "+qe(e));this.name="NonErrorThrown",this.thrownValue=e}}function Rr(e){return typeof e=="object"&&e!==null}function cn(e,t){if(!e)throw Error(t??"Unexpected invariant triggered.")}var hxe=/\r\n|[\n\r]/g;function am(e,t){let n=0,r=1;for(let i of e.body.matchAll(hxe)){if(typeof i.index!=="number")cn(!1);if(i.index>=t)break;n=i.index+i[0].length,r+=1}return{line:r,column:t+1-n}}function TN(e){return D0(e.source,am(e.source,e.start))}function D0(e,t){let n=e.locationOffset.column-1,r="".padStart(n)+e.body,i=t.line-1,s=e.locationOffset.line-1,o=t.line+s,a=t.line===1?n:0,l=t.column+a,c=`${e.name}:${o}:${l} +spurious results.`)}}return!1}function yxe(e,t){return e?.__kind===t}var ui=yxe;function P8(){ui=mxe}var hxe=!1;function $8(){hxe=!0,P8()}function I8(e){return e instanceof Error?e:new A8(e)}class A8 extends Error{constructor(e){super("Unexpected error value: "+qe(e));this.name="NonErrorThrown",this.thrownValue=e}}function jr(e){return typeof e=="object"&&e!==null}function cn(e,t){if(!e)throw Error(t??"Unexpected invariant triggered.")}var gxe=/\r\n|[\n\r]/g;function cm(e,t){let n=0,r=1;for(let i of e.body.matchAll(gxe)){if(typeof i.index!=="number")cn(!1);if(i.index>=t)break;n=i.index+i[0].length,r+=1}return{line:r,column:t+1-n}}function TN(e){return D0(e.source,cm(e.source,e.start))}function D0(e,t){let n=e.locationOffset.column-1,r="".padStart(n)+e.body,i=t.line-1,s=e.locationOffset.line-1,o=t.line+s,a=t.line===1?n:0,l=t.column+a,c=`${e.name}:${o}:${l} `,u=r.split(/\r\n|[\n\r]/g),p=u[i];if(p.length>120){let d=Math.floor(l/80),f=l%80,m=[];for(let y=0;y["|",y]),["|","^".padStart(f)],["|",m[d+1]]])}return c+R8([[`${o-1} |`,u[i-1]],[`${o} |`,p],["|","^".padStart(l)],[`${o+1} |`,u[i+1]]])}function R8(e){let t=e.filter(([r,i])=>i!==void 0),n=Math.max(...t.map(([r])=>r.length));return t.map(([r,i])=>r.padStart(n)+(i?" "+i:"")).join(` -`)}class ae extends Error{constructor(e,t={}){let{nodes:n,source:r,positions:i,path:s,originalError:o,cause:a,extensions:l}=t,c="cause"in t,u=c?a:o,p=c||o!=null?{cause:u}:void 0;super(e,p);this.name="GraphQLError",this.path=s??void 0;let d=o??(a instanceof Error?a:void 0);this.originalError=d,this.nodes=j8(Array.isArray(n)?n:n?[n]:void 0);let f=j8(this.nodes?.map((y)=>y.loc).filter((y)=>y!=null));this.source=r??f?.[0]?.source,this.positions=i??f?.map((y)=>y.start),this.locations=i&&r?i.map((y)=>am(r,y)):f?.map((y)=>am(y.source,y.start));let m=Rr(d?.extensions)?d.extensions:void 0;if(this.extensions=l??m??Object.create(null),Object.defineProperties(this,{message:{writable:!0,enumerable:!0},name:{enumerable:!1},nodes:{enumerable:!1},source:{enumerable:!1},positions:{enumerable:!1},originalError:{enumerable:!1}}),o?.stack!=null)Object.defineProperty(this,"stack",{value:o.stack,writable:!0,configurable:!0});else if(Error.captureStackTrace!=null)Error.captureStackTrace(this,ae);else Object.defineProperty(this,"stack",{value:Error().stack,writable:!0,configurable:!0})}get[Symbol.toStringTag](){return"GraphQLError"}toString(){let e=this.message;if(this.nodes){for(let t of this.nodes)if(t.loc)e+=` +`)}class ae extends Error{constructor(e,t={}){let{nodes:n,source:r,positions:i,path:s,originalError:o,cause:a,extensions:l}=t,c="cause"in t,u=c?a:o,p=c||o!=null?{cause:u}:void 0;super(e,p);this.name="GraphQLError",this.path=s??void 0;let d=o??(a instanceof Error?a:void 0);this.originalError=d,this.nodes=j8(Array.isArray(n)?n:n?[n]:void 0);let f=j8(this.nodes?.map((y)=>y.loc).filter((y)=>y!=null));this.source=r??f?.[0]?.source,this.positions=i??f?.map((y)=>y.start),this.locations=i&&r?i.map((y)=>cm(r,y)):f?.map((y)=>cm(y.source,y.start));let m=jr(d?.extensions)?d.extensions:void 0;if(this.extensions=l??m??Object.create(null),Object.defineProperties(this,{message:{writable:!0,enumerable:!0},name:{enumerable:!1},nodes:{enumerable:!1},source:{enumerable:!1},positions:{enumerable:!1},originalError:{enumerable:!1}}),o?.stack!=null)Object.defineProperty(this,"stack",{value:o.stack,writable:!0,configurable:!0});else if(Error.captureStackTrace!=null)Error.captureStackTrace(this,ae);else Object.defineProperty(this,"stack",{value:Error().stack,writable:!0,configurable:!0})}get[Symbol.toStringTag](){return"GraphQLError"}toString(){let e=this.message;if(this.nodes){for(let t of this.nodes)if(t.loc)e+=` `+TN(t.loc)}else if(this.source&&this.locations)for(let t of this.locations)e+=` -`+D0(this.source,t);return e}toJSON(){let e={message:this.message};if(this.locations!=null)e.locations=this.locations;if(this.path!=null)e.path=this.path;if(this.extensions!=null&&Object.keys(this.extensions).length>0)e.extensions=this.extensions;return e}}function j8(e){return e===void 0||e.length===0?void 0:e}function dg(e){if(e instanceof ae)return e;let t=I8(e);return new ae(t.message,{originalError:t})}class zi extends Map{get[Symbol.toStringTag](){return"AccumulatorMap"}add(e,t){let n=this.get(e);if(n===void 0)this.set(e,[t]);else n.push(t)}}function F8(e){return e.charAt(0).toUpperCase()+e.slice(1).toLowerCase()}function C8(e){return L8("or",e)}function M8(e){return L8("and",e)}function L8(e,t){if(t.length===0)cn(!1);switch(t.length){case 1:return t[0];case 2:return t[0]+" "+e+" "+t[1]}let n=t.slice(0,-1),r=t.at(-1);return n.join(", ")+", "+e+" "+r}function So(e){return typeof e==="object"&&typeof e?.[Symbol.iterator]==="function"}function lm(e,t){let n=Object.create(null);for(let r of e)n[t(r)]=r;return n}function tl(e,t){let n=Object.create(null);for(let r of Object.keys(e))n[r]=t(e[r],r);return n}function fg(e){if(e.length===0)return"";return` at ${e.map((t)=>typeof t==="number"?`[${t}]`:`.${t}`).join("")}`}class T0{constructor(e,t,n){this.start=e.start,this.end=t.end,this.startToken=e,this.endToken=t,this.source=n}get[Symbol.toStringTag](){return"Location"}toJSON(){return{start:this.start,end:this.end}}}class mg{constructor(e,t,n,r,i,s){this.kind=e,this.start=t,this.end=n,this.line=r,this.column=i,this.value=s,this.prev=null,this.next=null}get[Symbol.toStringTag](){return"Token"}toJSON(){return{kind:this.kind,value:this.value,line:this.line,column:this.column}}}var yg={Name:[],Document:["definitions"],OperationDefinition:["description","name","variableDefinitions","directives","selectionSet"],VariableDefinition:["description","variable","type","defaultValue","directives"],Variable:["name"],SelectionSet:["selections"],Field:["alias","name","arguments","directives","selectionSet"],Argument:["name","value"],FragmentArgument:["name","value"],FragmentSpread:["name","arguments","directives"],InlineFragment:["typeCondition","directives","selectionSet"],FragmentDefinition:["description","name","variableDefinitions","typeCondition","directives","selectionSet"],IntValue:[],FloatValue:[],StringValue:[],BooleanValue:[],NullValue:[],EnumValue:[],ListValue:["values"],ObjectValue:["fields"],ObjectField:["name","value"],Directive:["name","arguments"],NamedType:["name"],ListType:["type"],NonNullType:["type"],SchemaDefinition:["description","directives","operationTypes"],OperationTypeDefinition:["type"],ScalarTypeDefinition:["description","name","directives"],ObjectTypeDefinition:["description","name","interfaces","directives","fields"],FieldDefinition:["description","name","arguments","type","directives"],InputValueDefinition:["description","name","type","defaultValue","directives"],InterfaceTypeDefinition:["description","name","interfaces","directives","fields"],UnionTypeDefinition:["description","name","directives","types"],EnumTypeDefinition:["description","name","directives","values"],EnumValueDefinition:["description","name","directives"],InputObjectTypeDefinition:["description","name","directives","fields"],DirectiveDefinition:["description","name","arguments","directives","locations"],SchemaExtension:["directives","operationTypes"],DirectiveExtension:["name","directives"],ScalarTypeExtension:["name","directives"],ObjectTypeExtension:["name","interfaces","directives","fields"],InterfaceTypeExtension:["name","interfaces","directives","fields"],UnionTypeExtension:["name","directives","types"],EnumTypeExtension:["name","directives","values"],InputObjectTypeExtension:["name","directives","fields"],TypeCoordinate:["name"],MemberCoordinate:["name","memberName"],ArgumentCoordinate:["name","fieldName","argumentName"],DirectiveCoordinate:["name"],DirectiveArgumentCoordinate:["name","argumentName"]},gxe=new Set(Object.keys(yg));function SN(e){let t=e?.kind;return typeof t==="string"&&gxe.has(t)}var jr={QUERY:"query",MUTATION:"mutation",SUBSCRIPTION:"subscription"};var zt={};kf(zt,{ARGUMENT:()=>B8,ARGUMENT_COORDINATE:()=>z8,BOOLEAN:()=>Eo,DIRECTIVE:()=>K8,DIRECTIVE_ARGUMENT_COORDINATE:()=>Q8,DIRECTIVE_COORDINATE:()=>W8,DIRECTIVE_DEFINITION:()=>nl,DIRECTIVE_EXTENSION:()=>um,DOCUMENT:()=>q8,ENUM:()=>td,ENUM_TYPE_DEFINITION:()=>ad,ENUM_TYPE_EXTENSION:()=>Du,ENUM_VALUE_DEFINITION:()=>PN,FIELD:()=>cm,FIELD_DEFINITION:()=>NN,FLOAT:()=>gu,FRAGMENT_ARGUMENT:()=>V8,FRAGMENT_DEFINITION:()=>Ql,FRAGMENT_SPREAD:()=>hu,INLINE_FRAGMENT:()=>gg,INPUT_OBJECT_TYPE_DEFINITION:()=>bu,INPUT_OBJECT_TYPE_EXTENSION:()=>Yl,INPUT_VALUE_DEFINITION:()=>ON,INT:()=>ui,INTERFACE_TYPE_DEFINITION:()=>sd,INTERFACE_TYPE_EXTENSION:()=>xu,LIST:()=>ko,LIST_TYPE:()=>S0,MEMBER_COORDINATE:()=>H8,NAME:()=>hg,NAMED_TYPE:()=>kN,NON_NULL_TYPE:()=>vg,NULL:()=>Fr,OBJECT:()=>No,OBJECT_FIELD:()=>bg,OBJECT_TYPE_DEFINITION:()=>id,OBJECT_TYPE_EXTENSION:()=>_u,OPERATION_DEFINITION:()=>ed,OPERATION_TYPE_DEFINITION:()=>J8,SCALAR_TYPE_DEFINITION:()=>rd,SCALAR_TYPE_EXTENSION:()=>vu,SCHEMA_DEFINITION:()=>nd,SCHEMA_EXTENSION:()=>ld,SELECTION_SET:()=>U8,STRING:()=>ba,TYPE_COORDINATE:()=>G8,UNION_TYPE_DEFINITION:()=>od,UNION_TYPE_EXTENSION:()=>wu,VARIABLE:()=>_s,VARIABLE_DEFINITION:()=>EN});var hg="Name",q8="Document",ed="OperationDefinition",EN="VariableDefinition",U8="SelectionSet",cm="Field",B8="Argument",V8="FragmentArgument",hu="FragmentSpread",gg="InlineFragment",Ql="FragmentDefinition",_s="Variable",ui="IntValue",gu="FloatValue",ba="StringValue",Eo="BooleanValue",Fr="NullValue",td="EnumValue",ko="ListValue",No="ObjectValue",bg="ObjectField",K8="Directive",kN="NamedType",S0="ListType",vg="NonNullType",nd="SchemaDefinition",J8="OperationTypeDefinition",rd="ScalarTypeDefinition",id="ObjectTypeDefinition",NN="FieldDefinition",ON="InputValueDefinition",sd="InterfaceTypeDefinition",od="UnionTypeDefinition",ad="EnumTypeDefinition",PN="EnumValueDefinition",bu="InputObjectTypeDefinition",nl="DirectiveDefinition",ld="SchemaExtension",um="DirectiveExtension",vu="ScalarTypeExtension",_u="ObjectTypeExtension",xu="InterfaceTypeExtension",wu="UnionTypeExtension",Du="EnumTypeExtension",Yl="InputObjectTypeExtension",G8="TypeCoordinate",H8="MemberCoordinate",z8="ArgumentCoordinate",W8="DirectiveCoordinate",Q8="DirectiveArgumentCoordinate";function Oo(e,t){if(!e)throw Error(t)}var bxe=5;function Oi(e,t){let[n,r]=t?[e,t]:[void 0,e];if(r.length===0)return"";let i=" Did you mean ";if(n!=null)i+=n+" ";let s=C8(r.slice(0,bxe).map((o)=>`"${o}"`));return i+s+"?"}function $N(e){return e}function cd(e,t,n){let r=Object.create(null);for(let i of e)r[t(i)]=n(i);return r}function pm(e,t){let n=0,r=0;while(n0);let a=0;do++r,a=a*10+s-IN,s=t.charCodeAt(r);while(E0(s)&&a>0);if(oa)return 1}else{if(is)return 1;++n,++r}}return e.length-t.length}var IN=48,vxe=57;function E0(e){return!isNaN(e)&&IN<=e&&e<=vxe}function Wi(e,t){let n=Object.create(null),r=new X8(e),i=Math.floor(e.length*0.4)+1;for(let s of t){let o=r.measure(s,i);if(o!==void 0)n[s]=o}return Object.keys(n).sort((s,o)=>{let a=n[s]-n[o];return a!==0?a:pm(s,o)})}class X8{constructor(e){this._input=e,this._inputLowerCase=e.toLowerCase(),this._inputArray=Y8(this._inputLowerCase),this._rows=[Array(e.length+1).fill(0),Array(e.length+1).fill(0),Array(e.length+1).fill(0)]}measure(e,t){if(this._input===e)return 0;let n=e.toLowerCase();if(this._inputLowerCase===n)return 1;let r=Y8(n),i=this._inputArray;if(r.lengtht)return;let a=this._rows;for(let c=0;c<=o;c++)a[0][c]=c;for(let c=1;c<=s;c++){let u=a[(c-1)%3],p=a[c%3],d=p[0]=c;for(let f=1;f<=o;f++){let m=r[c-1]===i[f-1]?0:1,y=Math.min(u[f]+1,p[f-1]+1,u[f-1]+m);if(c>1&&f>1&&r[c-1]===i[f-2]&&r[c-2]===i[f-1]){let h=a[(c-2)%3][f-2];y=Math.min(y,h+1)}if(yt)return}let l=a[s%3][o];return l<=t?l:void 0}}function Y8(e){let t=e.length,n=Array(t);for(let r=0;r=48&&e<=57}function Z8(e){return e>=97&&e<=122||e>=65&&e<=90}function _g(e){return Z8(e)||e===95}function N0(e){return Z8(e)||ud(e)||e===95}function eV(e){let t=Number.MAX_SAFE_INTEGER,n=null,r=-1;for(let i=0;is===0?i:i.slice(t)).slice(n??0,r+1)}function _xe(e){let t=0;while(t1&&r.slice(1).every((f)=>f.length===0||k0(f.charCodeAt(0))),o=n.endsWith('\\"""'),a=e.endsWith('"')&&!o,l=e.endsWith("\\"),c=a||l,u=!t?.minimize&&(!i||e.length>70||c||s||o),p="",d=i&&k0(e.charCodeAt(0));if(u&&!d||s)p+=` +`+D0(this.source,t);return e}toJSON(){let e={message:this.message};if(this.locations!=null)e.locations=this.locations;if(this.path!=null)e.path=this.path;if(this.extensions!=null&&Object.keys(this.extensions).length>0)e.extensions=this.extensions;return e}}function j8(e){return e===void 0||e.length===0?void 0:e}function dg(e){if(e instanceof ae)return e;let t=I8(e);return new ae(t.message,{originalError:t})}class Wi extends Map{get[Symbol.toStringTag](){return"AccumulatorMap"}add(e,t){let n=this.get(e);if(n===void 0)this.set(e,[t]);else n.push(t)}}function F8(e){return e.charAt(0).toUpperCase()+e.slice(1).toLowerCase()}function C8(e){return L8("or",e)}function M8(e){return L8("and",e)}function L8(e,t){if(t.length===0)cn(!1);switch(t.length){case 1:return t[0];case 2:return t[0]+" "+e+" "+t[1]}let n=t.slice(0,-1),r=t.at(-1);return n.join(", ")+", "+e+" "+r}function So(e){return typeof e==="object"&&typeof e?.[Symbol.iterator]==="function"}function um(e,t){let n=Object.create(null);for(let r of e)n[t(r)]=r;return n}function tl(e,t){let n=Object.create(null);for(let r of Object.keys(e))n[r]=t(e[r],r);return n}function fg(e){if(e.length===0)return"";return` at ${e.map((t)=>typeof t==="number"?`[${t}]`:`.${t}`).join("")}`}class T0{constructor(e,t,n){this.start=e.start,this.end=t.end,this.startToken=e,this.endToken=t,this.source=n}get[Symbol.toStringTag](){return"Location"}toJSON(){return{start:this.start,end:this.end}}}class mg{constructor(e,t,n,r,i,s){this.kind=e,this.start=t,this.end=n,this.line=r,this.column=i,this.value=s,this.prev=null,this.next=null}get[Symbol.toStringTag](){return"Token"}toJSON(){return{kind:this.kind,value:this.value,line:this.line,column:this.column}}}var yg={Name:[],Document:["definitions"],OperationDefinition:["description","name","variableDefinitions","directives","selectionSet"],VariableDefinition:["description","variable","type","defaultValue","directives"],Variable:["name"],SelectionSet:["selections"],Field:["alias","name","arguments","directives","selectionSet"],Argument:["name","value"],FragmentArgument:["name","value"],FragmentSpread:["name","arguments","directives"],InlineFragment:["typeCondition","directives","selectionSet"],FragmentDefinition:["description","name","variableDefinitions","typeCondition","directives","selectionSet"],IntValue:[],FloatValue:[],StringValue:[],BooleanValue:[],NullValue:[],EnumValue:[],ListValue:["values"],ObjectValue:["fields"],ObjectField:["name","value"],Directive:["name","arguments"],NamedType:["name"],ListType:["type"],NonNullType:["type"],SchemaDefinition:["description","directives","operationTypes"],OperationTypeDefinition:["type"],ScalarTypeDefinition:["description","name","directives"],ObjectTypeDefinition:["description","name","interfaces","directives","fields"],FieldDefinition:["description","name","arguments","type","directives"],InputValueDefinition:["description","name","type","defaultValue","directives"],InterfaceTypeDefinition:["description","name","interfaces","directives","fields"],UnionTypeDefinition:["description","name","directives","types"],EnumTypeDefinition:["description","name","directives","values"],EnumValueDefinition:["description","name","directives"],InputObjectTypeDefinition:["description","name","directives","fields"],DirectiveDefinition:["description","name","arguments","directives","locations"],SchemaExtension:["directives","operationTypes"],DirectiveExtension:["name","directives"],ScalarTypeExtension:["name","directives"],ObjectTypeExtension:["name","interfaces","directives","fields"],InterfaceTypeExtension:["name","interfaces","directives","fields"],UnionTypeExtension:["name","directives","types"],EnumTypeExtension:["name","directives","values"],InputObjectTypeExtension:["name","directives","fields"],TypeCoordinate:["name"],MemberCoordinate:["name","memberName"],ArgumentCoordinate:["name","fieldName","argumentName"],DirectiveCoordinate:["name"],DirectiveArgumentCoordinate:["name","argumentName"]},bxe=new Set(Object.keys(yg));function SN(e){let t=e?.kind;return typeof t==="string"&&bxe.has(t)}var Fr={QUERY:"query",MUTATION:"mutation",SUBSCRIPTION:"subscription"};var zt={};Of(zt,{ARGUMENT:()=>B8,ARGUMENT_COORDINATE:()=>z8,BOOLEAN:()=>Eo,DIRECTIVE:()=>K8,DIRECTIVE_ARGUMENT_COORDINATE:()=>Q8,DIRECTIVE_COORDINATE:()=>W8,DIRECTIVE_DEFINITION:()=>nl,DIRECTIVE_EXTENSION:()=>dm,DOCUMENT:()=>q8,ENUM:()=>rd,ENUM_TYPE_DEFINITION:()=>cd,ENUM_TYPE_EXTENSION:()=>Tu,ENUM_VALUE_DEFINITION:()=>PN,FIELD:()=>pm,FIELD_DEFINITION:()=>NN,FLOAT:()=>bu,FRAGMENT_ARGUMENT:()=>V8,FRAGMENT_DEFINITION:()=>Ql,FRAGMENT_SPREAD:()=>gu,INLINE_FRAGMENT:()=>gg,INPUT_OBJECT_TYPE_DEFINITION:()=>vu,INPUT_OBJECT_TYPE_EXTENSION:()=>Yl,INPUT_VALUE_DEFINITION:()=>ON,INT:()=>pi,INTERFACE_TYPE_DEFINITION:()=>ad,INTERFACE_TYPE_EXTENSION:()=>wu,LIST:()=>ko,LIST_TYPE:()=>S0,MEMBER_COORDINATE:()=>H8,NAME:()=>hg,NAMED_TYPE:()=>kN,NON_NULL_TYPE:()=>vg,NULL:()=>Cr,OBJECT:()=>No,OBJECT_FIELD:()=>bg,OBJECT_TYPE_DEFINITION:()=>od,OBJECT_TYPE_EXTENSION:()=>xu,OPERATION_DEFINITION:()=>nd,OPERATION_TYPE_DEFINITION:()=>J8,SCALAR_TYPE_DEFINITION:()=>sd,SCALAR_TYPE_EXTENSION:()=>_u,SCHEMA_DEFINITION:()=>id,SCHEMA_EXTENSION:()=>ud,SELECTION_SET:()=>U8,STRING:()=>ba,TYPE_COORDINATE:()=>G8,UNION_TYPE_DEFINITION:()=>ld,UNION_TYPE_EXTENSION:()=>Du,VARIABLE:()=>xs,VARIABLE_DEFINITION:()=>EN});var hg="Name",q8="Document",nd="OperationDefinition",EN="VariableDefinition",U8="SelectionSet",pm="Field",B8="Argument",V8="FragmentArgument",gu="FragmentSpread",gg="InlineFragment",Ql="FragmentDefinition",xs="Variable",pi="IntValue",bu="FloatValue",ba="StringValue",Eo="BooleanValue",Cr="NullValue",rd="EnumValue",ko="ListValue",No="ObjectValue",bg="ObjectField",K8="Directive",kN="NamedType",S0="ListType",vg="NonNullType",id="SchemaDefinition",J8="OperationTypeDefinition",sd="ScalarTypeDefinition",od="ObjectTypeDefinition",NN="FieldDefinition",ON="InputValueDefinition",ad="InterfaceTypeDefinition",ld="UnionTypeDefinition",cd="EnumTypeDefinition",PN="EnumValueDefinition",vu="InputObjectTypeDefinition",nl="DirectiveDefinition",ud="SchemaExtension",dm="DirectiveExtension",_u="ScalarTypeExtension",xu="ObjectTypeExtension",wu="InterfaceTypeExtension",Du="UnionTypeExtension",Tu="EnumTypeExtension",Yl="InputObjectTypeExtension",G8="TypeCoordinate",H8="MemberCoordinate",z8="ArgumentCoordinate",W8="DirectiveCoordinate",Q8="DirectiveArgumentCoordinate";function Oo(e,t){if(!e)throw Error(t)}var vxe=5;function Oi(e,t){let[n,r]=t?[e,t]:[void 0,e];if(r.length===0)return"";let i=" Did you mean ";if(n!=null)i+=n+" ";let s=C8(r.slice(0,vxe).map((o)=>`"${o}"`));return i+s+"?"}function $N(e){return e}function pd(e,t,n){let r=Object.create(null);for(let i of e)r[t(i)]=n(i);return r}function fm(e,t){let n=0,r=0;while(n0);let a=0;do++r,a=a*10+s-IN,s=t.charCodeAt(r);while(E0(s)&&a>0);if(oa)return 1}else{if(is)return 1;++n,++r}}return e.length-t.length}var IN=48,_xe=57;function E0(e){return!isNaN(e)&&IN<=e&&e<=_xe}function Qi(e,t){let n=Object.create(null),r=new X8(e),i=Math.floor(e.length*0.4)+1;for(let s of t){let o=r.measure(s,i);if(o!==void 0)n[s]=o}return Object.keys(n).sort((s,o)=>{let a=n[s]-n[o];return a!==0?a:fm(s,o)})}class X8{constructor(e){this._input=e,this._inputLowerCase=e.toLowerCase(),this._inputArray=Y8(this._inputLowerCase),this._rows=[Array(e.length+1).fill(0),Array(e.length+1).fill(0),Array(e.length+1).fill(0)]}measure(e,t){if(this._input===e)return 0;let n=e.toLowerCase();if(this._inputLowerCase===n)return 1;let r=Y8(n),i=this._inputArray;if(r.lengtht)return;let a=this._rows;for(let c=0;c<=o;c++)a[0][c]=c;for(let c=1;c<=s;c++){let u=a[(c-1)%3],p=a[c%3],d=p[0]=c;for(let f=1;f<=o;f++){let m=r[c-1]===i[f-1]?0:1,y=Math.min(u[f]+1,p[f-1]+1,u[f-1]+m);if(c>1&&f>1&&r[c-1]===i[f-2]&&r[c-2]===i[f-1]){let h=a[(c-2)%3][f-2];y=Math.min(y,h+1)}if(yt)return}let l=a[s%3][o];return l<=t?l:void 0}}function Y8(e){let t=e.length,n=Array(t);for(let r=0;r=48&&e<=57}function Z8(e){return e>=97&&e<=122||e>=65&&e<=90}function _g(e){return Z8(e)||e===95}function N0(e){return Z8(e)||dd(e)||e===95}function eV(e){let t=Number.MAX_SAFE_INTEGER,n=null,r=-1;for(let i=0;is===0?i:i.slice(t)).slice(n??0,r+1)}function xxe(e){let t=0;while(t1&&r.slice(1).every((f)=>f.length===0||k0(f.charCodeAt(0))),o=n.endsWith('\\"""'),a=e.endsWith('"')&&!o,l=e.endsWith("\\"),c=a||l,u=!t?.minimize&&(!i||e.length>70||c||s||o),p="",d=i&&k0(e.charCodeAt(0));if(u&&!d||s)p+=` `;if(p+=n,u||c)p+=` -`;return'"""'+p+'"""'}function nV(e){return`"${e.replace(xxe,wxe)}"`}var xxe=/[\x00-\x1f\x22\x5c\x7f-\x9f]/g;function wxe(e){return Dxe[e.charCodeAt(0)]}var Dxe=["\\u0000","\\u0001","\\u0002","\\u0003","\\u0004","\\u0005","\\u0006","\\u0007","\\b","\\t","\\n","\\u000B","\\f","\\r","\\u000E","\\u000F","\\u0010","\\u0011","\\u0012","\\u0013","\\u0014","\\u0015","\\u0016","\\u0017","\\u0018","\\u0019","\\u001A","\\u001B","\\u001C","\\u001D","\\u001E","\\u001F","","","\\\"","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\\\","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\u007F","\\u0080","\\u0081","\\u0082","\\u0083","\\u0084","\\u0085","\\u0086","\\u0087","\\u0088","\\u0089","\\u008A","\\u008B","\\u008C","\\u008D","\\u008E","\\u008F","\\u0090","\\u0091","\\u0092","\\u0093","\\u0094","\\u0095","\\u0096","\\u0097","\\u0098","\\u0099","\\u009A","\\u009B","\\u009C","\\u009D","\\u009E","\\u009F"];var dm=Object.freeze({});function xg(e,t,n=yg){let r=new Map;for(let m of Object.values(zt))r.set(m,RN(t,m));let i=void 0,s=Array.isArray(e),o=[e],a=-1,l=[],c=e,u=void 0,p=void 0,d=[],f=[];do{a++;let m=a===o.length,y=m&&l.length!==0;if(m){if(u=f.length===0?void 0:d[d.length-1],c=p,p=f.pop(),y)if(s){c=c.slice();let b=0;for(let[g,x]of l){let v=g-b;if(x===null)c.splice(v,1),b++;else c[v]=x}}else{c={...c};for(let[b,g]of l)c[b]=g}a=i.index,o=i.keys,l=i.edits,s=i.inArray,i=i.prev}else if(p!=null){if(u=s?a:o[a],c=p[u],c===null||c===void 0)continue;d.push(u)}let h;if(!Array.isArray(c)){if(!SN(c))Oo(!1,`Invalid AST Node: ${qe(c)}.`);if(h=(m?r.get(c.kind)?.leave:r.get(c.kind)?.enter)?.call(t,c,u,p,d,f),h===dm)break;if(h===!1){if(!m){d.pop();continue}}else if(h!==void 0){if(l.push([u,h]),!m)if(SN(h))c=h;else{d.pop();continue}}}if(h===void 0&&y)l.push([u,c]);if(m)d.pop();else{if(i={inArray:s,index:a,keys:o,edits:l,prev:i},s=Array.isArray(c),o=s?c:n[c.kind]??[],a=-1,l=[],p!=null)f.push(p);p=c}}while(i!==void 0);if(l.length!==0)return l.at(-1)[1];return e}function AN(e){let t=Array(e.length).fill(null),n=Object.create(null);for(let r of Object.values(zt)){let i=!1,s=Array(e.length).fill(void 0),o=Array(e.length).fill(void 0);for(let l=0;le.value},Variable:{leave:(e)=>"$"+e.name},Document:{leave:(e)=>He(e.definitions,` +`;return'"""'+p+'"""'}function nV(e){return`"${e.replace(wxe,Dxe)}"`}var wxe=/[\x00-\x1f\x22\x5c\x7f-\x9f]/g;function Dxe(e){return Txe[e.charCodeAt(0)]}var Txe=["\\u0000","\\u0001","\\u0002","\\u0003","\\u0004","\\u0005","\\u0006","\\u0007","\\b","\\t","\\n","\\u000B","\\f","\\r","\\u000E","\\u000F","\\u0010","\\u0011","\\u0012","\\u0013","\\u0014","\\u0015","\\u0016","\\u0017","\\u0018","\\u0019","\\u001A","\\u001B","\\u001C","\\u001D","\\u001E","\\u001F","","","\\\"","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\\\","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\u007F","\\u0080","\\u0081","\\u0082","\\u0083","\\u0084","\\u0085","\\u0086","\\u0087","\\u0088","\\u0089","\\u008A","\\u008B","\\u008C","\\u008D","\\u008E","\\u008F","\\u0090","\\u0091","\\u0092","\\u0093","\\u0094","\\u0095","\\u0096","\\u0097","\\u0098","\\u0099","\\u009A","\\u009B","\\u009C","\\u009D","\\u009E","\\u009F"];var mm=Object.freeze({});function xg(e,t,n=yg){let r=new Map;for(let m of Object.values(zt))r.set(m,RN(t,m));let i=void 0,s=Array.isArray(e),o=[e],a=-1,l=[],c=e,u=void 0,p=void 0,d=[],f=[];do{a++;let m=a===o.length,y=m&&l.length!==0;if(m){if(u=f.length===0?void 0:d[d.length-1],c=p,p=f.pop(),y)if(s){c=c.slice();let b=0;for(let[g,x]of l){let v=g-b;if(x===null)c.splice(v,1),b++;else c[v]=x}}else{c={...c};for(let[b,g]of l)c[b]=g}a=i.index,o=i.keys,l=i.edits,s=i.inArray,i=i.prev}else if(p!=null){if(u=s?a:o[a],c=p[u],c===null||c===void 0)continue;d.push(u)}let h;if(!Array.isArray(c)){if(!SN(c))Oo(!1,`Invalid AST Node: ${qe(c)}.`);if(h=(m?r.get(c.kind)?.leave:r.get(c.kind)?.enter)?.call(t,c,u,p,d,f),h===mm)break;if(h===!1){if(!m){d.pop();continue}}else if(h!==void 0){if(l.push([u,h]),!m)if(SN(h))c=h;else{d.pop();continue}}}if(h===void 0&&y)l.push([u,c]);if(m)d.pop();else{if(i={inArray:s,index:a,keys:o,edits:l,prev:i},s=Array.isArray(c),o=s?c:n[c.kind]??[],a=-1,l=[],p!=null)f.push(p);p=c}}while(i!==void 0);if(l.length!==0)return l.at(-1)[1];return e}function AN(e){let t=Array(e.length).fill(null),n=Object.create(null);for(let r of Object.values(zt)){let i=!1,s=Array(e.length).fill(void 0),o=Array(e.length).fill(void 0);for(let l=0;le.value},Variable:{leave:(e)=>"$"+e.name},Document:{leave:(e)=>He(e.definitions,` -`)},OperationDefinition:{leave(e){let t=jN(e.variableDefinitions)?wt(`( +`)},OperationDefinition:{leave(e){let t=jN(e.variableDefinitions)?Dt(`( `,He(e.variableDefinitions,` `),` -)`):wt("(",He(e.variableDefinitions,", "),")"),n=wt("",e.description,` -`)+He([e.operation,He([e.name,t]),He(e.directives," ")]," ");return(n==="query"?"":n+" ")+e.selectionSet}},VariableDefinition:{leave:({variable:e,type:t,defaultValue:n,directives:r,description:i})=>wt("",i,` -`)+e+": "+t+wt(" = ",n)+wt(" ",He(r," "))},SelectionSet:{leave:({selections:e})=>Po(e)},Field:{leave({alias:e,name:t,arguments:n,directives:r,selectionSet:i}){let s=He([wt("",e,": "),t],"");return He([rV(s,n),wt(" ",He(r," ")),wt(" ",i)])}},Argument:{leave:({name:e,value:t})=>e+": "+t},FragmentArgument:{leave:({name:e,value:t})=>e+": "+t},FragmentSpread:{leave:({name:e,arguments:t,directives:n})=>{let r="..."+e;return rV(r,t)+wt(" ",He(n," "))}},InlineFragment:{leave:({typeCondition:e,directives:t,selectionSet:n})=>He(["...",wt("on ",e),He(t," "),n]," ")},FragmentDefinition:{leave:({name:e,typeCondition:t,variableDefinitions:n,directives:r,selectionSet:i,description:s})=>wt("",s,` -`)+`fragment ${e}${wt("(",He(n,", "),")")} on ${t} ${wt("",He(r," ")," ")}`+i},IntValue:{leave:({value:e})=>e},FloatValue:{leave:({value:e})=>e},StringValue:{leave:({value:e,block:t})=>t===!0?tV(e):nV(e)},BooleanValue:{leave:({value:e})=>e?"true":"false"},NullValue:{leave:()=>"null"},EnumValue:{leave:({value:e})=>e},ListValue:{leave:({values:e})=>{let t="["+He(e,", ")+"]";if(t.length>FN)return`[ +)`):Dt("(",He(e.variableDefinitions,", "),")"),n=Dt("",e.description,` +`)+He([e.operation,He([e.name,t]),He(e.directives," ")]," ");return(n==="query"?"":n+" ")+e.selectionSet}},VariableDefinition:{leave:({variable:e,type:t,defaultValue:n,directives:r,description:i})=>Dt("",i,` +`)+e+": "+t+Dt(" = ",n)+Dt(" ",He(r," "))},SelectionSet:{leave:({selections:e})=>Po(e)},Field:{leave({alias:e,name:t,arguments:n,directives:r,selectionSet:i}){let s=He([Dt("",e,": "),t],"");return He([rV(s,n),Dt(" ",He(r," ")),Dt(" ",i)])}},Argument:{leave:({name:e,value:t})=>e+": "+t},FragmentArgument:{leave:({name:e,value:t})=>e+": "+t},FragmentSpread:{leave:({name:e,arguments:t,directives:n})=>{let r="..."+e;return rV(r,t)+Dt(" ",He(n," "))}},InlineFragment:{leave:({typeCondition:e,directives:t,selectionSet:n})=>He(["...",Dt("on ",e),He(t," "),n]," ")},FragmentDefinition:{leave:({name:e,typeCondition:t,variableDefinitions:n,directives:r,selectionSet:i,description:s})=>Dt("",s,` +`)+`fragment ${e}${Dt("(",He(n,", "),")")} on ${t} ${Dt("",He(r," ")," ")}`+i},IntValue:{leave:({value:e})=>e},FloatValue:{leave:({value:e})=>e},StringValue:{leave:({value:e,block:t})=>t===!0?tV(e):nV(e)},BooleanValue:{leave:({value:e})=>e?"true":"false"},NullValue:{leave:()=>"null"},EnumValue:{leave:({value:e})=>e},ListValue:{leave:({values:e})=>{let t="["+He(e,", ")+"]";if(t.length>FN)return`[ `+wg(He(e,` `))+` -]`;return t}},ObjectValue:{leave:({fields:e})=>{let t="{ "+He(e,", ")+" }";return t.length>FN?Po(e):t}},ObjectField:{leave:({name:e,value:t})=>e+": "+t},Directive:{leave:({name:e,arguments:t})=>"@"+e+wt("(",He(t,", "),")")},NamedType:{leave:({name:e})=>e},ListType:{leave:({type:e})=>"["+e+"]"},NonNullType:{leave:({type:e})=>e+"!"},SchemaDefinition:{leave:({description:e,directives:t,operationTypes:n})=>wt("",e,` -`)+He(["schema",He(t," "),Po(n)]," ")},OperationTypeDefinition:{leave:({operation:e,type:t})=>e+": "+t},ScalarTypeDefinition:{leave:({description:e,name:t,directives:n})=>wt("",e,` -`)+He(["scalar",t,He(n," ")]," ")},ObjectTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>wt("",e,` -`)+He(["type",t,wt("implements ",He(n," & ")),He(r," "),Po(i)]," ")},FieldDefinition:{leave:({description:e,name:t,arguments:n,type:r,directives:i})=>wt("",e,` -`)+t+(jN(n)?wt(`( +]`;return t}},ObjectValue:{leave:({fields:e})=>{let t="{ "+He(e,", ")+" }";return t.length>FN?Po(e):t}},ObjectField:{leave:({name:e,value:t})=>e+": "+t},Directive:{leave:({name:e,arguments:t})=>"@"+e+Dt("(",He(t,", "),")")},NamedType:{leave:({name:e})=>e},ListType:{leave:({type:e})=>"["+e+"]"},NonNullType:{leave:({type:e})=>e+"!"},SchemaDefinition:{leave:({description:e,directives:t,operationTypes:n})=>Dt("",e,` +`)+He(["schema",He(t," "),Po(n)]," ")},OperationTypeDefinition:{leave:({operation:e,type:t})=>e+": "+t},ScalarTypeDefinition:{leave:({description:e,name:t,directives:n})=>Dt("",e,` +`)+He(["scalar",t,He(n," ")]," ")},ObjectTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>Dt("",e,` +`)+He(["type",t,Dt("implements ",He(n," & ")),He(r," "),Po(i)]," ")},FieldDefinition:{leave:({description:e,name:t,arguments:n,type:r,directives:i})=>Dt("",e,` +`)+t+(jN(n)?Dt(`( `,wg(He(n,` `)),` -)`):wt("(",He(n,", "),")"))+": "+r+wt(" ",He(i," "))},InputValueDefinition:{leave:({description:e,name:t,type:n,defaultValue:r,directives:i})=>wt("",e,` -`)+He([t+": "+n,wt("= ",r),He(i," ")]," ")},InterfaceTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>wt("",e,` -`)+He(["interface",t,wt("implements ",He(n," & ")),He(r," "),Po(i)]," ")},UnionTypeDefinition:{leave:({description:e,name:t,directives:n,types:r})=>wt("",e,` -`)+He(["union",t,He(n," "),wt("= ",He(r," | "))]," ")},EnumTypeDefinition:{leave:({description:e,name:t,directives:n,values:r})=>wt("",e,` -`)+He(["enum",t,He(n," "),Po(r)]," ")},EnumValueDefinition:{leave:({description:e,name:t,directives:n})=>wt("",e,` -`)+He([t,He(n," ")]," ")},InputObjectTypeDefinition:{leave:({description:e,name:t,directives:n,fields:r})=>wt("",e,` -`)+He(["input",t,He(n," "),Po(r)]," ")},DirectiveDefinition:{leave:({description:e,name:t,arguments:n,directives:r,repeatable:i,locations:s})=>wt("",e,` -`)+"directive @"+t+(jN(n)?wt(`( +)`):Dt("(",He(n,", "),")"))+": "+r+Dt(" ",He(i," "))},InputValueDefinition:{leave:({description:e,name:t,type:n,defaultValue:r,directives:i})=>Dt("",e,` +`)+He([t+": "+n,Dt("= ",r),He(i," ")]," ")},InterfaceTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>Dt("",e,` +`)+He(["interface",t,Dt("implements ",He(n," & ")),He(r," "),Po(i)]," ")},UnionTypeDefinition:{leave:({description:e,name:t,directives:n,types:r})=>Dt("",e,` +`)+He(["union",t,He(n," "),Dt("= ",He(r," | "))]," ")},EnumTypeDefinition:{leave:({description:e,name:t,directives:n,values:r})=>Dt("",e,` +`)+He(["enum",t,He(n," "),Po(r)]," ")},EnumValueDefinition:{leave:({description:e,name:t,directives:n})=>Dt("",e,` +`)+He([t,He(n," ")]," ")},InputObjectTypeDefinition:{leave:({description:e,name:t,directives:n,fields:r})=>Dt("",e,` +`)+He(["input",t,He(n," "),Po(r)]," ")},DirectiveDefinition:{leave:({description:e,name:t,arguments:n,directives:r,repeatable:i,locations:s})=>Dt("",e,` +`)+"directive @"+t+(jN(n)?Dt(`( `,wg(He(n,` `)),` -)`):wt("(",He(n,", "),")"))+wt(" ",He(r," "))+(i?" repeatable":"")+" on "+He(s," | ")},SchemaExtension:{leave:({directives:e,operationTypes:t})=>He(["extend schema",He(e," "),Po(t)]," ")},ScalarTypeExtension:{leave:({name:e,directives:t})=>He(["extend scalar",e,He(t," ")]," ")},ObjectTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>He(["extend type",e,wt("implements ",He(t," & ")),He(n," "),Po(r)]," ")},InterfaceTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>He(["extend interface",e,wt("implements ",He(t," & ")),He(n," "),Po(r)]," ")},UnionTypeExtension:{leave:({name:e,directives:t,types:n})=>He(["extend union",e,He(t," "),wt("= ",He(n," | "))]," ")},EnumTypeExtension:{leave:({name:e,directives:t,values:n})=>He(["extend enum",e,He(t," "),Po(n)]," ")},InputObjectTypeExtension:{leave:({name:e,directives:t,fields:n})=>He(["extend input",e,He(t," "),Po(n)]," ")},DirectiveExtension:{leave:({name:e,directives:t})=>He(["extend directive @"+e,He(t," ")]," ")},TypeCoordinate:{leave:({name:e})=>e},MemberCoordinate:{leave:({name:e,memberName:t})=>He([e,wt(".",t)])},ArgumentCoordinate:{leave:({name:e,fieldName:t,argumentName:n})=>He([e,wt(".",t),wt("(",n,":)")])},DirectiveCoordinate:{leave:({name:e})=>He(["@",e])},DirectiveArgumentCoordinate:{leave:({name:e,argumentName:t})=>He(["@",e,wt("(",t,":)")])}};function He(e,t=""){return e?.filter((n)=>n!==void 0&&n!=="").join(t)??""}function Po(e){return wt(`{ +)`):Dt("(",He(n,", "),")"))+Dt(" ",He(r," "))+(i?" repeatable":"")+" on "+He(s," | ")},SchemaExtension:{leave:({directives:e,operationTypes:t})=>He(["extend schema",He(e," "),Po(t)]," ")},ScalarTypeExtension:{leave:({name:e,directives:t})=>He(["extend scalar",e,He(t," ")]," ")},ObjectTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>He(["extend type",e,Dt("implements ",He(t," & ")),He(n," "),Po(r)]," ")},InterfaceTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>He(["extend interface",e,Dt("implements ",He(t," & ")),He(n," "),Po(r)]," ")},UnionTypeExtension:{leave:({name:e,directives:t,types:n})=>He(["extend union",e,He(t," "),Dt("= ",He(n," | "))]," ")},EnumTypeExtension:{leave:({name:e,directives:t,values:n})=>He(["extend enum",e,He(t," "),Po(n)]," ")},InputObjectTypeExtension:{leave:({name:e,directives:t,fields:n})=>He(["extend input",e,He(t," "),Po(n)]," ")},DirectiveExtension:{leave:({name:e,directives:t})=>He(["extend directive @"+e,He(t," ")]," ")},TypeCoordinate:{leave:({name:e})=>e},MemberCoordinate:{leave:({name:e,memberName:t})=>He([e,Dt(".",t)])},ArgumentCoordinate:{leave:({name:e,fieldName:t,argumentName:n})=>He([e,Dt(".",t),Dt("(",n,":)")])},DirectiveCoordinate:{leave:({name:e})=>He(["@",e])},DirectiveArgumentCoordinate:{leave:({name:e,argumentName:t})=>He(["@",e,Dt("(",t,":)")])}};function He(e,t=""){return e?.filter((n)=>n!==void 0&&n!=="").join(t)??""}function Po(e){return Dt(`{ `,wg(He(e,` `)),` -}`)}function wt(e,t,n=""){return t!=null&&t!==""?e+t+n:""}function wg(e){return wt(" ",e.replaceAll(` +}`)}function Dt(e,t,n=""){return t!=null&&t!==""?e+t+n:""}function wg(e){return Dt(" ",e.replaceAll(` `,` `))}function jN(e){return e?.some((t)=>t.includes(` -`))??!1}function rV(e,t){let n=e+wt("(",He(t,", "),")");if(n.length>FN)n=e+wt(`( +`))??!1}function rV(e,t){let n=e+Dt("(",He(t,", "),")");if(n.length>FN)n=e+Dt(`( `,wg(He(t,` `)),` -)`);return n}function Dg(e,t){switch(e.kind){case Fr:return null;case ui:return parseInt(e.value,10);case gu:return parseFloat(e.value);case ba:case td:case Eo:return e.value;case ko:return e.values.map((n)=>Dg(n,t));case No:return cd(e.fields,(n)=>n.name.value,(n)=>Dg(n.value,t));case _s:return t?.[e.name.value]}}function xs(e){if(e.length===0)throw new ae("Expected name to be a non-empty string.");for(let t=1;tthis.coerceInputValue(Dg(t,n))),this.coerceOutputValue=e.coerceOutputValue??this.serialize,this.coerceInputValue=e.coerceInputValue??this.parseValue,this.coerceInputLiteral=e.coerceInputLiteral,this.valueToLiteral=e.valueToLiteral,this.extensions=Qi(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=e.extensionASTNodes??[],e.parseLiteral){if(!(typeof e.parseValue==="function"&&typeof e.parseLiteral==="function"))Oo(!1,`${this.name} must provide both "parseValue" and "parseLiteral" functions.`)}if(e.coerceInputLiteral){if(!(typeof e.coerceInputValue==="function"&&typeof e.coerceInputLiteral==="function"))Oo(!1,`${this.name} must provide both "coerceInputValue" and "coerceInputLiteral" functions.`)}}get[Symbol.toStringTag](){return"GraphQLScalarType"}toConfig(){return{name:this.name,description:this.description,specifiedByURL:this.specifiedByURL,serialize:this.serialize,parseValue:this.parseValue,parseLiteral:this.parseLiteral,coerceOutputValue:this.coerceOutputValue,coerceInputValue:this.coerceInputValue,coerceInputLiteral:this.coerceInputLiteral,valueToLiteral:this.valueToLiteral,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}class ws{constructor(e){this.__kind=MN,this.__kind=MN,this.name=xs(e.name),this.description=e.description,this.isTypeOf=e.isTypeOf,this.extensions=Qi(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=e.extensionASTNodes??[],this._fields=fV.bind(void 0,this,e.fields),this._interfaces=dV.bind(void 0,e.interfaces)}get[Symbol.toStringTag](){return"GraphQLObjectType"}getFields(){if(typeof this._fields==="function")this._fields=this._fields();return this._fields}getInterfaces(){if(typeof this._interfaces==="function")this._interfaces=this._interfaces();return this._interfaces}toConfig(){return{name:this.name,description:this.description,interfaces:this.getInterfaces(),fields:tl(this.getFields(),(e)=>e.toConfig()),isTypeOf:this.isTypeOf,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function dV(e){return BN(e??[])}function fV(e,t){let n=I0(t);return tl(n,(r,i)=>new mm(e,i,r))}class mm{constructor(e,t,n){this.__kind=Sxe,this.parentType=e,this.name=xs(t),this.description=n.description,this.type=n.type;let r=n.args;this.args=r?Object.entries(r).map(([i,s])=>new Tg(this,i,s)):[],this.resolve=n.resolve,this.subscribe=n.subscribe,this.deprecationReason=n.deprecationReason,this.extensions=Qi(n.extensions),this.astNode=n.astNode}get[Symbol.toStringTag](){return"GraphQLField"}toConfig(){return{description:this.description,type:this.type,args:cd(this.args,(e)=>e.name,(e)=>e.toConfig()),resolve:this.resolve,subscribe:this.subscribe,deprecationReason:this.deprecationReason,extensions:this.extensions,astNode:this.astNode}}toString(){return`${this.parentType??""}.${this.name}`}toJSON(){return this.toString()}}class Tg{constructor(e,t,n){this.__kind=sV,this.parent=e,this.name=xs(t),this.description=n.description,this.type=n.type,this.defaultValue=n.defaultValue,this.default=n.default,this._memoizedCoercedDefaultValue=void 0,this.deprecationReason=n.deprecationReason,this.extensions=Qi(n.extensions),this.astNode=n.astNode}get[Symbol.toStringTag](){return"GraphQLArgument"}toConfig(){return{description:this.description,type:this.type,defaultValue:this.defaultValue,default:this.default,deprecationReason:this.deprecationReason,extensions:this.extensions,astNode:this.astNode}}toString(){return`${this.parent}(${this.name}:)`}toJSON(){return this.toString()}}function xa(e){return Ft(e.type)&&e.default===void 0&&e.defaultValue===void 0}class pd{constructor(e){this.__kind=oV,this.name=xs(e.name),this.description=e.description,this.resolveType=e.resolveType,this.extensions=Qi(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=e.extensionASTNodes??[],this._fields=fV.bind(void 0,this,e.fields),this._interfaces=dV.bind(void 0,e.interfaces)}get[Symbol.toStringTag](){return"GraphQLInterfaceType"}getFields(){if(typeof this._fields==="function")this._fields=this._fields();return this._fields}getInterfaces(){if(typeof this._interfaces==="function")this._interfaces=this._interfaces();return this._interfaces}toConfig(){return{name:this.name,description:this.description,interfaces:this.getInterfaces(),fields:tl(this.getFields(),(e)=>e.toConfig()),resolveType:this.resolveType,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}class dd{constructor(e){this.__kind=aV,this.name=xs(e.name),this.description=e.description,this.resolveType=e.resolveType,this.extensions=Qi(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=e.extensionASTNodes??[],this._types=Nxe.bind(void 0,e.types)}get[Symbol.toStringTag](){return"GraphQLUnionType"}getTypes(){if(typeof this._types==="function")this._types=this._types();return this._types}toConfig(){return{name:this.name,description:this.description,types:this.getTypes(),resolveType:this.resolveType,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function Nxe(e){return BN(e)}class rl{constructor(e){this.__kind=lV,this.name=xs(e.name),this.description=e.description,this.extensions=Qi(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=e.extensionASTNodes??[],this._values=Oxe.bind(void 0,this,e.values),this._valueLookup=null,this._nameLookup=null}get[Symbol.toStringTag](){return"GraphQLEnumType"}getValues(){if(typeof this._values==="function")this._values=this._values();return this._values}getValue(e){return this._nameLookup??=lm(this.getValues(),(t)=>t.name),this._nameLookup[e]}serialize(e){return this.coerceOutputValue(e)}coerceOutputValue(e){this._valueLookup??=new Map(this.getValues().map((n)=>[n.value,n]));let t=this._valueLookup.get(e);if(t===void 0)throw new ae(`Enum "${this.name}" cannot represent value: ${qe(e)}`);return t.name}parseValue(e,t){return this.coerceInputValue(e,t)}coerceInputValue(e,t){if(typeof e!=="string"){let r=qe(e);throw new ae(`Enum "${this.name}" cannot represent non-string value: ${r}.`+(t?"":O0(this,r)))}let n=this.getValue(e);if(n==null)throw new ae(`Value "${e}" does not exist in "${this.name}" enum.`+(t?"":O0(this,e)));return n.value}parseLiteral(e,t,n){return this.coerceInputLiteral(e,n)}coerceInputLiteral(e,t){if(e.kind!==td){let r=hn(e);throw new ae(`Enum "${this.name}" cannot represent non-enum value: ${r}.`+(t?"":O0(this,r)),{nodes:e})}let n=this.getValue(e.value);if(n==null){let r=hn(e);throw new ae(`Value "${r}" does not exist in "${this.name}" enum.`+(t?"":O0(this,r)),{nodes:e})}return n.value}valueToLiteral(e){if(typeof e==="string"&&this.getValue(e))return{kind:td,value:e}}toConfig(){return{name:this.name,description:this.description,values:cd(this.getValues(),(e)=>e.name,(e)=>e.toConfig()),extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function Oxe(e,t){let n=I0(t);return Object.entries(n).map(([r,i])=>new mV(e,r,i))}function O0(e,t){let n=e.getValues().map((i)=>i.name),r=Wi(t,n);return Oi("the enum value",r)}class mV{constructor(e,t,n){this.__kind=Exe,this.parentEnum=e,this.name=CN(t),this.description=n.description,this.value=n.value!==void 0?n.value:t,this.deprecationReason=n.deprecationReason,this.extensions=Qi(n.extensions),this.astNode=n.astNode}get[Symbol.toStringTag](){return"GraphQLEnumValue"}toConfig(){return{description:this.description,value:this.value,deprecationReason:this.deprecationReason,extensions:this.extensions,astNode:this.astNode}}toString(){return`${this.parentEnum.name}.${this.name}`}toJSON(){return this.toString()}}class fd{constructor(e){this.__kind=cV,this.name=xs(e.name),this.description=e.description,this.extensions=Qi(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=e.extensionASTNodes??[],this.isOneOf=e.isOneOf??!1,this._fields=Pxe.bind(void 0,this,e.fields)}get[Symbol.toStringTag](){return"GraphQLInputObjectType"}getFields(){if(typeof this._fields==="function")this._fields=this._fields();return this._fields}toConfig(){return{name:this.name,description:this.description,fields:tl(this.getFields(),(e)=>e.toConfig()),extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes,isOneOf:this.isOneOf}}toString(){return this.name}toJSON(){return this.toString()}}function Pxe(e,t){let n=I0(t);return tl(n,(r,i)=>new yV(e,i,r))}class yV{constructor(e,t,n){if("resolve"in n)Oo(!1,`${e}.${t} field has a resolve property, but Input Types cannot define resolvers.`);this.__kind=kxe,this.parentType=e,this.name=xs(t),this.description=n.description,this.type=n.type,this.defaultValue=n.defaultValue,this.default=n.default,this._memoizedCoercedDefaultValue=void 0,this.deprecationReason=n.deprecationReason,this.extensions=Qi(n.extensions),this.astNode=n.astNode}get[Symbol.toStringTag](){return"GraphQLInputField"}toConfig(){return{description:this.description,type:this.type,defaultValue:this.defaultValue,default:this.default,deprecationReason:this.deprecationReason,extensions:this.extensions,astNode:this.astNode}}toString(){return`${this.parentType}.${this.name}`}toJSON(){return this.toString()}}function Ao(e){return Ft(e.type)&&e.defaultValue===void 0&&e.default===void 0}function Sg(e,t){if(e===t)return!0;if(Ft(e)&&Ft(t))return Sg(e.ofType,t.ofType);if(fn(e)&&fn(t))return Sg(e.ofType,t.ofType);return!1}function Zl(e,t,n){if(t===n)return!0;if(Ft(n)){if(Ft(t))return Zl(e,t.ofType,n.ofType);return!1}if(Ft(t))return Zl(e,t.ofType,n);if(fn(n)){if(fn(t))return Zl(e,t.ofType,n.ofType);return!1}if(fn(t))return!1;return Io(n)&&(dn(t)||Dn(t))&&e.isSubType(n,t)}function A0(e,t,n){if(t===n)return!0;if(Io(t)){if(Io(n))return e.getPossibleTypes(t).some((r)=>e.isSubType(n,r));return e.isSubType(t,n)}if(Io(n))return e.isSubType(n,t);return!1}function md(e,t,n){return{prev:e,key:t,typename:n}}function Eg(e){let t=[],n=e;while(n)t.push(n.key),n=n.prev;return t.reverse()}function ec(e,t){if(Ft(t)){if(e==null)return;return ec(e,t.ofType)}if(e==null)return{kind:Fr};if(fn(t)){if(!So(e))return ec(e,t.ofType);let r=[];for(let i of e){let s=ec(i,t.ofType);if(!s)return;r.push(s)}return{kind:ko,values:r}}if(en(t)){if(!Rr(e))return;let r=[],i=t.getFields();if(Object.keys(e).some((o)=>e[o]!==void 0&&!Object.hasOwn(i,o)))return;for(let o of Object.values(t.getFields()))if(e[o.name]===void 0){if(Ao(o))return}else{let l=ec(e[o.name],o.type);if(!l)return;r.push({kind:bg,name:{kind:hg,value:o.name},value:l})}return{kind:No,fields:r}}let n=va(t);if(n.valueToLiteral)try{return n.valueToLiteral(e)}catch(r){return}return yd(e)}function yd(e){if(e==null)return{kind:Fr};switch(typeof e){case"boolean":return{kind:Eo,value:e};case"string":return{kind:ba,value:e,block:!1};case"bigint":return{kind:ui,value:e.toString()};case"number":{if(!Number.isFinite(e))return{kind:Fr};let t=String(e);return/^-?(?:0|[1-9][0-9]*)$/.test(t)?{kind:ui,value:t}:{kind:gu,value:t}}case"object":{if(So(e))return{kind:ko,values:Array.from(e,yd)};let t=e,n=[];for(let r of Object.keys(t)){let i=t[r];if(i!==void 0)n.push({kind:bg,name:{kind:hg,value:r},value:yd(i)})}return{kind:No,fields:n}}}throw TypeError(`Cannot convert value to AST: ${qe(e)}.`)}function Eu(e,t,n){switch(e.kind){case _s:{let r=e.name.value,i=n?.sources[r];if(i){let o=i.value;if(o===void 0){let a=i.signature.default;if(a!==void 0)return a.literal;return{kind:Fr}}return Eu(o,t,i.fragmentVariableValues)}let s=t?.sources[r];if(s==null)return{kind:Fr};if(s.value===void 0){let o=s.signature.default;if(o!==void 0)return o.literal}return ec(s.value,s.signature.type)}case No:{let r=[];for(let i of e.fields){if(i.value.kind===_s){let o=n?.sources[i.value.name.value]??t?.sources[i.value.name.value];if(o?.value===void 0&&o?.signature.default===void 0)continue}let s=Eu(i.value,t,n);r.push({...i,value:s})}return{...e,fields:r}}case ko:{let r=[];for(let i of e.values){let s=Eu(i,t,n);r.push(s)}return{...e,values:r}}default:return e}}function Og(e,t,n,r){return kg(e,t,n,r,void 0)}function kg(e,t,n,r,i){if(Ft(t)){if(e===void 0){ku(n,`Expected a value of non-null type "${t}" to be provided.`,i);return}if(e===null){ku(n,`Expected value of non-null type "${t}" not to be null.`,i);return}return kg(e,t.ofType,n,r,i)}if(e==null)return;if(fn(t))if(!So(e))kg(e,t.ofType,n,r,i);else{let s=0;for(let o of e)kg(o,t.ofType,n,r,md(i,s++,void 0))}else if(en(t)){if(!Rr(e)||Array.isArray(e)){ku(n,`Expected value of type "${t}" to be an object, found: ${qe(e)}.`,i);return}let s=t.getFields();for(let a of Object.values(s)){let l=e[a.name];if(l===void 0){if(Ao(a))ku(n,`Expected value of type "${t}" to include required field "${a.name}", found: ${qe(e)}.`,i)}else kg(l,a.type,n,r,md(i,a.name,t.name))}let o=[];for(let a of Object.keys(e)){if(e[a]===void 0)continue;if(!Object.hasOwn(s,a)){let l=r?"":Oi(Wi(a,Object.keys(s)));ku(n,`Expected value of type "${t}" not to include unknown field "${a}"${l?`.${l} Found`:", found"}: ${qe(e)}.`,i);continue}o.push(a)}if(t.isOneOf){if(o.length!==1)ku(n,R0(t),i);let a=o[0];if(e[a]===null)ku(n,R0(t),md(i,a,t.name))}}else{va(t);let s,o;try{s=t.coerceInputValue(e,r)}catch(a){if(a instanceof ae){n(a,Eg(i));return}o=a}if(s===void 0)ku(n,`Expected value of type "${t}"${o!=null?`, but encountered error "${gV(o)}"; found`:", found"}: ${qe(e)}.`,i,dg(o))}}function ku(e,t,n,r){e(new ae(t,{originalError:r}),Eg(n))}function hd(e,t,n,r,i,s){return Ng({static:!r&&!i,onError:n,variables:r,fragmentVariableValues:i},e,t,s,void 0)}function Ng(e,t,n,r,i){if(t.kind===_s){if(e.static)return;let o=hV(e,t)?.coerced[t.name.value];if(Ft(n)){if(o===void 0)wa(e.onError,`Expected variable "$${t.name.value}" provided to type "${n}" to provide a runtime value.`,t,i);else if(o===null)wa(e.onError,`Expected variable "$${t.name.value}" provided to non-null type "${n}" not to be null.`,t,i)}return}if(Ft(n)){if(t.kind===Fr){wa(e.onError,`Expected value of non-null type "${n}" not to be null.`,t,i);return}return Ng(e,t,n.ofType,r,i)}if(t.kind===Fr)return;if(fn(n))if(t.kind!==ko)Ng(e,t,n.ofType,r,i);else{let s=0;for(let o of t.values)Ng(e,o,n.ofType,r,md(i,s++,void 0))}else if(en(n)){if(t.kind!==No){wa(e.onError,`Expected value of type "${n}" to be an object, found: ${hn(t)}.`,t,i);return}let s=n.getFields(),o=lm(t.fields,(c)=>c.name.value);for(let c of Object.values(s)){let u=o[c.name];if(u===void 0){if(Ao(c))wa(e.onError,`Expected value of type "${n}" to include required field "${c.name}", found: ${hn(t)}.`,t,i)}else{let p=u.value;if(p.kind===_s&&!e.static){let d=hV(e,p),f=p.name.value,m=d?.coerced[f];if(n.isOneOf){if(m===void 0)wa(e.onError,`Expected variable "$${f}" provided to field "${c.name}" for OneOf Input Object type "${n}" to provide a runtime value.`,t,i);else if(m===null)wa(e.onError,`Expected variable "$${f}" provided to field "${c.name}" for OneOf Input Object type "${n}" not to be null.`,t,i)}else if(m===void 0&&!Ao(c))continue}Ng(e,p,c.type,r,md(i,c.name,n.name))}}let a=t.fields,l=[];for(let c of a){let u=c.name.value;if(!Object.hasOwn(s,u)){let p=r?"":Oi(Wi(u,Object.keys(s)));wa(e.onError,`Expected value of type "${n}" not to include unknown field "${u}"${p?`.${p} Found`:", found"}: ${hn(t)}.`,c,i)}else l.push(c)}if(n.isOneOf){if(l.length!==1){wa(e.onError,R0(n),t,i);return}if(l[0].value.kind===Fr){let p=l[0].name.value;wa(e.onError,R0(n),t,md(i,p,void 0))}}}else{va(n);let s,o;try{s=n.coerceInputLiteral?n.coerceInputLiteral(Eu(t,e.variables,e.fragmentVariableValues),r):n.parseLiteral(t,void 0,r)}catch(a){if(a instanceof ae){e.onError(a,Eg(i));return}o=a}if(s===void 0)wa(e.onError,`Expected value of type "${n}"${o!=null?`, but encountered error "${gV(o)}"; found`:", found"}: ${hn(t)}.`,t,i,dg(o))}}function hV(e,t){let n=t.name.value,{fragmentVariableValues:r,variables:i}=e;return r?.sources[n]?r:i}function wa(e,t,n,r,i){e(new ae(t,{nodes:n,originalError:i}),Eg(r))}function gV(e){if(Rr(e)){let t=e.message;if(typeof t==="string"&&t!=="")return t}return String(e)}function R0(e){return`Within OneOf Input Object type "${e}", exactly one field must be specified, and the value for that field must be non-null.`}var et={QUERY:"QUERY",MUTATION:"MUTATION",SUBSCRIPTION:"SUBSCRIPTION",FIELD:"FIELD",FRAGMENT_DEFINITION:"FRAGMENT_DEFINITION",FRAGMENT_SPREAD:"FRAGMENT_SPREAD",INLINE_FRAGMENT:"INLINE_FRAGMENT",VARIABLE_DEFINITION:"VARIABLE_DEFINITION",FRAGMENT_VARIABLE_DEFINITION:"FRAGMENT_VARIABLE_DEFINITION",SCHEMA:"SCHEMA",SCALAR:"SCALAR",OBJECT:"OBJECT",FIELD_DEFINITION:"FIELD_DEFINITION",ARGUMENT_DEFINITION:"ARGUMENT_DEFINITION",INTERFACE:"INTERFACE",UNION:"UNION",ENUM:"ENUM",ENUM_VALUE:"ENUM_VALUE",INPUT_OBJECT:"INPUT_OBJECT",INPUT_FIELD_DEFINITION:"INPUT_FIELD_DEFINITION",DIRECTIVE_DEFINITION:"DIRECTIVE_DEFINITION"};var ym=2147483647,hm=-2147483648,j0=new Hs({name:"Int",description:"The `Int` scalar type represents non-fractional signed whole numeric values. Int can represent values between -(2^31) and 2^31 - 1.",coerceOutputValue(e){let t=Pg(e);if(typeof t==="number")return bV(t);if(typeof t==="boolean")return t?1:0;if(typeof t==="string")return $xe(t);if(typeof t==="bigint")return vV(t);throw new ae(`Int cannot represent non-integer value: ${qe(t)}`)},coerceInputValue(e){if(typeof e==="number")return bV(e);if(typeof e==="bigint")return vV(e);throw new ae(`Int cannot represent non-integer value: ${qe(e)}`)},coerceInputLiteral(e){if(e.kind!==ui)throw new ae(`Int cannot represent non-integer value: ${hn(e)}`,{nodes:e});let t=parseInt(e.value,10);if(t>ym||t=hm)return{kind:ui,value:String(e)}}}),wV=new Hs({name:"Float",description:"The `Float` scalar type represents signed double-precision fractional values as specified by [IEEE 754](https://en.wikipedia.org/wiki/IEEE_floating_point).",coerceOutputValue(e){let t=Pg(e);if(typeof t==="number")return _V(t);if(typeof t==="boolean")return t?1:0;if(typeof t==="string")return Ixe(t);if(typeof t==="bigint")return xV(t);throw new ae(`Float cannot represent non numeric value: ${qe(t)}`)},coerceInputValue(e){if(typeof e==="number")return _V(e);if(typeof e==="bigint")return xV(e);throw new ae(`Float cannot represent non numeric value: ${qe(e)}`)},coerceInputLiteral(e){if(e.kind!==gu&&e.kind!==ui)throw new ae(`Float cannot represent non numeric value: ${hn(e)}`,{nodes:e});return parseFloat(e.value)},valueToLiteral(e){let t=yd(e);if(t.kind===gu||t.kind===ui)return t}}),Cn=new Hs({name:"String",description:"The `String` scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.",coerceOutputValue(e){let t=Pg(e);if(typeof t==="string")return t;if(typeof t==="boolean")return t?"true":"false";if(typeof t==="number")return Axe(t);if(typeof t==="bigint")return String(t);throw new ae(`String cannot represent value: ${qe(e)}`)},coerceInputValue(e){if(typeof e!=="string")throw new ae(`String cannot represent a non string value: ${qe(e)}`);return e},coerceInputLiteral(e){if(e.kind!==ba)throw new ae(`String cannot represent a non string value: ${hn(e)}`,{nodes:e});return e.value},valueToLiteral(e){let t=yd(e);if(t.kind===ba)return t}}),Sr=new Hs({name:"Boolean",description:"The `Boolean` scalar type represents `true` or `false`.",coerceOutputValue(e){let t=Pg(e);if(typeof t==="boolean")return t;if(typeof t==="number")return Rxe(t);if(typeof t==="bigint")return t!==0n;throw new ae(`Boolean cannot represent a non boolean value: ${qe(t)}`)},coerceInputValue(e){if(typeof e!=="boolean")throw new ae(`Boolean cannot represent a non boolean value: ${qe(e)}`);return e},coerceInputLiteral(e){if(e.kind!==Eo)throw new ae(`Boolean cannot represent a non boolean value: ${hn(e)}`,{nodes:e});return e.value},valueToLiteral(e){let t=yd(e);if(t.kind===Eo)return t}}),F0=new Hs({name:"ID",description:'The `ID` scalar type represents a unique identifier, often used to refetch an object or as key for a cache. The ID type appears in a JSON response as a String; however, it is not intended to be human-readable. When expected as an input type, any string (such as `"4"`) or integer (such as `4`) input value will be accepted as an ID.',coerceOutputValue(e){let t=Pg(e);if(typeof t==="string")return t;if(typeof t==="number")return VN(t);if(typeof t==="bigint")return String(t);throw new ae(`ID cannot represent value: ${qe(e)}`)},coerceInputValue(e){if(typeof e==="string")return e;if(typeof e==="number")return VN(e);if(typeof e==="bigint")return String(e);throw new ae(`ID cannot represent value: ${qe(e)}`)},coerceInputLiteral(e){if(e.kind!==ba&&e.kind!==ui)throw new ae("ID cannot represent a non-string and non-integer value: "+hn(e),{nodes:e});return e.value},valueToLiteral(e){if(typeof e==="string")return/^-?(?:0|[1-9][0-9]*)$/.test(e)?{kind:ui,value:e}:{kind:ba,value:e,block:!1};if(typeof e==="number")return{kind:ui,value:VN(e)};if(typeof e==="bigint")return{kind:ui,value:String(e)}}}),Nu=Object.freeze([Cn,j0,wV,Sr,F0]);function KN(e){return Nu.some(({name:t})=>e.name===t)}function Pg(e){if(Rr(e)){if(typeof e.valueOf==="function"){let t=e.valueOf();if(!Rr(t))return t}if(typeof e.toJSON==="function")return e.toJSON()}return e}function bV(e){if(!Number.isInteger(e))throw new ae(`Int cannot represent non-integer value: ${qe(e)}`);if(e>ym||eym||tym||enew Tg(this,n,r))}get[Symbol.toStringTag](){return"GraphQLDirective"}toConfig(){return{name:this.name,description:this.description,locations:this.locations,args:cd(this.args,(e)=>e.name,(e)=>e.toConfig()),isRepeatable:this.isRepeatable,deprecationReason:this.deprecationReason,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return"@"+this.name}toJSON(){return this.toString()}}var gd=new Pi({name:"include",description:"Directs the executor to include this field or fragment only when the `if` argument is true.",locations:[et.FIELD,et.FRAGMENT_SPREAD,et.INLINE_FRAGMENT],args:{if:{type:new dt(Sr),description:"Included when true."}}}),bd=new Pi({name:"skip",description:"Directs the executor to skip this field or fragment when the `if` argument is true.",locations:[et.FIELD,et.FRAGMENT_SPREAD,et.INLINE_FRAGMENT],args:{if:{type:new dt(Sr),description:"Skipped when true."}}}),tc=new Pi({name:"defer",description:"Directs the executor to defer this fragment when the `if` argument is true or undefined.",locations:[et.FRAGMENT_SPREAD,et.INLINE_FRAGMENT],args:{if:{type:new dt(Sr),description:"Deferred when true or undefined.",default:{value:!0}},label:{type:Cn,description:"Unique name"}}}),nc=new Pi({name:"stream",description:"Directs the executor to stream plural fields when the `if` argument is true or undefined.",locations:[et.FIELD],args:{initialCount:{default:{value:0},type:new dt(j0),description:"Number of items to return immediately"},if:{type:new dt(Sr),description:"Stream when true or undefined.",default:{value:!0}},label:{type:Cn,description:"Unique name"}}}),TV="No longer supported",gm=new Pi({name:"deprecated",description:"Marks an element of a GraphQL schema as no longer supported.",locations:[et.FIELD_DEFINITION,et.ARGUMENT_DEFINITION,et.INPUT_FIELD_DEFINITION,et.ENUM_VALUE,et.DIRECTIVE_DEFINITION],args:{reason:{type:new dt(Cn),description:"Explains why this element was deprecated, usually also including a suggestion for how to access supported similar data. Formatted using the Markdown syntax, as specified by [CommonMark](https://commonmark.org/).",default:{value:TV}}}}),C0=new Pi({name:"specifiedBy",description:"Exposes a URL that specifies the behavior of this scalar.",locations:[et.SCALAR],args:{url:{type:new dt(Cn),description:"The URL that specifies the behavior of this scalar."}}}),M0=new Pi({name:"oneOf",description:"Indicates exactly one field must be supplied and this field must not be `null`.",locations:[et.INPUT_OBJECT],args:{}}),YYe=new Pi({name:"experimental_disableErrorPropagation",description:"Disables error propagation.",locations:[et.QUERY,et.MUTATION,et.SUBSCRIPTION]}),Ds=Object.freeze([gd,bd,gm,C0,M0]);function JN(e){return Ds.some(({name:t})=>t===e.name)}function vd(e,t){if(Ft(t)){let n=vd(e,t.ofType);if(n?.kind===Fr)return null;return n}if(e===null)return{kind:Fr};if(e===void 0)return null;if(fn(t)){let n=t.ofType;if(So(e)){let r=[];for(let i of e){let s=vd(i,n);if(s!=null)r.push(s)}return{kind:ko,values:r}}return vd(e,n)}if(en(t)){if(!Rr(e))return null;let n=[];for(let r of Object.values(t.getFields())){let i=vd(e[r.name],r.type);if(i)n.push({kind:bg,name:{kind:hg,value:r.name},value:i})}return{kind:No,fields:n}}if(Xl(t)){let n=t.coerceOutputValue(e);if(n==null)return null;if(typeof n==="boolean")return{kind:Eo,value:n};if(typeof n==="number"&&Number.isFinite(n)){let r=String(n);return SV.test(r)?{kind:ui,value:r}:{kind:gu,value:r}}if(typeof n==="bigint")return{kind:ui,value:String(n)};if(typeof n==="string"){if(Cr(t))return{kind:td,value:n};if(t===F0&&SV.test(n))return{kind:ui,value:n};return{kind:ba,value:n}}throw TypeError(`Cannot convert value to AST: ${qe(n)}.`)}cn(!1,"Unexpected input type: "+qe(t))}var SV=/^-?(?:0|[1-9][0-9]*)$/;function EV(e){let{type:t,default:n}=e;if(n){let i=n.literal??ec(n.value,t);if(i==null)cn(!1,"Invalid default value");return i}let r=e.defaultValue;if(r!==void 0){let i=vd(r,t);if(i==null)cn(!1,"Invalid default value");return i}return}var Ig=new ws({name:"__Schema",description:"A GraphQL Schema defines the capabilities of a GraphQL server. It exposes all available types and directives on the server, as well as the entry points for query, mutation, and subscription operations.",fields:()=>({description:{type:Cn,resolve:(e)=>e.description},types:{description:"A list of all types supported by this server.",type:new dt(new Tr(new dt(Ro))),resolve(e){return Object.values(e.getTypeMap())}},queryType:{description:"The type that query operations will be rooted at.",type:new dt(Ro),resolve:(e)=>e.getQueryType()},mutationType:{description:"If this server supports mutation, the type that mutation operations will be rooted at.",type:Ro,resolve:(e)=>e.getMutationType()},subscriptionType:{description:"If this server support subscription, the type that subscription operations will be rooted at.",type:Ro,resolve:(e)=>e.getSubscriptionType()},directives:{description:"A list of all directives supported by this server.",type:new dt(new Tr(new dt(GN))),args:{includeDeprecated:{type:new dt(Sr),default:{value:!1}}},resolve:(e,{includeDeprecated:t})=>t===!0?e.getDirectives():e.getDirectives().filter((n)=>n.deprecationReason==null)}})}),GN=new ws({name:"__Directive",description:`A Directive provides a way to describe alternate runtime execution and type validation behavior in a GraphQL document. +)`);return n}function Dg(e,t){switch(e.kind){case Cr:return null;case pi:return parseInt(e.value,10);case bu:return parseFloat(e.value);case ba:case rd:case Eo:return e.value;case ko:return e.values.map((n)=>Dg(n,t));case No:return pd(e.fields,(n)=>n.name.value,(n)=>Dg(n.value,t));case xs:return t?.[e.name.value]}}function ws(e){if(e.length===0)throw new ae("Expected name to be a non-empty string.");for(let t=1;tthis.coerceInputValue(Dg(t,n))),this.coerceOutputValue=e.coerceOutputValue??this.serialize,this.coerceInputValue=e.coerceInputValue??this.parseValue,this.coerceInputLiteral=e.coerceInputLiteral,this.valueToLiteral=e.valueToLiteral,this.extensions=Yi(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=e.extensionASTNodes??[],e.parseLiteral){if(!(typeof e.parseValue==="function"&&typeof e.parseLiteral==="function"))Oo(!1,`${this.name} must provide both "parseValue" and "parseLiteral" functions.`)}if(e.coerceInputLiteral){if(!(typeof e.coerceInputValue==="function"&&typeof e.coerceInputLiteral==="function"))Oo(!1,`${this.name} must provide both "coerceInputValue" and "coerceInputLiteral" functions.`)}}get[Symbol.toStringTag](){return"GraphQLScalarType"}toConfig(){return{name:this.name,description:this.description,specifiedByURL:this.specifiedByURL,serialize:this.serialize,parseValue:this.parseValue,parseLiteral:this.parseLiteral,coerceOutputValue:this.coerceOutputValue,coerceInputValue:this.coerceInputValue,coerceInputLiteral:this.coerceInputLiteral,valueToLiteral:this.valueToLiteral,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}class Ds{constructor(e){this.__kind=MN,this.__kind=MN,this.name=ws(e.name),this.description=e.description,this.isTypeOf=e.isTypeOf,this.extensions=Yi(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=e.extensionASTNodes??[],this._fields=fV.bind(void 0,this,e.fields),this._interfaces=dV.bind(void 0,e.interfaces)}get[Symbol.toStringTag](){return"GraphQLObjectType"}getFields(){if(typeof this._fields==="function")this._fields=this._fields();return this._fields}getInterfaces(){if(typeof this._interfaces==="function")this._interfaces=this._interfaces();return this._interfaces}toConfig(){return{name:this.name,description:this.description,interfaces:this.getInterfaces(),fields:tl(this.getFields(),(e)=>e.toConfig()),isTypeOf:this.isTypeOf,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function dV(e){return BN(e??[])}function fV(e,t){let n=I0(t);return tl(n,(r,i)=>new hm(e,i,r))}class hm{constructor(e,t,n){this.__kind=Exe,this.parentType=e,this.name=ws(t),this.description=n.description,this.type=n.type;let r=n.args;this.args=r?Object.entries(r).map(([i,s])=>new Tg(this,i,s)):[],this.resolve=n.resolve,this.subscribe=n.subscribe,this.deprecationReason=n.deprecationReason,this.extensions=Yi(n.extensions),this.astNode=n.astNode}get[Symbol.toStringTag](){return"GraphQLField"}toConfig(){return{description:this.description,type:this.type,args:pd(this.args,(e)=>e.name,(e)=>e.toConfig()),resolve:this.resolve,subscribe:this.subscribe,deprecationReason:this.deprecationReason,extensions:this.extensions,astNode:this.astNode}}toString(){return`${this.parentType??""}.${this.name}`}toJSON(){return this.toString()}}class Tg{constructor(e,t,n){this.__kind=sV,this.parent=e,this.name=ws(t),this.description=n.description,this.type=n.type,this.defaultValue=n.defaultValue,this.default=n.default,this._memoizedCoercedDefaultValue=void 0,this.deprecationReason=n.deprecationReason,this.extensions=Yi(n.extensions),this.astNode=n.astNode}get[Symbol.toStringTag](){return"GraphQLArgument"}toConfig(){return{description:this.description,type:this.type,defaultValue:this.defaultValue,default:this.default,deprecationReason:this.deprecationReason,extensions:this.extensions,astNode:this.astNode}}toString(){return`${this.parent}(${this.name}:)`}toJSON(){return this.toString()}}function xa(e){return Ft(e.type)&&e.default===void 0&&e.defaultValue===void 0}class fd{constructor(e){this.__kind=oV,this.name=ws(e.name),this.description=e.description,this.resolveType=e.resolveType,this.extensions=Yi(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=e.extensionASTNodes??[],this._fields=fV.bind(void 0,this,e.fields),this._interfaces=dV.bind(void 0,e.interfaces)}get[Symbol.toStringTag](){return"GraphQLInterfaceType"}getFields(){if(typeof this._fields==="function")this._fields=this._fields();return this._fields}getInterfaces(){if(typeof this._interfaces==="function")this._interfaces=this._interfaces();return this._interfaces}toConfig(){return{name:this.name,description:this.description,interfaces:this.getInterfaces(),fields:tl(this.getFields(),(e)=>e.toConfig()),resolveType:this.resolveType,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}class md{constructor(e){this.__kind=aV,this.name=ws(e.name),this.description=e.description,this.resolveType=e.resolveType,this.extensions=Yi(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=e.extensionASTNodes??[],this._types=Oxe.bind(void 0,e.types)}get[Symbol.toStringTag](){return"GraphQLUnionType"}getTypes(){if(typeof this._types==="function")this._types=this._types();return this._types}toConfig(){return{name:this.name,description:this.description,types:this.getTypes(),resolveType:this.resolveType,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function Oxe(e){return BN(e)}class rl{constructor(e){this.__kind=lV,this.name=ws(e.name),this.description=e.description,this.extensions=Yi(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=e.extensionASTNodes??[],this._values=Pxe.bind(void 0,this,e.values),this._valueLookup=null,this._nameLookup=null}get[Symbol.toStringTag](){return"GraphQLEnumType"}getValues(){if(typeof this._values==="function")this._values=this._values();return this._values}getValue(e){return this._nameLookup??=um(this.getValues(),(t)=>t.name),this._nameLookup[e]}serialize(e){return this.coerceOutputValue(e)}coerceOutputValue(e){this._valueLookup??=new Map(this.getValues().map((n)=>[n.value,n]));let t=this._valueLookup.get(e);if(t===void 0)throw new ae(`Enum "${this.name}" cannot represent value: ${qe(e)}`);return t.name}parseValue(e,t){return this.coerceInputValue(e,t)}coerceInputValue(e,t){if(typeof e!=="string"){let r=qe(e);throw new ae(`Enum "${this.name}" cannot represent non-string value: ${r}.`+(t?"":O0(this,r)))}let n=this.getValue(e);if(n==null)throw new ae(`Value "${e}" does not exist in "${this.name}" enum.`+(t?"":O0(this,e)));return n.value}parseLiteral(e,t,n){return this.coerceInputLiteral(e,n)}coerceInputLiteral(e,t){if(e.kind!==rd){let r=hn(e);throw new ae(`Enum "${this.name}" cannot represent non-enum value: ${r}.`+(t?"":O0(this,r)),{nodes:e})}let n=this.getValue(e.value);if(n==null){let r=hn(e);throw new ae(`Value "${r}" does not exist in "${this.name}" enum.`+(t?"":O0(this,r)),{nodes:e})}return n.value}valueToLiteral(e){if(typeof e==="string"&&this.getValue(e))return{kind:rd,value:e}}toConfig(){return{name:this.name,description:this.description,values:pd(this.getValues(),(e)=>e.name,(e)=>e.toConfig()),extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function Pxe(e,t){let n=I0(t);return Object.entries(n).map(([r,i])=>new mV(e,r,i))}function O0(e,t){let n=e.getValues().map((i)=>i.name),r=Qi(t,n);return Oi("the enum value",r)}class mV{constructor(e,t,n){this.__kind=kxe,this.parentEnum=e,this.name=CN(t),this.description=n.description,this.value=n.value!==void 0?n.value:t,this.deprecationReason=n.deprecationReason,this.extensions=Yi(n.extensions),this.astNode=n.astNode}get[Symbol.toStringTag](){return"GraphQLEnumValue"}toConfig(){return{description:this.description,value:this.value,deprecationReason:this.deprecationReason,extensions:this.extensions,astNode:this.astNode}}toString(){return`${this.parentEnum.name}.${this.name}`}toJSON(){return this.toString()}}class yd{constructor(e){this.__kind=cV,this.name=ws(e.name),this.description=e.description,this.extensions=Yi(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=e.extensionASTNodes??[],this.isOneOf=e.isOneOf??!1,this._fields=$xe.bind(void 0,this,e.fields)}get[Symbol.toStringTag](){return"GraphQLInputObjectType"}getFields(){if(typeof this._fields==="function")this._fields=this._fields();return this._fields}toConfig(){return{name:this.name,description:this.description,fields:tl(this.getFields(),(e)=>e.toConfig()),extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes,isOneOf:this.isOneOf}}toString(){return this.name}toJSON(){return this.toString()}}function $xe(e,t){let n=I0(t);return tl(n,(r,i)=>new yV(e,i,r))}class yV{constructor(e,t,n){if("resolve"in n)Oo(!1,`${e}.${t} field has a resolve property, but Input Types cannot define resolvers.`);this.__kind=Nxe,this.parentType=e,this.name=ws(t),this.description=n.description,this.type=n.type,this.defaultValue=n.defaultValue,this.default=n.default,this._memoizedCoercedDefaultValue=void 0,this.deprecationReason=n.deprecationReason,this.extensions=Yi(n.extensions),this.astNode=n.astNode}get[Symbol.toStringTag](){return"GraphQLInputField"}toConfig(){return{description:this.description,type:this.type,defaultValue:this.defaultValue,default:this.default,deprecationReason:this.deprecationReason,extensions:this.extensions,astNode:this.astNode}}toString(){return`${this.parentType}.${this.name}`}toJSON(){return this.toString()}}function Ao(e){return Ft(e.type)&&e.defaultValue===void 0&&e.default===void 0}function Sg(e,t){if(e===t)return!0;if(Ft(e)&&Ft(t))return Sg(e.ofType,t.ofType);if(fn(e)&&fn(t))return Sg(e.ofType,t.ofType);return!1}function Zl(e,t,n){if(t===n)return!0;if(Ft(n)){if(Ft(t))return Zl(e,t.ofType,n.ofType);return!1}if(Ft(t))return Zl(e,t.ofType,n);if(fn(n)){if(fn(t))return Zl(e,t.ofType,n.ofType);return!1}if(fn(t))return!1;return Io(n)&&(dn(t)||Dn(t))&&e.isSubType(n,t)}function A0(e,t,n){if(t===n)return!0;if(Io(t)){if(Io(n))return e.getPossibleTypes(t).some((r)=>e.isSubType(n,r));return e.isSubType(t,n)}if(Io(n))return e.isSubType(n,t);return!1}function hd(e,t,n){return{prev:e,key:t,typename:n}}function Eg(e){let t=[],n=e;while(n)t.push(n.key),n=n.prev;return t.reverse()}function ec(e,t){if(Ft(t)){if(e==null)return;return ec(e,t.ofType)}if(e==null)return{kind:Cr};if(fn(t)){if(!So(e))return ec(e,t.ofType);let r=[];for(let i of e){let s=ec(i,t.ofType);if(!s)return;r.push(s)}return{kind:ko,values:r}}if(en(t)){if(!jr(e))return;let r=[],i=t.getFields();if(Object.keys(e).some((o)=>e[o]!==void 0&&!Object.hasOwn(i,o)))return;for(let o of Object.values(t.getFields()))if(e[o.name]===void 0){if(Ao(o))return}else{let l=ec(e[o.name],o.type);if(!l)return;r.push({kind:bg,name:{kind:hg,value:o.name},value:l})}return{kind:No,fields:r}}let n=va(t);if(n.valueToLiteral)try{return n.valueToLiteral(e)}catch(r){return}return gd(e)}function gd(e){if(e==null)return{kind:Cr};switch(typeof e){case"boolean":return{kind:Eo,value:e};case"string":return{kind:ba,value:e,block:!1};case"bigint":return{kind:pi,value:e.toString()};case"number":{if(!Number.isFinite(e))return{kind:Cr};let t=String(e);return/^-?(?:0|[1-9][0-9]*)$/.test(t)?{kind:pi,value:t}:{kind:bu,value:t}}case"object":{if(So(e))return{kind:ko,values:Array.from(e,gd)};let t=e,n=[];for(let r of Object.keys(t)){let i=t[r];if(i!==void 0)n.push({kind:bg,name:{kind:hg,value:r},value:gd(i)})}return{kind:No,fields:n}}}throw TypeError(`Cannot convert value to AST: ${qe(e)}.`)}function ku(e,t,n){switch(e.kind){case xs:{let r=e.name.value,i=n?.sources[r];if(i){let o=i.value;if(o===void 0){let a=i.signature.default;if(a!==void 0)return a.literal;return{kind:Cr}}return ku(o,t,i.fragmentVariableValues)}let s=t?.sources[r];if(s==null)return{kind:Cr};if(s.value===void 0){let o=s.signature.default;if(o!==void 0)return o.literal}return ec(s.value,s.signature.type)}case No:{let r=[];for(let i of e.fields){if(i.value.kind===xs){let o=n?.sources[i.value.name.value]??t?.sources[i.value.name.value];if(o?.value===void 0&&o?.signature.default===void 0)continue}let s=ku(i.value,t,n);r.push({...i,value:s})}return{...e,fields:r}}case ko:{let r=[];for(let i of e.values){let s=ku(i,t,n);r.push(s)}return{...e,values:r}}default:return e}}function Og(e,t,n,r){return kg(e,t,n,r,void 0)}function kg(e,t,n,r,i){if(Ft(t)){if(e===void 0){Nu(n,`Expected a value of non-null type "${t}" to be provided.`,i);return}if(e===null){Nu(n,`Expected value of non-null type "${t}" not to be null.`,i);return}return kg(e,t.ofType,n,r,i)}if(e==null)return;if(fn(t))if(!So(e))kg(e,t.ofType,n,r,i);else{let s=0;for(let o of e)kg(o,t.ofType,n,r,hd(i,s++,void 0))}else if(en(t)){if(!jr(e)||Array.isArray(e)){Nu(n,`Expected value of type "${t}" to be an object, found: ${qe(e)}.`,i);return}let s=t.getFields();for(let a of Object.values(s)){let l=e[a.name];if(l===void 0){if(Ao(a))Nu(n,`Expected value of type "${t}" to include required field "${a.name}", found: ${qe(e)}.`,i)}else kg(l,a.type,n,r,hd(i,a.name,t.name))}let o=[];for(let a of Object.keys(e)){if(e[a]===void 0)continue;if(!Object.hasOwn(s,a)){let l=r?"":Oi(Qi(a,Object.keys(s)));Nu(n,`Expected value of type "${t}" not to include unknown field "${a}"${l?`.${l} Found`:", found"}: ${qe(e)}.`,i);continue}o.push(a)}if(t.isOneOf){if(o.length!==1)Nu(n,R0(t),i);let a=o[0];if(e[a]===null)Nu(n,R0(t),hd(i,a,t.name))}}else{va(t);let s,o;try{s=t.coerceInputValue(e,r)}catch(a){if(a instanceof ae){n(a,Eg(i));return}o=a}if(s===void 0)Nu(n,`Expected value of type "${t}"${o!=null?`, but encountered error "${gV(o)}"; found`:", found"}: ${qe(e)}.`,i,dg(o))}}function Nu(e,t,n,r){e(new ae(t,{originalError:r}),Eg(n))}function bd(e,t,n,r,i,s){return Ng({static:!r&&!i,onError:n,variables:r,fragmentVariableValues:i},e,t,s,void 0)}function Ng(e,t,n,r,i){if(t.kind===xs){if(e.static)return;let o=hV(e,t)?.coerced[t.name.value];if(Ft(n)){if(o===void 0)wa(e.onError,`Expected variable "$${t.name.value}" provided to type "${n}" to provide a runtime value.`,t,i);else if(o===null)wa(e.onError,`Expected variable "$${t.name.value}" provided to non-null type "${n}" not to be null.`,t,i)}return}if(Ft(n)){if(t.kind===Cr){wa(e.onError,`Expected value of non-null type "${n}" not to be null.`,t,i);return}return Ng(e,t,n.ofType,r,i)}if(t.kind===Cr)return;if(fn(n))if(t.kind!==ko)Ng(e,t,n.ofType,r,i);else{let s=0;for(let o of t.values)Ng(e,o,n.ofType,r,hd(i,s++,void 0))}else if(en(n)){if(t.kind!==No){wa(e.onError,`Expected value of type "${n}" to be an object, found: ${hn(t)}.`,t,i);return}let s=n.getFields(),o=um(t.fields,(c)=>c.name.value);for(let c of Object.values(s)){let u=o[c.name];if(u===void 0){if(Ao(c))wa(e.onError,`Expected value of type "${n}" to include required field "${c.name}", found: ${hn(t)}.`,t,i)}else{let p=u.value;if(p.kind===xs&&!e.static){let d=hV(e,p),f=p.name.value,m=d?.coerced[f];if(n.isOneOf){if(m===void 0)wa(e.onError,`Expected variable "$${f}" provided to field "${c.name}" for OneOf Input Object type "${n}" to provide a runtime value.`,t,i);else if(m===null)wa(e.onError,`Expected variable "$${f}" provided to field "${c.name}" for OneOf Input Object type "${n}" not to be null.`,t,i)}else if(m===void 0&&!Ao(c))continue}Ng(e,p,c.type,r,hd(i,c.name,n.name))}}let a=t.fields,l=[];for(let c of a){let u=c.name.value;if(!Object.hasOwn(s,u)){let p=r?"":Oi(Qi(u,Object.keys(s)));wa(e.onError,`Expected value of type "${n}" not to include unknown field "${u}"${p?`.${p} Found`:", found"}: ${hn(t)}.`,c,i)}else l.push(c)}if(n.isOneOf){if(l.length!==1){wa(e.onError,R0(n),t,i);return}if(l[0].value.kind===Cr){let p=l[0].name.value;wa(e.onError,R0(n),t,hd(i,p,void 0))}}}else{va(n);let s,o;try{s=n.coerceInputLiteral?n.coerceInputLiteral(ku(t,e.variables,e.fragmentVariableValues),r):n.parseLiteral(t,void 0,r)}catch(a){if(a instanceof ae){e.onError(a,Eg(i));return}o=a}if(s===void 0)wa(e.onError,`Expected value of type "${n}"${o!=null?`, but encountered error "${gV(o)}"; found`:", found"}: ${hn(t)}.`,t,i,dg(o))}}function hV(e,t){let n=t.name.value,{fragmentVariableValues:r,variables:i}=e;return r?.sources[n]?r:i}function wa(e,t,n,r,i){e(new ae(t,{nodes:n,originalError:i}),Eg(r))}function gV(e){if(jr(e)){let t=e.message;if(typeof t==="string"&&t!=="")return t}return String(e)}function R0(e){return`Within OneOf Input Object type "${e}", exactly one field must be specified, and the value for that field must be non-null.`}var et={QUERY:"QUERY",MUTATION:"MUTATION",SUBSCRIPTION:"SUBSCRIPTION",FIELD:"FIELD",FRAGMENT_DEFINITION:"FRAGMENT_DEFINITION",FRAGMENT_SPREAD:"FRAGMENT_SPREAD",INLINE_FRAGMENT:"INLINE_FRAGMENT",VARIABLE_DEFINITION:"VARIABLE_DEFINITION",FRAGMENT_VARIABLE_DEFINITION:"FRAGMENT_VARIABLE_DEFINITION",SCHEMA:"SCHEMA",SCALAR:"SCALAR",OBJECT:"OBJECT",FIELD_DEFINITION:"FIELD_DEFINITION",ARGUMENT_DEFINITION:"ARGUMENT_DEFINITION",INTERFACE:"INTERFACE",UNION:"UNION",ENUM:"ENUM",ENUM_VALUE:"ENUM_VALUE",INPUT_OBJECT:"INPUT_OBJECT",INPUT_FIELD_DEFINITION:"INPUT_FIELD_DEFINITION",DIRECTIVE_DEFINITION:"DIRECTIVE_DEFINITION"};var gm=2147483647,bm=-2147483648,j0=new zs({name:"Int",description:"The `Int` scalar type represents non-fractional signed whole numeric values. Int can represent values between -(2^31) and 2^31 - 1.",coerceOutputValue(e){let t=Pg(e);if(typeof t==="number")return bV(t);if(typeof t==="boolean")return t?1:0;if(typeof t==="string")return Ixe(t);if(typeof t==="bigint")return vV(t);throw new ae(`Int cannot represent non-integer value: ${qe(t)}`)},coerceInputValue(e){if(typeof e==="number")return bV(e);if(typeof e==="bigint")return vV(e);throw new ae(`Int cannot represent non-integer value: ${qe(e)}`)},coerceInputLiteral(e){if(e.kind!==pi)throw new ae(`Int cannot represent non-integer value: ${hn(e)}`,{nodes:e});let t=parseInt(e.value,10);if(t>gm||t=bm)return{kind:pi,value:String(e)}}}),wV=new zs({name:"Float",description:"The `Float` scalar type represents signed double-precision fractional values as specified by [IEEE 754](https://en.wikipedia.org/wiki/IEEE_floating_point).",coerceOutputValue(e){let t=Pg(e);if(typeof t==="number")return _V(t);if(typeof t==="boolean")return t?1:0;if(typeof t==="string")return Axe(t);if(typeof t==="bigint")return xV(t);throw new ae(`Float cannot represent non numeric value: ${qe(t)}`)},coerceInputValue(e){if(typeof e==="number")return _V(e);if(typeof e==="bigint")return xV(e);throw new ae(`Float cannot represent non numeric value: ${qe(e)}`)},coerceInputLiteral(e){if(e.kind!==bu&&e.kind!==pi)throw new ae(`Float cannot represent non numeric value: ${hn(e)}`,{nodes:e});return parseFloat(e.value)},valueToLiteral(e){let t=gd(e);if(t.kind===bu||t.kind===pi)return t}}),Cn=new zs({name:"String",description:"The `String` scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.",coerceOutputValue(e){let t=Pg(e);if(typeof t==="string")return t;if(typeof t==="boolean")return t?"true":"false";if(typeof t==="number")return Rxe(t);if(typeof t==="bigint")return String(t);throw new ae(`String cannot represent value: ${qe(e)}`)},coerceInputValue(e){if(typeof e!=="string")throw new ae(`String cannot represent a non string value: ${qe(e)}`);return e},coerceInputLiteral(e){if(e.kind!==ba)throw new ae(`String cannot represent a non string value: ${hn(e)}`,{nodes:e});return e.value},valueToLiteral(e){let t=gd(e);if(t.kind===ba)return t}}),Er=new zs({name:"Boolean",description:"The `Boolean` scalar type represents `true` or `false`.",coerceOutputValue(e){let t=Pg(e);if(typeof t==="boolean")return t;if(typeof t==="number")return jxe(t);if(typeof t==="bigint")return t!==0n;throw new ae(`Boolean cannot represent a non boolean value: ${qe(t)}`)},coerceInputValue(e){if(typeof e!=="boolean")throw new ae(`Boolean cannot represent a non boolean value: ${qe(e)}`);return e},coerceInputLiteral(e){if(e.kind!==Eo)throw new ae(`Boolean cannot represent a non boolean value: ${hn(e)}`,{nodes:e});return e.value},valueToLiteral(e){let t=gd(e);if(t.kind===Eo)return t}}),F0=new zs({name:"ID",description:'The `ID` scalar type represents a unique identifier, often used to refetch an object or as key for a cache. The ID type appears in a JSON response as a String; however, it is not intended to be human-readable. When expected as an input type, any string (such as `"4"`) or integer (such as `4`) input value will be accepted as an ID.',coerceOutputValue(e){let t=Pg(e);if(typeof t==="string")return t;if(typeof t==="number")return VN(t);if(typeof t==="bigint")return String(t);throw new ae(`ID cannot represent value: ${qe(e)}`)},coerceInputValue(e){if(typeof e==="string")return e;if(typeof e==="number")return VN(e);if(typeof e==="bigint")return String(e);throw new ae(`ID cannot represent value: ${qe(e)}`)},coerceInputLiteral(e){if(e.kind!==ba&&e.kind!==pi)throw new ae("ID cannot represent a non-string and non-integer value: "+hn(e),{nodes:e});return e.value},valueToLiteral(e){if(typeof e==="string")return/^-?(?:0|[1-9][0-9]*)$/.test(e)?{kind:pi,value:e}:{kind:ba,value:e,block:!1};if(typeof e==="number")return{kind:pi,value:VN(e)};if(typeof e==="bigint")return{kind:pi,value:String(e)}}}),Ou=Object.freeze([Cn,j0,wV,Er,F0]);function KN(e){return Ou.some(({name:t})=>e.name===t)}function Pg(e){if(jr(e)){if(typeof e.valueOf==="function"){let t=e.valueOf();if(!jr(t))return t}if(typeof e.toJSON==="function")return e.toJSON()}return e}function bV(e){if(!Number.isInteger(e))throw new ae(`Int cannot represent non-integer value: ${qe(e)}`);if(e>gm||egm||tgm||enew Tg(this,n,r))}get[Symbol.toStringTag](){return"GraphQLDirective"}toConfig(){return{name:this.name,description:this.description,locations:this.locations,args:pd(this.args,(e)=>e.name,(e)=>e.toConfig()),isRepeatable:this.isRepeatable,deprecationReason:this.deprecationReason,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return"@"+this.name}toJSON(){return this.toString()}}var vd=new Pi({name:"include",description:"Directs the executor to include this field or fragment only when the `if` argument is true.",locations:[et.FIELD,et.FRAGMENT_SPREAD,et.INLINE_FRAGMENT],args:{if:{type:new dt(Er),description:"Included when true."}}}),_d=new Pi({name:"skip",description:"Directs the executor to skip this field or fragment when the `if` argument is true.",locations:[et.FIELD,et.FRAGMENT_SPREAD,et.INLINE_FRAGMENT],args:{if:{type:new dt(Er),description:"Skipped when true."}}}),tc=new Pi({name:"defer",description:"Directs the executor to defer this fragment when the `if` argument is true or undefined.",locations:[et.FRAGMENT_SPREAD,et.INLINE_FRAGMENT],args:{if:{type:new dt(Er),description:"Deferred when true or undefined.",default:{value:!0}},label:{type:Cn,description:"Unique name"}}}),nc=new Pi({name:"stream",description:"Directs the executor to stream plural fields when the `if` argument is true or undefined.",locations:[et.FIELD],args:{initialCount:{default:{value:0},type:new dt(j0),description:"Number of items to return immediately"},if:{type:new dt(Er),description:"Stream when true or undefined.",default:{value:!0}},label:{type:Cn,description:"Unique name"}}}),TV="No longer supported",vm=new Pi({name:"deprecated",description:"Marks an element of a GraphQL schema as no longer supported.",locations:[et.FIELD_DEFINITION,et.ARGUMENT_DEFINITION,et.INPUT_FIELD_DEFINITION,et.ENUM_VALUE,et.DIRECTIVE_DEFINITION],args:{reason:{type:new dt(Cn),description:"Explains why this element was deprecated, usually also including a suggestion for how to access supported similar data. Formatted using the Markdown syntax, as specified by [CommonMark](https://commonmark.org/).",default:{value:TV}}}}),C0=new Pi({name:"specifiedBy",description:"Exposes a URL that specifies the behavior of this scalar.",locations:[et.SCALAR],args:{url:{type:new dt(Cn),description:"The URL that specifies the behavior of this scalar."}}}),M0=new Pi({name:"oneOf",description:"Indicates exactly one field must be supplied and this field must not be `null`.",locations:[et.INPUT_OBJECT],args:{}}),ZYe=new Pi({name:"experimental_disableErrorPropagation",description:"Disables error propagation.",locations:[et.QUERY,et.MUTATION,et.SUBSCRIPTION]}),Ts=Object.freeze([vd,_d,vm,C0,M0]);function JN(e){return Ts.some(({name:t})=>t===e.name)}function xd(e,t){if(Ft(t)){let n=xd(e,t.ofType);if(n?.kind===Cr)return null;return n}if(e===null)return{kind:Cr};if(e===void 0)return null;if(fn(t)){let n=t.ofType;if(So(e)){let r=[];for(let i of e){let s=xd(i,n);if(s!=null)r.push(s)}return{kind:ko,values:r}}return xd(e,n)}if(en(t)){if(!jr(e))return null;let n=[];for(let r of Object.values(t.getFields())){let i=xd(e[r.name],r.type);if(i)n.push({kind:bg,name:{kind:hg,value:r.name},value:i})}return{kind:No,fields:n}}if(Xl(t)){let n=t.coerceOutputValue(e);if(n==null)return null;if(typeof n==="boolean")return{kind:Eo,value:n};if(typeof n==="number"&&Number.isFinite(n)){let r=String(n);return SV.test(r)?{kind:pi,value:r}:{kind:bu,value:r}}if(typeof n==="bigint")return{kind:pi,value:String(n)};if(typeof n==="string"){if(Mr(t))return{kind:rd,value:n};if(t===F0&&SV.test(n))return{kind:pi,value:n};return{kind:ba,value:n}}throw TypeError(`Cannot convert value to AST: ${qe(n)}.`)}cn(!1,"Unexpected input type: "+qe(t))}var SV=/^-?(?:0|[1-9][0-9]*)$/;function EV(e){let{type:t,default:n}=e;if(n){let i=n.literal??ec(n.value,t);if(i==null)cn(!1,"Invalid default value");return i}let r=e.defaultValue;if(r!==void 0){let i=xd(r,t);if(i==null)cn(!1,"Invalid default value");return i}return}var Ig=new Ds({name:"__Schema",description:"A GraphQL Schema defines the capabilities of a GraphQL server. It exposes all available types and directives on the server, as well as the entry points for query, mutation, and subscription operations.",fields:()=>({description:{type:Cn,resolve:(e)=>e.description},types:{description:"A list of all types supported by this server.",type:new dt(new Sr(new dt(Ro))),resolve(e){return Object.values(e.getTypeMap())}},queryType:{description:"The type that query operations will be rooted at.",type:new dt(Ro),resolve:(e)=>e.getQueryType()},mutationType:{description:"If this server supports mutation, the type that mutation operations will be rooted at.",type:Ro,resolve:(e)=>e.getMutationType()},subscriptionType:{description:"If this server support subscription, the type that subscription operations will be rooted at.",type:Ro,resolve:(e)=>e.getSubscriptionType()},directives:{description:"A list of all directives supported by this server.",type:new dt(new Sr(new dt(GN))),args:{includeDeprecated:{type:new dt(Er),default:{value:!1}}},resolve:(e,{includeDeprecated:t})=>t===!0?e.getDirectives():e.getDirectives().filter((n)=>n.deprecationReason==null)}})}),GN=new Ds({name:"__Directive",description:`A Directive provides a way to describe alternate runtime execution and type validation behavior in a GraphQL document. -In some cases, you need to provide options to alter GraphQL's execution behavior in ways field arguments will not suffice, such as conditionally including or skipping a field. Directives provide this by describing additional information to the executor.`,fields:()=>({name:{type:new dt(Cn),resolve:(e)=>e.name},description:{type:Cn,resolve:(e)=>e.description},isRepeatable:{type:new dt(Sr),resolve:(e)=>e.isRepeatable},locations:{type:new dt(new Tr(new dt(HN))),resolve:(e)=>e.locations},args:{type:new dt(new Tr(new dt(Ag))),args:{includeDeprecated:{type:new dt(Sr),default:{value:!1}}},resolve(e,{includeDeprecated:t}){return t===!0?e.args:e.args.filter((n)=>n.deprecationReason==null)}},isDeprecated:{type:new dt(Sr),resolve:(e)=>e.deprecationReason!=null},deprecationReason:{type:Cn,resolve:(e)=>e.deprecationReason}})}),HN=new rl({name:"__DirectiveLocation",description:"A Directive can be adjacent to many parts of the GraphQL language, a __DirectiveLocation describes one such possible adjacencies.",values:{QUERY:{value:et.QUERY,description:"Location adjacent to a query operation."},MUTATION:{value:et.MUTATION,description:"Location adjacent to a mutation operation."},SUBSCRIPTION:{value:et.SUBSCRIPTION,description:"Location adjacent to a subscription operation."},FIELD:{value:et.FIELD,description:"Location adjacent to a field."},FRAGMENT_DEFINITION:{value:et.FRAGMENT_DEFINITION,description:"Location adjacent to a fragment definition."},FRAGMENT_SPREAD:{value:et.FRAGMENT_SPREAD,description:"Location adjacent to a fragment spread."},INLINE_FRAGMENT:{value:et.INLINE_FRAGMENT,description:"Location adjacent to an inline fragment."},VARIABLE_DEFINITION:{value:et.VARIABLE_DEFINITION,description:"Location adjacent to an operation variable definition."},FRAGMENT_VARIABLE_DEFINITION:{value:et.FRAGMENT_VARIABLE_DEFINITION,description:"Location adjacent to a fragment variable definition."},SCHEMA:{value:et.SCHEMA,description:"Location adjacent to a schema definition."},SCALAR:{value:et.SCALAR,description:"Location adjacent to a scalar definition."},OBJECT:{value:et.OBJECT,description:"Location adjacent to an object type definition."},FIELD_DEFINITION:{value:et.FIELD_DEFINITION,description:"Location adjacent to a field definition."},ARGUMENT_DEFINITION:{value:et.ARGUMENT_DEFINITION,description:"Location adjacent to an argument definition."},INTERFACE:{value:et.INTERFACE,description:"Location adjacent to an interface definition."},UNION:{value:et.UNION,description:"Location adjacent to a union definition."},ENUM:{value:et.ENUM,description:"Location adjacent to an enum definition."},ENUM_VALUE:{value:et.ENUM_VALUE,description:"Location adjacent to an enum value definition."},INPUT_OBJECT:{value:et.INPUT_OBJECT,description:"Location adjacent to an input object type definition."},INPUT_FIELD_DEFINITION:{value:et.INPUT_FIELD_DEFINITION,description:"Location adjacent to an input object field definition."},DIRECTIVE_DEFINITION:{value:et.DIRECTIVE_DEFINITION,description:"Location adjacent to a directive definition."}}}),Ro=new ws({name:"__Type",description:"The fundamental unit of any GraphQL Schema is the type. There are many kinds of types in GraphQL as represented by the `__TypeKind` enum.\n\nDepending on the kind of a type, certain fields describe information about that type. Scalar types provide no information beyond a name, description and optional `specifiedByURL`, while Enum types provide their values. Object and Interface types provide the fields they describe. Abstract types, Union and Interface, provide the Object types possible at runtime. List and NonNull types compose other types.",fields:()=>({kind:{type:new dt(QN),resolve(e){if($o(e))return pi.SCALAR;if(Dn(e))return pi.OBJECT;if(dn(e))return pi.INTERFACE;if(Wr(e))return pi.UNION;if(Cr(e))return pi.ENUM;if(en(e))return pi.INPUT_OBJECT;if(fn(e))return pi.LIST;if(Ft(e))return pi.NON_NULL;cn(!1,`Unexpected type: "${qe(e)}".`)}},name:{type:Cn,resolve:(e)=>("name"in e)?e.name:void 0},description:{type:Cn,resolve:(e)=>("description"in e)?e.description:void 0},specifiedByURL:{type:Cn,resolve:(e)=>("specifiedByURL"in e)?e.specifiedByURL:void 0},fields:{type:new Tr(new dt(zN)),args:{includeDeprecated:{type:new dt(Sr),default:{value:!1}}},resolve(e,{includeDeprecated:t}){if(Dn(e)||dn(e)){let n=Object.values(e.getFields());return t===!0?n:n.filter((r)=>r.deprecationReason==null)}}},interfaces:{type:new Tr(new dt(Ro)),resolve(e){if(Dn(e)||dn(e))return e.getInterfaces()}},possibleTypes:{type:new Tr(new dt(Ro)),resolve(e,t,n,{schema:r}){if(Io(e))return r.getPossibleTypes(e)}},enumValues:{type:new Tr(new dt(WN)),args:{includeDeprecated:{type:new dt(Sr),default:{value:!1}}},resolve(e,{includeDeprecated:t}){if(Cr(e)){let n=e.getValues();return t===!0?n:n.filter((r)=>r.deprecationReason==null)}}},inputFields:{type:new Tr(new dt(Ag)),args:{includeDeprecated:{type:new dt(Sr),default:{value:!1}}},resolve(e,{includeDeprecated:t}){if(en(e)){let n=Object.values(e.getFields());return t===!0?n:n.filter((r)=>r.deprecationReason==null)}}},ofType:{type:Ro,resolve:(e)=>("ofType"in e)?e.ofType:void 0},isOneOf:{type:Sr,resolve:(e)=>{if(en(e))return e.isOneOf}}})}),zN=new ws({name:"__Field",description:"Object and Interface types are described by a list of Fields, each of which has a name, potentially a list of arguments, and a return type.",fields:()=>({name:{type:new dt(Cn),resolve:(e)=>e.name},description:{type:Cn,resolve:(e)=>e.description},args:{type:new dt(new Tr(new dt(Ag))),args:{includeDeprecated:{type:new dt(Sr),default:{value:!1}}},resolve(e,{includeDeprecated:t}){return t===!0?e.args:e.args.filter((n)=>n.deprecationReason==null)}},type:{type:new dt(Ro),resolve:(e)=>e.type},isDeprecated:{type:new dt(Sr),resolve:(e)=>e.deprecationReason!=null},deprecationReason:{type:Cn,resolve:(e)=>e.deprecationReason}})}),Ag=new ws({name:"__InputValue",description:"Arguments provided to Fields or Directives and the input fields of an InputObject are represented as Input Values which describe their type and optionally a default value.",fields:()=>({name:{type:new dt(Cn),resolve:(e)=>e.name},description:{type:Cn,resolve:(e)=>e.description},type:{type:new dt(Ro),resolve:(e)=>e.type},defaultValue:{type:Cn,description:"A GraphQL-formatted string representing the default value for this input value.",resolve(e){let t=EV(e);if(t)return hn(t);return null}},isDeprecated:{type:new dt(Sr),resolve:(e)=>e.deprecationReason!=null},deprecationReason:{type:Cn,resolve:(e)=>e.deprecationReason}})}),WN=new ws({name:"__EnumValue",description:"One possible value for a given Enum. Enum values are unique values, not a placeholder for a string or numeric value. However an Enum value is returned in a JSON response as a string.",fields:()=>({name:{type:new dt(Cn),resolve:(e)=>e.name},description:{type:Cn,resolve:(e)=>e.description},isDeprecated:{type:new dt(Sr),resolve:(e)=>e.deprecationReason!=null},deprecationReason:{type:Cn,resolve:(e)=>e.deprecationReason}})}),pi={SCALAR:"SCALAR",OBJECT:"OBJECT",INTERFACE:"INTERFACE",UNION:"UNION",ENUM:"ENUM",INPUT_OBJECT:"INPUT_OBJECT",LIST:"LIST",NON_NULL:"NON_NULL"},QN=new rl({name:"__TypeKind",description:"An enum describing what kind of type a given `__Type` is.",values:{SCALAR:{value:pi.SCALAR,description:"Indicates this type is a scalar."},OBJECT:{value:pi.OBJECT,description:"Indicates this type is an object. `fields` and `interfaces` are valid fields."},INTERFACE:{value:pi.INTERFACE,description:"Indicates this type is an interface. `fields`, `interfaces`, and `possibleTypes` are valid fields."},UNION:{value:pi.UNION,description:"Indicates this type is a union. `possibleTypes` is a valid field."},ENUM:{value:pi.ENUM,description:"Indicates this type is an enum. `enumValues` is a valid field."},INPUT_OBJECT:{value:pi.INPUT_OBJECT,description:"Indicates this type is an input object. `inputFields` is a valid field."},LIST:{value:pi.LIST,description:"Indicates this type is a list. `ofType` is a valid field."},NON_NULL:{value:pi.NON_NULL,description:"Indicates this type is a non-null. `ofType` is a valid field."}}}),L0=new mm(void 0,"__schema",{type:new dt(Ig),description:"Access the current type schema of this server.",resolve:(e,t,n,{schema:r})=>r}),q0=new mm(void 0,"__type",{type:Ro,description:"Request the type information of a single type.",args:{name:{type:new dt(Cn)}},resolve:(e,{name:t},n,{schema:r})=>r.getType(t)}),U0=new mm(void 0,"__typename",{type:new dt(Cn),description:"The name of the current Object type at runtime.",resolve:(e,t,n,{parentType:r})=>r.name}),Ou=Object.freeze([Ig,GN,HN,Ro,zN,Ag,WN,QN]);function Rg(e){return Ou.some(({name:t})=>e.name===t)}function kV(e){return ci(e,NV,jg)}function YN(e){if(!kV(e))throw Error(`Expected ${qe(e)} to be a GraphQL schema.`);return e}var NV=Symbol("Schema");class jg{constructor(e){this.__kind=NV,this.assumeValid=e.assumeValid??!1,this.__validationErrors=e.assumeValid===!0?[]:void 0,this.description=e.description,this.extensions=Qi(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=e.extensionASTNodes??[],this._queryType=e.query,this._mutationType=e.mutation,this._subscriptionType=e.subscription,this._directives=e.directives??Ds;let t=new Set(e.types);if(e.types!=null)for(let n of e.types)t.delete(n),Da(n,t);if(this._queryType!=null)Da(this._queryType,t);if(this._mutationType!=null)Da(this._mutationType,t);if(this._subscriptionType!=null)Da(this._subscriptionType,t);for(let n of this._directives)if($g(n))for(let r of n.args)Da(r.type,t);Da(Ig,t),this._typeMap=Object.create(null),this._subTypeMap=new Map,this._implementationsMap=Object.create(null);for(let n of t){if(n==null)continue;let r=n.name;if(this._typeMap[r]!==void 0)throw Error(`Schema must contain uniquely named types but contains multiple types named "${r}".`);if(this._typeMap[r]=n,dn(n)){for(let i of n.getInterfaces())if(dn(i)){let s=this._implementationsMap[i.name];s??=this._implementationsMap[i.name]={objects:[],interfaces:[]},s.interfaces.push(n)}}else if(Dn(n)){for(let i of n.getInterfaces())if(dn(i)){let s=this._implementationsMap[i.name];s??=this._implementationsMap[i.name]={objects:[],interfaces:[]},s.objects.push(n)}}}}get[Symbol.toStringTag](){return"GraphQLSchema"}getQueryType(){return this._queryType}getMutationType(){return this._mutationType}getSubscriptionType(){return this._subscriptionType}getRootType(e){switch(e){case jr.QUERY:return this.getQueryType();case jr.MUTATION:return this.getMutationType();case jr.SUBSCRIPTION:return this.getSubscriptionType()}}getTypeMap(){return this._typeMap}getType(e){return this.getTypeMap()[e]}getPossibleTypes(e){return Wr(e)?e.getTypes():this.getImplementations(e).objects}getImplementations(e){return this._implementationsMap[e.name]??{objects:[],interfaces:[]}}isSubType(e,t){let n=this._subTypeMap.get(e);if(n===void 0){if(Wr(e))n=new Set(e.getTypes());else{let r=this.getImplementations(e);n=new Set([...r.objects,...r.interfaces])}this._subTypeMap.set(e,n)}return n.has(t)}getDirectives(){return this._directives}getDirective(e){return this.getDirectives().find((t)=>t.name===e)}getField(e,t){switch(t){case L0.name:return this.getQueryType()===e?L0:void 0;case q0.name:return this.getQueryType()===e?q0:void 0;case U0.name:return U0}if("getFields"in e)return e.getFields()[t];return}toConfig(){return{description:this.description,query:this.getQueryType(),mutation:this.getMutationType(),subscription:this.getSubscriptionType(),types:Object.values(this.getTypeMap()),directives:this.getDirectives(),extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes,assumeValid:this.assumeValid}}}function Da(e,t){let n=_a(e);if(!t.has(n)){if(t.add(n),Wr(n))for(let r of n.getTypes())Da(r,t);else if(Dn(n)||dn(n)){for(let r of n.getInterfaces())Da(r,t);for(let r of Object.values(n.getFields())){Da(r.type,t);for(let i of r.args)Da(i.type,t)}}else if(en(n))for(let r of Object.values(n.getFields()))Da(r.type,t)}return t}function B0(e){if(YN(e),e.__validationErrors)return e.__validationErrors;let t=new AV(e);jxe(t),Fxe(t),Cxe(t);let n=t.getErrors();return e.__validationErrors=n,n}class AV{constructor(e){this._errors=[],this.schema=e}reportError(e,t){let n=Array.isArray(t)?t.filter(Boolean):t;this._errors.push(new ae(e,{nodes:n}))}getErrors(){return this._errors}}function jxe(e){let t=e.schema;if(t.getQueryType()==null)e.reportError("Query root type must be provided.",t.astNode);let n=new zi;for(let r of Object.values(jr)){let i=t.getRootType(r);if(i!=null)if(!Dn(i)){let s=F8(r),o=qe(i);e.reportError(r===jr.QUERY?`${s} root type must be Object type, it cannot be ${o}.`:`${s} root type must be Object type if provided, it cannot be ${o}.`,OV(t,r)??i.astNode)}else n.add(i,r)}for(let[r,i]of n)if(i.length>1){let s=M8(i);e.reportError(`All root types must be different, "${r}" type is used as ${s} root types.`,i.map((o)=>OV(t,o)))}}function OV(e,t){return[e.astNode,...e.extensionASTNodes].flatMap((n)=>n?.operationTypes??[]).find((n)=>n.operation===t)?.type}function Fxe(e){for(let t of e.schema.getDirectives()){if(!$g(t)){e.reportError(`Expected directive but got: ${qe(t)}.`,t?.astNode);continue}if(_d(e,t),t.locations.length===0)e.reportError(`Directive ${t} must include 1 or more locations.`,t.astNode);for(let n of t.args){if(_d(e,n),!Tu(n.type))e.reportError(`The type of ${n} must be Input Type but got: ${qe(n.type)}.`,n.astNode);if(xa(n)&&n.deprecationReason!=null)e.reportError(`Required argument ${n} cannot be deprecated.`,[V0(n.astNode),n.astNode?.type]);XN(e,n)}}}function XN(e,t){let n=t.default;if(!n)return;let r=[];if(ZN(n,t.type,(i,s)=>{r.push([i,s])}),r.length===0)return;if(!n.literal)try{let i=Fg(n.value,t.type),s=[];if(Og(i,t.type,(o,a)=>{s.push([o,a])}),s.length===0){e.reportError(`${t} has invalid default value: ${qe(n.value)}. Did you mean: ${qe(i)}?`,t.astNode?.defaultValue);return}}catch(i){}for(let[i,s]of r)e.reportError(`${t} has invalid default value${fg(s)}: ${i.message}`,i.nodes??t.astNode?.defaultValue)}function ZN(e,t,n,r){if(e.literal){hd(e.literal,t,n,void 0,void 0,r);return}Og(e.value,t,n,r)}function Fg(e,t){if(Ft(t))return Fg(e,t.ofType);if(e===null)return null;if(fn(t)){if(So(e))return Array.from(e,(n)=>Fg(n,t.ofType));return[Fg(e,t.ofType)]}if(en(t)){if(!Rr(e))cn(!1);let n=t.getFields();return tl(e,(r,i)=>{if(!(i in n))cn(!1);return Fg(r,n[i].type)})}return va(t),t.coerceOutputValue(e)}function _d(e,t){if(t.name.startsWith("__"))e.reportError(`Name "${t.name}" must not begin with "__", which is reserved by GraphQL introspection.`,t.astNode)}function Cxe(e){let t=Gxe(e),n=e.schema.getTypeMap(),r=new Map;for(let s of Object.values(n)){if(!UN(s)){e.reportError(`Expected GraphQL named type but got: ${qe(s)}.`,s.astNode);continue}if(!Rg(s))_d(e,s);if(Dn(s))PV(e,s),$V(e,s);else if(dn(s))PV(e,s),$V(e,s);else if(Wr(s))qxe(e,s);else if(Cr(s))Uxe(e,s);else if(en(s))Bxe(e,s),i(s),t(s)}Kxe(e,r);function i(s){r.set(s,{inputObj:s,targets:[],dependents:[],unresolvedTargetCount:0,hasFiniteValue:!1})}}function PV(e,t){let n=Object.values(t.getFields());if(n.length===0)e.reportError(`Type ${t} must define one or more fields.`,[t.astNode,...t.extensionASTNodes]);for(let r of n){if(_d(e,r),!$0(r.type))e.reportError(`The type of ${r} must be Output Type but got: ${qe(r.type)}.`,r.astNode?.type);for(let i of r.args){if(_d(e,i),!Tu(i.type))e.reportError(`The type of ${i} must be Input Type but got: ${qe(i.type)}.`,i.astNode?.type);if(xa(i)&&i.deprecationReason!=null)e.reportError(`Required argument ${i} cannot be deprecated.`,[V0(i.astNode),i.astNode?.type]);XN(e,i)}}}function $V(e,t){let n=new Set;for(let r of t.getInterfaces()){if(!dn(r)){e.reportError(`Type ${t} must only implement Interface types, it cannot implement ${qe(r)}.`,Cg(t,r));continue}if(t===r){e.reportError(`Type ${t} cannot implement itself because it would create a circular reference.`,Cg(t,r));continue}if(n.has(r.name)){e.reportError(`Type ${t} can only implement ${r} once.`,Cg(t,r));continue}n.add(r.name),Lxe(e,t,r),Mxe(e,t,r)}}function Mxe(e,t,n){let r=t.getFields();for(let i of Object.values(n.getFields())){let s=r[i.name];if(s==null){e.reportError(`Interface field ${i} expected but ${t} does not provide it.`,[i.astNode,t.astNode,...t.extensionASTNodes]);continue}if(!Zl(e.schema,s.type,i.type))e.reportError(`Interface field ${i} expects type ${i.type} but ${s} is type ${s.type}.`,[i.astNode?.type,s.astNode?.type]);for(let o of i.args){let a=s.args.find((l)=>l.name===o.name);if(!a){e.reportError(`Interface field argument ${o} expected but ${s} does not provide it.`,[o.astNode,s.astNode]);continue}if(!Sg(o.type,a.type))e.reportError(`Interface field argument ${o} expects type ${o.type} but ${a} is type ${a.type}.`,[o.astNode?.type,a.astNode?.type])}for(let o of s.args)if(xa(o)){if(!i.args.find((l)=>l.name===o.name))e.reportError(`Argument "${o}" must not be required type "${o.type}" if not provided by the Interface field "${i}".`,[o.astNode,i.astNode])}if(s.deprecationReason!=null&&i.deprecationReason==null)e.reportError(`Interface field ${n.name}.${i.name} is not deprecated, so implementation field ${t.name}.${s.name} must not be deprecated.`,[V0(s.astNode),s.astNode?.type])}}function Lxe(e,t,n){let r=t.getInterfaces();for(let i of n.getInterfaces())if(!r.includes(i))e.reportError(i===t?`Type ${t} cannot implement ${n} because it would create a circular reference.`:`Type ${t} must implement ${i} because it is implemented by ${n}.`,[...Cg(n,i),...Cg(t,n)])}function qxe(e,t){let n=t.getTypes();if(n.length===0)e.reportError(`Union type ${t} must define one or more member types.`,[t.astNode,...t.extensionASTNodes]);let r=new Set;for(let i of n){if(r.has(i.name)){e.reportError(`Union type ${t} can only include type ${i} once.`,IV(t,i.name));continue}if(r.add(i.name),!Dn(i))e.reportError(`Union type ${t} can only include Object types, it cannot include ${qe(i)}.`,IV(t,String(i)))}}function Uxe(e,t){let n=t.getValues();if(n.length===0)e.reportError(`Enum type ${t} must define one or more values.`,[t.astNode,...t.extensionASTNodes]);for(let r of n)_d(e,r)}function Bxe(e,t){let n=Object.values(t.getFields());if(n.length===0)e.reportError(`Input Object type ${t} must define one or more fields.`,[t.astNode,...t.extensionASTNodes]);for(let r of n){if(_d(e,r),!Tu(r.type))e.reportError(`The type of ${r} must be Input Type but got: ${qe(r.type)}.`,r.astNode?.type);if(Ao(r)&&r.deprecationReason!=null)e.reportError(`Required input field ${r} cannot be deprecated.`,[V0(r.astNode),r.astNode?.type]);if(XN(e,r),t.isOneOf)Vxe(t,r,e)}}function Vxe(e,t,n){if(Ft(t.type))n.reportError(`OneOf input field ${e}.${t.name} must be nullable.`,t.astNode?.type);if(t.default!==void 0||t.defaultValue!==void 0)n.reportError(`OneOf input field ${e}.${t.name} cannot have a default value.`,t.astNode)}function Kxe(e,t){let n=[];for(let c of t.values()){let u=c.inputObj,p=Object.values(u.getFields());for(let d of p){let f=Jxe(u,d.type);if(f===void 0)continue;c.targets.push({field:d,target:f});let m=t.get(f);if(m!==void 0)m.dependents.push(c)}if(u.isOneOf){if(p.length===0||c.targets.lengthb.fieldStr).join(", ");e.reportError(`Input Object ${d} cannot be provided a finite value because it references itself through fields: ${h}.`,y.map((b)=>b.astNode))}s.pop()}o.delete(u)}}function Jxe(e,t){if(e.isOneOf){if(en(t))return t;return}if(Ft(t)&&en(t.ofType))return t.ofType}function Gxe(e){let t=Object.create(null),n=[],r=Object.create(null);return function(l){return i(l,Object.create(null))};function i(a,l){if(So(l)){for(let c of l)i(a,c);return}else if(!Rr(l))return;for(let c of Object.values(a.getFields())){let u=_a(c.type);if(!en(u))continue;if(Object.hasOwn(l,c.name))i(u,l[c.name]);else o(c,u,`${a}.${c.name}`)}}function s(a,l){if(l.kind===ko){for(let u of l.values)s(a,u);return}else if(l.kind!==No)return;let c=lm(l.fields,(u)=>u.name.value);for(let u of Object.values(a.getFields())){let p=_a(u.type);if(!en(p))continue;if(Object.hasOwn(c,u.name))s(p,c[u.name].value);else o(u,p,`${a}.${u.name}`)}}function o(a,l,c){let u=a.default;if(u===void 0)return;let p=r[c];if(p!==void 0){e.reportError(`Invalid circular reference. The default value of Input Object field ${c} references itself${pd).join(", ")}`:""}.`,n.slice(p-1).map(([,d])=>d));return}if(t[c]===void 0){if(t[c]=!0,r[c]=n.push([c,a.astNode?.defaultValue]),u.literal)s(l,u.literal);else i(l,u.value);n.pop(),r[c]=void 0}}}function Cg(e,t){let{astNode:n,extensionASTNodes:r}=e;return(n!=null?[n,...r]:r).flatMap((s)=>s.interfaces??[]).filter((s)=>s.name.value===t.name)}function IV(e,t){let{astNode:n,extensionASTNodes:r}=e;return(n!=null?[n,...r]:r).flatMap((s)=>s.types??[]).filter((s)=>s.name.value===t)}function V0(e){return e?.directives?.find((t)=>t.name.value===gm.name)}function tr(e,t,n){return new ae(`Syntax Error: ${n}`,{source:e,positions:[t]})}function Hxe(){let e;try{let t=globalThis.process;if(typeof t?.getBuiltinModule==="function")e=t.getBuiltinModule("node:diagnostics_channel")}catch{}return e}var xd=Hxe(),eO=xd?.tracingChannel("graphql:parse"),WXe=xd?.tracingChannel("graphql:validate"),QXe=xd?.tracingChannel("graphql:execute"),YXe=xd?.tracingChannel("graphql:execute:variableCoercion"),XXe=xd?.tracingChannel("graphql:execute:rootSelectionSet"),ZXe=xd?.tracingChannel("graphql:subscribe"),eZe=xd?.tracingChannel("graphql:resolve"),zxe=["start","end","asyncStart","asyncEnd","error"];function RV(e){if(e==null)return!1;let t=e.hasSubscribers;if(t!==void 0)return t;for(let n of zxe)if(e[n].hasSubscribers)return!0;return!1}var we={SOF:"",EOF:"",BANG:"!",DOLLAR:"$",AMP:"&",PAREN_L:"(",PAREN_R:")",DOT:".",SPREAD:"...",COLON:":",EQUALS:"=",AT:"@",BRACKET_L:"[",BRACKET_R:"]",BRACE_L:"{",PIPE:"|",BRACE_R:"}",NAME:"Name",INT:"Int",FLOAT:"Float",STRING:"String",BLOCK_STRING:"BlockString",COMMENT:"Comment"};class J0{constructor(e){let t=new mg(we.SOF,0,0,0,0);this.source=e,this.lastToken=t,this.token=t,this.line=1,this.lineStart=0}get[Symbol.toStringTag](){return"Lexer"}advance(){return this.lastToken=this.token,this.token=this.lookahead()}lookahead(){let e=this.token;if(e.kind!==we.EOF)do if(e.next)e=e.next;else{let t=Wxe(this,e.end);e.next=t,t.prev=e,e=t}while(e.kind===we.COMMENT);return e}}function FV(e){return e===we.BANG||e===we.DOLLAR||e===we.AMP||e===we.PAREN_L||e===we.PAREN_R||e===we.DOT||e===we.SPREAD||e===we.COLON||e===we.EQUALS||e===we.AT||e===we.BRACKET_L||e===we.BRACKET_R||e===we.BRACE_L||e===we.PIPE||e===we.BRACE_R}function bm(e){return e>=0&&e<=55295||e>=57344&&e<=1114111}function G0(e,t){return CV(e.charCodeAt(t))&&MV(e.charCodeAt(t+1))}function CV(e){return e>=55296&&e<=56319}function MV(e){return e>=56320&&e<=57343}function wd(e,t){let n=e.source.body.codePointAt(t);if(n===void 0)return we.EOF;else if(n>=32&&n<=126){let r=String.fromCodePoint(n);return r==='"'?`'"'`:`"${r}"`}return"U+"+n.toString(16).toUpperCase().padStart(4,"0")}function Er(e,t,n,r,i){let s=e.line,o=1+n-e.lineStart;return new mg(t,n,r,s,o,i)}function Wxe(e,t){let n=e.source.body,r=n.length,i=t;while(i=48&&e<=57?e-48:e>=65&&e<=70?e-55:e>=97&&e<=102?e-87:-1}function t0e(e,t){let n=e.source.body;switch(n.charCodeAt(t+1)){case 34:return{value:'"',size:2};case 92:return{value:"\\",size:2};case 47:return{value:"/",size:2};case 98:return{value:"\b",size:2};case 102:return{value:"\f",size:2};case 110:return{value:` -`,size:2};case 114:return{value:"\r",size:2};case 116:return{value:"\t",size:2}}throw tr(e.source,t,`Invalid character escape sequence: "${n.slice(t,t+2)}".`)}function n0e(e,t){let n=e.source.body,r=n.length,i=e.lineStart,s=t+3,o=s,a="",l=[];while(s0))Oo(!1,"line in locationOffset is 1-indexed and must be positive.");if(!(this.locationOffset.column>0))Oo(!1,"column in locationOffset is 1-indexed and must be positive.")}get[Symbol.toStringTag](){return"Source"}}function qV(e){return ci(e,LV,Lg)}function z0(e,t){return RV(eO)?eO.traceSync(()=>UV(e,t),{source:e}):UV(e,t)}function UV(e,t){let n=new BV(e,t),r=n.parseDocument();return Object.defineProperty(r,"tokenCount",{enumerable:!1,value:n.tokenCount}),r}class BV{constructor(e,t={}){let{lexer:n,...r}=t;if(n)this._lexer=n;else{let i=qV(e)?e:new Lg(e);this._lexer=new J0(i)}this._options=r,this._tokenCounter=0}get tokenCount(){return this._tokenCounter}parseName(){let e=this.expectToken(we.NAME);return this.node(e,{kind:hg,value:e.value})}parseDocument(){return this.node(this._lexer.token,{kind:q8,definitions:this.many(we.SOF,this.parseDefinition,we.EOF)})}parseDefinition(){if(this.peek(we.BRACE_L))return this.parseOperationDefinition();let e=this.peekDescription(),t=e?this._lexer.lookahead():this._lexer.token;if(e&&t.kind===we.BRACE_L)throw tr(this._lexer.source,this._lexer.token.start,"Unexpected description, descriptions are not supported on shorthand queries.");if(t.kind===we.NAME){switch(t.value){case"schema":return this.parseSchemaDefinition();case"scalar":return this.parseScalarTypeDefinition();case"type":return this.parseObjectTypeDefinition();case"interface":return this.parseInterfaceTypeDefinition();case"union":return this.parseUnionTypeDefinition();case"enum":return this.parseEnumTypeDefinition();case"input":return this.parseInputObjectTypeDefinition();case"directive":return this.parseDirectiveDefinition()}switch(t.value){case"query":case"mutation":case"subscription":return this.parseOperationDefinition();case"fragment":return this.parseFragmentDefinition()}if(e)throw tr(this._lexer.source,this._lexer.token.start,"Unexpected description, only GraphQL definitions support descriptions.");switch(t.value){case"extend":return this.parseTypeSystemExtension()}}throw this.unexpected(t)}parseOperationDefinition(){let e=this._lexer.token;if(this.peek(we.BRACE_L))return this.node(e,{kind:ed,operation:jr.QUERY,description:void 0,name:void 0,variableDefinitions:void 0,directives:void 0,selectionSet:this.parseSelectionSet()});let t=this.parseDescription(),n=this.parseOperationType(),r;if(this.peek(we.NAME))r=this.parseName();return this.node(e,{kind:ed,operation:n,description:t,name:r,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseOperationType(){let e=this.expectToken(we.NAME);switch(e.value){case"query":return jr.QUERY;case"mutation":return jr.MUTATION;case"subscription":return jr.SUBSCRIPTION}throw this.unexpected(e)}parseVariableDefinitions(){return this.optionalMany(we.PAREN_L,this.parseVariableDefinition,we.PAREN_R)}parseVariableDefinition(){return this.node(this._lexer.token,{kind:EN,description:this.parseDescription(),variable:this.parseVariable(),type:(this.expectToken(we.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(we.EQUALS)?this.parseConstValueLiteral():void 0,directives:this.parseConstDirectives()})}parseVariable(){let e=this._lexer.token;return this.expectToken(we.DOLLAR),this.node(e,{kind:_s,name:this.parseName()})}parseSelectionSet(){return this.node(this._lexer.token,{kind:U8,selections:this.many(we.BRACE_L,this.parseSelection,we.BRACE_R)})}parseSelection(){return this.peek(we.SPREAD)?this.parseFragment():this.parseField()}parseField(){let e=this._lexer.token,t=this.parseName(),n,r;if(this.expectOptionalToken(we.COLON))n=t,r=this.parseName();else r=t;return this.node(e,{kind:cm,alias:n,name:r,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(we.BRACE_L)?this.parseSelectionSet():void 0})}parseArguments(e){let t=e?this.parseConstArgument:this.parseArgument;return this.optionalMany(we.PAREN_L,t,we.PAREN_R)}parseFragmentArguments(){let e=this.parseFragmentArgument;return this.optionalMany(we.PAREN_L,e,we.PAREN_R)}parseArgument(e=!1){let t=this._lexer.token,n=this.parseName();return this.expectToken(we.COLON),this.node(t,{kind:B8,name:n,value:this.parseValueLiteral(e)})}parseConstArgument(){return this.parseArgument(!0)}parseFragmentArgument(){let e=this._lexer.token,t=this.parseName();return this.expectToken(we.COLON),this.node(e,{kind:V8,name:t,value:this.parseValueLiteral(!1)})}parseFragment(){let e=this._lexer.token;this.expectToken(we.SPREAD);let t=this.expectOptionalKeyword("on");if(!t&&this.peek(we.NAME)){let n=this.parseFragmentName();if(this.peek(we.PAREN_L)&&this._options.experimentalFragmentArguments)return this.node(e,{kind:hu,name:n,arguments:this.parseFragmentArguments(),directives:this.parseDirectives(!1)});return this.node(e,{kind:hu,name:n,directives:this.parseDirectives(!1)})}return this.node(e,{kind:gg,typeCondition:t?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentDefinition(){let e=this._lexer.token,t=this.parseDescription();if(this.expectKeyword("fragment"),this._options.experimentalFragmentArguments===!0)return this.node(e,{kind:Ql,description:t,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()});return this.node(e,{kind:Ql,description:t,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentName(){if(this._lexer.token.value==="on")throw this.unexpected();return this.parseName()}parseValueLiteral(e){let t=this._lexer.token;switch(t.kind){case we.BRACKET_L:return this.parseList(e);case we.BRACE_L:return this.parseObject(e);case we.INT:return this.advanceLexer(),this.node(t,{kind:ui,value:t.value});case we.FLOAT:return this.advanceLexer(),this.node(t,{kind:gu,value:t.value});case we.STRING:case we.BLOCK_STRING:return this.parseStringLiteral();case we.NAME:switch(this.advanceLexer(),t.value){case"true":return this.node(t,{kind:Eo,value:!0});case"false":return this.node(t,{kind:Eo,value:!1});case"null":return this.node(t,{kind:Fr});default:return this.node(t,{kind:td,value:t.value})}case we.DOLLAR:if(e)if(this.expectToken(we.DOLLAR),this._lexer.token.kind===we.NAME){let n=this._lexer.token.value;throw tr(this._lexer.source,t.start,`Unexpected variable "$${n}" in constant value.`)}else throw this.unexpected(t);return this.parseVariable();default:throw this.unexpected()}}parseConstValueLiteral(){return this.parseValueLiteral(!0)}parseStringLiteral(){let e=this._lexer.token;return this.advanceLexer(),this.node(e,{kind:ba,value:e.value,block:e.kind===we.BLOCK_STRING})}parseList(e){let t=()=>this.parseValueLiteral(e);return this.node(this._lexer.token,{kind:ko,values:this.any(we.BRACKET_L,t,we.BRACKET_R)})}parseObject(e){let t=()=>this.parseObjectField(e);return this.node(this._lexer.token,{kind:No,fields:this.any(we.BRACE_L,t,we.BRACE_R)})}parseObjectField(e){let t=this._lexer.token,n=this.parseName();return this.expectToken(we.COLON),this.node(t,{kind:bg,name:n,value:this.parseValueLiteral(e)})}parseDirectives(e){let t=[];while(this.peek(we.AT))t.push(this.parseDirective(e));if(t.length)return t;return}parseConstDirectives(){return this.parseDirectives(!0)}parseDirective(e){let t=this._lexer.token;return this.expectToken(we.AT),this.node(t,{kind:K8,name:this.parseName(),arguments:this.parseArguments(e)})}parseTypeReference(){let e=this._lexer.token,t;if(this.expectOptionalToken(we.BRACKET_L)){let n=this.parseTypeReference();this.expectToken(we.BRACKET_R),t=this.node(e,{kind:S0,type:n})}else t=this.parseNamedType();if(this.expectOptionalToken(we.BANG))return this.node(e,{kind:vg,type:t});return t}parseNamedType(){return this.node(this._lexer.token,{kind:kN,name:this.parseName()})}peekDescription(){return this.peek(we.STRING)||this.peek(we.BLOCK_STRING)}parseDescription(){if(this.peekDescription())return this.parseStringLiteral()}parseSchemaDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("schema");let n=this.parseConstDirectives(),r=this.many(we.BRACE_L,this.parseOperationTypeDefinition,we.BRACE_R);return this.node(e,{kind:nd,description:t,directives:n,operationTypes:r})}parseOperationTypeDefinition(){let e=this._lexer.token,t=this.parseOperationType();this.expectToken(we.COLON);let n=this.parseNamedType();return this.node(e,{kind:J8,operation:t,type:n})}parseScalarTypeDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("scalar");let n=this.parseName(),r=this.parseConstDirectives();return this.node(e,{kind:rd,description:t,name:n,directives:r})}parseObjectTypeDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("type");let n=this.parseName(),r=this.parseImplementsInterfaces(),i=this.parseConstDirectives(),s=this.parseFieldsDefinition();return this.node(e,{kind:id,description:t,name:n,interfaces:r,directives:i,fields:s})}parseImplementsInterfaces(){return this.expectOptionalKeyword("implements")?this.delimitedMany(we.AMP,this.parseNamedType):void 0}parseFieldsDefinition(){return this.optionalMany(we.BRACE_L,this.parseFieldDefinition,we.BRACE_R)}parseFieldDefinition(){let e=this._lexer.token,t=this.parseDescription(),n=this.parseName(),r=this.parseArgumentDefs();this.expectToken(we.COLON);let i=this.parseTypeReference(),s=this.parseConstDirectives();return this.node(e,{kind:NN,description:t,name:n,arguments:r,type:i,directives:s})}parseArgumentDefs(){return this.optionalMany(we.PAREN_L,this.parseInputValueDef,we.PAREN_R)}parseInputValueDef(){let e=this._lexer.token,t=this.parseDescription(),n=this.parseName();this.expectToken(we.COLON);let r=this.parseTypeReference(),i;if(this.expectOptionalToken(we.EQUALS))i=this.parseConstValueLiteral();let s=this.parseConstDirectives();return this.node(e,{kind:ON,description:t,name:n,type:r,defaultValue:i,directives:s})}parseInterfaceTypeDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("interface");let n=this.parseName(),r=this.parseImplementsInterfaces(),i=this.parseConstDirectives(),s=this.parseFieldsDefinition();return this.node(e,{kind:sd,description:t,name:n,interfaces:r,directives:i,fields:s})}parseUnionTypeDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("union");let n=this.parseName(),r=this.parseConstDirectives(),i=this.parseUnionMemberTypes();return this.node(e,{kind:od,description:t,name:n,directives:r,types:i})}parseUnionMemberTypes(){return this.expectOptionalToken(we.EQUALS)?this.delimitedMany(we.PIPE,this.parseNamedType):void 0}parseEnumTypeDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("enum");let n=this.parseName(),r=this.parseConstDirectives(),i=this.parseEnumValuesDefinition();return this.node(e,{kind:ad,description:t,name:n,directives:r,values:i})}parseEnumValuesDefinition(){return this.optionalMany(we.BRACE_L,this.parseEnumValueDefinition,we.BRACE_R)}parseEnumValueDefinition(){let e=this._lexer.token,t=this.parseDescription(),n=this.parseEnumValueName(),r=this.parseConstDirectives();return this.node(e,{kind:PN,description:t,name:n,directives:r})}parseEnumValueName(){if(this._lexer.token.value==="true"||this._lexer.token.value==="false"||this._lexer.token.value==="null")throw tr(this._lexer.source,this._lexer.token.start,`${H0(this._lexer.token)} is reserved and cannot be used for an enum value.`);return this.parseName()}parseInputObjectTypeDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("input");let n=this.parseName(),r=this.parseConstDirectives(),i=this.parseInputFieldsDefinition();return this.node(e,{kind:bu,description:t,name:n,directives:r,fields:i})}parseInputFieldsDefinition(){return this.optionalMany(we.BRACE_L,this.parseInputValueDef,we.BRACE_R)}parseTypeSystemExtension(){let e=this._lexer.lookahead();if(e.kind===we.NAME)switch(e.value){case"schema":return this.parseSchemaExtension();case"scalar":return this.parseScalarTypeExtension();case"type":return this.parseObjectTypeExtension();case"interface":return this.parseInterfaceTypeExtension();case"union":return this.parseUnionTypeExtension();case"enum":return this.parseEnumTypeExtension();case"input":return this.parseInputObjectTypeExtension();case"directive":return this.parseDirectiveExtension()}throw this.unexpected(e)}parseSchemaExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");let t=this.parseConstDirectives(),n=this.optionalMany(we.BRACE_L,this.parseOperationTypeDefinition,we.BRACE_R);if(t===void 0&&n===void 0)throw this.unexpected();return this.node(e,{kind:ld,directives:t,operationTypes:n})}parseScalarTypeExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");let t=this.parseName(),n=this.parseConstDirectives();if(n===void 0)throw this.unexpected();return this.node(e,{kind:vu,name:t,directives:n})}parseObjectTypeExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");let t=this.parseName(),n=this.parseImplementsInterfaces(),r=this.parseConstDirectives(),i=this.parseFieldsDefinition();if(n===void 0&&r===void 0&&i===void 0)throw this.unexpected();return this.node(e,{kind:_u,name:t,interfaces:n,directives:r,fields:i})}parseInterfaceTypeExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");let t=this.parseName(),n=this.parseImplementsInterfaces(),r=this.parseConstDirectives(),i=this.parseFieldsDefinition();if(n===void 0&&r===void 0&&i===void 0)throw this.unexpected();return this.node(e,{kind:xu,name:t,interfaces:n,directives:r,fields:i})}parseUnionTypeExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");let t=this.parseName(),n=this.parseConstDirectives(),r=this.parseUnionMemberTypes();if(n===void 0&&r===void 0)throw this.unexpected();return this.node(e,{kind:wu,name:t,directives:n,types:r})}parseEnumTypeExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");let t=this.parseName(),n=this.parseConstDirectives(),r=this.parseEnumValuesDefinition();if(n===void 0&&r===void 0)throw this.unexpected();return this.node(e,{kind:Du,name:t,directives:n,values:r})}parseInputObjectTypeExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");let t=this.parseName(),n=this.parseConstDirectives(),r=this.parseInputFieldsDefinition();if(n===void 0&&r===void 0)throw this.unexpected();return this.node(e,{kind:Yl,name:t,directives:n,fields:r})}parseDirectiveExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("directive"),this.expectToken(we.AT);let t=this.parseName(),n=this.parseConstDirectives();if(n===void 0)throw this.unexpected();return this.node(e,{kind:um,name:t,directives:n})}parseDirectiveDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("directive"),this.expectToken(we.AT);let n=this.parseName(),r=this.parseArgumentDefs(),i=this.parseConstDirectives(),s=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");let o=this.parseDirectiveLocations();return this.node(e,{kind:nl,description:t,name:n,arguments:r,directives:i,repeatable:s,locations:o})}parseDirectiveLocations(){return this.delimitedMany(we.PIPE,this.parseDirectiveLocation)}parseDirectiveLocation(){let e=this._lexer.token,t=this.parseName();if(Object.hasOwn(et,t.value))return t;throw this.unexpected(e)}parseSchemaCoordinate(){let e=this._lexer.token,t=this.expectOptionalToken(we.AT),n=this.parseName(),r;if(!t&&this.expectOptionalToken(we.DOT))r=this.parseName();let i;if((t||r)&&this.expectOptionalToken(we.PAREN_L))i=this.parseName(),this.expectToken(we.COLON),this.expectToken(we.PAREN_R);if(t){if(i)return this.node(e,{kind:Q8,name:n,argumentName:i});return this.node(e,{kind:W8,name:n})}else if(r){if(i)return this.node(e,{kind:z8,name:n,fieldName:r,argumentName:i});return this.node(e,{kind:H8,name:n,memberName:r})}return this.node(e,{kind:G8,name:n})}node(e,t){if(this._options.noLocation!==!0)t.loc=new T0(e,this._lexer.lastToken,this._lexer.source);return t}peek(e){return this._lexer.token.kind===e}expectToken(e){let t=this._lexer.token;if(t.kind===e)return this.advanceLexer(),t;throw tr(this._lexer.source,t.start,`Expected ${VV(e)}, found ${H0(t)}.`)}expectOptionalToken(e){if(this._lexer.token.kind===e)return this.advanceLexer(),!0;return!1}expectKeyword(e){let t=this._lexer.token;if(t.kind===we.NAME&&t.value===e)this.advanceLexer();else throw tr(this._lexer.source,t.start,`Expected "${e}", found ${H0(t)}.`)}expectOptionalKeyword(e){let t=this._lexer.token;if(t.kind===we.NAME&&t.value===e)return this.advanceLexer(),!0;return!1}unexpected(e){let t=e??this._lexer.token;return tr(this._lexer.source,t.start,`Unexpected ${H0(t)}.`)}any(e,t,n){this.expectToken(e);let r=[];while(!this.expectOptionalToken(n))r.push(t.call(this));return r}optionalMany(e,t,n){if(this.expectOptionalToken(e)){let r=[];do r.push(t.call(this));while(!this.expectOptionalToken(n));return r}return}many(e,t,n){this.expectToken(e);let r=[];do r.push(t.call(this));while(!this.expectOptionalToken(n));return r}delimitedMany(e,t){this.expectOptionalToken(e);let n=[];do n.push(t.call(this));while(this.expectOptionalToken(e));return n}advanceLexer(){let{maxTokens:e}=this._options,t=this._lexer.advance();if(t.kind!==we.EOF){if(++this._tokenCounter,e!==void 0&&this._tokenCounter>e)throw tr(this._lexer.source,t.start,`Document contains more than ${e} tokens. Parsing aborted.`)}}}function H0(e){let t=e.value;return VV(e.kind)+(t!=null?` "${t}"`:"")}function VV(e){return FV(e)?`"${e}"`:e}function Mr(e,t){switch(t.kind){case S0:{let n=Mr(e,t.type);return n&&new Tr(n)}case vg:{let n=Mr(e,t.type);return n&&new dt(n)}case kN:return e.getType(t.name.value)}}function KV(e){let t=new Map;return{Directive(n){if(n.name.value===tc.name||n.name.value===nc.name){let i=n.arguments?.find((o)=>o.name.value==="label")?.value;if(!i||i.kind===Fr)return;if(i.kind!==ba){e.reportError(new ae(`Argument "@${n.name.value}(label:)" must be a static string.`,{nodes:n}));return}let s=t.get(i.value);if(s!=null)e.reportError(new ae('Value for arguments "defer(label:)" and "stream(label:)" must be unique across all Defer/Stream directive usages.',{nodes:[s,n]}));else t.set(i.value,n)}}}}function GV(e){return{OperationDefinition(t){let n=e.getDocument(),r=new Map;for(let o of n.definitions)if(o.kind===Ql)r.set(o.name.value,o);if(t.operation!=="subscription"&&t.operation!=="mutation")return;let s=e.getSchema().getRootType(t.operation);if(s)tO({context:e,operationType:t.operation,rootType:s,fragments:r,selectionSet:t.selectionSet,visitedFragments:new Set})}}}function tO({context:e,operationType:t,rootType:n,fragments:r,selectionSet:i,visitedFragments:s}){for(let o of i.selections)if(o.kind==="Field"){let a=o.directives?.find((l)=>l.name.value===nc.name);if(a)e.reportError(new ae(`Stream directive cannot be used on root ${t} type "${n}".`,{nodes:a}))}else if(o.kind==="FragmentSpread"){let a=o.name.value;if(s.has(a))continue;let l=r.get(a);if(l){let c=JV(o);if(c!==void 0)e.reportError(new ae(`Defer directive cannot be used on root ${t} type "${n}".`,{nodes:c}));tO({context:e,operationType:t,rootType:n,fragments:r,selectionSet:l.selectionSet,visitedFragments:s})}s.add(a)}else if(o.kind==="InlineFragment"){let a=JV(o);if(a!==void 0)e.reportError(new ae(`Defer directive cannot be used on root ${t} type "${n}".`,{nodes:a}));tO({context:e,operationType:t,rootType:n,fragments:r,selectionSet:o.selectionSet,visitedFragments:s})}}function JV(e){return e.directives?.find((t)=>t.name.value===tc.name)}function HV(e){let t=e.arguments?.find((n)=>n.name.value==="if");if(!t)return!1;if(t.value.kind===Eo){if(t.value.value)return!1}else if(t.value.kind!==_s)return!1;return!0}function i0e(e){let t=e.arguments?.find((n)=>n.name.value==="if");if(!t)return!0;if(t.value.kind===Eo){if(t.value.value)return!0;return!1}return!0}function s0e(e){let t=e.arguments?.find((n)=>n.name.value==="if");if(!t)return!1;if(t?.value.kind===Eo){if(t.value.value)return!1;return!0}return!0}function zV(e){return{OperationDefinition(t){if(t.operation!==jr.SUBSCRIPTION)return;let n=e.getDocument(),r=new Map;for(let s of n.definitions)if(s.kind===Ql)r.set(s.name.value,s);let i=new Set;nO({context:e,fragments:r,selectionSet:t.selectionSet,parentNodes:[],visitedFragments:i})}}}function nO({context:e,fragments:t,selectionSet:n,parentNodes:r,visitedFragments:i}){for(let s of n.selections){let o=s.directives?.find((l)=>l.name.value===bd.name);if(o&&i0e(o))continue;let a=s.directives?.find((l)=>l.name.value===gd.name);if(a&&s0e(a))continue;for(let l of s.directives??[])if(l.name.value===tc.name){if(!HV(l))e.reportError(new ae("Defer directive not supported on subscription operations. Disable `@defer` by setting the `if` argument to `false`.",{nodes:[l,...r]}))}else if(l.name.value===nc.name){if(!HV(l))e.reportError(new ae("Stream directive not supported on subscription operations. Disable `@stream` by setting the `if` argument to `false`.",{nodes:[l,...r]}))}if(s.kind==="FragmentSpread"){let l=s.name.value;if(i.has(l))continue;i.add(l);let c=t.get(l);if(c)nO({context:e,fragments:t,parentNodes:[s,...r],selectionSet:c?.selectionSet,visitedFragments:i})}else if(s.selectionSet)nO({context:e,fragments:t,selectionSet:s.selectionSet,parentNodes:r,visitedFragments:i})}}function rO(e){return e.kind===ed||e.kind===Ql}function iO(e){return e.kind===nd||Pu(e)||e.kind===nl}function Pu(e){return e.kind===rd||e.kind===id||e.kind===sd||e.kind===od||e.kind===ad||e.kind===bu}function sO(e){return e.kind===ld||e.kind===um||W0(e)}function W0(e){return e.kind===vu||e.kind===_u||e.kind===xu||e.kind===wu||e.kind===Du||e.kind===Yl}function WV(e){return{Document(t){for(let n of t.definitions)if(!rO(n)){let r=n.kind===nd||n.kind===ld?"schema":'"'+n.name.value+'"';e.reportError(new ae(`The ${r} definition is not executable.`,{nodes:n}))}return!1}}}function QV(e){return{Field(t){let n=e.getParentType();if(n){if(!e.getFieldDef()){let i=e.getSchema(),s=t.name.value,o=Oi("to use an inline fragment on",e.hideSuggestions?[]:o0e(i,n,s));if(o==="")o=Oi(e.hideSuggestions?[]:a0e(n,s));e.reportError(new ae(`Cannot query field "${s}" on type "${n}".`+o,{nodes:t}))}}}}}function o0e(e,t,n){if(!Io(t))return[];let r=new Set,i=Object.create(null);for(let s of e.getPossibleTypes(t)){if(s.getFields()[n]==null)continue;r.add(s),i[s.name]=1;for(let o of s.getInterfaces()){if(o.getFields()[n]==null)continue;r.add(o),i[o.name]=(i[o.name]??0)+1}}return[...r].sort((s,o)=>{let a=i[o.name]-i[s.name];if(a!==0)return a;if(dn(s)&&e.isSubType(s,o))return-1;if(dn(o)&&e.isSubType(o,s))return 1;return pm(s.name,o.name)}).map((s)=>s.name)}function a0e(e,t){if(Dn(e)||dn(e)){let n=Object.keys(e.getFields());return Wi(t,n)}return[]}function YV(e){return{InlineFragment(t){let n=t.typeCondition;if(n){let r=Mr(e.getSchema(),n);if(r&&!Su(r)){let i=hn(n);e.reportError(new ae(`Fragment cannot condition on non composite type "${i}".`,{nodes:n}))}}},FragmentDefinition(t){let n=Mr(e.getSchema(),t.typeCondition);if(n&&!Su(n)){let r=hn(t.typeCondition);e.reportError(new ae(`Fragment "${t.name.value}" cannot condition on non composite type "${r}".`,{nodes:t.typeCondition}))}}}}function XV(e){return{...oO(e),FragmentArgument(t){let n=e.getFragmentSignature();if(n){if(!n.variableDefinitions.get(t.name.value)){let i=t.name.value,s=e.hideSuggestions?[]:Wi(i,Array.from(n.variableDefinitions.values()).map((o)=>o.variable.name.value));e.reportError(new ae(`Unknown argument "${i}" on fragment "${n.definition.name.value}".`+Oi(s),{nodes:t}))}}},Argument(t){let n=e.getArgument(),r=e.getFieldDef();if(!n&&r){let i=t.name.value,s=e.hideSuggestions?[]:Wi(i,r.args.map((o)=>o.name));e.reportError(new ae(`Unknown argument "${i}" on field "${r}".`+Oi(s),{nodes:t}))}}}}function oO(e){let t=new Map,n=e.getSchema(),r=n?n.getDirectives():Ds;for(let s of r)t.set(s.name,s.args.map((o)=>o.name));let i=e.getDocument().definitions;for(let s of i)if(s.kind===nl){let o=s.arguments??[];t.set(s.name.value,o.map((a)=>a.name.value))}return{Directive(s){let o=s.name.value,a=t.get(o);if(s.arguments!=null&&a!=null)for(let l of s.arguments){let c=l.name.value;if(!a.includes(c)){let u=Wi(c,a);e.reportError(new ae(`Unknown argument "${c}" on directive "@${o}".`+(e.hideSuggestions?"":Oi(u)),{nodes:l}))}}return!1}}}function aO(e){let t=new Map,n=e.getSchema(),r=n?n.getDirectives():Ds;for(let s of r)t.set(s.name,s.locations);let i=e.getDocument().definitions;for(let s of i)if(s.kind===nl)t.set(s.name.value,s.locations.map((o)=>o.value));return{Directive(s,o,a,l,c){let u=s.name.value,p=t.get(u);if(p==null){e.reportError(new ae(`Unknown directive "@${u}".`,{nodes:s}));return}let d=l0e(c);if(d!=null&&!p.includes(d))e.reportError(new ae(`Directive "@${u}" may not be used on ${d}.`,{nodes:s}))}}}function l0e(e){let t=e.at(-1);if(!(t!=null&&("kind"in t)))cn(!1);switch(t.kind){case ed:return c0e(t.operation);case cm:return et.FIELD;case hu:return et.FRAGMENT_SPREAD;case gg:return et.INLINE_FRAGMENT;case Ql:return et.FRAGMENT_DEFINITION;case EN:{let n=e[e.length-3];if(!("kind"in n))cn(!1);return n.kind===ed?et.VARIABLE_DEFINITION:et.FRAGMENT_VARIABLE_DEFINITION}case nd:case ld:return et.SCHEMA;case rd:case vu:return et.SCALAR;case id:case _u:return et.OBJECT;case NN:return et.FIELD_DEFINITION;case sd:case xu:return et.INTERFACE;case od:case wu:return et.UNION;case ad:case Du:return et.ENUM;case PN:return et.ENUM_VALUE;case bu:case Yl:return et.INPUT_OBJECT;case ON:{let n=e.at(-3);if(!(n!=null&&("kind"in n)))cn(!1);return n.kind===bu||n.kind===Yl?et.INPUT_FIELD_DEFINITION:et.ARGUMENT_DEFINITION}case nl:case um:return et.DIRECTIVE_DEFINITION;default:cn(!1,"Unexpected kind: "+qe(t.kind))}}function c0e(e){switch(e){case jr.QUERY:return et.QUERY;case jr.MUTATION:return et.MUTATION;case jr.SUBSCRIPTION:return et.SUBSCRIPTION}}function ZV(e){return{FragmentSpread(t){let n=t.name.value;if(!e.getFragment(n))e.reportError(new ae(`Unknown fragment "${n}".`,{nodes:t.name}))}}}function e6(e){let t=e.getSchema();return{OperationDefinition(n){let r=n.operation;if(!t.getRootType(r))e.reportError(new ae(`The ${r} operation is not supported by the schema.`,{nodes:n}))}}}function lO(e){let{definitions:t}=e.getDocument(),n=e.getSchema()?.getTypeMap()??{},r=new Set([...Object.keys(n),...t.filter(Pu).map((i)=>i.name.value)]);return{NamedType(i,s,o,a,l){let c=i.name.value;if(!r.has(c)){let u=l[2]??o,p=u!=null&&u0e(u);if(p&&t6.has(c))return;let d=e.hideSuggestions?[]:Wi(c,p?[...t6,...r]:[...r]);e.reportError(new ae(`Unknown type "${c}".`+Oi(d),{nodes:i}))}}}}var t6=new Set([...Nu,...Ou].map((e)=>e.name));function u0e(e){return"kind"in e&&(iO(e)||sO(e))}function n6(e){let t=0;return{Document(n){t=n.definitions.filter((r)=>r.kind===ed).length},OperationDefinition(n){if(!n.name&&t>1)e.reportError(new ae("This anonymous operation must be the only defined operation.",{nodes:n}))}}}function r6(e){let t=e.getSchema(),n=t?.astNode??t?.getQueryType()??t?.getMutationType()??t?.getSubscriptionType(),r=0;return{SchemaDefinition(i){if(n){e.reportError(new ae("Cannot define a new schema within a schema extension.",{nodes:i}));return}if(r>0)e.reportError(new ae("Must provide only one schema definition.",{nodes:i}));++r}}}var p0e=3;function i6(e){function t(n,r=Object.create(null),i=0){if(n.kind===hu){let s=n.name.value;if(r[s]===!0)return!1;let o=e.getFragment(s);if(!o)return!1;try{return r[s]=!0,t(o,r,i)}finally{r[s]=void 0}}if(n.kind===cm&&(n.name.value==="fields"||n.name.value==="interfaces"||n.name.value==="possibleTypes"||n.name.value==="inputFields")){if(i++,i>=p0e)return!0}if("selectionSet"in n&&n.selectionSet){for(let s of n.selectionSet.selections)if(t(s,r,i))return!0}return!1}return{Field(n){if(n.name.value==="__schema"||n.name.value==="__type"){if(t(n))return e.reportError(new ae("Maximum introspection depth exceeded",{nodes:[n]})),!1}}}}function s6(e){let t=new Set,n=[],r=Object.create(null);return{OperationDefinition:()=>!1,FragmentDefinition(s){return i(s),!1}};function i(s){if(t.has(s.name.value))return;let o=s.name.value;t.add(o);let a=e.getFragmentSpreads(s.selectionSet);if(a.length===0)return;r[o]=n.length;for(let l of a){let c=l.name.value,u=r[c];if(n.push(l),u===void 0){let p=e.getFragment(c);if(p)i(p)}else{let p=n.slice(u),d=p.slice(0,-1).map((f)=>'"'+f.name.value+'"').join(", ");e.reportError(new ae(`Cannot spread fragment "${c}" within itself`+(d!==""?` via ${d}.`:"."),{nodes:p}))}n.pop()}r[o]=void 0}}function o6(e){return{OperationDefinition(t){let n=new Set(t.variableDefinitions?.map((i)=>i.variable.name.value)),r=e.getRecursiveVariableUsages(t);for(let{node:i,fragmentVariableDefinition:s}of r){if(s)continue;let o=i.name.value;if(!n.has(o))e.reportError(new ae(t.name?`Variable "$${o}" is not defined by operation "${t.name.value}".`:`Variable "$${o}" is not defined.`,{nodes:[i,t]}))}}}}function a6(e){let t=new Set,n=[];return{OperationDefinition(r){for(let i of e.getRecursivelyReferencedFragments(r))t.add(i.name.value);return!1},FragmentDefinition(r){return n.push(r),!1},Document:{leave(){for(let r of n){let i=r.name.value;if(!t.has(i))e.reportError(new ae(`Fragment "${i}" is never used.`,{nodes:r}))}}}}}function l6(e){return{FragmentDefinition(t){let n=e.getVariableUsages(t),r=new Set(n.map(({node:s})=>s.name.value)),i=t.variableDefinitions??[];for(let s of i){let o=s.variable.name.value;if(!r.has(o))e.reportError(new ae(`Variable "$${o}" is never used in fragment "${t.name.value}".`,{nodes:s}))}},OperationDefinition(t){let n=e.getRecursiveVariableUsages(t),r=new Set;for(let{node:s,fragmentVariableDefinition:o}of n){let a=s.name.value;if(!o)r.add(a)}let i=t.variableDefinitions??[];for(let s of i){let o=s.variable.name.value;if(!r.has(o))e.reportError(new ae(t.name?`Variable "$${o}" is never used in operation "${t.name.value}".`:`Variable "$${o}" is never used.`,{nodes:s}))}}}}function qg(e){switch(e.kind){case No:return{...e,fields:d0e(e.fields)};case ko:return{...e,values:e.values.map(qg)};case ui:case gu:case ba:case Eo:case Fr:case td:case _s:return e}}function d0e(e){return e.map((t)=>({...t,value:qg(t.value)})).sort((t,n)=>pm(t.name.value,n.name.value))}function p6(e){if(Array.isArray(e))return e.map(([t,n])=>`subfields "${t}" conflict because `+p6(n)).join(" and ");return e}function d6(e){let t=new fO,n=new y6,r=new Map;return{SelectionSet(i){let s=f0e(e,r,t,n,e.getParentType(),i);for(let[[o,a],l,c]of s){let u=p6(a);e.reportError(new ae(`Fields "${o}" conflict because ${u}. Use different aliases on the fields to fetch both if this was intentional.`,{nodes:l.concat(c)}))}}}}function f0e(e,t,n,r,i,s){let o=[],[a,l]=X0(e,t,i,s,void 0);if(y0e(e,o,t,n,r,a),l.length!==0)for(let c=0;c1)for(let l=0;l[s.value,r===void 0?o:Ug(o,r)]));return e.every((s)=>{let o=s.value;if(t)o=Ug(o,t);let a=i.get(s.name.value);if(a===void 0)return!1;return c6(o)===c6(a)})}function Ug(e,t){switch(e.kind){case _s:return t.get(e.name.value)??e;case ko:return{...e,values:e.values.map((n)=>Ug(n,t))};case No:return{...e,fields:e.fields.map((n)=>({...n,value:Ug(n.value,t)}))};default:return e}}function c6(e){return hn(qg(e))}function u6(e){return e?.find((t)=>t.name.value==="stream")}function h0e(e,t,n,r){let i=u6(e),s=u6(n);if(!i&&!s)return;else if(i&&s){if(dO(i.arguments,t,s.arguments,r))return"they have overlapping stream directives. See https://github.com/graphql/defer-stream-wg/discussions/100";return"they have overlapping stream directives"}return"they have overlapping stream directives"}function cO(e,t){if(fn(e))return fn(t)?cO(e.ofType,t.ofType):!0;if(fn(t))return!0;if(Ft(e))return Ft(t)?cO(e.ofType,t.ofType):!0;if(Ft(t))return!0;if(Xl(e)||Xl(t))return e!==t;return!1}function X0(e,t,n,r,i){let s=t.get(r);if(s)return s;let o=new Map,a=new Map;m6(e,n,r,o,a,i);let l=[o,Array.from(a.values())];return t.set(r,l),l}function uO(e,t,n,r){let i=t.get(n.selectionSet);if(i)return i;let s=Mr(e.getSchema(),n.typeCondition);return X0(e,t,s,n.selectionSet,r)}function m6(e,t,n,r,i,s){for(let o of n.selections)switch(o.kind){case cm:{let a=o.name.value,l;if(Dn(t)||dn(t))l=t.getFields()[a];let c=o.alias?o.alias.value:a,u=r.get(c);if(u==null)u=[],r.set(c,u);u.push([t,o,l]);break}case hu:{let a=g0e(e,o,s);i.set(a.key,a);break}case gg:{let a=o.typeCondition,l=a?Mr(e.getSchema(),a):t;m6(e,l,o.selectionSet,r,i,s);break}}}function g0e(e,t,n){let r="",i=new Map,s=e.getFragmentSignatureByName()(t.name.value),o=new Map;if(t.arguments)for(let a of t.arguments)o.set(a.name.value,a.value);if(s?.variableDefinitions){r+=t.name.value+"(";for(let[a,l]of s.variableDefinitions){let c=o.get(a);if(c)r+=a+": "+hn(qg(c));let u=o.get(a);if(u!==void 0)i.set(a,n!==void 0?Ug(u,n):u);else if(l.defaultValue)i.set(a,l.defaultValue)}r+=")"}return{key:r,node:t,varMap:i.size>0?i:void 0}}function b0e(e,t,n,r){if(e.length>0)return[[t,e.map(([i])=>i)],[n,...e.map(([,i])=>i).flat()],[r,...e.map(([,,i])=>i).flat()]]}class fO{constructor(){this._data=new Map}has(e,t,n){let r=this._data.get(e)?.get(t);if(r===void 0)return!1;return n?!0:n===r}add(e,t,n){let r=this._data.get(e);if(r===void 0)this._data.set(e,new Map([[t,n]]));else r.set(t,n)}}class y6{constructor(){this._orderedPairSet=new fO}has(e,t,n){return ei.name.value));for(let i of n.args)if(!r.has(i.name)&&xa(i))e.reportError(new ae(`Argument "${i}" of type "${i.type}" is required, but it was not provided.`,{nodes:t}))}},FragmentSpread:{leave(t){let n=e.getFragmentSignature();if(!n)return!1;let r=new Set(t.arguments?.map((i)=>i.name.value));for(let[i,s]of n.variableDefinitions)if(!r.has(i)&&v6(s)){let o=Mr(e.getSchema(),s.type),a=qe(o);e.reportError(new ae(`Fragment "${t.name.value}" argument "${i}" of type "${a}" is required, but it was not provided.`,{nodes:t}))}}}}}function mO(e){let t=new Map,r=e.getSchema()?.getDirectives()??Ds;for(let s of r)t.set(s.name,new Map(s.args.filter(xa).map((o)=>[o.name,o])));let i=e.getDocument().definitions;for(let s of i)if(s.kind===nl){let o=s.arguments??[];t.set(s.name.value,new Map(o.filter(v6).map((a)=>[a.name.value,a])))}return{Directive:{leave(s){let o=s.name.value,a=t.get(o);if(a!=null){let l=s.arguments??[],c=new Set(l.map((u)=>u.name.value));for(let[u,p]of a.entries())if(!c.has(u)){let d=P0(p.type)?qe(p.type):hn(p.type);e.reportError(new ae(`Argument "@${o}(${u}:)" of type "${d}" is required, but it was not provided.`,{nodes:s}))}}}}}}function v6(e){return e.type.kind===vg&&e.defaultValue==null}function _6(e){return{Field(t){let n=e.getType(),r=t.selectionSet;if(n){if(Xl(_a(n))){if(r){let i=t.name.value,s=qe(n);e.reportError(new ae(`Field "${i}" must not have a selection since type "${s}" has no subfields.`,{nodes:r}))}}else if(!r){let i=t.name.value,s=qe(n);e.reportError(new ae(`Field "${i}" of type "${s}" must have a selection of subfields. Did you mean "${i} { ... }"?`,{nodes:t}))}else if(r.selections.length===0){let i=t.name.value,s=qe(n);e.reportError(new ae(`Field "${i}" of type "${s}" must have at least one field selected.`,{nodes:t}))}}}}}function Dd(e,t){if(Ft(t)){if(e==null)return;return Dd(e,t.ofType)}if(e==null)return null;if(fn(t)){if(!So(e)){let i=Dd(e,t.ofType);if(i===void 0)return;return[i]}let r=[];for(let i of e){let s=Dd(i,t.ofType);if(s===void 0)return;r.push(s)}return r}if(en(t)){if(!Rr(e)||Array.isArray(e))return;let r=Object.create(null),i=t.getFields(),s=0;for(let o of Object.keys(e)){if(e[o]===void 0)continue;if(s++,!Object.hasOwn(i,o))return}for(let o of Object.values(i)){let a=e[o.name];if(a===void 0){if(Ao(o))return;let l=Z0(o);if(l!==void 0)r[o.name]=l}else{let l=Dd(a,o.type);if(l===void 0)return;r[o.name]=l}}if(t.isOneOf){let o=Object.keys(r);if(s!==1||o.length!==1)return;let a=o[0];if(r[a]===null)return}return r}let n=va(t);try{return n.coerceInputValue(e)}catch(r){}}function $u(e,t,n,r){if(e.kind===_s){let s=x6(e,n,r);if(s==null&&Ft(t))return;return s}if(Ft(t)){if(e.kind===Fr)return;return $u(e,t.ofType,n,r)}if(e.kind===Fr)return null;if(fn(t)){if(e.kind!==ko){let o=$u(e,t.ofType,n,r);if(o===void 0)return;return[o]}let s=[];for(let o of e.values){let a=$u(o,t.ofType,n,r);if(a===void 0)if(o.kind===_s&&x6(o,n,r)==null&&!Ft(t.ofType))a=null;else return;s.push(a)}return s}if(en(t)){if(e.kind!==No)return;let s=Object.create(null),o=t.getFields();if(e.fields.some((c)=>!Object.hasOwn(o,c.name.value)))return;let l=new Map(e.fields.map((c)=>[c.name.value,c]));for(let c of Object.values(o)){let u=l.get(c.name);if(!u||u.value.kind===_s&&D0e(u.value,n,r)){if(Ao(c))return;let p=Z0(c);if(p!==void 0)s[c.name]=p}else{let p=$u(u.value,c.type,n,r);if(p===void 0)return;s[c.name]=p}}if(t.isOneOf){let c=Object.keys(s);if(l.size!==1||c.length!==1)return;for(let[u,p]of l)if(p.value.kind===Fr||s[u]===null)return}return s}let i=va(t);try{return i.coerceInputLiteral?i.coerceInputLiteral(Eu(e,n,r)):i.parseLiteral(e,n?.coerced)}catch(s){}}function x6(e,t,n){let r=e.name.value;if(n?.sources[r]!==void 0)return n.coerced[r];return t?.coerced[r]}function D0e(e,t,n){let r=e.name.value;return(n?.sources[r]!==void 0?n.coerced:t?.coerced)?.[r]===void 0}function Z0(e){let t=e._memoizedCoercedDefaultValue;if(t!==void 0)return t;let n=e.default;if(n!==void 0){if(t=n.literal?$u(n.literal,e.type):Dd(n.value,e.type),t===void 0)cn(!1,`Expected value of type "${e.type}" to be valid, found: ${qe(n.literal??n.value)}.`);return e._memoizedCoercedDefaultValue=t,t}let r=e.defaultValue;if(r!==void 0)e._memoizedCoercedDefaultValue=r;return r}function w6(e,t,n,r,i){try{let s=Z0(n);if(s!==void 0)e[t]=s}catch(s){let o=n.default;if(o===void 0)throw s;let a=!1;if(ZN(o,n.type,(l,c)=>{a=!0,r(l,c)},i),!a)r(dg(s),[])}}function D6(e,t,n,r,i){let s=e.arguments??[],o=new Map(s.map((c)=>[c.name.value,c])),a=Object.create(null),l=Object.create(null);for(let[c,u]of Object.entries(t)){let p=o.get(c);if(p!==void 0)a[c]=r==null?{signature:u,value:p.value}:{signature:u,value:p.value,fragmentVariableValues:r};else a[c]={signature:u};T6(l,e,c,u,p,n,r,i)}return{sources:a,coerced:l}}function ew(e,t,n,r,i){let s=Object.create(null),o=t.arguments??[],a=new Map(o.map((l)=>[l.name.value,l]));for(let l of e.args){let c=l.name;T6(s,t,c,l,a.get(l.name),n,r,i)}return s}function T6(e,t,n,r,i,s,o,a){let l=r.type,c=(d,f)=>{throw new ae(`${yO(r,t)} has invalid default value${fg(f)}: ${d.message}`,{nodes:t})};if(!i){if(xa(r))throw new ae(`${yO(r,t)} of required type "${l}" was not provided.`,{nodes:t});w6(e,n,r,c,a);return}let u=i.value;if(u.kind===_s){let d=u.name.value,f=o?.sources[d]?o:s;if((f==null||!Object.hasOwn(f.coerced,d))&&!xa(r)){w6(e,n,r,c,a);return}}let p=$u(u,l,s,o);if(p===void 0)hd(u,l,(d,f)=>{throw d.message=`${yO(r,t)} has invalid value${fg(f)}: ${d.message}`,d},s,o,a),cn(!1,"Invalid argument");e[n]=p}function yO(e,t){return LN(e)?`Argument "${e}"`:`Variable "$${e.name}" defined by fragment "${t.name.value}"`}function vm(e,t,n,r,i){let s=t.directives?.find((o)=>o.name.value===e.name);if(s)return ew(e,s,n,r,i)}function k6(e,t,n,r,i,s,o=!1){let a=new zi,l=[],c={schema:e,fragments:t,variableValues:n,runtimeType:r,visitedFragmentNames:new Map,hideSuggestions:s,forbiddenDirectiveInstances:[],forbidSkipAndInclude:o};return tw(c,i,a,l),{groupedFieldSet:a,newDeferUsages:l,forbiddenDirectiveInstances:c.forbiddenDirectiveInstances}}function tw(e,t,n,r,i,s){let{schema:o,fragments:a,variableValues:l,runtimeType:c,visitedFragmentNames:u,hideSuggestions:p}=e;for(let d of t.selections)switch(d.kind){case cm:{if(!hO(e,d,l,s))continue;n.add(T0e(d),{node:d,deferUsage:i,fragmentVariableValues:s});break}case gg:{if(!hO(e,d,l,s)||!E6(o,d,c))continue;let f=S6(l,s,d,i);if(!f)tw(e,d.selectionSet,n,r,i,s);else r.push(f),tw(e,d.selectionSet,n,r,f,s);break}case hu:{let f=d.name.value;if(!hO(e,d,l,s))continue;let m=a[f];if(m==null||!E6(o,m.definition,c))continue;let y=S6(l,s,d,i),h=u.get(f),b;if(!y){if(h===!1)continue;u.set(f,!1),b=i}else{if(h!==void 0)continue;u.set(f,!0),r.push(y),b=y}let g=m.variableSignatures,x;if(g)x=D6(d,g,l,s,p);tw(e,m.definition.selectionSet,n,r,b,x);break}}}function S6(e,t,n,r){let i=vm(tc,n,e,t);if(!i)return;if(i.if===!1)return;return{label:typeof i.label==="string"?i.label:void 0,parentDeferUsage:r}}function hO(e,t,n,r){let i=t.directives?.find((l)=>l.name.value===bd.name);if(i&&e.forbidSkipAndInclude)return e.forbiddenDirectiveInstances.push(i),!1;if((i?ew(bd,i,n,r,e.hideSuggestions):void 0)?.if===!0)return!1;let o=t.directives?.find((l)=>l.name.value===gd.name);if(o&&e.forbidSkipAndInclude)return e.forbiddenDirectiveInstances.push(o),!1;if((o?ew(gd,o,n,r,e.hideSuggestions):void 0)?.if===!1)return!1;return!0}function E6(e,t,n){let r=t.typeCondition;if(!r)return!0;let i=Mr(e,r);if(i===n)return!0;if(Io(i))return e.isSubType(i,n);return!1}function T0e(e){return e.alias?e.alias.value:e.name.value}function gO(e){return e.map((t)=>t.node)}function N6(e){return{OperationDefinition(t){if(t.operation==="subscription"){let n=e.getSchema(),r=n.getSubscriptionType();if(r){let i=t.name?t.name.value:null,s=Object.create(null),o=e.getDocument(),a=Object.create(null);for(let u of o.definitions)if(u.kind===Ql)a[u.name.value]={definition:u};let{groupedFieldSet:l,forbiddenDirectiveInstances:c}=k6(n,a,s,r,t.selectionSet,e.hideSuggestions,!0);if(c.length>0){e.reportError(new ae(i!=null?`Subscription "${i}" must not use \`@skip\` or \`@include\` directives in the top level selection.`:"Anonymous Subscription must not use `@skip` or `@include` directives in the top level selection.",{nodes:c}));return}if(l.size>1){let d=[...l.values()].slice(1).flatMap((f)=>gO(f));e.reportError(new ae(i!=null?`Subscription "${i}" must select only one top level field.`:"Anonymous Subscription must select only one top level field.",{nodes:d}))}for(let u of l.values())if(gO(u)[0].name.value.startsWith("__"))e.reportError(new ae(i!=null?`Subscription "${i}" must not select an introspection top level field.`:"Anonymous Subscription must not select an introspection top level field.",{nodes:gO(u)}))}}}}}function O6(e){return{Directive(t){let n=e.getFieldDef(),r=e.getParentType();if(n&&r&&t.name.value===nc.name&&!(fn(n.type)||fm(n.type)&&fn(n.type.ofType)))e.reportError(new ae(`Directive "@stream" cannot be used on non-list field "${r}.${n.name}".`,{nodes:t}))}}}function _m(e,t){let n=new zi;for(let r of e)n.add(t(r),r);return n}function P6(e){return{DirectiveDefinition(r){let i=r.arguments??[];return n(`@${r.name.value}`,i)},InterfaceTypeDefinition:t,InterfaceTypeExtension:t,ObjectTypeDefinition:t,ObjectTypeExtension:t};function t(r){let i=r.name.value,s=r.fields??[];for(let o of s){let a=o.name.value,l=o.arguments??[];n(`${i}.${a}`,l)}return!1}function n(r,i){let s=_m(i,(o)=>o.name.value);for(let[o,a]of s)if(a.length>1)e.reportError(new ae(`Argument "${r}(${o}:)" can only be defined once.`,{nodes:a.map((l)=>l.name)}));return!1}}function bO(e){return{Field:t,Directive:t};function t(n){let r=n.arguments??[],i=_m(r,(s)=>s.name.value);for(let[s,o]of i)if(o.length>1)e.reportError(new ae(`There can be only one argument named "${s}".`,{nodes:o.map((a)=>a.name)}))}}function $6(e){let t=new Map,n=e.getSchema();return{DirectiveDefinition(r){let i=r.name.value;if(n?.getDirective(i)){e.reportError(new ae(`Directive "@${i}" already exists in the schema. It cannot be redefined.`,{nodes:r.name}));return}let s=t.get(i);if(s)e.reportError(new ae(`There can be only one directive named "@${i}".`,{nodes:[s,r.name]}));else t.set(i,r.name);return!1}}}function vO(e){let t=new Map,n=e.getSchema(),r=n?n.getDirectives():Ds;for(let l of r)t.set(l.name,!l.isRepeatable);let i=e.getDocument().definitions;for(let l of i)if(l.kind===nl)t.set(l.name.value,!l.repeatable);let s=new Map,o=new Map,a=new Map;return{enter(l){if(!("directives"in l)||!l.directives)return;let c;if(l.kind===nd||l.kind===ld)c=s;else if(Pu(l)||W0(l)){let u=l.name.value;if(c=o.get(u),c===void 0)c=new Map,o.set(u,c)}else if(l.kind===nl||l.kind===um){let u=l.name.value;if(c=a.get(u),c===void 0)c=new Map,a.set(u,c)}else c=new Map;for(let u of l.directives){let p=u.name.value;if(t.get(p)===!0){let d=c.get(p);if(d!=null)e.reportError(new ae(`The directive "@${p}" can only be used once at this location.`,{nodes:[d,u]}));else c.set(p,u)}}}}}function I6(e){let t=e.getSchema(),n=t?t.getTypeMap():Object.create(null),r=new Map;return{EnumTypeDefinition:i,EnumTypeExtension:i};function i(s){let o=s.name.value,a=r.get(o);if(a==null)a=new Map,r.set(o,a);let l=s.values??[];for(let c of l){let u=c.name.value,p=n[o];if(Cr(p)&&p.getValue(u)){e.reportError(new ae(`Enum value "${o}.${u}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:c.name}));continue}let d=a.get(u);if(d!=null)e.reportError(new ae(`Enum value "${o}.${u}" can only be defined once.`,{nodes:[d,c.name]}));else a.set(u,c.name)}return!1}}function A6(e){let t=e.getSchema(),n=t?t.getTypeMap():Object.create(null),r=new Map;return{InputObjectTypeDefinition:i,InputObjectTypeExtension:i,InterfaceTypeDefinition:i,InterfaceTypeExtension:i,ObjectTypeDefinition:i,ObjectTypeExtension:i};function i(s){let o=s.name.value,a=r.get(o);if(a==null)a=new Map,r.set(o,a);let l=s.fields??[];for(let c of l){let u=c.name.value;if(S0e(n[o],u)){e.reportError(new ae(`Field "${o}.${u}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:c.name}));continue}let p=a.get(u);if(p!=null)e.reportError(new ae(`Field "${o}.${u}" can only be defined once.`,{nodes:[p,c.name]}));else a.set(u,c.name)}return!1}}function S0e(e,t){if(Dn(e)||dn(e)||en(e))return e.getFields()[t]!=null;return!1}function R6(e){let t=new Map;return{OperationDefinition:()=>!1,FragmentDefinition(n){let r=n.name.value,i=t.get(r);if(i!=null)e.reportError(new ae(`There can be only one fragment named "${r}".`,{nodes:[i,n.name]}));else t.set(r,n.name);return!1}}}function _O(e){let t=[],n=new Map;return{ObjectValue:{enter(){t.push(n),n=new Map},leave(){let r=t.pop();if(r==null)cn(!1);n=r}},ObjectField(r){let i=r.name.value,s=n.get(i);if(s!=null)e.reportError(new ae(`There can be only one input field named "${i}".`,{nodes:[s,r.name]}));else n.set(i,r.name)}}}function j6(e){let t=new Map;return{OperationDefinition(n){let r=n.name;if(r!=null){let i=t.get(r.value);if(i!=null)e.reportError(new ae(`There can be only one operation named "${r.value}".`,{nodes:[i,r]}));else t.set(r.value,r)}return!1},FragmentDefinition:()=>!1}}function F6(e){let t=e.getSchema(),n=new Map,r=t?{query:t.getQueryType(),mutation:t.getMutationType(),subscription:t.getSubscriptionType()}:{};return{SchemaDefinition:i,SchemaExtension:i};function i(s){let o=s.operationTypes??[];for(let a of o){let l=a.operation,c=n.get(l);if(r[l])e.reportError(new ae(`Type for ${l} already defined in the schema. It cannot be redefined.`,{nodes:a}));else if(c)e.reportError(new ae(`There can be only one ${l} type in schema.`,{nodes:[c,a]}));else n.set(l,a)}return!1}}function C6(e){let t=new Map,n=e.getSchema();return{ScalarTypeDefinition:r,ObjectTypeDefinition:r,InterfaceTypeDefinition:r,UnionTypeDefinition:r,EnumTypeDefinition:r,InputObjectTypeDefinition:r};function r(i){let s=i.name.value;if(n?.getType(s)){e.reportError(new ae(`Type "${s}" already exists in the schema. It cannot also be defined in this type definition.`,{nodes:i.name}));return}let o=t.get(s);if(o!=null)e.reportError(new ae(`There can be only one type named "${s}".`,{nodes:[o,i.name]}));else t.set(s,i.name);return!1}}function M6(e){return{OperationDefinition(t){let n=t.variableDefinitions??[],r=_m(n,(i)=>i.variable.name.value);for(let[i,s]of r)if(s.length>1)e.reportError(new ae(`There can be only one variable named "$${i}".`,{nodes:s.map((o)=>o.variable.name)}))}}}function L6(e){return{NullValue:(t)=>Iu(e,t,e.getInputType()),ListValue:(t)=>Iu(e,t,e.getParentInputType()),ObjectValue:(t)=>Iu(e,t,e.getInputType()),EnumValue:(t)=>Iu(e,t,e.getInputType()),IntValue:(t)=>Iu(e,t,e.getInputType()),FloatValue:(t)=>Iu(e,t,e.getInputType()),StringValue:(t)=>Iu(e,t,e.getInputType()),BooleanValue:(t)=>Iu(e,t,e.getInputType())}}function Iu(e,t,n){if(n)hd(t,n,(r)=>{e.reportError(r)},void 0,void 0,e.hideSuggestions);return!1}function q6(e){return{VariableDefinition(t){let n=Mr(e.getSchema(),t.type);if(n!==void 0&&!Tu(n)){let r=t.variable.name.value,i=hn(t.type);e.reportError(new ae(`Variable "$${r}" cannot be non-input type "${i}".`,{nodes:t.type}))}}}}function U6(e){let t;return{OperationDefinition:{enter(){t=new Map},leave(n){let r=e.getRecursiveVariableUsages(n);for(let{node:i,type:s,parentType:o,defaultValue:a,fragmentVariableDefinition:l}of r){let c=i.name.value,u=l;if(u??=t.get(c),u&&s){let p=e.getSchema(),d=Mr(p,u.type);if(d&&!E0e(p,d,u.defaultValue,s,a))e.reportError(new ae(`Variable "$${c}" of type "${d}" used in position expecting type "${s}".`,{nodes:[u,i]}));if(en(o)&&o.isOneOf&&qN(d))e.reportError(new ae(`Variable "$${c}" is of type "${d}" but must be non-nullable to be used for OneOf Input Object "${o}".`,{nodes:[u,i]}))}}}},VariableDefinition(n){t.set(n.variable.name.value,n)}}}function E0e(e,t,n,r,i){if(Ft(r)&&!Ft(t)){if(!(n!=null&&n.kind!==Fr)&&i===void 0)return!1;let a=r.ofType;return Zl(e,t,a)}return Zl(e,t,r)}var k0e=Object.freeze([i6]),N0e=Object.freeze([WV,e6,j6,n6,N6,lO,YV,q6,_6,QV,R6,ZV,a6,h6,s6,M6,o6,l6,aO,vO,GV,zV,KV,O6,XV,bO,L6,b6,U6,d6,_O,...k0e]),B6=Object.freeze([r6,F6,C6,I6,A6,P6,$6,lO,aO,vO,g6,oO,bO,_O,mO]);class V6{constructor(e,t){this._ast=e,this._fragments=void 0,this._fragmentSpreads=new Map,this._recursivelyReferencedFragments=new Map,this._onError=t}get[Symbol.toStringTag](){return"ASTValidationContext"}reportError(e){this._onError(e)}getDocument(){return this._ast}getFragment(e){let t;if(this._fragments)t=this._fragments;else{t=Object.create(null);for(let n of this.getDocument().definitions)if(n.kind===Ql)t[n.name.value]=n;this._fragments=t}return t[e]}getFragmentSpreads(e){let t=this._fragmentSpreads.get(e);if(!t){t=[];let n=[e],r;while(r=n.pop())for(let i of r.selections)if(i.kind===hu)t.push(i);else if(i.selectionSet)n.push(i.selectionSet);this._fragmentSpreads.set(e,t)}return t}getRecursivelyReferencedFragments(e){let t=this._recursivelyReferencedFragments.get(e);if(!t){t=[];let n=new Set,r=[e.selectionSet],i;while(i=r.pop())for(let s of this.getFragmentSpreads(i)){let o=s.name.value;if(!n.has(o)){n.add(o);let a=this.getFragment(o);if(a)t.push(a),r.push(a.selectionSet)}}this._recursivelyReferencedFragments.set(e,t)}return t}}class xO extends V6{constructor(e,t,n){super(e,n);this._schema=t}get hideSuggestions(){return!1}get[Symbol.toStringTag](){return"SDLValidationContext"}getSchema(){return this._schema}}var Qrt=tl(yg,(e)=>e.filter((t)=>t!=="description")),Yrt=new ae("Too many validation errors, error limit reached. Validation aborted.");function O0e(e,t,n=B6){let r=[],i=new xO(e,t,(o)=>{r.push(o)}),s=n.map((o)=>o(i));return xg(e,AN(s)),r}function K6(e){let t=O0e(e);if(t.length!==0)throw Error(t.map((n)=>n.message).join(` +In some cases, you need to provide options to alter GraphQL's execution behavior in ways field arguments will not suffice, such as conditionally including or skipping a field. Directives provide this by describing additional information to the executor.`,fields:()=>({name:{type:new dt(Cn),resolve:(e)=>e.name},description:{type:Cn,resolve:(e)=>e.description},isRepeatable:{type:new dt(Er),resolve:(e)=>e.isRepeatable},locations:{type:new dt(new Sr(new dt(HN))),resolve:(e)=>e.locations},args:{type:new dt(new Sr(new dt(Ag))),args:{includeDeprecated:{type:new dt(Er),default:{value:!1}}},resolve(e,{includeDeprecated:t}){return t===!0?e.args:e.args.filter((n)=>n.deprecationReason==null)}},isDeprecated:{type:new dt(Er),resolve:(e)=>e.deprecationReason!=null},deprecationReason:{type:Cn,resolve:(e)=>e.deprecationReason}})}),HN=new rl({name:"__DirectiveLocation",description:"A Directive can be adjacent to many parts of the GraphQL language, a __DirectiveLocation describes one such possible adjacencies.",values:{QUERY:{value:et.QUERY,description:"Location adjacent to a query operation."},MUTATION:{value:et.MUTATION,description:"Location adjacent to a mutation operation."},SUBSCRIPTION:{value:et.SUBSCRIPTION,description:"Location adjacent to a subscription operation."},FIELD:{value:et.FIELD,description:"Location adjacent to a field."},FRAGMENT_DEFINITION:{value:et.FRAGMENT_DEFINITION,description:"Location adjacent to a fragment definition."},FRAGMENT_SPREAD:{value:et.FRAGMENT_SPREAD,description:"Location adjacent to a fragment spread."},INLINE_FRAGMENT:{value:et.INLINE_FRAGMENT,description:"Location adjacent to an inline fragment."},VARIABLE_DEFINITION:{value:et.VARIABLE_DEFINITION,description:"Location adjacent to an operation variable definition."},FRAGMENT_VARIABLE_DEFINITION:{value:et.FRAGMENT_VARIABLE_DEFINITION,description:"Location adjacent to a fragment variable definition."},SCHEMA:{value:et.SCHEMA,description:"Location adjacent to a schema definition."},SCALAR:{value:et.SCALAR,description:"Location adjacent to a scalar definition."},OBJECT:{value:et.OBJECT,description:"Location adjacent to an object type definition."},FIELD_DEFINITION:{value:et.FIELD_DEFINITION,description:"Location adjacent to a field definition."},ARGUMENT_DEFINITION:{value:et.ARGUMENT_DEFINITION,description:"Location adjacent to an argument definition."},INTERFACE:{value:et.INTERFACE,description:"Location adjacent to an interface definition."},UNION:{value:et.UNION,description:"Location adjacent to a union definition."},ENUM:{value:et.ENUM,description:"Location adjacent to an enum definition."},ENUM_VALUE:{value:et.ENUM_VALUE,description:"Location adjacent to an enum value definition."},INPUT_OBJECT:{value:et.INPUT_OBJECT,description:"Location adjacent to an input object type definition."},INPUT_FIELD_DEFINITION:{value:et.INPUT_FIELD_DEFINITION,description:"Location adjacent to an input object field definition."},DIRECTIVE_DEFINITION:{value:et.DIRECTIVE_DEFINITION,description:"Location adjacent to a directive definition."}}}),Ro=new Ds({name:"__Type",description:"The fundamental unit of any GraphQL Schema is the type. There are many kinds of types in GraphQL as represented by the `__TypeKind` enum.\n\nDepending on the kind of a type, certain fields describe information about that type. Scalar types provide no information beyond a name, description and optional `specifiedByURL`, while Enum types provide their values. Object and Interface types provide the fields they describe. Abstract types, Union and Interface, provide the Object types possible at runtime. List and NonNull types compose other types.",fields:()=>({kind:{type:new dt(QN),resolve(e){if($o(e))return di.SCALAR;if(Dn(e))return di.OBJECT;if(dn(e))return di.INTERFACE;if(Qr(e))return di.UNION;if(Mr(e))return di.ENUM;if(en(e))return di.INPUT_OBJECT;if(fn(e))return di.LIST;if(Ft(e))return di.NON_NULL;cn(!1,`Unexpected type: "${qe(e)}".`)}},name:{type:Cn,resolve:(e)=>("name"in e)?e.name:void 0},description:{type:Cn,resolve:(e)=>("description"in e)?e.description:void 0},specifiedByURL:{type:Cn,resolve:(e)=>("specifiedByURL"in e)?e.specifiedByURL:void 0},fields:{type:new Sr(new dt(zN)),args:{includeDeprecated:{type:new dt(Er),default:{value:!1}}},resolve(e,{includeDeprecated:t}){if(Dn(e)||dn(e)){let n=Object.values(e.getFields());return t===!0?n:n.filter((r)=>r.deprecationReason==null)}}},interfaces:{type:new Sr(new dt(Ro)),resolve(e){if(Dn(e)||dn(e))return e.getInterfaces()}},possibleTypes:{type:new Sr(new dt(Ro)),resolve(e,t,n,{schema:r}){if(Io(e))return r.getPossibleTypes(e)}},enumValues:{type:new Sr(new dt(WN)),args:{includeDeprecated:{type:new dt(Er),default:{value:!1}}},resolve(e,{includeDeprecated:t}){if(Mr(e)){let n=e.getValues();return t===!0?n:n.filter((r)=>r.deprecationReason==null)}}},inputFields:{type:new Sr(new dt(Ag)),args:{includeDeprecated:{type:new dt(Er),default:{value:!1}}},resolve(e,{includeDeprecated:t}){if(en(e)){let n=Object.values(e.getFields());return t===!0?n:n.filter((r)=>r.deprecationReason==null)}}},ofType:{type:Ro,resolve:(e)=>("ofType"in e)?e.ofType:void 0},isOneOf:{type:Er,resolve:(e)=>{if(en(e))return e.isOneOf}}})}),zN=new Ds({name:"__Field",description:"Object and Interface types are described by a list of Fields, each of which has a name, potentially a list of arguments, and a return type.",fields:()=>({name:{type:new dt(Cn),resolve:(e)=>e.name},description:{type:Cn,resolve:(e)=>e.description},args:{type:new dt(new Sr(new dt(Ag))),args:{includeDeprecated:{type:new dt(Er),default:{value:!1}}},resolve(e,{includeDeprecated:t}){return t===!0?e.args:e.args.filter((n)=>n.deprecationReason==null)}},type:{type:new dt(Ro),resolve:(e)=>e.type},isDeprecated:{type:new dt(Er),resolve:(e)=>e.deprecationReason!=null},deprecationReason:{type:Cn,resolve:(e)=>e.deprecationReason}})}),Ag=new Ds({name:"__InputValue",description:"Arguments provided to Fields or Directives and the input fields of an InputObject are represented as Input Values which describe their type and optionally a default value.",fields:()=>({name:{type:new dt(Cn),resolve:(e)=>e.name},description:{type:Cn,resolve:(e)=>e.description},type:{type:new dt(Ro),resolve:(e)=>e.type},defaultValue:{type:Cn,description:"A GraphQL-formatted string representing the default value for this input value.",resolve(e){let t=EV(e);if(t)return hn(t);return null}},isDeprecated:{type:new dt(Er),resolve:(e)=>e.deprecationReason!=null},deprecationReason:{type:Cn,resolve:(e)=>e.deprecationReason}})}),WN=new Ds({name:"__EnumValue",description:"One possible value for a given Enum. Enum values are unique values, not a placeholder for a string or numeric value. However an Enum value is returned in a JSON response as a string.",fields:()=>({name:{type:new dt(Cn),resolve:(e)=>e.name},description:{type:Cn,resolve:(e)=>e.description},isDeprecated:{type:new dt(Er),resolve:(e)=>e.deprecationReason!=null},deprecationReason:{type:Cn,resolve:(e)=>e.deprecationReason}})}),di={SCALAR:"SCALAR",OBJECT:"OBJECT",INTERFACE:"INTERFACE",UNION:"UNION",ENUM:"ENUM",INPUT_OBJECT:"INPUT_OBJECT",LIST:"LIST",NON_NULL:"NON_NULL"},QN=new rl({name:"__TypeKind",description:"An enum describing what kind of type a given `__Type` is.",values:{SCALAR:{value:di.SCALAR,description:"Indicates this type is a scalar."},OBJECT:{value:di.OBJECT,description:"Indicates this type is an object. `fields` and `interfaces` are valid fields."},INTERFACE:{value:di.INTERFACE,description:"Indicates this type is an interface. `fields`, `interfaces`, and `possibleTypes` are valid fields."},UNION:{value:di.UNION,description:"Indicates this type is a union. `possibleTypes` is a valid field."},ENUM:{value:di.ENUM,description:"Indicates this type is an enum. `enumValues` is a valid field."},INPUT_OBJECT:{value:di.INPUT_OBJECT,description:"Indicates this type is an input object. `inputFields` is a valid field."},LIST:{value:di.LIST,description:"Indicates this type is a list. `ofType` is a valid field."},NON_NULL:{value:di.NON_NULL,description:"Indicates this type is a non-null. `ofType` is a valid field."}}}),L0=new hm(void 0,"__schema",{type:new dt(Ig),description:"Access the current type schema of this server.",resolve:(e,t,n,{schema:r})=>r}),q0=new hm(void 0,"__type",{type:Ro,description:"Request the type information of a single type.",args:{name:{type:new dt(Cn)}},resolve:(e,{name:t},n,{schema:r})=>r.getType(t)}),U0=new hm(void 0,"__typename",{type:new dt(Cn),description:"The name of the current Object type at runtime.",resolve:(e,t,n,{parentType:r})=>r.name}),Pu=Object.freeze([Ig,GN,HN,Ro,zN,Ag,WN,QN]);function Rg(e){return Pu.some(({name:t})=>e.name===t)}function kV(e){return ui(e,NV,jg)}function YN(e){if(!kV(e))throw Error(`Expected ${qe(e)} to be a GraphQL schema.`);return e}var NV=Symbol("Schema");class jg{constructor(e){this.__kind=NV,this.assumeValid=e.assumeValid??!1,this.__validationErrors=e.assumeValid===!0?[]:void 0,this.description=e.description,this.extensions=Yi(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=e.extensionASTNodes??[],this._queryType=e.query,this._mutationType=e.mutation,this._subscriptionType=e.subscription,this._directives=e.directives??Ts;let t=new Set(e.types);if(e.types!=null)for(let n of e.types)t.delete(n),Da(n,t);if(this._queryType!=null)Da(this._queryType,t);if(this._mutationType!=null)Da(this._mutationType,t);if(this._subscriptionType!=null)Da(this._subscriptionType,t);for(let n of this._directives)if($g(n))for(let r of n.args)Da(r.type,t);Da(Ig,t),this._typeMap=Object.create(null),this._subTypeMap=new Map,this._implementationsMap=Object.create(null);for(let n of t){if(n==null)continue;let r=n.name;if(this._typeMap[r]!==void 0)throw Error(`Schema must contain uniquely named types but contains multiple types named "${r}".`);if(this._typeMap[r]=n,dn(n)){for(let i of n.getInterfaces())if(dn(i)){let s=this._implementationsMap[i.name];s??=this._implementationsMap[i.name]={objects:[],interfaces:[]},s.interfaces.push(n)}}else if(Dn(n)){for(let i of n.getInterfaces())if(dn(i)){let s=this._implementationsMap[i.name];s??=this._implementationsMap[i.name]={objects:[],interfaces:[]},s.objects.push(n)}}}}get[Symbol.toStringTag](){return"GraphQLSchema"}getQueryType(){return this._queryType}getMutationType(){return this._mutationType}getSubscriptionType(){return this._subscriptionType}getRootType(e){switch(e){case Fr.QUERY:return this.getQueryType();case Fr.MUTATION:return this.getMutationType();case Fr.SUBSCRIPTION:return this.getSubscriptionType()}}getTypeMap(){return this._typeMap}getType(e){return this.getTypeMap()[e]}getPossibleTypes(e){return Qr(e)?e.getTypes():this.getImplementations(e).objects}getImplementations(e){return this._implementationsMap[e.name]??{objects:[],interfaces:[]}}isSubType(e,t){let n=this._subTypeMap.get(e);if(n===void 0){if(Qr(e))n=new Set(e.getTypes());else{let r=this.getImplementations(e);n=new Set([...r.objects,...r.interfaces])}this._subTypeMap.set(e,n)}return n.has(t)}getDirectives(){return this._directives}getDirective(e){return this.getDirectives().find((t)=>t.name===e)}getField(e,t){switch(t){case L0.name:return this.getQueryType()===e?L0:void 0;case q0.name:return this.getQueryType()===e?q0:void 0;case U0.name:return U0}if("getFields"in e)return e.getFields()[t];return}toConfig(){return{description:this.description,query:this.getQueryType(),mutation:this.getMutationType(),subscription:this.getSubscriptionType(),types:Object.values(this.getTypeMap()),directives:this.getDirectives(),extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes,assumeValid:this.assumeValid}}}function Da(e,t){let n=_a(e);if(!t.has(n)){if(t.add(n),Qr(n))for(let r of n.getTypes())Da(r,t);else if(Dn(n)||dn(n)){for(let r of n.getInterfaces())Da(r,t);for(let r of Object.values(n.getFields())){Da(r.type,t);for(let i of r.args)Da(i.type,t)}}else if(en(n))for(let r of Object.values(n.getFields()))Da(r.type,t)}return t}function B0(e){if(YN(e),e.__validationErrors)return e.__validationErrors;let t=new AV(e);Fxe(t),Cxe(t),Mxe(t);let n=t.getErrors();return e.__validationErrors=n,n}class AV{constructor(e){this._errors=[],this.schema=e}reportError(e,t){let n=Array.isArray(t)?t.filter(Boolean):t;this._errors.push(new ae(e,{nodes:n}))}getErrors(){return this._errors}}function Fxe(e){let t=e.schema;if(t.getQueryType()==null)e.reportError("Query root type must be provided.",t.astNode);let n=new Wi;for(let r of Object.values(Fr)){let i=t.getRootType(r);if(i!=null)if(!Dn(i)){let s=F8(r),o=qe(i);e.reportError(r===Fr.QUERY?`${s} root type must be Object type, it cannot be ${o}.`:`${s} root type must be Object type if provided, it cannot be ${o}.`,OV(t,r)??i.astNode)}else n.add(i,r)}for(let[r,i]of n)if(i.length>1){let s=M8(i);e.reportError(`All root types must be different, "${r}" type is used as ${s} root types.`,i.map((o)=>OV(t,o)))}}function OV(e,t){return[e.astNode,...e.extensionASTNodes].flatMap((n)=>n?.operationTypes??[]).find((n)=>n.operation===t)?.type}function Cxe(e){for(let t of e.schema.getDirectives()){if(!$g(t)){e.reportError(`Expected directive but got: ${qe(t)}.`,t?.astNode);continue}if(wd(e,t),t.locations.length===0)e.reportError(`Directive ${t} must include 1 or more locations.`,t.astNode);for(let n of t.args){if(wd(e,n),!Su(n.type))e.reportError(`The type of ${n} must be Input Type but got: ${qe(n.type)}.`,n.astNode);if(xa(n)&&n.deprecationReason!=null)e.reportError(`Required argument ${n} cannot be deprecated.`,[V0(n.astNode),n.astNode?.type]);XN(e,n)}}}function XN(e,t){let n=t.default;if(!n)return;let r=[];if(ZN(n,t.type,(i,s)=>{r.push([i,s])}),r.length===0)return;if(!n.literal)try{let i=Fg(n.value,t.type),s=[];if(Og(i,t.type,(o,a)=>{s.push([o,a])}),s.length===0){e.reportError(`${t} has invalid default value: ${qe(n.value)}. Did you mean: ${qe(i)}?`,t.astNode?.defaultValue);return}}catch(i){}for(let[i,s]of r)e.reportError(`${t} has invalid default value${fg(s)}: ${i.message}`,i.nodes??t.astNode?.defaultValue)}function ZN(e,t,n,r){if(e.literal){bd(e.literal,t,n,void 0,void 0,r);return}Og(e.value,t,n,r)}function Fg(e,t){if(Ft(t))return Fg(e,t.ofType);if(e===null)return null;if(fn(t)){if(So(e))return Array.from(e,(n)=>Fg(n,t.ofType));return[Fg(e,t.ofType)]}if(en(t)){if(!jr(e))cn(!1);let n=t.getFields();return tl(e,(r,i)=>{if(!(i in n))cn(!1);return Fg(r,n[i].type)})}return va(t),t.coerceOutputValue(e)}function wd(e,t){if(t.name.startsWith("__"))e.reportError(`Name "${t.name}" must not begin with "__", which is reserved by GraphQL introspection.`,t.astNode)}function Mxe(e){let t=Hxe(e),n=e.schema.getTypeMap(),r=new Map;for(let s of Object.values(n)){if(!UN(s)){e.reportError(`Expected GraphQL named type but got: ${qe(s)}.`,s.astNode);continue}if(!Rg(s))wd(e,s);if(Dn(s))PV(e,s),$V(e,s);else if(dn(s))PV(e,s),$V(e,s);else if(Qr(s))Uxe(e,s);else if(Mr(s))Bxe(e,s);else if(en(s))Vxe(e,s),i(s),t(s)}Jxe(e,r);function i(s){r.set(s,{inputObj:s,targets:[],dependents:[],unresolvedTargetCount:0,hasFiniteValue:!1})}}function PV(e,t){let n=Object.values(t.getFields());if(n.length===0)e.reportError(`Type ${t} must define one or more fields.`,[t.astNode,...t.extensionASTNodes]);for(let r of n){if(wd(e,r),!$0(r.type))e.reportError(`The type of ${r} must be Output Type but got: ${qe(r.type)}.`,r.astNode?.type);for(let i of r.args){if(wd(e,i),!Su(i.type))e.reportError(`The type of ${i} must be Input Type but got: ${qe(i.type)}.`,i.astNode?.type);if(xa(i)&&i.deprecationReason!=null)e.reportError(`Required argument ${i} cannot be deprecated.`,[V0(i.astNode),i.astNode?.type]);XN(e,i)}}}function $V(e,t){let n=new Set;for(let r of t.getInterfaces()){if(!dn(r)){e.reportError(`Type ${t} must only implement Interface types, it cannot implement ${qe(r)}.`,Cg(t,r));continue}if(t===r){e.reportError(`Type ${t} cannot implement itself because it would create a circular reference.`,Cg(t,r));continue}if(n.has(r.name)){e.reportError(`Type ${t} can only implement ${r} once.`,Cg(t,r));continue}n.add(r.name),qxe(e,t,r),Lxe(e,t,r)}}function Lxe(e,t,n){let r=t.getFields();for(let i of Object.values(n.getFields())){let s=r[i.name];if(s==null){e.reportError(`Interface field ${i} expected but ${t} does not provide it.`,[i.astNode,t.astNode,...t.extensionASTNodes]);continue}if(!Zl(e.schema,s.type,i.type))e.reportError(`Interface field ${i} expects type ${i.type} but ${s} is type ${s.type}.`,[i.astNode?.type,s.astNode?.type]);for(let o of i.args){let a=s.args.find((l)=>l.name===o.name);if(!a){e.reportError(`Interface field argument ${o} expected but ${s} does not provide it.`,[o.astNode,s.astNode]);continue}if(!Sg(o.type,a.type))e.reportError(`Interface field argument ${o} expects type ${o.type} but ${a} is type ${a.type}.`,[o.astNode?.type,a.astNode?.type])}for(let o of s.args)if(xa(o)){if(!i.args.find((l)=>l.name===o.name))e.reportError(`Argument "${o}" must not be required type "${o.type}" if not provided by the Interface field "${i}".`,[o.astNode,i.astNode])}if(s.deprecationReason!=null&&i.deprecationReason==null)e.reportError(`Interface field ${n.name}.${i.name} is not deprecated, so implementation field ${t.name}.${s.name} must not be deprecated.`,[V0(s.astNode),s.astNode?.type])}}function qxe(e,t,n){let r=t.getInterfaces();for(let i of n.getInterfaces())if(!r.includes(i))e.reportError(i===t?`Type ${t} cannot implement ${n} because it would create a circular reference.`:`Type ${t} must implement ${i} because it is implemented by ${n}.`,[...Cg(n,i),...Cg(t,n)])}function Uxe(e,t){let n=t.getTypes();if(n.length===0)e.reportError(`Union type ${t} must define one or more member types.`,[t.astNode,...t.extensionASTNodes]);let r=new Set;for(let i of n){if(r.has(i.name)){e.reportError(`Union type ${t} can only include type ${i} once.`,IV(t,i.name));continue}if(r.add(i.name),!Dn(i))e.reportError(`Union type ${t} can only include Object types, it cannot include ${qe(i)}.`,IV(t,String(i)))}}function Bxe(e,t){let n=t.getValues();if(n.length===0)e.reportError(`Enum type ${t} must define one or more values.`,[t.astNode,...t.extensionASTNodes]);for(let r of n)wd(e,r)}function Vxe(e,t){let n=Object.values(t.getFields());if(n.length===0)e.reportError(`Input Object type ${t} must define one or more fields.`,[t.astNode,...t.extensionASTNodes]);for(let r of n){if(wd(e,r),!Su(r.type))e.reportError(`The type of ${r} must be Input Type but got: ${qe(r.type)}.`,r.astNode?.type);if(Ao(r)&&r.deprecationReason!=null)e.reportError(`Required input field ${r} cannot be deprecated.`,[V0(r.astNode),r.astNode?.type]);if(XN(e,r),t.isOneOf)Kxe(t,r,e)}}function Kxe(e,t,n){if(Ft(t.type))n.reportError(`OneOf input field ${e}.${t.name} must be nullable.`,t.astNode?.type);if(t.default!==void 0||t.defaultValue!==void 0)n.reportError(`OneOf input field ${e}.${t.name} cannot have a default value.`,t.astNode)}function Jxe(e,t){let n=[];for(let c of t.values()){let u=c.inputObj,p=Object.values(u.getFields());for(let d of p){let f=Gxe(u,d.type);if(f===void 0)continue;c.targets.push({field:d,target:f});let m=t.get(f);if(m!==void 0)m.dependents.push(c)}if(u.isOneOf){if(p.length===0||c.targets.lengthb.fieldStr).join(", ");e.reportError(`Input Object ${d} cannot be provided a finite value because it references itself through fields: ${h}.`,y.map((b)=>b.astNode))}s.pop()}o.delete(u)}}function Gxe(e,t){if(e.isOneOf){if(en(t))return t;return}if(Ft(t)&&en(t.ofType))return t.ofType}function Hxe(e){let t=Object.create(null),n=[],r=Object.create(null);return function(l){return i(l,Object.create(null))};function i(a,l){if(So(l)){for(let c of l)i(a,c);return}else if(!jr(l))return;for(let c of Object.values(a.getFields())){let u=_a(c.type);if(!en(u))continue;if(Object.hasOwn(l,c.name))i(u,l[c.name]);else o(c,u,`${a}.${c.name}`)}}function s(a,l){if(l.kind===ko){for(let u of l.values)s(a,u);return}else if(l.kind!==No)return;let c=um(l.fields,(u)=>u.name.value);for(let u of Object.values(a.getFields())){let p=_a(u.type);if(!en(p))continue;if(Object.hasOwn(c,u.name))s(p,c[u.name].value);else o(u,p,`${a}.${u.name}`)}}function o(a,l,c){let u=a.default;if(u===void 0)return;let p=r[c];if(p!==void 0){e.reportError(`Invalid circular reference. The default value of Input Object field ${c} references itself${pd).join(", ")}`:""}.`,n.slice(p-1).map(([,d])=>d));return}if(t[c]===void 0){if(t[c]=!0,r[c]=n.push([c,a.astNode?.defaultValue]),u.literal)s(l,u.literal);else i(l,u.value);n.pop(),r[c]=void 0}}}function Cg(e,t){let{astNode:n,extensionASTNodes:r}=e;return(n!=null?[n,...r]:r).flatMap((s)=>s.interfaces??[]).filter((s)=>s.name.value===t.name)}function IV(e,t){let{astNode:n,extensionASTNodes:r}=e;return(n!=null?[n,...r]:r).flatMap((s)=>s.types??[]).filter((s)=>s.name.value===t)}function V0(e){return e?.directives?.find((t)=>t.name.value===vm.name)}function tr(e,t,n){return new ae(`Syntax Error: ${n}`,{source:e,positions:[t]})}function zxe(){let e;try{let t=globalThis.process;if(typeof t?.getBuiltinModule==="function")e=t.getBuiltinModule("node:diagnostics_channel")}catch{}return e}var Dd=zxe(),eO=Dd?.tracingChannel("graphql:parse"),YXe=Dd?.tracingChannel("graphql:validate"),XXe=Dd?.tracingChannel("graphql:execute"),ZXe=Dd?.tracingChannel("graphql:execute:variableCoercion"),eZe=Dd?.tracingChannel("graphql:execute:rootSelectionSet"),tZe=Dd?.tracingChannel("graphql:subscribe"),nZe=Dd?.tracingChannel("graphql:resolve"),Wxe=["start","end","asyncStart","asyncEnd","error"];function RV(e){if(e==null)return!1;let t=e.hasSubscribers;if(t!==void 0)return t;for(let n of Wxe)if(e[n].hasSubscribers)return!0;return!1}var we={SOF:"",EOF:"",BANG:"!",DOLLAR:"$",AMP:"&",PAREN_L:"(",PAREN_R:")",DOT:".",SPREAD:"...",COLON:":",EQUALS:"=",AT:"@",BRACKET_L:"[",BRACKET_R:"]",BRACE_L:"{",PIPE:"|",BRACE_R:"}",NAME:"Name",INT:"Int",FLOAT:"Float",STRING:"String",BLOCK_STRING:"BlockString",COMMENT:"Comment"};class J0{constructor(e){let t=new mg(we.SOF,0,0,0,0);this.source=e,this.lastToken=t,this.token=t,this.line=1,this.lineStart=0}get[Symbol.toStringTag](){return"Lexer"}advance(){return this.lastToken=this.token,this.token=this.lookahead()}lookahead(){let e=this.token;if(e.kind!==we.EOF)do if(e.next)e=e.next;else{let t=Qxe(this,e.end);e.next=t,t.prev=e,e=t}while(e.kind===we.COMMENT);return e}}function FV(e){return e===we.BANG||e===we.DOLLAR||e===we.AMP||e===we.PAREN_L||e===we.PAREN_R||e===we.DOT||e===we.SPREAD||e===we.COLON||e===we.EQUALS||e===we.AT||e===we.BRACKET_L||e===we.BRACKET_R||e===we.BRACE_L||e===we.PIPE||e===we.BRACE_R}function _m(e){return e>=0&&e<=55295||e>=57344&&e<=1114111}function G0(e,t){return CV(e.charCodeAt(t))&&MV(e.charCodeAt(t+1))}function CV(e){return e>=55296&&e<=56319}function MV(e){return e>=56320&&e<=57343}function Td(e,t){let n=e.source.body.codePointAt(t);if(n===void 0)return we.EOF;else if(n>=32&&n<=126){let r=String.fromCodePoint(n);return r==='"'?`'"'`:`"${r}"`}return"U+"+n.toString(16).toUpperCase().padStart(4,"0")}function kr(e,t,n,r,i){let s=e.line,o=1+n-e.lineStart;return new mg(t,n,r,s,o,i)}function Qxe(e,t){let n=e.source.body,r=n.length,i=t;while(i=48&&e<=57?e-48:e>=65&&e<=70?e-55:e>=97&&e<=102?e-87:-1}function n0e(e,t){let n=e.source.body;switch(n.charCodeAt(t+1)){case 34:return{value:'"',size:2};case 92:return{value:"\\",size:2};case 47:return{value:"/",size:2};case 98:return{value:"\b",size:2};case 102:return{value:"\f",size:2};case 110:return{value:` +`,size:2};case 114:return{value:"\r",size:2};case 116:return{value:"\t",size:2}}throw tr(e.source,t,`Invalid character escape sequence: "${n.slice(t,t+2)}".`)}function r0e(e,t){let n=e.source.body,r=n.length,i=e.lineStart,s=t+3,o=s,a="",l=[];while(s0))Oo(!1,"line in locationOffset is 1-indexed and must be positive.");if(!(this.locationOffset.column>0))Oo(!1,"column in locationOffset is 1-indexed and must be positive.")}get[Symbol.toStringTag](){return"Source"}}function qV(e){return ui(e,LV,Lg)}function z0(e,t){return RV(eO)?eO.traceSync(()=>UV(e,t),{source:e}):UV(e,t)}function UV(e,t){let n=new BV(e,t),r=n.parseDocument();return Object.defineProperty(r,"tokenCount",{enumerable:!1,value:n.tokenCount}),r}class BV{constructor(e,t={}){let{lexer:n,...r}=t;if(n)this._lexer=n;else{let i=qV(e)?e:new Lg(e);this._lexer=new J0(i)}this._options=r,this._tokenCounter=0}get tokenCount(){return this._tokenCounter}parseName(){let e=this.expectToken(we.NAME);return this.node(e,{kind:hg,value:e.value})}parseDocument(){return this.node(this._lexer.token,{kind:q8,definitions:this.many(we.SOF,this.parseDefinition,we.EOF)})}parseDefinition(){if(this.peek(we.BRACE_L))return this.parseOperationDefinition();let e=this.peekDescription(),t=e?this._lexer.lookahead():this._lexer.token;if(e&&t.kind===we.BRACE_L)throw tr(this._lexer.source,this._lexer.token.start,"Unexpected description, descriptions are not supported on shorthand queries.");if(t.kind===we.NAME){switch(t.value){case"schema":return this.parseSchemaDefinition();case"scalar":return this.parseScalarTypeDefinition();case"type":return this.parseObjectTypeDefinition();case"interface":return this.parseInterfaceTypeDefinition();case"union":return this.parseUnionTypeDefinition();case"enum":return this.parseEnumTypeDefinition();case"input":return this.parseInputObjectTypeDefinition();case"directive":return this.parseDirectiveDefinition()}switch(t.value){case"query":case"mutation":case"subscription":return this.parseOperationDefinition();case"fragment":return this.parseFragmentDefinition()}if(e)throw tr(this._lexer.source,this._lexer.token.start,"Unexpected description, only GraphQL definitions support descriptions.");switch(t.value){case"extend":return this.parseTypeSystemExtension()}}throw this.unexpected(t)}parseOperationDefinition(){let e=this._lexer.token;if(this.peek(we.BRACE_L))return this.node(e,{kind:nd,operation:Fr.QUERY,description:void 0,name:void 0,variableDefinitions:void 0,directives:void 0,selectionSet:this.parseSelectionSet()});let t=this.parseDescription(),n=this.parseOperationType(),r;if(this.peek(we.NAME))r=this.parseName();return this.node(e,{kind:nd,operation:n,description:t,name:r,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseOperationType(){let e=this.expectToken(we.NAME);switch(e.value){case"query":return Fr.QUERY;case"mutation":return Fr.MUTATION;case"subscription":return Fr.SUBSCRIPTION}throw this.unexpected(e)}parseVariableDefinitions(){return this.optionalMany(we.PAREN_L,this.parseVariableDefinition,we.PAREN_R)}parseVariableDefinition(){return this.node(this._lexer.token,{kind:EN,description:this.parseDescription(),variable:this.parseVariable(),type:(this.expectToken(we.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(we.EQUALS)?this.parseConstValueLiteral():void 0,directives:this.parseConstDirectives()})}parseVariable(){let e=this._lexer.token;return this.expectToken(we.DOLLAR),this.node(e,{kind:xs,name:this.parseName()})}parseSelectionSet(){return this.node(this._lexer.token,{kind:U8,selections:this.many(we.BRACE_L,this.parseSelection,we.BRACE_R)})}parseSelection(){return this.peek(we.SPREAD)?this.parseFragment():this.parseField()}parseField(){let e=this._lexer.token,t=this.parseName(),n,r;if(this.expectOptionalToken(we.COLON))n=t,r=this.parseName();else r=t;return this.node(e,{kind:pm,alias:n,name:r,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(we.BRACE_L)?this.parseSelectionSet():void 0})}parseArguments(e){let t=e?this.parseConstArgument:this.parseArgument;return this.optionalMany(we.PAREN_L,t,we.PAREN_R)}parseFragmentArguments(){let e=this.parseFragmentArgument;return this.optionalMany(we.PAREN_L,e,we.PAREN_R)}parseArgument(e=!1){let t=this._lexer.token,n=this.parseName();return this.expectToken(we.COLON),this.node(t,{kind:B8,name:n,value:this.parseValueLiteral(e)})}parseConstArgument(){return this.parseArgument(!0)}parseFragmentArgument(){let e=this._lexer.token,t=this.parseName();return this.expectToken(we.COLON),this.node(e,{kind:V8,name:t,value:this.parseValueLiteral(!1)})}parseFragment(){let e=this._lexer.token;this.expectToken(we.SPREAD);let t=this.expectOptionalKeyword("on");if(!t&&this.peek(we.NAME)){let n=this.parseFragmentName();if(this.peek(we.PAREN_L)&&this._options.experimentalFragmentArguments)return this.node(e,{kind:gu,name:n,arguments:this.parseFragmentArguments(),directives:this.parseDirectives(!1)});return this.node(e,{kind:gu,name:n,directives:this.parseDirectives(!1)})}return this.node(e,{kind:gg,typeCondition:t?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentDefinition(){let e=this._lexer.token,t=this.parseDescription();if(this.expectKeyword("fragment"),this._options.experimentalFragmentArguments===!0)return this.node(e,{kind:Ql,description:t,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()});return this.node(e,{kind:Ql,description:t,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentName(){if(this._lexer.token.value==="on")throw this.unexpected();return this.parseName()}parseValueLiteral(e){let t=this._lexer.token;switch(t.kind){case we.BRACKET_L:return this.parseList(e);case we.BRACE_L:return this.parseObject(e);case we.INT:return this.advanceLexer(),this.node(t,{kind:pi,value:t.value});case we.FLOAT:return this.advanceLexer(),this.node(t,{kind:bu,value:t.value});case we.STRING:case we.BLOCK_STRING:return this.parseStringLiteral();case we.NAME:switch(this.advanceLexer(),t.value){case"true":return this.node(t,{kind:Eo,value:!0});case"false":return this.node(t,{kind:Eo,value:!1});case"null":return this.node(t,{kind:Cr});default:return this.node(t,{kind:rd,value:t.value})}case we.DOLLAR:if(e)if(this.expectToken(we.DOLLAR),this._lexer.token.kind===we.NAME){let n=this._lexer.token.value;throw tr(this._lexer.source,t.start,`Unexpected variable "$${n}" in constant value.`)}else throw this.unexpected(t);return this.parseVariable();default:throw this.unexpected()}}parseConstValueLiteral(){return this.parseValueLiteral(!0)}parseStringLiteral(){let e=this._lexer.token;return this.advanceLexer(),this.node(e,{kind:ba,value:e.value,block:e.kind===we.BLOCK_STRING})}parseList(e){let t=()=>this.parseValueLiteral(e);return this.node(this._lexer.token,{kind:ko,values:this.any(we.BRACKET_L,t,we.BRACKET_R)})}parseObject(e){let t=()=>this.parseObjectField(e);return this.node(this._lexer.token,{kind:No,fields:this.any(we.BRACE_L,t,we.BRACE_R)})}parseObjectField(e){let t=this._lexer.token,n=this.parseName();return this.expectToken(we.COLON),this.node(t,{kind:bg,name:n,value:this.parseValueLiteral(e)})}parseDirectives(e){let t=[];while(this.peek(we.AT))t.push(this.parseDirective(e));if(t.length)return t;return}parseConstDirectives(){return this.parseDirectives(!0)}parseDirective(e){let t=this._lexer.token;return this.expectToken(we.AT),this.node(t,{kind:K8,name:this.parseName(),arguments:this.parseArguments(e)})}parseTypeReference(){let e=this._lexer.token,t;if(this.expectOptionalToken(we.BRACKET_L)){let n=this.parseTypeReference();this.expectToken(we.BRACKET_R),t=this.node(e,{kind:S0,type:n})}else t=this.parseNamedType();if(this.expectOptionalToken(we.BANG))return this.node(e,{kind:vg,type:t});return t}parseNamedType(){return this.node(this._lexer.token,{kind:kN,name:this.parseName()})}peekDescription(){return this.peek(we.STRING)||this.peek(we.BLOCK_STRING)}parseDescription(){if(this.peekDescription())return this.parseStringLiteral()}parseSchemaDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("schema");let n=this.parseConstDirectives(),r=this.many(we.BRACE_L,this.parseOperationTypeDefinition,we.BRACE_R);return this.node(e,{kind:id,description:t,directives:n,operationTypes:r})}parseOperationTypeDefinition(){let e=this._lexer.token,t=this.parseOperationType();this.expectToken(we.COLON);let n=this.parseNamedType();return this.node(e,{kind:J8,operation:t,type:n})}parseScalarTypeDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("scalar");let n=this.parseName(),r=this.parseConstDirectives();return this.node(e,{kind:sd,description:t,name:n,directives:r})}parseObjectTypeDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("type");let n=this.parseName(),r=this.parseImplementsInterfaces(),i=this.parseConstDirectives(),s=this.parseFieldsDefinition();return this.node(e,{kind:od,description:t,name:n,interfaces:r,directives:i,fields:s})}parseImplementsInterfaces(){return this.expectOptionalKeyword("implements")?this.delimitedMany(we.AMP,this.parseNamedType):void 0}parseFieldsDefinition(){return this.optionalMany(we.BRACE_L,this.parseFieldDefinition,we.BRACE_R)}parseFieldDefinition(){let e=this._lexer.token,t=this.parseDescription(),n=this.parseName(),r=this.parseArgumentDefs();this.expectToken(we.COLON);let i=this.parseTypeReference(),s=this.parseConstDirectives();return this.node(e,{kind:NN,description:t,name:n,arguments:r,type:i,directives:s})}parseArgumentDefs(){return this.optionalMany(we.PAREN_L,this.parseInputValueDef,we.PAREN_R)}parseInputValueDef(){let e=this._lexer.token,t=this.parseDescription(),n=this.parseName();this.expectToken(we.COLON);let r=this.parseTypeReference(),i;if(this.expectOptionalToken(we.EQUALS))i=this.parseConstValueLiteral();let s=this.parseConstDirectives();return this.node(e,{kind:ON,description:t,name:n,type:r,defaultValue:i,directives:s})}parseInterfaceTypeDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("interface");let n=this.parseName(),r=this.parseImplementsInterfaces(),i=this.parseConstDirectives(),s=this.parseFieldsDefinition();return this.node(e,{kind:ad,description:t,name:n,interfaces:r,directives:i,fields:s})}parseUnionTypeDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("union");let n=this.parseName(),r=this.parseConstDirectives(),i=this.parseUnionMemberTypes();return this.node(e,{kind:ld,description:t,name:n,directives:r,types:i})}parseUnionMemberTypes(){return this.expectOptionalToken(we.EQUALS)?this.delimitedMany(we.PIPE,this.parseNamedType):void 0}parseEnumTypeDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("enum");let n=this.parseName(),r=this.parseConstDirectives(),i=this.parseEnumValuesDefinition();return this.node(e,{kind:cd,description:t,name:n,directives:r,values:i})}parseEnumValuesDefinition(){return this.optionalMany(we.BRACE_L,this.parseEnumValueDefinition,we.BRACE_R)}parseEnumValueDefinition(){let e=this._lexer.token,t=this.parseDescription(),n=this.parseEnumValueName(),r=this.parseConstDirectives();return this.node(e,{kind:PN,description:t,name:n,directives:r})}parseEnumValueName(){if(this._lexer.token.value==="true"||this._lexer.token.value==="false"||this._lexer.token.value==="null")throw tr(this._lexer.source,this._lexer.token.start,`${H0(this._lexer.token)} is reserved and cannot be used for an enum value.`);return this.parseName()}parseInputObjectTypeDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("input");let n=this.parseName(),r=this.parseConstDirectives(),i=this.parseInputFieldsDefinition();return this.node(e,{kind:vu,description:t,name:n,directives:r,fields:i})}parseInputFieldsDefinition(){return this.optionalMany(we.BRACE_L,this.parseInputValueDef,we.BRACE_R)}parseTypeSystemExtension(){let e=this._lexer.lookahead();if(e.kind===we.NAME)switch(e.value){case"schema":return this.parseSchemaExtension();case"scalar":return this.parseScalarTypeExtension();case"type":return this.parseObjectTypeExtension();case"interface":return this.parseInterfaceTypeExtension();case"union":return this.parseUnionTypeExtension();case"enum":return this.parseEnumTypeExtension();case"input":return this.parseInputObjectTypeExtension();case"directive":return this.parseDirectiveExtension()}throw this.unexpected(e)}parseSchemaExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");let t=this.parseConstDirectives(),n=this.optionalMany(we.BRACE_L,this.parseOperationTypeDefinition,we.BRACE_R);if(t===void 0&&n===void 0)throw this.unexpected();return this.node(e,{kind:ud,directives:t,operationTypes:n})}parseScalarTypeExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");let t=this.parseName(),n=this.parseConstDirectives();if(n===void 0)throw this.unexpected();return this.node(e,{kind:_u,name:t,directives:n})}parseObjectTypeExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");let t=this.parseName(),n=this.parseImplementsInterfaces(),r=this.parseConstDirectives(),i=this.parseFieldsDefinition();if(n===void 0&&r===void 0&&i===void 0)throw this.unexpected();return this.node(e,{kind:xu,name:t,interfaces:n,directives:r,fields:i})}parseInterfaceTypeExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");let t=this.parseName(),n=this.parseImplementsInterfaces(),r=this.parseConstDirectives(),i=this.parseFieldsDefinition();if(n===void 0&&r===void 0&&i===void 0)throw this.unexpected();return this.node(e,{kind:wu,name:t,interfaces:n,directives:r,fields:i})}parseUnionTypeExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");let t=this.parseName(),n=this.parseConstDirectives(),r=this.parseUnionMemberTypes();if(n===void 0&&r===void 0)throw this.unexpected();return this.node(e,{kind:Du,name:t,directives:n,types:r})}parseEnumTypeExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");let t=this.parseName(),n=this.parseConstDirectives(),r=this.parseEnumValuesDefinition();if(n===void 0&&r===void 0)throw this.unexpected();return this.node(e,{kind:Tu,name:t,directives:n,values:r})}parseInputObjectTypeExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");let t=this.parseName(),n=this.parseConstDirectives(),r=this.parseInputFieldsDefinition();if(n===void 0&&r===void 0)throw this.unexpected();return this.node(e,{kind:Yl,name:t,directives:n,fields:r})}parseDirectiveExtension(){let e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("directive"),this.expectToken(we.AT);let t=this.parseName(),n=this.parseConstDirectives();if(n===void 0)throw this.unexpected();return this.node(e,{kind:dm,name:t,directives:n})}parseDirectiveDefinition(){let e=this._lexer.token,t=this.parseDescription();this.expectKeyword("directive"),this.expectToken(we.AT);let n=this.parseName(),r=this.parseArgumentDefs(),i=this.parseConstDirectives(),s=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");let o=this.parseDirectiveLocations();return this.node(e,{kind:nl,description:t,name:n,arguments:r,directives:i,repeatable:s,locations:o})}parseDirectiveLocations(){return this.delimitedMany(we.PIPE,this.parseDirectiveLocation)}parseDirectiveLocation(){let e=this._lexer.token,t=this.parseName();if(Object.hasOwn(et,t.value))return t;throw this.unexpected(e)}parseSchemaCoordinate(){let e=this._lexer.token,t=this.expectOptionalToken(we.AT),n=this.parseName(),r;if(!t&&this.expectOptionalToken(we.DOT))r=this.parseName();let i;if((t||r)&&this.expectOptionalToken(we.PAREN_L))i=this.parseName(),this.expectToken(we.COLON),this.expectToken(we.PAREN_R);if(t){if(i)return this.node(e,{kind:Q8,name:n,argumentName:i});return this.node(e,{kind:W8,name:n})}else if(r){if(i)return this.node(e,{kind:z8,name:n,fieldName:r,argumentName:i});return this.node(e,{kind:H8,name:n,memberName:r})}return this.node(e,{kind:G8,name:n})}node(e,t){if(this._options.noLocation!==!0)t.loc=new T0(e,this._lexer.lastToken,this._lexer.source);return t}peek(e){return this._lexer.token.kind===e}expectToken(e){let t=this._lexer.token;if(t.kind===e)return this.advanceLexer(),t;throw tr(this._lexer.source,t.start,`Expected ${VV(e)}, found ${H0(t)}.`)}expectOptionalToken(e){if(this._lexer.token.kind===e)return this.advanceLexer(),!0;return!1}expectKeyword(e){let t=this._lexer.token;if(t.kind===we.NAME&&t.value===e)this.advanceLexer();else throw tr(this._lexer.source,t.start,`Expected "${e}", found ${H0(t)}.`)}expectOptionalKeyword(e){let t=this._lexer.token;if(t.kind===we.NAME&&t.value===e)return this.advanceLexer(),!0;return!1}unexpected(e){let t=e??this._lexer.token;return tr(this._lexer.source,t.start,`Unexpected ${H0(t)}.`)}any(e,t,n){this.expectToken(e);let r=[];while(!this.expectOptionalToken(n))r.push(t.call(this));return r}optionalMany(e,t,n){if(this.expectOptionalToken(e)){let r=[];do r.push(t.call(this));while(!this.expectOptionalToken(n));return r}return}many(e,t,n){this.expectToken(e);let r=[];do r.push(t.call(this));while(!this.expectOptionalToken(n));return r}delimitedMany(e,t){this.expectOptionalToken(e);let n=[];do n.push(t.call(this));while(this.expectOptionalToken(e));return n}advanceLexer(){let{maxTokens:e}=this._options,t=this._lexer.advance();if(t.kind!==we.EOF){if(++this._tokenCounter,e!==void 0&&this._tokenCounter>e)throw tr(this._lexer.source,t.start,`Document contains more than ${e} tokens. Parsing aborted.`)}}}function H0(e){let t=e.value;return VV(e.kind)+(t!=null?` "${t}"`:"")}function VV(e){return FV(e)?`"${e}"`:e}function Lr(e,t){switch(t.kind){case S0:{let n=Lr(e,t.type);return n&&new Sr(n)}case vg:{let n=Lr(e,t.type);return n&&new dt(n)}case kN:return e.getType(t.name.value)}}function KV(e){let t=new Map;return{Directive(n){if(n.name.value===tc.name||n.name.value===nc.name){let i=n.arguments?.find((o)=>o.name.value==="label")?.value;if(!i||i.kind===Cr)return;if(i.kind!==ba){e.reportError(new ae(`Argument "@${n.name.value}(label:)" must be a static string.`,{nodes:n}));return}let s=t.get(i.value);if(s!=null)e.reportError(new ae('Value for arguments "defer(label:)" and "stream(label:)" must be unique across all Defer/Stream directive usages.',{nodes:[s,n]}));else t.set(i.value,n)}}}}function GV(e){return{OperationDefinition(t){let n=e.getDocument(),r=new Map;for(let o of n.definitions)if(o.kind===Ql)r.set(o.name.value,o);if(t.operation!=="subscription"&&t.operation!=="mutation")return;let s=e.getSchema().getRootType(t.operation);if(s)tO({context:e,operationType:t.operation,rootType:s,fragments:r,selectionSet:t.selectionSet,visitedFragments:new Set})}}}function tO({context:e,operationType:t,rootType:n,fragments:r,selectionSet:i,visitedFragments:s}){for(let o of i.selections)if(o.kind==="Field"){let a=o.directives?.find((l)=>l.name.value===nc.name);if(a)e.reportError(new ae(`Stream directive cannot be used on root ${t} type "${n}".`,{nodes:a}))}else if(o.kind==="FragmentSpread"){let a=o.name.value;if(s.has(a))continue;let l=r.get(a);if(l){let c=JV(o);if(c!==void 0)e.reportError(new ae(`Defer directive cannot be used on root ${t} type "${n}".`,{nodes:c}));tO({context:e,operationType:t,rootType:n,fragments:r,selectionSet:l.selectionSet,visitedFragments:s})}s.add(a)}else if(o.kind==="InlineFragment"){let a=JV(o);if(a!==void 0)e.reportError(new ae(`Defer directive cannot be used on root ${t} type "${n}".`,{nodes:a}));tO({context:e,operationType:t,rootType:n,fragments:r,selectionSet:o.selectionSet,visitedFragments:s})}}function JV(e){return e.directives?.find((t)=>t.name.value===tc.name)}function HV(e){let t=e.arguments?.find((n)=>n.name.value==="if");if(!t)return!1;if(t.value.kind===Eo){if(t.value.value)return!1}else if(t.value.kind!==xs)return!1;return!0}function s0e(e){let t=e.arguments?.find((n)=>n.name.value==="if");if(!t)return!0;if(t.value.kind===Eo){if(t.value.value)return!0;return!1}return!0}function o0e(e){let t=e.arguments?.find((n)=>n.name.value==="if");if(!t)return!1;if(t?.value.kind===Eo){if(t.value.value)return!1;return!0}return!0}function zV(e){return{OperationDefinition(t){if(t.operation!==Fr.SUBSCRIPTION)return;let n=e.getDocument(),r=new Map;for(let s of n.definitions)if(s.kind===Ql)r.set(s.name.value,s);let i=new Set;nO({context:e,fragments:r,selectionSet:t.selectionSet,parentNodes:[],visitedFragments:i})}}}function nO({context:e,fragments:t,selectionSet:n,parentNodes:r,visitedFragments:i}){for(let s of n.selections){let o=s.directives?.find((l)=>l.name.value===_d.name);if(o&&s0e(o))continue;let a=s.directives?.find((l)=>l.name.value===vd.name);if(a&&o0e(a))continue;for(let l of s.directives??[])if(l.name.value===tc.name){if(!HV(l))e.reportError(new ae("Defer directive not supported on subscription operations. Disable `@defer` by setting the `if` argument to `false`.",{nodes:[l,...r]}))}else if(l.name.value===nc.name){if(!HV(l))e.reportError(new ae("Stream directive not supported on subscription operations. Disable `@stream` by setting the `if` argument to `false`.",{nodes:[l,...r]}))}if(s.kind==="FragmentSpread"){let l=s.name.value;if(i.has(l))continue;i.add(l);let c=t.get(l);if(c)nO({context:e,fragments:t,parentNodes:[s,...r],selectionSet:c?.selectionSet,visitedFragments:i})}else if(s.selectionSet)nO({context:e,fragments:t,selectionSet:s.selectionSet,parentNodes:r,visitedFragments:i})}}function rO(e){return e.kind===nd||e.kind===Ql}function iO(e){return e.kind===id||$u(e)||e.kind===nl}function $u(e){return e.kind===sd||e.kind===od||e.kind===ad||e.kind===ld||e.kind===cd||e.kind===vu}function sO(e){return e.kind===ud||e.kind===dm||W0(e)}function W0(e){return e.kind===_u||e.kind===xu||e.kind===wu||e.kind===Du||e.kind===Tu||e.kind===Yl}function WV(e){return{Document(t){for(let n of t.definitions)if(!rO(n)){let r=n.kind===id||n.kind===ud?"schema":'"'+n.name.value+'"';e.reportError(new ae(`The ${r} definition is not executable.`,{nodes:n}))}return!1}}}function QV(e){return{Field(t){let n=e.getParentType();if(n){if(!e.getFieldDef()){let i=e.getSchema(),s=t.name.value,o=Oi("to use an inline fragment on",e.hideSuggestions?[]:a0e(i,n,s));if(o==="")o=Oi(e.hideSuggestions?[]:l0e(n,s));e.reportError(new ae(`Cannot query field "${s}" on type "${n}".`+o,{nodes:t}))}}}}}function a0e(e,t,n){if(!Io(t))return[];let r=new Set,i=Object.create(null);for(let s of e.getPossibleTypes(t)){if(s.getFields()[n]==null)continue;r.add(s),i[s.name]=1;for(let o of s.getInterfaces()){if(o.getFields()[n]==null)continue;r.add(o),i[o.name]=(i[o.name]??0)+1}}return[...r].sort((s,o)=>{let a=i[o.name]-i[s.name];if(a!==0)return a;if(dn(s)&&e.isSubType(s,o))return-1;if(dn(o)&&e.isSubType(o,s))return 1;return fm(s.name,o.name)}).map((s)=>s.name)}function l0e(e,t){if(Dn(e)||dn(e)){let n=Object.keys(e.getFields());return Qi(t,n)}return[]}function YV(e){return{InlineFragment(t){let n=t.typeCondition;if(n){let r=Lr(e.getSchema(),n);if(r&&!Eu(r)){let i=hn(n);e.reportError(new ae(`Fragment cannot condition on non composite type "${i}".`,{nodes:n}))}}},FragmentDefinition(t){let n=Lr(e.getSchema(),t.typeCondition);if(n&&!Eu(n)){let r=hn(t.typeCondition);e.reportError(new ae(`Fragment "${t.name.value}" cannot condition on non composite type "${r}".`,{nodes:t.typeCondition}))}}}}function XV(e){return{...oO(e),FragmentArgument(t){let n=e.getFragmentSignature();if(n){if(!n.variableDefinitions.get(t.name.value)){let i=t.name.value,s=e.hideSuggestions?[]:Qi(i,Array.from(n.variableDefinitions.values()).map((o)=>o.variable.name.value));e.reportError(new ae(`Unknown argument "${i}" on fragment "${n.definition.name.value}".`+Oi(s),{nodes:t}))}}},Argument(t){let n=e.getArgument(),r=e.getFieldDef();if(!n&&r){let i=t.name.value,s=e.hideSuggestions?[]:Qi(i,r.args.map((o)=>o.name));e.reportError(new ae(`Unknown argument "${i}" on field "${r}".`+Oi(s),{nodes:t}))}}}}function oO(e){let t=new Map,n=e.getSchema(),r=n?n.getDirectives():Ts;for(let s of r)t.set(s.name,s.args.map((o)=>o.name));let i=e.getDocument().definitions;for(let s of i)if(s.kind===nl){let o=s.arguments??[];t.set(s.name.value,o.map((a)=>a.name.value))}return{Directive(s){let o=s.name.value,a=t.get(o);if(s.arguments!=null&&a!=null)for(let l of s.arguments){let c=l.name.value;if(!a.includes(c)){let u=Qi(c,a);e.reportError(new ae(`Unknown argument "${c}" on directive "@${o}".`+(e.hideSuggestions?"":Oi(u)),{nodes:l}))}}return!1}}}function aO(e){let t=new Map,n=e.getSchema(),r=n?n.getDirectives():Ts;for(let s of r)t.set(s.name,s.locations);let i=e.getDocument().definitions;for(let s of i)if(s.kind===nl)t.set(s.name.value,s.locations.map((o)=>o.value));return{Directive(s,o,a,l,c){let u=s.name.value,p=t.get(u);if(p==null){e.reportError(new ae(`Unknown directive "@${u}".`,{nodes:s}));return}let d=c0e(c);if(d!=null&&!p.includes(d))e.reportError(new ae(`Directive "@${u}" may not be used on ${d}.`,{nodes:s}))}}}function c0e(e){let t=e.at(-1);if(!(t!=null&&("kind"in t)))cn(!1);switch(t.kind){case nd:return u0e(t.operation);case pm:return et.FIELD;case gu:return et.FRAGMENT_SPREAD;case gg:return et.INLINE_FRAGMENT;case Ql:return et.FRAGMENT_DEFINITION;case EN:{let n=e[e.length-3];if(!("kind"in n))cn(!1);return n.kind===nd?et.VARIABLE_DEFINITION:et.FRAGMENT_VARIABLE_DEFINITION}case id:case ud:return et.SCHEMA;case sd:case _u:return et.SCALAR;case od:case xu:return et.OBJECT;case NN:return et.FIELD_DEFINITION;case ad:case wu:return et.INTERFACE;case ld:case Du:return et.UNION;case cd:case Tu:return et.ENUM;case PN:return et.ENUM_VALUE;case vu:case Yl:return et.INPUT_OBJECT;case ON:{let n=e.at(-3);if(!(n!=null&&("kind"in n)))cn(!1);return n.kind===vu||n.kind===Yl?et.INPUT_FIELD_DEFINITION:et.ARGUMENT_DEFINITION}case nl:case dm:return et.DIRECTIVE_DEFINITION;default:cn(!1,"Unexpected kind: "+qe(t.kind))}}function u0e(e){switch(e){case Fr.QUERY:return et.QUERY;case Fr.MUTATION:return et.MUTATION;case Fr.SUBSCRIPTION:return et.SUBSCRIPTION}}function ZV(e){return{FragmentSpread(t){let n=t.name.value;if(!e.getFragment(n))e.reportError(new ae(`Unknown fragment "${n}".`,{nodes:t.name}))}}}function e6(e){let t=e.getSchema();return{OperationDefinition(n){let r=n.operation;if(!t.getRootType(r))e.reportError(new ae(`The ${r} operation is not supported by the schema.`,{nodes:n}))}}}function lO(e){let{definitions:t}=e.getDocument(),n=e.getSchema()?.getTypeMap()??{},r=new Set([...Object.keys(n),...t.filter($u).map((i)=>i.name.value)]);return{NamedType(i,s,o,a,l){let c=i.name.value;if(!r.has(c)){let u=l[2]??o,p=u!=null&&p0e(u);if(p&&t6.has(c))return;let d=e.hideSuggestions?[]:Qi(c,p?[...t6,...r]:[...r]);e.reportError(new ae(`Unknown type "${c}".`+Oi(d),{nodes:i}))}}}}var t6=new Set([...Ou,...Pu].map((e)=>e.name));function p0e(e){return"kind"in e&&(iO(e)||sO(e))}function n6(e){let t=0;return{Document(n){t=n.definitions.filter((r)=>r.kind===nd).length},OperationDefinition(n){if(!n.name&&t>1)e.reportError(new ae("This anonymous operation must be the only defined operation.",{nodes:n}))}}}function r6(e){let t=e.getSchema(),n=t?.astNode??t?.getQueryType()??t?.getMutationType()??t?.getSubscriptionType(),r=0;return{SchemaDefinition(i){if(n){e.reportError(new ae("Cannot define a new schema within a schema extension.",{nodes:i}));return}if(r>0)e.reportError(new ae("Must provide only one schema definition.",{nodes:i}));++r}}}var d0e=3;function i6(e){function t(n,r=Object.create(null),i=0){if(n.kind===gu){let s=n.name.value;if(r[s]===!0)return!1;let o=e.getFragment(s);if(!o)return!1;try{return r[s]=!0,t(o,r,i)}finally{r[s]=void 0}}if(n.kind===pm&&(n.name.value==="fields"||n.name.value==="interfaces"||n.name.value==="possibleTypes"||n.name.value==="inputFields")){if(i++,i>=d0e)return!0}if("selectionSet"in n&&n.selectionSet){for(let s of n.selectionSet.selections)if(t(s,r,i))return!0}return!1}return{Field(n){if(n.name.value==="__schema"||n.name.value==="__type"){if(t(n))return e.reportError(new ae("Maximum introspection depth exceeded",{nodes:[n]})),!1}}}}function s6(e){let t=new Set,n=[],r=Object.create(null);return{OperationDefinition:()=>!1,FragmentDefinition(s){return i(s),!1}};function i(s){if(t.has(s.name.value))return;let o=s.name.value;t.add(o);let a=e.getFragmentSpreads(s.selectionSet);if(a.length===0)return;r[o]=n.length;for(let l of a){let c=l.name.value,u=r[c];if(n.push(l),u===void 0){let p=e.getFragment(c);if(p)i(p)}else{let p=n.slice(u),d=p.slice(0,-1).map((f)=>'"'+f.name.value+'"').join(", ");e.reportError(new ae(`Cannot spread fragment "${c}" within itself`+(d!==""?` via ${d}.`:"."),{nodes:p}))}n.pop()}r[o]=void 0}}function o6(e){return{OperationDefinition(t){let n=new Set(t.variableDefinitions?.map((i)=>i.variable.name.value)),r=e.getRecursiveVariableUsages(t);for(let{node:i,fragmentVariableDefinition:s}of r){if(s)continue;let o=i.name.value;if(!n.has(o))e.reportError(new ae(t.name?`Variable "$${o}" is not defined by operation "${t.name.value}".`:`Variable "$${o}" is not defined.`,{nodes:[i,t]}))}}}}function a6(e){let t=new Set,n=[];return{OperationDefinition(r){for(let i of e.getRecursivelyReferencedFragments(r))t.add(i.name.value);return!1},FragmentDefinition(r){return n.push(r),!1},Document:{leave(){for(let r of n){let i=r.name.value;if(!t.has(i))e.reportError(new ae(`Fragment "${i}" is never used.`,{nodes:r}))}}}}}function l6(e){return{FragmentDefinition(t){let n=e.getVariableUsages(t),r=new Set(n.map(({node:s})=>s.name.value)),i=t.variableDefinitions??[];for(let s of i){let o=s.variable.name.value;if(!r.has(o))e.reportError(new ae(`Variable "$${o}" is never used in fragment "${t.name.value}".`,{nodes:s}))}},OperationDefinition(t){let n=e.getRecursiveVariableUsages(t),r=new Set;for(let{node:s,fragmentVariableDefinition:o}of n){let a=s.name.value;if(!o)r.add(a)}let i=t.variableDefinitions??[];for(let s of i){let o=s.variable.name.value;if(!r.has(o))e.reportError(new ae(t.name?`Variable "$${o}" is never used in operation "${t.name.value}".`:`Variable "$${o}" is never used.`,{nodes:s}))}}}}function qg(e){switch(e.kind){case No:return{...e,fields:f0e(e.fields)};case ko:return{...e,values:e.values.map(qg)};case pi:case bu:case ba:case Eo:case Cr:case rd:case xs:return e}}function f0e(e){return e.map((t)=>({...t,value:qg(t.value)})).sort((t,n)=>fm(t.name.value,n.name.value))}function p6(e){if(Array.isArray(e))return e.map(([t,n])=>`subfields "${t}" conflict because `+p6(n)).join(" and ");return e}function d6(e){let t=new fO,n=new y6,r=new Map;return{SelectionSet(i){let s=m0e(e,r,t,n,e.getParentType(),i);for(let[[o,a],l,c]of s){let u=p6(a);e.reportError(new ae(`Fields "${o}" conflict because ${u}. Use different aliases on the fields to fetch both if this was intentional.`,{nodes:l.concat(c)}))}}}}function m0e(e,t,n,r,i,s){let o=[],[a,l]=X0(e,t,i,s,void 0);if(h0e(e,o,t,n,r,a),l.length!==0)for(let c=0;c1)for(let l=0;l[s.value,r===void 0?o:Ug(o,r)]));return e.every((s)=>{let o=s.value;if(t)o=Ug(o,t);let a=i.get(s.name.value);if(a===void 0)return!1;return c6(o)===c6(a)})}function Ug(e,t){switch(e.kind){case xs:return t.get(e.name.value)??e;case ko:return{...e,values:e.values.map((n)=>Ug(n,t))};case No:return{...e,fields:e.fields.map((n)=>({...n,value:Ug(n.value,t)}))};default:return e}}function c6(e){return hn(qg(e))}function u6(e){return e?.find((t)=>t.name.value==="stream")}function g0e(e,t,n,r){let i=u6(e),s=u6(n);if(!i&&!s)return;else if(i&&s){if(dO(i.arguments,t,s.arguments,r))return"they have overlapping stream directives. See https://github.com/graphql/defer-stream-wg/discussions/100";return"they have overlapping stream directives"}return"they have overlapping stream directives"}function cO(e,t){if(fn(e))return fn(t)?cO(e.ofType,t.ofType):!0;if(fn(t))return!0;if(Ft(e))return Ft(t)?cO(e.ofType,t.ofType):!0;if(Ft(t))return!0;if(Xl(e)||Xl(t))return e!==t;return!1}function X0(e,t,n,r,i){let s=t.get(r);if(s)return s;let o=new Map,a=new Map;m6(e,n,r,o,a,i);let l=[o,Array.from(a.values())];return t.set(r,l),l}function uO(e,t,n,r){let i=t.get(n.selectionSet);if(i)return i;let s=Lr(e.getSchema(),n.typeCondition);return X0(e,t,s,n.selectionSet,r)}function m6(e,t,n,r,i,s){for(let o of n.selections)switch(o.kind){case pm:{let a=o.name.value,l;if(Dn(t)||dn(t))l=t.getFields()[a];let c=o.alias?o.alias.value:a,u=r.get(c);if(u==null)u=[],r.set(c,u);u.push([t,o,l]);break}case gu:{let a=b0e(e,o,s);i.set(a.key,a);break}case gg:{let a=o.typeCondition,l=a?Lr(e.getSchema(),a):t;m6(e,l,o.selectionSet,r,i,s);break}}}function b0e(e,t,n){let r="",i=new Map,s=e.getFragmentSignatureByName()(t.name.value),o=new Map;if(t.arguments)for(let a of t.arguments)o.set(a.name.value,a.value);if(s?.variableDefinitions){r+=t.name.value+"(";for(let[a,l]of s.variableDefinitions){let c=o.get(a);if(c)r+=a+": "+hn(qg(c));let u=o.get(a);if(u!==void 0)i.set(a,n!==void 0?Ug(u,n):u);else if(l.defaultValue)i.set(a,l.defaultValue)}r+=")"}return{key:r,node:t,varMap:i.size>0?i:void 0}}function v0e(e,t,n,r){if(e.length>0)return[[t,e.map(([i])=>i)],[n,...e.map(([,i])=>i).flat()],[r,...e.map(([,,i])=>i).flat()]]}class fO{constructor(){this._data=new Map}has(e,t,n){let r=this._data.get(e)?.get(t);if(r===void 0)return!1;return n?!0:n===r}add(e,t,n){let r=this._data.get(e);if(r===void 0)this._data.set(e,new Map([[t,n]]));else r.set(t,n)}}class y6{constructor(){this._orderedPairSet=new fO}has(e,t,n){return ei.name.value));for(let i of n.args)if(!r.has(i.name)&&xa(i))e.reportError(new ae(`Argument "${i}" of type "${i.type}" is required, but it was not provided.`,{nodes:t}))}},FragmentSpread:{leave(t){let n=e.getFragmentSignature();if(!n)return!1;let r=new Set(t.arguments?.map((i)=>i.name.value));for(let[i,s]of n.variableDefinitions)if(!r.has(i)&&v6(s)){let o=Lr(e.getSchema(),s.type),a=qe(o);e.reportError(new ae(`Fragment "${t.name.value}" argument "${i}" of type "${a}" is required, but it was not provided.`,{nodes:t}))}}}}}function mO(e){let t=new Map,r=e.getSchema()?.getDirectives()??Ts;for(let s of r)t.set(s.name,new Map(s.args.filter(xa).map((o)=>[o.name,o])));let i=e.getDocument().definitions;for(let s of i)if(s.kind===nl){let o=s.arguments??[];t.set(s.name.value,new Map(o.filter(v6).map((a)=>[a.name.value,a])))}return{Directive:{leave(s){let o=s.name.value,a=t.get(o);if(a!=null){let l=s.arguments??[],c=new Set(l.map((u)=>u.name.value));for(let[u,p]of a.entries())if(!c.has(u)){let d=P0(p.type)?qe(p.type):hn(p.type);e.reportError(new ae(`Argument "@${o}(${u}:)" of type "${d}" is required, but it was not provided.`,{nodes:s}))}}}}}}function v6(e){return e.type.kind===vg&&e.defaultValue==null}function _6(e){return{Field(t){let n=e.getType(),r=t.selectionSet;if(n){if(Xl(_a(n))){if(r){let i=t.name.value,s=qe(n);e.reportError(new ae(`Field "${i}" must not have a selection since type "${s}" has no subfields.`,{nodes:r}))}}else if(!r){let i=t.name.value,s=qe(n);e.reportError(new ae(`Field "${i}" of type "${s}" must have a selection of subfields. Did you mean "${i} { ... }"?`,{nodes:t}))}else if(r.selections.length===0){let i=t.name.value,s=qe(n);e.reportError(new ae(`Field "${i}" of type "${s}" must have at least one field selected.`,{nodes:t}))}}}}}function Sd(e,t){if(Ft(t)){if(e==null)return;return Sd(e,t.ofType)}if(e==null)return null;if(fn(t)){if(!So(e)){let i=Sd(e,t.ofType);if(i===void 0)return;return[i]}let r=[];for(let i of e){let s=Sd(i,t.ofType);if(s===void 0)return;r.push(s)}return r}if(en(t)){if(!jr(e)||Array.isArray(e))return;let r=Object.create(null),i=t.getFields(),s=0;for(let o of Object.keys(e)){if(e[o]===void 0)continue;if(s++,!Object.hasOwn(i,o))return}for(let o of Object.values(i)){let a=e[o.name];if(a===void 0){if(Ao(o))return;let l=Z0(o);if(l!==void 0)r[o.name]=l}else{let l=Sd(a,o.type);if(l===void 0)return;r[o.name]=l}}if(t.isOneOf){let o=Object.keys(r);if(s!==1||o.length!==1)return;let a=o[0];if(r[a]===null)return}return r}let n=va(t);try{return n.coerceInputValue(e)}catch(r){}}function Iu(e,t,n,r){if(e.kind===xs){let s=x6(e,n,r);if(s==null&&Ft(t))return;return s}if(Ft(t)){if(e.kind===Cr)return;return Iu(e,t.ofType,n,r)}if(e.kind===Cr)return null;if(fn(t)){if(e.kind!==ko){let o=Iu(e,t.ofType,n,r);if(o===void 0)return;return[o]}let s=[];for(let o of e.values){let a=Iu(o,t.ofType,n,r);if(a===void 0)if(o.kind===xs&&x6(o,n,r)==null&&!Ft(t.ofType))a=null;else return;s.push(a)}return s}if(en(t)){if(e.kind!==No)return;let s=Object.create(null),o=t.getFields();if(e.fields.some((c)=>!Object.hasOwn(o,c.name.value)))return;let l=new Map(e.fields.map((c)=>[c.name.value,c]));for(let c of Object.values(o)){let u=l.get(c.name);if(!u||u.value.kind===xs&&T0e(u.value,n,r)){if(Ao(c))return;let p=Z0(c);if(p!==void 0)s[c.name]=p}else{let p=Iu(u.value,c.type,n,r);if(p===void 0)return;s[c.name]=p}}if(t.isOneOf){let c=Object.keys(s);if(l.size!==1||c.length!==1)return;for(let[u,p]of l)if(p.value.kind===Cr||s[u]===null)return}return s}let i=va(t);try{return i.coerceInputLiteral?i.coerceInputLiteral(ku(e,n,r)):i.parseLiteral(e,n?.coerced)}catch(s){}}function x6(e,t,n){let r=e.name.value;if(n?.sources[r]!==void 0)return n.coerced[r];return t?.coerced[r]}function T0e(e,t,n){let r=e.name.value;return(n?.sources[r]!==void 0?n.coerced:t?.coerced)?.[r]===void 0}function Z0(e){let t=e._memoizedCoercedDefaultValue;if(t!==void 0)return t;let n=e.default;if(n!==void 0){if(t=n.literal?Iu(n.literal,e.type):Sd(n.value,e.type),t===void 0)cn(!1,`Expected value of type "${e.type}" to be valid, found: ${qe(n.literal??n.value)}.`);return e._memoizedCoercedDefaultValue=t,t}let r=e.defaultValue;if(r!==void 0)e._memoizedCoercedDefaultValue=r;return r}function w6(e,t,n,r,i){try{let s=Z0(n);if(s!==void 0)e[t]=s}catch(s){let o=n.default;if(o===void 0)throw s;let a=!1;if(ZN(o,n.type,(l,c)=>{a=!0,r(l,c)},i),!a)r(dg(s),[])}}function D6(e,t,n,r,i){let s=e.arguments??[],o=new Map(s.map((c)=>[c.name.value,c])),a=Object.create(null),l=Object.create(null);for(let[c,u]of Object.entries(t)){let p=o.get(c);if(p!==void 0)a[c]=r==null?{signature:u,value:p.value}:{signature:u,value:p.value,fragmentVariableValues:r};else a[c]={signature:u};T6(l,e,c,u,p,n,r,i)}return{sources:a,coerced:l}}function ew(e,t,n,r,i){let s=Object.create(null),o=t.arguments??[],a=new Map(o.map((l)=>[l.name.value,l]));for(let l of e.args){let c=l.name;T6(s,t,c,l,a.get(l.name),n,r,i)}return s}function T6(e,t,n,r,i,s,o,a){let l=r.type,c=(d,f)=>{throw new ae(`${yO(r,t)} has invalid default value${fg(f)}: ${d.message}`,{nodes:t})};if(!i){if(xa(r))throw new ae(`${yO(r,t)} of required type "${l}" was not provided.`,{nodes:t});w6(e,n,r,c,a);return}let u=i.value;if(u.kind===xs){let d=u.name.value,f=o?.sources[d]?o:s;if((f==null||!Object.hasOwn(f.coerced,d))&&!xa(r)){w6(e,n,r,c,a);return}}let p=Iu(u,l,s,o);if(p===void 0)bd(u,l,(d,f)=>{throw d.message=`${yO(r,t)} has invalid value${fg(f)}: ${d.message}`,d},s,o,a),cn(!1,"Invalid argument");e[n]=p}function yO(e,t){return LN(e)?`Argument "${e}"`:`Variable "$${e.name}" defined by fragment "${t.name.value}"`}function xm(e,t,n,r,i){let s=t.directives?.find((o)=>o.name.value===e.name);if(s)return ew(e,s,n,r,i)}function k6(e,t,n,r,i,s,o=!1){let a=new Wi,l=[],c={schema:e,fragments:t,variableValues:n,runtimeType:r,visitedFragmentNames:new Map,hideSuggestions:s,forbiddenDirectiveInstances:[],forbidSkipAndInclude:o};return tw(c,i,a,l),{groupedFieldSet:a,newDeferUsages:l,forbiddenDirectiveInstances:c.forbiddenDirectiveInstances}}function tw(e,t,n,r,i,s){let{schema:o,fragments:a,variableValues:l,runtimeType:c,visitedFragmentNames:u,hideSuggestions:p}=e;for(let d of t.selections)switch(d.kind){case pm:{if(!hO(e,d,l,s))continue;n.add(S0e(d),{node:d,deferUsage:i,fragmentVariableValues:s});break}case gg:{if(!hO(e,d,l,s)||!E6(o,d,c))continue;let f=S6(l,s,d,i);if(!f)tw(e,d.selectionSet,n,r,i,s);else r.push(f),tw(e,d.selectionSet,n,r,f,s);break}case gu:{let f=d.name.value;if(!hO(e,d,l,s))continue;let m=a[f];if(m==null||!E6(o,m.definition,c))continue;let y=S6(l,s,d,i),h=u.get(f),b;if(!y){if(h===!1)continue;u.set(f,!1),b=i}else{if(h!==void 0)continue;u.set(f,!0),r.push(y),b=y}let g=m.variableSignatures,x;if(g)x=D6(d,g,l,s,p);tw(e,m.definition.selectionSet,n,r,b,x);break}}}function S6(e,t,n,r){let i=xm(tc,n,e,t);if(!i)return;if(i.if===!1)return;return{label:typeof i.label==="string"?i.label:void 0,parentDeferUsage:r}}function hO(e,t,n,r){let i=t.directives?.find((l)=>l.name.value===_d.name);if(i&&e.forbidSkipAndInclude)return e.forbiddenDirectiveInstances.push(i),!1;if((i?ew(_d,i,n,r,e.hideSuggestions):void 0)?.if===!0)return!1;let o=t.directives?.find((l)=>l.name.value===vd.name);if(o&&e.forbidSkipAndInclude)return e.forbiddenDirectiveInstances.push(o),!1;if((o?ew(vd,o,n,r,e.hideSuggestions):void 0)?.if===!1)return!1;return!0}function E6(e,t,n){let r=t.typeCondition;if(!r)return!0;let i=Lr(e,r);if(i===n)return!0;if(Io(i))return e.isSubType(i,n);return!1}function S0e(e){return e.alias?e.alias.value:e.name.value}function gO(e){return e.map((t)=>t.node)}function N6(e){return{OperationDefinition(t){if(t.operation==="subscription"){let n=e.getSchema(),r=n.getSubscriptionType();if(r){let i=t.name?t.name.value:null,s=Object.create(null),o=e.getDocument(),a=Object.create(null);for(let u of o.definitions)if(u.kind===Ql)a[u.name.value]={definition:u};let{groupedFieldSet:l,forbiddenDirectiveInstances:c}=k6(n,a,s,r,t.selectionSet,e.hideSuggestions,!0);if(c.length>0){e.reportError(new ae(i!=null?`Subscription "${i}" must not use \`@skip\` or \`@include\` directives in the top level selection.`:"Anonymous Subscription must not use `@skip` or `@include` directives in the top level selection.",{nodes:c}));return}if(l.size>1){let d=[...l.values()].slice(1).flatMap((f)=>gO(f));e.reportError(new ae(i!=null?`Subscription "${i}" must select only one top level field.`:"Anonymous Subscription must select only one top level field.",{nodes:d}))}for(let u of l.values())if(gO(u)[0].name.value.startsWith("__"))e.reportError(new ae(i!=null?`Subscription "${i}" must not select an introspection top level field.`:"Anonymous Subscription must not select an introspection top level field.",{nodes:gO(u)}))}}}}}function O6(e){return{Directive(t){let n=e.getFieldDef(),r=e.getParentType();if(n&&r&&t.name.value===nc.name&&!(fn(n.type)||ym(n.type)&&fn(n.type.ofType)))e.reportError(new ae(`Directive "@stream" cannot be used on non-list field "${r}.${n.name}".`,{nodes:t}))}}}function wm(e,t){let n=new Wi;for(let r of e)n.add(t(r),r);return n}function P6(e){return{DirectiveDefinition(r){let i=r.arguments??[];return n(`@${r.name.value}`,i)},InterfaceTypeDefinition:t,InterfaceTypeExtension:t,ObjectTypeDefinition:t,ObjectTypeExtension:t};function t(r){let i=r.name.value,s=r.fields??[];for(let o of s){let a=o.name.value,l=o.arguments??[];n(`${i}.${a}`,l)}return!1}function n(r,i){let s=wm(i,(o)=>o.name.value);for(let[o,a]of s)if(a.length>1)e.reportError(new ae(`Argument "${r}(${o}:)" can only be defined once.`,{nodes:a.map((l)=>l.name)}));return!1}}function bO(e){return{Field:t,Directive:t};function t(n){let r=n.arguments??[],i=wm(r,(s)=>s.name.value);for(let[s,o]of i)if(o.length>1)e.reportError(new ae(`There can be only one argument named "${s}".`,{nodes:o.map((a)=>a.name)}))}}function $6(e){let t=new Map,n=e.getSchema();return{DirectiveDefinition(r){let i=r.name.value;if(n?.getDirective(i)){e.reportError(new ae(`Directive "@${i}" already exists in the schema. It cannot be redefined.`,{nodes:r.name}));return}let s=t.get(i);if(s)e.reportError(new ae(`There can be only one directive named "@${i}".`,{nodes:[s,r.name]}));else t.set(i,r.name);return!1}}}function vO(e){let t=new Map,n=e.getSchema(),r=n?n.getDirectives():Ts;for(let l of r)t.set(l.name,!l.isRepeatable);let i=e.getDocument().definitions;for(let l of i)if(l.kind===nl)t.set(l.name.value,!l.repeatable);let s=new Map,o=new Map,a=new Map;return{enter(l){if(!("directives"in l)||!l.directives)return;let c;if(l.kind===id||l.kind===ud)c=s;else if($u(l)||W0(l)){let u=l.name.value;if(c=o.get(u),c===void 0)c=new Map,o.set(u,c)}else if(l.kind===nl||l.kind===dm){let u=l.name.value;if(c=a.get(u),c===void 0)c=new Map,a.set(u,c)}else c=new Map;for(let u of l.directives){let p=u.name.value;if(t.get(p)===!0){let d=c.get(p);if(d!=null)e.reportError(new ae(`The directive "@${p}" can only be used once at this location.`,{nodes:[d,u]}));else c.set(p,u)}}}}}function I6(e){let t=e.getSchema(),n=t?t.getTypeMap():Object.create(null),r=new Map;return{EnumTypeDefinition:i,EnumTypeExtension:i};function i(s){let o=s.name.value,a=r.get(o);if(a==null)a=new Map,r.set(o,a);let l=s.values??[];for(let c of l){let u=c.name.value,p=n[o];if(Mr(p)&&p.getValue(u)){e.reportError(new ae(`Enum value "${o}.${u}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:c.name}));continue}let d=a.get(u);if(d!=null)e.reportError(new ae(`Enum value "${o}.${u}" can only be defined once.`,{nodes:[d,c.name]}));else a.set(u,c.name)}return!1}}function A6(e){let t=e.getSchema(),n=t?t.getTypeMap():Object.create(null),r=new Map;return{InputObjectTypeDefinition:i,InputObjectTypeExtension:i,InterfaceTypeDefinition:i,InterfaceTypeExtension:i,ObjectTypeDefinition:i,ObjectTypeExtension:i};function i(s){let o=s.name.value,a=r.get(o);if(a==null)a=new Map,r.set(o,a);let l=s.fields??[];for(let c of l){let u=c.name.value;if(E0e(n[o],u)){e.reportError(new ae(`Field "${o}.${u}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:c.name}));continue}let p=a.get(u);if(p!=null)e.reportError(new ae(`Field "${o}.${u}" can only be defined once.`,{nodes:[p,c.name]}));else a.set(u,c.name)}return!1}}function E0e(e,t){if(Dn(e)||dn(e)||en(e))return e.getFields()[t]!=null;return!1}function R6(e){let t=new Map;return{OperationDefinition:()=>!1,FragmentDefinition(n){let r=n.name.value,i=t.get(r);if(i!=null)e.reportError(new ae(`There can be only one fragment named "${r}".`,{nodes:[i,n.name]}));else t.set(r,n.name);return!1}}}function _O(e){let t=[],n=new Map;return{ObjectValue:{enter(){t.push(n),n=new Map},leave(){let r=t.pop();if(r==null)cn(!1);n=r}},ObjectField(r){let i=r.name.value,s=n.get(i);if(s!=null)e.reportError(new ae(`There can be only one input field named "${i}".`,{nodes:[s,r.name]}));else n.set(i,r.name)}}}function j6(e){let t=new Map;return{OperationDefinition(n){let r=n.name;if(r!=null){let i=t.get(r.value);if(i!=null)e.reportError(new ae(`There can be only one operation named "${r.value}".`,{nodes:[i,r]}));else t.set(r.value,r)}return!1},FragmentDefinition:()=>!1}}function F6(e){let t=e.getSchema(),n=new Map,r=t?{query:t.getQueryType(),mutation:t.getMutationType(),subscription:t.getSubscriptionType()}:{};return{SchemaDefinition:i,SchemaExtension:i};function i(s){let o=s.operationTypes??[];for(let a of o){let l=a.operation,c=n.get(l);if(r[l])e.reportError(new ae(`Type for ${l} already defined in the schema. It cannot be redefined.`,{nodes:a}));else if(c)e.reportError(new ae(`There can be only one ${l} type in schema.`,{nodes:[c,a]}));else n.set(l,a)}return!1}}function C6(e){let t=new Map,n=e.getSchema();return{ScalarTypeDefinition:r,ObjectTypeDefinition:r,InterfaceTypeDefinition:r,UnionTypeDefinition:r,EnumTypeDefinition:r,InputObjectTypeDefinition:r};function r(i){let s=i.name.value;if(n?.getType(s)){e.reportError(new ae(`Type "${s}" already exists in the schema. It cannot also be defined in this type definition.`,{nodes:i.name}));return}let o=t.get(s);if(o!=null)e.reportError(new ae(`There can be only one type named "${s}".`,{nodes:[o,i.name]}));else t.set(s,i.name);return!1}}function M6(e){return{OperationDefinition(t){let n=t.variableDefinitions??[],r=wm(n,(i)=>i.variable.name.value);for(let[i,s]of r)if(s.length>1)e.reportError(new ae(`There can be only one variable named "$${i}".`,{nodes:s.map((o)=>o.variable.name)}))}}}function L6(e){return{NullValue:(t)=>Au(e,t,e.getInputType()),ListValue:(t)=>Au(e,t,e.getParentInputType()),ObjectValue:(t)=>Au(e,t,e.getInputType()),EnumValue:(t)=>Au(e,t,e.getInputType()),IntValue:(t)=>Au(e,t,e.getInputType()),FloatValue:(t)=>Au(e,t,e.getInputType()),StringValue:(t)=>Au(e,t,e.getInputType()),BooleanValue:(t)=>Au(e,t,e.getInputType())}}function Au(e,t,n){if(n)bd(t,n,(r)=>{e.reportError(r)},void 0,void 0,e.hideSuggestions);return!1}function q6(e){return{VariableDefinition(t){let n=Lr(e.getSchema(),t.type);if(n!==void 0&&!Su(n)){let r=t.variable.name.value,i=hn(t.type);e.reportError(new ae(`Variable "$${r}" cannot be non-input type "${i}".`,{nodes:t.type}))}}}}function U6(e){let t;return{OperationDefinition:{enter(){t=new Map},leave(n){let r=e.getRecursiveVariableUsages(n);for(let{node:i,type:s,parentType:o,defaultValue:a,fragmentVariableDefinition:l}of r){let c=i.name.value,u=l;if(u??=t.get(c),u&&s){let p=e.getSchema(),d=Lr(p,u.type);if(d&&!k0e(p,d,u.defaultValue,s,a))e.reportError(new ae(`Variable "$${c}" of type "${d}" used in position expecting type "${s}".`,{nodes:[u,i]}));if(en(o)&&o.isOneOf&&qN(d))e.reportError(new ae(`Variable "$${c}" is of type "${d}" but must be non-nullable to be used for OneOf Input Object "${o}".`,{nodes:[u,i]}))}}}},VariableDefinition(n){t.set(n.variable.name.value,n)}}}function k0e(e,t,n,r,i){if(Ft(r)&&!Ft(t)){if(!(n!=null&&n.kind!==Cr)&&i===void 0)return!1;let a=r.ofType;return Zl(e,t,a)}return Zl(e,t,r)}var N0e=Object.freeze([i6]),O0e=Object.freeze([WV,e6,j6,n6,N6,lO,YV,q6,_6,QV,R6,ZV,a6,h6,s6,M6,o6,l6,aO,vO,GV,zV,KV,O6,XV,bO,L6,b6,U6,d6,_O,...N0e]),B6=Object.freeze([r6,F6,C6,I6,A6,P6,$6,lO,aO,vO,g6,oO,bO,_O,mO]);class V6{constructor(e,t){this._ast=e,this._fragments=void 0,this._fragmentSpreads=new Map,this._recursivelyReferencedFragments=new Map,this._onError=t}get[Symbol.toStringTag](){return"ASTValidationContext"}reportError(e){this._onError(e)}getDocument(){return this._ast}getFragment(e){let t;if(this._fragments)t=this._fragments;else{t=Object.create(null);for(let n of this.getDocument().definitions)if(n.kind===Ql)t[n.name.value]=n;this._fragments=t}return t[e]}getFragmentSpreads(e){let t=this._fragmentSpreads.get(e);if(!t){t=[];let n=[e],r;while(r=n.pop())for(let i of r.selections)if(i.kind===gu)t.push(i);else if(i.selectionSet)n.push(i.selectionSet);this._fragmentSpreads.set(e,t)}return t}getRecursivelyReferencedFragments(e){let t=this._recursivelyReferencedFragments.get(e);if(!t){t=[];let n=new Set,r=[e.selectionSet],i;while(i=r.pop())for(let s of this.getFragmentSpreads(i)){let o=s.name.value;if(!n.has(o)){n.add(o);let a=this.getFragment(o);if(a)t.push(a),r.push(a.selectionSet)}}this._recursivelyReferencedFragments.set(e,t)}return t}}class xO extends V6{constructor(e,t,n){super(e,n);this._schema=t}get hideSuggestions(){return!1}get[Symbol.toStringTag](){return"SDLValidationContext"}getSchema(){return this._schema}}var Xrt=tl(yg,(e)=>e.filter((t)=>t!=="description")),Zrt=new ae("Too many validation errors, error limit reached. Validation aborted.");function P0e(e,t,n=B6){let r=[],i=new xO(e,t,(o)=>{r.push(o)}),s=n.map((o)=>o(i));return xg(e,AN(s)),r}function K6(e){let t=P0e(e);if(t.length!==0)throw Error(t.map((n)=>n.message).join(` -`))}var kr={SCHEMA:"SCHEMA",SCALAR:"SCALAR",OBJECT:"OBJECT",FIELD:"FIELD",ARGUMENT:"ARGUMENT",INTERFACE:"INTERFACE",UNION:"UNION",ENUM:"ENUM",ENUM_VALUE:"ENUM_VALUE",INPUT_OBJECT:"INPUT_OBJECT",INPUT_FIELD:"INPUT_FIELD",DIRECTIVE:"DIRECTIVE"};function J6(e,t){let n=t({getNamedType:l,setNamedType:c,getNamedTypes:u}),r=new Map;for(let N of e.types){let O=N.name,C=p(N);if(C)r.set(O,C)}let i=[];for(let N of e.directives){if(JN(N)){i.push(N);continue}let O=T(N.toConfig());if(O)i.push(new Pi(O))}let s={...e,query:e.query&&l(e.query.name),mutation:e.mutation&&l(e.mutation.name),subscription:e.subscription&&l(e.subscription.name),types:Array.from(r.values()),directives:i},o=n[kr.SCHEMA];return o==null?s:o(s);function a(N){if(fn(N))return new Tr(a(N.ofType));if(Ft(N))return new dt(a(N.ofType));return l(N.name)}function l(N){let O=j0e.get(N)??r.get(N);if(O===void 0)cn(!1,`Unknown type: "${N}".`);return O}function c(N){r.set(N.name,N)}function u(){return Array.from(r.values())}function p(N){if(Rg(N)||KN(N))return N;if($o(N))return d(N);if(Dn(N))return f(N);if(dn(N))return h(N);if(Wr(N))return b(N);if(Cr(N))return g(N);if(en(N))return v(N);cn(!1,"Unexpected type: "+qe(N))}function d(N){let O=N.toConfig(),C=n[kr.SCALAR];return O=C==null?O:C(O),new Hs(O)}function f(N){let O=N.toConfig(),C={...O,interfaces:()=>O.interfaces.map((te)=>l(te.name)),fields:()=>m(O.fields,N.name)},X=n[kr.OBJECT];return C=X==null?C:X(C),new ws(C)}function m(N,O){let C=Object.create(null);for(let[X,te]of Object.entries(N)){let L={...te,type:a(te.type),args:y(te.args,X,O)},Y=n[kr.FIELD];if(Y)L=Y(L,O);C[X]=L}return C}function y(N,O,C){let X=Object.create(null);for(let[te,L]of Object.entries(N)){let Y={...L,type:a(L.type)},me=n[kr.ARGUMENT];if(me)Y=me(Y,O,C);X[te]=Y}return X}function h(N){let O=N.toConfig(),C={...O,interfaces:()=>O.interfaces.map((te)=>l(te.name)),fields:()=>m(O.fields,N.name)},X=n[kr.INTERFACE];return C=X==null?C:X(C),new pd(C)}function b(N){let O=N.toConfig(),C={...O,types:()=>O.types.map((te)=>l(te.name))},X=n[kr.UNION];return C=X==null?C:X(C),new dd(C)}function g(N){let O=N.toConfig(),C={...O,values:()=>{let te=Object.create(null);for(let[L,Y]of Object.entries(O.values)){let me=x(Y,L,N.name);te[L]=me}return te}},X=n[kr.ENUM];return C=X==null?C:X(C),new rl(C)}function x(N,O,C){let X={...N},te=n[kr.ENUM_VALUE];return te==null?X:te(X,O,C)}function v(N){let O=N.toConfig(),C={...O,fields:()=>{let te=Object.create(null);for(let[L,Y]of Object.entries(O.fields)){let me=D(Y,L,N.name);te[L]=me}return te}},X=n[kr.INPUT_OBJECT];return C=X==null?C:X(C),new fd(C)}function D(N,O,C){let X={...N,type:a(N.type)},te=n[kr.INPUT_FIELD];return te==null?X:te(X,O,C)}function T(N){let O={...N,args:y(N.args,N.name,void 0)},C=n[kr.DIRECTIVE];return C==null?O:C(O)}}var j0e=new Map([...Nu,...Ou].map((e)=>[e.name,e]));function G6(e,t,n){let r=[],i=new zi,s=new zi,o=new zi,a=new zi,l=new zi,c=new zi,u=new zi,p=[],d,f=[],m=!1;for(let y of t.definitions){switch(y.kind){case nd:d=y;break;case ld:f.push(y);break;case nl:p.push(y);break;case um:u.add(y.name.value,y);break;case rd:case id:case sd:case od:case ad:case bu:r.push(y);break;case vu:i.add(y.name.value,y);break;case _u:s.add(y.name.value,y);break;case xu:o.add(y.name.value,y);break;case wu:a.add(y.name.value,y);break;case Du:l.add(y.name.value,y);break;case Yl:c.add(y.name.value,y);break;default:continue}m=!0}if(!m)return e;return J6(e,(y)=>{let{getNamedType:h,setNamedType:b,getNamedTypes:g}=y;return{[kr.SCHEMA]:(I)=>{for(let pe of r){let de=F0e.get(pe.name.value)??me(pe);b(de)}let Z={query:I.query&&h(I.query.name),mutation:I.mutation&&h(I.mutation.name),subscription:I.subscription&&h(I.subscription.name),...d&&x([d]),...x(f)};return{description:d?.description?.value??I.description,...Z,types:g(),directives:[...I.directives.map(N),...p.map(T)],extensions:I.extensions,astNode:d??I.astNode,extensionASTNodes:I.extensionASTNodes.concat(f),assumeValid:n?.assumeValid??!1}},[kr.INPUT_OBJECT]:(I)=>{let Z=c.get(I.name)??[];return{...I,fields:()=>({...I.fields(),...X(Z)}),extensionASTNodes:I.extensionASTNodes.concat(Z)}},[kr.ENUM]:(I)=>{let Z=l.get(I.name)??[];return{...I,values:()=>({...I.values(),...te(Z)}),extensionASTNodes:I.extensionASTNodes.concat(Z)}},[kr.SCALAR]:(I)=>{let Z=i.get(I.name)??[],pe=I.specifiedByURL;for(let de of Z)pe=wO(de)??pe;return{...I,specifiedByURL:pe,extensionASTNodes:I.extensionASTNodes.concat(Z)}},[kr.OBJECT]:(I)=>{let Z=s.get(I.name)??[];return{...I,interfaces:()=>[...I.interfaces(),...L(Z)],fields:()=>({...I.fields(),...O(Z)}),extensionASTNodes:I.extensionASTNodes.concat(Z)}},[kr.INTERFACE]:(I)=>{let Z=o.get(I.name)??[];return{...I,interfaces:()=>[...I.interfaces(),...L(Z)],fields:()=>({...I.fields(),...O(Z)}),extensionASTNodes:I.extensionASTNodes.concat(Z)}},[kr.UNION]:(I)=>{let Z=a.get(I.name)??[];return{...I,types:()=>[...I.types(),...Y(Z)],extensionASTNodes:I.extensionASTNodes.concat(Z)}}};function x(I){let Z={};for(let pe of I){let de=pe.operationTypes??[];for(let je of de)Z[je.operation]=v(je.type)}return Z}function v(I){let Z=I.name.value,pe=h(Z);if(pe===void 0)cn(!1,`Unknown type: "${Z}".`);return pe}function D(I){if(I.kind===S0)return new Tr(D(I.type));if(I.kind===vg)return new dt(D(I.type));return v(I)}function T(I){let Z=u.get(I.name.value)??[],pe=Td(I)??Z.map((de)=>Td(de)).find((de)=>de!=null);return new Pi({name:I.name.value,description:I.description?.value,locations:I.locations.map(({value:de})=>de),isRepeatable:I.repeatable,args:C(I.arguments),deprecationReason:pe,astNode:I,extensionASTNodes:Z})}function N(I){let Z=u.get(I.name)??[];if(Z.length===0)return I;let pe=I.deprecationReason??Z.map((de)=>Td(de)).find((de)=>de!=null);return new Pi({...I.toConfig(),deprecationReason:pe,extensionASTNodes:I.extensionASTNodes.concat(Z)})}function O(I){let Z=Object.create(null);for(let pe of I){let de=pe.fields??[];for(let je of de)Z[je.name.value]={type:D(je.type),description:je.description?.value,args:C(je.arguments),deprecationReason:Td(je),astNode:je}}return Z}function C(I){let Z=I??[],pe=Object.create(null);for(let de of Z){let je=D(de.type);pe[de.name.value]={type:je,description:de.description?.value,default:de.defaultValue&&{literal:de.defaultValue},deprecationReason:Td(de),astNode:de}}return pe}function X(I){let Z=Object.create(null);for(let pe of I){let de=pe.fields??[];for(let je of de){let be=D(je.type);Z[je.name.value]={type:be,description:je.description?.value,default:je.defaultValue&&{literal:je.defaultValue},deprecationReason:Td(je),astNode:je}}}return Z}function te(I){let Z=Object.create(null);for(let pe of I){let de=pe.values??[];for(let je of de)Z[je.name.value]={description:je.description?.value,deprecationReason:Td(je),astNode:je}}return Z}function L(I){return I.flatMap((Z)=>Z.interfaces?.map(v)??[])}function Y(I){return I.flatMap((Z)=>Z.types?.map(v)??[])}function me(I){let Z=I.name.value;switch(I.kind){case id:{let pe=s.get(Z)??[],de=[I,...pe];return new ws({name:Z,description:I.description?.value,interfaces:()=>L(de),fields:()=>O(de),astNode:I,extensionASTNodes:pe})}case sd:{let pe=o.get(Z)??[],de=[I,...pe];return new pd({name:Z,description:I.description?.value,interfaces:()=>L(de),fields:()=>O(de),astNode:I,extensionASTNodes:pe})}case ad:{let pe=l.get(Z)??[],de=[I,...pe];return new rl({name:Z,description:I.description?.value,values:()=>te(de),astNode:I,extensionASTNodes:pe})}case od:{let pe=a.get(Z)??[],de=[I,...pe];return new dd({name:Z,description:I.description?.value,types:()=>Y(de),astNode:I,extensionASTNodes:pe})}case rd:{let pe=i.get(Z)??[],de=wO(I);for(let je of pe)de=wO(je)??de;return new Hs({name:Z,description:I.description?.value,specifiedByURL:de,astNode:I,extensionASTNodes:pe})}case bu:{let pe=c.get(Z)??[],de=[I,...pe];return new fd({name:Z,description:I.description?.value,fields:()=>X(de),astNode:I,extensionASTNodes:pe,isOneOf:C0e(I)})}}}})}var F0e=new Map([...Nu,...Ou].map((e)=>[e.name,e]));function Td(e){return vm(gm,e)?.reason}function wO(e){return vm(C0,e)?.url}function C0e(e){return Boolean(vm(M0,e))}function nw(e,t){if(t?.assumeValid!==!0&&t?.assumeValidSDL!==!0)K6(e);let n={description:void 0,types:[],directives:[],extensions:Object.create(null),extensionASTNodes:[],assumeValid:!1},r=G6(n,e,t);if(r.astNode==null)for(let s of r.types)switch(s.name){case"Query":r.query=s;break;case"Mutation":r.mutation=s;break;case"Subscription":r.subscription=s;break}let i=[...r.directives,...Ds.filter((s)=>r.directives.every((o)=>o.name!==s.name))];return new jg({...r,directives:i})}$8();var rw={id:"umf.graphql",version:"0.1.0",coreVersion:"0.1.0",description:"GraphQL SDL native AST and source preservation",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:graphql:0.1.0",type:"object",required:["profile","ast","originalSource"],properties:{profile:{const:"graphql-js-17.0.2-sdl"},mode:{enum:["schema","fragment"]},ast:{$ref:"#/$defs/DocumentNode"},originalSource:{type:"string"}},$defs:{DocumentNode:{type:"object",required:["kind","definitions"],properties:{kind:{const:"Document"},definitions:{type:"array",minItems:1,items:{anyOf:[{$ref:"#/$defs/TypeSystemDefinitionNode"},{$ref:"#/$defs/TypeSystemExtensionNode"}]}}}},TypeSystemDefinitionNode:{anyOf:[{$ref:"#/$defs/SchemaDefinitionNode"},{$ref:"#/$defs/ScalarTypeDefinitionNode"},{$ref:"#/$defs/ObjectTypeDefinitionNode"},{$ref:"#/$defs/InterfaceTypeDefinitionNode"},{$ref:"#/$defs/UnionTypeDefinitionNode"},{$ref:"#/$defs/EnumTypeDefinitionNode"},{$ref:"#/$defs/InputObjectTypeDefinitionNode"},{$ref:"#/$defs/DirectiveDefinitionNode"}]},SchemaDefinitionNode:{type:"object",required:["kind","operationTypes"],properties:{kind:{const:"SchemaDefinition"},description:{$ref:"#/$defs/StringValueNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},operationTypes:{type:"array",items:{$ref:"#/$defs/OperationTypeDefinitionNode"}}}},StringValueNode:{type:"object",required:["kind","value"],properties:{kind:{const:"StringValue"},value:{type:"string"},block:{type:"boolean"}}},ConstDirectiveNode:{type:"object",required:["kind","name"],properties:{kind:{const:"Directive"},name:{$ref:"#/$defs/NameNode"},arguments:{type:"array",items:{$ref:"#/$defs/ConstArgumentNode"}}}},NameNode:{type:"object",required:["kind","value"],properties:{kind:{const:"Name"},value:{type:"string"}}},ConstArgumentNode:{type:"object",required:["kind","name","value"],properties:{kind:{const:"Argument"},name:{$ref:"#/$defs/NameNode"},value:{anyOf:[{$ref:"#/$defs/StringValueNode"},{$ref:"#/$defs/IntValueNode"},{$ref:"#/$defs/FloatValueNode"},{$ref:"#/$defs/BooleanValueNode"},{$ref:"#/$defs/NullValueNode"},{$ref:"#/$defs/EnumValueNode"},{$ref:"#/$defs/ConstListValueNode"},{$ref:"#/$defs/ConstObjectValueNode"}]}}},IntValueNode:{type:"object",required:["kind","value"],properties:{kind:{const:"IntValue"},value:{type:"string"}}},FloatValueNode:{type:"object",required:["kind","value"],properties:{kind:{const:"FloatValue"},value:{type:"string"}}},BooleanValueNode:{type:"object",required:["kind","value"],properties:{kind:{const:"BooleanValue"},value:{type:"boolean"}}},NullValueNode:{type:"object",required:["kind"],properties:{kind:{const:"NullValue"}}},EnumValueNode:{type:"object",required:["kind","value"],properties:{kind:{const:"EnumValue"},value:{type:"string"}}},ConstListValueNode:{type:"object",required:["kind","values"],properties:{kind:{const:"ListValue"},values:{type:"array",items:{anyOf:[{$ref:"#/$defs/StringValueNode"},{$ref:"#/$defs/IntValueNode"},{$ref:"#/$defs/FloatValueNode"},{$ref:"#/$defs/BooleanValueNode"},{$ref:"#/$defs/NullValueNode"},{$ref:"#/$defs/EnumValueNode"},{$ref:"#/$defs/ConstListValueNode"},{$ref:"#/$defs/ConstObjectValueNode"}]}}}},ConstObjectValueNode:{type:"object",required:["kind","fields"],properties:{kind:{const:"ObjectValue"},fields:{type:"array",items:{$ref:"#/$defs/ConstObjectFieldNode"}}}},ConstObjectFieldNode:{type:"object",required:["kind","name","value"],properties:{kind:{const:"ObjectField"},name:{$ref:"#/$defs/NameNode"},value:{anyOf:[{$ref:"#/$defs/StringValueNode"},{$ref:"#/$defs/IntValueNode"},{$ref:"#/$defs/FloatValueNode"},{$ref:"#/$defs/BooleanValueNode"},{$ref:"#/$defs/NullValueNode"},{$ref:"#/$defs/EnumValueNode"},{$ref:"#/$defs/ConstListValueNode"},{$ref:"#/$defs/ConstObjectValueNode"}]}}},OperationTypeDefinitionNode:{type:"object",required:["kind","operation","type"],properties:{kind:{const:"OperationTypeDefinition"},operation:{anyOf:[{const:"query"},{const:"mutation"},{const:"subscription"}]},type:{$ref:"#/$defs/NamedTypeNode"}}},NamedTypeNode:{type:"object",required:["kind","name"],properties:{kind:{const:"NamedType"},name:{$ref:"#/$defs/NameNode"}}},ScalarTypeDefinitionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"ScalarTypeDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}}}},ObjectTypeDefinitionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"ObjectTypeDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},interfaces:{type:"array",items:{$ref:"#/$defs/NamedTypeNode"}},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},fields:{type:"array",items:{$ref:"#/$defs/FieldDefinitionNode"}}}},FieldDefinitionNode:{type:"object",required:["kind","name","type"],properties:{kind:{const:"FieldDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},arguments:{type:"array",items:{$ref:"#/$defs/InputValueDefinitionNode"}},type:{anyOf:[{$ref:"#/$defs/NamedTypeNode"},{$ref:"#/$defs/ListTypeNode"},{$ref:"#/$defs/NonNullTypeNode"}]},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}}}},InputValueDefinitionNode:{type:"object",required:["kind","name","type"],properties:{kind:{const:"InputValueDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},type:{anyOf:[{$ref:"#/$defs/NamedTypeNode"},{$ref:"#/$defs/ListTypeNode"},{$ref:"#/$defs/NonNullTypeNode"}]},defaultValue:{anyOf:[{$ref:"#/$defs/StringValueNode"},{$ref:"#/$defs/IntValueNode"},{$ref:"#/$defs/FloatValueNode"},{$ref:"#/$defs/BooleanValueNode"},{$ref:"#/$defs/NullValueNode"},{$ref:"#/$defs/EnumValueNode"},{$ref:"#/$defs/ConstListValueNode"},{$ref:"#/$defs/ConstObjectValueNode"}]},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}}}},ListTypeNode:{type:"object",required:["kind","type"],properties:{kind:{const:"ListType"},type:{anyOf:[{$ref:"#/$defs/NamedTypeNode"},{$ref:"#/$defs/ListTypeNode"},{$ref:"#/$defs/NonNullTypeNode"}]}}},NonNullTypeNode:{type:"object",required:["kind","type"],properties:{kind:{const:"NonNullType"},type:{anyOf:[{$ref:"#/$defs/NamedTypeNode"},{$ref:"#/$defs/ListTypeNode"}]}}},InterfaceTypeDefinitionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"InterfaceTypeDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},interfaces:{type:"array",items:{$ref:"#/$defs/NamedTypeNode"}},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},fields:{type:"array",items:{$ref:"#/$defs/FieldDefinitionNode"}}}},UnionTypeDefinitionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"UnionTypeDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},types:{type:"array",items:{$ref:"#/$defs/NamedTypeNode"}}}},EnumTypeDefinitionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"EnumTypeDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},values:{type:"array",items:{$ref:"#/$defs/EnumValueDefinitionNode"}}}},EnumValueDefinitionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"EnumValueDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}}}},InputObjectTypeDefinitionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"InputObjectTypeDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},fields:{type:"array",items:{$ref:"#/$defs/InputValueDefinitionNode"}}}},DirectiveDefinitionNode:{type:"object",required:["kind","name","repeatable","locations"],properties:{kind:{const:"DirectiveDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},arguments:{type:"array",items:{$ref:"#/$defs/InputValueDefinitionNode"}},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},repeatable:{type:"boolean"},locations:{type:"array",items:{$ref:"#/$defs/NameNode"}}}},TypeSystemExtensionNode:{anyOf:[{$ref:"#/$defs/SchemaExtensionNode"},{$ref:"#/$defs/ScalarTypeExtensionNode"},{$ref:"#/$defs/ObjectTypeExtensionNode"},{$ref:"#/$defs/InterfaceTypeExtensionNode"},{$ref:"#/$defs/UnionTypeExtensionNode"},{$ref:"#/$defs/EnumTypeExtensionNode"},{$ref:"#/$defs/InputObjectTypeExtensionNode"},{$ref:"#/$defs/DirectiveExtensionNode"}]},SchemaExtensionNode:{type:"object",required:["kind"],properties:{kind:{const:"SchemaExtension"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},operationTypes:{type:"array",items:{$ref:"#/$defs/OperationTypeDefinitionNode"}}}},ScalarTypeExtensionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"ScalarTypeExtension"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}}}},ObjectTypeExtensionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"ObjectTypeExtension"},name:{$ref:"#/$defs/NameNode"},interfaces:{type:"array",items:{$ref:"#/$defs/NamedTypeNode"}},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},fields:{type:"array",items:{$ref:"#/$defs/FieldDefinitionNode"}}}},InterfaceTypeExtensionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"InterfaceTypeExtension"},name:{$ref:"#/$defs/NameNode"},interfaces:{type:"array",items:{$ref:"#/$defs/NamedTypeNode"}},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},fields:{type:"array",items:{$ref:"#/$defs/FieldDefinitionNode"}}}},UnionTypeExtensionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"UnionTypeExtension"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},types:{type:"array",items:{$ref:"#/$defs/NamedTypeNode"}}}},EnumTypeExtensionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"EnumTypeExtension"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},values:{type:"array",items:{$ref:"#/$defs/EnumValueDefinitionNode"}}}},InputObjectTypeExtensionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"InputObjectTypeExtension"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},fields:{type:"array",items:{$ref:"#/$defs/InputValueDefinitionNode"}}}},DirectiveExtensionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"DirectiveExtension"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}}}}}},semantics:"CONTRACT-009. SDL AST preserves native type/directive/default declarations; original source retains comments. Runtime scalar/directive behavior remains external.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"GraphQL SDL",version:"GraphQL.js 17.0.2; September 2025 specification plus explicitly reported runtime grammar additions",subset:"Schema definitions/extensions and constant values; executable operations are outside this schema adapter"},evidence:["tests/graphql/native.test.ts","tests/graphql/corpus.test.ts","fixtures/graphql/corpus-oracle-results.json"]}};var H6="umf.graphql",q0e=rw,U0e=mt().compile(rw.schema),z6=new Map;for(let e of Object.values(rw.schema.$defs))if(e.properties?.kind?.const)z6.set(e.properties.kind.const,Object.keys(e.properties));function iw(e){if(typeof e!=="string"||e.length>Zt.maxTextLength)throw new U("GRAPHQL_LIMIT","Source exceeds text limit");let t=z0(e,{noLocation:!0,maxTokens:Zt.maxValues});return Ae(JSON.parse(JSON.stringify(t,(n,r)=>n==="tokenCount"?void 0:r)))}function B0e(e){let t=e,n=[],r=(s,o,a)=>n.push({code:s,path:o,message:a,severity:"warning"});for(let s of Object.keys(t))if(!["profile","mode","ast","originalSource"].includes(s))r("GRAPHQL_REPRESENTATION","/"+Pe(s),"Unknown payload field has no SDL destination");function i(s,o){if(!s||typeof s!=="object")return;if(Array.isArray(s)){s.forEach((l,c)=>i(l,o+"/"+c));return}let a=z6.get(s.kind);for(let l of Object.keys(s))if(!a?.includes(l))r("GRAPHQL_REPRESENTATION",o+"/"+Pe(l),"Unknown AST field has no SDL destination");if(s.kind==="ScalarTypeDefinition")r("GRAPHQL_SCALAR",o,"Custom scalar coercion/serialization is external to SDL");if(s.kind==="Directive"&&!["deprecated","specifiedBy","oneOf"].includes(s.name?.value))r("GRAPHQL_DIRECTIVE",o,"Custom directive behavior is retained but not implemented by this adapter");if(s.kind==="DirectiveExtension"||s.kind==="DirectiveDefinition"&&s.directives?.length)r("GRAPHQL_PROFILE_EXTENSION",o,"GraphQL.js grammar addition beyond the September 2025 SDL profile");for(let[l,c]of Object.entries(s))if(l!=="kind")i(c,o+"/"+Pe(l))}i(t.ast,"/ast");try{let s=hn(t.ast),o=iw(s);if(JSON.stringify(o)!==JSON.stringify(t.ast)){if(Au(o)!==Au(t.ast))r("GRAPHQL_PRINT_CHANGE","/ast","Printing changes AST content; conservative export is blocked")}if(t.mode==="fragment")r("GRAPHQL_FRAGMENT","/ast","Syntax-only SDL fragment: references, roots and composed-schema semantics require an explicit schema context");let a=t.mode==="fragment"?[]:B0(nw(t.ast));for(let l of a)n.push({code:"GRAPHQL_SCHEMA",path:"/ast",severity:"error",message:l.message})}catch(s){n.push({code:"GRAPHQL_SCHEMA",path:"/ast",severity:"error",message:String(s)})}try{iw(t.originalSource)}catch(s){n.push({code:"GRAPHQL_SOURCE_ARCHIVE",path:"/originalSource",severity:"error",message:String(s)})}return n}function Au(e){return JSON.stringify(e&&typeof e==="object"?Array.isArray(e)?e.map((t)=>JSON.parse(Au(t))):Object.fromEntries(Object.keys(e).sort().map((t)=>[t,JSON.parse(Au(e[t]))])):e)}function V0e(){return new nt().register(q0e,B0e)}function DO(e){return We(e,V0e())}function W6(e){let t=DO(e);if(!t.valid)throw new U("GRAPHQL_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[H6];if(e.vocabularies[H6]?.version!=="0.1.0"||!U0e(n))throw new U("GRAPHQL_PAYLOAD","Missing or invalid GraphQL payload");return Ae(n)}function TO(e){let t=W6(e);if(DO(e).diagnostics.some((n)=>["GRAPHQL_REPRESENTATION","GRAPHQL_PRINT_CHANGE"].includes(n.code)))throw new U("GRAPHQL_REPRESENTATION","Native export would discard AST content");return Au(iw(t.originalSource))===Au(t.ast)?t.originalSource:hn(t.ast)+` -`}function Q6(e){let t=W6(e),n=Au(iw(t.originalSource))!==Au(t.ast);return{schema:TO(e),source:Ae(e),diagnostics:[...DO(e).diagnostics,...n?[{code:"GRAPHQL_SOURCE_LAYOUT",path:"",severity:"warning",message:"Edited SDL is printed; comments and original formatting remain only in retained originalSource"}]:[],{code:"SOURCE_ARTIFACT_REQUIRED",path:"",severity:"warning",message:"Native SDL cannot preserve unrelated UMF metadata; retain source bundle"}]}}function Bg(e){if(Array.isArray(e))return e.map(Bg);if(e&&typeof e==="object")return Object.fromEntries(Object.entries(e).map(([t,n])=>t==="$dynamicRef"&&n==="#meta"?["$ref","#/$defs/schema"]:[t,Bg(n)]));return e}var Y6={$id:"https://spec.openapis.org/oas/3.1/meta/2024-11-10",$schema:"https://json-schema.org/draft/2020-12/schema",title:"OAS Base Vocabulary",description:"A JSON Schema Vocabulary used in the OpenAPI Schema Dialect",$dynamicAnchor:"meta",$vocabulary:{"https://spec.openapis.org/oas/3.1/vocab/base":!0},type:["object","boolean"],properties:{discriminator:{$ref:"#/$defs/discriminator"},example:!0,externalDocs:{$ref:"#/$defs/external-docs"},xml:{$ref:"#/$defs/xml"}},$defs:{discriminator:{$ref:"#/$defs/extensible",properties:{mapping:{additionalProperties:{type:"string"},type:"object"},propertyName:{type:"string"}},required:["propertyName"],type:"object",unevaluatedProperties:!1},extensible:{patternProperties:{"^x-":!0}},"external-docs":{$ref:"#/$defs/extensible",properties:{description:{type:"string"},url:{format:"uri-reference",type:"string"}},required:["url"],type:"object",unevaluatedProperties:!1},xml:{$ref:"#/$defs/extensible",properties:{attribute:{type:"boolean"},name:{type:"string"},namespace:{format:"uri",type:"string"},prefix:{type:"string"},wrapped:{type:"boolean"}},type:"object",unevaluatedProperties:!1}}};var X6={$id:"https://spec.openapis.org/oas/3.2/meta/2026-02-26",$schema:"https://json-schema.org/draft/2020-12/schema",title:"OAS Base Vocabulary",description:"A JSON Schema Vocabulary used in the OpenAPI JSON Schema Dialect",$dynamicAnchor:"meta",$vocabulary:{"https://spec.openapis.org/oas/3.2/vocab/base":!0},type:["object","boolean"],properties:{discriminator:{$ref:"#/$defs/discriminator"},example:{deprecated:!0},externalDocs:{$ref:"#/$defs/external-docs"},xml:{$ref:"#/$defs/xml"}},$defs:{discriminator:{$ref:"#/$defs/extensible",properties:{mapping:{additionalProperties:{type:"string"},type:"object"},defaultMapping:{type:"string"},propertyName:{type:"string"}},required:["propertyName"],type:"object",unevaluatedProperties:!1},extensible:{patternProperties:{"^x-":!0}},"external-docs":{$ref:"#/$defs/extensible",properties:{description:{type:"string"},url:{format:"uri-reference",type:"string"}},required:["url"],type:"object",unevaluatedProperties:!1},xml:{$ref:"#/$defs/extensible",properties:{nodeType:{type:"string",enum:["element","attribute","text","cdata","none"]},name:{type:"string"},namespace:{format:"iri",type:"string"},prefix:{type:"string"},attribute:{type:"boolean",deprecated:!0},wrapped:{type:"boolean",deprecated:!0}},type:"object",dependentSchemas:{nodeType:{properties:{attribute:!1,wrapped:!1}}},unevaluatedProperties:!1}}};var e4="https://json-schema.org/draft/2020-12/schema",G0e=mt(!1),H0e=G0e.getSchema(e4),z0e={"3.1":mt(!1).compile(Y6),"3.2":mt(!1).compile(X6)},Z6={[e4]:"standard","https://spec.openapis.org/oas/3.1/dialect/base":"3.1","https://spec.openapis.org/oas/3.1/dialect/2024-11-10":"3.1","https://spec.openapis.org/oas/3.2/dialect/2026-02-26":"3.2"},W0e=["not","if","then","else","items","contains","additionalProperties","unevaluatedProperties","unevaluatedItems","propertyNames","contentSchema"],Q0e=["allOf","anyOf","oneOf","prefixItems"],Y0e=["$defs","definitions","properties","patternProperties","dependentSchemas"],Yi=(e)=>e!==null&&typeof e==="object"&&!Array.isArray(e);function X0e(e){let t=[];function n(y,h,b){if(Yi(y))for(let[g,x]of Object.entries(y))b(x,h+"/"+Pe(g))}function r(y,h,b){if(Array.isArray(y))y.forEach((g,x)=>b(g,h+"/"+x))}function i(y,h){if(y!==void 0)t.push({pointer:h,schema:y})}function s(y,h){if(!Yi(y))return;if(n(y.headers,h+"/headers",l),n(y.encoding,h+"/encoding",s),r(y.prefixEncoding,h+"/prefixEncoding",s),y.itemEncoding)s(y.itemEncoding,h+"/itemEncoding")}function o(y,h){if(!Yi(y))return;i(y.schema,h+"/schema"),i(y.itemSchema,h+"/itemSchema"),s(y,h)}function a(y,h){if(Yi(y))n(y.content,h+"/content",o)}function l(y,h){if(!Yi(y))return;i(y.schema,h+"/schema"),a(y,h)}function c(y,h){if(!Yi(y))return;a(y,h),n(y.headers,h+"/headers",l)}function u(y,h){n(y,h,(b,g)=>{if(!g.split("/").at(-1).startsWith("x-")&&Yi(b))d(b,g)})}function p(y,h){if(!Yi(y))return;r(y.parameters,h+"/parameters",l),a(y.requestBody,h+"/requestBody"),n(y.responses,h+"/responses",(b,g)=>{let x=g.split("/").at(-1);if(x==="default"||/^[1-5][0-9Xx]{2}$/.test(x))c(b,g)}),n(y.callbacks,h+"/callbacks",u)}function d(y,h){if(!Yi(y))return;r(y.parameters,h+"/parameters",l);for(let b of["get","put","post","delete","options","head","patch","trace","query"])p(y[b],h+"/"+b);n(y.additionalOperations,h+"/additionalOperations",p)}let f=e;n(f.paths,"/paths",(y,h)=>{if(h.startsWith("/paths/~1"))d(y,h)}),n(f.webhooks,"/webhooks",d);let m=f.components;if(Yi(m)){n(m.schemas,"/components/schemas",i);for(let y of["parameters","headers"])n(m[y],"/components/"+y,l);n(m.responses,"/components/responses",c),n(m.requestBodies,"/components/requestBodies",a),n(m.callbacks,"/components/callbacks",u),n(m.pathItems,"/components/pathItems",d),n(m.mediaTypes,"/components/mediaTypes",o)}return t}function t4(e){let t=e,n=String(t.openapi??"").slice(0,3);if(!["3.1","3.2"].includes(n))return[];let r=[],i=t.jsonSchemaDialect??(n==="3.1"?"https://spec.openapis.org/oas/3.1/dialect/2024-11-10":"https://spec.openapis.org/oas/3.2/dialect/2026-02-26");function s(o,a,l){if(typeof o!=="boolean"&&!Yi(o)){r.push({code:"OPENAPI_SCHEMA_META",path:a,severity:"error",message:"Schema must be an object or boolean"});return}let c=typeof o==="boolean"?l:o.$schema??l,u=typeof c==="string"&&Object.hasOwn(Z6,c)?Z6[c]:void 0;if(typeof c!=="string"){r.push({code:"OPENAPI_SCHEMA_META",path:a+"/$schema",severity:"error",message:"Schema dialect must be a string"});return}if(!u){r.push({code:"OPENAPI_SCHEMA_DIALECT",path:a,severity:"warning",message:"Unknown dialect retained without applying another dialect: "+c});return}if(typeof o==="boolean")return;let p={...o},d=[],f=(m,y)=>(d.push({value:m,path:y}),Yi(m)||typeof m==="boolean"?!0:m);for(let m of W0e)if(Object.hasOwn(o,m))p[m]=f(o[m],a+"/"+m);for(let m of Q0e)if(Array.isArray(o[m]))p[m]=o[m].map((y,h)=>f(y,a+"/"+m+"/"+h));for(let m of Y0e)if(Yi(o[m]))p[m]=Object.fromEntries(Object.entries(o[m]).map(([y,h])=>[y,f(h,a+"/"+Pe(m)+"/"+Pe(y))]));if(Yi(o.dependencies))p.dependencies=Object.fromEntries(Object.entries(o.dependencies).map(([m,y])=>[m,Yi(y)||typeof y==="boolean"?f(y,a+"/dependencies/"+Pe(m)):y]));for(let m of[H0e,...u==="standard"?[]:[z0e[u]]])if(!m(p))for(let y of m.errors??[])r.push({code:"OPENAPI_SCHEMA_META",path:a+y.instancePath,severity:"error",message:y.message??"Invalid schema keyword"});if(o.$vocabulary)r.push({code:"OPENAPI_SCHEMA_VOCABULARY",path:a+"/$vocabulary",severity:"warning",message:"Custom vocabulary interpretation is not established by this meta-schema check"});for(let m of d)s(m.value,m.path,c)}for(let o of X0e(e))s(o.schema,o.pointer,i);return r}var T4=Ar(h4(),1);var g4={id:"https://spec.openapis.org/oas/3.0/schema/2024-10-18",$schema:"http://json-schema.org/draft-04/schema#",description:"The description of OpenAPI v3.0.x Documents",type:"object",required:["openapi","info","paths"],properties:{openapi:{type:"string",pattern:"^3\\.0\\.\\d(-.+)?$"},info:{$ref:"#/definitions/Info"},externalDocs:{$ref:"#/definitions/ExternalDocumentation"},servers:{type:"array",items:{$ref:"#/definitions/Server"}},security:{type:"array",items:{$ref:"#/definitions/SecurityRequirement"}},tags:{type:"array",items:{$ref:"#/definitions/Tag"},uniqueItems:!0},paths:{$ref:"#/definitions/Paths"},components:{$ref:"#/definitions/Components"}},patternProperties:{"^x-":{}},additionalProperties:!1,definitions:{Reference:{type:"object",required:["$ref"],patternProperties:{"^\\$ref$":{type:"string",format:"uri-reference"}}},Info:{type:"object",required:["title","version"],properties:{title:{type:"string"},description:{type:"string"},termsOfService:{type:"string",format:"uri-reference"},contact:{$ref:"#/definitions/Contact"},license:{$ref:"#/definitions/License"},version:{type:"string"}},patternProperties:{"^x-":{}},additionalProperties:!1},Contact:{type:"object",properties:{name:{type:"string"},url:{type:"string",format:"uri-reference"},email:{type:"string",format:"email"}},patternProperties:{"^x-":{}},additionalProperties:!1},License:{type:"object",required:["name"],properties:{name:{type:"string"},url:{type:"string",format:"uri-reference"}},patternProperties:{"^x-":{}},additionalProperties:!1},Server:{type:"object",required:["url"],properties:{url:{type:"string"},description:{type:"string"},variables:{type:"object",additionalProperties:{$ref:"#/definitions/ServerVariable"}}},patternProperties:{"^x-":{}},additionalProperties:!1},ServerVariable:{type:"object",required:["default"],properties:{enum:{type:"array",items:{type:"string"}},default:{type:"string"},description:{type:"string"}},patternProperties:{"^x-":{}},additionalProperties:!1},Components:{type:"object",properties:{schemas:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]}}},responses:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/Response"}]}}},parameters:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/Parameter"}]}}},examples:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/Example"}]}}},requestBodies:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/RequestBody"}]}}},headers:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/Header"}]}}},securitySchemes:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/SecurityScheme"}]}}},links:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/Link"}]}}},callbacks:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/Callback"}]}}}},patternProperties:{"^x-":{}},additionalProperties:!1},Schema:{type:"object",properties:{title:{type:"string"},multipleOf:{type:"number",minimum:0,exclusiveMinimum:!0},maximum:{type:"number"},exclusiveMaximum:{type:"boolean",default:!1},minimum:{type:"number"},exclusiveMinimum:{type:"boolean",default:!1},maxLength:{type:"integer",minimum:0},minLength:{type:"integer",minimum:0,default:0},pattern:{type:"string",format:"regex"},maxItems:{type:"integer",minimum:0},minItems:{type:"integer",minimum:0,default:0},uniqueItems:{type:"boolean",default:!1},maxProperties:{type:"integer",minimum:0},minProperties:{type:"integer",minimum:0,default:0},required:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0},enum:{type:"array",items:{},minItems:1,uniqueItems:!1},type:{type:"string",enum:["array","boolean","integer","number","object","string"]},not:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]},allOf:{type:"array",items:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]}},oneOf:{type:"array",items:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]}},anyOf:{type:"array",items:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]}},items:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]},properties:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]}},additionalProperties:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"},{type:"boolean"}],default:!0},description:{type:"string"},format:{type:"string"},default:{},nullable:{type:"boolean",default:!1},discriminator:{$ref:"#/definitions/Discriminator"},readOnly:{type:"boolean",default:!1},writeOnly:{type:"boolean",default:!1},example:{},externalDocs:{$ref:"#/definitions/ExternalDocumentation"},deprecated:{type:"boolean",default:!1},xml:{$ref:"#/definitions/XML"}},patternProperties:{"^x-":{}},additionalProperties:!1},Discriminator:{type:"object",required:["propertyName"],properties:{propertyName:{type:"string"},mapping:{type:"object",additionalProperties:{type:"string"}}}},XML:{type:"object",properties:{name:{type:"string"},namespace:{type:"string",format:"uri"},prefix:{type:"string"},attribute:{type:"boolean",default:!1},wrapped:{type:"boolean",default:!1}},patternProperties:{"^x-":{}},additionalProperties:!1},Response:{type:"object",required:["description"],properties:{description:{type:"string"},headers:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Header"},{$ref:"#/definitions/Reference"}]}},content:{type:"object",additionalProperties:{$ref:"#/definitions/MediaType"}},links:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Link"},{$ref:"#/definitions/Reference"}]}}},patternProperties:{"^x-":{}},additionalProperties:!1},MediaType:{type:"object",properties:{schema:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]},example:{},examples:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Example"},{$ref:"#/definitions/Reference"}]}},encoding:{type:"object",additionalProperties:{$ref:"#/definitions/Encoding"}}},patternProperties:{"^x-":{}},additionalProperties:!1,allOf:[{$ref:"#/definitions/ExampleXORExamples"}]},Example:{type:"object",properties:{summary:{type:"string"},description:{type:"string"},value:{},externalValue:{type:"string",format:"uri-reference"}},patternProperties:{"^x-":{}},additionalProperties:!1},Header:{type:"object",properties:{description:{type:"string"},required:{type:"boolean",default:!1},deprecated:{type:"boolean",default:!1},allowEmptyValue:{type:"boolean",default:!1},style:{type:"string",enum:["simple"],default:"simple"},explode:{type:"boolean"},allowReserved:{type:"boolean",default:!1},schema:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]},content:{type:"object",additionalProperties:{$ref:"#/definitions/MediaType"},minProperties:1,maxProperties:1},example:{},examples:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Example"},{$ref:"#/definitions/Reference"}]}}},patternProperties:{"^x-":{}},additionalProperties:!1,allOf:[{$ref:"#/definitions/ExampleXORExamples"},{$ref:"#/definitions/SchemaXORContent"}]},Paths:{type:"object",patternProperties:{"^\\/":{$ref:"#/definitions/PathItem"},"^x-":{}},additionalProperties:!1},PathItem:{type:"object",properties:{$ref:{type:"string"},summary:{type:"string"},description:{type:"string"},get:{$ref:"#/definitions/Operation"},put:{$ref:"#/definitions/Operation"},post:{$ref:"#/definitions/Operation"},delete:{$ref:"#/definitions/Operation"},options:{$ref:"#/definitions/Operation"},head:{$ref:"#/definitions/Operation"},patch:{$ref:"#/definitions/Operation"},trace:{$ref:"#/definitions/Operation"},servers:{type:"array",items:{$ref:"#/definitions/Server"}},parameters:{type:"array",items:{oneOf:[{$ref:"#/definitions/Parameter"},{$ref:"#/definitions/Reference"}]},uniqueItems:!0}},patternProperties:{"^x-":{}},additionalProperties:!1},Operation:{type:"object",required:["responses"],properties:{tags:{type:"array",items:{type:"string"}},summary:{type:"string"},description:{type:"string"},externalDocs:{$ref:"#/definitions/ExternalDocumentation"},operationId:{type:"string"},parameters:{type:"array",items:{oneOf:[{$ref:"#/definitions/Parameter"},{$ref:"#/definitions/Reference"}]},uniqueItems:!0},requestBody:{oneOf:[{$ref:"#/definitions/RequestBody"},{$ref:"#/definitions/Reference"}]},responses:{$ref:"#/definitions/Responses"},callbacks:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Callback"},{$ref:"#/definitions/Reference"}]}},deprecated:{type:"boolean",default:!1},security:{type:"array",items:{$ref:"#/definitions/SecurityRequirement"}},servers:{type:"array",items:{$ref:"#/definitions/Server"}}},patternProperties:{"^x-":{}},additionalProperties:!1},Responses:{type:"object",properties:{default:{oneOf:[{$ref:"#/definitions/Response"},{$ref:"#/definitions/Reference"}]}},patternProperties:{"^[1-5](?:\\d{2}|XX)$":{oneOf:[{$ref:"#/definitions/Response"},{$ref:"#/definitions/Reference"}]},"^x-":{}},minProperties:1,additionalProperties:!1},SecurityRequirement:{type:"object",additionalProperties:{type:"array",items:{type:"string"}}},Tag:{type:"object",required:["name"],properties:{name:{type:"string"},description:{type:"string"},externalDocs:{$ref:"#/definitions/ExternalDocumentation"}},patternProperties:{"^x-":{}},additionalProperties:!1},ExternalDocumentation:{type:"object",required:["url"],properties:{description:{type:"string"},url:{type:"string",format:"uri-reference"}},patternProperties:{"^x-":{}},additionalProperties:!1},ExampleXORExamples:{description:"Example and examples are mutually exclusive",not:{required:["example","examples"]}},SchemaXORContent:{description:"Schema and content are mutually exclusive, at least one is required",not:{required:["schema","content"]},oneOf:[{required:["schema"]},{required:["content"],description:"Some properties are not allowed if content is present",allOf:[{not:{required:["style"]}},{not:{required:["explode"]}},{not:{required:["allowReserved"]}},{not:{required:["example"]}},{not:{required:["examples"]}}]}]},Parameter:{type:"object",properties:{name:{type:"string"},in:{type:"string"},description:{type:"string"},required:{type:"boolean",default:!1},deprecated:{type:"boolean",default:!1},allowEmptyValue:{type:"boolean",default:!1},style:{type:"string"},explode:{type:"boolean"},allowReserved:{type:"boolean",default:!1},schema:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]},content:{type:"object",additionalProperties:{$ref:"#/definitions/MediaType"},minProperties:1,maxProperties:1},example:{},examples:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Example"},{$ref:"#/definitions/Reference"}]}}},patternProperties:{"^x-":{}},additionalProperties:!1,required:["name","in"],allOf:[{$ref:"#/definitions/ExampleXORExamples"},{$ref:"#/definitions/SchemaXORContent"}],oneOf:[{$ref:"#/definitions/PathParameter"},{$ref:"#/definitions/QueryParameter"},{$ref:"#/definitions/HeaderParameter"},{$ref:"#/definitions/CookieParameter"}]},PathParameter:{description:"Parameter in path",required:["required"],properties:{in:{enum:["path"]},style:{enum:["matrix","label","simple"],default:"simple"},required:{enum:[!0]}}},QueryParameter:{description:"Parameter in query",properties:{in:{enum:["query"]},style:{enum:["form","spaceDelimited","pipeDelimited","deepObject"],default:"form"}}},HeaderParameter:{description:"Parameter in header",properties:{in:{enum:["header"]},style:{enum:["simple"],default:"simple"}}},CookieParameter:{description:"Parameter in cookie",properties:{in:{enum:["cookie"]},style:{enum:["form"],default:"form"}}},RequestBody:{type:"object",required:["content"],properties:{description:{type:"string"},content:{type:"object",additionalProperties:{$ref:"#/definitions/MediaType"}},required:{type:"boolean",default:!1}},patternProperties:{"^x-":{}},additionalProperties:!1},SecurityScheme:{oneOf:[{$ref:"#/definitions/APIKeySecurityScheme"},{$ref:"#/definitions/HTTPSecurityScheme"},{$ref:"#/definitions/OAuth2SecurityScheme"},{$ref:"#/definitions/OpenIdConnectSecurityScheme"}]},APIKeySecurityScheme:{type:"object",required:["type","name","in"],properties:{type:{type:"string",enum:["apiKey"]},name:{type:"string"},in:{type:"string",enum:["header","query","cookie"]},description:{type:"string"}},patternProperties:{"^x-":{}},additionalProperties:!1},HTTPSecurityScheme:{type:"object",required:["scheme","type"],properties:{scheme:{type:"string"},bearerFormat:{type:"string"},description:{type:"string"},type:{type:"string",enum:["http"]}},patternProperties:{"^x-":{}},additionalProperties:!1,oneOf:[{description:"Bearer",properties:{scheme:{type:"string",pattern:"^[Bb][Ee][Aa][Rr][Ee][Rr]$"}}},{description:"Non Bearer",not:{required:["bearerFormat"]},properties:{scheme:{not:{type:"string",pattern:"^[Bb][Ee][Aa][Rr][Ee][Rr]$"}}}}]},OAuth2SecurityScheme:{type:"object",required:["type","flows"],properties:{type:{type:"string",enum:["oauth2"]},flows:{$ref:"#/definitions/OAuthFlows"},description:{type:"string"}},patternProperties:{"^x-":{}},additionalProperties:!1},OpenIdConnectSecurityScheme:{type:"object",required:["type","openIdConnectUrl"],properties:{type:{type:"string",enum:["openIdConnect"]},openIdConnectUrl:{type:"string",format:"uri-reference"},description:{type:"string"}},patternProperties:{"^x-":{}},additionalProperties:!1},OAuthFlows:{type:"object",properties:{implicit:{$ref:"#/definitions/ImplicitOAuthFlow"},password:{$ref:"#/definitions/PasswordOAuthFlow"},clientCredentials:{$ref:"#/definitions/ClientCredentialsFlow"},authorizationCode:{$ref:"#/definitions/AuthorizationCodeOAuthFlow"}},patternProperties:{"^x-":{}},additionalProperties:!1},ImplicitOAuthFlow:{type:"object",required:["authorizationUrl","scopes"],properties:{authorizationUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{type:"object",additionalProperties:{type:"string"}}},patternProperties:{"^x-":{}},additionalProperties:!1},PasswordOAuthFlow:{type:"object",required:["tokenUrl","scopes"],properties:{tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{type:"object",additionalProperties:{type:"string"}}},patternProperties:{"^x-":{}},additionalProperties:!1},ClientCredentialsFlow:{type:"object",required:["tokenUrl","scopes"],properties:{tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{type:"object",additionalProperties:{type:"string"}}},patternProperties:{"^x-":{}},additionalProperties:!1},AuthorizationCodeOAuthFlow:{type:"object",required:["authorizationUrl","tokenUrl","scopes"],properties:{authorizationUrl:{type:"string",format:"uri-reference"},tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{type:"object",additionalProperties:{type:"string"}}},patternProperties:{"^x-":{}},additionalProperties:!1},Link:{type:"object",properties:{operationId:{type:"string"},operationRef:{type:"string",format:"uri-reference"},parameters:{type:"object",additionalProperties:{}},requestBody:{},description:{type:"string"},server:{$ref:"#/definitions/Server"}},patternProperties:{"^x-":{}},additionalProperties:!1,not:{description:"Operation Id and Operation Ref are mutually exclusive",required:["operationId","operationRef"]}},Callback:{type:"object",additionalProperties:{$ref:"#/definitions/PathItem"},patternProperties:{"^x-":{}}},Encoding:{type:"object",properties:{contentType:{type:"string"},headers:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Header"},{$ref:"#/definitions/Reference"}]}},style:{type:"string",enum:["form","spaceDelimited","pipeDelimited","deepObject"]},explode:{type:"boolean"},allowReserved:{type:"boolean",default:!1}},patternProperties:{"^x-":{}},additionalProperties:!1}}};var b4={title:"A JSON Schema for Swagger 2.0 API.",id:"http://swagger.io/v2/schema.json#",$schema:"http://json-schema.org/draft-04/schema#",type:"object",required:["swagger","info","paths"],additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{swagger:{type:"string",enum:["2.0"],description:"The Swagger version of this document."},info:{$ref:"#/definitions/info"},host:{type:"string",pattern:"^[^{}/ :\\\\]+(?::\\d+)?$",description:"The host (name or ip) of the API. Example: 'swagger.io'"},basePath:{type:"string",pattern:"^/",description:"The base path to the API. Example: '/api'."},schemes:{$ref:"#/definitions/schemesList"},consumes:{description:"A list of MIME types accepted by the API.",allOf:[{$ref:"#/definitions/mediaTypeList"}]},produces:{description:"A list of MIME types the API can produce.",allOf:[{$ref:"#/definitions/mediaTypeList"}]},paths:{$ref:"#/definitions/paths"},definitions:{$ref:"#/definitions/definitions"},parameters:{$ref:"#/definitions/parameterDefinitions"},responses:{$ref:"#/definitions/responseDefinitions"},security:{$ref:"#/definitions/security"},securityDefinitions:{$ref:"#/definitions/securityDefinitions"},tags:{type:"array",items:{$ref:"#/definitions/tag"},uniqueItems:!0},externalDocs:{$ref:"#/definitions/externalDocs"}},definitions:{info:{type:"object",description:"General information about the API.",required:["version","title"],additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{title:{type:"string",description:"A unique and precise title of the API."},version:{type:"string",description:"A semantic version number of the API."},description:{type:"string",description:"A longer description of the API. Should be different from the title. GitHub Flavored Markdown is allowed."},termsOfService:{type:"string",description:"The terms of service for the API."},contact:{$ref:"#/definitions/contact"},license:{$ref:"#/definitions/license"}}},contact:{type:"object",description:"Contact information for the owners of the API.",additionalProperties:!1,properties:{name:{type:"string",description:"The identifying name of the contact person/organization."},url:{type:"string",description:"The URL pointing to the contact information.",format:"uri"},email:{type:"string",description:"The email address of the contact person/organization.",format:"email"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},license:{type:"object",required:["name"],additionalProperties:!1,properties:{name:{type:"string",description:"The name of the license type. It's encouraged to use an OSI compatible license."},url:{type:"string",description:"The URL pointing to the license.",format:"uri"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},paths:{type:"object",description:"Relative paths to the individual endpoints. They must be relative to the 'basePath'.",patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"},"^/":{$ref:"#/definitions/pathItem"}},additionalProperties:!1},definitions:{type:"object",additionalProperties:{$ref:"#/definitions/schema"},description:"One or more JSON objects describing the schemas being consumed and produced by the API."},parameterDefinitions:{type:"object",additionalProperties:{$ref:"#/definitions/parameter"},description:"One or more JSON representations for parameters"},responseDefinitions:{type:"object",additionalProperties:{$ref:"#/definitions/response"},description:"One or more JSON representations for responses"},externalDocs:{type:"object",additionalProperties:!1,description:"information about external documentation",required:["url"],properties:{description:{type:"string"},url:{type:"string",format:"uri"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},examples:{type:"object",additionalProperties:!0},mimeType:{type:"string",description:"The MIME type of the HTTP message."},operation:{type:"object",required:["responses"],additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{tags:{type:"array",items:{type:"string"},uniqueItems:!0},summary:{type:"string",description:"A brief summary of the operation."},description:{type:"string",description:"A longer description of the operation, GitHub Flavored Markdown is allowed."},externalDocs:{$ref:"#/definitions/externalDocs"},operationId:{type:"string",description:"A unique identifier of the operation."},produces:{description:"A list of MIME types the API can produce.",allOf:[{$ref:"#/definitions/mediaTypeList"}]},consumes:{description:"A list of MIME types the API can consume.",allOf:[{$ref:"#/definitions/mediaTypeList"}]},parameters:{$ref:"#/definitions/parametersList"},responses:{$ref:"#/definitions/responses"},schemes:{$ref:"#/definitions/schemesList"},deprecated:{type:"boolean",default:!1},security:{$ref:"#/definitions/security"}}},pathItem:{type:"object",additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{$ref:{type:"string"},get:{$ref:"#/definitions/operation"},put:{$ref:"#/definitions/operation"},post:{$ref:"#/definitions/operation"},delete:{$ref:"#/definitions/operation"},options:{$ref:"#/definitions/operation"},head:{$ref:"#/definitions/operation"},patch:{$ref:"#/definitions/operation"},parameters:{$ref:"#/definitions/parametersList"}}},responses:{type:"object",description:"Response objects names can either be any valid HTTP status code or 'default'.",minProperties:1,additionalProperties:!1,patternProperties:{"^([0-9]{3})$|^(default)$":{$ref:"#/definitions/responseValue"},"^x-":{$ref:"#/definitions/vendorExtension"}},not:{type:"object",additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}}},responseValue:{oneOf:[{$ref:"#/definitions/response"},{$ref:"#/definitions/jsonReference"}]},response:{type:"object",required:["description"],properties:{description:{type:"string"},schema:{oneOf:[{$ref:"#/definitions/schema"},{$ref:"#/definitions/fileSchema"}]},headers:{$ref:"#/definitions/headers"},examples:{$ref:"#/definitions/examples"}},additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},headers:{type:"object",additionalProperties:{$ref:"#/definitions/header"}},header:{type:"object",additionalProperties:!1,required:["type"],properties:{type:{type:"string",enum:["string","number","integer","boolean","array"]},format:{type:"string"},items:{$ref:"#/definitions/primitivesItems"},collectionFormat:{$ref:"#/definitions/collectionFormat"},default:{$ref:"#/definitions/default"},maximum:{$ref:"#/definitions/maximum"},exclusiveMaximum:{$ref:"#/definitions/exclusiveMaximum"},minimum:{$ref:"#/definitions/minimum"},exclusiveMinimum:{$ref:"#/definitions/exclusiveMinimum"},maxLength:{$ref:"#/definitions/maxLength"},minLength:{$ref:"#/definitions/minLength"},pattern:{$ref:"#/definitions/pattern"},maxItems:{$ref:"#/definitions/maxItems"},minItems:{$ref:"#/definitions/minItems"},uniqueItems:{$ref:"#/definitions/uniqueItems"},enum:{$ref:"#/definitions/enum"},multipleOf:{$ref:"#/definitions/multipleOf"},description:{type:"string"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},vendorExtension:{description:"Any property starting with x- is valid.",additionalProperties:!0,additionalItems:!0},bodyParameter:{type:"object",required:["name","in","schema"],patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{description:{type:"string",description:"A brief description of the parameter. This could contain examples of use. GitHub Flavored Markdown is allowed."},name:{type:"string",description:"The name of the parameter."},in:{type:"string",description:"Determines the location of the parameter.",enum:["body"]},required:{type:"boolean",description:"Determines whether or not this parameter is required or optional.",default:!1},schema:{$ref:"#/definitions/schema"}},additionalProperties:!1},headerParameterSubSchema:{additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{required:{type:"boolean",description:"Determines whether or not this parameter is required or optional.",default:!1},in:{type:"string",description:"Determines the location of the parameter.",enum:["header"]},description:{type:"string",description:"A brief description of the parameter. This could contain examples of use. GitHub Flavored Markdown is allowed."},name:{type:"string",description:"The name of the parameter."},type:{type:"string",enum:["string","number","boolean","integer","array"]},format:{type:"string"},items:{$ref:"#/definitions/primitivesItems"},collectionFormat:{$ref:"#/definitions/collectionFormat"},default:{$ref:"#/definitions/default"},maximum:{$ref:"#/definitions/maximum"},exclusiveMaximum:{$ref:"#/definitions/exclusiveMaximum"},minimum:{$ref:"#/definitions/minimum"},exclusiveMinimum:{$ref:"#/definitions/exclusiveMinimum"},maxLength:{$ref:"#/definitions/maxLength"},minLength:{$ref:"#/definitions/minLength"},pattern:{$ref:"#/definitions/pattern"},maxItems:{$ref:"#/definitions/maxItems"},minItems:{$ref:"#/definitions/minItems"},uniqueItems:{$ref:"#/definitions/uniqueItems"},enum:{$ref:"#/definitions/enum"},multipleOf:{$ref:"#/definitions/multipleOf"}}},queryParameterSubSchema:{additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{required:{type:"boolean",description:"Determines whether or not this parameter is required or optional.",default:!1},in:{type:"string",description:"Determines the location of the parameter.",enum:["query"]},description:{type:"string",description:"A brief description of the parameter. This could contain examples of use. GitHub Flavored Markdown is allowed."},name:{type:"string",description:"The name of the parameter."},allowEmptyValue:{type:"boolean",default:!1,description:"allows sending a parameter by name only or with an empty value."},type:{type:"string",enum:["string","number","boolean","integer","array"]},format:{type:"string"},items:{$ref:"#/definitions/primitivesItems"},collectionFormat:{$ref:"#/definitions/collectionFormatWithMulti"},default:{$ref:"#/definitions/default"},maximum:{$ref:"#/definitions/maximum"},exclusiveMaximum:{$ref:"#/definitions/exclusiveMaximum"},minimum:{$ref:"#/definitions/minimum"},exclusiveMinimum:{$ref:"#/definitions/exclusiveMinimum"},maxLength:{$ref:"#/definitions/maxLength"},minLength:{$ref:"#/definitions/minLength"},pattern:{$ref:"#/definitions/pattern"},maxItems:{$ref:"#/definitions/maxItems"},minItems:{$ref:"#/definitions/minItems"},uniqueItems:{$ref:"#/definitions/uniqueItems"},enum:{$ref:"#/definitions/enum"},multipleOf:{$ref:"#/definitions/multipleOf"}}},formDataParameterSubSchema:{additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{required:{type:"boolean",description:"Determines whether or not this parameter is required or optional.",default:!1},in:{type:"string",description:"Determines the location of the parameter.",enum:["formData"]},description:{type:"string",description:"A brief description of the parameter. This could contain examples of use. GitHub Flavored Markdown is allowed."},name:{type:"string",description:"The name of the parameter."},allowEmptyValue:{type:"boolean",default:!1,description:"allows sending a parameter by name only or with an empty value."},type:{type:"string",enum:["string","number","boolean","integer","array","file"]},format:{type:"string"},items:{$ref:"#/definitions/primitivesItems"},collectionFormat:{$ref:"#/definitions/collectionFormatWithMulti"},default:{$ref:"#/definitions/default"},maximum:{$ref:"#/definitions/maximum"},exclusiveMaximum:{$ref:"#/definitions/exclusiveMaximum"},minimum:{$ref:"#/definitions/minimum"},exclusiveMinimum:{$ref:"#/definitions/exclusiveMinimum"},maxLength:{$ref:"#/definitions/maxLength"},minLength:{$ref:"#/definitions/minLength"},pattern:{$ref:"#/definitions/pattern"},maxItems:{$ref:"#/definitions/maxItems"},minItems:{$ref:"#/definitions/minItems"},uniqueItems:{$ref:"#/definitions/uniqueItems"},enum:{$ref:"#/definitions/enum"},multipleOf:{$ref:"#/definitions/multipleOf"}}},pathParameterSubSchema:{additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},required:["required"],properties:{required:{type:"boolean",enum:[!0],description:"Determines whether or not this parameter is required or optional."},in:{type:"string",description:"Determines the location of the parameter.",enum:["path"]},description:{type:"string",description:"A brief description of the parameter. This could contain examples of use. GitHub Flavored Markdown is allowed."},name:{type:"string",description:"The name of the parameter."},type:{type:"string",enum:["string","number","boolean","integer","array"]},format:{type:"string"},items:{$ref:"#/definitions/primitivesItems"},collectionFormat:{$ref:"#/definitions/collectionFormat"},default:{$ref:"#/definitions/default"},maximum:{$ref:"#/definitions/maximum"},exclusiveMaximum:{$ref:"#/definitions/exclusiveMaximum"},minimum:{$ref:"#/definitions/minimum"},exclusiveMinimum:{$ref:"#/definitions/exclusiveMinimum"},maxLength:{$ref:"#/definitions/maxLength"},minLength:{$ref:"#/definitions/minLength"},pattern:{$ref:"#/definitions/pattern"},maxItems:{$ref:"#/definitions/maxItems"},minItems:{$ref:"#/definitions/minItems"},uniqueItems:{$ref:"#/definitions/uniqueItems"},enum:{$ref:"#/definitions/enum"},multipleOf:{$ref:"#/definitions/multipleOf"}}},nonBodyParameter:{type:"object",required:["name","in","type"],oneOf:[{$ref:"#/definitions/headerParameterSubSchema"},{$ref:"#/definitions/formDataParameterSubSchema"},{$ref:"#/definitions/queryParameterSubSchema"},{$ref:"#/definitions/pathParameterSubSchema"}]},parameter:{oneOf:[{$ref:"#/definitions/bodyParameter"},{$ref:"#/definitions/nonBodyParameter"}]},schema:{type:"object",description:"A deterministic version of a JSON Schema object.",patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{$ref:{type:"string"},format:{type:"string"},title:{$ref:"http://json-schema.org/draft-04/schema#/properties/title"},description:{$ref:"http://json-schema.org/draft-04/schema#/properties/description"},default:{$ref:"http://json-schema.org/draft-04/schema#/properties/default"},multipleOf:{$ref:"http://json-schema.org/draft-04/schema#/properties/multipleOf"},maximum:{$ref:"http://json-schema.org/draft-04/schema#/properties/maximum"},exclusiveMaximum:{$ref:"http://json-schema.org/draft-04/schema#/properties/exclusiveMaximum"},minimum:{$ref:"http://json-schema.org/draft-04/schema#/properties/minimum"},exclusiveMinimum:{$ref:"http://json-schema.org/draft-04/schema#/properties/exclusiveMinimum"},maxLength:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveInteger"},minLength:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveIntegerDefault0"},pattern:{$ref:"http://json-schema.org/draft-04/schema#/properties/pattern"},maxItems:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveInteger"},minItems:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveIntegerDefault0"},uniqueItems:{$ref:"http://json-schema.org/draft-04/schema#/properties/uniqueItems"},maxProperties:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveInteger"},minProperties:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveIntegerDefault0"},required:{$ref:"http://json-schema.org/draft-04/schema#/definitions/stringArray"},enum:{$ref:"http://json-schema.org/draft-04/schema#/properties/enum"},additionalProperties:{anyOf:[{$ref:"#/definitions/schema"},{type:"boolean"}],default:{}},type:{$ref:"http://json-schema.org/draft-04/schema#/properties/type"},items:{anyOf:[{$ref:"#/definitions/schema"},{type:"array",minItems:1,items:{$ref:"#/definitions/schema"}}],default:{}},allOf:{type:"array",minItems:1,items:{$ref:"#/definitions/schema"}},properties:{type:"object",additionalProperties:{$ref:"#/definitions/schema"},default:{}},discriminator:{type:"string"},readOnly:{type:"boolean",default:!1},xml:{$ref:"#/definitions/xml"},externalDocs:{$ref:"#/definitions/externalDocs"},example:{}},additionalProperties:!1},fileSchema:{type:"object",description:"A deterministic version of a JSON Schema object.",patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},required:["type"],properties:{format:{type:"string"},title:{$ref:"http://json-schema.org/draft-04/schema#/properties/title"},description:{$ref:"http://json-schema.org/draft-04/schema#/properties/description"},default:{$ref:"http://json-schema.org/draft-04/schema#/properties/default"},required:{$ref:"http://json-schema.org/draft-04/schema#/definitions/stringArray"},type:{type:"string",enum:["file"]},readOnly:{type:"boolean",default:!1},externalDocs:{$ref:"#/definitions/externalDocs"},example:{}},additionalProperties:!1},primitivesItems:{type:"object",additionalProperties:!1,properties:{type:{type:"string",enum:["string","number","integer","boolean","array"]},format:{type:"string"},items:{$ref:"#/definitions/primitivesItems"},collectionFormat:{$ref:"#/definitions/collectionFormat"},default:{$ref:"#/definitions/default"},maximum:{$ref:"#/definitions/maximum"},exclusiveMaximum:{$ref:"#/definitions/exclusiveMaximum"},minimum:{$ref:"#/definitions/minimum"},exclusiveMinimum:{$ref:"#/definitions/exclusiveMinimum"},maxLength:{$ref:"#/definitions/maxLength"},minLength:{$ref:"#/definitions/minLength"},pattern:{$ref:"#/definitions/pattern"},maxItems:{$ref:"#/definitions/maxItems"},minItems:{$ref:"#/definitions/minItems"},uniqueItems:{$ref:"#/definitions/uniqueItems"},enum:{$ref:"#/definitions/enum"},multipleOf:{$ref:"#/definitions/multipleOf"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},security:{type:"array",items:{$ref:"#/definitions/securityRequirement"},uniqueItems:!0},securityRequirement:{type:"object",additionalProperties:{type:"array",items:{type:"string"},uniqueItems:!0}},xml:{type:"object",additionalProperties:!1,properties:{name:{type:"string"},namespace:{type:"string"},prefix:{type:"string"},attribute:{type:"boolean",default:!1},wrapped:{type:"boolean",default:!1}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},tag:{type:"object",additionalProperties:!1,required:["name"],properties:{name:{type:"string"},description:{type:"string"},externalDocs:{$ref:"#/definitions/externalDocs"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},securityDefinitions:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/basicAuthenticationSecurity"},{$ref:"#/definitions/apiKeySecurity"},{$ref:"#/definitions/oauth2ImplicitSecurity"},{$ref:"#/definitions/oauth2PasswordSecurity"},{$ref:"#/definitions/oauth2ApplicationSecurity"},{$ref:"#/definitions/oauth2AccessCodeSecurity"}]}},basicAuthenticationSecurity:{type:"object",additionalProperties:!1,required:["type"],properties:{type:{type:"string",enum:["basic"]},description:{type:"string"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},apiKeySecurity:{type:"object",additionalProperties:!1,required:["type","name","in"],properties:{type:{type:"string",enum:["apiKey"]},name:{type:"string"},in:{type:"string",enum:["header","query"]},description:{type:"string"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},oauth2ImplicitSecurity:{type:"object",additionalProperties:!1,required:["type","flow","authorizationUrl"],properties:{type:{type:"string",enum:["oauth2"]},flow:{type:"string",enum:["implicit"]},scopes:{$ref:"#/definitions/oauth2Scopes"},authorizationUrl:{type:"string",format:"uri"},description:{type:"string"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},oauth2PasswordSecurity:{type:"object",additionalProperties:!1,required:["type","flow","tokenUrl"],properties:{type:{type:"string",enum:["oauth2"]},flow:{type:"string",enum:["password"]},scopes:{$ref:"#/definitions/oauth2Scopes"},tokenUrl:{type:"string",format:"uri"},description:{type:"string"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},oauth2ApplicationSecurity:{type:"object",additionalProperties:!1,required:["type","flow","tokenUrl"],properties:{type:{type:"string",enum:["oauth2"]},flow:{type:"string",enum:["application"]},scopes:{$ref:"#/definitions/oauth2Scopes"},tokenUrl:{type:"string",format:"uri"},description:{type:"string"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},oauth2AccessCodeSecurity:{type:"object",additionalProperties:!1,required:["type","flow","authorizationUrl","tokenUrl"],properties:{type:{type:"string",enum:["oauth2"]},flow:{type:"string",enum:["accessCode"]},scopes:{$ref:"#/definitions/oauth2Scopes"},authorizationUrl:{type:"string",format:"uri"},tokenUrl:{type:"string",format:"uri"},description:{type:"string"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},oauth2Scopes:{type:"object",additionalProperties:{type:"string"}},mediaTypeList:{type:"array",items:{$ref:"#/definitions/mimeType"},uniqueItems:!0},parametersList:{type:"array",description:"The parameters needed to send a valid API call.",additionalItems:!1,items:{oneOf:[{$ref:"#/definitions/parameter"},{$ref:"#/definitions/jsonReference"}]},uniqueItems:!0},schemesList:{type:"array",description:"The transfer protocol of the API.",items:{type:"string",enum:["http","https","ws","wss"]},uniqueItems:!0},collectionFormat:{type:"string",enum:["csv","ssv","tsv","pipes"],default:"csv"},collectionFormatWithMulti:{type:"string",enum:["csv","ssv","tsv","pipes","multi"],default:"csv"},title:{$ref:"http://json-schema.org/draft-04/schema#/properties/title"},description:{$ref:"http://json-schema.org/draft-04/schema#/properties/description"},default:{$ref:"http://json-schema.org/draft-04/schema#/properties/default"},multipleOf:{$ref:"http://json-schema.org/draft-04/schema#/properties/multipleOf"},maximum:{$ref:"http://json-schema.org/draft-04/schema#/properties/maximum"},exclusiveMaximum:{$ref:"http://json-schema.org/draft-04/schema#/properties/exclusiveMaximum"},minimum:{$ref:"http://json-schema.org/draft-04/schema#/properties/minimum"},exclusiveMinimum:{$ref:"http://json-schema.org/draft-04/schema#/properties/exclusiveMinimum"},maxLength:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveInteger"},minLength:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveIntegerDefault0"},pattern:{$ref:"http://json-schema.org/draft-04/schema#/properties/pattern"},maxItems:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveInteger"},minItems:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveIntegerDefault0"},uniqueItems:{$ref:"http://json-schema.org/draft-04/schema#/properties/uniqueItems"},enum:{$ref:"http://json-schema.org/draft-04/schema#/properties/enum"},jsonReference:{type:"object",required:["$ref"],additionalProperties:!1,properties:{$ref:{type:"string"}}}}};var OO={id:"umf.openapi",version:"0.1.0",coreVersion:"0.1.0",description:"OpenAPI JSON/YAML exact tree and source preservation",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:openapi:0.1.0",type:"object",required:["profile","root","originalSource","originalFormat"],properties:{profile:{const:"openapi-json-yaml-0.1"},root:{$ref:"#/$defs/node"},originalSource:{type:"string"},originalFormat:{enum:["json","yaml"]},baseUri:{type:"string",minLength:1},resources:{type:"array",items:{type:"object",required:["uri","root","originalSource","originalFormat"],properties:{uri:{type:"string",minLength:1},root:{$ref:"#/$defs/node"},originalSource:{type:"string"},originalFormat:{enum:["json","yaml"]}}}}},$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}},dependentRequired:{resources:["baseUri"]}},semantics:"CONTRACT-011. Exact native JSON tree and source archive; pinned OpenAPI/Swagger object schemas provide bounded validation, not reference, transport or runtime conformance.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"OpenAPI",version:"Swagger 2.0 schema 2017-08-27; OpenAPI 3.0 schema 2024-10-18; 3.1 schema 2026-08-03; 3.2 schema 2026-08-30",subset:"JSON-compatible JSON/YAML standalone descriptions; 2.0/3.0 check the Schema Object subset in their official schemas, known 3.1/3.2 embedded dialect keyword syntax is checked; unknown dialects are retained without reinterpretation; references and runtime rules remain incomplete; explicit URI-addressed resource archives and literal document-pointer lookup, without schema scope inference"},evidence:["tests/openapi/native.test.ts","tests/openapi/corpus.test.ts","fixtures/openapi/corpus-oracle-results.json","tests/openapi/bundle.test.ts","fixtures/openapi/resource-bundle-oracle-results.json","tests/openapi/schemas.test.ts","fixtures/openapi/embedded-schema-oracle-results.json","tests/openapi/references.test.ts","fixtures/openapi/reference-oracle-results.json","tests/openapi/extraction.test.ts","tests/openapi/scope.test.ts","fixtures/openapi/scope-oracle-results.json","tests/openapi/dynamic.test.ts","fixtures/openapi/dynamic-oracle-results.json"]}};var v4={$id:"https://spec.openapis.org/oas/3.1/schema/2026-08-03",$schema:"https://json-schema.org/draft/2020-12/schema",description:"The description of OpenAPI v3.1.x Documents without Schema Object validation",type:"object",properties:{openapi:{type:"string",pattern:"^3\\.1\\.\\d+(-.+)?$"},info:{$ref:"#/$defs/info"},jsonSchemaDialect:{type:"string",format:"uri-reference",default:"https://spec.openapis.org/oas/3.1/dialect/2024-11-10"},servers:{type:"array",items:{$ref:"#/$defs/server"},default:[{url:"/"}]},paths:{$ref:"#/$defs/paths"},webhooks:{type:"object",additionalProperties:{$ref:"#/$defs/path-item"}},components:{$ref:"#/$defs/components"},security:{type:"array",items:{$ref:"#/$defs/security-requirement"}},tags:{type:"array",items:{$ref:"#/$defs/tag"}},externalDocs:{$ref:"#/$defs/external-documentation"}},required:["openapi","info"],anyOf:[{required:["paths"]},{required:["components"]},{required:["webhooks"]}],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1,$defs:{info:{$comment:"https://spec.openapis.org/oas/v3.1#info-object",type:"object",properties:{title:{type:"string"},summary:{type:"string"},description:{type:"string"},termsOfService:{type:"string",format:"uri-reference"},contact:{$ref:"#/$defs/contact"},license:{$ref:"#/$defs/license"},version:{type:"string"}},required:["title","version"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},contact:{$comment:"https://spec.openapis.org/oas/v3.1#contact-object",type:"object",properties:{name:{type:"string"},url:{type:"string",format:"uri-reference"},email:{type:"string",format:"email"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},license:{$comment:"https://spec.openapis.org/oas/v3.1#license-object",type:"object",properties:{name:{type:"string"},identifier:{type:"string"},url:{type:"string",format:"uri-reference"}},required:["name"],dependentSchemas:{identifier:{not:{required:["url"]}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},server:{$comment:"https://spec.openapis.org/oas/v3.1#server-object",type:"object",properties:{url:{type:"string"},description:{type:"string"},variables:{type:"object",additionalProperties:{$ref:"#/$defs/server-variable"}}},required:["url"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"server-variable":{$comment:"https://spec.openapis.org/oas/v3.1#server-variable-object",type:"object",properties:{enum:{type:"array",items:{type:"string"},minItems:1},default:{type:"string"},description:{type:"string"}},required:["default"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},components:{$comment:"https://spec.openapis.org/oas/v3.1#components-object",type:"object",properties:{schemas:{type:"object",additionalProperties:{$dynamicRef:"#meta"}},responses:{type:"object",additionalProperties:{$ref:"#/$defs/response-or-reference"}},parameters:{type:"object",additionalProperties:{$ref:"#/$defs/parameter-or-reference"}},examples:{type:"object",additionalProperties:{$ref:"#/$defs/example-or-reference"}},requestBodies:{type:"object",additionalProperties:{$ref:"#/$defs/request-body-or-reference"}},headers:{type:"object",additionalProperties:{$ref:"#/$defs/header-or-reference"}},securitySchemes:{type:"object",additionalProperties:{$ref:"#/$defs/security-scheme-or-reference"}},links:{type:"object",additionalProperties:{$ref:"#/$defs/link-or-reference"}},callbacks:{type:"object",additionalProperties:{$ref:"#/$defs/callbacks-or-reference"}},pathItems:{type:"object",additionalProperties:{$ref:"#/$defs/path-item"}}},patternProperties:{"^(?:schemas|responses|parameters|examples|requestBodies|headers|securitySchemes|links|callbacks|pathItems)$":{$comment:"Enumerating all of the property names in the regex above is necessary for unevaluatedProperties to work as expected",propertyNames:{pattern:"^[a-zA-Z0-9._-]+$"}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},paths:{$comment:"https://spec.openapis.org/oas/v3.1#paths-object",type:"object",patternProperties:{"^/":{$ref:"#/$defs/path-item"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"path-item":{$comment:"https://spec.openapis.org/oas/v3.1#path-item-object",type:"object",properties:{$ref:{type:"string",format:"uri-reference"},summary:{type:"string"},description:{type:"string"},servers:{type:"array",items:{$ref:"#/$defs/server"}},parameters:{type:"array",items:{$ref:"#/$defs/parameter-or-reference"}},get:{$ref:"#/$defs/operation"},put:{$ref:"#/$defs/operation"},post:{$ref:"#/$defs/operation"},delete:{$ref:"#/$defs/operation"},options:{$ref:"#/$defs/operation"},head:{$ref:"#/$defs/operation"},patch:{$ref:"#/$defs/operation"},trace:{$ref:"#/$defs/operation"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},operation:{$comment:"https://spec.openapis.org/oas/v3.1#operation-object",type:"object",properties:{tags:{type:"array",items:{type:"string"}},summary:{type:"string"},description:{type:"string"},externalDocs:{$ref:"#/$defs/external-documentation"},operationId:{type:"string"},parameters:{type:"array",items:{$ref:"#/$defs/parameter-or-reference"}},requestBody:{$ref:"#/$defs/request-body-or-reference"},responses:{$ref:"#/$defs/responses"},callbacks:{type:"object",additionalProperties:{$ref:"#/$defs/callbacks-or-reference"}},deprecated:{default:!1,type:"boolean"},security:{type:"array",items:{$ref:"#/$defs/security-requirement"}},servers:{type:"array",items:{$ref:"#/$defs/server"}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"external-documentation":{$comment:"https://spec.openapis.org/oas/v3.1#external-documentation-object",type:"object",properties:{description:{type:"string"},url:{type:"string",format:"uri-reference"}},required:["url"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},parameter:{$comment:"https://spec.openapis.org/oas/v3.1#parameter-object",type:"object",properties:{name:{type:"string"},in:{enum:["query","header","path","cookie"]},description:{type:"string"},required:{default:!1,type:"boolean"},deprecated:{default:!1,type:"boolean"},schema:{$dynamicRef:"#meta"},content:{$ref:"#/$defs/content",minProperties:1,maxProperties:1}},required:["name","in"],oneOf:[{required:["schema"]},{required:["content"]}],if:{properties:{in:{const:"query"}}},then:{properties:{allowEmptyValue:{default:!1,type:"boolean"}}},dependentSchemas:{schema:{properties:{style:{type:"string"},explode:{type:"boolean"}},allOf:[{$ref:"#/$defs/examples"},{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-path"},{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-header"},{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-query"},{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-cookie"}],$defs:{"styles-for-path":{if:{properties:{in:{const:"path"}}},then:{properties:{name:{pattern:"^[^{}]+$"},style:{default:"simple",enum:["matrix","label","simple"]},required:{const:!0},explode:{default:!1}},required:["required"]}},"styles-for-header":{if:{properties:{in:{const:"header"}}},then:{properties:{style:{default:"simple",const:"simple"},explode:{default:!1}}}},"styles-for-query":{if:{properties:{in:{const:"query"}}},then:{properties:{style:{default:"form",enum:["form","spaceDelimited","pipeDelimited","deepObject"]},allowReserved:{default:!1,type:"boolean"}},$ref:"#/$defs/explode-for-form"}},"styles-for-cookie":{if:{properties:{in:{const:"cookie"}}},then:{properties:{style:{default:"form",const:"form"}},$ref:"#/$defs/explode-for-form"}}}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"parameter-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/parameter"}},"request-body":{$comment:"https://spec.openapis.org/oas/v3.1#request-body-object",type:"object",properties:{description:{type:"string"},content:{$ref:"#/$defs/content"},required:{default:!1,type:"boolean"}},required:["content"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"request-body-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/request-body"}},content:{$comment:"https://spec.openapis.org/oas/v3.1#fixed-fields-10",type:"object",additionalProperties:{$ref:"#/$defs/media-type"},propertyNames:{format:"media-range"}},"media-type":{$comment:"https://spec.openapis.org/oas/v3.1#media-type-object",type:"object",properties:{schema:{$dynamicRef:"#meta"},encoding:{type:"object",additionalProperties:{$ref:"#/$defs/encoding"}}},allOf:[{$ref:"#/$defs/specification-extensions"},{$ref:"#/$defs/examples"}],unevaluatedProperties:!1},encoding:{$comment:"https://spec.openapis.org/oas/v3.1#encoding-object",type:"object",properties:{contentType:{$comment:"one or more comma-separated media-ranges",type:"string"},headers:{type:"object",additionalProperties:{$ref:"#/$defs/header-or-reference"}},style:{enum:["form","spaceDelimited","pipeDelimited","deepObject"]},explode:{type:"boolean"},allowReserved:{type:"boolean"}},dependentSchemas:{style:{properties:{allowReserved:{default:!1}},$ref:"#/$defs/explode-for-form"},explode:{properties:{style:{default:"form"},allowReserved:{default:!1}}},allowReserved:{properties:{style:{default:"form"}},$ref:"#/$defs/explode-for-form"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},responses:{$comment:"https://spec.openapis.org/oas/v3.1#responses-object",type:"object",properties:{default:{$ref:"#/$defs/response-or-reference"}},patternProperties:{"^[1-5](?:[0-9]{2}|XX)$":{$ref:"#/$defs/response-or-reference"}},minProperties:1,$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1,if:{$comment:"either default, or at least one response code property must exist",patternProperties:{"^[1-5](?:[0-9]{2}|XX)$":!1}},then:{required:["default"]}},response:{$comment:"https://spec.openapis.org/oas/v3.1#response-object",type:"object",properties:{description:{type:"string"},headers:{type:"object",additionalProperties:{$ref:"#/$defs/header-or-reference"}},content:{$ref:"#/$defs/content"},links:{type:"object",additionalProperties:{$ref:"#/$defs/link-or-reference"}}},required:["description"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"response-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/response"}},callbacks:{$comment:"https://spec.openapis.org/oas/v3.1#callback-object",type:"object",$ref:"#/$defs/specification-extensions",additionalProperties:{$ref:"#/$defs/path-item"}},"callbacks-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/callbacks"}},example:{$comment:"https://spec.openapis.org/oas/v3.1#example-object",type:"object",properties:{summary:{type:"string"},description:{type:"string"},value:!0,externalValue:{type:"string",format:"uri-reference"}},not:{required:["value","externalValue"]},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"example-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/example"}},link:{$comment:"https://spec.openapis.org/oas/v3.1#link-object",type:"object",properties:{operationRef:{type:"string",format:"uri-reference"},operationId:{type:"string"},parameters:{$ref:"#/$defs/map-of-strings"},requestBody:!0,description:{type:"string"},server:{$ref:"#/$defs/server"}},oneOf:[{required:["operationRef"]},{required:["operationId"]}],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"link-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/link"}},header:{$comment:"https://spec.openapis.org/oas/v3.1#header-object",type:"object",properties:{description:{type:"string"},required:{default:!1,type:"boolean"},deprecated:{default:!1,type:"boolean"},schema:{$dynamicRef:"#meta"},content:{$ref:"#/$defs/content",minProperties:1,maxProperties:1}},oneOf:[{required:["schema"]},{required:["content"]}],dependentSchemas:{schema:{properties:{style:{default:"simple",const:"simple"},explode:{default:!1,type:"boolean"}},$ref:"#/$defs/examples"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"header-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/header"}},tag:{$comment:"https://spec.openapis.org/oas/v3.1#tag-object",type:"object",properties:{name:{type:"string"},description:{type:"string"},externalDocs:{$ref:"#/$defs/external-documentation"}},required:["name"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},reference:{$comment:"https://spec.openapis.org/oas/v3.1#reference-object",type:"object",properties:{$ref:{type:"string",format:"uri-reference"},summary:{type:"string"},description:{type:"string"}}},schema:{$comment:"https://spec.openapis.org/oas/v3.1#schema-object",$dynamicAnchor:"meta",type:["object","boolean"]},"security-scheme":{$comment:"https://spec.openapis.org/oas/v3.1#security-scheme-object",type:"object",properties:{type:{enum:["apiKey","http","mutualTLS","oauth2","openIdConnect"]},description:{type:"string"}},required:["type"],allOf:[{$ref:"#/$defs/specification-extensions"},{$ref:"#/$defs/security-scheme/$defs/type-apikey"},{$ref:"#/$defs/security-scheme/$defs/type-http"},{$ref:"#/$defs/security-scheme/$defs/type-http-bearer"},{$ref:"#/$defs/security-scheme/$defs/type-oauth2"},{$ref:"#/$defs/security-scheme/$defs/type-oidc"}],unevaluatedProperties:!1,$defs:{"type-apikey":{if:{properties:{type:{const:"apiKey"}}},then:{properties:{name:{type:"string"},in:{enum:["query","header","cookie"]}},required:["name","in"]}},"type-http":{if:{properties:{type:{const:"http"}}},then:{properties:{scheme:{type:"string"}},required:["scheme"]}},"type-http-bearer":{if:{properties:{type:{const:"http"},scheme:{type:"string",pattern:"^[Bb][Ee][Aa][Rr][Ee][Rr]$"}},required:["type","scheme"]},then:{properties:{bearerFormat:{type:"string"}}}},"type-oauth2":{if:{properties:{type:{const:"oauth2"}}},then:{properties:{flows:{$ref:"#/$defs/oauth-flows"}},required:["flows"]}},"type-oidc":{if:{properties:{type:{const:"openIdConnect"}}},then:{properties:{openIdConnectUrl:{type:"string",format:"uri-reference"}},required:["openIdConnectUrl"]}}}},"security-scheme-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/security-scheme"}},"oauth-flows":{type:"object",properties:{implicit:{$ref:"#/$defs/oauth-flows/$defs/implicit"},password:{$ref:"#/$defs/oauth-flows/$defs/password"},clientCredentials:{$ref:"#/$defs/oauth-flows/$defs/client-credentials"},authorizationCode:{$ref:"#/$defs/oauth-flows/$defs/authorization-code"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1,$defs:{implicit:{type:"object",properties:{authorizationUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["authorizationUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},password:{type:"object",properties:{tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["tokenUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"client-credentials":{type:"object",properties:{tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["tokenUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"authorization-code":{type:"object",properties:{authorizationUrl:{type:"string",format:"uri-reference"},tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["authorizationUrl","tokenUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1}}},"security-requirement":{$comment:"https://spec.openapis.org/oas/v3.1#security-requirement-object",type:"object",additionalProperties:{type:"array",items:{type:"string"}}},"specification-extensions":{$comment:"https://spec.openapis.org/oas/v3.1#specification-extensions",patternProperties:{"^x-":!0}},examples:{properties:{example:!0,examples:{type:"object",additionalProperties:{$ref:"#/$defs/example-or-reference"}}},not:{required:["example","examples"]}},"map-of-strings":{type:"object",additionalProperties:{type:"string"}},"explode-for-form":{$comment:"for encoding objects, and query and cookie parameters, style=form is the default",if:{properties:{style:{const:"form"}}},then:{properties:{explode:{default:!0}}},else:{properties:{explode:{default:!1}}}}}};var _4={$id:"https://spec.openapis.org/oas/3.2/schema/2026-08-30",$schema:"https://json-schema.org/draft/2020-12/schema",description:"The description of OpenAPI v3.2.x Documents without Schema Object validation",type:"object",properties:{openapi:{type:"string",pattern:"^3\\.2\\.[0-9]+(-.+)?$"},$self:{type:"string",format:"uri-reference",$comment:"MUST NOT contain a fragment",pattern:"^[^#]*$"},info:{$ref:"#/$defs/info"},jsonSchemaDialect:{type:"string",format:"uri-reference",default:"https://spec.openapis.org/oas/3.2/dialect/2026-02-26"},servers:{type:"array",items:{$ref:"#/$defs/server"},default:[{url:"/"}]},paths:{$ref:"#/$defs/paths"},webhooks:{type:"object",additionalProperties:{$ref:"#/$defs/path-item"}},components:{$ref:"#/$defs/components"},security:{type:"array",items:{$ref:"#/$defs/security-requirement"}},tags:{type:"array",items:{$ref:"#/$defs/tag"}},externalDocs:{$ref:"#/$defs/external-documentation"}},required:["openapi","info"],anyOf:[{required:["paths"]},{required:["components"]},{required:["webhooks"]}],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1,$defs:{info:{$comment:"https://spec.openapis.org/oas/v3.2#info-object",type:"object",properties:{title:{type:"string"},summary:{type:"string"},description:{type:"string"},termsOfService:{type:"string",format:"uri-reference"},contact:{$ref:"#/$defs/contact"},license:{$ref:"#/$defs/license"},version:{type:"string"}},required:["title","version"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},contact:{$comment:"https://spec.openapis.org/oas/v3.2#contact-object",type:"object",properties:{name:{type:"string"},url:{type:"string",format:"uri-reference"},email:{type:"string",format:"email"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},license:{$comment:"https://spec.openapis.org/oas/v3.2#license-object",type:"object",properties:{name:{type:"string"},identifier:{type:"string"},url:{type:"string",format:"uri-reference"}},required:["name"],dependentSchemas:{identifier:{not:{required:["url"]}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},server:{$comment:"https://spec.openapis.org/oas/v3.2#server-object",type:"object",properties:{url:{type:"string"},description:{type:"string"},name:{type:"string"},variables:{type:"object",additionalProperties:{$ref:"#/$defs/server-variable"}}},required:["url"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"server-variable":{$comment:"https://spec.openapis.org/oas/v3.2#server-variable-object",type:"object",properties:{enum:{type:"array",items:{type:"string"},minItems:1},default:{type:"string"},description:{type:"string"}},required:["default"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},components:{$comment:"https://spec.openapis.org/oas/v3.2#components-object",type:"object",properties:{schemas:{type:"object",additionalProperties:{$dynamicRef:"#meta"}},responses:{type:"object",additionalProperties:{$ref:"#/$defs/response-or-reference"}},parameters:{type:"object",additionalProperties:{$ref:"#/$defs/parameter-or-reference"}},examples:{type:"object",additionalProperties:{$ref:"#/$defs/example-or-reference"}},requestBodies:{type:"object",additionalProperties:{$ref:"#/$defs/request-body-or-reference"}},headers:{type:"object",additionalProperties:{$ref:"#/$defs/header-or-reference"}},securitySchemes:{type:"object",additionalProperties:{$ref:"#/$defs/security-scheme-or-reference"}},links:{type:"object",additionalProperties:{$ref:"#/$defs/link-or-reference"}},callbacks:{type:"object",additionalProperties:{$ref:"#/$defs/callbacks-or-reference"}},pathItems:{type:"object",additionalProperties:{$ref:"#/$defs/path-item"}},mediaTypes:{type:"object",additionalProperties:{$ref:"#/$defs/media-type-or-reference"}}},patternProperties:{"^(?:schemas|responses|parameters|examples|requestBodies|headers|securitySchemes|links|callbacks|pathItems|mediaTypes)$":{$comment:"Enumerating all of the property names in the regex above is necessary for unevaluatedProperties to work as expected",propertyNames:{pattern:"^[a-zA-Z0-9._-]+$"}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},paths:{$comment:"https://spec.openapis.org/oas/v3.2#paths-object",type:"object",patternProperties:{"^/":{$ref:"#/$defs/path-item"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"path-item":{$comment:"https://spec.openapis.org/oas/v3.2#path-item-object",type:"object",properties:{$ref:{type:"string",format:"uri-reference"},summary:{type:"string"},description:{type:"string"},servers:{type:"array",items:{$ref:"#/$defs/server"}},parameters:{$ref:"#/$defs/parameters"},additionalOperations:{type:"object",additionalProperties:{$ref:"#/$defs/operation"},propertyNames:{$comment:'RFC9110 restricts methods to "1*tchar" in ABNF',$ref:"#/$defs/token",not:{enum:["GET","PUT","POST","DELETE","OPTIONS","HEAD","PATCH","TRACE","QUERY"]}}},get:{$ref:"#/$defs/operation"},put:{$ref:"#/$defs/operation"},post:{$ref:"#/$defs/operation"},delete:{$ref:"#/$defs/operation"},options:{$ref:"#/$defs/operation"},head:{$ref:"#/$defs/operation"},patch:{$ref:"#/$defs/operation"},trace:{$ref:"#/$defs/operation"},query:{$ref:"#/$defs/operation"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},operation:{$comment:"https://spec.openapis.org/oas/v3.2#operation-object",type:"object",properties:{tags:{type:"array",items:{type:"string"}},summary:{type:"string"},description:{type:"string"},externalDocs:{$ref:"#/$defs/external-documentation"},operationId:{type:"string"},parameters:{$ref:"#/$defs/parameters"},requestBody:{$ref:"#/$defs/request-body-or-reference"},responses:{$ref:"#/$defs/responses"},callbacks:{type:"object",additionalProperties:{$ref:"#/$defs/callbacks-or-reference"}},deprecated:{default:!1,type:"boolean"},security:{type:"array",items:{$ref:"#/$defs/security-requirement"}},servers:{type:"array",items:{$ref:"#/$defs/server"}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"external-documentation":{$comment:"https://spec.openapis.org/oas/v3.2#external-documentation-object",type:"object",properties:{description:{type:"string"},url:{type:"string",format:"uri-reference"}},required:["url"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},parameters:{type:"array",items:{$ref:"#/$defs/parameter-or-reference"},not:{allOf:[{contains:{type:"object",properties:{in:{const:"query"}},required:["in"]}},{contains:{type:"object",properties:{in:{const:"querystring"}},required:["in"]}}]},contains:{type:"object",properties:{in:{const:"querystring"}},required:["in"]},minContains:0,maxContains:1},parameter:{$comment:"https://spec.openapis.org/oas/v3.2#parameter-object",type:"object",properties:{name:{type:"string"},in:{enum:["query","querystring","header","path","cookie"]},description:{type:"string"},required:{default:!1,type:"boolean"},deprecated:{default:!1,type:"boolean"},schema:{$dynamicRef:"#meta"},content:{$ref:"#/$defs/content",minProperties:1,maxProperties:1}},required:["name","in"],oneOf:[{required:["schema"]},{required:["content"]}],allOf:[{$ref:"#/$defs/examples"},{$ref:"#/$defs/specification-extensions"},{if:{properties:{in:{const:"query"}}},then:{properties:{allowEmptyValue:{default:!1,type:"boolean"}}}},{if:{properties:{in:{const:"querystring"}}},then:{required:["content"]}},{if:{properties:{in:{const:"path"}}},then:{properties:{name:{$comment:"see OAS 3.2.0 §4.8.2",pattern:"^[^{}]+$"}}}},{if:{properties:{in:{const:"header"}}},then:{properties:{name:{$comment:"see RFC9110 §5.1",$ref:"#/$defs/token"}}}}],dependentSchemas:{schema:{properties:{style:{type:"string"},explode:{type:"boolean"}},allOf:[{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-path"},{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-header"},{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-query"},{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-cookie"}],$defs:{"styles-for-path":{if:{properties:{in:{const:"path"}}},then:{properties:{name:{pattern:"^[^{}]+$"},style:{default:"simple",enum:["matrix","label","simple"]},required:{const:!0},explode:{default:!1},allowReserved:{type:"boolean",default:!1}},required:["required"]}},"styles-for-header":{if:{properties:{in:{const:"header"}}},then:{properties:{style:{default:"simple",const:"simple"},explode:{default:!1}}}},"styles-for-query":{if:{properties:{in:{const:"query"}}},then:{properties:{style:{default:"form",enum:["form","spaceDelimited","pipeDelimited","deepObject"]},allowReserved:{type:"boolean",default:!1}},$ref:"#/$defs/explode-for-form"}},"styles-for-cookie":{if:{properties:{in:{const:"cookie"}}},then:{properties:{style:{default:"form",enum:["form","cookie"]},explode:{default:!0}},if:{properties:{style:{const:"form"}}},then:{properties:{allowReserved:{type:"boolean",default:!1}}}}}}}},unevaluatedProperties:!1},"parameter-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/parameter"}},"request-body":{$comment:"https://spec.openapis.org/oas/v3.2#request-body-object",type:"object",properties:{description:{type:"string"},content:{$ref:"#/$defs/content"},required:{default:!1,type:"boolean"}},required:["content"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"request-body-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/request-body"}},content:{$comment:`The \`content\` object is a property of: +`))}var Nr={SCHEMA:"SCHEMA",SCALAR:"SCALAR",OBJECT:"OBJECT",FIELD:"FIELD",ARGUMENT:"ARGUMENT",INTERFACE:"INTERFACE",UNION:"UNION",ENUM:"ENUM",ENUM_VALUE:"ENUM_VALUE",INPUT_OBJECT:"INPUT_OBJECT",INPUT_FIELD:"INPUT_FIELD",DIRECTIVE:"DIRECTIVE"};function J6(e,t){let n=t({getNamedType:l,setNamedType:c,getNamedTypes:u}),r=new Map;for(let N of e.types){let O=N.name,C=p(N);if(C)r.set(O,C)}let i=[];for(let N of e.directives){if(JN(N)){i.push(N);continue}let O=T(N.toConfig());if(O)i.push(new Pi(O))}let s={...e,query:e.query&&l(e.query.name),mutation:e.mutation&&l(e.mutation.name),subscription:e.subscription&&l(e.subscription.name),types:Array.from(r.values()),directives:i},o=n[Nr.SCHEMA];return o==null?s:o(s);function a(N){if(fn(N))return new Sr(a(N.ofType));if(Ft(N))return new dt(a(N.ofType));return l(N.name)}function l(N){let O=F0e.get(N)??r.get(N);if(O===void 0)cn(!1,`Unknown type: "${N}".`);return O}function c(N){r.set(N.name,N)}function u(){return Array.from(r.values())}function p(N){if(Rg(N)||KN(N))return N;if($o(N))return d(N);if(Dn(N))return f(N);if(dn(N))return h(N);if(Qr(N))return b(N);if(Mr(N))return g(N);if(en(N))return v(N);cn(!1,"Unexpected type: "+qe(N))}function d(N){let O=N.toConfig(),C=n[Nr.SCALAR];return O=C==null?O:C(O),new zs(O)}function f(N){let O=N.toConfig(),C={...O,interfaces:()=>O.interfaces.map((te)=>l(te.name)),fields:()=>m(O.fields,N.name)},X=n[Nr.OBJECT];return C=X==null?C:X(C),new Ds(C)}function m(N,O){let C=Object.create(null);for(let[X,te]of Object.entries(N)){let L={...te,type:a(te.type),args:y(te.args,X,O)},Y=n[Nr.FIELD];if(Y)L=Y(L,O);C[X]=L}return C}function y(N,O,C){let X=Object.create(null);for(let[te,L]of Object.entries(N)){let Y={...L,type:a(L.type)},me=n[Nr.ARGUMENT];if(me)Y=me(Y,O,C);X[te]=Y}return X}function h(N){let O=N.toConfig(),C={...O,interfaces:()=>O.interfaces.map((te)=>l(te.name)),fields:()=>m(O.fields,N.name)},X=n[Nr.INTERFACE];return C=X==null?C:X(C),new fd(C)}function b(N){let O=N.toConfig(),C={...O,types:()=>O.types.map((te)=>l(te.name))},X=n[Nr.UNION];return C=X==null?C:X(C),new md(C)}function g(N){let O=N.toConfig(),C={...O,values:()=>{let te=Object.create(null);for(let[L,Y]of Object.entries(O.values)){let me=x(Y,L,N.name);te[L]=me}return te}},X=n[Nr.ENUM];return C=X==null?C:X(C),new rl(C)}function x(N,O,C){let X={...N},te=n[Nr.ENUM_VALUE];return te==null?X:te(X,O,C)}function v(N){let O=N.toConfig(),C={...O,fields:()=>{let te=Object.create(null);for(let[L,Y]of Object.entries(O.fields)){let me=D(Y,L,N.name);te[L]=me}return te}},X=n[Nr.INPUT_OBJECT];return C=X==null?C:X(C),new yd(C)}function D(N,O,C){let X={...N,type:a(N.type)},te=n[Nr.INPUT_FIELD];return te==null?X:te(X,O,C)}function T(N){let O={...N,args:y(N.args,N.name,void 0)},C=n[Nr.DIRECTIVE];return C==null?O:C(O)}}var F0e=new Map([...Ou,...Pu].map((e)=>[e.name,e]));function G6(e,t,n){let r=[],i=new Wi,s=new Wi,o=new Wi,a=new Wi,l=new Wi,c=new Wi,u=new Wi,p=[],d,f=[],m=!1;for(let y of t.definitions){switch(y.kind){case id:d=y;break;case ud:f.push(y);break;case nl:p.push(y);break;case dm:u.add(y.name.value,y);break;case sd:case od:case ad:case ld:case cd:case vu:r.push(y);break;case _u:i.add(y.name.value,y);break;case xu:s.add(y.name.value,y);break;case wu:o.add(y.name.value,y);break;case Du:a.add(y.name.value,y);break;case Tu:l.add(y.name.value,y);break;case Yl:c.add(y.name.value,y);break;default:continue}m=!0}if(!m)return e;return J6(e,(y)=>{let{getNamedType:h,setNamedType:b,getNamedTypes:g}=y;return{[Nr.SCHEMA]:(I)=>{for(let pe of r){let de=C0e.get(pe.name.value)??me(pe);b(de)}let Z={query:I.query&&h(I.query.name),mutation:I.mutation&&h(I.mutation.name),subscription:I.subscription&&h(I.subscription.name),...d&&x([d]),...x(f)};return{description:d?.description?.value??I.description,...Z,types:g(),directives:[...I.directives.map(N),...p.map(T)],extensions:I.extensions,astNode:d??I.astNode,extensionASTNodes:I.extensionASTNodes.concat(f),assumeValid:n?.assumeValid??!1}},[Nr.INPUT_OBJECT]:(I)=>{let Z=c.get(I.name)??[];return{...I,fields:()=>({...I.fields(),...X(Z)}),extensionASTNodes:I.extensionASTNodes.concat(Z)}},[Nr.ENUM]:(I)=>{let Z=l.get(I.name)??[];return{...I,values:()=>({...I.values(),...te(Z)}),extensionASTNodes:I.extensionASTNodes.concat(Z)}},[Nr.SCALAR]:(I)=>{let Z=i.get(I.name)??[],pe=I.specifiedByURL;for(let de of Z)pe=wO(de)??pe;return{...I,specifiedByURL:pe,extensionASTNodes:I.extensionASTNodes.concat(Z)}},[Nr.OBJECT]:(I)=>{let Z=s.get(I.name)??[];return{...I,interfaces:()=>[...I.interfaces(),...L(Z)],fields:()=>({...I.fields(),...O(Z)}),extensionASTNodes:I.extensionASTNodes.concat(Z)}},[Nr.INTERFACE]:(I)=>{let Z=o.get(I.name)??[];return{...I,interfaces:()=>[...I.interfaces(),...L(Z)],fields:()=>({...I.fields(),...O(Z)}),extensionASTNodes:I.extensionASTNodes.concat(Z)}},[Nr.UNION]:(I)=>{let Z=a.get(I.name)??[];return{...I,types:()=>[...I.types(),...Y(Z)],extensionASTNodes:I.extensionASTNodes.concat(Z)}}};function x(I){let Z={};for(let pe of I){let de=pe.operationTypes??[];for(let je of de)Z[je.operation]=v(je.type)}return Z}function v(I){let Z=I.name.value,pe=h(Z);if(pe===void 0)cn(!1,`Unknown type: "${Z}".`);return pe}function D(I){if(I.kind===S0)return new Sr(D(I.type));if(I.kind===vg)return new dt(D(I.type));return v(I)}function T(I){let Z=u.get(I.name.value)??[],pe=Ed(I)??Z.map((de)=>Ed(de)).find((de)=>de!=null);return new Pi({name:I.name.value,description:I.description?.value,locations:I.locations.map(({value:de})=>de),isRepeatable:I.repeatable,args:C(I.arguments),deprecationReason:pe,astNode:I,extensionASTNodes:Z})}function N(I){let Z=u.get(I.name)??[];if(Z.length===0)return I;let pe=I.deprecationReason??Z.map((de)=>Ed(de)).find((de)=>de!=null);return new Pi({...I.toConfig(),deprecationReason:pe,extensionASTNodes:I.extensionASTNodes.concat(Z)})}function O(I){let Z=Object.create(null);for(let pe of I){let de=pe.fields??[];for(let je of de)Z[je.name.value]={type:D(je.type),description:je.description?.value,args:C(je.arguments),deprecationReason:Ed(je),astNode:je}}return Z}function C(I){let Z=I??[],pe=Object.create(null);for(let de of Z){let je=D(de.type);pe[de.name.value]={type:je,description:de.description?.value,default:de.defaultValue&&{literal:de.defaultValue},deprecationReason:Ed(de),astNode:de}}return pe}function X(I){let Z=Object.create(null);for(let pe of I){let de=pe.fields??[];for(let je of de){let be=D(je.type);Z[je.name.value]={type:be,description:je.description?.value,default:je.defaultValue&&{literal:je.defaultValue},deprecationReason:Ed(je),astNode:je}}}return Z}function te(I){let Z=Object.create(null);for(let pe of I){let de=pe.values??[];for(let je of de)Z[je.name.value]={description:je.description?.value,deprecationReason:Ed(je),astNode:je}}return Z}function L(I){return I.flatMap((Z)=>Z.interfaces?.map(v)??[])}function Y(I){return I.flatMap((Z)=>Z.types?.map(v)??[])}function me(I){let Z=I.name.value;switch(I.kind){case od:{let pe=s.get(Z)??[],de=[I,...pe];return new Ds({name:Z,description:I.description?.value,interfaces:()=>L(de),fields:()=>O(de),astNode:I,extensionASTNodes:pe})}case ad:{let pe=o.get(Z)??[],de=[I,...pe];return new fd({name:Z,description:I.description?.value,interfaces:()=>L(de),fields:()=>O(de),astNode:I,extensionASTNodes:pe})}case cd:{let pe=l.get(Z)??[],de=[I,...pe];return new rl({name:Z,description:I.description?.value,values:()=>te(de),astNode:I,extensionASTNodes:pe})}case ld:{let pe=a.get(Z)??[],de=[I,...pe];return new md({name:Z,description:I.description?.value,types:()=>Y(de),astNode:I,extensionASTNodes:pe})}case sd:{let pe=i.get(Z)??[],de=wO(I);for(let je of pe)de=wO(je)??de;return new zs({name:Z,description:I.description?.value,specifiedByURL:de,astNode:I,extensionASTNodes:pe})}case vu:{let pe=c.get(Z)??[],de=[I,...pe];return new yd({name:Z,description:I.description?.value,fields:()=>X(de),astNode:I,extensionASTNodes:pe,isOneOf:M0e(I)})}}}})}var C0e=new Map([...Ou,...Pu].map((e)=>[e.name,e]));function Ed(e){return xm(vm,e)?.reason}function wO(e){return xm(C0,e)?.url}function M0e(e){return Boolean(xm(M0,e))}function nw(e,t){if(t?.assumeValid!==!0&&t?.assumeValidSDL!==!0)K6(e);let n={description:void 0,types:[],directives:[],extensions:Object.create(null),extensionASTNodes:[],assumeValid:!1},r=G6(n,e,t);if(r.astNode==null)for(let s of r.types)switch(s.name){case"Query":r.query=s;break;case"Mutation":r.mutation=s;break;case"Subscription":r.subscription=s;break}let i=[...r.directives,...Ts.filter((s)=>r.directives.every((o)=>o.name!==s.name))];return new jg({...r,directives:i})}$8();var rw={id:"umf.graphql",version:"0.1.0",coreVersion:"0.1.0",description:"GraphQL SDL native AST and source preservation",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:graphql:0.1.0",type:"object",required:["profile","ast","originalSource"],properties:{profile:{const:"graphql-js-17.0.2-sdl"},mode:{enum:["schema","fragment"]},ast:{$ref:"#/$defs/DocumentNode"},originalSource:{type:"string"}},$defs:{DocumentNode:{type:"object",required:["kind","definitions"],properties:{kind:{const:"Document"},definitions:{type:"array",minItems:1,items:{anyOf:[{$ref:"#/$defs/TypeSystemDefinitionNode"},{$ref:"#/$defs/TypeSystemExtensionNode"}]}}}},TypeSystemDefinitionNode:{anyOf:[{$ref:"#/$defs/SchemaDefinitionNode"},{$ref:"#/$defs/ScalarTypeDefinitionNode"},{$ref:"#/$defs/ObjectTypeDefinitionNode"},{$ref:"#/$defs/InterfaceTypeDefinitionNode"},{$ref:"#/$defs/UnionTypeDefinitionNode"},{$ref:"#/$defs/EnumTypeDefinitionNode"},{$ref:"#/$defs/InputObjectTypeDefinitionNode"},{$ref:"#/$defs/DirectiveDefinitionNode"}]},SchemaDefinitionNode:{type:"object",required:["kind","operationTypes"],properties:{kind:{const:"SchemaDefinition"},description:{$ref:"#/$defs/StringValueNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},operationTypes:{type:"array",items:{$ref:"#/$defs/OperationTypeDefinitionNode"}}}},StringValueNode:{type:"object",required:["kind","value"],properties:{kind:{const:"StringValue"},value:{type:"string"},block:{type:"boolean"}}},ConstDirectiveNode:{type:"object",required:["kind","name"],properties:{kind:{const:"Directive"},name:{$ref:"#/$defs/NameNode"},arguments:{type:"array",items:{$ref:"#/$defs/ConstArgumentNode"}}}},NameNode:{type:"object",required:["kind","value"],properties:{kind:{const:"Name"},value:{type:"string"}}},ConstArgumentNode:{type:"object",required:["kind","name","value"],properties:{kind:{const:"Argument"},name:{$ref:"#/$defs/NameNode"},value:{anyOf:[{$ref:"#/$defs/StringValueNode"},{$ref:"#/$defs/IntValueNode"},{$ref:"#/$defs/FloatValueNode"},{$ref:"#/$defs/BooleanValueNode"},{$ref:"#/$defs/NullValueNode"},{$ref:"#/$defs/EnumValueNode"},{$ref:"#/$defs/ConstListValueNode"},{$ref:"#/$defs/ConstObjectValueNode"}]}}},IntValueNode:{type:"object",required:["kind","value"],properties:{kind:{const:"IntValue"},value:{type:"string"}}},FloatValueNode:{type:"object",required:["kind","value"],properties:{kind:{const:"FloatValue"},value:{type:"string"}}},BooleanValueNode:{type:"object",required:["kind","value"],properties:{kind:{const:"BooleanValue"},value:{type:"boolean"}}},NullValueNode:{type:"object",required:["kind"],properties:{kind:{const:"NullValue"}}},EnumValueNode:{type:"object",required:["kind","value"],properties:{kind:{const:"EnumValue"},value:{type:"string"}}},ConstListValueNode:{type:"object",required:["kind","values"],properties:{kind:{const:"ListValue"},values:{type:"array",items:{anyOf:[{$ref:"#/$defs/StringValueNode"},{$ref:"#/$defs/IntValueNode"},{$ref:"#/$defs/FloatValueNode"},{$ref:"#/$defs/BooleanValueNode"},{$ref:"#/$defs/NullValueNode"},{$ref:"#/$defs/EnumValueNode"},{$ref:"#/$defs/ConstListValueNode"},{$ref:"#/$defs/ConstObjectValueNode"}]}}}},ConstObjectValueNode:{type:"object",required:["kind","fields"],properties:{kind:{const:"ObjectValue"},fields:{type:"array",items:{$ref:"#/$defs/ConstObjectFieldNode"}}}},ConstObjectFieldNode:{type:"object",required:["kind","name","value"],properties:{kind:{const:"ObjectField"},name:{$ref:"#/$defs/NameNode"},value:{anyOf:[{$ref:"#/$defs/StringValueNode"},{$ref:"#/$defs/IntValueNode"},{$ref:"#/$defs/FloatValueNode"},{$ref:"#/$defs/BooleanValueNode"},{$ref:"#/$defs/NullValueNode"},{$ref:"#/$defs/EnumValueNode"},{$ref:"#/$defs/ConstListValueNode"},{$ref:"#/$defs/ConstObjectValueNode"}]}}},OperationTypeDefinitionNode:{type:"object",required:["kind","operation","type"],properties:{kind:{const:"OperationTypeDefinition"},operation:{anyOf:[{const:"query"},{const:"mutation"},{const:"subscription"}]},type:{$ref:"#/$defs/NamedTypeNode"}}},NamedTypeNode:{type:"object",required:["kind","name"],properties:{kind:{const:"NamedType"},name:{$ref:"#/$defs/NameNode"}}},ScalarTypeDefinitionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"ScalarTypeDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}}}},ObjectTypeDefinitionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"ObjectTypeDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},interfaces:{type:"array",items:{$ref:"#/$defs/NamedTypeNode"}},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},fields:{type:"array",items:{$ref:"#/$defs/FieldDefinitionNode"}}}},FieldDefinitionNode:{type:"object",required:["kind","name","type"],properties:{kind:{const:"FieldDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},arguments:{type:"array",items:{$ref:"#/$defs/InputValueDefinitionNode"}},type:{anyOf:[{$ref:"#/$defs/NamedTypeNode"},{$ref:"#/$defs/ListTypeNode"},{$ref:"#/$defs/NonNullTypeNode"}]},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}}}},InputValueDefinitionNode:{type:"object",required:["kind","name","type"],properties:{kind:{const:"InputValueDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},type:{anyOf:[{$ref:"#/$defs/NamedTypeNode"},{$ref:"#/$defs/ListTypeNode"},{$ref:"#/$defs/NonNullTypeNode"}]},defaultValue:{anyOf:[{$ref:"#/$defs/StringValueNode"},{$ref:"#/$defs/IntValueNode"},{$ref:"#/$defs/FloatValueNode"},{$ref:"#/$defs/BooleanValueNode"},{$ref:"#/$defs/NullValueNode"},{$ref:"#/$defs/EnumValueNode"},{$ref:"#/$defs/ConstListValueNode"},{$ref:"#/$defs/ConstObjectValueNode"}]},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}}}},ListTypeNode:{type:"object",required:["kind","type"],properties:{kind:{const:"ListType"},type:{anyOf:[{$ref:"#/$defs/NamedTypeNode"},{$ref:"#/$defs/ListTypeNode"},{$ref:"#/$defs/NonNullTypeNode"}]}}},NonNullTypeNode:{type:"object",required:["kind","type"],properties:{kind:{const:"NonNullType"},type:{anyOf:[{$ref:"#/$defs/NamedTypeNode"},{$ref:"#/$defs/ListTypeNode"}]}}},InterfaceTypeDefinitionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"InterfaceTypeDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},interfaces:{type:"array",items:{$ref:"#/$defs/NamedTypeNode"}},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},fields:{type:"array",items:{$ref:"#/$defs/FieldDefinitionNode"}}}},UnionTypeDefinitionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"UnionTypeDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},types:{type:"array",items:{$ref:"#/$defs/NamedTypeNode"}}}},EnumTypeDefinitionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"EnumTypeDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},values:{type:"array",items:{$ref:"#/$defs/EnumValueDefinitionNode"}}}},EnumValueDefinitionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"EnumValueDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}}}},InputObjectTypeDefinitionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"InputObjectTypeDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},fields:{type:"array",items:{$ref:"#/$defs/InputValueDefinitionNode"}}}},DirectiveDefinitionNode:{type:"object",required:["kind","name","repeatable","locations"],properties:{kind:{const:"DirectiveDefinition"},description:{$ref:"#/$defs/StringValueNode"},name:{$ref:"#/$defs/NameNode"},arguments:{type:"array",items:{$ref:"#/$defs/InputValueDefinitionNode"}},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},repeatable:{type:"boolean"},locations:{type:"array",items:{$ref:"#/$defs/NameNode"}}}},TypeSystemExtensionNode:{anyOf:[{$ref:"#/$defs/SchemaExtensionNode"},{$ref:"#/$defs/ScalarTypeExtensionNode"},{$ref:"#/$defs/ObjectTypeExtensionNode"},{$ref:"#/$defs/InterfaceTypeExtensionNode"},{$ref:"#/$defs/UnionTypeExtensionNode"},{$ref:"#/$defs/EnumTypeExtensionNode"},{$ref:"#/$defs/InputObjectTypeExtensionNode"},{$ref:"#/$defs/DirectiveExtensionNode"}]},SchemaExtensionNode:{type:"object",required:["kind"],properties:{kind:{const:"SchemaExtension"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},operationTypes:{type:"array",items:{$ref:"#/$defs/OperationTypeDefinitionNode"}}}},ScalarTypeExtensionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"ScalarTypeExtension"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}}}},ObjectTypeExtensionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"ObjectTypeExtension"},name:{$ref:"#/$defs/NameNode"},interfaces:{type:"array",items:{$ref:"#/$defs/NamedTypeNode"}},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},fields:{type:"array",items:{$ref:"#/$defs/FieldDefinitionNode"}}}},InterfaceTypeExtensionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"InterfaceTypeExtension"},name:{$ref:"#/$defs/NameNode"},interfaces:{type:"array",items:{$ref:"#/$defs/NamedTypeNode"}},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},fields:{type:"array",items:{$ref:"#/$defs/FieldDefinitionNode"}}}},UnionTypeExtensionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"UnionTypeExtension"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},types:{type:"array",items:{$ref:"#/$defs/NamedTypeNode"}}}},EnumTypeExtensionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"EnumTypeExtension"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},values:{type:"array",items:{$ref:"#/$defs/EnumValueDefinitionNode"}}}},InputObjectTypeExtensionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"InputObjectTypeExtension"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}},fields:{type:"array",items:{$ref:"#/$defs/InputValueDefinitionNode"}}}},DirectiveExtensionNode:{type:"object",required:["kind","name"],properties:{kind:{const:"DirectiveExtension"},name:{$ref:"#/$defs/NameNode"},directives:{type:"array",items:{$ref:"#/$defs/ConstDirectiveNode"}}}}}},semantics:"CONTRACT-009. SDL AST preserves native type/directive/default declarations; original source retains comments. Runtime scalar/directive behavior remains external.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"GraphQL SDL",version:"GraphQL.js 17.0.2; September 2025 specification plus explicitly reported runtime grammar additions",subset:"Schema definitions/extensions and constant values; executable operations are outside this schema adapter"},evidence:["tests/graphql/native.test.ts","tests/graphql/corpus.test.ts","fixtures/graphql/corpus-oracle-results.json"]}};var H6="umf.graphql",U0e=rw,B0e=mt().compile(rw.schema),z6=new Map;for(let e of Object.values(rw.schema.$defs))if(e.properties?.kind?.const)z6.set(e.properties.kind.const,Object.keys(e.properties));function iw(e){if(typeof e!=="string"||e.length>Zt.maxTextLength)throw new U("GRAPHQL_LIMIT","Source exceeds text limit");let t=z0(e,{noLocation:!0,maxTokens:Zt.maxValues});return Ae(JSON.parse(JSON.stringify(t,(n,r)=>n==="tokenCount"?void 0:r)))}function V0e(e){let t=e,n=[],r=(s,o,a)=>n.push({code:s,path:o,message:a,severity:"warning"});for(let s of Object.keys(t))if(!["profile","mode","ast","originalSource"].includes(s))r("GRAPHQL_REPRESENTATION","/"+$e(s),"Unknown payload field has no SDL destination");function i(s,o){if(!s||typeof s!=="object")return;if(Array.isArray(s)){s.forEach((l,c)=>i(l,o+"/"+c));return}let a=z6.get(s.kind);for(let l of Object.keys(s))if(!a?.includes(l))r("GRAPHQL_REPRESENTATION",o+"/"+$e(l),"Unknown AST field has no SDL destination");if(s.kind==="ScalarTypeDefinition")r("GRAPHQL_SCALAR",o,"Custom scalar coercion/serialization is external to SDL");if(s.kind==="Directive"&&!["deprecated","specifiedBy","oneOf"].includes(s.name?.value))r("GRAPHQL_DIRECTIVE",o,"Custom directive behavior is retained but not implemented by this adapter");if(s.kind==="DirectiveExtension"||s.kind==="DirectiveDefinition"&&s.directives?.length)r("GRAPHQL_PROFILE_EXTENSION",o,"GraphQL.js grammar addition beyond the September 2025 SDL profile");for(let[l,c]of Object.entries(s))if(l!=="kind")i(c,o+"/"+$e(l))}i(t.ast,"/ast");try{let s=hn(t.ast),o=iw(s);if(JSON.stringify(o)!==JSON.stringify(t.ast)){if(Ru(o)!==Ru(t.ast))r("GRAPHQL_PRINT_CHANGE","/ast","Printing changes AST content; conservative export is blocked")}if(t.mode==="fragment")r("GRAPHQL_FRAGMENT","/ast","Syntax-only SDL fragment: references, roots and composed-schema semantics require an explicit schema context");let a=t.mode==="fragment"?[]:B0(nw(t.ast));for(let l of a)n.push({code:"GRAPHQL_SCHEMA",path:"/ast",severity:"error",message:l.message})}catch(s){n.push({code:"GRAPHQL_SCHEMA",path:"/ast",severity:"error",message:String(s)})}try{iw(t.originalSource)}catch(s){n.push({code:"GRAPHQL_SOURCE_ARCHIVE",path:"/originalSource",severity:"error",message:String(s)})}return n}function Ru(e){return JSON.stringify(e&&typeof e==="object"?Array.isArray(e)?e.map((t)=>JSON.parse(Ru(t))):Object.fromEntries(Object.keys(e).sort().map((t)=>[t,JSON.parse(Ru(e[t]))])):e)}function K0e(){return new nt().register(U0e,V0e)}function DO(e){return We(e,K0e())}function W6(e){let t=DO(e);if(!t.valid)throw new U("GRAPHQL_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[H6];if(e.vocabularies[H6]?.version!=="0.1.0"||!B0e(n))throw new U("GRAPHQL_PAYLOAD","Missing or invalid GraphQL payload");return Ae(n)}function TO(e){let t=W6(e);if(DO(e).diagnostics.some((n)=>["GRAPHQL_REPRESENTATION","GRAPHQL_PRINT_CHANGE"].includes(n.code)))throw new U("GRAPHQL_REPRESENTATION","Native export would discard AST content");return Ru(iw(t.originalSource))===Ru(t.ast)?t.originalSource:hn(t.ast)+` +`}function Q6(e){let t=W6(e),n=Ru(iw(t.originalSource))!==Ru(t.ast);return{schema:TO(e),source:Ae(e),diagnostics:[...DO(e).diagnostics,...n?[{code:"GRAPHQL_SOURCE_LAYOUT",path:"",severity:"warning",message:"Edited SDL is printed; comments and original formatting remain only in retained originalSource"}]:[],{code:"SOURCE_ARTIFACT_REQUIRED",path:"",severity:"warning",message:"Native SDL cannot preserve unrelated UMF metadata; retain source bundle"}]}}function Bg(e){if(Array.isArray(e))return e.map(Bg);if(e&&typeof e==="object")return Object.fromEntries(Object.entries(e).map(([t,n])=>t==="$dynamicRef"&&n==="#meta"?["$ref","#/$defs/schema"]:[t,Bg(n)]));return e}var Y6={$id:"https://spec.openapis.org/oas/3.1/meta/2024-11-10",$schema:"https://json-schema.org/draft/2020-12/schema",title:"OAS Base Vocabulary",description:"A JSON Schema Vocabulary used in the OpenAPI Schema Dialect",$dynamicAnchor:"meta",$vocabulary:{"https://spec.openapis.org/oas/3.1/vocab/base":!0},type:["object","boolean"],properties:{discriminator:{$ref:"#/$defs/discriminator"},example:!0,externalDocs:{$ref:"#/$defs/external-docs"},xml:{$ref:"#/$defs/xml"}},$defs:{discriminator:{$ref:"#/$defs/extensible",properties:{mapping:{additionalProperties:{type:"string"},type:"object"},propertyName:{type:"string"}},required:["propertyName"],type:"object",unevaluatedProperties:!1},extensible:{patternProperties:{"^x-":!0}},"external-docs":{$ref:"#/$defs/extensible",properties:{description:{type:"string"},url:{format:"uri-reference",type:"string"}},required:["url"],type:"object",unevaluatedProperties:!1},xml:{$ref:"#/$defs/extensible",properties:{attribute:{type:"boolean"},name:{type:"string"},namespace:{format:"uri",type:"string"},prefix:{type:"string"},wrapped:{type:"boolean"}},type:"object",unevaluatedProperties:!1}}};var X6={$id:"https://spec.openapis.org/oas/3.2/meta/2026-02-26",$schema:"https://json-schema.org/draft/2020-12/schema",title:"OAS Base Vocabulary",description:"A JSON Schema Vocabulary used in the OpenAPI JSON Schema Dialect",$dynamicAnchor:"meta",$vocabulary:{"https://spec.openapis.org/oas/3.2/vocab/base":!0},type:["object","boolean"],properties:{discriminator:{$ref:"#/$defs/discriminator"},example:{deprecated:!0},externalDocs:{$ref:"#/$defs/external-docs"},xml:{$ref:"#/$defs/xml"}},$defs:{discriminator:{$ref:"#/$defs/extensible",properties:{mapping:{additionalProperties:{type:"string"},type:"object"},defaultMapping:{type:"string"},propertyName:{type:"string"}},required:["propertyName"],type:"object",unevaluatedProperties:!1},extensible:{patternProperties:{"^x-":!0}},"external-docs":{$ref:"#/$defs/extensible",properties:{description:{type:"string"},url:{format:"uri-reference",type:"string"}},required:["url"],type:"object",unevaluatedProperties:!1},xml:{$ref:"#/$defs/extensible",properties:{nodeType:{type:"string",enum:["element","attribute","text","cdata","none"]},name:{type:"string"},namespace:{format:"iri",type:"string"},prefix:{type:"string"},attribute:{type:"boolean",deprecated:!0},wrapped:{type:"boolean",deprecated:!0}},type:"object",dependentSchemas:{nodeType:{properties:{attribute:!1,wrapped:!1}}},unevaluatedProperties:!1}}};var e4="https://json-schema.org/draft/2020-12/schema",H0e=mt(!1),z0e=H0e.getSchema(e4),W0e={"3.1":mt(!1).compile(Y6),"3.2":mt(!1).compile(X6)},Z6={[e4]:"standard","https://spec.openapis.org/oas/3.1/dialect/base":"3.1","https://spec.openapis.org/oas/3.1/dialect/2024-11-10":"3.1","https://spec.openapis.org/oas/3.2/dialect/2026-02-26":"3.2"},Q0e=["not","if","then","else","items","contains","additionalProperties","unevaluatedProperties","unevaluatedItems","propertyNames","contentSchema"],Y0e=["allOf","anyOf","oneOf","prefixItems"],X0e=["$defs","definitions","properties","patternProperties","dependentSchemas"],Xi=(e)=>e!==null&&typeof e==="object"&&!Array.isArray(e);function Z0e(e){let t=[];function n(y,h,b){if(Xi(y))for(let[g,x]of Object.entries(y))b(x,h+"/"+$e(g))}function r(y,h,b){if(Array.isArray(y))y.forEach((g,x)=>b(g,h+"/"+x))}function i(y,h){if(y!==void 0)t.push({pointer:h,schema:y})}function s(y,h){if(!Xi(y))return;if(n(y.headers,h+"/headers",l),n(y.encoding,h+"/encoding",s),r(y.prefixEncoding,h+"/prefixEncoding",s),y.itemEncoding)s(y.itemEncoding,h+"/itemEncoding")}function o(y,h){if(!Xi(y))return;i(y.schema,h+"/schema"),i(y.itemSchema,h+"/itemSchema"),s(y,h)}function a(y,h){if(Xi(y))n(y.content,h+"/content",o)}function l(y,h){if(!Xi(y))return;i(y.schema,h+"/schema"),a(y,h)}function c(y,h){if(!Xi(y))return;a(y,h),n(y.headers,h+"/headers",l)}function u(y,h){n(y,h,(b,g)=>{if(!g.split("/").at(-1).startsWith("x-")&&Xi(b))d(b,g)})}function p(y,h){if(!Xi(y))return;r(y.parameters,h+"/parameters",l),a(y.requestBody,h+"/requestBody"),n(y.responses,h+"/responses",(b,g)=>{let x=g.split("/").at(-1);if(x==="default"||/^[1-5][0-9Xx]{2}$/.test(x))c(b,g)}),n(y.callbacks,h+"/callbacks",u)}function d(y,h){if(!Xi(y))return;r(y.parameters,h+"/parameters",l);for(let b of["get","put","post","delete","options","head","patch","trace","query"])p(y[b],h+"/"+b);n(y.additionalOperations,h+"/additionalOperations",p)}let f=e;n(f.paths,"/paths",(y,h)=>{if(h.startsWith("/paths/~1"))d(y,h)}),n(f.webhooks,"/webhooks",d);let m=f.components;if(Xi(m)){n(m.schemas,"/components/schemas",i);for(let y of["parameters","headers"])n(m[y],"/components/"+y,l);n(m.responses,"/components/responses",c),n(m.requestBodies,"/components/requestBodies",a),n(m.callbacks,"/components/callbacks",u),n(m.pathItems,"/components/pathItems",d),n(m.mediaTypes,"/components/mediaTypes",o)}return t}function t4(e){let t=e,n=String(t.openapi??"").slice(0,3);if(!["3.1","3.2"].includes(n))return[];let r=[],i=t.jsonSchemaDialect??(n==="3.1"?"https://spec.openapis.org/oas/3.1/dialect/2024-11-10":"https://spec.openapis.org/oas/3.2/dialect/2026-02-26");function s(o,a,l){if(typeof o!=="boolean"&&!Xi(o)){r.push({code:"OPENAPI_SCHEMA_META",path:a,severity:"error",message:"Schema must be an object or boolean"});return}let c=typeof o==="boolean"?l:o.$schema??l,u=typeof c==="string"&&Object.hasOwn(Z6,c)?Z6[c]:void 0;if(typeof c!=="string"){r.push({code:"OPENAPI_SCHEMA_META",path:a+"/$schema",severity:"error",message:"Schema dialect must be a string"});return}if(!u){r.push({code:"OPENAPI_SCHEMA_DIALECT",path:a,severity:"warning",message:"Unknown dialect retained without applying another dialect: "+c});return}if(typeof o==="boolean")return;let p={...o},d=[],f=(m,y)=>(d.push({value:m,path:y}),Xi(m)||typeof m==="boolean"?!0:m);for(let m of Q0e)if(Object.hasOwn(o,m))p[m]=f(o[m],a+"/"+m);for(let m of Y0e)if(Array.isArray(o[m]))p[m]=o[m].map((y,h)=>f(y,a+"/"+m+"/"+h));for(let m of X0e)if(Xi(o[m]))p[m]=Object.fromEntries(Object.entries(o[m]).map(([y,h])=>[y,f(h,a+"/"+$e(m)+"/"+$e(y))]));if(Xi(o.dependencies))p.dependencies=Object.fromEntries(Object.entries(o.dependencies).map(([m,y])=>[m,Xi(y)||typeof y==="boolean"?f(y,a+"/dependencies/"+$e(m)):y]));for(let m of[z0e,...u==="standard"?[]:[W0e[u]]])if(!m(p))for(let y of m.errors??[])r.push({code:"OPENAPI_SCHEMA_META",path:a+y.instancePath,severity:"error",message:y.message??"Invalid schema keyword"});if(o.$vocabulary)r.push({code:"OPENAPI_SCHEMA_VOCABULARY",path:a+"/$vocabulary",severity:"warning",message:"Custom vocabulary interpretation is not established by this meta-schema check"});for(let m of d)s(m.value,m.path,c)}for(let o of Z0e(e))s(o.schema,o.pointer,i);return r}var T4=Rr(h4(),1);var g4={id:"https://spec.openapis.org/oas/3.0/schema/2024-10-18",$schema:"http://json-schema.org/draft-04/schema#",description:"The description of OpenAPI v3.0.x Documents",type:"object",required:["openapi","info","paths"],properties:{openapi:{type:"string",pattern:"^3\\.0\\.\\d(-.+)?$"},info:{$ref:"#/definitions/Info"},externalDocs:{$ref:"#/definitions/ExternalDocumentation"},servers:{type:"array",items:{$ref:"#/definitions/Server"}},security:{type:"array",items:{$ref:"#/definitions/SecurityRequirement"}},tags:{type:"array",items:{$ref:"#/definitions/Tag"},uniqueItems:!0},paths:{$ref:"#/definitions/Paths"},components:{$ref:"#/definitions/Components"}},patternProperties:{"^x-":{}},additionalProperties:!1,definitions:{Reference:{type:"object",required:["$ref"],patternProperties:{"^\\$ref$":{type:"string",format:"uri-reference"}}},Info:{type:"object",required:["title","version"],properties:{title:{type:"string"},description:{type:"string"},termsOfService:{type:"string",format:"uri-reference"},contact:{$ref:"#/definitions/Contact"},license:{$ref:"#/definitions/License"},version:{type:"string"}},patternProperties:{"^x-":{}},additionalProperties:!1},Contact:{type:"object",properties:{name:{type:"string"},url:{type:"string",format:"uri-reference"},email:{type:"string",format:"email"}},patternProperties:{"^x-":{}},additionalProperties:!1},License:{type:"object",required:["name"],properties:{name:{type:"string"},url:{type:"string",format:"uri-reference"}},patternProperties:{"^x-":{}},additionalProperties:!1},Server:{type:"object",required:["url"],properties:{url:{type:"string"},description:{type:"string"},variables:{type:"object",additionalProperties:{$ref:"#/definitions/ServerVariable"}}},patternProperties:{"^x-":{}},additionalProperties:!1},ServerVariable:{type:"object",required:["default"],properties:{enum:{type:"array",items:{type:"string"}},default:{type:"string"},description:{type:"string"}},patternProperties:{"^x-":{}},additionalProperties:!1},Components:{type:"object",properties:{schemas:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]}}},responses:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/Response"}]}}},parameters:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/Parameter"}]}}},examples:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/Example"}]}}},requestBodies:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/RequestBody"}]}}},headers:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/Header"}]}}},securitySchemes:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/SecurityScheme"}]}}},links:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/Link"}]}}},callbacks:{type:"object",patternProperties:{"^[a-zA-Z0-9\\.\\-_]+$":{oneOf:[{$ref:"#/definitions/Reference"},{$ref:"#/definitions/Callback"}]}}}},patternProperties:{"^x-":{}},additionalProperties:!1},Schema:{type:"object",properties:{title:{type:"string"},multipleOf:{type:"number",minimum:0,exclusiveMinimum:!0},maximum:{type:"number"},exclusiveMaximum:{type:"boolean",default:!1},minimum:{type:"number"},exclusiveMinimum:{type:"boolean",default:!1},maxLength:{type:"integer",minimum:0},minLength:{type:"integer",minimum:0,default:0},pattern:{type:"string",format:"regex"},maxItems:{type:"integer",minimum:0},minItems:{type:"integer",minimum:0,default:0},uniqueItems:{type:"boolean",default:!1},maxProperties:{type:"integer",minimum:0},minProperties:{type:"integer",minimum:0,default:0},required:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0},enum:{type:"array",items:{},minItems:1,uniqueItems:!1},type:{type:"string",enum:["array","boolean","integer","number","object","string"]},not:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]},allOf:{type:"array",items:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]}},oneOf:{type:"array",items:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]}},anyOf:{type:"array",items:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]}},items:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]},properties:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]}},additionalProperties:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"},{type:"boolean"}],default:!0},description:{type:"string"},format:{type:"string"},default:{},nullable:{type:"boolean",default:!1},discriminator:{$ref:"#/definitions/Discriminator"},readOnly:{type:"boolean",default:!1},writeOnly:{type:"boolean",default:!1},example:{},externalDocs:{$ref:"#/definitions/ExternalDocumentation"},deprecated:{type:"boolean",default:!1},xml:{$ref:"#/definitions/XML"}},patternProperties:{"^x-":{}},additionalProperties:!1},Discriminator:{type:"object",required:["propertyName"],properties:{propertyName:{type:"string"},mapping:{type:"object",additionalProperties:{type:"string"}}}},XML:{type:"object",properties:{name:{type:"string"},namespace:{type:"string",format:"uri"},prefix:{type:"string"},attribute:{type:"boolean",default:!1},wrapped:{type:"boolean",default:!1}},patternProperties:{"^x-":{}},additionalProperties:!1},Response:{type:"object",required:["description"],properties:{description:{type:"string"},headers:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Header"},{$ref:"#/definitions/Reference"}]}},content:{type:"object",additionalProperties:{$ref:"#/definitions/MediaType"}},links:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Link"},{$ref:"#/definitions/Reference"}]}}},patternProperties:{"^x-":{}},additionalProperties:!1},MediaType:{type:"object",properties:{schema:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]},example:{},examples:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Example"},{$ref:"#/definitions/Reference"}]}},encoding:{type:"object",additionalProperties:{$ref:"#/definitions/Encoding"}}},patternProperties:{"^x-":{}},additionalProperties:!1,allOf:[{$ref:"#/definitions/ExampleXORExamples"}]},Example:{type:"object",properties:{summary:{type:"string"},description:{type:"string"},value:{},externalValue:{type:"string",format:"uri-reference"}},patternProperties:{"^x-":{}},additionalProperties:!1},Header:{type:"object",properties:{description:{type:"string"},required:{type:"boolean",default:!1},deprecated:{type:"boolean",default:!1},allowEmptyValue:{type:"boolean",default:!1},style:{type:"string",enum:["simple"],default:"simple"},explode:{type:"boolean"},allowReserved:{type:"boolean",default:!1},schema:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]},content:{type:"object",additionalProperties:{$ref:"#/definitions/MediaType"},minProperties:1,maxProperties:1},example:{},examples:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Example"},{$ref:"#/definitions/Reference"}]}}},patternProperties:{"^x-":{}},additionalProperties:!1,allOf:[{$ref:"#/definitions/ExampleXORExamples"},{$ref:"#/definitions/SchemaXORContent"}]},Paths:{type:"object",patternProperties:{"^\\/":{$ref:"#/definitions/PathItem"},"^x-":{}},additionalProperties:!1},PathItem:{type:"object",properties:{$ref:{type:"string"},summary:{type:"string"},description:{type:"string"},get:{$ref:"#/definitions/Operation"},put:{$ref:"#/definitions/Operation"},post:{$ref:"#/definitions/Operation"},delete:{$ref:"#/definitions/Operation"},options:{$ref:"#/definitions/Operation"},head:{$ref:"#/definitions/Operation"},patch:{$ref:"#/definitions/Operation"},trace:{$ref:"#/definitions/Operation"},servers:{type:"array",items:{$ref:"#/definitions/Server"}},parameters:{type:"array",items:{oneOf:[{$ref:"#/definitions/Parameter"},{$ref:"#/definitions/Reference"}]},uniqueItems:!0}},patternProperties:{"^x-":{}},additionalProperties:!1},Operation:{type:"object",required:["responses"],properties:{tags:{type:"array",items:{type:"string"}},summary:{type:"string"},description:{type:"string"},externalDocs:{$ref:"#/definitions/ExternalDocumentation"},operationId:{type:"string"},parameters:{type:"array",items:{oneOf:[{$ref:"#/definitions/Parameter"},{$ref:"#/definitions/Reference"}]},uniqueItems:!0},requestBody:{oneOf:[{$ref:"#/definitions/RequestBody"},{$ref:"#/definitions/Reference"}]},responses:{$ref:"#/definitions/Responses"},callbacks:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Callback"},{$ref:"#/definitions/Reference"}]}},deprecated:{type:"boolean",default:!1},security:{type:"array",items:{$ref:"#/definitions/SecurityRequirement"}},servers:{type:"array",items:{$ref:"#/definitions/Server"}}},patternProperties:{"^x-":{}},additionalProperties:!1},Responses:{type:"object",properties:{default:{oneOf:[{$ref:"#/definitions/Response"},{$ref:"#/definitions/Reference"}]}},patternProperties:{"^[1-5](?:\\d{2}|XX)$":{oneOf:[{$ref:"#/definitions/Response"},{$ref:"#/definitions/Reference"}]},"^x-":{}},minProperties:1,additionalProperties:!1},SecurityRequirement:{type:"object",additionalProperties:{type:"array",items:{type:"string"}}},Tag:{type:"object",required:["name"],properties:{name:{type:"string"},description:{type:"string"},externalDocs:{$ref:"#/definitions/ExternalDocumentation"}},patternProperties:{"^x-":{}},additionalProperties:!1},ExternalDocumentation:{type:"object",required:["url"],properties:{description:{type:"string"},url:{type:"string",format:"uri-reference"}},patternProperties:{"^x-":{}},additionalProperties:!1},ExampleXORExamples:{description:"Example and examples are mutually exclusive",not:{required:["example","examples"]}},SchemaXORContent:{description:"Schema and content are mutually exclusive, at least one is required",not:{required:["schema","content"]},oneOf:[{required:["schema"]},{required:["content"],description:"Some properties are not allowed if content is present",allOf:[{not:{required:["style"]}},{not:{required:["explode"]}},{not:{required:["allowReserved"]}},{not:{required:["example"]}},{not:{required:["examples"]}}]}]},Parameter:{type:"object",properties:{name:{type:"string"},in:{type:"string"},description:{type:"string"},required:{type:"boolean",default:!1},deprecated:{type:"boolean",default:!1},allowEmptyValue:{type:"boolean",default:!1},style:{type:"string"},explode:{type:"boolean"},allowReserved:{type:"boolean",default:!1},schema:{oneOf:[{$ref:"#/definitions/Schema"},{$ref:"#/definitions/Reference"}]},content:{type:"object",additionalProperties:{$ref:"#/definitions/MediaType"},minProperties:1,maxProperties:1},example:{},examples:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Example"},{$ref:"#/definitions/Reference"}]}}},patternProperties:{"^x-":{}},additionalProperties:!1,required:["name","in"],allOf:[{$ref:"#/definitions/ExampleXORExamples"},{$ref:"#/definitions/SchemaXORContent"}],oneOf:[{$ref:"#/definitions/PathParameter"},{$ref:"#/definitions/QueryParameter"},{$ref:"#/definitions/HeaderParameter"},{$ref:"#/definitions/CookieParameter"}]},PathParameter:{description:"Parameter in path",required:["required"],properties:{in:{enum:["path"]},style:{enum:["matrix","label","simple"],default:"simple"},required:{enum:[!0]}}},QueryParameter:{description:"Parameter in query",properties:{in:{enum:["query"]},style:{enum:["form","spaceDelimited","pipeDelimited","deepObject"],default:"form"}}},HeaderParameter:{description:"Parameter in header",properties:{in:{enum:["header"]},style:{enum:["simple"],default:"simple"}}},CookieParameter:{description:"Parameter in cookie",properties:{in:{enum:["cookie"]},style:{enum:["form"],default:"form"}}},RequestBody:{type:"object",required:["content"],properties:{description:{type:"string"},content:{type:"object",additionalProperties:{$ref:"#/definitions/MediaType"}},required:{type:"boolean",default:!1}},patternProperties:{"^x-":{}},additionalProperties:!1},SecurityScheme:{oneOf:[{$ref:"#/definitions/APIKeySecurityScheme"},{$ref:"#/definitions/HTTPSecurityScheme"},{$ref:"#/definitions/OAuth2SecurityScheme"},{$ref:"#/definitions/OpenIdConnectSecurityScheme"}]},APIKeySecurityScheme:{type:"object",required:["type","name","in"],properties:{type:{type:"string",enum:["apiKey"]},name:{type:"string"},in:{type:"string",enum:["header","query","cookie"]},description:{type:"string"}},patternProperties:{"^x-":{}},additionalProperties:!1},HTTPSecurityScheme:{type:"object",required:["scheme","type"],properties:{scheme:{type:"string"},bearerFormat:{type:"string"},description:{type:"string"},type:{type:"string",enum:["http"]}},patternProperties:{"^x-":{}},additionalProperties:!1,oneOf:[{description:"Bearer",properties:{scheme:{type:"string",pattern:"^[Bb][Ee][Aa][Rr][Ee][Rr]$"}}},{description:"Non Bearer",not:{required:["bearerFormat"]},properties:{scheme:{not:{type:"string",pattern:"^[Bb][Ee][Aa][Rr][Ee][Rr]$"}}}}]},OAuth2SecurityScheme:{type:"object",required:["type","flows"],properties:{type:{type:"string",enum:["oauth2"]},flows:{$ref:"#/definitions/OAuthFlows"},description:{type:"string"}},patternProperties:{"^x-":{}},additionalProperties:!1},OpenIdConnectSecurityScheme:{type:"object",required:["type","openIdConnectUrl"],properties:{type:{type:"string",enum:["openIdConnect"]},openIdConnectUrl:{type:"string",format:"uri-reference"},description:{type:"string"}},patternProperties:{"^x-":{}},additionalProperties:!1},OAuthFlows:{type:"object",properties:{implicit:{$ref:"#/definitions/ImplicitOAuthFlow"},password:{$ref:"#/definitions/PasswordOAuthFlow"},clientCredentials:{$ref:"#/definitions/ClientCredentialsFlow"},authorizationCode:{$ref:"#/definitions/AuthorizationCodeOAuthFlow"}},patternProperties:{"^x-":{}},additionalProperties:!1},ImplicitOAuthFlow:{type:"object",required:["authorizationUrl","scopes"],properties:{authorizationUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{type:"object",additionalProperties:{type:"string"}}},patternProperties:{"^x-":{}},additionalProperties:!1},PasswordOAuthFlow:{type:"object",required:["tokenUrl","scopes"],properties:{tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{type:"object",additionalProperties:{type:"string"}}},patternProperties:{"^x-":{}},additionalProperties:!1},ClientCredentialsFlow:{type:"object",required:["tokenUrl","scopes"],properties:{tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{type:"object",additionalProperties:{type:"string"}}},patternProperties:{"^x-":{}},additionalProperties:!1},AuthorizationCodeOAuthFlow:{type:"object",required:["authorizationUrl","tokenUrl","scopes"],properties:{authorizationUrl:{type:"string",format:"uri-reference"},tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{type:"object",additionalProperties:{type:"string"}}},patternProperties:{"^x-":{}},additionalProperties:!1},Link:{type:"object",properties:{operationId:{type:"string"},operationRef:{type:"string",format:"uri-reference"},parameters:{type:"object",additionalProperties:{}},requestBody:{},description:{type:"string"},server:{$ref:"#/definitions/Server"}},patternProperties:{"^x-":{}},additionalProperties:!1,not:{description:"Operation Id and Operation Ref are mutually exclusive",required:["operationId","operationRef"]}},Callback:{type:"object",additionalProperties:{$ref:"#/definitions/PathItem"},patternProperties:{"^x-":{}}},Encoding:{type:"object",properties:{contentType:{type:"string"},headers:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/Header"},{$ref:"#/definitions/Reference"}]}},style:{type:"string",enum:["form","spaceDelimited","pipeDelimited","deepObject"]},explode:{type:"boolean"},allowReserved:{type:"boolean",default:!1}},patternProperties:{"^x-":{}},additionalProperties:!1}}};var b4={title:"A JSON Schema for Swagger 2.0 API.",id:"http://swagger.io/v2/schema.json#",$schema:"http://json-schema.org/draft-04/schema#",type:"object",required:["swagger","info","paths"],additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{swagger:{type:"string",enum:["2.0"],description:"The Swagger version of this document."},info:{$ref:"#/definitions/info"},host:{type:"string",pattern:"^[^{}/ :\\\\]+(?::\\d+)?$",description:"The host (name or ip) of the API. Example: 'swagger.io'"},basePath:{type:"string",pattern:"^/",description:"The base path to the API. Example: '/api'."},schemes:{$ref:"#/definitions/schemesList"},consumes:{description:"A list of MIME types accepted by the API.",allOf:[{$ref:"#/definitions/mediaTypeList"}]},produces:{description:"A list of MIME types the API can produce.",allOf:[{$ref:"#/definitions/mediaTypeList"}]},paths:{$ref:"#/definitions/paths"},definitions:{$ref:"#/definitions/definitions"},parameters:{$ref:"#/definitions/parameterDefinitions"},responses:{$ref:"#/definitions/responseDefinitions"},security:{$ref:"#/definitions/security"},securityDefinitions:{$ref:"#/definitions/securityDefinitions"},tags:{type:"array",items:{$ref:"#/definitions/tag"},uniqueItems:!0},externalDocs:{$ref:"#/definitions/externalDocs"}},definitions:{info:{type:"object",description:"General information about the API.",required:["version","title"],additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{title:{type:"string",description:"A unique and precise title of the API."},version:{type:"string",description:"A semantic version number of the API."},description:{type:"string",description:"A longer description of the API. Should be different from the title. GitHub Flavored Markdown is allowed."},termsOfService:{type:"string",description:"The terms of service for the API."},contact:{$ref:"#/definitions/contact"},license:{$ref:"#/definitions/license"}}},contact:{type:"object",description:"Contact information for the owners of the API.",additionalProperties:!1,properties:{name:{type:"string",description:"The identifying name of the contact person/organization."},url:{type:"string",description:"The URL pointing to the contact information.",format:"uri"},email:{type:"string",description:"The email address of the contact person/organization.",format:"email"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},license:{type:"object",required:["name"],additionalProperties:!1,properties:{name:{type:"string",description:"The name of the license type. It's encouraged to use an OSI compatible license."},url:{type:"string",description:"The URL pointing to the license.",format:"uri"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},paths:{type:"object",description:"Relative paths to the individual endpoints. They must be relative to the 'basePath'.",patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"},"^/":{$ref:"#/definitions/pathItem"}},additionalProperties:!1},definitions:{type:"object",additionalProperties:{$ref:"#/definitions/schema"},description:"One or more JSON objects describing the schemas being consumed and produced by the API."},parameterDefinitions:{type:"object",additionalProperties:{$ref:"#/definitions/parameter"},description:"One or more JSON representations for parameters"},responseDefinitions:{type:"object",additionalProperties:{$ref:"#/definitions/response"},description:"One or more JSON representations for responses"},externalDocs:{type:"object",additionalProperties:!1,description:"information about external documentation",required:["url"],properties:{description:{type:"string"},url:{type:"string",format:"uri"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},examples:{type:"object",additionalProperties:!0},mimeType:{type:"string",description:"The MIME type of the HTTP message."},operation:{type:"object",required:["responses"],additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{tags:{type:"array",items:{type:"string"},uniqueItems:!0},summary:{type:"string",description:"A brief summary of the operation."},description:{type:"string",description:"A longer description of the operation, GitHub Flavored Markdown is allowed."},externalDocs:{$ref:"#/definitions/externalDocs"},operationId:{type:"string",description:"A unique identifier of the operation."},produces:{description:"A list of MIME types the API can produce.",allOf:[{$ref:"#/definitions/mediaTypeList"}]},consumes:{description:"A list of MIME types the API can consume.",allOf:[{$ref:"#/definitions/mediaTypeList"}]},parameters:{$ref:"#/definitions/parametersList"},responses:{$ref:"#/definitions/responses"},schemes:{$ref:"#/definitions/schemesList"},deprecated:{type:"boolean",default:!1},security:{$ref:"#/definitions/security"}}},pathItem:{type:"object",additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{$ref:{type:"string"},get:{$ref:"#/definitions/operation"},put:{$ref:"#/definitions/operation"},post:{$ref:"#/definitions/operation"},delete:{$ref:"#/definitions/operation"},options:{$ref:"#/definitions/operation"},head:{$ref:"#/definitions/operation"},patch:{$ref:"#/definitions/operation"},parameters:{$ref:"#/definitions/parametersList"}}},responses:{type:"object",description:"Response objects names can either be any valid HTTP status code or 'default'.",minProperties:1,additionalProperties:!1,patternProperties:{"^([0-9]{3})$|^(default)$":{$ref:"#/definitions/responseValue"},"^x-":{$ref:"#/definitions/vendorExtension"}},not:{type:"object",additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}}},responseValue:{oneOf:[{$ref:"#/definitions/response"},{$ref:"#/definitions/jsonReference"}]},response:{type:"object",required:["description"],properties:{description:{type:"string"},schema:{oneOf:[{$ref:"#/definitions/schema"},{$ref:"#/definitions/fileSchema"}]},headers:{$ref:"#/definitions/headers"},examples:{$ref:"#/definitions/examples"}},additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},headers:{type:"object",additionalProperties:{$ref:"#/definitions/header"}},header:{type:"object",additionalProperties:!1,required:["type"],properties:{type:{type:"string",enum:["string","number","integer","boolean","array"]},format:{type:"string"},items:{$ref:"#/definitions/primitivesItems"},collectionFormat:{$ref:"#/definitions/collectionFormat"},default:{$ref:"#/definitions/default"},maximum:{$ref:"#/definitions/maximum"},exclusiveMaximum:{$ref:"#/definitions/exclusiveMaximum"},minimum:{$ref:"#/definitions/minimum"},exclusiveMinimum:{$ref:"#/definitions/exclusiveMinimum"},maxLength:{$ref:"#/definitions/maxLength"},minLength:{$ref:"#/definitions/minLength"},pattern:{$ref:"#/definitions/pattern"},maxItems:{$ref:"#/definitions/maxItems"},minItems:{$ref:"#/definitions/minItems"},uniqueItems:{$ref:"#/definitions/uniqueItems"},enum:{$ref:"#/definitions/enum"},multipleOf:{$ref:"#/definitions/multipleOf"},description:{type:"string"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},vendorExtension:{description:"Any property starting with x- is valid.",additionalProperties:!0,additionalItems:!0},bodyParameter:{type:"object",required:["name","in","schema"],patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{description:{type:"string",description:"A brief description of the parameter. This could contain examples of use. GitHub Flavored Markdown is allowed."},name:{type:"string",description:"The name of the parameter."},in:{type:"string",description:"Determines the location of the parameter.",enum:["body"]},required:{type:"boolean",description:"Determines whether or not this parameter is required or optional.",default:!1},schema:{$ref:"#/definitions/schema"}},additionalProperties:!1},headerParameterSubSchema:{additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{required:{type:"boolean",description:"Determines whether or not this parameter is required or optional.",default:!1},in:{type:"string",description:"Determines the location of the parameter.",enum:["header"]},description:{type:"string",description:"A brief description of the parameter. This could contain examples of use. GitHub Flavored Markdown is allowed."},name:{type:"string",description:"The name of the parameter."},type:{type:"string",enum:["string","number","boolean","integer","array"]},format:{type:"string"},items:{$ref:"#/definitions/primitivesItems"},collectionFormat:{$ref:"#/definitions/collectionFormat"},default:{$ref:"#/definitions/default"},maximum:{$ref:"#/definitions/maximum"},exclusiveMaximum:{$ref:"#/definitions/exclusiveMaximum"},minimum:{$ref:"#/definitions/minimum"},exclusiveMinimum:{$ref:"#/definitions/exclusiveMinimum"},maxLength:{$ref:"#/definitions/maxLength"},minLength:{$ref:"#/definitions/minLength"},pattern:{$ref:"#/definitions/pattern"},maxItems:{$ref:"#/definitions/maxItems"},minItems:{$ref:"#/definitions/minItems"},uniqueItems:{$ref:"#/definitions/uniqueItems"},enum:{$ref:"#/definitions/enum"},multipleOf:{$ref:"#/definitions/multipleOf"}}},queryParameterSubSchema:{additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{required:{type:"boolean",description:"Determines whether or not this parameter is required or optional.",default:!1},in:{type:"string",description:"Determines the location of the parameter.",enum:["query"]},description:{type:"string",description:"A brief description of the parameter. This could contain examples of use. GitHub Flavored Markdown is allowed."},name:{type:"string",description:"The name of the parameter."},allowEmptyValue:{type:"boolean",default:!1,description:"allows sending a parameter by name only or with an empty value."},type:{type:"string",enum:["string","number","boolean","integer","array"]},format:{type:"string"},items:{$ref:"#/definitions/primitivesItems"},collectionFormat:{$ref:"#/definitions/collectionFormatWithMulti"},default:{$ref:"#/definitions/default"},maximum:{$ref:"#/definitions/maximum"},exclusiveMaximum:{$ref:"#/definitions/exclusiveMaximum"},minimum:{$ref:"#/definitions/minimum"},exclusiveMinimum:{$ref:"#/definitions/exclusiveMinimum"},maxLength:{$ref:"#/definitions/maxLength"},minLength:{$ref:"#/definitions/minLength"},pattern:{$ref:"#/definitions/pattern"},maxItems:{$ref:"#/definitions/maxItems"},minItems:{$ref:"#/definitions/minItems"},uniqueItems:{$ref:"#/definitions/uniqueItems"},enum:{$ref:"#/definitions/enum"},multipleOf:{$ref:"#/definitions/multipleOf"}}},formDataParameterSubSchema:{additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{required:{type:"boolean",description:"Determines whether or not this parameter is required or optional.",default:!1},in:{type:"string",description:"Determines the location of the parameter.",enum:["formData"]},description:{type:"string",description:"A brief description of the parameter. This could contain examples of use. GitHub Flavored Markdown is allowed."},name:{type:"string",description:"The name of the parameter."},allowEmptyValue:{type:"boolean",default:!1,description:"allows sending a parameter by name only or with an empty value."},type:{type:"string",enum:["string","number","boolean","integer","array","file"]},format:{type:"string"},items:{$ref:"#/definitions/primitivesItems"},collectionFormat:{$ref:"#/definitions/collectionFormatWithMulti"},default:{$ref:"#/definitions/default"},maximum:{$ref:"#/definitions/maximum"},exclusiveMaximum:{$ref:"#/definitions/exclusiveMaximum"},minimum:{$ref:"#/definitions/minimum"},exclusiveMinimum:{$ref:"#/definitions/exclusiveMinimum"},maxLength:{$ref:"#/definitions/maxLength"},minLength:{$ref:"#/definitions/minLength"},pattern:{$ref:"#/definitions/pattern"},maxItems:{$ref:"#/definitions/maxItems"},minItems:{$ref:"#/definitions/minItems"},uniqueItems:{$ref:"#/definitions/uniqueItems"},enum:{$ref:"#/definitions/enum"},multipleOf:{$ref:"#/definitions/multipleOf"}}},pathParameterSubSchema:{additionalProperties:!1,patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},required:["required"],properties:{required:{type:"boolean",enum:[!0],description:"Determines whether or not this parameter is required or optional."},in:{type:"string",description:"Determines the location of the parameter.",enum:["path"]},description:{type:"string",description:"A brief description of the parameter. This could contain examples of use. GitHub Flavored Markdown is allowed."},name:{type:"string",description:"The name of the parameter."},type:{type:"string",enum:["string","number","boolean","integer","array"]},format:{type:"string"},items:{$ref:"#/definitions/primitivesItems"},collectionFormat:{$ref:"#/definitions/collectionFormat"},default:{$ref:"#/definitions/default"},maximum:{$ref:"#/definitions/maximum"},exclusiveMaximum:{$ref:"#/definitions/exclusiveMaximum"},minimum:{$ref:"#/definitions/minimum"},exclusiveMinimum:{$ref:"#/definitions/exclusiveMinimum"},maxLength:{$ref:"#/definitions/maxLength"},minLength:{$ref:"#/definitions/minLength"},pattern:{$ref:"#/definitions/pattern"},maxItems:{$ref:"#/definitions/maxItems"},minItems:{$ref:"#/definitions/minItems"},uniqueItems:{$ref:"#/definitions/uniqueItems"},enum:{$ref:"#/definitions/enum"},multipleOf:{$ref:"#/definitions/multipleOf"}}},nonBodyParameter:{type:"object",required:["name","in","type"],oneOf:[{$ref:"#/definitions/headerParameterSubSchema"},{$ref:"#/definitions/formDataParameterSubSchema"},{$ref:"#/definitions/queryParameterSubSchema"},{$ref:"#/definitions/pathParameterSubSchema"}]},parameter:{oneOf:[{$ref:"#/definitions/bodyParameter"},{$ref:"#/definitions/nonBodyParameter"}]},schema:{type:"object",description:"A deterministic version of a JSON Schema object.",patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},properties:{$ref:{type:"string"},format:{type:"string"},title:{$ref:"http://json-schema.org/draft-04/schema#/properties/title"},description:{$ref:"http://json-schema.org/draft-04/schema#/properties/description"},default:{$ref:"http://json-schema.org/draft-04/schema#/properties/default"},multipleOf:{$ref:"http://json-schema.org/draft-04/schema#/properties/multipleOf"},maximum:{$ref:"http://json-schema.org/draft-04/schema#/properties/maximum"},exclusiveMaximum:{$ref:"http://json-schema.org/draft-04/schema#/properties/exclusiveMaximum"},minimum:{$ref:"http://json-schema.org/draft-04/schema#/properties/minimum"},exclusiveMinimum:{$ref:"http://json-schema.org/draft-04/schema#/properties/exclusiveMinimum"},maxLength:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveInteger"},minLength:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveIntegerDefault0"},pattern:{$ref:"http://json-schema.org/draft-04/schema#/properties/pattern"},maxItems:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveInteger"},minItems:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveIntegerDefault0"},uniqueItems:{$ref:"http://json-schema.org/draft-04/schema#/properties/uniqueItems"},maxProperties:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveInteger"},minProperties:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveIntegerDefault0"},required:{$ref:"http://json-schema.org/draft-04/schema#/definitions/stringArray"},enum:{$ref:"http://json-schema.org/draft-04/schema#/properties/enum"},additionalProperties:{anyOf:[{$ref:"#/definitions/schema"},{type:"boolean"}],default:{}},type:{$ref:"http://json-schema.org/draft-04/schema#/properties/type"},items:{anyOf:[{$ref:"#/definitions/schema"},{type:"array",minItems:1,items:{$ref:"#/definitions/schema"}}],default:{}},allOf:{type:"array",minItems:1,items:{$ref:"#/definitions/schema"}},properties:{type:"object",additionalProperties:{$ref:"#/definitions/schema"},default:{}},discriminator:{type:"string"},readOnly:{type:"boolean",default:!1},xml:{$ref:"#/definitions/xml"},externalDocs:{$ref:"#/definitions/externalDocs"},example:{}},additionalProperties:!1},fileSchema:{type:"object",description:"A deterministic version of a JSON Schema object.",patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}},required:["type"],properties:{format:{type:"string"},title:{$ref:"http://json-schema.org/draft-04/schema#/properties/title"},description:{$ref:"http://json-schema.org/draft-04/schema#/properties/description"},default:{$ref:"http://json-schema.org/draft-04/schema#/properties/default"},required:{$ref:"http://json-schema.org/draft-04/schema#/definitions/stringArray"},type:{type:"string",enum:["file"]},readOnly:{type:"boolean",default:!1},externalDocs:{$ref:"#/definitions/externalDocs"},example:{}},additionalProperties:!1},primitivesItems:{type:"object",additionalProperties:!1,properties:{type:{type:"string",enum:["string","number","integer","boolean","array"]},format:{type:"string"},items:{$ref:"#/definitions/primitivesItems"},collectionFormat:{$ref:"#/definitions/collectionFormat"},default:{$ref:"#/definitions/default"},maximum:{$ref:"#/definitions/maximum"},exclusiveMaximum:{$ref:"#/definitions/exclusiveMaximum"},minimum:{$ref:"#/definitions/minimum"},exclusiveMinimum:{$ref:"#/definitions/exclusiveMinimum"},maxLength:{$ref:"#/definitions/maxLength"},minLength:{$ref:"#/definitions/minLength"},pattern:{$ref:"#/definitions/pattern"},maxItems:{$ref:"#/definitions/maxItems"},minItems:{$ref:"#/definitions/minItems"},uniqueItems:{$ref:"#/definitions/uniqueItems"},enum:{$ref:"#/definitions/enum"},multipleOf:{$ref:"#/definitions/multipleOf"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},security:{type:"array",items:{$ref:"#/definitions/securityRequirement"},uniqueItems:!0},securityRequirement:{type:"object",additionalProperties:{type:"array",items:{type:"string"},uniqueItems:!0}},xml:{type:"object",additionalProperties:!1,properties:{name:{type:"string"},namespace:{type:"string"},prefix:{type:"string"},attribute:{type:"boolean",default:!1},wrapped:{type:"boolean",default:!1}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},tag:{type:"object",additionalProperties:!1,required:["name"],properties:{name:{type:"string"},description:{type:"string"},externalDocs:{$ref:"#/definitions/externalDocs"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},securityDefinitions:{type:"object",additionalProperties:{oneOf:[{$ref:"#/definitions/basicAuthenticationSecurity"},{$ref:"#/definitions/apiKeySecurity"},{$ref:"#/definitions/oauth2ImplicitSecurity"},{$ref:"#/definitions/oauth2PasswordSecurity"},{$ref:"#/definitions/oauth2ApplicationSecurity"},{$ref:"#/definitions/oauth2AccessCodeSecurity"}]}},basicAuthenticationSecurity:{type:"object",additionalProperties:!1,required:["type"],properties:{type:{type:"string",enum:["basic"]},description:{type:"string"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},apiKeySecurity:{type:"object",additionalProperties:!1,required:["type","name","in"],properties:{type:{type:"string",enum:["apiKey"]},name:{type:"string"},in:{type:"string",enum:["header","query"]},description:{type:"string"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},oauth2ImplicitSecurity:{type:"object",additionalProperties:!1,required:["type","flow","authorizationUrl"],properties:{type:{type:"string",enum:["oauth2"]},flow:{type:"string",enum:["implicit"]},scopes:{$ref:"#/definitions/oauth2Scopes"},authorizationUrl:{type:"string",format:"uri"},description:{type:"string"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},oauth2PasswordSecurity:{type:"object",additionalProperties:!1,required:["type","flow","tokenUrl"],properties:{type:{type:"string",enum:["oauth2"]},flow:{type:"string",enum:["password"]},scopes:{$ref:"#/definitions/oauth2Scopes"},tokenUrl:{type:"string",format:"uri"},description:{type:"string"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},oauth2ApplicationSecurity:{type:"object",additionalProperties:!1,required:["type","flow","tokenUrl"],properties:{type:{type:"string",enum:["oauth2"]},flow:{type:"string",enum:["application"]},scopes:{$ref:"#/definitions/oauth2Scopes"},tokenUrl:{type:"string",format:"uri"},description:{type:"string"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},oauth2AccessCodeSecurity:{type:"object",additionalProperties:!1,required:["type","flow","authorizationUrl","tokenUrl"],properties:{type:{type:"string",enum:["oauth2"]},flow:{type:"string",enum:["accessCode"]},scopes:{$ref:"#/definitions/oauth2Scopes"},authorizationUrl:{type:"string",format:"uri"},tokenUrl:{type:"string",format:"uri"},description:{type:"string"}},patternProperties:{"^x-":{$ref:"#/definitions/vendorExtension"}}},oauth2Scopes:{type:"object",additionalProperties:{type:"string"}},mediaTypeList:{type:"array",items:{$ref:"#/definitions/mimeType"},uniqueItems:!0},parametersList:{type:"array",description:"The parameters needed to send a valid API call.",additionalItems:!1,items:{oneOf:[{$ref:"#/definitions/parameter"},{$ref:"#/definitions/jsonReference"}]},uniqueItems:!0},schemesList:{type:"array",description:"The transfer protocol of the API.",items:{type:"string",enum:["http","https","ws","wss"]},uniqueItems:!0},collectionFormat:{type:"string",enum:["csv","ssv","tsv","pipes"],default:"csv"},collectionFormatWithMulti:{type:"string",enum:["csv","ssv","tsv","pipes","multi"],default:"csv"},title:{$ref:"http://json-schema.org/draft-04/schema#/properties/title"},description:{$ref:"http://json-schema.org/draft-04/schema#/properties/description"},default:{$ref:"http://json-schema.org/draft-04/schema#/properties/default"},multipleOf:{$ref:"http://json-schema.org/draft-04/schema#/properties/multipleOf"},maximum:{$ref:"http://json-schema.org/draft-04/schema#/properties/maximum"},exclusiveMaximum:{$ref:"http://json-schema.org/draft-04/schema#/properties/exclusiveMaximum"},minimum:{$ref:"http://json-schema.org/draft-04/schema#/properties/minimum"},exclusiveMinimum:{$ref:"http://json-schema.org/draft-04/schema#/properties/exclusiveMinimum"},maxLength:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveInteger"},minLength:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveIntegerDefault0"},pattern:{$ref:"http://json-schema.org/draft-04/schema#/properties/pattern"},maxItems:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveInteger"},minItems:{$ref:"http://json-schema.org/draft-04/schema#/definitions/positiveIntegerDefault0"},uniqueItems:{$ref:"http://json-schema.org/draft-04/schema#/properties/uniqueItems"},enum:{$ref:"http://json-schema.org/draft-04/schema#/properties/enum"},jsonReference:{type:"object",required:["$ref"],additionalProperties:!1,properties:{$ref:{type:"string"}}}}};var OO={id:"umf.openapi",version:"0.1.0",coreVersion:"0.1.0",description:"OpenAPI JSON/YAML exact tree and source preservation",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:openapi:0.1.0",type:"object",required:["profile","root","originalSource","originalFormat"],properties:{profile:{const:"openapi-json-yaml-0.1"},root:{$ref:"#/$defs/node"},originalSource:{type:"string"},originalFormat:{enum:["json","yaml"]},baseUri:{type:"string",minLength:1},resources:{type:"array",items:{type:"object",required:["uri","root","originalSource","originalFormat"],properties:{uri:{type:"string",minLength:1},root:{$ref:"#/$defs/node"},originalSource:{type:"string"},originalFormat:{enum:["json","yaml"]}}}}},$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}},dependentRequired:{resources:["baseUri"]}},semantics:"CONTRACT-011. Exact native JSON tree and source archive; pinned OpenAPI/Swagger object schemas provide bounded validation, not reference, transport or runtime conformance.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"OpenAPI",version:"Swagger 2.0 schema 2017-08-27; OpenAPI 3.0 schema 2024-10-18; 3.1 schema 2026-08-03; 3.2 schema 2026-08-30",subset:"JSON-compatible JSON/YAML standalone descriptions; 2.0/3.0 check the Schema Object subset in their official schemas, known 3.1/3.2 embedded dialect keyword syntax is checked; unknown dialects are retained without reinterpretation; references and runtime rules remain incomplete; explicit URI-addressed resource archives and literal document-pointer lookup, without schema scope inference"},evidence:["tests/openapi/native.test.ts","tests/openapi/corpus.test.ts","fixtures/openapi/corpus-oracle-results.json","tests/openapi/bundle.test.ts","fixtures/openapi/resource-bundle-oracle-results.json","tests/openapi/schemas.test.ts","fixtures/openapi/embedded-schema-oracle-results.json","tests/openapi/references.test.ts","fixtures/openapi/reference-oracle-results.json","tests/openapi/extraction.test.ts","tests/openapi/scope.test.ts","fixtures/openapi/scope-oracle-results.json","tests/openapi/dynamic.test.ts","fixtures/openapi/dynamic-oracle-results.json"]}};var v4={$id:"https://spec.openapis.org/oas/3.1/schema/2026-08-03",$schema:"https://json-schema.org/draft/2020-12/schema",description:"The description of OpenAPI v3.1.x Documents without Schema Object validation",type:"object",properties:{openapi:{type:"string",pattern:"^3\\.1\\.\\d+(-.+)?$"},info:{$ref:"#/$defs/info"},jsonSchemaDialect:{type:"string",format:"uri-reference",default:"https://spec.openapis.org/oas/3.1/dialect/2024-11-10"},servers:{type:"array",items:{$ref:"#/$defs/server"},default:[{url:"/"}]},paths:{$ref:"#/$defs/paths"},webhooks:{type:"object",additionalProperties:{$ref:"#/$defs/path-item"}},components:{$ref:"#/$defs/components"},security:{type:"array",items:{$ref:"#/$defs/security-requirement"}},tags:{type:"array",items:{$ref:"#/$defs/tag"}},externalDocs:{$ref:"#/$defs/external-documentation"}},required:["openapi","info"],anyOf:[{required:["paths"]},{required:["components"]},{required:["webhooks"]}],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1,$defs:{info:{$comment:"https://spec.openapis.org/oas/v3.1#info-object",type:"object",properties:{title:{type:"string"},summary:{type:"string"},description:{type:"string"},termsOfService:{type:"string",format:"uri-reference"},contact:{$ref:"#/$defs/contact"},license:{$ref:"#/$defs/license"},version:{type:"string"}},required:["title","version"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},contact:{$comment:"https://spec.openapis.org/oas/v3.1#contact-object",type:"object",properties:{name:{type:"string"},url:{type:"string",format:"uri-reference"},email:{type:"string",format:"email"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},license:{$comment:"https://spec.openapis.org/oas/v3.1#license-object",type:"object",properties:{name:{type:"string"},identifier:{type:"string"},url:{type:"string",format:"uri-reference"}},required:["name"],dependentSchemas:{identifier:{not:{required:["url"]}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},server:{$comment:"https://spec.openapis.org/oas/v3.1#server-object",type:"object",properties:{url:{type:"string"},description:{type:"string"},variables:{type:"object",additionalProperties:{$ref:"#/$defs/server-variable"}}},required:["url"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"server-variable":{$comment:"https://spec.openapis.org/oas/v3.1#server-variable-object",type:"object",properties:{enum:{type:"array",items:{type:"string"},minItems:1},default:{type:"string"},description:{type:"string"}},required:["default"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},components:{$comment:"https://spec.openapis.org/oas/v3.1#components-object",type:"object",properties:{schemas:{type:"object",additionalProperties:{$dynamicRef:"#meta"}},responses:{type:"object",additionalProperties:{$ref:"#/$defs/response-or-reference"}},parameters:{type:"object",additionalProperties:{$ref:"#/$defs/parameter-or-reference"}},examples:{type:"object",additionalProperties:{$ref:"#/$defs/example-or-reference"}},requestBodies:{type:"object",additionalProperties:{$ref:"#/$defs/request-body-or-reference"}},headers:{type:"object",additionalProperties:{$ref:"#/$defs/header-or-reference"}},securitySchemes:{type:"object",additionalProperties:{$ref:"#/$defs/security-scheme-or-reference"}},links:{type:"object",additionalProperties:{$ref:"#/$defs/link-or-reference"}},callbacks:{type:"object",additionalProperties:{$ref:"#/$defs/callbacks-or-reference"}},pathItems:{type:"object",additionalProperties:{$ref:"#/$defs/path-item"}}},patternProperties:{"^(?:schemas|responses|parameters|examples|requestBodies|headers|securitySchemes|links|callbacks|pathItems)$":{$comment:"Enumerating all of the property names in the regex above is necessary for unevaluatedProperties to work as expected",propertyNames:{pattern:"^[a-zA-Z0-9._-]+$"}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},paths:{$comment:"https://spec.openapis.org/oas/v3.1#paths-object",type:"object",patternProperties:{"^/":{$ref:"#/$defs/path-item"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"path-item":{$comment:"https://spec.openapis.org/oas/v3.1#path-item-object",type:"object",properties:{$ref:{type:"string",format:"uri-reference"},summary:{type:"string"},description:{type:"string"},servers:{type:"array",items:{$ref:"#/$defs/server"}},parameters:{type:"array",items:{$ref:"#/$defs/parameter-or-reference"}},get:{$ref:"#/$defs/operation"},put:{$ref:"#/$defs/operation"},post:{$ref:"#/$defs/operation"},delete:{$ref:"#/$defs/operation"},options:{$ref:"#/$defs/operation"},head:{$ref:"#/$defs/operation"},patch:{$ref:"#/$defs/operation"},trace:{$ref:"#/$defs/operation"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},operation:{$comment:"https://spec.openapis.org/oas/v3.1#operation-object",type:"object",properties:{tags:{type:"array",items:{type:"string"}},summary:{type:"string"},description:{type:"string"},externalDocs:{$ref:"#/$defs/external-documentation"},operationId:{type:"string"},parameters:{type:"array",items:{$ref:"#/$defs/parameter-or-reference"}},requestBody:{$ref:"#/$defs/request-body-or-reference"},responses:{$ref:"#/$defs/responses"},callbacks:{type:"object",additionalProperties:{$ref:"#/$defs/callbacks-or-reference"}},deprecated:{default:!1,type:"boolean"},security:{type:"array",items:{$ref:"#/$defs/security-requirement"}},servers:{type:"array",items:{$ref:"#/$defs/server"}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"external-documentation":{$comment:"https://spec.openapis.org/oas/v3.1#external-documentation-object",type:"object",properties:{description:{type:"string"},url:{type:"string",format:"uri-reference"}},required:["url"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},parameter:{$comment:"https://spec.openapis.org/oas/v3.1#parameter-object",type:"object",properties:{name:{type:"string"},in:{enum:["query","header","path","cookie"]},description:{type:"string"},required:{default:!1,type:"boolean"},deprecated:{default:!1,type:"boolean"},schema:{$dynamicRef:"#meta"},content:{$ref:"#/$defs/content",minProperties:1,maxProperties:1}},required:["name","in"],oneOf:[{required:["schema"]},{required:["content"]}],if:{properties:{in:{const:"query"}}},then:{properties:{allowEmptyValue:{default:!1,type:"boolean"}}},dependentSchemas:{schema:{properties:{style:{type:"string"},explode:{type:"boolean"}},allOf:[{$ref:"#/$defs/examples"},{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-path"},{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-header"},{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-query"},{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-cookie"}],$defs:{"styles-for-path":{if:{properties:{in:{const:"path"}}},then:{properties:{name:{pattern:"^[^{}]+$"},style:{default:"simple",enum:["matrix","label","simple"]},required:{const:!0},explode:{default:!1}},required:["required"]}},"styles-for-header":{if:{properties:{in:{const:"header"}}},then:{properties:{style:{default:"simple",const:"simple"},explode:{default:!1}}}},"styles-for-query":{if:{properties:{in:{const:"query"}}},then:{properties:{style:{default:"form",enum:["form","spaceDelimited","pipeDelimited","deepObject"]},allowReserved:{default:!1,type:"boolean"}},$ref:"#/$defs/explode-for-form"}},"styles-for-cookie":{if:{properties:{in:{const:"cookie"}}},then:{properties:{style:{default:"form",const:"form"}},$ref:"#/$defs/explode-for-form"}}}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"parameter-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/parameter"}},"request-body":{$comment:"https://spec.openapis.org/oas/v3.1#request-body-object",type:"object",properties:{description:{type:"string"},content:{$ref:"#/$defs/content"},required:{default:!1,type:"boolean"}},required:["content"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"request-body-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/request-body"}},content:{$comment:"https://spec.openapis.org/oas/v3.1#fixed-fields-10",type:"object",additionalProperties:{$ref:"#/$defs/media-type"},propertyNames:{format:"media-range"}},"media-type":{$comment:"https://spec.openapis.org/oas/v3.1#media-type-object",type:"object",properties:{schema:{$dynamicRef:"#meta"},encoding:{type:"object",additionalProperties:{$ref:"#/$defs/encoding"}}},allOf:[{$ref:"#/$defs/specification-extensions"},{$ref:"#/$defs/examples"}],unevaluatedProperties:!1},encoding:{$comment:"https://spec.openapis.org/oas/v3.1#encoding-object",type:"object",properties:{contentType:{$comment:"one or more comma-separated media-ranges",type:"string"},headers:{type:"object",additionalProperties:{$ref:"#/$defs/header-or-reference"}},style:{enum:["form","spaceDelimited","pipeDelimited","deepObject"]},explode:{type:"boolean"},allowReserved:{type:"boolean"}},dependentSchemas:{style:{properties:{allowReserved:{default:!1}},$ref:"#/$defs/explode-for-form"},explode:{properties:{style:{default:"form"},allowReserved:{default:!1}}},allowReserved:{properties:{style:{default:"form"}},$ref:"#/$defs/explode-for-form"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},responses:{$comment:"https://spec.openapis.org/oas/v3.1#responses-object",type:"object",properties:{default:{$ref:"#/$defs/response-or-reference"}},patternProperties:{"^[1-5](?:[0-9]{2}|XX)$":{$ref:"#/$defs/response-or-reference"}},minProperties:1,$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1,if:{$comment:"either default, or at least one response code property must exist",patternProperties:{"^[1-5](?:[0-9]{2}|XX)$":!1}},then:{required:["default"]}},response:{$comment:"https://spec.openapis.org/oas/v3.1#response-object",type:"object",properties:{description:{type:"string"},headers:{type:"object",additionalProperties:{$ref:"#/$defs/header-or-reference"}},content:{$ref:"#/$defs/content"},links:{type:"object",additionalProperties:{$ref:"#/$defs/link-or-reference"}}},required:["description"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"response-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/response"}},callbacks:{$comment:"https://spec.openapis.org/oas/v3.1#callback-object",type:"object",$ref:"#/$defs/specification-extensions",additionalProperties:{$ref:"#/$defs/path-item"}},"callbacks-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/callbacks"}},example:{$comment:"https://spec.openapis.org/oas/v3.1#example-object",type:"object",properties:{summary:{type:"string"},description:{type:"string"},value:!0,externalValue:{type:"string",format:"uri-reference"}},not:{required:["value","externalValue"]},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"example-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/example"}},link:{$comment:"https://spec.openapis.org/oas/v3.1#link-object",type:"object",properties:{operationRef:{type:"string",format:"uri-reference"},operationId:{type:"string"},parameters:{$ref:"#/$defs/map-of-strings"},requestBody:!0,description:{type:"string"},server:{$ref:"#/$defs/server"}},oneOf:[{required:["operationRef"]},{required:["operationId"]}],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"link-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/link"}},header:{$comment:"https://spec.openapis.org/oas/v3.1#header-object",type:"object",properties:{description:{type:"string"},required:{default:!1,type:"boolean"},deprecated:{default:!1,type:"boolean"},schema:{$dynamicRef:"#meta"},content:{$ref:"#/$defs/content",minProperties:1,maxProperties:1}},oneOf:[{required:["schema"]},{required:["content"]}],dependentSchemas:{schema:{properties:{style:{default:"simple",const:"simple"},explode:{default:!1,type:"boolean"}},$ref:"#/$defs/examples"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"header-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/header"}},tag:{$comment:"https://spec.openapis.org/oas/v3.1#tag-object",type:"object",properties:{name:{type:"string"},description:{type:"string"},externalDocs:{$ref:"#/$defs/external-documentation"}},required:["name"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},reference:{$comment:"https://spec.openapis.org/oas/v3.1#reference-object",type:"object",properties:{$ref:{type:"string",format:"uri-reference"},summary:{type:"string"},description:{type:"string"}}},schema:{$comment:"https://spec.openapis.org/oas/v3.1#schema-object",$dynamicAnchor:"meta",type:["object","boolean"]},"security-scheme":{$comment:"https://spec.openapis.org/oas/v3.1#security-scheme-object",type:"object",properties:{type:{enum:["apiKey","http","mutualTLS","oauth2","openIdConnect"]},description:{type:"string"}},required:["type"],allOf:[{$ref:"#/$defs/specification-extensions"},{$ref:"#/$defs/security-scheme/$defs/type-apikey"},{$ref:"#/$defs/security-scheme/$defs/type-http"},{$ref:"#/$defs/security-scheme/$defs/type-http-bearer"},{$ref:"#/$defs/security-scheme/$defs/type-oauth2"},{$ref:"#/$defs/security-scheme/$defs/type-oidc"}],unevaluatedProperties:!1,$defs:{"type-apikey":{if:{properties:{type:{const:"apiKey"}}},then:{properties:{name:{type:"string"},in:{enum:["query","header","cookie"]}},required:["name","in"]}},"type-http":{if:{properties:{type:{const:"http"}}},then:{properties:{scheme:{type:"string"}},required:["scheme"]}},"type-http-bearer":{if:{properties:{type:{const:"http"},scheme:{type:"string",pattern:"^[Bb][Ee][Aa][Rr][Ee][Rr]$"}},required:["type","scheme"]},then:{properties:{bearerFormat:{type:"string"}}}},"type-oauth2":{if:{properties:{type:{const:"oauth2"}}},then:{properties:{flows:{$ref:"#/$defs/oauth-flows"}},required:["flows"]}},"type-oidc":{if:{properties:{type:{const:"openIdConnect"}}},then:{properties:{openIdConnectUrl:{type:"string",format:"uri-reference"}},required:["openIdConnectUrl"]}}}},"security-scheme-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/security-scheme"}},"oauth-flows":{type:"object",properties:{implicit:{$ref:"#/$defs/oauth-flows/$defs/implicit"},password:{$ref:"#/$defs/oauth-flows/$defs/password"},clientCredentials:{$ref:"#/$defs/oauth-flows/$defs/client-credentials"},authorizationCode:{$ref:"#/$defs/oauth-flows/$defs/authorization-code"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1,$defs:{implicit:{type:"object",properties:{authorizationUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["authorizationUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},password:{type:"object",properties:{tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["tokenUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"client-credentials":{type:"object",properties:{tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["tokenUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"authorization-code":{type:"object",properties:{authorizationUrl:{type:"string",format:"uri-reference"},tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["authorizationUrl","tokenUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1}}},"security-requirement":{$comment:"https://spec.openapis.org/oas/v3.1#security-requirement-object",type:"object",additionalProperties:{type:"array",items:{type:"string"}}},"specification-extensions":{$comment:"https://spec.openapis.org/oas/v3.1#specification-extensions",patternProperties:{"^x-":!0}},examples:{properties:{example:!0,examples:{type:"object",additionalProperties:{$ref:"#/$defs/example-or-reference"}}},not:{required:["example","examples"]}},"map-of-strings":{type:"object",additionalProperties:{type:"string"}},"explode-for-form":{$comment:"for encoding objects, and query and cookie parameters, style=form is the default",if:{properties:{style:{const:"form"}}},then:{properties:{explode:{default:!0}}},else:{properties:{explode:{default:!1}}}}}};var _4={$id:"https://spec.openapis.org/oas/3.2/schema/2026-08-30",$schema:"https://json-schema.org/draft/2020-12/schema",description:"The description of OpenAPI v3.2.x Documents without Schema Object validation",type:"object",properties:{openapi:{type:"string",pattern:"^3\\.2\\.[0-9]+(-.+)?$"},$self:{type:"string",format:"uri-reference",$comment:"MUST NOT contain a fragment",pattern:"^[^#]*$"},info:{$ref:"#/$defs/info"},jsonSchemaDialect:{type:"string",format:"uri-reference",default:"https://spec.openapis.org/oas/3.2/dialect/2026-02-26"},servers:{type:"array",items:{$ref:"#/$defs/server"},default:[{url:"/"}]},paths:{$ref:"#/$defs/paths"},webhooks:{type:"object",additionalProperties:{$ref:"#/$defs/path-item"}},components:{$ref:"#/$defs/components"},security:{type:"array",items:{$ref:"#/$defs/security-requirement"}},tags:{type:"array",items:{$ref:"#/$defs/tag"}},externalDocs:{$ref:"#/$defs/external-documentation"}},required:["openapi","info"],anyOf:[{required:["paths"]},{required:["components"]},{required:["webhooks"]}],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1,$defs:{info:{$comment:"https://spec.openapis.org/oas/v3.2#info-object",type:"object",properties:{title:{type:"string"},summary:{type:"string"},description:{type:"string"},termsOfService:{type:"string",format:"uri-reference"},contact:{$ref:"#/$defs/contact"},license:{$ref:"#/$defs/license"},version:{type:"string"}},required:["title","version"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},contact:{$comment:"https://spec.openapis.org/oas/v3.2#contact-object",type:"object",properties:{name:{type:"string"},url:{type:"string",format:"uri-reference"},email:{type:"string",format:"email"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},license:{$comment:"https://spec.openapis.org/oas/v3.2#license-object",type:"object",properties:{name:{type:"string"},identifier:{type:"string"},url:{type:"string",format:"uri-reference"}},required:["name"],dependentSchemas:{identifier:{not:{required:["url"]}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},server:{$comment:"https://spec.openapis.org/oas/v3.2#server-object",type:"object",properties:{url:{type:"string"},description:{type:"string"},name:{type:"string"},variables:{type:"object",additionalProperties:{$ref:"#/$defs/server-variable"}}},required:["url"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"server-variable":{$comment:"https://spec.openapis.org/oas/v3.2#server-variable-object",type:"object",properties:{enum:{type:"array",items:{type:"string"},minItems:1},default:{type:"string"},description:{type:"string"}},required:["default"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},components:{$comment:"https://spec.openapis.org/oas/v3.2#components-object",type:"object",properties:{schemas:{type:"object",additionalProperties:{$dynamicRef:"#meta"}},responses:{type:"object",additionalProperties:{$ref:"#/$defs/response-or-reference"}},parameters:{type:"object",additionalProperties:{$ref:"#/$defs/parameter-or-reference"}},examples:{type:"object",additionalProperties:{$ref:"#/$defs/example-or-reference"}},requestBodies:{type:"object",additionalProperties:{$ref:"#/$defs/request-body-or-reference"}},headers:{type:"object",additionalProperties:{$ref:"#/$defs/header-or-reference"}},securitySchemes:{type:"object",additionalProperties:{$ref:"#/$defs/security-scheme-or-reference"}},links:{type:"object",additionalProperties:{$ref:"#/$defs/link-or-reference"}},callbacks:{type:"object",additionalProperties:{$ref:"#/$defs/callbacks-or-reference"}},pathItems:{type:"object",additionalProperties:{$ref:"#/$defs/path-item"}},mediaTypes:{type:"object",additionalProperties:{$ref:"#/$defs/media-type-or-reference"}}},patternProperties:{"^(?:schemas|responses|parameters|examples|requestBodies|headers|securitySchemes|links|callbacks|pathItems|mediaTypes)$":{$comment:"Enumerating all of the property names in the regex above is necessary for unevaluatedProperties to work as expected",propertyNames:{pattern:"^[a-zA-Z0-9._-]+$"}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},paths:{$comment:"https://spec.openapis.org/oas/v3.2#paths-object",type:"object",patternProperties:{"^/":{$ref:"#/$defs/path-item"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"path-item":{$comment:"https://spec.openapis.org/oas/v3.2#path-item-object",type:"object",properties:{$ref:{type:"string",format:"uri-reference"},summary:{type:"string"},description:{type:"string"},servers:{type:"array",items:{$ref:"#/$defs/server"}},parameters:{$ref:"#/$defs/parameters"},additionalOperations:{type:"object",additionalProperties:{$ref:"#/$defs/operation"},propertyNames:{$comment:'RFC9110 restricts methods to "1*tchar" in ABNF',$ref:"#/$defs/token",not:{enum:["GET","PUT","POST","DELETE","OPTIONS","HEAD","PATCH","TRACE","QUERY"]}}},get:{$ref:"#/$defs/operation"},put:{$ref:"#/$defs/operation"},post:{$ref:"#/$defs/operation"},delete:{$ref:"#/$defs/operation"},options:{$ref:"#/$defs/operation"},head:{$ref:"#/$defs/operation"},patch:{$ref:"#/$defs/operation"},trace:{$ref:"#/$defs/operation"},query:{$ref:"#/$defs/operation"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},operation:{$comment:"https://spec.openapis.org/oas/v3.2#operation-object",type:"object",properties:{tags:{type:"array",items:{type:"string"}},summary:{type:"string"},description:{type:"string"},externalDocs:{$ref:"#/$defs/external-documentation"},operationId:{type:"string"},parameters:{$ref:"#/$defs/parameters"},requestBody:{$ref:"#/$defs/request-body-or-reference"},responses:{$ref:"#/$defs/responses"},callbacks:{type:"object",additionalProperties:{$ref:"#/$defs/callbacks-or-reference"}},deprecated:{default:!1,type:"boolean"},security:{type:"array",items:{$ref:"#/$defs/security-requirement"}},servers:{type:"array",items:{$ref:"#/$defs/server"}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"external-documentation":{$comment:"https://spec.openapis.org/oas/v3.2#external-documentation-object",type:"object",properties:{description:{type:"string"},url:{type:"string",format:"uri-reference"}},required:["url"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},parameters:{type:"array",items:{$ref:"#/$defs/parameter-or-reference"},not:{allOf:[{contains:{type:"object",properties:{in:{const:"query"}},required:["in"]}},{contains:{type:"object",properties:{in:{const:"querystring"}},required:["in"]}}]},contains:{type:"object",properties:{in:{const:"querystring"}},required:["in"]},minContains:0,maxContains:1},parameter:{$comment:"https://spec.openapis.org/oas/v3.2#parameter-object",type:"object",properties:{name:{type:"string"},in:{enum:["query","querystring","header","path","cookie"]},description:{type:"string"},required:{default:!1,type:"boolean"},deprecated:{default:!1,type:"boolean"},schema:{$dynamicRef:"#meta"},content:{$ref:"#/$defs/content",minProperties:1,maxProperties:1}},required:["name","in"],oneOf:[{required:["schema"]},{required:["content"]}],allOf:[{$ref:"#/$defs/examples"},{$ref:"#/$defs/specification-extensions"},{if:{properties:{in:{const:"query"}}},then:{properties:{allowEmptyValue:{default:!1,type:"boolean"}}}},{if:{properties:{in:{const:"querystring"}}},then:{required:["content"]}},{if:{properties:{in:{const:"path"}}},then:{properties:{name:{$comment:"see OAS 3.2.0 §4.8.2",pattern:"^[^{}]+$"}}}},{if:{properties:{in:{const:"header"}}},then:{properties:{name:{$comment:"see RFC9110 §5.1",$ref:"#/$defs/token"}}}}],dependentSchemas:{schema:{properties:{style:{type:"string"},explode:{type:"boolean"}},allOf:[{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-path"},{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-header"},{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-query"},{$ref:"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-cookie"}],$defs:{"styles-for-path":{if:{properties:{in:{const:"path"}}},then:{properties:{name:{pattern:"^[^{}]+$"},style:{default:"simple",enum:["matrix","label","simple"]},required:{const:!0},explode:{default:!1},allowReserved:{type:"boolean",default:!1}},required:["required"]}},"styles-for-header":{if:{properties:{in:{const:"header"}}},then:{properties:{style:{default:"simple",const:"simple"},explode:{default:!1}}}},"styles-for-query":{if:{properties:{in:{const:"query"}}},then:{properties:{style:{default:"form",enum:["form","spaceDelimited","pipeDelimited","deepObject"]},allowReserved:{type:"boolean",default:!1}},$ref:"#/$defs/explode-for-form"}},"styles-for-cookie":{if:{properties:{in:{const:"cookie"}}},then:{properties:{style:{default:"form",enum:["form","cookie"]},explode:{default:!0}},if:{properties:{style:{const:"form"}}},then:{properties:{allowReserved:{type:"boolean",default:!1}}}}}}}},unevaluatedProperties:!1},"parameter-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/parameter"}},"request-body":{$comment:"https://spec.openapis.org/oas/v3.2#request-body-object",type:"object",properties:{description:{type:"string"},content:{$ref:"#/$defs/content"},required:{default:!1,type:"boolean"}},required:["content"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"request-body-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/request-body"}},content:{$comment:`The \`content\` object is a property of: Parameter Object: https://spec.openapis.org/oas/v3.2#parameter-object Request Body Object: https://spec.openapis.org/oas/v3.2#request-body-object Response Object: https://spec.openapis.org/oas/v3.2#response-object Header Object: https://spec.openapis.org/oas/v3.2#header-object -`,type:"object",additionalProperties:{$ref:"#/$defs/media-type-or-reference"},propertyNames:{format:"media-range"}},"media-type":{$comment:"https://spec.openapis.org/oas/v3.2#media-type-object",type:"object",properties:{description:{type:"string"},schema:{$dynamicRef:"#meta"},itemSchema:{$dynamicRef:"#meta"},encoding:{type:"object",additionalProperties:{$ref:"#/$defs/encoding"}},prefixEncoding:{type:"array",items:{$ref:"#/$defs/encoding"}},itemEncoding:{$ref:"#/$defs/encoding"}},dependentSchemas:{encoding:{properties:{prefixEncoding:!1,itemEncoding:!1}}},allOf:[{$ref:"#/$defs/examples"},{$ref:"#/$defs/specification-extensions"}],unevaluatedProperties:!1},"media-type-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/media-type"}},encoding:{$comment:"https://spec.openapis.org/oas/v3.2#encoding-object",type:"object",properties:{contentType:{$comment:"one or more comma-separated media-ranges",type:"string"},headers:{type:"object",propertyNames:{$ref:"#/$defs/token"},additionalProperties:{$ref:"#/$defs/header-or-reference"}},style:{enum:["form","spaceDelimited","pipeDelimited","deepObject"]},explode:{type:"boolean"},allowReserved:{type:"boolean"},encoding:{type:"object",additionalProperties:{$ref:"#/$defs/encoding"}},prefixEncoding:{type:"array",items:{$ref:"#/$defs/encoding"}},itemEncoding:{$ref:"#/$defs/encoding"}},dependentSchemas:{encoding:{properties:{prefixEncoding:!1,itemEncoding:!1}},style:{properties:{allowReserved:{default:!1}},$ref:"#/$defs/explode-for-form"},explode:{properties:{style:{default:"form"},allowReserved:{default:!1}}},allowReserved:{properties:{style:{default:"form"}},$ref:"#/$defs/explode-for-form"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},responses:{$comment:"https://spec.openapis.org/oas/v3.2#responses-object",type:"object",properties:{default:{$ref:"#/$defs/response-or-reference"}},patternProperties:{"^[1-5](?:[0-9]{2}|XX)$":{$ref:"#/$defs/response-or-reference"}},minProperties:1,$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1,if:{$comment:"either default, or at least one response code property must exist",patternProperties:{"^[1-5](?:[0-9]{2}|XX)$":!1}},then:{required:["default"]}},response:{$comment:"https://spec.openapis.org/oas/v3.2#response-object",type:"object",properties:{summary:{type:"string"},description:{type:"string"},headers:{type:"object",propertyNames:{$ref:"#/$defs/token"},additionalProperties:{$ref:"#/$defs/header-or-reference"}},content:{$ref:"#/$defs/content"},links:{type:"object",additionalProperties:{$ref:"#/$defs/link-or-reference"}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"response-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/response"}},callbacks:{$comment:"https://spec.openapis.org/oas/v3.2#callback-object",type:"object",$ref:"#/$defs/specification-extensions",additionalProperties:{$ref:"#/$defs/path-item"}},"callbacks-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/callbacks"}},example:{$comment:"https://spec.openapis.org/oas/v3.2#example-object",type:"object",properties:{summary:{type:"string"},description:{type:"string"},dataValue:!0,serializedValue:{type:"string"},value:!0,externalValue:{type:"string",format:"uri-reference"}},allOf:[{not:{required:["value","externalValue"]}},{not:{required:["value","dataValue"]}},{not:{required:["value","serializedValue"]}},{not:{required:["serializedValue","externalValue"]}}],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"example-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/example"}},link:{$comment:"https://spec.openapis.org/oas/v3.2#link-object",type:"object",properties:{operationRef:{type:"string",format:"uri-reference"},operationId:{type:"string"},parameters:{$ref:"#/$defs/map-of-strings"},requestBody:!0,description:{type:"string"},server:{$ref:"#/$defs/server"}},oneOf:[{required:["operationRef"]},{required:["operationId"]}],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"link-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/link"}},header:{$comment:"https://spec.openapis.org/oas/v3.2#header-object",type:"object",properties:{description:{type:"string"},required:{default:!1,type:"boolean"},deprecated:{default:!1,type:"boolean"},schema:{$dynamicRef:"#meta"},content:{$ref:"#/$defs/content",minProperties:1,maxProperties:1}},oneOf:[{required:["schema"]},{required:["content"]}],dependentSchemas:{schema:{properties:{style:{default:"simple",const:"simple"},explode:{default:!1,type:"boolean"}}}},allOf:[{$ref:"#/$defs/examples"},{$ref:"#/$defs/specification-extensions"}],unevaluatedProperties:!1},"header-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/header"}},tag:{$comment:"https://spec.openapis.org/oas/v3.2#tag-object",type:"object",properties:{name:{type:"string"},summary:{type:"string"},description:{type:"string"},externalDocs:{$ref:"#/$defs/external-documentation"},parent:{type:"string"},kind:{type:"string"}},required:["name"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},reference:{$comment:"https://spec.openapis.org/oas/v3.2#reference-object",type:"object",properties:{$ref:{type:"string",format:"uri-reference"},summary:{type:"string"},description:{type:"string"}}},schema:{$comment:"https://spec.openapis.org/oas/v3.2#schema-object",$dynamicAnchor:"meta",type:["object","boolean"]},"security-scheme":{$comment:"https://spec.openapis.org/oas/v3.2#security-scheme-object",type:"object",properties:{type:{enum:["apiKey","http","mutualTLS","oauth2","openIdConnect"]},description:{type:"string"},deprecated:{default:!1,type:"boolean"}},required:["type"],allOf:[{$ref:"#/$defs/specification-extensions"},{$ref:"#/$defs/security-scheme/$defs/type-apikey"},{$ref:"#/$defs/security-scheme/$defs/type-http"},{$ref:"#/$defs/security-scheme/$defs/type-http-bearer"},{$ref:"#/$defs/security-scheme/$defs/type-oauth2"},{$ref:"#/$defs/security-scheme/$defs/type-oidc"}],unevaluatedProperties:!1,$defs:{"type-apikey":{if:{properties:{type:{const:"apiKey"}}},then:{properties:{name:{type:"string"},in:{enum:["query","header","cookie"]}},required:["name","in"]}},"type-http":{if:{properties:{type:{const:"http"}}},then:{properties:{scheme:{type:"string"}},required:["scheme"]}},"type-http-bearer":{if:{properties:{type:{const:"http"},scheme:{type:"string",pattern:"^[Bb][Ee][Aa][Rr][Ee][Rr]$"}},required:["type","scheme"]},then:{properties:{bearerFormat:{type:"string"}}}},"type-oauth2":{if:{properties:{type:{const:"oauth2"}}},then:{properties:{flows:{$ref:"#/$defs/oauth-flows"},oauth2MetadataUrl:{type:"string",format:"uri-reference"}},required:["flows"]}},"type-oidc":{if:{properties:{type:{const:"openIdConnect"}}},then:{properties:{openIdConnectUrl:{type:"string",format:"uri-reference"}},required:["openIdConnectUrl"]}}}},"security-scheme-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/security-scheme"}},"oauth-flows":{type:"object",properties:{implicit:{$ref:"#/$defs/oauth-flows/$defs/implicit"},password:{$ref:"#/$defs/oauth-flows/$defs/password"},clientCredentials:{$ref:"#/$defs/oauth-flows/$defs/client-credentials"},authorizationCode:{$ref:"#/$defs/oauth-flows/$defs/authorization-code"},deviceAuthorization:{$ref:"#/$defs/oauth-flows/$defs/device-authorization"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1,$defs:{implicit:{type:"object",properties:{authorizationUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["authorizationUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},password:{type:"object",properties:{tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["tokenUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"client-credentials":{type:"object",properties:{tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["tokenUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"authorization-code":{type:"object",properties:{authorizationUrl:{type:"string",format:"uri-reference"},tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["authorizationUrl","tokenUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"device-authorization":{type:"object",properties:{deviceAuthorizationUrl:{type:"string",format:"uri-reference"},tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["deviceAuthorizationUrl","tokenUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1}}},"security-requirement":{$comment:"https://spec.openapis.org/oas/v3.2#security-requirement-object",type:"object",additionalProperties:{type:"array",items:{type:"string"}}},"specification-extensions":{$comment:"https://spec.openapis.org/oas/v3.2#specification-extensions",patternProperties:{"^x-":!0}},examples:{properties:{example:!0,examples:{type:"object",additionalProperties:{$ref:"#/$defs/example-or-reference"}}},not:{required:["example","examples"]}},"map-of-strings":{type:"object",additionalProperties:{type:"string"}},"explode-for-form":{$comment:"for encoding objects, and query and cookie parameters, style=form is the default",if:{properties:{style:{const:"form"}}},then:{properties:{explode:{default:!0}}},else:{properties:{explode:{default:!1}}}},token:{$comment:"see https://www.rfc-editor.org/rfc/rfc9110.html#section-5.6.2",type:"string",pattern:"^[0-9A-Za-z!#$%&'*+.^_`|~-]+$"}}};var x4="umf.openapi",qwe=OO,Uwe=mt().compile(OO.schema);function w4(e){let t=new T4.default({allErrors:!0,strict:!1,ownProperties:!0,validateFormats:!1});return Gp(t),t.compile(e)}var Bwe={"2.0":w4(b4),"3.0":w4(g4),"3.1":mt(!1).compile(Bg(v4)),"3.2":mt(!1).compile(Bg(_4))},ow=(e,t)=>t==="json"?Jt(e):Wa(e);function Vwe(e){let t=e,n=[],r=(u,p,d)=>n.push({code:u,path:p,message:d,severity:"warning"});for(let u of Object.keys(t))if(!["profile","root","originalSource","originalFormat","baseUri","resources"].includes(u))r("OPENAPI_REPRESENTATION","/"+Pe(u),"Unknown representation field cannot be emitted natively");function i(u,p){let d=u.kind==="object"?["kind","members"]:u.kind==="array"?["kind","items"]:u.kind==="null"?["kind"]:["kind","value"];for(let f of Object.keys(u))if(!d.includes(f))r("OPENAPI_REPRESENTATION",p+"/"+Pe(f),"Unknown tree encoding field cannot be emitted natively");if(u.kind==="object")for(let[f,m]of Object.entries(u.members))i(m,p+"/members/"+Pe(f));if(u.kind==="array")u.items.forEach((f,m)=>i(f,p+"/items/"+m))}i(t.root,"/root");let s=new Set;try{if(t.baseUri)s.add(D4(t.baseUri))}catch(u){n.push({code:"OPENAPI_RESOURCE_URI",path:"/baseUri",severity:"error",message:String(u)})}for(let[u,p]of(t.resources??[]).entries()){let d="/resources/"+u;for(let f of Object.keys(p))if(!["uri","root","originalSource","originalFormat"].includes(f))r("OPENAPI_REPRESENTATION",d+"/"+Pe(f),"Unknown resource field cannot be emitted natively");i(p.root,d+"/root");try{let f=D4(p.uri);if(s.has(f))throw Error("Duplicate document URI");s.add(f),ow(p.originalSource,p.originalFormat)}catch(f){n.push({code:"OPENAPI_RESOURCE",path:d,severity:"error",message:String(f)})}}if(t.resources?.length)r("OPENAPI_RESOURCE_CONTEXT","/resources","Explicit resources are retained; URI/pointer lookup does not validate their contextual types, nested schema IDs, anchors, dynamic scope or reference closure");try{ow(t.originalSource,t.originalFormat)}catch(u){n.push({code:"OPENAPI_ARCHIVE",path:"/originalSource",severity:"error",message:String(u)})}if(t.root.kind!=="object")return n.push({code:"OPENAPI_ROOT",path:"/root",severity:"error",message:"OpenAPI description must be an object"}),n;let o=t.root.members.openapi??t.root.members.swagger;if(o?.kind!=="string")return n.push({code:"OPENAPI_VERSION",path:"/root",severity:"error",message:"Native openapi or swagger version must be a string"}),n;let a=o.value.slice(0,3),l=Bwe[a];if(!l)return r("OPENAPI_VERSION_UNSUPPORTED","/root","Native version retained without interpretation: "+o.value),n;let c;try{c=ms(Be(t.root),"json")}catch(u){return r("OPENAPI_NUMERIC","/root","Exact numeric tokens retained; host interpretation unavailable: "+String(u)),n}if(!l(c))for(let u of l.errors??[])n.push({code:"OPENAPI_OBJECT_SCHEMA",path:"/root"+u.instancePath,severity:"error",message:u.message??"Invalid OpenAPI object"});return n.push(...t4(c)),r("OPENAPI_VALIDATION_LIMIT","/root","Pinned official-schema checks do not prove reference resolution, URI formats, security execution, parameter serialization or all normative prose rules; known 3.1/3.2 embedded dialect keyword syntax is checked, while instances, unknown dialects and referenced resource contexts remain incomplete; legacy schemas check their declared Schema Object subset; extension content remains source-owned"),n}function Kwe(){return new nt().register(qwe,Vwe)}function $O(e){return We(e,Kwe())}function S4(e){let t=$O(e);if(!t.valid)throw new U("OPENAPI_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[x4];if(e.vocabularies[x4]?.version!=="0.1.0"||!Uwe(n))throw new U("OPENAPI_PAYLOAD","Missing or invalid OpenAPI payload");return Ae(n)}function D4(e){try{let t=new URL(e);if(t.hash||e.includes("#"))throw Error("Document URI cannot contain a fragment");return t.href}catch(t){throw new U("OPENAPI_RESOURCE_URI",String(t))}}function PO(e,t){if(t!==void 0&&!["json","yaml"].includes(t))throw new U("OPENAPI_FORMAT","Unsupported native format");if((t??e.originalFormat)===e.originalFormat&&Be(ow(e.originalSource,e.originalFormat))===Be(e.root))return e.originalSource;let r=Be(e.root)+` -`;if(r.length>Zt.maxTextLength)throw new U("LIMIT","Native OpenAPI output exceeds text limit");return r}function E4(e){if($O(e).diagnostics.some((t)=>t.code==="OPENAPI_REPRESENTATION"))throw new U("OPENAPI_REPRESENTATION","Native export would discard encoding content")}function k4(e,t){let n=S4(e);if(E4(e),n.resources?.length)throw new U("OPENAPI_BUNDLE_REQUIRED","Export the full bundle to retain referenced resources");return PO(n,t)}function N4(e){let t=S4(e),n=[t,...t.resources??[]].some((r)=>Be(ow(r.originalSource,r.originalFormat))!==Be(r.root));return E4(e),{schema:PO(t),format:t.originalFormat,...t.baseUri?{baseUri:t.baseUri}:{},resources:(t.resources??[]).map((r)=>({uri:r.uri,text:PO(r),format:r.originalFormat})),source:Ae(e),diagnostics:[...$O(e).diagnostics,...n?[{code:"OPENAPI_SOURCE_LAYOUT",path:"",severity:"warning",message:"Edited native output uses JSON syntax; original layout and comments remain in source archive"}]:[],{code:"SOURCE_ARTIFACT_REQUIRED",path:"",severity:"warning",message:"Retain source UMF for unrelated metadata and archived native layout"}]}}function O4(e){let t=[],n=(v,D,T)=>t.push({code:v,path:D,message:T,severity:"warning"});if(e.kind!=="object")return t;let r=e.members.metaData,i=e.members.protocol;if(r?.kind!=="object"||i?.kind!=="object")return t;let s=r.members.configuration;if(s?.kind!=="object")return t;let o=s.members["delta.columnMapping.mode"];if(!o||o.kind==="string"&&o.value==="none")return t;let a="/metaData/configuration/";if(o.kind!=="string"||!["id","name"].includes(o.value))return n("DELTA_MAPPING_MODE",a+"delta.columnMapping.mode","Unknown mapping mode remains uninterpreted"),t;let l=(v)=>v?.kind==="number"?v.value:void 0,c=(v,D)=>{let T=i.members[v];return T?.kind==="array"&&T.items.some((N)=>N.kind==="string"&&N.value===D)},u=l(i.members.minReaderVersion),p=l(i.members.minWriterVersion);if(!(u==="2"||u==="3"&&c("readerFeatures","columnMapping")))n("DELTA_MAPPING_READER_PROTOCOL","/protocol","Mapping requires reader 2 or reader 3 with columnMapping");if(!(["5","6"].includes(p??"")||p==="7"&&c("writerFeatures","columnMapping")))n("DELTA_MAPPING_WRITER_PROTOCOL","/protocol","Mapping requires writer 5/6 or writer 7 with columnMapping");n("DELTA_MAPPING_HISTORY_UNVERIFIED","/metaData/schemaString","Historical physical-path uniqueness, monotonic maxColumnId and actual Parquet field IDs are not verified");let d=s.members["delta.columnMapping.maxColumnId"],f,m=d?.kind==="string"?d.value.replace(/^(-?)0+(?=\d)/,"$1"):void 0;if(m!==void 0&&/^-?\d+$/.test(m)&&m.replace(/^-/,"").length<=10){if(f=BigInt(m),f<-2147483648n||f>2147483647n)f=void 0}if(f===void 0)n("DELTA_MAPPING_MAX_ID",a+"delta.columnMapping.maxColumnId","Expected a string containing a signed int32 maximum column ID");let y=r.members.schemaString;if(y?.kind!=="string")return t;let h;try{h=Jt(y.value)}catch{return t}let b=new Set,g=new Set;function x(v,D,T){if(v.kind!=="object"||v.members.type?.kind!=="string")return;if(v.members.type.value==="struct"&&v.members.fields?.kind==="array")v.members.fields.items.forEach((N,O)=>{if(N.kind!=="object")return;let C=D+"/fields/"+O,X=N.members.metadata,te=X?.kind==="object"?X.members:{},L=te["delta.columnMapping.id"],Y=te["delta.columnMapping.physicalName"];if(L?.kind!=="number"||!/^-?\d+$/.test(L.value)||L.value.replace(/^-/,"").length>10||BigInt(L.value)<-2147483648n||BigInt(L.value)>2147483647n)n("DELTA_MAPPING_ID",C+"/metadata/delta.columnMapping.id","Every mapped field requires an exact signed int32 column ID");else{let I=BigInt(L.value),Z=I.toString();if(b.has(Z))n("DELTA_MAPPING_DUPLICATE_ID",C+"/metadata/delta.columnMapping.id","Column ID is reused in the current schema");if(b.add(Z),f!==void 0&&I>f)n("DELTA_MAPPING_MAX_ID_BELOW_FIELD",a+"delta.columnMapping.maxColumnId","Declared maximum is below an assigned field ID")}let me;if(Y?.kind!=="string"||!Y.value)n("DELTA_MAPPING_PHYSICAL_NAME",C+"/metadata/delta.columnMapping.physicalName","Every mapped field requires a nonempty physical name");else if(T){me=[...T,Y.value];let I=JSON.stringify(me);if(g.has(I))n("DELTA_MAPPING_DUPLICATE_PATH",C+"/metadata/delta.columnMapping.physicalName","Physical field path is reused in the current schema");g.add(I)}if(N.members.type)x(N.members.type,C+"/type",me)});if(v.members.type.value==="array"&&v.members.elementType)x(v.members.elementType,D+"/elementType",T&&[...T,"element"]);if(v.members.type.value==="map"){if(v.members.keyType)x(v.members.keyType,D+"/keyType",T&&[...T,"key"]);if(v.members.valueType)x(v.members.valueType,D+"/valueType",T&&[...T,"value"])}}return x(h,"/metaData/schemaString",[]),t}var P4={id:"umf.delta.table",version:"0.1.0",coreVersion:"0.1.0",description:"Exact Delta metadata/protocol pair with embedded schema string and preserved future features",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:delta-table:0.1.0",type:"object",properties:{profile:{const:"delta-table-context"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-018 table context. An explicitly supplied metadata/protocol pair is not a reconciled transaction-log snapshot or a write authorization.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Delta transaction-log metadata and protocol context",version:"Protocol 3b1b99cd077ec9c84c8a94c250dea3730cc33392; deltalake 1.6.4 examples",subset:"Exact context preservation, known shape checks, incomplete feature diagnostics and guarded mapped rename candidates. No log reconciliation, transaction commit or general table evolution claim."},evidence:["tests/delta/upstream.test.ts","fixtures/delta/upstream/oracle-results.json","fixtures/delta/upstream/browser-results.json","tests/delta/table.test.ts","fixtures/delta/tables/results.json","fixtures/delta/table-results.json","fixtures/delta/table-browser-results.json","tests/delta/column-mapping.test.ts","tests/delta/rename.test.ts","fixtures/delta/mapping/oracle-results.json","fixtures/delta/mapped-data/rename-oracle-results.json","tests/delta/mapped-nested.test.ts","fixtures/delta/mapped-nested/oracle-results.json"]}};var $4={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:delta:table-context:0.1.0",type:"object",properties:{protocol:{type:"object",properties:{minReaderVersion:{type:"integer",minimum:1},minWriterVersion:{type:"integer",minimum:1},readerFeatures:{type:"array",items:{type:"string"}},writerFeatures:{type:"array",items:{type:"string"}}},required:["minReaderVersion","minWriterVersion"],additionalProperties:!0},metaData:{type:"object",properties:{id:{type:"string"},name:{type:["string","null"]},description:{type:["string","null"]},format:{type:"object",properties:{provider:{type:"string"},options:{type:"object",additionalProperties:{type:["string","null"]}}},required:["provider"],additionalProperties:!0},schemaString:{type:"string"},partitionColumns:{type:"array",items:{type:"string"}},configuration:{type:"object",additionalProperties:{type:["string","null"]}},createdTime:{type:["integer","null"]}},required:["id","format","schemaString","partitionColumns","configuration"],additionalProperties:!0}},required:["protocol","metaData"],additionalProperties:!0};var I4={id:"umf.delta",version:"0.1.0",coreVersion:"0.1.0",description:"Exact Delta schema JSON with explicit table/protocol interpretation limits",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:delta:0.1.0",type:"object",properties:{profile:{const:"delta-schema-json"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-018. Source tokens and unknown content are authoritative; no table feature support, SQL evaluation or native normalization is implied.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Delta schema JSON",version:"Protocol commit 3b1b99cd077ec9c84c8a94c250dea3730cc33392; deltalake 1.6.4 oracle",subset:"Recursive schema preservation, structural validation, copied pointer access and candidate edits. Table/protocol profile and execution support remain separate."},evidence:["tests/delta/upstream.test.ts","fixtures/delta/upstream/oracle-results.json","fixtures/delta/upstream/browser-results.json","tests/delta/schema.test.ts","fixtures/delta/capability-results.json","fixtures/delta/umf-oracle-results.json","fixtures/delta/browser-results.json"]}};var A4={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:delta:schema-json:0.1.0",type:"object",properties:{type:{const:"struct"},fields:{type:"array",items:{$ref:"#/$defs/field"}}},required:["type","fields"],additionalProperties:!0,$defs:{type:{anyOf:[{type:"string",minLength:1},{type:"object",properties:{type:{const:"struct"},fields:{type:"array",items:{$ref:"#/$defs/field"}}},required:["type","fields"],additionalProperties:!0},{type:"object",properties:{type:{const:"array"},elementType:{$ref:"#/$defs/type"},containsNull:{type:"boolean"}},required:["type","elementType","containsNull"],additionalProperties:!0},{type:"object",properties:{type:{const:"map"},keyType:{$ref:"#/$defs/type"},valueType:{$ref:"#/$defs/type"},valueContainsNull:{type:"boolean"}},required:["type","keyType","valueType"],additionalProperties:!0},{type:"object",properties:{type:{type:"string",minLength:1,not:{enum:["array","map","struct"]}}},required:["type"],additionalProperties:!0}]},field:{type:"object",properties:{name:{type:"string"},type:{$ref:"#/$defs/type"},nullable:{type:"boolean"},metadata:{type:"object"}},required:["name","type","nullable","metadata"],additionalProperties:!0}}};var aw="umf.delta",Wwe=I4,IO,Qwe=new Set(["string","long","integer","short","byte","float","double","boolean","binary","date","timestamp","timestamp_ntz","void","variant"]);function Ywe(e){let t=e,n=[{code:"DELTA_CONTEXT_UNVERIFIED",path:"",severity:"warning",message:"Schema alone cannot establish Delta protocol/features, table configuration or read/write validity"}],r=(l,c,u,p="warning")=>n.push({code:l,path:c,message:u,severity:p});if(Object.keys(t).some((l)=>!["profile","root"].includes(l)))r("DELTA_REPRESENTATION","","Unknown representation fields must remain in UMF");function i(l,c){let u=l.kind==="null"?["kind"]:l.kind==="array"?["kind","items"]:l.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(l).some((p)=>!u.includes(p)))r("DELTA_REPRESENTATION",c,"Unknown tagged-tree fields must remain in UMF");if(l.kind==="object")for(let[p,d]of Object.entries(l.members))i(d,c+"/"+Pe(p));if(l.kind==="array")l.items.forEach((p,d)=>i(p,c+"/"+d))}i(t.root,"/root");let s=JSON.parse(Be(t.root));if(IO??=mt().compile(A4),!IO(s)){for(let l of IO.errors??[])r("DELTA_STRUCTURE",l.instancePath,l.message??"Invalid Delta schema shape","error");return n}let o=(l,c,u)=>{for(let p of Object.keys(l))if(!c.includes(p))r("DELTA_UNKNOWN",u+"/"+Pe(p),"Unknown native property preserved; native normalization may discard it")};function a(l,c){if(typeof l==="string"){let u=/^decimal\((\d+),\s*(-?\d+)\)$/.exec(l);if(u){let p=Number(u[1]),d=Number(u[2]);if(p<1||p>38||d<0||d>p)r("DELTA_DECIMAL_RANGE",c,"Decimal parameters require native and protocol validation")}else if(!Qwe.has(l))r("DELTA_UNKNOWN_TYPE",c,"Type spelling is outside the declared protocol vocabulary; native parser acceptance is insufficient");if(["timestamp_ntz","variant"].includes(l))r("DELTA_FEATURE_REQUIRED",c,"Type requires matching table protocol/features; schema-only import cannot verify them");if(l==="void")r("DELTA_VOID_WRITE_CONTEXT",c,"Void storage omission and write restrictions require the surrounding table schema");return}if(l.type==="struct"){o(l,["type","fields"],c);let u=new Set;l.fields.forEach((p,d)=>{let f=c+"/fields/"+d;o(p,["name","type","nullable","metadata"],f);let m=p.name.toLowerCase();if(u.has(m))r("DELTA_DUPLICATE_NAME",f+"/name","Case-insensitive duplicate name; preserved source is not a valid Delta table schema");u.add(m),a(p.type,f+"/type");for(let y of Object.keys(p.metadata))r("DELTA_METADATA_UNVERIFIED",f+"/metadata/"+Pe(y),"Column metadata retained exactly; constraints, identity, mapping and defaults are not executed or validated against table context")})}else if(l.type==="array")o(l,["type","elementType","containsNull"],c),a(l.elementType,c+"/elementType");else if(l.type==="map"){if(o(l,["type","keyType","valueType","valueContainsNull"],c),a(l.keyType,c+"/keyType"),a(l.valueType,c+"/valueType"),l.valueContainsNull===void 0)r("DELTA_DEFAULT_NULLABILITY",c,"Native parser may insert valueContainsNull=true; source absence is retained")}else r("DELTA_UNKNOWN_TYPE",c,"Unknown object-form type retained without interpreting or executing it")}return a(s,""),n}function Xwe(){return new nt().register(Wwe,Ywe)}function lw(e){return We(e,Xwe())}function R4(e){let t=lw(e);if(!t.valid)throw new U("DELTA_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[aw];if(!n||e.vocabularies[aw]?.version!=="0.1.0")throw new U("DELTA_PAYLOAD","Expected pinned Delta schema payload");return Ae(n)}function j4(e,t){let n={umf:"0.1.0",id:t.id,vocabularies:{[aw]:{version:"0.1.0"}},modules:[{id:"schema",namespace:"",elements:[{id:"schema",extensions:{[aw]:{profile:"delta-schema-json",root:Jt(e)}}}]}]};return R4(n),n}function F4(e){let t=R4(e);if(lw(e).diagnostics.some((n)=>n.code==="DELTA_REPRESENTATION"))throw new U("DELTA_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var C4="umf.delta.table",Zwe=P4,AO;function eDe(e){let t=e,n=[{code:"DELTA_TABLE_UNVERIFIED",path:"",severity:"warning",message:"Supplied metadata/protocol context is not a reconciled snapshot; reader/writer support and safe evolution remain unverified"}],r=(u,p,d,f="warning")=>n.push({code:u,path:p,message:d,severity:f});if(Object.keys(t).some((u)=>!["profile","root"].includes(u)))r("DELTA_TABLE_REPRESENTATION","","Unknown profile fields must remain in UMF");function i(u,p){let d=u.kind==="null"?["kind"]:u.kind==="array"?["kind","items"]:u.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(u).some((f)=>!d.includes(f)))r("DELTA_TABLE_REPRESENTATION",p,"Unknown tagged-tree fields must remain in UMF");if(u.kind==="object")for(let[f,m]of Object.entries(u.members))i(m,p+"/"+Pe(f));if(u.kind==="array")u.items.forEach((f,m)=>i(f,p+"/"+m))}i(t.root,"/root");let s=JSON.parse(Be(t.root));if(AO??=mt().compile($4),!AO(s)){for(let u of AO.errors??[])r("DELTA_TABLE_STRUCTURE",u.instancePath,u.message??"Invalid table context","error");return n}let o=(u,p,d)=>{for(let f of Object.keys(u))if(!p.includes(f))r("DELTA_TABLE_UNKNOWN",d+"/"+Pe(f),"Unknown native property retained")};o(s,["protocol","metaData"],""),o(s.protocol,["minReaderVersion","minWriterVersion","readerFeatures","writerFeatures"],"/protocol"),o(s.metaData,["id","name","description","format","schemaString","partitionColumns","configuration","createdTime"],"/metaData"),o(s.metaData.format,["provider","options"],"/metaData/format");let a=s.protocol,l=a.readerFeatures??[],c=a.writerFeatures??[];for(let[u,p,d]of[[a.minReaderVersion,"readerFeatures",3],[a.minWriterVersion,"writerFeatures",7]]){if(u===d!==(a[p]!==void 0))r("DELTA_FEATURE_VERSION","/protocol/"+p,"Feature-list presence does not match the pinned protocol version rule");if(u>d)r("DELTA_FUTURE_PROTOCOL","/protocol","Future protocol version remains uninterpreted");if(a[p]){if(new Set(a[p]).size!==a[p].length)r("DELTA_DUPLICATE_FEATURE","/protocol/"+p,"Feature names must be unique");for(let[f,m]of a[p].entries())r("DELTA_FEATURE_UNVERIFIED","/protocol/"+p+"/"+f,"Feature preserved; implementation capability is not asserted: "+m)}}for(let u of l)if(!c.includes(u))r("DELTA_READER_FEATURE_WRITER","/protocol/readerFeatures","Reader feature absent from writer feature list: "+u);if(s.metaData.format.provider!=="parquet")r("DELTA_FORMAT_UNVERIFIED","/metaData/format/provider","Storage provider is outside the verified examples");for(let u of Object.keys(s.metaData.configuration))r("DELTA_CONFIGURATION_UNVERIFIED","/metaData/configuration/"+Pe(u),"Table configuration and embedded SQL preserved without execution or enforcement");try{let m=function(y,h){if(y==="timestamp_ntz"&&(!l.includes("timestampNtz")||!c.includes("timestampNtz")))r("DELTA_TIMESTAMP_NTZ_FEATURE",h,"timestamp_ntz requires reader and writer feature declarations");if(y&&typeof y==="object"){if(y.type==="struct")y.fields.forEach((b,g)=>m(b.type,h+"/fields/"+g+"/type"));if(y.type==="array")m(y.elementType,h+"/elementType");if(y.type==="map")m(y.keyType,h+"/keyType"),m(y.valueType,h+"/valueType")}},u=j4(s.metaData.schemaString,{id:"embedded"});for(let y of lw(u).diagnostics)n.push({...y,path:"/metaData/schemaString"+y.path});let p=JSON.parse(s.metaData.schemaString),d=new Set(p.fields.map((y)=>y.name)),f=new Set;for(let[y,h]of s.metaData.partitionColumns.entries()){if(!d.has(h))r("DELTA_PARTITION_UNRESOLVED","/metaData/partitionColumns/"+y,"Partition name does not exactly match a top-level field");if(f.has(h))r("DELTA_PARTITION_DUPLICATE","/metaData/partitionColumns/"+y,"Duplicate partition column");f.add(h)}m(p,"/metaData/schemaString")}catch{r("DELTA_EMBEDDED_SCHEMA","/metaData/schemaString","Embedded schema is invalid or outside known shape; exact string retained")}return n.push(...O4(t.root)),n}function tDe(){return new nt().register(Zwe,eDe)}function M4(e){return We(e,tDe())}function nDe(e){let t=M4(e);if(!t.valid)throw new U("DELTA_TABLE_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="table")?.elements.find((r)=>r.id==="table")?.extensions[C4];if(!n||e.vocabularies[C4]?.version!=="0.1.0")throw new U("DELTA_TABLE_PAYLOAD","Expected pinned Delta schema payload");return Ae(n)}function L4(e){let t=nDe(e);if(M4(e).diagnostics.some((n)=>n.code==="DELTA_TABLE_REPRESENTATION"))throw new U("DELTA_TABLE_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var q4={id:"umf.delta.log",version:"0.1.0",coreVersion:"0.1.0",description:"Exact Delta JSON-lines source capture with independent action inspection",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:delta-log:0.1.0",type:"object",required:["profile","text"],properties:{profile:{const:"delta-jsonl-source"},text:{type:"string",maxLength:1e6}},additionalProperties:!0},semantics:"CONTRACT-018. Source text is authoritative, including invalid lines and unknown actions; inspection does not reconcile state or authorize writes.",scopes:["element"],capabilities:{validation:"structural",directions:["import","export"],native:{system:"Delta JSON transaction log",version:"Protocol 3b1b99cd077ec9c84c8a94c250dea3730cc33392; pinned delta-rs corpus",subset:"Bounded exact text capture and line/action envelope inspection. Native action semantics, commit validity and snapshot reconciliation remain unverified."},evidence:["tests/delta/log.test.ts","tests/delta/actions.test.ts","tests/delta/reconcile.test.ts","tests/delta/checkpoint.test.ts","fixtures/delta/checkpoint/oracle-results.json","fixtures/delta/checkpoint/browser-results.json","tests/delta/history-upstream.test.ts","fixtures/delta/upstream/history-oracle-results.json","fixtures/delta/upstream/history-browser-results.json","fixtures/delta/history/oracle-results.json","fixtures/delta/history/browser-results.json","fixtures/delta/upstream/action-results.json","fixtures/delta/upstream/action-oracle-results.json","fixtures/delta/upstream/log-results.json","fixtures/delta/upstream/log-browser-results.json"]}};var U4="umf.delta.log",iDe=q4;function sDe(){return new nt().register(iDe)}function B4(e){if(!We(e,sDe()).valid)throw new U("DELTA_LOG_DOCUMENT","Invalid source capture envelope");let t=e.modules.find((n)=>n.id==="log")?.elements.find((n)=>n.id==="source")?.extensions[U4];if(e.vocabularies[U4]?.version!=="0.1.0"||!t||typeof t!=="object"||Array.isArray(t))throw new U("DELTA_LOG_PAYLOAD","Expected pinned log payload");if(Object.keys(t).some((n)=>!["profile","text"].includes(n)))throw new U("DELTA_LOG_REPRESENTATION","Unknown representation fields cannot be dropped from native export");if(typeof t.text!=="string"||t.text.length>1e6)throw new U("DELTA_LOG_LIMIT","Expected at most 1000000 UTF-16 code units");return t.text}var V4={id:"umf.iceberg",version:"0.1.0",coreVersion:"0.1.0",description:"Exact Iceberg schema JSON with field identity and explicit table-context limits",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:iceberg:0.1.0",type:"object",properties:{profile:{const:"iceberg-schema-json"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-020. Native JSON tokens remain authoritative. Identifier fields do not imply enforced uniqueness. Table metadata, storage evolution and default execution remain separate.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Apache Iceberg schema JSON",version:"1.11.0 spec 6976e020b894f6a6777704df2b8c4458cb291ae9; PyIceberg 0.11.0 oracle",subset:"Standalone recursive schema preservation, field-ID and identifier checks, pointer access and candidate edits; no table compatibility or data-reader claim"},evidence:["tests/iceberg/schema.test.ts","fixtures/iceberg/oracle-results.json","fixtures/iceberg/browser-results.json"]}};var K4={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:iceberg:schema-json:0.1.0",type:"object",properties:{type:{const:"struct"},fields:{type:"array",items:{$ref:"#/$defs/field"}},"schema-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"identifier-field-ids":{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647},uniqueItems:!0}},required:["type","fields"],additionalProperties:!0,$defs:{field:{type:"object",properties:{id:{type:"integer",minimum:-2147483648,maximum:2147483647},name:{type:"string"},required:{type:"boolean"},type:{$ref:"#/$defs/type"},doc:{type:"string"},"initial-default":{},"write-default":{}},required:["id","name","required","type"],additionalProperties:!0},type:{anyOf:[{type:"string",minLength:1},{type:"object",properties:{type:{const:"struct"},fields:{type:"array",items:{$ref:"#/$defs/field"}}},required:["type","fields"],additionalProperties:!0},{type:"object",properties:{type:{const:"list"},"element-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"element-required":{type:"boolean"},element:{$ref:"#/$defs/type"}},required:["type","element-id","element-required","element"],additionalProperties:!0},{type:"object",properties:{type:{const:"map"},"key-id":{type:"integer",minimum:-2147483648,maximum:2147483647},key:{$ref:"#/$defs/type"},"value-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"value-required":{type:"boolean"},value:{$ref:"#/$defs/type"}},required:["type","key-id","key","value-id","value-required","value"],additionalProperties:!0},{type:"object",properties:{type:{type:"string",minLength:1,not:{enum:["struct","list","map"]}}},required:["type"],additionalProperties:!0}]}}};var cw="umf.iceberg",lDe=V4,RO;function cDe(e){let t=e,n=[{code:"ICEBERG_CONTEXT_UNVERIFIED",path:"",severity:"warning",message:"Standalone schema does not establish table format-version, evolution legality, default execution or data-reader support"}],r=(p,d,f,m="warning")=>n.push({code:p,path:d,message:f,severity:m});if(Object.keys(t).some((p)=>!["profile","root"].includes(p)))r("ICEBERG_REPRESENTATION","","Unknown representation fields must remain in UMF");function i(p,d){let f=p.kind==="null"?["kind"]:p.kind==="array"?["kind","items"]:p.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(p).some((m)=>!f.includes(m)))r("ICEBERG_REPRESENTATION",d,"Unknown tagged-tree fields must remain in UMF");if(p.kind==="object")for(let[m,y]of Object.entries(p.members))i(y,d+"/"+Pe(m));if(p.kind==="array")p.items.forEach((m,y)=>i(m,d+"/"+y))}i(t.root,"/root");let s=JSON.parse(Be(t.root));if(RO??=mt().compile(K4),!RO(s)){for(let p of RO.errors??[])r("ICEBERG_STRUCTURE",p.instancePath,p.message??"Invalid shape","error");return n}let o=new Set(["unknown","boolean","int","long","float","double","date","time","timestamp","timestamptz","timestamp_ns","timestamptz_ns","string","uuid","binary","variant"]),a=new Map,l=(p,d,f,m)=>{if(a.has(p))r("ICEBERG_DUPLICATE_ID",m,"Field IDs must be unique across fields and list/map components","error");else a.set(p,{type:d,eligible:f,path:m});if(p<=0)r("ICEBERG_ID_CONTEXT",m,"Nonpositive ID retained; allocation legality requires table context");if(p>2147483447)r("ICEBERG_RESERVED_ID",m,"Reserved metadata-column range requires table context")},c=(p,d,f)=>{for(let m of Object.keys(p))if(!d.includes(m))r("ICEBERG_UNKNOWN",f+"/"+Pe(m),"Unknown native property preserved without interpretation")};function u(p,d,f,m,y=!1){if(typeof p==="string"){if(o.has(p))return;let h=/^decimal\((\d+),\s*(\d+)\)$/.exec(p),b=/^fixed\[(\d+)\]$/.exec(p);if(h){if(+h[1]<1||+h[1]>38||+h[2]>+h[1])r("ICEBERG_TYPE_PARAMETERS",d,"Decimal requires 1..38 precision and 0..precision scale","error");return}if(b){if(BigInt(b[1])<1n||BigInt(b[1])>2147483647n)r("ICEBERG_TYPE_PARAMETERS",d,"Fixed length must be a positive int32","error");return}r("ICEBERG_UNKNOWN_TYPE",d,"Uninterpreted native type spelling; geospatial and future type parameters require separate checks");return}if(p.type==="struct"){c(p,y?["type","fields","schema-id","identifier-field-ids"]:["type","fields"],d);let h=new Set;for(let[b,g]of p.fields.entries()){let x=d+"/fields/"+b;if(h.has(g.name))r("ICEBERG_DUPLICATE_NAME",x,"Sibling names must be unique","error");h.add(g.name),l(g.id,g.type,f&&g.required&&!m,x+"/id"),c(g,["id","name","type","required","doc","initial-default","write-default"],x);for(let v of["initial-default","write-default"])if(Object.hasOwn(g,v))r("ICEBERG_DEFAULT_UNVERIFIED",x+"/"+v,"Default retained exactly; type encoding and historical execution require separate checks");u(g.type,x+"/type",f&&g.required,m)}}else if(p.type==="list")c(p,["type","element-id","element-required","element"],d),l(p["element-id"],p.element,!1,d+"/element-id"),u(p.element,d+"/element",!1,!0);else if(p.type==="map")c(p,["type","key-id","key","value-id","value-required","value"],d),l(p["key-id"],p.key,!1,d+"/key-id"),l(p["value-id"],p.value,!1,d+"/value-id"),u(p.key,d+"/key",!1,!0),u(p.value,d+"/value",!1,!0);else r("ICEBERG_UNKNOWN_TYPE",d,"Unknown object-form type preserved without interpretation")}u(s,"",!0,!1,!0);for(let[p,d]of(s["identifier-field-ids"]??[]).entries()){let f=a.get(d);if(!f||!f.eligible||typeof f.type!=="string"||["float","double"].includes(f.type))r("ICEBERG_IDENTIFIER","/identifier-field-ids/"+p,"Identifier requires a required primitive field under required structs, outside collections","error");else if(!o.has(f.type)&&!/^decimal\(|^fixed\[/.test(f.type))r("ICEBERG_IDENTIFIER_UNVERIFIED","/identifier-field-ids/"+p,"Unknown primitive meaning cannot establish identifier eligibility")}if(s["schema-id"]===void 0)r("ICEBERG_SCHEMA_ID_CONTEXT","","Missing schema-id is retained; table format version determines whether it is required");return n}function uDe(){return new nt().register(lDe,cDe)}function uw(e){return We(e,uDe())}function J4(e){let t=uw(e);if(!t.valid)throw new U("ICEBERG_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[cw];if(!n||e.vocabularies[cw]?.version!=="0.1.0")throw new U("ICEBERG_PAYLOAD","Expected pinned Iceberg schema payload");return Ae(n)}function G4(e,t){let n={umf:"0.1.0",id:t.id,vocabularies:{[cw]:{version:"0.1.0"}},modules:[{id:"schema",namespace:"",elements:[{id:"schema",extensions:{[cw]:{profile:"iceberg-schema-json",root:Jt(e)}}}]}]};return J4(n),n}function H4(e){let t=J4(e);if(uw(e).diagnostics.some((n)=>n.code==="ICEBERG_REPRESENTATION"))throw new U("ICEBERG_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var z4={id:"umf.iceberg.table",version:"0.1.0",coreVersion:"0.1.0",description:"Exact Iceberg table metadata JSON, known field shapes and explicit context limits",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:iceberg:table:0.1.0",type:"object",properties:{profile:{const:"iceberg-table-json"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-021. Preserve exact table JSON, unknown fields and versions; schema/shape checks do not authorize data reads, commits or evolution.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Apache Iceberg table metadata JSON",version:"1.11.0 spec; PyIceberg 0.11.0",subset:"Known v1-v3 metadata field shapes, embedded schema consistency, exact integers, preservation and candidate edits; reference/feature/default/history validation remains incomplete"},evidence:["tests/iceberg/table.test.ts","fixtures/iceberg/table/oracle-results.json","fixtures/iceberg/table/browser-results.json"]}};var Vg={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:iceberg:table-json:0.1.0",type:"object",properties:{"format-version":{type:"integer",minimum:-2147483648,maximum:2147483647}},required:["format-version"],additionalProperties:!0,allOf:[{if:{properties:{"format-version":{enum:[1,2,3]}}},then:{properties:{"format-version":{type:"integer",minimum:-2147483648,maximum:2147483647},"table-uuid":{type:"string"},location:{type:"string"},"last-sequence-number":{type:"integer",format:"int64"},"last-updated-ms":{type:"integer",format:"int64"},"last-column-id":{type:"integer",minimum:-2147483648,maximum:2147483647},schema:{$ref:"#/$defs/Schema"},schemas:{type:"array",items:{$ref:"#/$defs/Schema"}},"current-schema-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"partition-spec":{type:"array",items:{$ref:"#/$defs/PartitionField"}},"partition-specs":{type:"array",items:{$ref:"#/$defs/PartitionSpec"}},"default-spec-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"last-partition-id":{type:"integer",minimum:-2147483648,maximum:2147483647},properties:{type:"object",additionalProperties:{type:"string"}},"current-snapshot-id":{anyOf:[{type:"integer",format:"int64"},{type:"null"}]},snapshots:{type:"array",items:{$ref:"#/$defs/Snapshot"}},"snapshot-log":{type:"array",items:{type:"object",properties:{"timestamp-ms":{type:"integer",format:"int64"},"snapshot-id":{type:"integer",format:"int64"}},required:["timestamp-ms","snapshot-id"],additionalProperties:!0}},"metadata-log":{type:"array",items:{type:"object",properties:{"timestamp-ms":{type:"integer",format:"int64"},"metadata-file":{type:"string"}},required:["timestamp-ms","metadata-file"],additionalProperties:!0}},"sort-orders":{type:"array",items:{$ref:"#/$defs/SortOrder"}},"default-sort-order-id":{type:"integer",minimum:-2147483648,maximum:2147483647},refs:{anyOf:[{type:"object",additionalProperties:{$ref:"#/$defs/Ref"}},{type:"null"}]},statistics:{type:"array",items:{$ref:"#/$defs/Statistics"}},"partition-statistics":{type:"array",items:{$ref:"#/$defs/PartitionStatistics"}},"next-row-id":{type:"integer",format:"int64"},"encryption-keys":{type:"array",items:{$ref:"#/$defs/EncryptionKey"}}},required:["format-version","location","last-updated-ms","last-column-id"]}},{if:{properties:{"format-version":{const:1}}},then:{required:["schema","partition-spec"]}},{if:{properties:{"format-version":{enum:[2,3]}}},then:{required:["table-uuid","last-sequence-number","schemas","current-schema-id","partition-specs","default-spec-id","last-partition-id","sort-orders","default-sort-order-id"]}},{if:{properties:{"format-version":{const:3}}},then:{required:["next-row-id"]}},{if:{properties:{"format-version":{enum:[1,2]}}},then:{properties:{"partition-spec":{type:"array",items:{type:"object",properties:{"source-id":{}},required:["source-id"]}},"partition-specs":{type:"array",items:{type:"object",properties:{fields:{type:"array",items:{type:"object",properties:{"source-id":{}},required:["source-id"]}}},required:[],additionalProperties:!0}},"sort-orders":{type:"array",items:{type:"object",properties:{fields:{type:"array",items:{type:"object",properties:{"source-id":{}},required:["source-id"]}}},required:[],additionalProperties:!0}}}}},{if:{properties:{"format-version":{enum:[2,3]}}},then:{properties:{"partition-spec":{type:"array",items:{type:"object",properties:{"field-id":{}},required:["field-id"]}},"partition-specs":{type:"array",items:{type:"object",properties:{fields:{type:"array",items:{type:"object",properties:{"field-id":{}},required:["field-id"]}}},required:[],additionalProperties:!0}}}}}],$defs:{field:{type:"object",properties:{id:{type:"integer",minimum:-2147483648,maximum:2147483647},name:{type:"string"},required:{type:"boolean"},type:{$ref:"#/$defs/type"},doc:{type:"string"},"initial-default":{},"write-default":{}},required:["id","name","required","type"],additionalProperties:!0},type:{anyOf:[{type:"string",minLength:1},{type:"object",properties:{type:{const:"struct"},fields:{type:"array",items:{$ref:"#/$defs/field"}}},required:["type","fields"],additionalProperties:!0},{type:"object",properties:{type:{const:"list"},"element-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"element-required":{type:"boolean"},element:{$ref:"#/$defs/type"}},required:["type","element-id","element-required","element"],additionalProperties:!0},{type:"object",properties:{type:{const:"map"},"key-id":{type:"integer",minimum:-2147483648,maximum:2147483647},key:{$ref:"#/$defs/type"},"value-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"value-required":{type:"boolean"},value:{$ref:"#/$defs/type"}},required:["type","key-id","key","value-id","value-required","value"],additionalProperties:!0},{type:"object",properties:{type:{type:"string",minLength:1,not:{enum:["struct","list","map"]}}},required:["type"],additionalProperties:!0}]},Schema:{type:"object",properties:{type:{const:"struct"},fields:{type:"array",items:{$ref:"#/$defs/field"}},"schema-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"identifier-field-ids":{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647},uniqueItems:!0}},required:["type","fields"],additionalProperties:!0},PartitionField:{type:"object",properties:{"source-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"source-ids":{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647},minItems:1},"field-id":{type:"integer",minimum:-2147483648,maximum:2147483647},name:{type:"string"},transform:{type:"string"}},required:["name","transform"],additionalProperties:!0,oneOf:[{properties:{"source-id":{},"source-ids":{}},required:["source-id"],not:{properties:{"source-ids":{}},required:["source-ids"]}},{properties:{"source-id":{},"source-ids":{}},required:["source-ids"],not:{properties:{"source-id":{}},required:["source-id"]}}]},PartitionSpec:{type:"object",properties:{"spec-id":{type:"integer",minimum:-2147483648,maximum:2147483647},fields:{type:"array",items:{$ref:"#/$defs/PartitionField"}}},required:["spec-id","fields"],additionalProperties:!0},SortField:{type:"object",properties:{"source-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"source-ids":{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647},minItems:1},transform:{type:"string"},direction:{type:"string"},"null-order":{type:"string"}},required:["transform","direction","null-order"],additionalProperties:!0,oneOf:[{properties:{"source-id":{},"source-ids":{}},required:["source-id"],not:{properties:{"source-ids":{}},required:["source-ids"]}},{properties:{"source-id":{},"source-ids":{}},required:["source-ids"],not:{properties:{"source-id":{}},required:["source-id"]}}]},SortOrder:{type:"object",properties:{"order-id":{type:"integer",minimum:-2147483648,maximum:2147483647},fields:{type:"array",items:{$ref:"#/$defs/SortField"}}},required:["order-id","fields"],additionalProperties:!0},Snapshot:{type:"object",properties:{"snapshot-id":{type:"integer",format:"int64"},"parent-snapshot-id":{type:"integer",format:"int64"},"sequence-number":{type:"integer",format:"int64"},"timestamp-ms":{type:"integer",format:"int64"},"manifest-list":{type:"string"},manifests:{type:"array",items:{type:"string"}},summary:{type:"object",additionalProperties:{type:"string"}},"schema-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"first-row-id":{type:"integer",format:"int64"},"added-rows":{type:"integer",format:"int64"}},required:["snapshot-id","timestamp-ms"],additionalProperties:!0},Ref:{type:"object",properties:{"snapshot-id":{type:"integer",format:"int64"},type:{type:"string"},"min-snapshots-to-keep":{type:"integer",minimum:-2147483648,maximum:2147483647},"max-snapshot-age-ms":{type:"integer",format:"int64"},"max-ref-age-ms":{type:"integer",format:"int64"}},required:["snapshot-id","type"],additionalProperties:!0},Blob:{type:"object",properties:{type:{type:"string"},"snapshot-id":{type:"integer",format:"int64"},"sequence-number":{type:"integer",format:"int64"},fields:{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647}},properties:{type:"object",additionalProperties:{type:"string"}}},required:["type","snapshot-id","sequence-number","fields"],additionalProperties:!0},Statistics:{type:"object",properties:{"snapshot-id":{type:"integer",format:"int64"},"statistics-path":{type:"string"},"file-size-in-bytes":{type:"integer",format:"int64"},"file-footer-size-in-bytes":{type:"integer",format:"int64"},"key-metadata":{type:"string"},"blob-metadata":{type:"array",items:{$ref:"#/$defs/Blob"}}},required:["snapshot-id","statistics-path","file-size-in-bytes","file-footer-size-in-bytes","blob-metadata"],additionalProperties:!0},PartitionStatistics:{type:"object",properties:{"snapshot-id":{type:"integer",format:"int64"},"statistics-path":{type:"string"},"file-size-in-bytes":{type:"integer",format:"int64"}},required:["snapshot-id","statistics-path","file-size-in-bytes"],additionalProperties:!0},EncryptionKey:{type:"object",properties:{"key-id":{type:"string"},"key-metadata":{type:"string"}},required:["key-id","key-metadata"],additionalProperties:!0}}};var W4="umf.iceberg.table",fDe=z4,jO;function mDe(e){let t=e,n=[{code:"ICEBERG_TABLE_CONTEXT",path:"",severity:"warning",message:"Metadata shapes do not validate physical files, schema evolution, transforms, reference histories, defaults, encryption or safe commits"}],r=(c,u,p,d="warning")=>n.push({code:c,path:u,message:p,severity:d});if(Object.keys(t).some((c)=>!["profile","root"].includes(c)))r("ICEBERG_TABLE_REPRESENTATION","","Unknown representation fields must remain in UMF");function i(c,u){let p=c.kind==="null"?["kind"]:c.kind==="array"?["kind","items"]:c.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(c).some((d)=>!p.includes(d)))r("ICEBERG_TABLE_REPRESENTATION",u,"Unknown tagged-tree fields must remain in UMF");if(c.kind==="object")for(let[d,f]of Object.entries(c.members))i(f,u+"/"+Pe(d));if(c.kind==="array")c.items.forEach((d,f)=>i(d,u+"/"+f))}i(t.root,""),jO??=mt().compile(Vg);let s=JSON.parse(Be(t.root));if(!jO(s)){for(let c of jO.errors??[])r("ICEBERG_TABLE_STRUCTURE",c.instancePath,c.message??"Invalid table shape","error");return n}let o=[1,2,3].includes(s["format-version"]);if(!o)r("ICEBERG_TABLE_VERSION","/format-version","Unknown table version preserved without native interpretation");let a=o?Vg.allOf[0].then:{properties:Vg.properties};function l(c,u,p){if(u.$ref){let d=u.$ref.split("/").at(-1);return l(c,Vg.$defs[d],p)}if(u.anyOf){if(c.kind==="null")return;let d=c.kind==="object"&&c.members.type?.kind==="string"?c.members.type.value:void 0,f=(d?u.anyOf.find((m)=>m.properties?.type?.const===d):void 0)??u.anyOf.find((m)=>m.type===c.kind&&!m.properties?.type?.const||c.kind==="number"&&m.type==="integer")??u.anyOf.find((m)=>m.type==="object"&&!m.properties?.type?.const);if(f)return l(c,f,p);return}if(u.type==="integer"&&c.kind==="number"){if(!/^-?\d+$/.test(c.value)||c.value.replace("-","").length>19){r("ICEBERG_TABLE_INTEGER",p,"Expected bounded exact integer token","error");return}let d=BigInt(c.value),f=u.format==="int64"?-9223372036854775808n:BigInt(u.minimum??-2147483648),m=u.format==="int64"?9223372036854775807n:BigInt(u.maximum??2147483647);if(dm)r("ICEBERG_TABLE_INTEGER",p,"Integer exceeds signed width","error")}if(c.kind==="object")for(let[d,f]of Object.entries(c.members)){let m=u.properties&&Object.hasOwn(u.properties,d)?u.properties[d]:typeof u.additionalProperties==="object"?u.additionalProperties:void 0;if(m)l(f,m,p+"/"+Pe(d));else if(u.properties)r("ICEBERG_TABLE_UNKNOWN",p+"/"+Pe(d),"Unknown native property preserved")}if(c.kind==="array"&&u.items)c.items.forEach((d,f)=>l(d,u.items,p+"/"+f))}if(l(t.root,a,""),o&&t.root.kind==="object"){let c=t.root.members.schemas,u=t.root.members.schema,p=[...u?[{node:u,path:"/schema"}]:[],...c?.kind==="array"?c.items.map((d,f)=>({node:d,path:"/schemas/"+f})):[]];for(let d of p)try{let f=G4(Be(d.node),{id:"embedded"});for(let m of uw(f).diagnostics)n.push({...m,path:d.path+m.path})}catch(f){r("ICEBERG_TABLE_SCHEMA",d.path,f.message,"error")}}return n}function yDe(){return new nt().register(fDe,mDe)}function Q4(e){return We(e,yDe())}function hDe(e){let t=Q4(e);if(!t.valid)throw new U("ICEBERG_TABLE_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="table")?.elements.find((r)=>r.id==="table")?.extensions[W4];if(!n||e.vocabularies[W4]?.version!=="0.1.0")throw new U("ICEBERG_TABLE_PAYLOAD","Expected pinned Iceberg schema payload");return Ae(n)}function Y4(e){let t=hDe(e);if(Q4(e).diagnostics.some((n)=>n.code==="ICEBERG_TABLE_REPRESENTATION"))throw new U("ICEBERG_TABLE_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var X4={id:"umf.dbt.semantic",version:"0.1.0",coreVersion:"0.1.0",description:"Exact dbt semantic manifest with DSI-version-scoped serialized shape checks",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:dbt:semantic:0.1.0",type:"object",properties:{profile:{const:"dbt-semantic-json"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-022 AC10–AC11; retain source independently of derived shape diagnostics; semantic validation and execution remain external",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"dbt semantic manifest",version:"dbt-semantic-interfaces 0.8.5, dbt Core 1.10.0",subset:"Exact JSON preservation, copied candidate edits and derived nullable serialized shapes; no metric execution or semantic-validator equivalence"},evidence:["tests/dbt/semantic.test.ts","fixtures/dbt/semantic/oracle-results.json","fixtures/dbt/semantic/browser-results.json","tests/dbt/semantic-metrics.test.ts","fixtures/dbt/semantic-metrics/oracle-results.json","fixtures/dbt/semantic-metrics/browser-results.json"]}};var Z4={title:"PydanticSemanticManifest",description:"Model holds all the information the SemanticLayer needs to render a query.",type:"object",properties:{semantic_models:{title:"Semantic Models",type:"array",items:{$ref:"#/definitions/PydanticSemanticModel"}},metrics:{title:"Metrics",type:"array",items:{$ref:"#/definitions/PydanticMetric"}},project_configuration:{$ref:"#/definitions/PydanticProjectConfiguration"},saved_queries:{title:"Saved Queries",type:"array",items:{$ref:"#/definitions/PydanticSavedQuery"}}},required:["semantic_models","metrics","project_configuration"],definitions:{PydanticSemanticModelDefaults:{title:"PydanticSemanticModelDefaults",description:"Extends BaseModel with a generic hash function.",type:"object",properties:{agg_time_dimension:{anyOf:[{title:"Agg Time Dimension",type:"string"},{type:"null"}]}}},PydanticNodeRelation:{title:"PydanticNodeRelation",description:"Path object to where the data should be.",type:"object",properties:{alias:{title:"Alias",type:"string"},schema_name:{title:"Schema Name",type:"string"},database:{anyOf:[{title:"Database",type:"string"},{type:"null"}]},relation_name:{title:"Relation Name",default:"",type:"string"}},required:["alias","schema_name"]},EntityType:{title:"EntityType",description:"Defines uniqueness and the extent to which an entity represents the common entity for a semantic model.",enum:["foreign","natural","primary","unique"]},PydanticFileSlice:{title:"PydanticFileSlice",description:"Extends BaseModel with a generic hash function.",type:"object",properties:{filename:{title:"Filename",type:"string"},content:{title:"Content",type:"string"},start_line_number:{title:"Start Line Number",type:"integer"},end_line_number:{title:"End Line Number",type:"integer"}},required:["filename","content","start_line_number","end_line_number"]},PydanticMetadata:{title:"PydanticMetadata",description:"Extends BaseModel with a generic hash function.",type:"object",properties:{repo_file_path:{title:"Repo File Path",type:"string"},file_slice:{$ref:"#/definitions/PydanticFileSlice"}},required:["repo_file_path","file_slice"]},PydanticSemanticLayerElementConfig:{title:"PydanticSemanticLayerElementConfig",description:"PydanticDimension config.",type:"object",properties:{meta:{title:"Meta",type:"object"}}},PydanticEntity:{title:"PydanticEntity",description:"Describes a entity.",type:"object",properties:{name:{title:"Name",type:"string"},description:{anyOf:[{title:"Description",type:"string"},{type:"null"}]},type:{$ref:"#/definitions/EntityType"},role:{anyOf:[{title:"Role",type:"string"},{type:"null"}]},expr:{anyOf:[{title:"Expr",type:"string"},{type:"null"}]},metadata:{anyOf:[{$ref:"#/definitions/PydanticMetadata"},{type:"null"}]},label:{anyOf:[{title:"Label",type:"string"},{type:"null"}]},config:{anyOf:[{$ref:"#/definitions/PydanticSemanticLayerElementConfig"},{type:"null"}]}},required:["name","type"]},AggregationType:{title:"AggregationType",description:"Aggregation methods for measures.",enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},PydanticMeasureAggregationParameters:{title:"PydanticMeasureAggregationParameters",description:"Describes parameters for aggregations.",type:"object",properties:{percentile:{anyOf:[{title:"Percentile",type:"number"},{type:"null"}]},use_discrete_percentile:{title:"Use Discrete Percentile",default:!1,type:"boolean"},use_approximate_percentile:{title:"Use Approximate Percentile",default:!1,type:"boolean"}}},PydanticNonAdditiveDimensionParameters:{title:"PydanticNonAdditiveDimensionParameters",description:`Describes the params for specifying non-additive dimensions in a measure. +`,type:"object",additionalProperties:{$ref:"#/$defs/media-type-or-reference"},propertyNames:{format:"media-range"}},"media-type":{$comment:"https://spec.openapis.org/oas/v3.2#media-type-object",type:"object",properties:{description:{type:"string"},schema:{$dynamicRef:"#meta"},itemSchema:{$dynamicRef:"#meta"},encoding:{type:"object",additionalProperties:{$ref:"#/$defs/encoding"}},prefixEncoding:{type:"array",items:{$ref:"#/$defs/encoding"}},itemEncoding:{$ref:"#/$defs/encoding"}},dependentSchemas:{encoding:{properties:{prefixEncoding:!1,itemEncoding:!1}}},allOf:[{$ref:"#/$defs/examples"},{$ref:"#/$defs/specification-extensions"}],unevaluatedProperties:!1},"media-type-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/media-type"}},encoding:{$comment:"https://spec.openapis.org/oas/v3.2#encoding-object",type:"object",properties:{contentType:{$comment:"one or more comma-separated media-ranges",type:"string"},headers:{type:"object",propertyNames:{$ref:"#/$defs/token"},additionalProperties:{$ref:"#/$defs/header-or-reference"}},style:{enum:["form","spaceDelimited","pipeDelimited","deepObject"]},explode:{type:"boolean"},allowReserved:{type:"boolean"},encoding:{type:"object",additionalProperties:{$ref:"#/$defs/encoding"}},prefixEncoding:{type:"array",items:{$ref:"#/$defs/encoding"}},itemEncoding:{$ref:"#/$defs/encoding"}},dependentSchemas:{encoding:{properties:{prefixEncoding:!1,itemEncoding:!1}},style:{properties:{allowReserved:{default:!1}},$ref:"#/$defs/explode-for-form"},explode:{properties:{style:{default:"form"},allowReserved:{default:!1}}},allowReserved:{properties:{style:{default:"form"}},$ref:"#/$defs/explode-for-form"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},responses:{$comment:"https://spec.openapis.org/oas/v3.2#responses-object",type:"object",properties:{default:{$ref:"#/$defs/response-or-reference"}},patternProperties:{"^[1-5](?:[0-9]{2}|XX)$":{$ref:"#/$defs/response-or-reference"}},minProperties:1,$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1,if:{$comment:"either default, or at least one response code property must exist",patternProperties:{"^[1-5](?:[0-9]{2}|XX)$":!1}},then:{required:["default"]}},response:{$comment:"https://spec.openapis.org/oas/v3.2#response-object",type:"object",properties:{summary:{type:"string"},description:{type:"string"},headers:{type:"object",propertyNames:{$ref:"#/$defs/token"},additionalProperties:{$ref:"#/$defs/header-or-reference"}},content:{$ref:"#/$defs/content"},links:{type:"object",additionalProperties:{$ref:"#/$defs/link-or-reference"}}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"response-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/response"}},callbacks:{$comment:"https://spec.openapis.org/oas/v3.2#callback-object",type:"object",$ref:"#/$defs/specification-extensions",additionalProperties:{$ref:"#/$defs/path-item"}},"callbacks-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/callbacks"}},example:{$comment:"https://spec.openapis.org/oas/v3.2#example-object",type:"object",properties:{summary:{type:"string"},description:{type:"string"},dataValue:!0,serializedValue:{type:"string"},value:!0,externalValue:{type:"string",format:"uri-reference"}},allOf:[{not:{required:["value","externalValue"]}},{not:{required:["value","dataValue"]}},{not:{required:["value","serializedValue"]}},{not:{required:["serializedValue","externalValue"]}}],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"example-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/example"}},link:{$comment:"https://spec.openapis.org/oas/v3.2#link-object",type:"object",properties:{operationRef:{type:"string",format:"uri-reference"},operationId:{type:"string"},parameters:{$ref:"#/$defs/map-of-strings"},requestBody:!0,description:{type:"string"},server:{$ref:"#/$defs/server"}},oneOf:[{required:["operationRef"]},{required:["operationId"]}],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"link-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/link"}},header:{$comment:"https://spec.openapis.org/oas/v3.2#header-object",type:"object",properties:{description:{type:"string"},required:{default:!1,type:"boolean"},deprecated:{default:!1,type:"boolean"},schema:{$dynamicRef:"#meta"},content:{$ref:"#/$defs/content",minProperties:1,maxProperties:1}},oneOf:[{required:["schema"]},{required:["content"]}],dependentSchemas:{schema:{properties:{style:{default:"simple",const:"simple"},explode:{default:!1,type:"boolean"}}}},allOf:[{$ref:"#/$defs/examples"},{$ref:"#/$defs/specification-extensions"}],unevaluatedProperties:!1},"header-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/header"}},tag:{$comment:"https://spec.openapis.org/oas/v3.2#tag-object",type:"object",properties:{name:{type:"string"},summary:{type:"string"},description:{type:"string"},externalDocs:{$ref:"#/$defs/external-documentation"},parent:{type:"string"},kind:{type:"string"}},required:["name"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},reference:{$comment:"https://spec.openapis.org/oas/v3.2#reference-object",type:"object",properties:{$ref:{type:"string",format:"uri-reference"},summary:{type:"string"},description:{type:"string"}}},schema:{$comment:"https://spec.openapis.org/oas/v3.2#schema-object",$dynamicAnchor:"meta",type:["object","boolean"]},"security-scheme":{$comment:"https://spec.openapis.org/oas/v3.2#security-scheme-object",type:"object",properties:{type:{enum:["apiKey","http","mutualTLS","oauth2","openIdConnect"]},description:{type:"string"},deprecated:{default:!1,type:"boolean"}},required:["type"],allOf:[{$ref:"#/$defs/specification-extensions"},{$ref:"#/$defs/security-scheme/$defs/type-apikey"},{$ref:"#/$defs/security-scheme/$defs/type-http"},{$ref:"#/$defs/security-scheme/$defs/type-http-bearer"},{$ref:"#/$defs/security-scheme/$defs/type-oauth2"},{$ref:"#/$defs/security-scheme/$defs/type-oidc"}],unevaluatedProperties:!1,$defs:{"type-apikey":{if:{properties:{type:{const:"apiKey"}}},then:{properties:{name:{type:"string"},in:{enum:["query","header","cookie"]}},required:["name","in"]}},"type-http":{if:{properties:{type:{const:"http"}}},then:{properties:{scheme:{type:"string"}},required:["scheme"]}},"type-http-bearer":{if:{properties:{type:{const:"http"},scheme:{type:"string",pattern:"^[Bb][Ee][Aa][Rr][Ee][Rr]$"}},required:["type","scheme"]},then:{properties:{bearerFormat:{type:"string"}}}},"type-oauth2":{if:{properties:{type:{const:"oauth2"}}},then:{properties:{flows:{$ref:"#/$defs/oauth-flows"},oauth2MetadataUrl:{type:"string",format:"uri-reference"}},required:["flows"]}},"type-oidc":{if:{properties:{type:{const:"openIdConnect"}}},then:{properties:{openIdConnectUrl:{type:"string",format:"uri-reference"}},required:["openIdConnectUrl"]}}}},"security-scheme-or-reference":{if:{type:"object",required:["$ref"]},then:{$ref:"#/$defs/reference"},else:{$ref:"#/$defs/security-scheme"}},"oauth-flows":{type:"object",properties:{implicit:{$ref:"#/$defs/oauth-flows/$defs/implicit"},password:{$ref:"#/$defs/oauth-flows/$defs/password"},clientCredentials:{$ref:"#/$defs/oauth-flows/$defs/client-credentials"},authorizationCode:{$ref:"#/$defs/oauth-flows/$defs/authorization-code"},deviceAuthorization:{$ref:"#/$defs/oauth-flows/$defs/device-authorization"}},$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1,$defs:{implicit:{type:"object",properties:{authorizationUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["authorizationUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},password:{type:"object",properties:{tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["tokenUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"client-credentials":{type:"object",properties:{tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["tokenUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"authorization-code":{type:"object",properties:{authorizationUrl:{type:"string",format:"uri-reference"},tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["authorizationUrl","tokenUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1},"device-authorization":{type:"object",properties:{deviceAuthorizationUrl:{type:"string",format:"uri-reference"},tokenUrl:{type:"string",format:"uri-reference"},refreshUrl:{type:"string",format:"uri-reference"},scopes:{$ref:"#/$defs/map-of-strings"}},required:["deviceAuthorizationUrl","tokenUrl","scopes"],$ref:"#/$defs/specification-extensions",unevaluatedProperties:!1}}},"security-requirement":{$comment:"https://spec.openapis.org/oas/v3.2#security-requirement-object",type:"object",additionalProperties:{type:"array",items:{type:"string"}}},"specification-extensions":{$comment:"https://spec.openapis.org/oas/v3.2#specification-extensions",patternProperties:{"^x-":!0}},examples:{properties:{example:!0,examples:{type:"object",additionalProperties:{$ref:"#/$defs/example-or-reference"}}},not:{required:["example","examples"]}},"map-of-strings":{type:"object",additionalProperties:{type:"string"}},"explode-for-form":{$comment:"for encoding objects, and query and cookie parameters, style=form is the default",if:{properties:{style:{const:"form"}}},then:{properties:{explode:{default:!0}}},else:{properties:{explode:{default:!1}}}},token:{$comment:"see https://www.rfc-editor.org/rfc/rfc9110.html#section-5.6.2",type:"string",pattern:"^[0-9A-Za-z!#$%&'*+.^_`|~-]+$"}}};var x4="umf.openapi",Uwe=OO,Bwe=mt().compile(OO.schema);function w4(e){let t=new T4.default({allErrors:!0,strict:!1,ownProperties:!0,validateFormats:!1});return zp(t),t.compile(e)}var Vwe={"2.0":w4(b4),"3.0":w4(g4),"3.1":mt(!1).compile(Bg(v4)),"3.2":mt(!1).compile(Bg(_4))},ow=(e,t)=>t==="json"?Jt(e):Wa(e);function Kwe(e){let t=e,n=[],r=(u,p,d)=>n.push({code:u,path:p,message:d,severity:"warning"});for(let u of Object.keys(t))if(!["profile","root","originalSource","originalFormat","baseUri","resources"].includes(u))r("OPENAPI_REPRESENTATION","/"+$e(u),"Unknown representation field cannot be emitted natively");function i(u,p){let d=u.kind==="object"?["kind","members"]:u.kind==="array"?["kind","items"]:u.kind==="null"?["kind"]:["kind","value"];for(let f of Object.keys(u))if(!d.includes(f))r("OPENAPI_REPRESENTATION",p+"/"+$e(f),"Unknown tree encoding field cannot be emitted natively");if(u.kind==="object")for(let[f,m]of Object.entries(u.members))i(m,p+"/members/"+$e(f));if(u.kind==="array")u.items.forEach((f,m)=>i(f,p+"/items/"+m))}i(t.root,"/root");let s=new Set;try{if(t.baseUri)s.add(D4(t.baseUri))}catch(u){n.push({code:"OPENAPI_RESOURCE_URI",path:"/baseUri",severity:"error",message:String(u)})}for(let[u,p]of(t.resources??[]).entries()){let d="/resources/"+u;for(let f of Object.keys(p))if(!["uri","root","originalSource","originalFormat"].includes(f))r("OPENAPI_REPRESENTATION",d+"/"+$e(f),"Unknown resource field cannot be emitted natively");i(p.root,d+"/root");try{let f=D4(p.uri);if(s.has(f))throw Error("Duplicate document URI");s.add(f),ow(p.originalSource,p.originalFormat)}catch(f){n.push({code:"OPENAPI_RESOURCE",path:d,severity:"error",message:String(f)})}}if(t.resources?.length)r("OPENAPI_RESOURCE_CONTEXT","/resources","Explicit resources are retained; URI/pointer lookup does not validate their contextual types, nested schema IDs, anchors, dynamic scope or reference closure");try{ow(t.originalSource,t.originalFormat)}catch(u){n.push({code:"OPENAPI_ARCHIVE",path:"/originalSource",severity:"error",message:String(u)})}if(t.root.kind!=="object")return n.push({code:"OPENAPI_ROOT",path:"/root",severity:"error",message:"OpenAPI description must be an object"}),n;let o=t.root.members.openapi??t.root.members.swagger;if(o?.kind!=="string")return n.push({code:"OPENAPI_VERSION",path:"/root",severity:"error",message:"Native openapi or swagger version must be a string"}),n;let a=o.value.slice(0,3),l=Vwe[a];if(!l)return r("OPENAPI_VERSION_UNSUPPORTED","/root","Native version retained without interpretation: "+o.value),n;let c;try{c=ys(Be(t.root),"json")}catch(u){return r("OPENAPI_NUMERIC","/root","Exact numeric tokens retained; host interpretation unavailable: "+String(u)),n}if(!l(c))for(let u of l.errors??[])n.push({code:"OPENAPI_OBJECT_SCHEMA",path:"/root"+u.instancePath,severity:"error",message:u.message??"Invalid OpenAPI object"});return n.push(...t4(c)),r("OPENAPI_VALIDATION_LIMIT","/root","Pinned official-schema checks do not prove reference resolution, URI formats, security execution, parameter serialization or all normative prose rules; known 3.1/3.2 embedded dialect keyword syntax is checked, while instances, unknown dialects and referenced resource contexts remain incomplete; legacy schemas check their declared Schema Object subset; extension content remains source-owned"),n}function Jwe(){return new nt().register(Uwe,Kwe)}function $O(e){return We(e,Jwe())}function S4(e){let t=$O(e);if(!t.valid)throw new U("OPENAPI_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[x4];if(e.vocabularies[x4]?.version!=="0.1.0"||!Bwe(n))throw new U("OPENAPI_PAYLOAD","Missing or invalid OpenAPI payload");return Ae(n)}function D4(e){try{let t=new URL(e);if(t.hash||e.includes("#"))throw Error("Document URI cannot contain a fragment");return t.href}catch(t){throw new U("OPENAPI_RESOURCE_URI",String(t))}}function PO(e,t){if(t!==void 0&&!["json","yaml"].includes(t))throw new U("OPENAPI_FORMAT","Unsupported native format");if((t??e.originalFormat)===e.originalFormat&&Be(ow(e.originalSource,e.originalFormat))===Be(e.root))return e.originalSource;let r=Be(e.root)+` +`;if(r.length>Zt.maxTextLength)throw new U("LIMIT","Native OpenAPI output exceeds text limit");return r}function E4(e){if($O(e).diagnostics.some((t)=>t.code==="OPENAPI_REPRESENTATION"))throw new U("OPENAPI_REPRESENTATION","Native export would discard encoding content")}function k4(e,t){let n=S4(e);if(E4(e),n.resources?.length)throw new U("OPENAPI_BUNDLE_REQUIRED","Export the full bundle to retain referenced resources");return PO(n,t)}function N4(e){let t=S4(e),n=[t,...t.resources??[]].some((r)=>Be(ow(r.originalSource,r.originalFormat))!==Be(r.root));return E4(e),{schema:PO(t),format:t.originalFormat,...t.baseUri?{baseUri:t.baseUri}:{},resources:(t.resources??[]).map((r)=>({uri:r.uri,text:PO(r),format:r.originalFormat})),source:Ae(e),diagnostics:[...$O(e).diagnostics,...n?[{code:"OPENAPI_SOURCE_LAYOUT",path:"",severity:"warning",message:"Edited native output uses JSON syntax; original layout and comments remain in source archive"}]:[],{code:"SOURCE_ARTIFACT_REQUIRED",path:"",severity:"warning",message:"Retain source UMF for unrelated metadata and archived native layout"}]}}function O4(e){let t=[],n=(v,D,T)=>t.push({code:v,path:D,message:T,severity:"warning"});if(e.kind!=="object")return t;let r=e.members.metaData,i=e.members.protocol;if(r?.kind!=="object"||i?.kind!=="object")return t;let s=r.members.configuration;if(s?.kind!=="object")return t;let o=s.members["delta.columnMapping.mode"];if(!o||o.kind==="string"&&o.value==="none")return t;let a="/metaData/configuration/";if(o.kind!=="string"||!["id","name"].includes(o.value))return n("DELTA_MAPPING_MODE",a+"delta.columnMapping.mode","Unknown mapping mode remains uninterpreted"),t;let l=(v)=>v?.kind==="number"?v.value:void 0,c=(v,D)=>{let T=i.members[v];return T?.kind==="array"&&T.items.some((N)=>N.kind==="string"&&N.value===D)},u=l(i.members.minReaderVersion),p=l(i.members.minWriterVersion);if(!(u==="2"||u==="3"&&c("readerFeatures","columnMapping")))n("DELTA_MAPPING_READER_PROTOCOL","/protocol","Mapping requires reader 2 or reader 3 with columnMapping");if(!(["5","6"].includes(p??"")||p==="7"&&c("writerFeatures","columnMapping")))n("DELTA_MAPPING_WRITER_PROTOCOL","/protocol","Mapping requires writer 5/6 or writer 7 with columnMapping");n("DELTA_MAPPING_HISTORY_UNVERIFIED","/metaData/schemaString","Historical physical-path uniqueness, monotonic maxColumnId and actual Parquet field IDs are not verified");let d=s.members["delta.columnMapping.maxColumnId"],f,m=d?.kind==="string"?d.value.replace(/^(-?)0+(?=\d)/,"$1"):void 0;if(m!==void 0&&/^-?\d+$/.test(m)&&m.replace(/^-/,"").length<=10){if(f=BigInt(m),f<-2147483648n||f>2147483647n)f=void 0}if(f===void 0)n("DELTA_MAPPING_MAX_ID",a+"delta.columnMapping.maxColumnId","Expected a string containing a signed int32 maximum column ID");let y=r.members.schemaString;if(y?.kind!=="string")return t;let h;try{h=Jt(y.value)}catch{return t}let b=new Set,g=new Set;function x(v,D,T){if(v.kind!=="object"||v.members.type?.kind!=="string")return;if(v.members.type.value==="struct"&&v.members.fields?.kind==="array")v.members.fields.items.forEach((N,O)=>{if(N.kind!=="object")return;let C=D+"/fields/"+O,X=N.members.metadata,te=X?.kind==="object"?X.members:{},L=te["delta.columnMapping.id"],Y=te["delta.columnMapping.physicalName"];if(L?.kind!=="number"||!/^-?\d+$/.test(L.value)||L.value.replace(/^-/,"").length>10||BigInt(L.value)<-2147483648n||BigInt(L.value)>2147483647n)n("DELTA_MAPPING_ID",C+"/metadata/delta.columnMapping.id","Every mapped field requires an exact signed int32 column ID");else{let I=BigInt(L.value),Z=I.toString();if(b.has(Z))n("DELTA_MAPPING_DUPLICATE_ID",C+"/metadata/delta.columnMapping.id","Column ID is reused in the current schema");if(b.add(Z),f!==void 0&&I>f)n("DELTA_MAPPING_MAX_ID_BELOW_FIELD",a+"delta.columnMapping.maxColumnId","Declared maximum is below an assigned field ID")}let me;if(Y?.kind!=="string"||!Y.value)n("DELTA_MAPPING_PHYSICAL_NAME",C+"/metadata/delta.columnMapping.physicalName","Every mapped field requires a nonempty physical name");else if(T){me=[...T,Y.value];let I=JSON.stringify(me);if(g.has(I))n("DELTA_MAPPING_DUPLICATE_PATH",C+"/metadata/delta.columnMapping.physicalName","Physical field path is reused in the current schema");g.add(I)}if(N.members.type)x(N.members.type,C+"/type",me)});if(v.members.type.value==="array"&&v.members.elementType)x(v.members.elementType,D+"/elementType",T&&[...T,"element"]);if(v.members.type.value==="map"){if(v.members.keyType)x(v.members.keyType,D+"/keyType",T&&[...T,"key"]);if(v.members.valueType)x(v.members.valueType,D+"/valueType",T&&[...T,"value"])}}return x(h,"/metaData/schemaString",[]),t}var P4={id:"umf.delta.table",version:"0.1.0",coreVersion:"0.1.0",description:"Exact Delta metadata/protocol pair with embedded schema string and preserved future features",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:delta-table:0.1.0",type:"object",properties:{profile:{const:"delta-table-context"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-018 table context. An explicitly supplied metadata/protocol pair is not a reconciled transaction-log snapshot or a write authorization.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Delta transaction-log metadata and protocol context",version:"Protocol 3b1b99cd077ec9c84c8a94c250dea3730cc33392; deltalake 1.6.4 examples",subset:"Exact context preservation, known shape checks, incomplete feature diagnostics and guarded mapped rename candidates. No log reconciliation, transaction commit or general table evolution claim."},evidence:["tests/delta/upstream.test.ts","fixtures/delta/upstream/oracle-results.json","fixtures/delta/upstream/browser-results.json","tests/delta/table.test.ts","fixtures/delta/tables/results.json","fixtures/delta/table-results.json","fixtures/delta/table-browser-results.json","tests/delta/column-mapping.test.ts","tests/delta/rename.test.ts","fixtures/delta/mapping/oracle-results.json","fixtures/delta/mapped-data/rename-oracle-results.json","tests/delta/mapped-nested.test.ts","fixtures/delta/mapped-nested/oracle-results.json"]}};var $4={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:delta:table-context:0.1.0",type:"object",properties:{protocol:{type:"object",properties:{minReaderVersion:{type:"integer",minimum:1},minWriterVersion:{type:"integer",minimum:1},readerFeatures:{type:"array",items:{type:"string"}},writerFeatures:{type:"array",items:{type:"string"}}},required:["minReaderVersion","minWriterVersion"],additionalProperties:!0},metaData:{type:"object",properties:{id:{type:"string"},name:{type:["string","null"]},description:{type:["string","null"]},format:{type:"object",properties:{provider:{type:"string"},options:{type:"object",additionalProperties:{type:["string","null"]}}},required:["provider"],additionalProperties:!0},schemaString:{type:"string"},partitionColumns:{type:"array",items:{type:"string"}},configuration:{type:"object",additionalProperties:{type:["string","null"]}},createdTime:{type:["integer","null"]}},required:["id","format","schemaString","partitionColumns","configuration"],additionalProperties:!0}},required:["protocol","metaData"],additionalProperties:!0};var I4={id:"umf.delta",version:"0.1.0",coreVersion:"0.1.0",description:"Exact Delta schema JSON with explicit table/protocol interpretation limits",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:delta:0.1.0",type:"object",properties:{profile:{const:"delta-schema-json"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-018. Source tokens and unknown content are authoritative; no table feature support, SQL evaluation or native normalization is implied.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Delta schema JSON",version:"Protocol commit 3b1b99cd077ec9c84c8a94c250dea3730cc33392; deltalake 1.6.4 oracle",subset:"Recursive schema preservation, structural validation, copied pointer access and candidate edits. Table/protocol profile and execution support remain separate."},evidence:["tests/delta/upstream.test.ts","fixtures/delta/upstream/oracle-results.json","fixtures/delta/upstream/browser-results.json","tests/delta/schema.test.ts","fixtures/delta/capability-results.json","fixtures/delta/umf-oracle-results.json","fixtures/delta/browser-results.json"]}};var A4={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:delta:schema-json:0.1.0",type:"object",properties:{type:{const:"struct"},fields:{type:"array",items:{$ref:"#/$defs/field"}}},required:["type","fields"],additionalProperties:!0,$defs:{type:{anyOf:[{type:"string",minLength:1},{type:"object",properties:{type:{const:"struct"},fields:{type:"array",items:{$ref:"#/$defs/field"}}},required:["type","fields"],additionalProperties:!0},{type:"object",properties:{type:{const:"array"},elementType:{$ref:"#/$defs/type"},containsNull:{type:"boolean"}},required:["type","elementType","containsNull"],additionalProperties:!0},{type:"object",properties:{type:{const:"map"},keyType:{$ref:"#/$defs/type"},valueType:{$ref:"#/$defs/type"},valueContainsNull:{type:"boolean"}},required:["type","keyType","valueType"],additionalProperties:!0},{type:"object",properties:{type:{type:"string",minLength:1,not:{enum:["array","map","struct"]}}},required:["type"],additionalProperties:!0}]},field:{type:"object",properties:{name:{type:"string"},type:{$ref:"#/$defs/type"},nullable:{type:"boolean"},metadata:{type:"object"}},required:["name","type","nullable","metadata"],additionalProperties:!0}}};var aw="umf.delta",Qwe=I4,IO,Ywe=new Set(["string","long","integer","short","byte","float","double","boolean","binary","date","timestamp","timestamp_ntz","void","variant"]);function Xwe(e){let t=e,n=[{code:"DELTA_CONTEXT_UNVERIFIED",path:"",severity:"warning",message:"Schema alone cannot establish Delta protocol/features, table configuration or read/write validity"}],r=(l,c,u,p="warning")=>n.push({code:l,path:c,message:u,severity:p});if(Object.keys(t).some((l)=>!["profile","root"].includes(l)))r("DELTA_REPRESENTATION","","Unknown representation fields must remain in UMF");function i(l,c){let u=l.kind==="null"?["kind"]:l.kind==="array"?["kind","items"]:l.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(l).some((p)=>!u.includes(p)))r("DELTA_REPRESENTATION",c,"Unknown tagged-tree fields must remain in UMF");if(l.kind==="object")for(let[p,d]of Object.entries(l.members))i(d,c+"/"+$e(p));if(l.kind==="array")l.items.forEach((p,d)=>i(p,c+"/"+d))}i(t.root,"/root");let s=JSON.parse(Be(t.root));if(IO??=mt().compile(A4),!IO(s)){for(let l of IO.errors??[])r("DELTA_STRUCTURE",l.instancePath,l.message??"Invalid Delta schema shape","error");return n}let o=(l,c,u)=>{for(let p of Object.keys(l))if(!c.includes(p))r("DELTA_UNKNOWN",u+"/"+$e(p),"Unknown native property preserved; native normalization may discard it")};function a(l,c){if(typeof l==="string"){let u=/^decimal\((\d+),\s*(-?\d+)\)$/.exec(l);if(u){let p=Number(u[1]),d=Number(u[2]);if(p<1||p>38||d<0||d>p)r("DELTA_DECIMAL_RANGE",c,"Decimal parameters require native and protocol validation")}else if(!Ywe.has(l))r("DELTA_UNKNOWN_TYPE",c,"Type spelling is outside the declared protocol vocabulary; native parser acceptance is insufficient");if(["timestamp_ntz","variant"].includes(l))r("DELTA_FEATURE_REQUIRED",c,"Type requires matching table protocol/features; schema-only import cannot verify them");if(l==="void")r("DELTA_VOID_WRITE_CONTEXT",c,"Void storage omission and write restrictions require the surrounding table schema");return}if(l.type==="struct"){o(l,["type","fields"],c);let u=new Set;l.fields.forEach((p,d)=>{let f=c+"/fields/"+d;o(p,["name","type","nullable","metadata"],f);let m=p.name.toLowerCase();if(u.has(m))r("DELTA_DUPLICATE_NAME",f+"/name","Case-insensitive duplicate name; preserved source is not a valid Delta table schema");u.add(m),a(p.type,f+"/type");for(let y of Object.keys(p.metadata))r("DELTA_METADATA_UNVERIFIED",f+"/metadata/"+$e(y),"Column metadata retained exactly; constraints, identity, mapping and defaults are not executed or validated against table context")})}else if(l.type==="array")o(l,["type","elementType","containsNull"],c),a(l.elementType,c+"/elementType");else if(l.type==="map"){if(o(l,["type","keyType","valueType","valueContainsNull"],c),a(l.keyType,c+"/keyType"),a(l.valueType,c+"/valueType"),l.valueContainsNull===void 0)r("DELTA_DEFAULT_NULLABILITY",c,"Native parser may insert valueContainsNull=true; source absence is retained")}else r("DELTA_UNKNOWN_TYPE",c,"Unknown object-form type retained without interpreting or executing it")}return a(s,""),n}function Zwe(){return new nt().register(Qwe,Xwe)}function lw(e){return We(e,Zwe())}function R4(e){let t=lw(e);if(!t.valid)throw new U("DELTA_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[aw];if(!n||e.vocabularies[aw]?.version!=="0.1.0")throw new U("DELTA_PAYLOAD","Expected pinned Delta schema payload");return Ae(n)}function j4(e,t){let n={umf:"0.1.0",id:t.id,vocabularies:{[aw]:{version:"0.1.0"}},modules:[{id:"schema",namespace:"",elements:[{id:"schema",extensions:{[aw]:{profile:"delta-schema-json",root:Jt(e)}}}]}]};return R4(n),n}function F4(e){let t=R4(e);if(lw(e).diagnostics.some((n)=>n.code==="DELTA_REPRESENTATION"))throw new U("DELTA_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var C4="umf.delta.table",eDe=P4,AO;function tDe(e){let t=e,n=[{code:"DELTA_TABLE_UNVERIFIED",path:"",severity:"warning",message:"Supplied metadata/protocol context is not a reconciled snapshot; reader/writer support and safe evolution remain unverified"}],r=(u,p,d,f="warning")=>n.push({code:u,path:p,message:d,severity:f});if(Object.keys(t).some((u)=>!["profile","root"].includes(u)))r("DELTA_TABLE_REPRESENTATION","","Unknown profile fields must remain in UMF");function i(u,p){let d=u.kind==="null"?["kind"]:u.kind==="array"?["kind","items"]:u.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(u).some((f)=>!d.includes(f)))r("DELTA_TABLE_REPRESENTATION",p,"Unknown tagged-tree fields must remain in UMF");if(u.kind==="object")for(let[f,m]of Object.entries(u.members))i(m,p+"/"+$e(f));if(u.kind==="array")u.items.forEach((f,m)=>i(f,p+"/"+m))}i(t.root,"/root");let s=JSON.parse(Be(t.root));if(AO??=mt().compile($4),!AO(s)){for(let u of AO.errors??[])r("DELTA_TABLE_STRUCTURE",u.instancePath,u.message??"Invalid table context","error");return n}let o=(u,p,d)=>{for(let f of Object.keys(u))if(!p.includes(f))r("DELTA_TABLE_UNKNOWN",d+"/"+$e(f),"Unknown native property retained")};o(s,["protocol","metaData"],""),o(s.protocol,["minReaderVersion","minWriterVersion","readerFeatures","writerFeatures"],"/protocol"),o(s.metaData,["id","name","description","format","schemaString","partitionColumns","configuration","createdTime"],"/metaData"),o(s.metaData.format,["provider","options"],"/metaData/format");let a=s.protocol,l=a.readerFeatures??[],c=a.writerFeatures??[];for(let[u,p,d]of[[a.minReaderVersion,"readerFeatures",3],[a.minWriterVersion,"writerFeatures",7]]){if(u===d!==(a[p]!==void 0))r("DELTA_FEATURE_VERSION","/protocol/"+p,"Feature-list presence does not match the pinned protocol version rule");if(u>d)r("DELTA_FUTURE_PROTOCOL","/protocol","Future protocol version remains uninterpreted");if(a[p]){if(new Set(a[p]).size!==a[p].length)r("DELTA_DUPLICATE_FEATURE","/protocol/"+p,"Feature names must be unique");for(let[f,m]of a[p].entries())r("DELTA_FEATURE_UNVERIFIED","/protocol/"+p+"/"+f,"Feature preserved; implementation capability is not asserted: "+m)}}for(let u of l)if(!c.includes(u))r("DELTA_READER_FEATURE_WRITER","/protocol/readerFeatures","Reader feature absent from writer feature list: "+u);if(s.metaData.format.provider!=="parquet")r("DELTA_FORMAT_UNVERIFIED","/metaData/format/provider","Storage provider is outside the verified examples");for(let u of Object.keys(s.metaData.configuration))r("DELTA_CONFIGURATION_UNVERIFIED","/metaData/configuration/"+$e(u),"Table configuration and embedded SQL preserved without execution or enforcement");try{let m=function(y,h){if(y==="timestamp_ntz"&&(!l.includes("timestampNtz")||!c.includes("timestampNtz")))r("DELTA_TIMESTAMP_NTZ_FEATURE",h,"timestamp_ntz requires reader and writer feature declarations");if(y&&typeof y==="object"){if(y.type==="struct")y.fields.forEach((b,g)=>m(b.type,h+"/fields/"+g+"/type"));if(y.type==="array")m(y.elementType,h+"/elementType");if(y.type==="map")m(y.keyType,h+"/keyType"),m(y.valueType,h+"/valueType")}},u=j4(s.metaData.schemaString,{id:"embedded"});for(let y of lw(u).diagnostics)n.push({...y,path:"/metaData/schemaString"+y.path});let p=JSON.parse(s.metaData.schemaString),d=new Set(p.fields.map((y)=>y.name)),f=new Set;for(let[y,h]of s.metaData.partitionColumns.entries()){if(!d.has(h))r("DELTA_PARTITION_UNRESOLVED","/metaData/partitionColumns/"+y,"Partition name does not exactly match a top-level field");if(f.has(h))r("DELTA_PARTITION_DUPLICATE","/metaData/partitionColumns/"+y,"Duplicate partition column");f.add(h)}m(p,"/metaData/schemaString")}catch{r("DELTA_EMBEDDED_SCHEMA","/metaData/schemaString","Embedded schema is invalid or outside known shape; exact string retained")}return n.push(...O4(t.root)),n}function nDe(){return new nt().register(eDe,tDe)}function M4(e){return We(e,nDe())}function rDe(e){let t=M4(e);if(!t.valid)throw new U("DELTA_TABLE_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="table")?.elements.find((r)=>r.id==="table")?.extensions[C4];if(!n||e.vocabularies[C4]?.version!=="0.1.0")throw new U("DELTA_TABLE_PAYLOAD","Expected pinned Delta schema payload");return Ae(n)}function L4(e){let t=rDe(e);if(M4(e).diagnostics.some((n)=>n.code==="DELTA_TABLE_REPRESENTATION"))throw new U("DELTA_TABLE_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var q4={id:"umf.delta.log",version:"0.1.0",coreVersion:"0.1.0",description:"Exact Delta JSON-lines source capture with independent action inspection",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:delta-log:0.1.0",type:"object",required:["profile","text"],properties:{profile:{const:"delta-jsonl-source"},text:{type:"string",maxLength:1e6}},additionalProperties:!0},semantics:"CONTRACT-018. Source text is authoritative, including invalid lines and unknown actions; inspection does not reconcile state or authorize writes.",scopes:["element"],capabilities:{validation:"structural",directions:["import","export"],native:{system:"Delta JSON transaction log",version:"Protocol 3b1b99cd077ec9c84c8a94c250dea3730cc33392; pinned delta-rs corpus",subset:"Bounded exact text capture and line/action envelope inspection. Native action semantics, commit validity and snapshot reconciliation remain unverified."},evidence:["tests/delta/log.test.ts","tests/delta/actions.test.ts","tests/delta/reconcile.test.ts","tests/delta/checkpoint.test.ts","fixtures/delta/checkpoint/oracle-results.json","fixtures/delta/checkpoint/browser-results.json","tests/delta/history-upstream.test.ts","fixtures/delta/upstream/history-oracle-results.json","fixtures/delta/upstream/history-browser-results.json","fixtures/delta/history/oracle-results.json","fixtures/delta/history/browser-results.json","fixtures/delta/upstream/action-results.json","fixtures/delta/upstream/action-oracle-results.json","fixtures/delta/upstream/log-results.json","fixtures/delta/upstream/log-browser-results.json"]}};var U4="umf.delta.log",sDe=q4;function oDe(){return new nt().register(sDe)}function B4(e){if(!We(e,oDe()).valid)throw new U("DELTA_LOG_DOCUMENT","Invalid source capture envelope");let t=e.modules.find((n)=>n.id==="log")?.elements.find((n)=>n.id==="source")?.extensions[U4];if(e.vocabularies[U4]?.version!=="0.1.0"||!t||typeof t!=="object"||Array.isArray(t))throw new U("DELTA_LOG_PAYLOAD","Expected pinned log payload");if(Object.keys(t).some((n)=>!["profile","text"].includes(n)))throw new U("DELTA_LOG_REPRESENTATION","Unknown representation fields cannot be dropped from native export");if(typeof t.text!=="string"||t.text.length>1e6)throw new U("DELTA_LOG_LIMIT","Expected at most 1000000 UTF-16 code units");return t.text}var V4={id:"umf.iceberg",version:"0.1.0",coreVersion:"0.1.0",description:"Exact Iceberg schema JSON with field identity and explicit table-context limits",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:iceberg:0.1.0",type:"object",properties:{profile:{const:"iceberg-schema-json"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-020. Native JSON tokens remain authoritative. Identifier fields do not imply enforced uniqueness. Table metadata, storage evolution and default execution remain separate.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Apache Iceberg schema JSON",version:"1.11.0 spec 6976e020b894f6a6777704df2b8c4458cb291ae9; PyIceberg 0.11.0 oracle",subset:"Standalone recursive schema preservation, field-ID and identifier checks, pointer access and candidate edits; no table compatibility or data-reader claim"},evidence:["tests/iceberg/schema.test.ts","fixtures/iceberg/oracle-results.json","fixtures/iceberg/browser-results.json"]}};var K4={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:iceberg:schema-json:0.1.0",type:"object",properties:{type:{const:"struct"},fields:{type:"array",items:{$ref:"#/$defs/field"}},"schema-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"identifier-field-ids":{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647},uniqueItems:!0}},required:["type","fields"],additionalProperties:!0,$defs:{field:{type:"object",properties:{id:{type:"integer",minimum:-2147483648,maximum:2147483647},name:{type:"string"},required:{type:"boolean"},type:{$ref:"#/$defs/type"},doc:{type:"string"},"initial-default":{},"write-default":{}},required:["id","name","required","type"],additionalProperties:!0},type:{anyOf:[{type:"string",minLength:1},{type:"object",properties:{type:{const:"struct"},fields:{type:"array",items:{$ref:"#/$defs/field"}}},required:["type","fields"],additionalProperties:!0},{type:"object",properties:{type:{const:"list"},"element-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"element-required":{type:"boolean"},element:{$ref:"#/$defs/type"}},required:["type","element-id","element-required","element"],additionalProperties:!0},{type:"object",properties:{type:{const:"map"},"key-id":{type:"integer",minimum:-2147483648,maximum:2147483647},key:{$ref:"#/$defs/type"},"value-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"value-required":{type:"boolean"},value:{$ref:"#/$defs/type"}},required:["type","key-id","key","value-id","value-required","value"],additionalProperties:!0},{type:"object",properties:{type:{type:"string",minLength:1,not:{enum:["struct","list","map"]}}},required:["type"],additionalProperties:!0}]}}};var cw="umf.iceberg",cDe=V4,RO;function uDe(e){let t=e,n=[{code:"ICEBERG_CONTEXT_UNVERIFIED",path:"",severity:"warning",message:"Standalone schema does not establish table format-version, evolution legality, default execution or data-reader support"}],r=(p,d,f,m="warning")=>n.push({code:p,path:d,message:f,severity:m});if(Object.keys(t).some((p)=>!["profile","root"].includes(p)))r("ICEBERG_REPRESENTATION","","Unknown representation fields must remain in UMF");function i(p,d){let f=p.kind==="null"?["kind"]:p.kind==="array"?["kind","items"]:p.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(p).some((m)=>!f.includes(m)))r("ICEBERG_REPRESENTATION",d,"Unknown tagged-tree fields must remain in UMF");if(p.kind==="object")for(let[m,y]of Object.entries(p.members))i(y,d+"/"+$e(m));if(p.kind==="array")p.items.forEach((m,y)=>i(m,d+"/"+y))}i(t.root,"/root");let s=JSON.parse(Be(t.root));if(RO??=mt().compile(K4),!RO(s)){for(let p of RO.errors??[])r("ICEBERG_STRUCTURE",p.instancePath,p.message??"Invalid shape","error");return n}let o=new Set(["unknown","boolean","int","long","float","double","date","time","timestamp","timestamptz","timestamp_ns","timestamptz_ns","string","uuid","binary","variant"]),a=new Map,l=(p,d,f,m)=>{if(a.has(p))r("ICEBERG_DUPLICATE_ID",m,"Field IDs must be unique across fields and list/map components","error");else a.set(p,{type:d,eligible:f,path:m});if(p<=0)r("ICEBERG_ID_CONTEXT",m,"Nonpositive ID retained; allocation legality requires table context");if(p>2147483447)r("ICEBERG_RESERVED_ID",m,"Reserved metadata-column range requires table context")},c=(p,d,f)=>{for(let m of Object.keys(p))if(!d.includes(m))r("ICEBERG_UNKNOWN",f+"/"+$e(m),"Unknown native property preserved without interpretation")};function u(p,d,f,m,y=!1){if(typeof p==="string"){if(o.has(p))return;let h=/^decimal\((\d+),\s*(\d+)\)$/.exec(p),b=/^fixed\[(\d+)\]$/.exec(p);if(h){if(+h[1]<1||+h[1]>38||+h[2]>+h[1])r("ICEBERG_TYPE_PARAMETERS",d,"Decimal requires 1..38 precision and 0..precision scale","error");return}if(b){if(BigInt(b[1])<1n||BigInt(b[1])>2147483647n)r("ICEBERG_TYPE_PARAMETERS",d,"Fixed length must be a positive int32","error");return}r("ICEBERG_UNKNOWN_TYPE",d,"Uninterpreted native type spelling; geospatial and future type parameters require separate checks");return}if(p.type==="struct"){c(p,y?["type","fields","schema-id","identifier-field-ids"]:["type","fields"],d);let h=new Set;for(let[b,g]of p.fields.entries()){let x=d+"/fields/"+b;if(h.has(g.name))r("ICEBERG_DUPLICATE_NAME",x,"Sibling names must be unique","error");h.add(g.name),l(g.id,g.type,f&&g.required&&!m,x+"/id"),c(g,["id","name","type","required","doc","initial-default","write-default"],x);for(let v of["initial-default","write-default"])if(Object.hasOwn(g,v))r("ICEBERG_DEFAULT_UNVERIFIED",x+"/"+v,"Default retained exactly; type encoding and historical execution require separate checks");u(g.type,x+"/type",f&&g.required,m)}}else if(p.type==="list")c(p,["type","element-id","element-required","element"],d),l(p["element-id"],p.element,!1,d+"/element-id"),u(p.element,d+"/element",!1,!0);else if(p.type==="map")c(p,["type","key-id","key","value-id","value-required","value"],d),l(p["key-id"],p.key,!1,d+"/key-id"),l(p["value-id"],p.value,!1,d+"/value-id"),u(p.key,d+"/key",!1,!0),u(p.value,d+"/value",!1,!0);else r("ICEBERG_UNKNOWN_TYPE",d,"Unknown object-form type preserved without interpretation")}u(s,"",!0,!1,!0);for(let[p,d]of(s["identifier-field-ids"]??[]).entries()){let f=a.get(d);if(!f||!f.eligible||typeof f.type!=="string"||["float","double"].includes(f.type))r("ICEBERG_IDENTIFIER","/identifier-field-ids/"+p,"Identifier requires a required primitive field under required structs, outside collections","error");else if(!o.has(f.type)&&!/^decimal\(|^fixed\[/.test(f.type))r("ICEBERG_IDENTIFIER_UNVERIFIED","/identifier-field-ids/"+p,"Unknown primitive meaning cannot establish identifier eligibility")}if(s["schema-id"]===void 0)r("ICEBERG_SCHEMA_ID_CONTEXT","","Missing schema-id is retained; table format version determines whether it is required");return n}function pDe(){return new nt().register(cDe,uDe)}function uw(e){return We(e,pDe())}function J4(e){let t=uw(e);if(!t.valid)throw new U("ICEBERG_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[cw];if(!n||e.vocabularies[cw]?.version!=="0.1.0")throw new U("ICEBERG_PAYLOAD","Expected pinned Iceberg schema payload");return Ae(n)}function G4(e,t){let n={umf:"0.1.0",id:t.id,vocabularies:{[cw]:{version:"0.1.0"}},modules:[{id:"schema",namespace:"",elements:[{id:"schema",extensions:{[cw]:{profile:"iceberg-schema-json",root:Jt(e)}}}]}]};return J4(n),n}function H4(e){let t=J4(e);if(uw(e).diagnostics.some((n)=>n.code==="ICEBERG_REPRESENTATION"))throw new U("ICEBERG_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var z4={id:"umf.iceberg.table",version:"0.1.0",coreVersion:"0.1.0",description:"Exact Iceberg table metadata JSON, known field shapes and explicit context limits",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:iceberg:table:0.1.0",type:"object",properties:{profile:{const:"iceberg-table-json"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-021. Preserve exact table JSON, unknown fields and versions; schema/shape checks do not authorize data reads, commits or evolution.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Apache Iceberg table metadata JSON",version:"1.11.0 spec; PyIceberg 0.11.0",subset:"Known v1-v3 metadata field shapes, embedded schema consistency, exact integers, preservation and candidate edits; reference/feature/default/history validation remains incomplete"},evidence:["tests/iceberg/table.test.ts","fixtures/iceberg/table/oracle-results.json","fixtures/iceberg/table/browser-results.json"]}};var Vg={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:iceberg:table-json:0.1.0",type:"object",properties:{"format-version":{type:"integer",minimum:-2147483648,maximum:2147483647}},required:["format-version"],additionalProperties:!0,allOf:[{if:{properties:{"format-version":{enum:[1,2,3]}}},then:{properties:{"format-version":{type:"integer",minimum:-2147483648,maximum:2147483647},"table-uuid":{type:"string"},location:{type:"string"},"last-sequence-number":{type:"integer",format:"int64"},"last-updated-ms":{type:"integer",format:"int64"},"last-column-id":{type:"integer",minimum:-2147483648,maximum:2147483647},schema:{$ref:"#/$defs/Schema"},schemas:{type:"array",items:{$ref:"#/$defs/Schema"}},"current-schema-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"partition-spec":{type:"array",items:{$ref:"#/$defs/PartitionField"}},"partition-specs":{type:"array",items:{$ref:"#/$defs/PartitionSpec"}},"default-spec-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"last-partition-id":{type:"integer",minimum:-2147483648,maximum:2147483647},properties:{type:"object",additionalProperties:{type:"string"}},"current-snapshot-id":{anyOf:[{type:"integer",format:"int64"},{type:"null"}]},snapshots:{type:"array",items:{$ref:"#/$defs/Snapshot"}},"snapshot-log":{type:"array",items:{type:"object",properties:{"timestamp-ms":{type:"integer",format:"int64"},"snapshot-id":{type:"integer",format:"int64"}},required:["timestamp-ms","snapshot-id"],additionalProperties:!0}},"metadata-log":{type:"array",items:{type:"object",properties:{"timestamp-ms":{type:"integer",format:"int64"},"metadata-file":{type:"string"}},required:["timestamp-ms","metadata-file"],additionalProperties:!0}},"sort-orders":{type:"array",items:{$ref:"#/$defs/SortOrder"}},"default-sort-order-id":{type:"integer",minimum:-2147483648,maximum:2147483647},refs:{anyOf:[{type:"object",additionalProperties:{$ref:"#/$defs/Ref"}},{type:"null"}]},statistics:{type:"array",items:{$ref:"#/$defs/Statistics"}},"partition-statistics":{type:"array",items:{$ref:"#/$defs/PartitionStatistics"}},"next-row-id":{type:"integer",format:"int64"},"encryption-keys":{type:"array",items:{$ref:"#/$defs/EncryptionKey"}}},required:["format-version","location","last-updated-ms","last-column-id"]}},{if:{properties:{"format-version":{const:1}}},then:{required:["schema","partition-spec"]}},{if:{properties:{"format-version":{enum:[2,3]}}},then:{required:["table-uuid","last-sequence-number","schemas","current-schema-id","partition-specs","default-spec-id","last-partition-id","sort-orders","default-sort-order-id"]}},{if:{properties:{"format-version":{const:3}}},then:{required:["next-row-id"]}},{if:{properties:{"format-version":{enum:[1,2]}}},then:{properties:{"partition-spec":{type:"array",items:{type:"object",properties:{"source-id":{}},required:["source-id"]}},"partition-specs":{type:"array",items:{type:"object",properties:{fields:{type:"array",items:{type:"object",properties:{"source-id":{}},required:["source-id"]}}},required:[],additionalProperties:!0}},"sort-orders":{type:"array",items:{type:"object",properties:{fields:{type:"array",items:{type:"object",properties:{"source-id":{}},required:["source-id"]}}},required:[],additionalProperties:!0}}}}},{if:{properties:{"format-version":{enum:[2,3]}}},then:{properties:{"partition-spec":{type:"array",items:{type:"object",properties:{"field-id":{}},required:["field-id"]}},"partition-specs":{type:"array",items:{type:"object",properties:{fields:{type:"array",items:{type:"object",properties:{"field-id":{}},required:["field-id"]}}},required:[],additionalProperties:!0}}}}}],$defs:{field:{type:"object",properties:{id:{type:"integer",minimum:-2147483648,maximum:2147483647},name:{type:"string"},required:{type:"boolean"},type:{$ref:"#/$defs/type"},doc:{type:"string"},"initial-default":{},"write-default":{}},required:["id","name","required","type"],additionalProperties:!0},type:{anyOf:[{type:"string",minLength:1},{type:"object",properties:{type:{const:"struct"},fields:{type:"array",items:{$ref:"#/$defs/field"}}},required:["type","fields"],additionalProperties:!0},{type:"object",properties:{type:{const:"list"},"element-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"element-required":{type:"boolean"},element:{$ref:"#/$defs/type"}},required:["type","element-id","element-required","element"],additionalProperties:!0},{type:"object",properties:{type:{const:"map"},"key-id":{type:"integer",minimum:-2147483648,maximum:2147483647},key:{$ref:"#/$defs/type"},"value-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"value-required":{type:"boolean"},value:{$ref:"#/$defs/type"}},required:["type","key-id","key","value-id","value-required","value"],additionalProperties:!0},{type:"object",properties:{type:{type:"string",minLength:1,not:{enum:["struct","list","map"]}}},required:["type"],additionalProperties:!0}]},Schema:{type:"object",properties:{type:{const:"struct"},fields:{type:"array",items:{$ref:"#/$defs/field"}},"schema-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"identifier-field-ids":{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647},uniqueItems:!0}},required:["type","fields"],additionalProperties:!0},PartitionField:{type:"object",properties:{"source-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"source-ids":{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647},minItems:1},"field-id":{type:"integer",minimum:-2147483648,maximum:2147483647},name:{type:"string"},transform:{type:"string"}},required:["name","transform"],additionalProperties:!0,oneOf:[{properties:{"source-id":{},"source-ids":{}},required:["source-id"],not:{properties:{"source-ids":{}},required:["source-ids"]}},{properties:{"source-id":{},"source-ids":{}},required:["source-ids"],not:{properties:{"source-id":{}},required:["source-id"]}}]},PartitionSpec:{type:"object",properties:{"spec-id":{type:"integer",minimum:-2147483648,maximum:2147483647},fields:{type:"array",items:{$ref:"#/$defs/PartitionField"}}},required:["spec-id","fields"],additionalProperties:!0},SortField:{type:"object",properties:{"source-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"source-ids":{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647},minItems:1},transform:{type:"string"},direction:{type:"string"},"null-order":{type:"string"}},required:["transform","direction","null-order"],additionalProperties:!0,oneOf:[{properties:{"source-id":{},"source-ids":{}},required:["source-id"],not:{properties:{"source-ids":{}},required:["source-ids"]}},{properties:{"source-id":{},"source-ids":{}},required:["source-ids"],not:{properties:{"source-id":{}},required:["source-id"]}}]},SortOrder:{type:"object",properties:{"order-id":{type:"integer",minimum:-2147483648,maximum:2147483647},fields:{type:"array",items:{$ref:"#/$defs/SortField"}}},required:["order-id","fields"],additionalProperties:!0},Snapshot:{type:"object",properties:{"snapshot-id":{type:"integer",format:"int64"},"parent-snapshot-id":{type:"integer",format:"int64"},"sequence-number":{type:"integer",format:"int64"},"timestamp-ms":{type:"integer",format:"int64"},"manifest-list":{type:"string"},manifests:{type:"array",items:{type:"string"}},summary:{type:"object",additionalProperties:{type:"string"}},"schema-id":{type:"integer",minimum:-2147483648,maximum:2147483647},"first-row-id":{type:"integer",format:"int64"},"added-rows":{type:"integer",format:"int64"}},required:["snapshot-id","timestamp-ms"],additionalProperties:!0},Ref:{type:"object",properties:{"snapshot-id":{type:"integer",format:"int64"},type:{type:"string"},"min-snapshots-to-keep":{type:"integer",minimum:-2147483648,maximum:2147483647},"max-snapshot-age-ms":{type:"integer",format:"int64"},"max-ref-age-ms":{type:"integer",format:"int64"}},required:["snapshot-id","type"],additionalProperties:!0},Blob:{type:"object",properties:{type:{type:"string"},"snapshot-id":{type:"integer",format:"int64"},"sequence-number":{type:"integer",format:"int64"},fields:{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647}},properties:{type:"object",additionalProperties:{type:"string"}}},required:["type","snapshot-id","sequence-number","fields"],additionalProperties:!0},Statistics:{type:"object",properties:{"snapshot-id":{type:"integer",format:"int64"},"statistics-path":{type:"string"},"file-size-in-bytes":{type:"integer",format:"int64"},"file-footer-size-in-bytes":{type:"integer",format:"int64"},"key-metadata":{type:"string"},"blob-metadata":{type:"array",items:{$ref:"#/$defs/Blob"}}},required:["snapshot-id","statistics-path","file-size-in-bytes","file-footer-size-in-bytes","blob-metadata"],additionalProperties:!0},PartitionStatistics:{type:"object",properties:{"snapshot-id":{type:"integer",format:"int64"},"statistics-path":{type:"string"},"file-size-in-bytes":{type:"integer",format:"int64"}},required:["snapshot-id","statistics-path","file-size-in-bytes"],additionalProperties:!0},EncryptionKey:{type:"object",properties:{"key-id":{type:"string"},"key-metadata":{type:"string"}},required:["key-id","key-metadata"],additionalProperties:!0}}};var W4="umf.iceberg.table",mDe=z4,jO;function yDe(e){let t=e,n=[{code:"ICEBERG_TABLE_CONTEXT",path:"",severity:"warning",message:"Metadata shapes do not validate physical files, schema evolution, transforms, reference histories, defaults, encryption or safe commits"}],r=(c,u,p,d="warning")=>n.push({code:c,path:u,message:p,severity:d});if(Object.keys(t).some((c)=>!["profile","root"].includes(c)))r("ICEBERG_TABLE_REPRESENTATION","","Unknown representation fields must remain in UMF");function i(c,u){let p=c.kind==="null"?["kind"]:c.kind==="array"?["kind","items"]:c.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(c).some((d)=>!p.includes(d)))r("ICEBERG_TABLE_REPRESENTATION",u,"Unknown tagged-tree fields must remain in UMF");if(c.kind==="object")for(let[d,f]of Object.entries(c.members))i(f,u+"/"+$e(d));if(c.kind==="array")c.items.forEach((d,f)=>i(d,u+"/"+f))}i(t.root,""),jO??=mt().compile(Vg);let s=JSON.parse(Be(t.root));if(!jO(s)){for(let c of jO.errors??[])r("ICEBERG_TABLE_STRUCTURE",c.instancePath,c.message??"Invalid table shape","error");return n}let o=[1,2,3].includes(s["format-version"]);if(!o)r("ICEBERG_TABLE_VERSION","/format-version","Unknown table version preserved without native interpretation");let a=o?Vg.allOf[0].then:{properties:Vg.properties};function l(c,u,p){if(u.$ref){let d=u.$ref.split("/").at(-1);return l(c,Vg.$defs[d],p)}if(u.anyOf){if(c.kind==="null")return;let d=c.kind==="object"&&c.members.type?.kind==="string"?c.members.type.value:void 0,f=(d?u.anyOf.find((m)=>m.properties?.type?.const===d):void 0)??u.anyOf.find((m)=>m.type===c.kind&&!m.properties?.type?.const||c.kind==="number"&&m.type==="integer")??u.anyOf.find((m)=>m.type==="object"&&!m.properties?.type?.const);if(f)return l(c,f,p);return}if(u.type==="integer"&&c.kind==="number"){if(!/^-?\d+$/.test(c.value)||c.value.replace("-","").length>19){r("ICEBERG_TABLE_INTEGER",p,"Expected bounded exact integer token","error");return}let d=BigInt(c.value),f=u.format==="int64"?-9223372036854775808n:BigInt(u.minimum??-2147483648),m=u.format==="int64"?9223372036854775807n:BigInt(u.maximum??2147483647);if(dm)r("ICEBERG_TABLE_INTEGER",p,"Integer exceeds signed width","error")}if(c.kind==="object")for(let[d,f]of Object.entries(c.members)){let m=u.properties&&Object.hasOwn(u.properties,d)?u.properties[d]:typeof u.additionalProperties==="object"?u.additionalProperties:void 0;if(m)l(f,m,p+"/"+$e(d));else if(u.properties)r("ICEBERG_TABLE_UNKNOWN",p+"/"+$e(d),"Unknown native property preserved")}if(c.kind==="array"&&u.items)c.items.forEach((d,f)=>l(d,u.items,p+"/"+f))}if(l(t.root,a,""),o&&t.root.kind==="object"){let c=t.root.members.schemas,u=t.root.members.schema,p=[...u?[{node:u,path:"/schema"}]:[],...c?.kind==="array"?c.items.map((d,f)=>({node:d,path:"/schemas/"+f})):[]];for(let d of p)try{let f=G4(Be(d.node),{id:"embedded"});for(let m of uw(f).diagnostics)n.push({...m,path:d.path+m.path})}catch(f){r("ICEBERG_TABLE_SCHEMA",d.path,f.message,"error")}}return n}function hDe(){return new nt().register(mDe,yDe)}function Q4(e){return We(e,hDe())}function gDe(e){let t=Q4(e);if(!t.valid)throw new U("ICEBERG_TABLE_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="table")?.elements.find((r)=>r.id==="table")?.extensions[W4];if(!n||e.vocabularies[W4]?.version!=="0.1.0")throw new U("ICEBERG_TABLE_PAYLOAD","Expected pinned Iceberg schema payload");return Ae(n)}function Y4(e){let t=gDe(e);if(Q4(e).diagnostics.some((n)=>n.code==="ICEBERG_TABLE_REPRESENTATION"))throw new U("ICEBERG_TABLE_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var X4={id:"umf.dbt.semantic",version:"0.1.0",coreVersion:"0.1.0",description:"Exact dbt semantic manifest with DSI-version-scoped serialized shape checks",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:dbt:semantic:0.1.0",type:"object",properties:{profile:{const:"dbt-semantic-json"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-022 AC10–AC11; retain source independently of derived shape diagnostics; semantic validation and execution remain external",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"dbt semantic manifest",version:"dbt-semantic-interfaces 0.8.5, dbt Core 1.10.0",subset:"Exact JSON preservation, copied candidate edits and derived nullable serialized shapes; no metric execution or semantic-validator equivalence"},evidence:["tests/dbt/semantic.test.ts","fixtures/dbt/semantic/oracle-results.json","fixtures/dbt/semantic/browser-results.json","tests/dbt/semantic-metrics.test.ts","fixtures/dbt/semantic-metrics/oracle-results.json","fixtures/dbt/semantic-metrics/browser-results.json"]}};var Z4={title:"PydanticSemanticManifest",description:"Model holds all the information the SemanticLayer needs to render a query.",type:"object",properties:{semantic_models:{title:"Semantic Models",type:"array",items:{$ref:"#/definitions/PydanticSemanticModel"}},metrics:{title:"Metrics",type:"array",items:{$ref:"#/definitions/PydanticMetric"}},project_configuration:{$ref:"#/definitions/PydanticProjectConfiguration"},saved_queries:{title:"Saved Queries",type:"array",items:{$ref:"#/definitions/PydanticSavedQuery"}}},required:["semantic_models","metrics","project_configuration"],definitions:{PydanticSemanticModelDefaults:{title:"PydanticSemanticModelDefaults",description:"Extends BaseModel with a generic hash function.",type:"object",properties:{agg_time_dimension:{anyOf:[{title:"Agg Time Dimension",type:"string"},{type:"null"}]}}},PydanticNodeRelation:{title:"PydanticNodeRelation",description:"Path object to where the data should be.",type:"object",properties:{alias:{title:"Alias",type:"string"},schema_name:{title:"Schema Name",type:"string"},database:{anyOf:[{title:"Database",type:"string"},{type:"null"}]},relation_name:{title:"Relation Name",default:"",type:"string"}},required:["alias","schema_name"]},EntityType:{title:"EntityType",description:"Defines uniqueness and the extent to which an entity represents the common entity for a semantic model.",enum:["foreign","natural","primary","unique"]},PydanticFileSlice:{title:"PydanticFileSlice",description:"Extends BaseModel with a generic hash function.",type:"object",properties:{filename:{title:"Filename",type:"string"},content:{title:"Content",type:"string"},start_line_number:{title:"Start Line Number",type:"integer"},end_line_number:{title:"End Line Number",type:"integer"}},required:["filename","content","start_line_number","end_line_number"]},PydanticMetadata:{title:"PydanticMetadata",description:"Extends BaseModel with a generic hash function.",type:"object",properties:{repo_file_path:{title:"Repo File Path",type:"string"},file_slice:{$ref:"#/definitions/PydanticFileSlice"}},required:["repo_file_path","file_slice"]},PydanticSemanticLayerElementConfig:{title:"PydanticSemanticLayerElementConfig",description:"PydanticDimension config.",type:"object",properties:{meta:{title:"Meta",type:"object"}}},PydanticEntity:{title:"PydanticEntity",description:"Describes a entity.",type:"object",properties:{name:{title:"Name",type:"string"},description:{anyOf:[{title:"Description",type:"string"},{type:"null"}]},type:{$ref:"#/definitions/EntityType"},role:{anyOf:[{title:"Role",type:"string"},{type:"null"}]},expr:{anyOf:[{title:"Expr",type:"string"},{type:"null"}]},metadata:{anyOf:[{$ref:"#/definitions/PydanticMetadata"},{type:"null"}]},label:{anyOf:[{title:"Label",type:"string"},{type:"null"}]},config:{anyOf:[{$ref:"#/definitions/PydanticSemanticLayerElementConfig"},{type:"null"}]}},required:["name","type"]},AggregationType:{title:"AggregationType",description:"Aggregation methods for measures.",enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},PydanticMeasureAggregationParameters:{title:"PydanticMeasureAggregationParameters",description:"Describes parameters for aggregations.",type:"object",properties:{percentile:{anyOf:[{title:"Percentile",type:"number"},{type:"null"}]},use_discrete_percentile:{title:"Use Discrete Percentile",default:!1,type:"boolean"},use_approximate_percentile:{title:"Use Approximate Percentile",default:!1,type:"boolean"}}},PydanticNonAdditiveDimensionParameters:{title:"PydanticNonAdditiveDimensionParameters",description:`Describes the params for specifying non-additive dimensions in a measure. NOTE: Currently, only TimeDimensions are supported for this filter`,type:"object",properties:{name:{title:"Name",type:"string"},window_choice:{default:"min",allOf:[{$ref:"#/definitions/AggregationType"}]},window_groupings:{title:"Window Groupings",type:"array",items:{type:"string"}}},required:["name"]},PydanticMeasure:{title:"PydanticMeasure",description:"Describes a measure.",type:"object",properties:{name:{title:"Name",type:"string"},agg:{$ref:"#/definitions/AggregationType"},description:{anyOf:[{title:"Description",type:"string"},{type:"null"}]},create_metric:{anyOf:[{title:"Create Metric",type:"boolean"},{type:"null"}]},expr:{anyOf:[{title:"Expr",type:"string"},{type:"null"}]},agg_params:{anyOf:[{$ref:"#/definitions/PydanticMeasureAggregationParameters"},{type:"null"}]},metadata:{anyOf:[{$ref:"#/definitions/PydanticMetadata"},{type:"null"}]},non_additive_dimension:{anyOf:[{$ref:"#/definitions/PydanticNonAdditiveDimensionParameters"},{type:"null"}]},agg_time_dimension:{anyOf:[{title:"Agg Time Dimension",type:"string"},{type:"null"}]},label:{anyOf:[{title:"Label",type:"string"},{type:"null"}]},config:{anyOf:[{$ref:"#/definitions/PydanticSemanticLayerElementConfig"},{type:"null"}]}},required:["name","agg"]},DimensionType:{title:"DimensionType",description:"Determines types of values expected of dimensions.",enum:["categorical","time"]},TimeGranularity:{title:"TimeGranularity",description:`For time dimensions, the smallest possible difference between two time values. @@ -394,23 +394,23 @@ The data set will contain entities and dimensions as referenced in the query alo that are referenced in any of these filters, whether they are part of the query request or metric definition.`,type:"object",properties:{where_sql_template:{title:"Where Sql Template",type:"string"}},required:["where_sql_template"]},PydanticWhereFilterIntersection:{title:"PydanticWhereFilterIntersection",description:"Pydantic implementation of a WhereFilterIntersection.",type:"object",properties:{where_filters:{title:"Where Filters",type:"array",items:{$ref:"#/definitions/PydanticWhereFilter"}}},required:["where_filters"]},PydanticMetricInputMeasure:{title:"PydanticMetricInputMeasure",description:`Provides a pointer to a measure along with metric-specific processing directives. If an alias is set, this will be used as the string name reference for this measure after the aggregation -phase in the SQL plan.`,type:"object",properties:{name:{title:"Name",type:"string"},filter:{anyOf:[{$ref:"#/definitions/PydanticWhereFilterIntersection"},{type:"null"}]},alias:{anyOf:[{title:"Alias",type:"string"},{type:"null"}]},join_to_timespine:{title:"Join To Timespine",default:!1,type:"boolean"},fill_nulls_with:{anyOf:[{title:"Fill Nulls With",type:"integer"},{type:"null"}]}},required:["name"]},PydanticMetricTimeWindow:{title:"PydanticMetricTimeWindow",description:"Describes the window of time the metric should be accumulated over, e.g., '1 day', '2 weeks', etc.",type:"object",properties:{count:{title:"Count",type:"integer"},granularity:{title:"Granularity",type:"string"}},required:["count","granularity"]},PydanticMetricInput:{title:"PydanticMetricInput",description:"Provides a pointer to a metric along with the additional properties used on that metric.",type:"object",properties:{name:{title:"Name",type:"string"},filter:{anyOf:[{$ref:"#/definitions/PydanticWhereFilterIntersection"},{type:"null"}]},alias:{anyOf:[{title:"Alias",type:"string"},{type:"null"}]},offset_window:{anyOf:[{$ref:"#/definitions/PydanticMetricTimeWindow"},{type:"null"}]},offset_to_grain:{anyOf:[{title:"Offset To Grain",type:"string"},{type:"null"}]}},required:["name"]},ConversionCalculationType:{title:"ConversionCalculationType",description:"Types of calculations for a conversion metric.",enum:["conversions","conversion_rate"]},PydanticConstantPropertyInput:{title:"PydanticConstantPropertyInput",description:"Input of a constant property used in conversion metrics.",type:"object",properties:{base_property:{title:"Base Property",type:"string"},conversion_property:{title:"Conversion Property",type:"string"}},required:["base_property","conversion_property"]},PydanticConversionTypeParams:{title:"PydanticConversionTypeParams",description:"Type params to provide context for conversion metrics properties.",type:"object",properties:{base_measure:{$ref:"#/definitions/PydanticMetricInputMeasure"},conversion_measure:{$ref:"#/definitions/PydanticMetricInputMeasure"},entity:{title:"Entity",type:"string"},calculation:{default:"conversion_rate",allOf:[{$ref:"#/definitions/ConversionCalculationType"}]},window:{anyOf:[{$ref:"#/definitions/PydanticMetricTimeWindow"},{type:"null"}]},constant_properties:{anyOf:[{title:"Constant Properties",type:"array",items:{$ref:"#/definitions/PydanticConstantPropertyInput"}},{type:"null"}]}},required:["base_measure","conversion_measure","entity"]},PeriodAggregation:{title:"PeriodAggregation",description:"Options for how to aggregate across a time period.",enum:["first","last","average"]},PydanticCumulativeTypeParams:{title:"PydanticCumulativeTypeParams",description:"Type params to provide context for cumulative metrics properties.",type:"object",properties:{window:{anyOf:[{$ref:"#/definitions/PydanticMetricTimeWindow"},{type:"null"}]},grain_to_date:{anyOf:[{title:"Grain To Date",type:"string"},{type:"null"}]},period_agg:{default:"first",allOf:[{$ref:"#/definitions/PeriodAggregation"}]}}},PydanticMetricTypeParams:{title:"PydanticMetricTypeParams",description:"Type params add additional context to certain metric types (the context depends on the metric type).",type:"object",properties:{measure:{anyOf:[{$ref:"#/definitions/PydanticMetricInputMeasure"},{type:"null"}]},numerator:{anyOf:[{$ref:"#/definitions/PydanticMetricInput"},{type:"null"}]},denominator:{anyOf:[{$ref:"#/definitions/PydanticMetricInput"},{type:"null"}]},expr:{anyOf:[{title:"Expr",type:"string"},{type:"null"}]},window:{anyOf:[{$ref:"#/definitions/PydanticMetricTimeWindow"},{type:"null"}]},grain_to_date:{anyOf:[{$ref:"#/definitions/TimeGranularity"},{type:"null"}]},metrics:{anyOf:[{title:"Metrics",type:"array",items:{$ref:"#/definitions/PydanticMetricInput"}},{type:"null"}]},conversion_type_params:{anyOf:[{$ref:"#/definitions/PydanticConversionTypeParams"},{type:"null"}]},cumulative_type_params:{anyOf:[{$ref:"#/definitions/PydanticCumulativeTypeParams"},{type:"null"}]},input_measures:{title:"Input Measures",type:"array",items:{$ref:"#/definitions/PydanticMetricInputMeasure"}}}},PydanticMetric:{title:"PydanticMetric",description:"Describes a metric.",type:"object",properties:{name:{title:"Name",type:"string"},description:{anyOf:[{title:"Description",type:"string"},{type:"null"}]},type:{$ref:"#/definitions/MetricType"},type_params:{$ref:"#/definitions/PydanticMetricTypeParams"},filter:{anyOf:[{$ref:"#/definitions/PydanticWhereFilterIntersection"},{type:"null"}]},metadata:{anyOf:[{$ref:"#/definitions/PydanticMetadata"},{type:"null"}]},label:{anyOf:[{title:"Label",type:"string"},{type:"null"}]},config:{anyOf:[{$ref:"#/definitions/PydanticSemanticLayerElementConfig"},{type:"null"}]},time_granularity:{anyOf:[{title:"Time Granularity",type:"string"},{type:"null"}]}},required:["name","type","type_params"]},PydanticTimeSpineTableConfiguration:{title:"PydanticTimeSpineTableConfiguration",description:"Legacy Pydantic implementation of SemanticVersion. In the process of deprecation.",type:"object",properties:{location:{title:"Location",type:"string"},column_name:{title:"Column Name",type:"string"},grain:{$ref:"#/definitions/TimeGranularity"}},required:["location","column_name","grain"]},PydanticSemanticVersion:{title:"PydanticSemanticVersion",description:"Pydantic implementation of SemanticVersion.",type:"object",properties:{major_version:{title:"Major Version",type:"string"},minor_version:{title:"Minor Version",type:"string"},patch_version:{anyOf:[{title:"Patch Version",type:"string"},{type:"null"}]}},required:["major_version","minor_version"]},PydanticTimeSpinePrimaryColumn:{title:"PydanticTimeSpinePrimaryColumn",description:"Extends BaseModel with a generic hash function.",type:"object",properties:{name:{title:"Name",type:"string"},time_granularity:{$ref:"#/definitions/TimeGranularity"}},required:["name","time_granularity"]},PydanticTimeSpineCustomGranularityColumn:{title:"PydanticTimeSpineCustomGranularityColumn",description:"Extends BaseModel with a generic hash function.",type:"object",properties:{name:{title:"Name",type:"string"},column_name:{anyOf:[{title:"Column Name",type:"string"},{type:"null"}]}},required:["name"]},PydanticTimeSpine:{title:"PydanticTimeSpine",description:"Extends BaseModel with a generic hash function.",type:"object",properties:{node_relation:{$ref:"#/definitions/PydanticNodeRelation"},primary_column:{$ref:"#/definitions/PydanticTimeSpinePrimaryColumn"},custom_granularities:{title:"Custom Granularities",type:"array",items:{$ref:"#/definitions/PydanticTimeSpineCustomGranularityColumn"}}},required:["node_relation","primary_column"]},PydanticProjectConfiguration:{title:"PydanticProjectConfiguration",description:"Pydantic implementation of ProjectConfiguration.",type:"object",properties:{time_spine_table_configurations:{title:"Time Spine Table Configurations",type:"array",items:{$ref:"#/definitions/PydanticTimeSpineTableConfiguration"}},metadata:{anyOf:[{$ref:"#/definitions/PydanticMetadata"},{type:"null"}]},dsi_package_version:{title:"Dsi Package Version",default:{major_version:"0",minor_version:"0",patch_version:"0"},allOf:[{$ref:"#/definitions/PydanticSemanticVersion"}]},time_spines:{title:"Time Spines",type:"array",items:{$ref:"#/definitions/PydanticTimeSpine"}}}},PydanticSavedQueryQueryParams:{title:"PydanticSavedQueryQueryParams",description:"Pydantic implementation of SavedQuery.",type:"object",properties:{metrics:{title:"Metrics",type:"array",items:{type:"string"}},group_by:{title:"Group By",type:"array",items:{type:"string"}},order_by:{title:"Order By",type:"array",items:{type:"string"}},limit:{anyOf:[{title:"Limit",type:"integer"},{type:"null"}]},where:{anyOf:[{$ref:"#/definitions/PydanticWhereFilterIntersection"},{type:"null"}]}},required:["metrics"]},ExportDestinationType:{title:"ExportDestinationType",description:"Types of destinations that exports can be written to.",enum:["table","view"]},PydanticExportConfig:{title:"PydanticExportConfig",description:'Pydantic implementation of ExportConfig.\n\nNote on `schema_name`: `schema` is an existing BaseModel attribute, so we need to alias it here.\n`Field.alias="schema"` enables using the `schema` key in YAML. `Config.allow_population_by_field_name`\nenables parsing for both `schema` and `schema_name` when deserializing from JSON.',type:"object",properties:{export_as:{$ref:"#/definitions/ExportDestinationType"},schema:{anyOf:[{title:"Schema",type:"string"},{type:"null"}]},alias:{anyOf:[{title:"Alias",type:"string"},{type:"null"}]}},required:["export_as"]},PydanticExport:{title:"PydanticExport",description:"Pydantic implementation of Export.",type:"object",properties:{name:{title:"Name",type:"string"},config:{$ref:"#/definitions/PydanticExportConfig"}},required:["name","config"]},PydanticSavedQuery:{title:"PydanticSavedQuery",description:"Pydantic implementation of SavedQuery.",type:"object",properties:{name:{title:"Name",type:"string"},query_params:{$ref:"#/definitions/PydanticSavedQueryQueryParams"},description:{anyOf:[{title:"Description",type:"string"},{type:"null"}]},metadata:{anyOf:[{$ref:"#/definitions/PydanticMetadata"},{type:"null"}]},label:{anyOf:[{title:"Label",type:"string"},{type:"null"}]},exports:{title:"Exports",type:"array",items:{$ref:"#/definitions/PydanticExport"}},tags:{title:"Tags",anyOf:[{type:"string"},{type:"array",items:{type:"string"}}]}},required:["name","query_params"]}},$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:dbt:semantic-manifest:dsi-0.8.5:serialized"};var e9="umf.dbt.semantic",vDe=X4,t9=new Map;function _De(e){let t=e,n=[{code:"DBT_SEMANTIC_MANIFEST_CONTEXT",path:"",severity:"warning",message:"Derived nullable shapes do not establish semantic rule validity, metric execution, joins, SQL semantics, parser coercion/defaults or exact-number constraints beyond JS precision"}],r=(c,u,p,d="warning")=>n.push({code:c,path:u,message:p,severity:d});if(Object.keys(t).some((c)=>!["profile","root"].includes(c)))r("DBT_SEMANTIC_MANIFEST_REPRESENTATION","","Unknown representation fields remain in UMF");function i(c,u){let p=c.kind==="null"?["kind"]:c.kind==="array"?["kind","items"]:c.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(c).some((d)=>!p.includes(d)))r("DBT_SEMANTIC_MANIFEST_REPRESENTATION",u,"Unknown tagged-tree fields remain in UMF");if(c.kind==="object")for(let[d,f]of Object.entries(c.members))i(f,u+"/"+Pe(d));if(c.kind==="array")c.items.forEach((d,f)=>i(d,u+"/"+f))}if(i(t.root,""),t.root.kind!=="object")return r("DBT_SEMANTIC_MANIFEST_STRUCTURE","","Expected semantic manifest object","error"),n;let s=t.root.members.project_configuration,o=s?.kind==="object"?s.members.dsi_package_version:void 0;if(!(o?.kind==="object"&&["major_version","minor_version","patch_version"].every((c,u)=>{let p=o.members[c];return p?.kind==="string"&&p.value===["0","8","5"][u]})))return r("DBT_SEMANTIC_MANIFEST_VERSION","/project_configuration/dsi_package_version","Missing or unknown DSI version preserved without interpretation"),n;let l=t9.get("0.8.5");if(!l)l=mt(!1).compile(Z4),t9.set("0.8.5",l);if(!l(JSON.parse(Be(t.root))))for(let c of(l.errors??[]).slice(0,100))r("DBT_SEMANTIC_MANIFEST_NATIVE_SCHEMA",c.instancePath,c.message??"Derived serialized shape mismatch");if((l.errors?.length??0)>100)r("DBT_SEMANTIC_MANIFEST_DIAGNOSTICS_TRUNCATED","","More than 100 native schema diagnostics; first 100 retained");return n}function xDe(){return new nt().register(vDe,_De)}function n9(e){return We(e,xDe())}function wDe(e){let t=n9(e);if(!t.valid)throw new U("DBT_SEMANTIC_MANIFEST_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="semantic")?.elements.find((r)=>r.id==="semantic")?.extensions[e9];if(!n||e.vocabularies[e9]?.version!=="0.1.0")throw new U("DBT_SEMANTIC_MANIFEST_PAYLOAD","Expected pinned dbt semantic payload");return Ae(n)}function r9(e){let t=wDe(e);if(n9(e).diagnostics.some((n)=>n.code==="DBT_SEMANTIC_MANIFEST_REPRESENTATION"))throw new U("DBT_SEMANTIC_MANIFEST_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var i9={id:"umf.dbt.artifact",version:"0.1.0",coreVersion:"0.1.0",description:"Exact dbt run-results/catalog/freshness artifacts and native shape diagnostics",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:dbt:artifact:0.1.0",type:"object",properties:{profile:{const:"dbt-artifact-json"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-022 AC7–AC9; preserve exact artifact JSON independently of native schema validity; edits are reviewable metadata, not changed execution or warehouse state",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"dbt generated artifacts",version:"run-results v6, catalog v1, sources v3; dbt Core 1.10.0 fixtures",subset:"Exact JSON preservation and candidate edits; native schema shapes; no artifact correlation or execution guarantees"},evidence:["tests/dbt/artifact.test.ts","fixtures/dbt/artifacts/oracle-results.json","fixtures/dbt/artifacts/browser-results.json","tests/dbt/freshness.test.ts","fixtures/dbt/freshness/oracle-results.json","fixtures/dbt/freshness/browser-results.json","tests/dbt/failure.test.ts","fixtures/dbt/failure/provenance.json"]}};var s9={$schema:"https://json-schema.org/draft/2020-12/schema",type:"object",title:"RunResultsArtifact",properties:{metadata:{type:"object",title:"BaseArtifactMetadata",properties:{dbt_schema_version:{type:"string"},dbt_version:{type:"string",default:"1.11.6"},generated_at:{type:"string"},invocation_id:{anyOf:[{type:"string"},{type:"null"}]},invocation_started_at:{anyOf:[{type:"string"},{type:"null"}]},env:{type:"object",additionalProperties:{type:"string"},propertyNames:{type:"string"}}},additionalProperties:!1,required:["dbt_schema_version"]},results:{type:"array",items:{type:"object",title:"RunResultOutput",properties:{status:{anyOf:[{enum:["success","error","skipped","partial success","no-op"]},{enum:["pass","error","fail","warn","skipped"]},{enum:["pass","warn","error","runtime error"]}]},timing:{type:"array",items:{type:"object",title:"TimingInfo",properties:{name:{type:"string"},started_at:{anyOf:[{type:"string"},{type:"null"}],default:null},completed_at:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},thread_id:{type:"string"},execution_time:{type:"number"},adapter_response:{type:"object",propertyNames:{type:"string"}},message:{anyOf:[{type:"string"},{type:"null"}]},failures:{anyOf:[{type:"integer"},{type:"null"}]},unique_id:{type:"string"},compiled:{anyOf:[{type:"boolean"},{type:"null"}]},compiled_code:{anyOf:[{type:"string"},{type:"null"}]},relation_name:{anyOf:[{type:"string"},{type:"null"}]},batch_results:{anyOf:[{type:"object",title:"BatchResults",properties:{successful:{type:"array",items:{type:"array",prefixItems:[{type:"string"},{type:"string"}],maxItems:2,minItems:2}},failed:{type:"array",items:{type:"array",prefixItems:[{type:"string"},{type:"string"}],maxItems:2,minItems:2}}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["status","timing","thread_id","execution_time","adapter_response","message","failures","unique_id","compiled","compiled_code","relation_name"]}},elapsed_time:{type:"number"},args:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1,required:["metadata","results","elapsed_time"],$id:"https://schemas.getdbt.com/dbt/run-results/v6.json"};var o9={$schema:"https://json-schema.org/draft/2020-12/schema",type:"object",title:"FreshnessExecutionResultArtifact",properties:{metadata:{type:"object",title:"FreshnessMetadata",properties:{dbt_schema_version:{type:"string"},dbt_version:{type:"string",default:"1.11.6"},generated_at:{type:"string"},invocation_id:{anyOf:[{type:"string"},{type:"null"}]},invocation_started_at:{anyOf:[{type:"string"},{type:"null"}]},env:{type:"object",additionalProperties:{type:"string"},propertyNames:{type:"string"}}},additionalProperties:!1},results:{type:"array",items:{anyOf:[{type:"object",title:"SourceFreshnessRuntimeError",properties:{unique_id:{type:"string"},error:{anyOf:[{type:"string"},{type:"integer"},{type:"null"}]},status:{enum:["runtime error"]}},additionalProperties:!1,required:["unique_id","error","status"]},{type:"object",title:"SourceFreshnessOutput",properties:{unique_id:{type:"string"},max_loaded_at:{type:"string"},snapshotted_at:{type:"string"},max_loaded_at_time_ago_in_s:{type:"number"},status:{enum:["pass","warn","error","runtime error"]},criteria:{type:"object",title:"FreshnessThreshold",properties:{warn_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},error_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},filter:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},adapter_response:{type:"object",propertyNames:{type:"string"}},timing:{type:"array",items:{type:"object",title:"TimingInfo",properties:{name:{type:"string"},started_at:{anyOf:[{type:"string"},{type:"null"}],default:null},completed_at:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},thread_id:{type:"string"},execution_time:{type:"number"}},additionalProperties:!1,required:["unique_id","max_loaded_at","snapshotted_at","max_loaded_at_time_ago_in_s","status","criteria","adapter_response","timing","thread_id","execution_time"]}]}},elapsed_time:{type:"number"}},additionalProperties:!1,required:["metadata","results","elapsed_time"],$id:"https://schemas.getdbt.com/dbt/sources/v3.json"};var a9={$schema:"https://json-schema.org/draft/2020-12/schema",type:"object",title:"CatalogArtifact",properties:{metadata:{type:"object",title:"CatalogMetadata",properties:{dbt_schema_version:{type:"string"},dbt_version:{type:"string",default:"1.11.6"},generated_at:{type:"string"},invocation_id:{anyOf:[{type:"string"},{type:"null"}]},invocation_started_at:{anyOf:[{type:"string"},{type:"null"}]},env:{type:"object",additionalProperties:{type:"string"},propertyNames:{type:"string"}}},additionalProperties:!1},nodes:{type:"object",additionalProperties:{type:"object",title:"CatalogTable",properties:{metadata:{type:"object",title:"TableMetadata",properties:{type:{type:"string"},schema:{type:"string"},name:{type:"string"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},comment:{anyOf:[{type:"string"},{type:"null"}],default:null},owner:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["type","schema","name"]},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnMetadata",properties:{type:{type:"string"},index:{type:"integer"},name:{type:"string"},comment:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["type","index","name"]},propertyNames:{type:"string"}},stats:{type:"object",additionalProperties:{type:"object",title:"StatsItem",properties:{id:{type:"string"},label:{type:"string"},value:{anyOf:[{type:"boolean"},{type:"string"},{type:"number"},{type:"null"}]},include:{type:"boolean"},description:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["id","label","value","include"]},propertyNames:{type:"string"}},unique_id:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["metadata","columns","stats"]},propertyNames:{type:"string"}},sources:{type:"object",additionalProperties:{type:"object",title:"CatalogTable",properties:{metadata:{type:"object",title:"TableMetadata",properties:{type:{type:"string"},schema:{type:"string"},name:{type:"string"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},comment:{anyOf:[{type:"string"},{type:"null"}],default:null},owner:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["type","schema","name"]},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnMetadata",properties:{type:{type:"string"},index:{type:"integer"},name:{type:"string"},comment:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["type","index","name"]},propertyNames:{type:"string"}},stats:{type:"object",additionalProperties:{type:"object",title:"StatsItem",properties:{id:{type:"string"},label:{type:"string"},value:{anyOf:[{type:"boolean"},{type:"string"},{type:"number"},{type:"null"}]},include:{type:"boolean"},description:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["id","label","value","include"]},propertyNames:{type:"string"}},unique_id:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["metadata","columns","stats"]},propertyNames:{type:"string"}},errors:{anyOf:[{type:"array",items:{type:"string"}},{type:"null"}],default:null},_compile_results:{anyOf:[{},{type:"null"}],default:null}},additionalProperties:!1,required:["metadata","nodes","sources"],$id:"https://schemas.getdbt.com/dbt/catalog/v1.json"};var l9="umf.dbt.artifact",kDe=i9,c9=new Map,u9={"https://schemas.getdbt.com/dbt/run-results/v6.json":s9,"https://schemas.getdbt.com/dbt/catalog/v1.json":a9,"https://schemas.getdbt.com/dbt/sources/v3.json":o9};function NDe(e){let t=e,n=[{code:"DBT_ARTIFACT_CONTEXT",path:"",severity:"warning",message:"Native shapes do not establish execution outcomes, warehouse state, artifact correlation, format constraints or exact-number constraints beyond JS precision"}],r=(l,c,u,p="warning")=>n.push({code:l,path:c,message:u,severity:p});if(Object.keys(t).some((l)=>!["profile","root"].includes(l)))r("DBT_ARTIFACT_REPRESENTATION","","Unknown representation fields remain in UMF");function i(l,c){let u=l.kind==="null"?["kind"]:l.kind==="array"?["kind","items"]:l.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(l).some((p)=>!u.includes(p)))r("DBT_ARTIFACT_REPRESENTATION",c,"Unknown tagged-tree fields remain in UMF");if(l.kind==="object")for(let[p,d]of Object.entries(l.members))i(d,c+"/"+Pe(p));if(l.kind==="array")l.items.forEach((p,d)=>i(p,c+"/"+d))}i(t.root,"");let s=t.root.kind==="object"?t.root.members.metadata:void 0,o=s?.kind==="object"?s.members.dbt_schema_version:void 0;if(o?.kind!=="string")return r("DBT_ARTIFACT_STRUCTURE","/metadata/dbt_schema_version","Expected artifact object with metadata object and schema version string","error"),n;if(!Object.hasOwn(u9,o.value))return r("DBT_ARTIFACT_VERSION","/metadata/dbt_schema_version","Unknown artifact version preserved without interpretation"),n;let a=c9.get(o.value);if(!a)a=mt(!1).compile(u9[o.value]),c9.set(o.value,a);if(!a(JSON.parse(Be(t.root))))for(let l of(a.errors??[]).slice(0,100))r("DBT_ARTIFACT_NATIVE_SCHEMA",l.instancePath,l.message??"Native grammar mismatch");if((a.errors?.length??0)>100)r("DBT_ARTIFACT_DIAGNOSTICS_TRUNCATED","","More than 100 native schema diagnostics; first 100 retained");return n}function ODe(){return new nt().register(kDe,NDe)}function p9(e){return We(e,ODe())}function PDe(e){let t=p9(e);if(!t.valid)throw new U("DBT_ARTIFACT_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="artifact")?.elements.find((r)=>r.id==="artifact")?.extensions[l9];if(!n||e.vocabularies[l9]?.version!=="0.1.0")throw new U("DBT_ARTIFACT_PAYLOAD","Expected pinned dbt artifact payload");return Ae(n)}function d9(e){let t=PDe(e);if(p9(e).diagnostics.some((n)=>n.code==="DBT_ARTIFACT_REPRESENTATION"))throw new U("DBT_ARTIFACT_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}await st();var BCe={type:"object",additionalProperties:!1,properties:{"output-file":{type:"string",nullable:!0,description:["Name of the output file."," Output file will interpolate the following values:"," - schema-name: Name of the schema if multiple",""," Default: `{schema-name}.graphql`",""," Example Single schema"," - `schema.graphql`",""," Example Multiple schemas"," - `Org1.Schema1.graphql`"," - `Org1.Schema2.graphql`"].join(` +phase in the SQL plan.`,type:"object",properties:{name:{title:"Name",type:"string"},filter:{anyOf:[{$ref:"#/definitions/PydanticWhereFilterIntersection"},{type:"null"}]},alias:{anyOf:[{title:"Alias",type:"string"},{type:"null"}]},join_to_timespine:{title:"Join To Timespine",default:!1,type:"boolean"},fill_nulls_with:{anyOf:[{title:"Fill Nulls With",type:"integer"},{type:"null"}]}},required:["name"]},PydanticMetricTimeWindow:{title:"PydanticMetricTimeWindow",description:"Describes the window of time the metric should be accumulated over, e.g., '1 day', '2 weeks', etc.",type:"object",properties:{count:{title:"Count",type:"integer"},granularity:{title:"Granularity",type:"string"}},required:["count","granularity"]},PydanticMetricInput:{title:"PydanticMetricInput",description:"Provides a pointer to a metric along with the additional properties used on that metric.",type:"object",properties:{name:{title:"Name",type:"string"},filter:{anyOf:[{$ref:"#/definitions/PydanticWhereFilterIntersection"},{type:"null"}]},alias:{anyOf:[{title:"Alias",type:"string"},{type:"null"}]},offset_window:{anyOf:[{$ref:"#/definitions/PydanticMetricTimeWindow"},{type:"null"}]},offset_to_grain:{anyOf:[{title:"Offset To Grain",type:"string"},{type:"null"}]}},required:["name"]},ConversionCalculationType:{title:"ConversionCalculationType",description:"Types of calculations for a conversion metric.",enum:["conversions","conversion_rate"]},PydanticConstantPropertyInput:{title:"PydanticConstantPropertyInput",description:"Input of a constant property used in conversion metrics.",type:"object",properties:{base_property:{title:"Base Property",type:"string"},conversion_property:{title:"Conversion Property",type:"string"}},required:["base_property","conversion_property"]},PydanticConversionTypeParams:{title:"PydanticConversionTypeParams",description:"Type params to provide context for conversion metrics properties.",type:"object",properties:{base_measure:{$ref:"#/definitions/PydanticMetricInputMeasure"},conversion_measure:{$ref:"#/definitions/PydanticMetricInputMeasure"},entity:{title:"Entity",type:"string"},calculation:{default:"conversion_rate",allOf:[{$ref:"#/definitions/ConversionCalculationType"}]},window:{anyOf:[{$ref:"#/definitions/PydanticMetricTimeWindow"},{type:"null"}]},constant_properties:{anyOf:[{title:"Constant Properties",type:"array",items:{$ref:"#/definitions/PydanticConstantPropertyInput"}},{type:"null"}]}},required:["base_measure","conversion_measure","entity"]},PeriodAggregation:{title:"PeriodAggregation",description:"Options for how to aggregate across a time period.",enum:["first","last","average"]},PydanticCumulativeTypeParams:{title:"PydanticCumulativeTypeParams",description:"Type params to provide context for cumulative metrics properties.",type:"object",properties:{window:{anyOf:[{$ref:"#/definitions/PydanticMetricTimeWindow"},{type:"null"}]},grain_to_date:{anyOf:[{title:"Grain To Date",type:"string"},{type:"null"}]},period_agg:{default:"first",allOf:[{$ref:"#/definitions/PeriodAggregation"}]}}},PydanticMetricTypeParams:{title:"PydanticMetricTypeParams",description:"Type params add additional context to certain metric types (the context depends on the metric type).",type:"object",properties:{measure:{anyOf:[{$ref:"#/definitions/PydanticMetricInputMeasure"},{type:"null"}]},numerator:{anyOf:[{$ref:"#/definitions/PydanticMetricInput"},{type:"null"}]},denominator:{anyOf:[{$ref:"#/definitions/PydanticMetricInput"},{type:"null"}]},expr:{anyOf:[{title:"Expr",type:"string"},{type:"null"}]},window:{anyOf:[{$ref:"#/definitions/PydanticMetricTimeWindow"},{type:"null"}]},grain_to_date:{anyOf:[{$ref:"#/definitions/TimeGranularity"},{type:"null"}]},metrics:{anyOf:[{title:"Metrics",type:"array",items:{$ref:"#/definitions/PydanticMetricInput"}},{type:"null"}]},conversion_type_params:{anyOf:[{$ref:"#/definitions/PydanticConversionTypeParams"},{type:"null"}]},cumulative_type_params:{anyOf:[{$ref:"#/definitions/PydanticCumulativeTypeParams"},{type:"null"}]},input_measures:{title:"Input Measures",type:"array",items:{$ref:"#/definitions/PydanticMetricInputMeasure"}}}},PydanticMetric:{title:"PydanticMetric",description:"Describes a metric.",type:"object",properties:{name:{title:"Name",type:"string"},description:{anyOf:[{title:"Description",type:"string"},{type:"null"}]},type:{$ref:"#/definitions/MetricType"},type_params:{$ref:"#/definitions/PydanticMetricTypeParams"},filter:{anyOf:[{$ref:"#/definitions/PydanticWhereFilterIntersection"},{type:"null"}]},metadata:{anyOf:[{$ref:"#/definitions/PydanticMetadata"},{type:"null"}]},label:{anyOf:[{title:"Label",type:"string"},{type:"null"}]},config:{anyOf:[{$ref:"#/definitions/PydanticSemanticLayerElementConfig"},{type:"null"}]},time_granularity:{anyOf:[{title:"Time Granularity",type:"string"},{type:"null"}]}},required:["name","type","type_params"]},PydanticTimeSpineTableConfiguration:{title:"PydanticTimeSpineTableConfiguration",description:"Legacy Pydantic implementation of SemanticVersion. In the process of deprecation.",type:"object",properties:{location:{title:"Location",type:"string"},column_name:{title:"Column Name",type:"string"},grain:{$ref:"#/definitions/TimeGranularity"}},required:["location","column_name","grain"]},PydanticSemanticVersion:{title:"PydanticSemanticVersion",description:"Pydantic implementation of SemanticVersion.",type:"object",properties:{major_version:{title:"Major Version",type:"string"},minor_version:{title:"Minor Version",type:"string"},patch_version:{anyOf:[{title:"Patch Version",type:"string"},{type:"null"}]}},required:["major_version","minor_version"]},PydanticTimeSpinePrimaryColumn:{title:"PydanticTimeSpinePrimaryColumn",description:"Extends BaseModel with a generic hash function.",type:"object",properties:{name:{title:"Name",type:"string"},time_granularity:{$ref:"#/definitions/TimeGranularity"}},required:["name","time_granularity"]},PydanticTimeSpineCustomGranularityColumn:{title:"PydanticTimeSpineCustomGranularityColumn",description:"Extends BaseModel with a generic hash function.",type:"object",properties:{name:{title:"Name",type:"string"},column_name:{anyOf:[{title:"Column Name",type:"string"},{type:"null"}]}},required:["name"]},PydanticTimeSpine:{title:"PydanticTimeSpine",description:"Extends BaseModel with a generic hash function.",type:"object",properties:{node_relation:{$ref:"#/definitions/PydanticNodeRelation"},primary_column:{$ref:"#/definitions/PydanticTimeSpinePrimaryColumn"},custom_granularities:{title:"Custom Granularities",type:"array",items:{$ref:"#/definitions/PydanticTimeSpineCustomGranularityColumn"}}},required:["node_relation","primary_column"]},PydanticProjectConfiguration:{title:"PydanticProjectConfiguration",description:"Pydantic implementation of ProjectConfiguration.",type:"object",properties:{time_spine_table_configurations:{title:"Time Spine Table Configurations",type:"array",items:{$ref:"#/definitions/PydanticTimeSpineTableConfiguration"}},metadata:{anyOf:[{$ref:"#/definitions/PydanticMetadata"},{type:"null"}]},dsi_package_version:{title:"Dsi Package Version",default:{major_version:"0",minor_version:"0",patch_version:"0"},allOf:[{$ref:"#/definitions/PydanticSemanticVersion"}]},time_spines:{title:"Time Spines",type:"array",items:{$ref:"#/definitions/PydanticTimeSpine"}}}},PydanticSavedQueryQueryParams:{title:"PydanticSavedQueryQueryParams",description:"Pydantic implementation of SavedQuery.",type:"object",properties:{metrics:{title:"Metrics",type:"array",items:{type:"string"}},group_by:{title:"Group By",type:"array",items:{type:"string"}},order_by:{title:"Order By",type:"array",items:{type:"string"}},limit:{anyOf:[{title:"Limit",type:"integer"},{type:"null"}]},where:{anyOf:[{$ref:"#/definitions/PydanticWhereFilterIntersection"},{type:"null"}]}},required:["metrics"]},ExportDestinationType:{title:"ExportDestinationType",description:"Types of destinations that exports can be written to.",enum:["table","view"]},PydanticExportConfig:{title:"PydanticExportConfig",description:'Pydantic implementation of ExportConfig.\n\nNote on `schema_name`: `schema` is an existing BaseModel attribute, so we need to alias it here.\n`Field.alias="schema"` enables using the `schema` key in YAML. `Config.allow_population_by_field_name`\nenables parsing for both `schema` and `schema_name` when deserializing from JSON.',type:"object",properties:{export_as:{$ref:"#/definitions/ExportDestinationType"},schema:{anyOf:[{title:"Schema",type:"string"},{type:"null"}]},alias:{anyOf:[{title:"Alias",type:"string"},{type:"null"}]}},required:["export_as"]},PydanticExport:{title:"PydanticExport",description:"Pydantic implementation of Export.",type:"object",properties:{name:{title:"Name",type:"string"},config:{$ref:"#/definitions/PydanticExportConfig"}},required:["name","config"]},PydanticSavedQuery:{title:"PydanticSavedQuery",description:"Pydantic implementation of SavedQuery.",type:"object",properties:{name:{title:"Name",type:"string"},query_params:{$ref:"#/definitions/PydanticSavedQueryQueryParams"},description:{anyOf:[{title:"Description",type:"string"},{type:"null"}]},metadata:{anyOf:[{$ref:"#/definitions/PydanticMetadata"},{type:"null"}]},label:{anyOf:[{title:"Label",type:"string"},{type:"null"}]},exports:{title:"Exports",type:"array",items:{$ref:"#/definitions/PydanticExport"}},tags:{title:"Tags",anyOf:[{type:"string"},{type:"array",items:{type:"string"}}]}},required:["name","query_params"]}},$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:dbt:semantic-manifest:dsi-0.8.5:serialized"};var e9="umf.dbt.semantic",_De=X4,t9=new Map;function xDe(e){let t=e,n=[{code:"DBT_SEMANTIC_MANIFEST_CONTEXT",path:"",severity:"warning",message:"Derived nullable shapes do not establish semantic rule validity, metric execution, joins, SQL semantics, parser coercion/defaults or exact-number constraints beyond JS precision"}],r=(c,u,p,d="warning")=>n.push({code:c,path:u,message:p,severity:d});if(Object.keys(t).some((c)=>!["profile","root"].includes(c)))r("DBT_SEMANTIC_MANIFEST_REPRESENTATION","","Unknown representation fields remain in UMF");function i(c,u){let p=c.kind==="null"?["kind"]:c.kind==="array"?["kind","items"]:c.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(c).some((d)=>!p.includes(d)))r("DBT_SEMANTIC_MANIFEST_REPRESENTATION",u,"Unknown tagged-tree fields remain in UMF");if(c.kind==="object")for(let[d,f]of Object.entries(c.members))i(f,u+"/"+$e(d));if(c.kind==="array")c.items.forEach((d,f)=>i(d,u+"/"+f))}if(i(t.root,""),t.root.kind!=="object")return r("DBT_SEMANTIC_MANIFEST_STRUCTURE","","Expected semantic manifest object","error"),n;let s=t.root.members.project_configuration,o=s?.kind==="object"?s.members.dsi_package_version:void 0;if(!(o?.kind==="object"&&["major_version","minor_version","patch_version"].every((c,u)=>{let p=o.members[c];return p?.kind==="string"&&p.value===["0","8","5"][u]})))return r("DBT_SEMANTIC_MANIFEST_VERSION","/project_configuration/dsi_package_version","Missing or unknown DSI version preserved without interpretation"),n;let l=t9.get("0.8.5");if(!l)l=mt(!1).compile(Z4),t9.set("0.8.5",l);if(!l(JSON.parse(Be(t.root))))for(let c of(l.errors??[]).slice(0,100))r("DBT_SEMANTIC_MANIFEST_NATIVE_SCHEMA",c.instancePath,c.message??"Derived serialized shape mismatch");if((l.errors?.length??0)>100)r("DBT_SEMANTIC_MANIFEST_DIAGNOSTICS_TRUNCATED","","More than 100 native schema diagnostics; first 100 retained");return n}function wDe(){return new nt().register(_De,xDe)}function n9(e){return We(e,wDe())}function DDe(e){let t=n9(e);if(!t.valid)throw new U("DBT_SEMANTIC_MANIFEST_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="semantic")?.elements.find((r)=>r.id==="semantic")?.extensions[e9];if(!n||e.vocabularies[e9]?.version!=="0.1.0")throw new U("DBT_SEMANTIC_MANIFEST_PAYLOAD","Expected pinned dbt semantic payload");return Ae(n)}function r9(e){let t=DDe(e);if(n9(e).diagnostics.some((n)=>n.code==="DBT_SEMANTIC_MANIFEST_REPRESENTATION"))throw new U("DBT_SEMANTIC_MANIFEST_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var i9={id:"umf.dbt.artifact",version:"0.1.0",coreVersion:"0.1.0",description:"Exact dbt run-results/catalog/freshness artifacts and native shape diagnostics",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:dbt:artifact:0.1.0",type:"object",properties:{profile:{const:"dbt-artifact-json"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-022 AC7–AC9; preserve exact artifact JSON independently of native schema validity; edits are reviewable metadata, not changed execution or warehouse state",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"dbt generated artifacts",version:"run-results v6, catalog v1, sources v3; dbt Core 1.10.0 fixtures",subset:"Exact JSON preservation and candidate edits; native schema shapes; no artifact correlation or execution guarantees"},evidence:["tests/dbt/artifact.test.ts","fixtures/dbt/artifacts/oracle-results.json","fixtures/dbt/artifacts/browser-results.json","tests/dbt/freshness.test.ts","fixtures/dbt/freshness/oracle-results.json","fixtures/dbt/freshness/browser-results.json","tests/dbt/failure.test.ts","fixtures/dbt/failure/provenance.json"]}};var s9={$schema:"https://json-schema.org/draft/2020-12/schema",type:"object",title:"RunResultsArtifact",properties:{metadata:{type:"object",title:"BaseArtifactMetadata",properties:{dbt_schema_version:{type:"string"},dbt_version:{type:"string",default:"1.11.6"},generated_at:{type:"string"},invocation_id:{anyOf:[{type:"string"},{type:"null"}]},invocation_started_at:{anyOf:[{type:"string"},{type:"null"}]},env:{type:"object",additionalProperties:{type:"string"},propertyNames:{type:"string"}}},additionalProperties:!1,required:["dbt_schema_version"]},results:{type:"array",items:{type:"object",title:"RunResultOutput",properties:{status:{anyOf:[{enum:["success","error","skipped","partial success","no-op"]},{enum:["pass","error","fail","warn","skipped"]},{enum:["pass","warn","error","runtime error"]}]},timing:{type:"array",items:{type:"object",title:"TimingInfo",properties:{name:{type:"string"},started_at:{anyOf:[{type:"string"},{type:"null"}],default:null},completed_at:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},thread_id:{type:"string"},execution_time:{type:"number"},adapter_response:{type:"object",propertyNames:{type:"string"}},message:{anyOf:[{type:"string"},{type:"null"}]},failures:{anyOf:[{type:"integer"},{type:"null"}]},unique_id:{type:"string"},compiled:{anyOf:[{type:"boolean"},{type:"null"}]},compiled_code:{anyOf:[{type:"string"},{type:"null"}]},relation_name:{anyOf:[{type:"string"},{type:"null"}]},batch_results:{anyOf:[{type:"object",title:"BatchResults",properties:{successful:{type:"array",items:{type:"array",prefixItems:[{type:"string"},{type:"string"}],maxItems:2,minItems:2}},failed:{type:"array",items:{type:"array",prefixItems:[{type:"string"},{type:"string"}],maxItems:2,minItems:2}}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["status","timing","thread_id","execution_time","adapter_response","message","failures","unique_id","compiled","compiled_code","relation_name"]}},elapsed_time:{type:"number"},args:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1,required:["metadata","results","elapsed_time"],$id:"https://schemas.getdbt.com/dbt/run-results/v6.json"};var o9={$schema:"https://json-schema.org/draft/2020-12/schema",type:"object",title:"FreshnessExecutionResultArtifact",properties:{metadata:{type:"object",title:"FreshnessMetadata",properties:{dbt_schema_version:{type:"string"},dbt_version:{type:"string",default:"1.11.6"},generated_at:{type:"string"},invocation_id:{anyOf:[{type:"string"},{type:"null"}]},invocation_started_at:{anyOf:[{type:"string"},{type:"null"}]},env:{type:"object",additionalProperties:{type:"string"},propertyNames:{type:"string"}}},additionalProperties:!1},results:{type:"array",items:{anyOf:[{type:"object",title:"SourceFreshnessRuntimeError",properties:{unique_id:{type:"string"},error:{anyOf:[{type:"string"},{type:"integer"},{type:"null"}]},status:{enum:["runtime error"]}},additionalProperties:!1,required:["unique_id","error","status"]},{type:"object",title:"SourceFreshnessOutput",properties:{unique_id:{type:"string"},max_loaded_at:{type:"string"},snapshotted_at:{type:"string"},max_loaded_at_time_ago_in_s:{type:"number"},status:{enum:["pass","warn","error","runtime error"]},criteria:{type:"object",title:"FreshnessThreshold",properties:{warn_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},error_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},filter:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},adapter_response:{type:"object",propertyNames:{type:"string"}},timing:{type:"array",items:{type:"object",title:"TimingInfo",properties:{name:{type:"string"},started_at:{anyOf:[{type:"string"},{type:"null"}],default:null},completed_at:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},thread_id:{type:"string"},execution_time:{type:"number"}},additionalProperties:!1,required:["unique_id","max_loaded_at","snapshotted_at","max_loaded_at_time_ago_in_s","status","criteria","adapter_response","timing","thread_id","execution_time"]}]}},elapsed_time:{type:"number"}},additionalProperties:!1,required:["metadata","results","elapsed_time"],$id:"https://schemas.getdbt.com/dbt/sources/v3.json"};var a9={$schema:"https://json-schema.org/draft/2020-12/schema",type:"object",title:"CatalogArtifact",properties:{metadata:{type:"object",title:"CatalogMetadata",properties:{dbt_schema_version:{type:"string"},dbt_version:{type:"string",default:"1.11.6"},generated_at:{type:"string"},invocation_id:{anyOf:[{type:"string"},{type:"null"}]},invocation_started_at:{anyOf:[{type:"string"},{type:"null"}]},env:{type:"object",additionalProperties:{type:"string"},propertyNames:{type:"string"}}},additionalProperties:!1},nodes:{type:"object",additionalProperties:{type:"object",title:"CatalogTable",properties:{metadata:{type:"object",title:"TableMetadata",properties:{type:{type:"string"},schema:{type:"string"},name:{type:"string"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},comment:{anyOf:[{type:"string"},{type:"null"}],default:null},owner:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["type","schema","name"]},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnMetadata",properties:{type:{type:"string"},index:{type:"integer"},name:{type:"string"},comment:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["type","index","name"]},propertyNames:{type:"string"}},stats:{type:"object",additionalProperties:{type:"object",title:"StatsItem",properties:{id:{type:"string"},label:{type:"string"},value:{anyOf:[{type:"boolean"},{type:"string"},{type:"number"},{type:"null"}]},include:{type:"boolean"},description:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["id","label","value","include"]},propertyNames:{type:"string"}},unique_id:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["metadata","columns","stats"]},propertyNames:{type:"string"}},sources:{type:"object",additionalProperties:{type:"object",title:"CatalogTable",properties:{metadata:{type:"object",title:"TableMetadata",properties:{type:{type:"string"},schema:{type:"string"},name:{type:"string"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},comment:{anyOf:[{type:"string"},{type:"null"}],default:null},owner:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["type","schema","name"]},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnMetadata",properties:{type:{type:"string"},index:{type:"integer"},name:{type:"string"},comment:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["type","index","name"]},propertyNames:{type:"string"}},stats:{type:"object",additionalProperties:{type:"object",title:"StatsItem",properties:{id:{type:"string"},label:{type:"string"},value:{anyOf:[{type:"boolean"},{type:"string"},{type:"number"},{type:"null"}]},include:{type:"boolean"},description:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["id","label","value","include"]},propertyNames:{type:"string"}},unique_id:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["metadata","columns","stats"]},propertyNames:{type:"string"}},errors:{anyOf:[{type:"array",items:{type:"string"}},{type:"null"}],default:null},_compile_results:{anyOf:[{},{type:"null"}],default:null}},additionalProperties:!1,required:["metadata","nodes","sources"],$id:"https://schemas.getdbt.com/dbt/catalog/v1.json"};var l9="umf.dbt.artifact",NDe=i9,c9=new Map,u9={"https://schemas.getdbt.com/dbt/run-results/v6.json":s9,"https://schemas.getdbt.com/dbt/catalog/v1.json":a9,"https://schemas.getdbt.com/dbt/sources/v3.json":o9};function ODe(e){let t=e,n=[{code:"DBT_ARTIFACT_CONTEXT",path:"",severity:"warning",message:"Native shapes do not establish execution outcomes, warehouse state, artifact correlation, format constraints or exact-number constraints beyond JS precision"}],r=(l,c,u,p="warning")=>n.push({code:l,path:c,message:u,severity:p});if(Object.keys(t).some((l)=>!["profile","root"].includes(l)))r("DBT_ARTIFACT_REPRESENTATION","","Unknown representation fields remain in UMF");function i(l,c){let u=l.kind==="null"?["kind"]:l.kind==="array"?["kind","items"]:l.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(l).some((p)=>!u.includes(p)))r("DBT_ARTIFACT_REPRESENTATION",c,"Unknown tagged-tree fields remain in UMF");if(l.kind==="object")for(let[p,d]of Object.entries(l.members))i(d,c+"/"+$e(p));if(l.kind==="array")l.items.forEach((p,d)=>i(p,c+"/"+d))}i(t.root,"");let s=t.root.kind==="object"?t.root.members.metadata:void 0,o=s?.kind==="object"?s.members.dbt_schema_version:void 0;if(o?.kind!=="string")return r("DBT_ARTIFACT_STRUCTURE","/metadata/dbt_schema_version","Expected artifact object with metadata object and schema version string","error"),n;if(!Object.hasOwn(u9,o.value))return r("DBT_ARTIFACT_VERSION","/metadata/dbt_schema_version","Unknown artifact version preserved without interpretation"),n;let a=c9.get(o.value);if(!a)a=mt(!1).compile(u9[o.value]),c9.set(o.value,a);if(!a(JSON.parse(Be(t.root))))for(let l of(a.errors??[]).slice(0,100))r("DBT_ARTIFACT_NATIVE_SCHEMA",l.instancePath,l.message??"Native grammar mismatch");if((a.errors?.length??0)>100)r("DBT_ARTIFACT_DIAGNOSTICS_TRUNCATED","","More than 100 native schema diagnostics; first 100 retained");return n}function PDe(){return new nt().register(NDe,ODe)}function p9(e){return We(e,PDe())}function $De(e){let t=p9(e);if(!t.valid)throw new U("DBT_ARTIFACT_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="artifact")?.elements.find((r)=>r.id==="artifact")?.extensions[l9];if(!n||e.vocabularies[l9]?.version!=="0.1.0")throw new U("DBT_ARTIFACT_PAYLOAD","Expected pinned dbt artifact payload");return Ae(n)}function d9(e){let t=$De(e);if(p9(e).diagnostics.some((n)=>n.code==="DBT_ARTIFACT_REPRESENTATION"))throw new U("DBT_ARTIFACT_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}await st();var VCe={type:"object",additionalProperties:!1,properties:{"output-file":{type:"string",nullable:!0,description:["Name of the output file."," Output file will interpolate the following values:"," - schema-name: Name of the schema if multiple",""," Default: `{schema-name}.graphql`",""," Example Single schema"," - `schema.graphql`",""," Example Multiple schemas"," - `Org1.Schema1.graphql`"," - `Org1.Schema2.graphql`"].join(` `)},"new-line":{type:"string",enum:["crlf","lf"],default:"lf",nullable:!0,description:"Set the newLine character for emitting files."},"omit-unreachable-types":{type:"boolean",nullable:!0,description:["Omit unreachable types.","By default all types declared under the schema namespace will be included.","With this flag on only types references in an operation will be emitted."].join(` -`)}},required:[]},VCe={name:"@typespec/graphql",diagnostics:{"graphql-operation-kind-duplicate":{severity:"error",messages:{default:M`GraphQL Operation Kind already applied to \`${"entityName"}\`.`}},"operation-field-conflict":{severity:"error",messages:{default:M`Operation \`${"operation"}\` conflicts with an existing ${"conflictType"} on model \`${"model"}\`.`}},"operation-field-duplicate":{severity:"warning",messages:{default:M`Operation \`${"operation"}\` is defined multiple times on \`${"model"}\`.`}},"invalid-interface":{severity:"error",messages:{default:M`All models used with \`@compose\` must be marked with \`@graphqlInterface\`, but ${"interface"} is not.`}},"circular-interface":{severity:"error",messages:{default:"An interface cannot implement itself."}},"missing-interface-property":{severity:"error",messages:{default:M`Model must contain property \`${"property"}\` from \`${"interface"}\` in order to implement it in GraphQL.`}},"incompatible-interface-property":{severity:"error",messages:{default:M`Property \`${"property"}\` is incompatible with \`${"interface"}\`.`}},"unrecognized-union":{severity:"error",messages:{default:"Unrecognized union construction. Union must be named, a return type, a model property, or an alias."}},"duplicate-union-variant":{severity:"warning",messages:{default:M`Union variant type "${"type"}" appears multiple times after flattening nested unions. Duplicate removed.`}},"empty-union":{severity:"error",messages:{default:"Union has no non-null variants. A GraphQL union must contain at least one member type."}},"graphql-builtin-scalar-collision":{severity:"warning",messages:{default:M`Scalar "${"name"}" collides with GraphQL built-in type "${"builtinName"}". This may cause unexpected behavior. Consider renaming the scalar.`}},"type-name-collision":{severity:"error",messages:{default:M`Type "${"name"}" collides with another type of the same name in the GraphQL schema. Consider renaming one of the types.`}},"operation-fields-ignored-on-input":{severity:"warning",messages:{default:M`@operationFields on \`${"model"}\` is ignored in input context — GraphQL input types cannot have operation fields.`}},"empty-schema":{severity:"warning",messages:{default:"GraphQL schema has no operations. At minimum a Query root type is required."}},"empty-enum":{severity:"error",messages:{default:M`Enum "${"name"}" must define at least one value. GraphQL enums cannot be empty.`}},"reserved-name":{severity:"error",messages:{default:M`Name "${"name"}" must not begin with "__" (two underscores), which is reserved by GraphQL for introspection.`}},"unsupported-type":{severity:"warning",messages:{default:M`Type "${"type"}" has no GraphQL equivalent. Using String as fallback.`}}},emitter:{options:BCe,capabilities:{dryRun:!0}},state:{operationKind:{description:"State for the graphql operation kind decorators (@query, @mutation, @subscription)"},operationFields:{description:"State for the @operationFields decorator."},compose:{description:"State for the @compose decorator."},interface:{description:"State for the @interface decorator."},interfaceOnly:{description:"State for @interface(#{interfaceOnly: true})."},schema:{description:"State for the @schema decorator."},specifiedBy:{description:"State for the @specifiedBy decorator."}}},wee=nr(VCe),{reportDiagnostic:fv,createDiagnostic:Hkt,stateKeys:Xo}=wee;Nn();await st();await st();var[n1t,r1t]=hr(Xo.interface),[i1t,s1t]=hr(Xo.interfaceOnly),[o1t,a1t,l1t]=ze(Xo.compose);Nn();await st();var[y1t,h1t,g1t]=ze(Xo.operationFields);It();vt();Fb();Xs();Nn();var[KCe,JCe,k1t]=ze(Xo.operationKind);function GCe(e,t){if(t.decorators.filter((r)=>zCe.includes(r.decorator)&&r.node?.kind===re.DecoratorExpression&&r.node?.parent===t.node).length>1)return fv(e.program,{code:"graphql-operation-kind-duplicate",format:{entityName:t.name},target:e.decoratorTarget}),!1;return!0}function HCe(e,t,n){if(GCe(e,t))JCe(e.program,t,n)}function LR(e){return(t,n)=>{HCe(t,n,e)}}var Dee=LR("Mutation"),Tee=LR("Query"),See=LR("Subscription"),zCe=[Dee,Tee,See];Nn();await st();var[I1t,A1t,R1t]=ze(Xo.schema);Nn();await st();var[L1t,q1t]=ze(Xo.specifiedBy);await st();Nn();await st();await st();var qR={type:"object",additionalProperties:!1,properties:{"file-type":{type:"string",enum:["yaml","json"],nullable:!0,description:"Serialize the schema as either yaml or json."},"int64-strategy":{type:"string",enum:["string","number"],nullable:!0,description:`How to handle 64 bit integers on the wire. Options are: +`)}},required:[]},KCe={name:"@typespec/graphql",diagnostics:{"graphql-operation-kind-duplicate":{severity:"error",messages:{default:M`GraphQL Operation Kind already applied to \`${"entityName"}\`.`}},"operation-field-conflict":{severity:"error",messages:{default:M`Operation \`${"operation"}\` conflicts with an existing ${"conflictType"} on model \`${"model"}\`.`}},"operation-field-duplicate":{severity:"warning",messages:{default:M`Operation \`${"operation"}\` is defined multiple times on \`${"model"}\`.`}},"invalid-interface":{severity:"error",messages:{default:M`All models used with \`@compose\` must be marked with \`@graphqlInterface\`, but ${"interface"} is not.`}},"circular-interface":{severity:"error",messages:{default:"An interface cannot implement itself."}},"missing-interface-property":{severity:"error",messages:{default:M`Model must contain property \`${"property"}\` from \`${"interface"}\` in order to implement it in GraphQL.`}},"incompatible-interface-property":{severity:"error",messages:{default:M`Property \`${"property"}\` is incompatible with \`${"interface"}\`.`}},"unrecognized-union":{severity:"error",messages:{default:"Unrecognized union construction. Union must be named, a return type, a model property, or an alias."}},"duplicate-union-variant":{severity:"warning",messages:{default:M`Union variant type "${"type"}" appears multiple times after flattening nested unions. Duplicate removed.`}},"empty-union":{severity:"error",messages:{default:"Union has no non-null variants. A GraphQL union must contain at least one member type."}},"graphql-builtin-scalar-collision":{severity:"warning",messages:{default:M`Scalar "${"name"}" collides with GraphQL built-in type "${"builtinName"}". This may cause unexpected behavior. Consider renaming the scalar.`}},"type-name-collision":{severity:"error",messages:{default:M`Type "${"name"}" collides with another type of the same name in the GraphQL schema. Consider renaming one of the types.`}},"operation-fields-ignored-on-input":{severity:"warning",messages:{default:M`@operationFields on \`${"model"}\` is ignored in input context — GraphQL input types cannot have operation fields.`}},"empty-schema":{severity:"warning",messages:{default:"GraphQL schema has no operations. At minimum a Query root type is required."}},"empty-enum":{severity:"error",messages:{default:M`Enum "${"name"}" must define at least one value. GraphQL enums cannot be empty.`}},"reserved-name":{severity:"error",messages:{default:M`Name "${"name"}" must not begin with "__" (two underscores), which is reserved by GraphQL for introspection.`}},"unsupported-type":{severity:"warning",messages:{default:M`Type "${"type"}" has no GraphQL equivalent. Using String as fallback.`}}},emitter:{options:VCe,capabilities:{dryRun:!0}},state:{operationKind:{description:"State for the graphql operation kind decorators (@query, @mutation, @subscription)"},operationFields:{description:"State for the @operationFields decorator."},compose:{description:"State for the @compose decorator."},interface:{description:"State for the @interface decorator."},interfaceOnly:{description:"State for @interface(#{interfaceOnly: true})."},schema:{description:"State for the @schema decorator."},specifiedBy:{description:"State for the @specifiedBy decorator."}}},wee=nr(KCe),{reportDiagnostic:fv,createDiagnostic:Wkt,stateKeys:Xo}=wee;Nn();await st();await st();var[i1t,s1t]=hr(Xo.interface),[o1t,a1t]=hr(Xo.interfaceOnly),[l1t,c1t,u1t]=ze(Xo.compose);Nn();await st();var[g1t,b1t,v1t]=ze(Xo.operationFields);It();_t();Fb();Zs();Nn();var[JCe,GCe,O1t]=ze(Xo.operationKind);function HCe(e,t){if(t.decorators.filter((r)=>WCe.includes(r.decorator)&&r.node?.kind===re.DecoratorExpression&&r.node?.parent===t.node).length>1)return fv(e.program,{code:"graphql-operation-kind-duplicate",format:{entityName:t.name},target:e.decoratorTarget}),!1;return!0}function zCe(e,t,n){if(HCe(e,t))GCe(e.program,t,n)}function LR(e){return(t,n)=>{zCe(t,n,e)}}var Dee=LR("Mutation"),Tee=LR("Query"),See=LR("Subscription"),WCe=[Dee,Tee,See];Nn();await st();var[R1t,j1t,F1t]=ze(Xo.schema);Nn();await st();var[U1t,B1t]=ze(Xo.specifiedBy);await st();Nn();await st();await st();var qR={type:"object",additionalProperties:!1,properties:{"file-type":{type:"string",enum:["yaml","json"],nullable:!0,description:"Serialize the schema as either yaml or json."},"int64-strategy":{type:"string",enum:["string","number"],nullable:!0,description:`How to handle 64 bit integers on the wire. Options are: * string: serialize as a string (widely interoperable) * number: serialize as a number (not widely interoperable)`},bundleId:{type:"string",nullable:!0,description:"When provided, bundle all the schemas into a single json schema document with schemas under $defs. The provided id is the id of the root document and is also used for the file name."},emitAllModels:{type:"boolean",nullable:!0,description:"When true, emit all model declarations to JSON Schema without requiring the @jsonSchema decorator."},emitAllRefs:{type:"boolean",nullable:!0,description:"When true, emit all references as json schema files, even if the referenced type does not have the `@jsonSchema` decorator or is not within a namespace with the `@jsonSchema` decorator."},"seal-object-schemas":{type:"boolean",nullable:!0,default:!1,description:["If true, then for models emitted as object schemas we default `unevaluatedProperties` to `{ not: {} }`,","if not explicitly specified elsewhere.","Default: `false`"].join(` `)},"polymorphic-models-strategy":{type:"string",enum:["ignore","oneOf","anyOf"],nullable:!0,default:"ignore",description:["Strategy for emitting models with the @discriminator decorator:","- ignore: Emit as regular object schema (default). Derived models use allOf to reference their base model.","- oneOf: Emit a oneOf schema with references to all derived models (closed union)","- anyOf: Emit an anyOf schema with references to all derived models (open union)","","When using oneOf or anyOf, derived models will inline all properties from their base model","instead of using allOf references. This avoids circular references in the generated schemas,","since the base model references derived models via oneOf/anyOf."].join(` -`)}},required:[]},KT=nr({name:"@typespec/json-schema",diagnostics:{"invalid-default":{severity:"error",messages:{default:M`Invalid type '${"type"}' for a default value`}},"duplicate-id":{severity:"error",messages:{default:M`There are multiple types with the same id "${"id"}".`}},"unknown-scalar":{severity:"warning",messages:{default:M`Scalar '${"name"}' is not a known scalar type and doesn't extend a known scalar type.`}}},emitter:{options:qR},state:{JsonSchema:{description:"State indexing types marked with @jsonSchema"},"JsonSchema.baseURI":{description:"Contains data configured with @baseUri decorator"},"JsonSchema.multipleOf":{description:"Contains data configured with @multipleOf decorator"},"JsonSchema.id":{description:"Contains data configured with @id decorator"},"JsonSchema.oneOf":{description:"Contains data configured with @oneOf decorator"},"JsonSchema.contains":{description:"Contains data configured with @contains decorator"},"JsonSchema.minContains":{description:"Contains data configured with @minContains decorator"},"JsonSchema.maxContains":{description:"Contains data configured with @maxContains decorator"},"JsonSchema.uniqueItems":{description:"Contains data configured with @uniqueItems decorator"},"JsonSchema.minProperties":{description:"Contains data configured with @minProperties decorator"},"JsonSchema.maxProperties":{description:"Contains data configured with @maxProperties decorator"},"JsonSchema.contentEncoding":{description:"Contains data configured with @contentEncoding decorator"},"JsonSchema.contentSchema":{description:"Contains data configured with @contentSchema decorator"},"JsonSchema.contentMediaType":{description:"Contains data configured with @contentMediaType decorator"},"JsonSchema.prefixItems":{description:"Contains data configured with @prefixItems decorator"},"JsonSchema.extension":{description:"Contains data configured with @extension decorator"}}}),UR=V$({}),{reportDiagnostic:QCe,createStateSymbol:lNt,stateKeys:gi}=KT;Nn();await st();function Zo(e,t){let[n,r]=ze(e);return[n,r,(...s)=>{if(t&&!t(...s))return;let[o,a,l]=s;r(o.program,a,l)}]}var[YCe,gNt]=hr(gi.JsonSchema);var[XCe,bNt,Eee]=Zo(gi["JsonSchema.baseURI"]);var[ZCe,vNt,kee]=Zo(gi["JsonSchema.multipleOf"]);var[Nee,_Nt,Oee]=Zo(gi["JsonSchema.id"]),[Pee,xNt]=hr(gi["JsonSchema.oneOf"]);var[$ee,wNt,Iee]=Zo(gi["JsonSchema.contains"]),[Aee,DNt,Ree]=Zo(gi["JsonSchema.minContains"]),[jee,TNt,Fee]=Zo(gi["JsonSchema.maxContains"]),[Cee,SNt]=ze(gi["JsonSchema.uniqueItems"]);var[Mee,ENt,Lee]=Zo(gi["JsonSchema.minProperties"]),[qee,kNt,Uee]=Zo(gi["JsonSchema.maxProperties"]),[Bee,NNt,Vee]=Zo(gi["JsonSchema.contentEncoding"]),[Kee,ONt,Jee]=Zo(gi["JsonSchema.contentMediaType"]),[Gee,PNt,Hee]=Zo(gi["JsonSchema.contentSchema"]),[zee,$Nt]=ze(gi["JsonSchema.prefixItems"]);var[INt,ANt,RNt]=ze(gi["JsonSchema.extension"]);var Wee=(e,t,n)=>{let[r,i]=xw(n,t);if(i.length>0)e.program.reportDiagnostics(i)};zd("Private",Wee);await st();var MNt=Symbol("$scalar"),LNt=Symbol("$ref"),qNt=Symbol("$map");var mv;(function(e){e[e.Duplex=3]="Duplex",e[e.In=2]="In",e[e.Out=1]="Out",e[e.None=0]="None"})(mv||(mv={}));await st();var oMe={type:"object",additionalProperties:!1,properties:{noEmit:{type:"boolean",nullable:!0,description:"If set to `true`, this emitter will not write any files. It will still validate the TypeSpec sources to ensure they are compatible with Protobuf, but the files will simply not be written to the output directory."},"omit-unreachable-types":{type:"boolean",nullable:!0,description:"By default, the emitter will create `message` declarations for any models in a namespace decorated with `@package` that have an `@field` decorator on every property. If this option is set to true, this behavior will be disabled, and only messages that are explicitly decorated with `@message` or that are reachable from a service operation will be emitted."}},required:[]},Qee="@typespec/protobuf",JT=nr({name:Qee,capabilities:{dryRun:!0},requireImports:[Qee],diagnostics:{"field-index":{severity:"error",messages:{missing:M`field ${"name"} does not have a field index, but one is required (try using the '@field' decorator)`,invalid:M`field index ${"index"} is invalid (must be an integer greater than zero)`,"out-of-bounds":M`field index ${"index"} is out of bounds (must be less than ${"max"})`,reserved:M`field index ${"index"} falls within the implementation-reserved range of 19000-19999 inclusive`,"user-reserved":M`field index ${"index"} was reserved by a call to @reserve on this model`,"user-reserved-range":M`field index ${"index"} falls within a range reserved by a call to @reserve on this model`}},"field-name":{severity:"error",messages:{"user-reserved":M`field name '${"name"}' was reserved by a call to @reserve on this model`}},"root-operation":{severity:"error",messages:{default:"operations in the root namespace are not supported (no associated Protobuf service)"}},"unsupported-intrinsic":{severity:"error",messages:{default:M`intrinsic type ${"name"} is not supported in Protobuf`}},"unsupported-return-type":{severity:"error",messages:{default:"Protobuf methods must return a named Model"}},"unsupported-input-type":{severity:"error",messages:{"wrong-number":"Protobuf methods must accept exactly one Model input (an empty model will do)","wrong-type":"Protobuf methods may only accept a named Model as an input",unconvertible:"input parameters cannot be converted to a Protobuf message"}},"unsupported-field-type":{severity:"error",messages:{unconvertible:M`cannot convert a ${"type"} to a protobuf type (only intrinsic types and models are supported)`,"unknown-intrinsic":M`no known protobuf scalar for intrinsic type ${"name"}`,"unknown-scalar":M`no known protobuf scalar for TypeSpec scalar type ${"name"}`,"recursive-map":"a protobuf map's 'value' type may not refer to another map",union:"a message field's type may not be a union"}},"optional-array-field":{severity:"warning",messages:{default:"optional array fields cannot preserve unset versus empty in protobuf; emitting a repeated field without the 'optional' label"}},"optional-map-field":{severity:"warning",messages:{default:"optional map fields cannot preserve unset versus empty in protobuf; emitting a map field without the 'optional' label"}},"namespace-collision":{severity:"error",messages:{default:M`the package name ${"name"} has already been used`}},"unconvertible-enum":{severity:"error",messages:{default:"enums must explicitly assign exactly one integer to each member to be used in a Protobuf message","no-zero-first":"the first variant of an enum must be set to zero to be used in a Protobuf message"}},"nested-array":{severity:"error",messages:{default:"nested arrays are not supported by the Protobuf emitter"}},"invalid-package-name":{severity:"error",messages:{default:M`${"name"} is not a valid package name (must consist of letters and numbers separated by ".")`}},"illegal-reservation":{severity:"error",messages:{default:"reservation value must be a string literal, uint32 literal, or a tuple of two uint32 literals denoting a range"}},"model-not-in-package":{severity:"error",messages:{default:M`model ${"name"} is not in a namespace that uses the '@Protobuf.package' decorator`}},"anonymous-model":{severity:"error",messages:{default:"anonymous models cannot be used in Protobuf messages"}},"unspeakable-template-argument":{severity:"error",messages:{default:M`template ${"name"} cannot be converted to a Protobuf message because it has an unspeakable argument (try using the '@friendlyName' decorator on the template)`}},package:{severity:"error",messages:{"disallowed-option-type":M`option '${"name"}' with type '${"type"}' is not allowed in a package declaration (only string, boolean, and numeric types are allowed)`}}},emitter:{options:oMe}}),Yee=new WeakMap;function aMe(e){let t=Yee.get(e);if(!t)t=new Map,Yee.set(e,t);return t}function lMe(e,t){let n=aMe(e),r=n.get(t);if(!r)r=new Set,n.set(t,r);return r}var Xee=Object.assign(JT.reportDiagnostic,{once:function(e,t){let n=lMe(e,t.target);if(n.has(t.code))return;n.add(t.code),JT.reportDiagnostic(e,t)}}),cMe=["fieldIndex","package","service","externRef","stream","reserve","message","_map"],Zee=Object.fromEntries(cMe.map((e)=>[e,JT.createStateSymbol(e)]));await st();await st();var ete={type:"string",enum:["parent-container","fqn","explicit-only"],default:"parent-container",description:["Determines how to generate operation IDs when `@operationId` is not used.","Avaliable options are:"," - `parent-container`: Uses the parent namespace and operation name to generate the ID."," - `fqn`: Uses the fully qualified name of the operation to generate the ID."," - `explicit-only`: Only use explicitly defined operation IDs."].join(` -`)},fMe={type:"object",additionalProperties:!1,properties:{"file-type":{type:["string","array"],nullable:!0,oneOf:[{type:"string",enum:["yaml","json"]},{type:"array",items:{type:"string",enum:["yaml","json"]},uniqueItems:!0,minItems:1}],description:"If the content should be serialized as YAML or JSON. Can be a single value or an array to emit multiple formats. Default 'yaml', if not specified infer from the `output-file` extension"},"output-file":{type:"string",nullable:!0,description:["Name of the output file."," Output file will interpolate the following values:"," - service-name: Name of the service"," - service-name-if-multiple: Name of the service if multiple"," - version: Version of the service if multiple"," - file-type: The file type being emitted (json or yaml). Useful when `file-type` is an array.","",' Default: `{service-name-if-multiple}.{version}.openapi.yaml` or `.json` if `file-type` is `"json"`'," When `file-type` is an array: `{service-name-if-multiple}.{version}.openapi.{file-type}`",""," Example Single service no versioning"," - `openapi.yaml`",""," Example Multiple services no versioning"," - `openapi.Org1.Service1.yaml`"," - `openapi.Org1.Service2.yaml`",""," Example Single service with versioning"," - `openapi.v1.yaml`"," - `openapi.v2.yaml`",""," Example Multiple service with versioning"," - `openapi.Org1.Service1.v1.yaml`"," - `openapi.Org1.Service1.v2.yaml`"," - `openapi.Org1.Service2.v1.0.yaml`"," - `openapi.Org1.Service2.v1.1.yaml` "].join(` +`)}},required:[]},KT=nr({name:"@typespec/json-schema",diagnostics:{"invalid-default":{severity:"error",messages:{default:M`Invalid type '${"type"}' for a default value`}},"duplicate-id":{severity:"error",messages:{default:M`There are multiple types with the same id "${"id"}".`}},"unknown-scalar":{severity:"warning",messages:{default:M`Scalar '${"name"}' is not a known scalar type and doesn't extend a known scalar type.`}}},emitter:{options:qR},state:{JsonSchema:{description:"State indexing types marked with @jsonSchema"},"JsonSchema.baseURI":{description:"Contains data configured with @baseUri decorator"},"JsonSchema.multipleOf":{description:"Contains data configured with @multipleOf decorator"},"JsonSchema.id":{description:"Contains data configured with @id decorator"},"JsonSchema.oneOf":{description:"Contains data configured with @oneOf decorator"},"JsonSchema.contains":{description:"Contains data configured with @contains decorator"},"JsonSchema.minContains":{description:"Contains data configured with @minContains decorator"},"JsonSchema.maxContains":{description:"Contains data configured with @maxContains decorator"},"JsonSchema.uniqueItems":{description:"Contains data configured with @uniqueItems decorator"},"JsonSchema.minProperties":{description:"Contains data configured with @minProperties decorator"},"JsonSchema.maxProperties":{description:"Contains data configured with @maxProperties decorator"},"JsonSchema.contentEncoding":{description:"Contains data configured with @contentEncoding decorator"},"JsonSchema.contentSchema":{description:"Contains data configured with @contentSchema decorator"},"JsonSchema.contentMediaType":{description:"Contains data configured with @contentMediaType decorator"},"JsonSchema.prefixItems":{description:"Contains data configured with @prefixItems decorator"},"JsonSchema.extension":{description:"Contains data configured with @extension decorator"}}}),UR=V$({}),{reportDiagnostic:YCe,createStateSymbol:uNt,stateKeys:bi}=KT;Nn();await st();function Zo(e,t){let[n,r]=ze(e);return[n,r,(...s)=>{if(t&&!t(...s))return;let[o,a,l]=s;r(o.program,a,l)}]}var[XCe,vNt]=hr(bi.JsonSchema);var[ZCe,_Nt,Eee]=Zo(bi["JsonSchema.baseURI"]);var[eMe,xNt,kee]=Zo(bi["JsonSchema.multipleOf"]);var[Nee,wNt,Oee]=Zo(bi["JsonSchema.id"]),[Pee,DNt]=hr(bi["JsonSchema.oneOf"]);var[$ee,TNt,Iee]=Zo(bi["JsonSchema.contains"]),[Aee,SNt,Ree]=Zo(bi["JsonSchema.minContains"]),[jee,ENt,Fee]=Zo(bi["JsonSchema.maxContains"]),[Cee,kNt]=ze(bi["JsonSchema.uniqueItems"]);var[Mee,NNt,Lee]=Zo(bi["JsonSchema.minProperties"]),[qee,ONt,Uee]=Zo(bi["JsonSchema.maxProperties"]),[Bee,PNt,Vee]=Zo(bi["JsonSchema.contentEncoding"]),[Kee,$Nt,Jee]=Zo(bi["JsonSchema.contentMediaType"]),[Gee,INt,Hee]=Zo(bi["JsonSchema.contentSchema"]),[zee,ANt]=ze(bi["JsonSchema.prefixItems"]);var[RNt,jNt,FNt]=ze(bi["JsonSchema.extension"]);var Wee=(e,t,n)=>{let[r,i]=xw(n,t);if(i.length>0)e.program.reportDiagnostics(i)};Qd("Private",Wee);await st();var qNt=Symbol("$scalar"),UNt=Symbol("$ref"),BNt=Symbol("$map");var mv;(function(e){e[e.Duplex=3]="Duplex",e[e.In=2]="In",e[e.Out=1]="Out",e[e.None=0]="None"})(mv||(mv={}));await st();var aMe={type:"object",additionalProperties:!1,properties:{noEmit:{type:"boolean",nullable:!0,description:"If set to `true`, this emitter will not write any files. It will still validate the TypeSpec sources to ensure they are compatible with Protobuf, but the files will simply not be written to the output directory."},"omit-unreachable-types":{type:"boolean",nullable:!0,description:"By default, the emitter will create `message` declarations for any models in a namespace decorated with `@package` that have an `@field` decorator on every property. If this option is set to true, this behavior will be disabled, and only messages that are explicitly decorated with `@message` or that are reachable from a service operation will be emitted."}},required:[]},Qee="@typespec/protobuf",JT=nr({name:Qee,capabilities:{dryRun:!0},requireImports:[Qee],diagnostics:{"field-index":{severity:"error",messages:{missing:M`field ${"name"} does not have a field index, but one is required (try using the '@field' decorator)`,invalid:M`field index ${"index"} is invalid (must be an integer greater than zero)`,"out-of-bounds":M`field index ${"index"} is out of bounds (must be less than ${"max"})`,reserved:M`field index ${"index"} falls within the implementation-reserved range of 19000-19999 inclusive`,"user-reserved":M`field index ${"index"} was reserved by a call to @reserve on this model`,"user-reserved-range":M`field index ${"index"} falls within a range reserved by a call to @reserve on this model`}},"field-name":{severity:"error",messages:{"user-reserved":M`field name '${"name"}' was reserved by a call to @reserve on this model`}},"root-operation":{severity:"error",messages:{default:"operations in the root namespace are not supported (no associated Protobuf service)"}},"unsupported-intrinsic":{severity:"error",messages:{default:M`intrinsic type ${"name"} is not supported in Protobuf`}},"unsupported-return-type":{severity:"error",messages:{default:"Protobuf methods must return a named Model"}},"unsupported-input-type":{severity:"error",messages:{"wrong-number":"Protobuf methods must accept exactly one Model input (an empty model will do)","wrong-type":"Protobuf methods may only accept a named Model as an input",unconvertible:"input parameters cannot be converted to a Protobuf message"}},"unsupported-field-type":{severity:"error",messages:{unconvertible:M`cannot convert a ${"type"} to a protobuf type (only intrinsic types and models are supported)`,"unknown-intrinsic":M`no known protobuf scalar for intrinsic type ${"name"}`,"unknown-scalar":M`no known protobuf scalar for TypeSpec scalar type ${"name"}`,"recursive-map":"a protobuf map's 'value' type may not refer to another map",union:"a message field's type may not be a union"}},"optional-array-field":{severity:"warning",messages:{default:"optional array fields cannot preserve unset versus empty in protobuf; emitting a repeated field without the 'optional' label"}},"optional-map-field":{severity:"warning",messages:{default:"optional map fields cannot preserve unset versus empty in protobuf; emitting a map field without the 'optional' label"}},"namespace-collision":{severity:"error",messages:{default:M`the package name ${"name"} has already been used`}},"unconvertible-enum":{severity:"error",messages:{default:"enums must explicitly assign exactly one integer to each member to be used in a Protobuf message","no-zero-first":"the first variant of an enum must be set to zero to be used in a Protobuf message"}},"nested-array":{severity:"error",messages:{default:"nested arrays are not supported by the Protobuf emitter"}},"invalid-package-name":{severity:"error",messages:{default:M`${"name"} is not a valid package name (must consist of letters and numbers separated by ".")`}},"illegal-reservation":{severity:"error",messages:{default:"reservation value must be a string literal, uint32 literal, or a tuple of two uint32 literals denoting a range"}},"model-not-in-package":{severity:"error",messages:{default:M`model ${"name"} is not in a namespace that uses the '@Protobuf.package' decorator`}},"anonymous-model":{severity:"error",messages:{default:"anonymous models cannot be used in Protobuf messages"}},"unspeakable-template-argument":{severity:"error",messages:{default:M`template ${"name"} cannot be converted to a Protobuf message because it has an unspeakable argument (try using the '@friendlyName' decorator on the template)`}},package:{severity:"error",messages:{"disallowed-option-type":M`option '${"name"}' with type '${"type"}' is not allowed in a package declaration (only string, boolean, and numeric types are allowed)`}}},emitter:{options:aMe}}),Yee=new WeakMap;function lMe(e){let t=Yee.get(e);if(!t)t=new Map,Yee.set(e,t);return t}function cMe(e,t){let n=lMe(e),r=n.get(t);if(!r)r=new Set,n.set(t,r);return r}var Xee=Object.assign(JT.reportDiagnostic,{once:function(e,t){let n=cMe(e,t.target);if(n.has(t.code))return;n.add(t.code),JT.reportDiagnostic(e,t)}}),uMe=["fieldIndex","package","service","externRef","stream","reserve","message","_map"],Zee=Object.fromEntries(uMe.map((e)=>[e,JT.createStateSymbol(e)]));await st();await st();var ete={type:"string",enum:["parent-container","fqn","explicit-only"],default:"parent-container",description:["Determines how to generate operation IDs when `@operationId` is not used.","Avaliable options are:"," - `parent-container`: Uses the parent namespace and operation name to generate the ID."," - `fqn`: Uses the fully qualified name of the operation to generate the ID."," - `explicit-only`: Only use explicitly defined operation IDs."].join(` +`)},mMe={type:"object",additionalProperties:!1,properties:{"file-type":{type:["string","array"],nullable:!0,oneOf:[{type:"string",enum:["yaml","json"]},{type:"array",items:{type:"string",enum:["yaml","json"]},uniqueItems:!0,minItems:1}],description:"If the content should be serialized as YAML or JSON. Can be a single value or an array to emit multiple formats. Default 'yaml', if not specified infer from the `output-file` extension"},"output-file":{type:"string",nullable:!0,description:["Name of the output file."," Output file will interpolate the following values:"," - service-name: Name of the service"," - service-name-if-multiple: Name of the service if multiple"," - version: Version of the service if multiple"," - file-type: The file type being emitted (json or yaml). Useful when `file-type` is an array.","",' Default: `{service-name-if-multiple}.{version}.openapi.yaml` or `.json` if `file-type` is `"json"`'," When `file-type` is an array: `{service-name-if-multiple}.{version}.openapi.{file-type}`",""," Example Single service no versioning"," - `openapi.yaml`",""," Example Multiple services no versioning"," - `openapi.Org1.Service1.yaml`"," - `openapi.Org1.Service2.yaml`",""," Example Single service with versioning"," - `openapi.v1.yaml`"," - `openapi.v2.yaml`",""," Example Multiple service with versioning"," - `openapi.Org1.Service1.v1.yaml`"," - `openapi.Org1.Service1.v2.yaml`"," - `openapi.Org1.Service2.v1.0.yaml`"," - `openapi.Org1.Service2.v1.1.yaml` "].join(` `)},"openapi-versions":{title:"OpenAPI Versions",type:"array",items:{type:"string",enum:["3.0.0","3.1.0","3.2.0"],nullable:!0,description:"The versions of OpenAPI to emit. Defaults to `[3.0.0]`"},nullable:!0,uniqueItems:!0,minItems:1,default:["3.0.0"]},"new-line":{type:"string",enum:["crlf","lf"],default:"lf",nullable:!0,description:"Set the newline character for emitting files."},"omit-unreachable-types":{type:"boolean",nullable:!0,description:`Omit unreachable types. By default all types declared under the service namespace will be included. With this flag on only types references in an operation will be emitted.`},"include-x-typespec-name":{type:"string",enum:["inline-only","never"],nullable:!0,default:"never",description:"If the generated openapi types should have the `x-typespec-name` extension set with the name of the TypeSpec type that created it.\nThis extension is meant for debugging and should not be depended on."},"safeint-strategy":{type:"string",enum:["double-int","int64"],nullable:!0,default:"int64",description:["How to handle safeint type. Options are:"," - `double-int`: Will produce `type: integer, format: double-int`"," - `int64`: Will produce `type: integer, format: int64`","","Default: `int64`"].join(` `)},"seal-object-schemas":{type:"boolean",nullable:!0,default:!1,description:["If true, then for models emitted as object schemas we default `additionalProperties` to false for","OpenAPI 3.0, and `unevaluatedProperties` to false for OpenAPI 3.1, if not explicitly specified elsewhere.","Default: `false`"].join(` `)},"experimental-parameter-examples":{type:"string",enum:["data","serialized"],nullable:!0,description:["Determines how to emit examples on parameters.","Note: This is an experimental feature and may change in future versions.","See https://spec.openapis.org/oas/v3.0.4.html#style-examples for parameter example serialization rules","See https://github.com/OAI/OpenAPI-Specification/discussions/4622 for discussion on handling parameter examples."].join(` `)},"operation-id-strategy":{oneOf:[ete,{type:"object",properties:{kind:ete,separator:{type:"string",nullable:!0,description:"Separator used to join segment in the operation name."}},required:["kind"]}]},"enum-strategy":{type:"string",enum:["default","annotated"],nullable:!0,default:"default",description:["How to emit TypeSpec enums and unions of literals. Options are:"," - `default`: Emit as a single schema using the `enum` keyword."," - `annotated`: Emit as a `oneOf` of `const` subschemas annotated with `title` and `description`"," from each member's/variant's `@summary` and `@doc`. Follows the OpenAPI 3.1.1 annotated enumerations pattern."," Only supported by OpenAPI 3.1.0 and above; on 3.0.0 the `default` style is used and a warning is reported."].join(` -`)}},required:[]},tte=nr({name:"@typespec/openapi3",capabilities:{dryRun:!0},diagnostics:{"oneof-union":{severity:"error",messages:{default:"@oneOf decorator can only be used on a union or a model property which type is a union."}},"inconsistent-shared-route-request-visibility":{severity:"error",messages:{default:"All operations with `@sharedRoutes` must have the same `@requestVisibility`."}},"invalid-server-variable":{severity:"error",docs:dl.fromPackageRoot("src/diagnostics/invalid-server-variable.md"),messages:{default:M`Server variable '${"propName"}' must be assignable to 'string'. It must either be a string, enum of string or union of strings.`}},"invalid-format":{severity:"warning",messages:{default:M`Collection format '${"value"}' is not supported in OpenAPI3 ${"paramType"} parameters. Defaulting to type 'string'.`}},"invalid-style":{severity:"warning",messages:{default:M`Style '${"style"}' is not supported in OpenAPI3 ${"paramType"} parameters. Defaulting to style 'simple'.`,optionalPath:M`Style '${"style"}' is not supported in OpenAPI3 ${"paramType"} parameters. The style ${"style"} could be introduced by an optional parameter. Defaulting to style 'simple'.`}},"path-reserved-expansion":{severity:"warning",messages:{default:"Reserved expansion of path parameter with '+' operator #{allowReserved: true} is not supported in OpenAPI3."}},"resource-namespace":{severity:"error",messages:{default:"Resource goes on namespace"}},"path-query":{severity:"error",docs:dl.fromPackageRoot("src/diagnostics/path-query.md"),messages:{default:"OpenAPI does not allow paths containing a query string."}},"duplicate-header":{severity:"error",docs:dl.fromPackageRoot("src/diagnostics/duplicate-header.md"),messages:{default:M`The header ${"header"} is defined across multiple content types`}},"status-code-in-default-response":{severity:"error",messages:{default:"a default response should not have an explicit status code"}},"invalid-schema":{severity:"error",docs:dl.fromPackageRoot("src/diagnostics/invalid-schema.md"),messages:{default:M`Couldn't get schema for type ${"type"}`}},"union-null":{severity:"error",docs:dl.fromPackageRoot("src/diagnostics/union-null.md"),messages:{default:"Cannot have a union containing only null types."}},"empty-union":{severity:"error",messages:{default:"Empty unions are not supported for OpenAPI v3 - enums must have at least one value."}},"empty-enum":{severity:"error",messages:{default:"Empty enums are not supported for OpenAPI v3 - enums must have at least one value."}},"enum-unique-type":{severity:"error",messages:{default:"Enums are not supported unless all options are literals of the same type."}},"inline-cycle":{severity:"error",docs:dl.fromPackageRoot("src/diagnostics/inline-cycle.md"),messages:{default:M`Cycle detected in '${"type"}'. Use @friendlyName decorator to assign an OpenAPI definition name and make it non-inline.`}},"unsupported-status-code-range":{severity:"error",messages:{default:M`Status code range '${"start"} to '${"end"}' is not supported. OpenAPI 3.0 can only represent range 1XX, 2XX, 3XX, 4XX and 5XX. Example: \`@minValue(400) @maxValue(499)\` for 4XX.`}},"invalid-model-property":{severity:"error",messages:{default:M`'${"type"}' cannot be specified as a model property.`}},"unsupported-auth":{severity:"warning",messages:{default:M`Authentication "${"authType"}" is not a known authentication by the openapi3 emitter, it will be ignored.`}},"xml-attribute-invalid-property-type":{severity:"warning",messages:{default:M`XML \`@attribute\` can only be primitive types in the OpenAPI 3 emitter, Property '${"name"}' type will be changed to type: string.`}},"xml-unwrapped-invalid-property-type":{severity:"warning",messages:{default:M`XML \`@unwrapped\` can only used on array properties or primitive ones in the OpenAPI 3 emitter, Property '${"name"}' will be ignored.`}},"invalid-component-fixed-field-key":{severity:"warning",messages:{default:M`Invalid key '${"value"}' used in a fixed field of the Component object. Only alphanumerics, dot (.), hyphen (-), and underscore (_) characters are allowed in keys.`}},"streams-not-supported":{severity:"warning",messages:{default:"Streams with itemSchema are only fully supported in OpenAPI 3.2.0 or above. The response will be emitted without itemSchema. Consider using OpenAPI 3.2.0 for full stream support."}},"default-not-supported":{severity:"warning",messages:{default:M`Default value is not supported in OpenAPI 3.0 ${"message"}`}},"enum-strategy-not-supported":{severity:"warning",messages:{default:"`enum-strategy: annotated` is only supported for OpenAPI 3.1.0 and above. The default enum strategy will be used for OpenAPI 3.0.0."}}},emitter:{options:fMe}}),{createDiagnostic:wOt,reportDiagnostic:mMe,createStateSymbol:BR}=tte;var SOt=BR("refs");var EOt=BR("oneOf");Nn();await st();var nte=nr({name:"@typespec/sse",diagnostics:{"terminal-event-not-in-events":{severity:"error",messages:{default:"A field marked as '@terminalEvent' must be a member of a type decorated with '@TypeSpec.Events.events'."}},"sse-stream-union-not-events":{severity:"error",messages:{default:"SSEStream type parameter must be a union decorated with '@TypeSpec.Events.events'."}}},state:{terminalEvent:{description:"State for the @terminalEvent decorator."}}}),{reportDiagnostic:hMe,createDiagnostic:AOt,stateKeys:VR}=nte;var[COt,MOt]=hr(VR.terminalEvent);await st();await st();var KR=nr({name:"@typespec/events",diagnostics:{"invalid-content-type-target":{severity:"error",messages:{default:"@contentType can only be specified on the top-level event envelope, or the event payload marked with @data"}},"multiple-event-payloads":{severity:"error",messages:{default:M`Event payload already applied to ${"dataPath"} but also exists under ${"currentPath"}`,payloadInIndexedModel:M`Event payload applied from inside a Record or Array at ${"dataPath"}`}}},state:{events:{description:"State for the @events decorator."},contentType:{description:"State for the @contentType decorator."},data:{description:"State for the @data decorator."}}}),{reportDiagnostic:UOt,createDiagnostic:gMe,stateKeys:yv}=KR;Nn();await st();var[rte,GOt]=hr(yv.events);var[ite,HOt]=ze(yv.contentType);var[ste,zOt]=hr(yv.data);await st();Nn();await st();Nn();await st();var JR=nr({name:"@typespec/http",diagnostics:{"http-verb-duplicate":{severity:"error",messages:{default:M`HTTP verb already applied to ${"entityName"}`}},"missing-uri-param":{severity:"error",messages:{default:M`Route reference parameter '${"param"}' but wasn't found in operation parameters`}},"incompatible-uri-param":{severity:"error",messages:{default:M`Parameter '${"param"}' is defined in the uri as a ${"uriKind"} but is annotated as a ${"annotationKind"}.`}},"use-uri-template":{severity:"error",messages:{default:M`Parameter '${"param"}' is already defined in the uri template. Explode, style and allowReserved property must be defined in the uri template as described by RFC 6570.`}},"double-slash":{severity:"warning",messages:{default:M`Route will result in duplicate slashes as parameter '${"paramName"}' use path expansion and is prefixed with a /`,optionalUnset:M`Route will result in duplicate slashes when optional parameter '${"paramName"}' is not set.`,optionalSet:M`Route will result in duplicate slashes when optional parameter '${"paramName"}' is set.`}},"missing-server-param":{severity:"error",messages:{default:M`Server url contains parameter '${"param"}' but wasn't found in given parameters`}},"duplicate-body":{severity:"error",messages:{default:"Operation has multiple @body parameters declared",duplicateUnannotated:"Operation has multiple unannotated parameters. There can only be one representing the body",bodyAndUnannotated:"Operation has a @body and an unannotated parameter. There can only be one representing the body"}},"duplicate-route-decorator":{severity:"error",messages:{namespace:"@route was defined twice on this namespace and has different values."}},"operation-param-duplicate-type":{severity:"error",messages:{default:M`Param ${"paramName"} has multiple types: [${"types"}]`}},"duplicate-operation":{severity:"error",messages:{default:M`Duplicate operation "${"operationName"}" routed at "${"verb"} ${"path"}".`}},"multiple-status-codes":{severity:"error",messages:{default:"Multiple `@statusCode` decorators defined for this operation response."}},"status-code-invalid":{severity:"error",messages:{default:"statusCode value must be a numeric or string literal or union of numeric or string literals",value:"statusCode value must be a three digit code between 100 and 599"}},"content-type-string":{severity:"error",messages:{default:"contentType parameter must be a string literal or union of string literals"}},"content-type-ignored":{severity:"warning",messages:{default:"`Content-Type` header ignored because there is no body."}},"metadata-ignored":{severity:"warning",messages:{default:M`${"kind"} property will be ignored as it is inside of a @body property. Use @bodyRoot instead if wanting to mix.`}},"response-cookie-not-supported":{severity:"warning",messages:{default:M`@cookie on response is not supported. Property '${"propName"}' will be ignored in the body. If you need 'Set-Cookie', use @header instead.`}},"no-service-found":{severity:"warning",messages:{default:M`No namespace with '@service' was found, but Namespace '${"namespace"}' contains routes. Did you mean to annotate this with '@service'?`}},"invalid-type-for-auth":{severity:"error",messages:{default:M`@useAuth ${"kind"} only accept Auth model, Tuple of auth model or union of auth model.`}},"shared-inconsistency":{severity:"error",messages:{default:M`Each operation routed at "${"verb"} ${"path"}" needs to have the @sharedRoute decorator.`}},"multipart-invalid-content-type":{severity:"error",messages:{default:M`Content type '${"contentType"}' is not a multipart content type. Supported content types are: ${"supportedContentTypes"}.`}},"multipart-model":{severity:"error",messages:{default:"Multipart request body must be a model or a tuple of http parts."}},"no-implicit-multipart":{severity:"error",messages:{default:"Using multipart payloads requires the use of @multipartBody and HttpPart models."}},"multipart-part":{severity:"error",messages:{default:"Expect item to be an HttpPart model."}},"multipart-nested":{severity:"error",messages:{default:"Cannot use @multipartBody inside of an HttpPart"}},"http-file-extra-property":{severity:"error",messages:{default:M`File model cannot define extra properties. Found '${"propName"}'.`}},"http-file-disallowed-metadata":{severity:"error",messages:{default:M`File model cannot define HTTP metadata type '${"metadataType"}' on property '${"propName"}'.`}},"formdata-no-part-name":{severity:"error",messages:{default:"Part used in multipart/form-data must have a name."}},"http-file-structured":{severity:"warning",messages:{default:M`HTTP File body is serialized as a structured model in '${"contentTypes"}' instead of being treated as the contents of a file because an explicit Content-Type header is defined. Override the \`contentType\` property of the file model to declare the internal media type of the file's contents, or suppress this warning if you intend to serialize the File as a model.`,union:"An HTTP File in a union is serialized as a structured model instead of being treated as the contents of a file. Declare a separate operation using `@sharedRoute` that has only the File model as the body type to treat it as a file, or suppress this warning if you intend to serialize the File as a model."}},"http-file-content-type-not-string":{severity:"error",messages:{default:M`The 'contentType' property of the file model must be 'TypeSpec.string', a string literal, or a union of string literals. Found '${"type"}'.`}},"http-file-contents-not-scalar":{severity:"error",messages:{default:M`The 'contents' property of the file model must be a scalar type that extends 'string' or 'bytes'. Found '${"type"}'.`}},"deprecated-implicit-optionality":{severity:"warning",messages:{default:"The implicitOptionality option is deprecated. To preserve previous behavior, use an explicit patch model with optional properties. For actual merge-patch semantics, use MergePatchUpdate for the @body type."}},"merge-patch-contains-null":{severity:"error",messages:{default:"Cannot convert model to a merge-patch compatible shape because it contains the 'null' intrinsic type."}},"merge-patch-content-type":{severity:"warning",messages:{default:M`The content-type of a request using a merge-patch template should be 'application/merge-patch+json' detected a header with content-type '${"contentType"}'.`}},"merge-patch-contains-metadata":{severity:"error",messages:{default:M`The MergePatch transform does not operate on http envelope metadata. Remove any http metadata decorators ('@query', '@header', '@path', '@cookie', '@statusCode') from the model passed to the MergePatch template. Found '${"metadataType"}' decorating property '${"propertyName"}'`}}},state:{authentication:{description:"State for the @auth decorator"},header:{description:"State for the @header decorator"},cookie:{description:"State for the @cookie decorator"},query:{description:"State for the @query decorator"},path:{description:"State for the @path decorator"},body:{description:"State for the @body decorator"},bodyRoot:{description:"State for the @bodyRoot decorator"},bodyIgnore:{description:"State for the @bodyIgnore decorator"},multipartBody:{description:"State for the @bodyIgnore decorator"},statusCode:{description:"State for the @statusCode decorator"},verbs:{description:"State for the verb decorators (@get, @post, @put, etc.)"},patchOptions:{description:"State for the options of the @patch decorator"},servers:{description:"State for the @server decorator"},includeInapplicableMetadataInPayload:{description:"State for the @includeInapplicableMetadataInPayload decorator"},externalInterfaces:{},routeProducer:{},routes:{},sharedRoutes:{description:"State for the @sharedRoute decorator"},routeOptions:{},file:{description:"State for the @Private.file decorator"},httpPart:{description:"State for the @Private.httpPart decorator"},mergePatchModel:{description:"State marking mergePatch models "},mergePatchProperty:{description:"State marking merge path model property source"},mergePatchPropertyOptions:{description:"Override options for a property in a merge patch transform"}}}),{reportDiagnostic:Is,createDiagnostic:In,stateKeys:Qt}=JR;ka();await st();function ky(e){return[[],[In({code:"status-code-invalid",target:e,messageId:"value"})]]}function xMe(e,t){let n=typeof e==="string"?parseInt(e,10):e;if(isNaN(n))return ky(t);if(!Number.isInteger(n))return ky(t);if(n<100||n>599)return ky(t);return[[n],[]]}function GT(e,t,n){switch(t.kind){case"String":case"Number":return xMe(t.value,n);case"Union":let r=Ct(),i=[...t.variants.values()].flatMap((s)=>r.pipe(GT(e,s.type,n)));return r.wrap(i);case"Scalar":return ote(e,t,t,n);case"ModelProperty":if(t.type.kind==="Scalar")return ote(e,t,t.type,n);else return GT(e,t.type,n);default:return ky(n)}}function ote(e,t,n,r){if(!DMe(e,n))return ky(r);let i=GR(e,t,r);if(wMe(i))return[[i],[]];else return ky(r)}function wMe(e){return e.start!==void 0&&e.end!==void 0}function GR(e,t,n){let r=Rm(e,t),i=Fm(e,t),s={};if(t.kind==="ModelProperty"&&(t.type.kind==="Scalar"||t.type.kind==="ModelProperty"))s=GR(e,t.type,n);else if(t.kind==="Scalar"&&t.baseScalar)s=GR(e,t.baseScalar,n);return{...s,start:r,end:i}}function DMe(e,t){let n=Kn(e);return n.type.isAssignableTo(t,n.builtin.int32,t)}function HT(e,t){return e.stateMap(Qt.header).get(t)}function hv(e,t){return e.stateMap(Qt.header).has(t)}function zT(e,t){return e.stateMap(Qt.cookie).get(t)}function gv(e,t){return e.stateMap(Qt.cookie).has(t)}var[bv,PPt]=ze(Qt.query);function lte(e){return{explode:e.explode??!1,name:e.name}}function vv(e,t){return e.stateMap(Qt.query).has(t)}var[Ny,$Pt]=ze(Qt.path);function cte(e){return{explode:e.explode??!1,allowReserved:e.allowReserved??!1,style:e.style??"simple",name:e.name}}function _v(e,t){return e.stateMap(Qt.path).has(t)}function xv(e,t){return e.stateSet(Qt.body).has(t)}function wv(e,t){return e.stateSet(Qt.bodyRoot).has(t)}function WT(e,t){return e.stateSet(Qt.bodyIgnore).has(t)}function Dv(e,t){return e.stateSet(Qt.multipartBody).has(t)}function Oc(e,t){return e.stateSet(Qt.statusCode).has(t)}function HR(e,t){return GT(e,t,t)}function zR(e){if(typeof e==="object")return ate(e.start,e.end);let t=typeof e==="string"?parseInt(e,10):e;switch(t){case 200:return"The request has succeeded.";case 201:return"The request has succeeded and a new resource has been created as a result.";case 202:return"The request has been accepted for processing, but processing has not yet completed.";case 204:return"There is no content to send for this request, but the headers may be useful. ";case 301:return"The URL of the requested resource has been changed permanently. The new URL is given in the response.";case 304:return"The client has made a conditional request and the resource has not been modified.";case 400:return"The server could not understand the request due to invalid syntax.";case 401:return"Access is unauthorized.";case 403:return"Access is forbidden.";case 404:return"The server cannot find the requested resource.";case 409:return"The request conflicts with the current state of the server.";case 412:return"Precondition failed.";case 503:return"Service unavailable."}return ate(t,t)}function ate(e,t){if(e>=100&&t<=199)return"Informational";else if(e>=200&&t<=299)return"Successful";else if(e>=300&&t<=399)return"Redirection";else if(e>=400&&t<=499)return"Client error";else if(e>=500&&t<=599)return"Server error";return}function TMe(e,t,n){SMe(e,t),e.program.stateMap(Qt.verbs).set(t,n)}function SMe(e,t){if(t.decorators.filter((r)=>PMe.includes(r.decorator)&&r.node?.kind===re.DecoratorExpression&&r.node?.parent===t.node).length>1)return Is(e.program,{code:"http-verb-duplicate",format:{entityName:t.name},target:e.decoratorTarget}),!1;return!0}function up(e,t){return e.stateMap(Qt.verbs).get(t)}function Oy(e){return(t,n)=>{TMe(t,n,e)}}var WR=Oy("get"),QR=Oy("put"),YR=Oy("post"),XR=Oy("delete"),ZR=Oy("head"),EMe=Oy("patch"),[kMe,NMe]=ze(Qt.patchOptions);function OMe(e,t){let n=e.decoratorTarget;if(t.interface!==void 0&&t.node!==void 0&&t.node.parent!==t.interface.node)return!1;if(t.sourceOperation!==void 0)return!1;if(n?.kind===re.DecoratorExpression&&n.parent){if(n.parent!==t.node)return!1}return!0}var ej=(e,t,n)=>{if(EMe(e,t),n){if(n.implicitOptionality===!0){if(OMe(e,t))Is(e.program,{code:"deprecated-implicit-optionality",target:t})}NMe(e.program,t,n)}};function tj(e,t){return kMe(e,t)}var PMe=[WR,ZR,YR,QR,ej,XR];function Py(e,t){return e.stateMap(Qt.authentication).get(t)}function nj(e,t){let n=Py(e,t);if(n)return n;if(t.interface!==void 0){let i=Py(e,t.interface);if(i)return i}let r=t.namespace;while(r){let i=Py(e,r);if(i)return i;r=r.namespace}return}await st();function Aa(e){let t=Ct();if(e.type.kind==="String")return[[e.type.value],[]];else if(e.type.kind==="Union"){let n=[];for(let r of e.type.variants.values())if(r.type.kind==="String")n.push(r.type.value);else{t.add(In({code:"content-type-string",target:e}));continue}return t.wrap(n)}else if(e.type.kind==="Scalar"&&e.type.name==="string")return[["*/*"],[]];return[[],[In({code:"content-type-string",target:e})]]}Nn();await st();Nn();var[$Me,UPt]=ze(Qt.sharedRoutes);function $y(e,t){return $Me(e,t)===!0}var[HPt,zPt]=ze(Qt.routes);await st();await st();await st();await st();Nn();await st();await st();function ute(e,t){return e.stateSet(Qt.file).has(t)}function pte(e,t){if(t.kind!=="Model")return!1;let n=t;while(n){if(ute(e,n))return!0;n=n.baseModel}return!1}function Tv(e,t,n){if(t.kind!=="Model")return;let r=Rd(t,"contentType"),i=Rd(t,"filename"),s=Rd(t,"contents");if(!r||!i||!s)return;if(!QT(e,r)||!QT(e,i)||!QT(e,s))return;let o=new Set(Zs(t));if(n){for(let a of o)if(!n(a))o.delete(a)}if(o.size!==3)return;return{contents:s,contentType:r,filename:i,type:t}}function QT(e,t){if(t.model?pte(e,t.model):!1)return!0;if(t.sourceProperty)return QT(e,t.sourceProperty);return!1}function rj(e,t){return e.stateMap(Qt.httpPart).get(t)}var An;(function(e){e[e.Read=1]="Read",e[e.Create=2]="Create",e[e.Update=4]="Update",e[e.Delete=8]="Delete",e[e.Query=16]="Query",e[e.None=0]="None",e[e.All=31]="All",e[e.Item=1048576]="Item",e[e.Patch=2097152]="Patch",e[e.Synthetic=3145728]="Synthetic"})(An||(An={}));function AMe(e,t){let n=Ea(e);if(Qe(!t.all,"Unexpected: `all` constraint in visibility filter passed to filterToVisibility"),Qe(!t.none,"Unexpected: `none` constraint in visibility filter passed to filterToVisibility"),!t.any)return An.All;else{let r=An.None;for(let i of t.any??[]){if(i.enum!==n)continue;switch(i.name){case"Read":r|=An.Read;break;case"Create":r|=An.Create;break;case"Update":r|=An.Update;break;case"Delete":r|=An.Delete;break;case"Query":r|=An.Query;break;default:Qe(!1,`Unreachable: unrecognized Lifecycle visibility member: '${i.name}'`)}}return r}}var dte=new WeakMap;function RMe(e){let t=dte.get(e);if(!t)t=new Map,dte.set(e,t);return t}function fte(e,t){if(t&=~An.Synthetic,t===An.All)return{};let n=RMe(e),r=n.get(t);if(!r){let i=Ea(e),s={Create:i.members.get("Create"),Read:i.members.get("Read"),Update:i.members.get("Update"),Delete:i.members.get("Delete"),Query:i.members.get("Query")},o=new Set;if(t&An.Read)o.add(s.Read);if(t&An.Create)o.add(s.Create);if(t&An.Update)o.add(s.Update);if(t&An.Delete)o.add(s.Delete);if(t&An.Query)o.add(s.Query);Qe(o.size>0||t===An.None,"invalid visibility"),r={any:o},n.set(t,r)}return r}function jMe(e){switch(e){case"get":case"head":return An.Query;case"post":return An.Create;case"put":return An.Create|An.Update;case"patch":return An.Update;case"delete":return An.Delete;default:Qe(!1,`Unreachable: unrecognized HTTP verb: '${e}'`)}}function mte(e){let t=typeof e==="string";return{parameters:(n,r)=>{let i=t?e:e?.verbSelector?.(n,r)??up(n,r);if(!i){let[{parameters:s}]=YT(n,r,void 0,{});i=s.verb}return fte(n,jMe(i))},returnType:(n,r)=>{let i=Ea(n).members.get("Read");return{any:new Set([i])}}}}function ij(e,t,n){let r=_P(e,t,mte(n)),i=AMe(e,r);if(n==="patch"){if(tj(e,t)?.implicitOptionality)i|=An.Patch}return i}function sj(e,t,n){return pc(e,t,fte(e,n))}await st();Nn();ka();Nn();await st();var[yte,hte]=ze(Qt.mergePatchModel),[oj,gte]=ze(Qt.mergePatchProperty),[bte,vte]=ze(Qt.mergePatchPropertyOptions);function aj(e,t){return yte(e,t)!==void 0}function _te(e,t){let n=new WeakMap;function r(i){if(n.has(i))return!1;if(n.set(t,!0),!Kn(e).model.is(i))return!1;if(aj(e,i))return!0;if(Kn(e).array.is(i)||Kn(e).record.is(i))return r(i.indexer.value);return!1}switch(t.kind){case"Model":return r(t)||t.sourceModels.some((i)=>r(i.model))||[...t.properties.values()].some((i)=>oj(e,i)!==void 0||r(i.type));case"ModelProperty":return r(t.type);case"Union":return[...t.variants.values()].some((i)=>r(i.type));case"UnionVariant":return r(t.type);case"Tuple":return t.values.some((i)=>r(i));default:return!1}}await st();function FMe(e,t,n,r={}){let i=[];function s(c){return[{...c,property:t,path:n},i]}let o={header:HT(e,t),cookie:zT(e,t),query:bv(e,t),path:Ny(e,t),body:xv(e,t),bodyRoot:wv(e,t),multipartBody:Dv(e,t),statusCode:Oc(e,t)},a=Object.entries(o).filter((c)=>!!c[1]),l=r.implicitParameter?.(t);if(l&&a.length>0)if(l.type==="path"&&o.path){if(o.path.explode!==void 0||o.path.style!==void 0||o.path.allowReserved!==void 0)i.push(In({code:"use-uri-template",format:{param:t.name},target:t}))}else if(l.type==="query"&&o.query){if(o.query.explode!==void 0)i.push(In({code:"use-uri-template",format:{param:t.name},target:t}))}else i.push(In({code:"incompatible-uri-param",format:{param:t.name,uriKind:l.type,annotationKind:a[0][0]},target:t}));if(l)return s({kind:l.type,options:l,property:t});if(a.length===0)return WT(e,t)?s({kind:"bodyIgnore"}):s({kind:"bodyProperty"});else if(a.length>1)i.push(In({code:"operation-param-duplicate-type",format:{paramName:t.name,types:a.map((c)=>c[0]).join(", ")},target:t}));if(o.header){if(o.header.name.toLowerCase()==="content-type"&&!r.treatContentTypeAsHeader)return s({kind:"contentType"});return s({kind:"header",options:o.header})}else if(o.cookie)return s({kind:"cookie",options:o.cookie});else if(o.query)return s({kind:"query",options:lte(o.query)});else if(o.path)return s({kind:"path",options:cte(o.path)});else if(o.statusCode)return s({kind:"statusCode"});else if(o.body)return s({kind:"body"});else if(o.bodyRoot)return s({kind:"bodyRoot"});else if(o.multipartBody)return s({kind:"multipartBody"});Qe(!1,"Unexpected http property type")}function xte(e,t,n,r,i={}){let s=Ct(),o=new Map;if(t.kind!=="Model"||t.properties.size===0&&!t.baseModel)return s.wrap([]);let a=new Set;function l(c,u){a.add(c);let p=!1,d=!1;for(let f of Zs(c)){let m=[...u,f.name];if(!sj(e,f,n))continue;let y=s.pipe(FMe(e,f,m,i));if(y.kind!=="bodyIgnore"&&MMe(y,r))y={kind:"bodyProperty",property:f,path:m};if(y.kind==="cookie"&&r===Vr.Response){s.add(In({code:"response-cookie-not-supported",target:f,format:{propName:f.name}}));continue}if(y.kind==="body"||y.kind==="bodyRoot"||y.kind==="multipartBody")p=!0;if(!(y.kind==="body"||y.kind==="multipartBody")&&CMe(f.type)&&!a.has(f.type)){if(l(f.type,m)){p=!0;continue}}if(y.kind==="bodyProperty")d=!0;if(y.kind!=="bodyIgnore")o.set(f,y)}return p&&!d}return l(t,[]),s.wrap([...o.values()])}function CMe(e){return e.kind==="Model"&&!e.indexer&&e.properties.size>0}function MMe(e,t){switch(t){case Vr.Request:return e.kind==="statusCode";case Vr.Response:return e.kind==="query"||e.kind==="path";case Vr.Multipart:return e.kind==="path"||e.kind==="query"||e.kind==="statusCode";default:return!1}}var Vr;(function(e){e[e.Request=0]="Request",e[e.Response=1]="Response",e[e.Multipart=2]="Multipart"})(Vr||(Vr={}));function Iy(e,t,n,r,i={}){let s=Ct(),o=s.pipe(xte(e,t,n,r,i)),a=s.pipe(LMe(e,t,o,n,r));if(a){if(a.contentTypes.some((l)=>l.startsWith("multipart/"))&&a.bodyKind!=="multipart")return s.add(In({code:"no-implicit-multipart",target:a.property??t})),s.wrap({body:void 0,metadata:o})}return s.wrap({body:a,metadata:o})}function LMe(e,t,n,r,i){let s=Ct(),o=n.find((u)=>u.kind==="contentType"),a=Tv(e,t,Ste(n));if(a!==void 0)if(!o)return s.join(Ete(a));else{let u=o&&s.pipe(Aa(o.property));Is(e,{code:"http-file-structured",format:{contentTypes:u.join(", ")},target:o.property})}if(t.kind!=="Model"||ks(t))return s.wrap({bodyKind:"single",...s.pipe(rf(e,o,t)),type:t,isExplicit:!1,containsMetadataAnnotations:!1});let l=s.pipe(qMe(e,n,o,r,i));if(l===void 0){if(t.baseModel||t.indexer)return s.wrap({bodyKind:"single",...s.pipe(rf(e,o,t)),type:t,isExplicit:!1,containsMetadataAnnotations:!1});if(t.derivedModels.length>0&&$d(e,t))return s.wrap({bodyKind:"single",...s.pipe(rf(e,o,t)),type:t,isExplicit:!1,containsMetadataAnnotations:!1})}let c=kD(e,t,(u)=>n.some((p)=>p.property===u&&p.kind==="bodyProperty"));if(c.properties.size>0)if(l===void 0)return s.wrap({bodyKind:"single",...s.pipe(rf(e,o,t)),type:c,isExplicit:!1,containsMetadataAnnotations:!1});else s.add(In({code:"duplicate-body",messageId:"bodyAndUnannotated",target:t}));if(l===void 0&&o)s.add(In({code:"content-type-ignored",target:o.property}));return s.wrap(l)}function qMe(e,t,n,r,i){let s=Ct(),o,a=new Ws;for(let l of t){if(l.kind==="body"||l.kind==="bodyRoot"||l.kind==="multipartBody")a.track("body",l.property);switch(l.kind){case"body":case"bodyRoot":let c=!1;if(l.kind==="body")c=!s.pipe(BMe(e,l.property,i));let u=Tv(e,l.property.type,Ste(t)),p=u!==void 0&&!n;if(u&&n){let d=s.pipe(Aa(n.property));Is(e,{code:"http-file-structured",format:{contentTypes:d.join(", ")},target:n.property})}if(l.property.type.kind==="Union"&&UMe(e,l.property.type))Is(e,{code:"http-file-structured",messageId:"union",target:l.property.node?.kind===re.ModelProperty?l.property.node.value:l.property});o??=p?s.pipe(Ete(u,l.property)):{bodyKind:"single",...s.pipe(rf(e,n,l.property.type)),type:l.property.type,isExplicit:l.kind==="body",containsMetadataAnnotations:c,property:l.property};break;case"multipartBody":o=s.pipe(VMe(e,l.property,n,r));break}}for(let[l,c]of a.entries())for(let u of c)s.add(In({code:"duplicate-body",target:u}));return s.wrap(o)}function UMe(e,t){return n(t);function n(r,i=new Set){if(i.has(r))return!1;i.add(r);for(let{type:s}of r.variants.values())if(!!Tv(e,s)||s.kind==="Union"&&n(s,i))return!0;return!1}}function BMe(e,t,n){let r=Ct();return yb(t.type,{modelProperty:(i)=>{let s=hv(e,i)?"header":(n===Vr.Request||n===Vr.Response)&&gv(e,i)?"cookie":(n===Vr.Request||n===Vr.Multipart)&&vv(e,i)?"query":n===Vr.Request&&_v(e,i)?"path":n===Vr.Response&&Oc(e,i)?"statusCode":void 0;if(s)r.add(In({code:"metadata-ignored",format:{kind:s},target:i}))}},{}),r.wrap(r.diagnostics.length===0)}function VMe(e,t,n,r){let i=Ct(),s=t.type,o=n&&i.pipe(Aa(n.property));for(let a of o??[])if(!wte.includes(a))i.add(In({code:"multipart-invalid-content-type",format:{contentType:a,supportedContentTypes:wte.join(", ")},target:s}));if(s.kind==="Model")return i.join(KMe(e,t,s,n,r));else if(s.kind==="Tuple")return i.join(JMe(e,t,s,n,r));else return i.add(In({code:"multipart-model",target:t})),i.wrap(void 0)}function KMe(e,t,n,r,i){let s=Ct(),o=[];for(let l of n.properties.values()){let c=s.pipe(Tte(e,l.type,i,l));if(c)o.push({partKind:"model",...c,name:c.name??l.name,optional:l.optional,property:l})}let a=r?{contentTypeProperty:r.property,contentTypes:s.pipe(Aa(r.property))}:{contentTypes:[XT.formData]};return s.wrap({bodyKind:"multipart",multipartKind:"model",...a,parts:o,property:t,type:n})}var XT={formData:"multipart/form-data",mixed:"multipart/mixed"},wte=Object.values(XT);function JMe(e,t,n,r,i){let s=Ct(),o=[],a=r&&s.pipe(Aa(r?.property));for(let[c,u]of n.values.entries()){let p=s.pipe(Tte(e,u,i));if(p?.name===void 0&&a?.includes(XT.formData))s.add(In({code:"formdata-no-part-name",target:n.node?.values[c]??n.values[c]}));if(p)o.push({partKind:"tuple",...p,optional:!1})}let l=r?{contentTypeProperty:r.property,contentTypes:s.pipe(Aa(r.property))}:{contentTypes:[XT.formData]};return s.wrap({bodyKind:"multipart",multipartKind:"tuple",...l,parts:o,property:t,type:n})}function Tte(e,t,n,r){if(t.kind==="Model"&&ks(t)){let[i,s]=Dte(e,t.indexer.value,n,r);if(i)return[{...i,multi:!0},s];return[i,s]}else return Dte(e,t,n,r)}function Dte(e,t,n,r){let i=Ct(),s=rj(e,t);if(s){let{body:o,metadata:a}=i.pipe(Iy(e,s.type,n,Vr.Multipart)),l=a.find((c)=>c.kind==="contentType");if(o===void 0)return i.wrap(void 0);else if(o.bodyKind==="multipart")return i.add(In({code:"multipart-nested",target:t})),i.wrap(void 0);if(o.contentTypes.length===0)o={...o,contentTypes:i.pipe(rf(e,l,o.type)).contentTypes};return i.wrap({multi:!1,property:r,name:s.options.name,body:o,optional:!1,headers:a.filter((c)=>c.kind==="header"),filename:o.bodyKind==="file"?o.filename:void 0})}return i.add(In({code:"multipart-part",target:t})),i.wrap(void 0)}function Ste(e){let t=new Map(e.map((n)=>[n.property,n]));return function(r){let i=t.get(r);if(["filename"].includes(r.name))return!0;if(!i)return!0;if(i.kind!=="bodyProperty")return!1;return!0}}function Ete(e,t){let[n,r]=Aa(e.contentType),i=s(e.contents.type);return[{bodyKind:"file",type:e.type,contents:e.contents,filename:e.filename,isText:i,contentTypeProperty:e.contentType,contentTypes:n,property:t},r];function s(o){return a(o)||!!o.baseScalar&&s(o.baseScalar);function a(l){return l.name==="string"&&!!l.namespace&&l.namespace.name==="TypeSpec"&&!!l.namespace.namespace&&l.namespace.namespace.name===""&&!l.namespace.namespace.namespace}}}function GMe(e){return e.kind==="Scalar"?"text/plain":"application/json"}function HMe(e){return e.kind==="String"||e.kind==="Number"||e.kind==="Boolean"||e.kind==="StringTemplate"}function rf(e,t,n,r=GMe){let i=Ct();return i.wrap(s());function s(){let o;if(_te(e,n))o="application/merge-patch+json";if(t){let l=i.pipe(Aa(t.property));if(o){let c=l.filter((u)=>!u.startsWith(o));if(c.length>0)i.add(In({code:"merge-patch-content-type",target:t.property??n,format:{contentType:c[0]}}))}return{contentTypes:l,contentTypeProperty:t.property}}if(o)return{contentTypes:[o]};if(HMe(n))switch(n.kind){case"StringTemplate":case"String":n=e.checker.getStdType("string");break;case"Boolean":n=e.checker.getStdType("boolean");break;case"Number":n=e.checker.getStdType("numeric");break;default:}let a;while((n.kind==="Scalar"||n.kind==="ModelProperty")&&(a=uc(e,n)))n=a.type;if(n.kind==="Union"){let l=[...n.variants.values()];if(l.some((p)=>p.type.kind==="Intrinsic"&&p.type.name==="null"))return{contentTypes:["application/json"]};let u=new Set;for(let p of l){let d=i.pipe(rf(e,t,p.type));for(let f of d.contentTypes)u.add(f)}return{contentTypes:[...u]}}else return{contentTypes:[dD(e,n)??r(n)]}}}var zMe=["+","#",".","/",";","?","&"],WMe=/\{([^{}]+)\}|([^{}]+)/g,QMe=/([^:*]*)(?::(\d+)|(\*))?/;function Sv(e){let t=[],n=[],r=e.matchAll(WMe);for(let[i,s,o]of r)if(s){let a;if(zMe.includes(s[0]))a=s[0],s=s.slice(1);let l=s.split(",");for(let c of l){let u=c.match(QMe),d={name:u[1],operator:a,modifier:u[3]?{type:"explode"}:u[2]?{type:"prefix",value:Number(u[2])}:void 0};t.push(d),n.push(d)}}else n.push(o);return{segments:n,parameters:t}}function ZT(e,t,n,r,i={}){let s=(i?.verbSelector&&i.verbSelector(e,t))??up(e,t)??r?.verb;if(s)return lj(e,t,s,n);let o=lj(e,t,"post",n);return o[0].body?o:lj(e,t,"get",n)}var kte={";":"matrix","#":"fragment",".":"label","/":"path"};function lj(e,t,n,r){let i=Ct(),s=ij(e,t,n),o=Sv(r),a=[],{body:l,metadata:c}=i.pipe(Iy(e,t.parameters,s,Vr.Request,{implicitParameter:(p)=>{let d=p.model===t.parameters,f=Ny(e,p),m=bv(e,p),y=f?.name??m?.name??p.name,h=d&&o.parameters.find((g)=>g.name===y);if(!h){let g=Ny(e,p);if(g&&p.optional)return{type:"path",name:g.name,explode:!1,allowReserved:!1,style:kte["/"]};return}let b=h.modifier?.type==="explode";if(h.operator==="?"||h.operator==="&")return{type:"query",name:h.name,explode:b};else if(h.operator==="+")return{type:"path",name:h.name,explode:b,allowReserved:!0,style:"simple"};else return{type:"path",name:h.name,explode:b,allowReserved:!1,style:(h.operator&&kte[h.operator])??"simple"}}}));for(let p of c)switch(p.kind){case"contentType":a.push({name:"Content-Type",type:"header",param:p.property});break;case"path":case"query":case"cookie":case"header":a.push({type:p.kind,...p.options,param:p.property});break}let u=l;return i.wrap({properties:c,parameters:a,verb:n,body:u,get bodyType(){return u?.type},get bodyParameter(){return u?.property}})}var Nte=["/",":","?"];function YMe(e){return!(e.length===0||Nte.indexOf(e[0])!==-1||e[0]==="{"&&e[1]==="/")}function XMe(e,t=!1){if(YMe(e))e=`/${e}`;if(t&&e[e.length-1]==="/")return e.slice(0,-1);return e}function Ev(e){let t="";for(let[n,r]of e.entries())t+=XMe(r,nu==="path"||u==="query").map((u)=>u.name));eLe(a,t,o).forEach((u)=>i.add(u));for(let u of a.parameters){let p=decodeURIComponent(u.name);if(!l.has(u.name)&&!l.has(p))i.add(In({code:"missing-uri-param",format:{param:u.name},target:t}))}let c=tLe(a);return i.wrap({uriTemplate:s,path:c,parameters:o})}function eLe(e,t,n){let r=Ct();if(e.segments){let[i,...s]=e.segments,o=i;for(let a of s)if(typeof a!=="string"){let l=n.parameters.find((c)=>c.name===a.name);if(a.operator==="/"){if(typeof o==="string"&&o.endsWith("/"))r.add(In({code:"double-slash",messageId:l?.param.optional?"optionalUnset":"default",format:{paramName:a.name},target:t}))}o=a}}return r.diagnostics}function tLe(e){let t="";for(let n of e.segments??[])if(typeof n==="string")t+=n;else if(n.operator!=="?"&&n.operator!=="&")t+=`{${n.name}}`;return t}function Ote(e,t){if(t===void 0)return[[],{}];let[n,r]=Ote(e,t.namespace),i=Ay(e,t)?.path,s=t.kind==="Namespace"?Pte(e,t)??{}:{};return[[...n,...i?[i]:[]],{...r,...s}]}function nLe(e,t,n,r){let[i,s]=Ote(e,t.interface??t.namespace),o=dj(e,t)??cj,[a,l]=o(e,t,i,n,{...s,...r});return[{uriTemplate:ZMe([a.uriTemplate]),parameters:a.parameters},l]}function cj(e,t,n,r,i){let s=Ct(),o=Ay(e,t)?.path,a=!o&&r?r.uriTemplate:Ev([...n,...o?[o]:[]]),l=Sv(a),c=s.pipe(ZT(e,t,a,r,i.paramOptions)),u=new Map(c.parameters.filter(({type:d})=>d==="path"||d==="query").map((d)=>[d.name,d]));for(let d of l.parameters)u.delete(d.name);let p=sLe(a,[...u.values()]);return s.wrap({uriTemplate:p,parameters:c})}var rLe={matrix:";",label:".",simple:"",path:"/",fragment:"#"};function uj(e){return`{${e.param.optional?"/":e.allowReserved?"+":rLe[e.style]}${e.name}${e.explode?"*":""}}`}function iLe(e){return`${oLe(e.name)}${e.explode?"*":""}`}function pj(e,t){let n=t.filter((r)=>r.type==="query");return e+(n.length>0?`{?${n.map((r)=>iLe(r)).join(",")}}`:"")}function sLe(e,t){let n=t.filter((s)=>s.type==="path").map(uj),r=t.filter((s)=>s.type==="query"),i=Ev([e,...n]);return pj(i,r)}function oLe(e){return encodeURIComponent(e).replace(/[:-]/g,function(t){return"%"+t.charCodeAt(0).toString(16).toUpperCase()})}function dj(e,t){return e.stateMap(Qt.routeProducer).get(t)}function Pte(e,t){return e.stateMap(Qt.routeOptions).get(t)}function Ay(e,t){let n=e.stateMap(Qt.routes).get(t);return n?{path:n,shared:t.kind==="Operation"&&$y(e,t)}:void 0}var $te=Cb({name:"op-reference-container-route",severity:"warning",description:"Check for referenced (`op is`) operations which have a @route on one of their containers.",url:"https://typespec.io/docs/libraries/http/rules/op-reference-container-route",docs:dl.fromPackageRoot("src/rules/op-reference-container-route.md"),messages:{default:M`Operation ${"opName"} references an operation which has a @route prefix on its namespace or interface: "${"routePrefix"}". This operation will not carry forward the route prefix so the final route may be different than the referenced operation.`},create(e){let t=new Map;function n(i){if(i===void 0)return;if(i.kind==="Operation")return n(i.interface)??n(i.namespace);let s=Ay(e.program,i);return s?s.path:n(i.namespace)}function r(i,s){if(i!==void 0){let o=i.interface??i.namespace,a=s.interface??s.namespace;if(o!==a){let l=t.get(i);if(l===void 0)l=n(i),t.set(i,l);if(l){e.reportDiagnostic({target:s,format:{opName:s.name,routePrefix:l}});return}}r(i.sourceOperation,s)}}return{operation:(i)=>{r(i.sourceOperation,i)}}}});var aLe=zD({rules:[$te]});await st();BT();function fj(e,t,n,r){let i=e.currentStage;if(i!=="validating"&&i!=="linting"&&i!=="emitting")return r();if(!n.isFinished)return r();let s=e.stateMap(t),o=s.get(n);if(o!==void 0)return o;let a=r();return s.set(n,a),a}hP();Pd();ka();await st();function mj(e,t){let n=Ct(),r=new Ate,i=Ite(e,t.returnType);for(let{type:s,description:o}of i)lLe(e,n,t,r,s,o);return n.wrap(r.values())}function Ite(e,t,n){let r=Kn(e);if(!r.union.is(t)||r.union.getDiscriminatedUnion(t))return[{type:t,description:n}];let i=Zr(e,t)??n,s=[],o=[];for(let l of t.variants.values()){if(Zg(l.type))continue;let c=Ite(e,l.type,Zr(e,l)??i);for(let u of c)if(dLe(e,u.type))s.push(u.type);else o.push(u)}let a=[];if(s.length===1)a.push({type:s[0],description:i});else if(s.length>1){let l=o.length===0?t:r.union.create(s);a.push({type:l,description:i})}return a.push(...o),a}class Ate{#e=new Map;get(e){return this.#e.get(this.#t(e))}set(e,t){this.#e.set(this.#t(e),t)}values(){return[...this.#e.values()]}#t(e){if(typeof e==="number"||e==="*")return String(e);else return`${e.start}-${e.end}`}}function lLe(e,t,n,r,i,s){let o=up(e,n),{body:a,metadata:l}=t.pipe(Iy(e,i,An.Read,Vr.Response,{treatContentTypeAsHeader:o==="head"})),c=t.pipe(cLe(e,i,l)),u=uLe(e,l);if(c.length===0)if(fc(e,i))c.push("*");else if(Pm(i))a=void 0,c.push(204);else if(a===void 0||Pm(a.type))a=void 0,c.push(200);else c.push(200);for(let p of c){let d=r.get(p)??{statusCodes:p,type:i,description:fLe(e,n,i,p,l,s),responses:[]};if(a!==void 0)d.responses.push({body:a,headers:u,properties:l});else d.responses.push({headers:u,properties:l});r.set(p,d)}}function cLe(e,t,n){let r=[],i=Ct(),s=!1;for(let o of n)if(o.kind==="statusCode"){if(s)Is(e,{code:"multiple-status-codes",target:t});s=!0,r.push(...i.pipe(HR(e,o.property)))}if(t.kind==="Model")for(let o=t;o;o=o.baseModel)r.push(...Rte(e,o));return i.wrap(r)}function Rte(e,t){return e.stateMap(Qt.statusCode).get(t)??[]}function uLe(e,t){let n={};for(let r of t)if(r.kind==="header")n[r.options.name]=r.property;return n}function pLe(e){return e.some((t)=>t.kind==="body"||t.kind==="bodyRoot"||t.kind==="multipartBody"||t.kind==="statusCode")}function dLe(e,t){if(Pm(t)||fc(e,t))return!1;if(t.kind==="Model"&&Rte(e,t).length>0)return!1;let[n]=Iy(e,t,An.Read,Vr.Response);return!n||!n.metadata.some((r)=>r.kind!=="bodyProperty")}function fLe(e,t,n,r,i,s){if(s)return s;if(pLe(i)){let a=Zr(e,n);if(a)return a}let o=fc(e,n)?AP(e,t):$P(e,t);if(o)return o;return zR(r)}var mLe=Symbol.for("@typespec/http.httpOperationCache");function yj(e,t,n){if(!n)return fj(e,mLe,t,()=>eS(e,t,n,new Map));return eS(e,t,n,new Map)}function eS(e,t,n,r){let i=r.get(t);if(i)return[i,[]];let s=Ct(),o={operation:t};r.set(t,o);let a=GP(e,t),l;if(a)l=o.overloading=s.pipe(eS(e,a,n,r));let c=s.pipe(YT(e,t,l,n??{})),u=s.pipe(mj(e,t)),p=nj(e,t),d={path:c.path,uriTemplate:c.uriTemplate,verb:c.parameters.verb,container:t.interface??t.namespace??e.getGlobalNamespaceType(),parameters:c.parameters,responses:u,operation:t,authentication:p};Object.assign(o,d);let f=xD(e,t);if(f)o.overloads=f.map((m)=>s.pipe(eS(e,m,n,r)));return s.wrap(o)}await st();ka();await st();var hLe=K$(({program:e,target:t})=>{if(t.kind!=="Operation")return;let[n]=yj(e,t);if(!n)return;let r=[`\`HTTP Route\`: \`${n.verb.toUpperCase()} ${n.uriTemplate}\``],i=n.responses.map((s)=>gLe(s.statusCodes));if(i.length>0)r.push(`\`Responses\`: ${i.map((s)=>`\`${s}\``).join(", ")}`);return{content:r.join(` +`)}},required:[]},tte=nr({name:"@typespec/openapi3",capabilities:{dryRun:!0},diagnostics:{"oneof-union":{severity:"error",messages:{default:"@oneOf decorator can only be used on a union or a model property which type is a union."}},"inconsistent-shared-route-request-visibility":{severity:"error",messages:{default:"All operations with `@sharedRoutes` must have the same `@requestVisibility`."}},"invalid-server-variable":{severity:"error",docs:dl.fromPackageRoot("src/diagnostics/invalid-server-variable.md"),messages:{default:M`Server variable '${"propName"}' must be assignable to 'string'. It must either be a string, enum of string or union of strings.`}},"invalid-format":{severity:"warning",messages:{default:M`Collection format '${"value"}' is not supported in OpenAPI3 ${"paramType"} parameters. Defaulting to type 'string'.`}},"invalid-style":{severity:"warning",messages:{default:M`Style '${"style"}' is not supported in OpenAPI3 ${"paramType"} parameters. Defaulting to style 'simple'.`,optionalPath:M`Style '${"style"}' is not supported in OpenAPI3 ${"paramType"} parameters. The style ${"style"} could be introduced by an optional parameter. Defaulting to style 'simple'.`}},"path-reserved-expansion":{severity:"warning",messages:{default:"Reserved expansion of path parameter with '+' operator #{allowReserved: true} is not supported in OpenAPI3."}},"resource-namespace":{severity:"error",messages:{default:"Resource goes on namespace"}},"path-query":{severity:"error",docs:dl.fromPackageRoot("src/diagnostics/path-query.md"),messages:{default:"OpenAPI does not allow paths containing a query string."}},"duplicate-header":{severity:"error",docs:dl.fromPackageRoot("src/diagnostics/duplicate-header.md"),messages:{default:M`The header ${"header"} is defined across multiple content types`}},"status-code-in-default-response":{severity:"error",messages:{default:"a default response should not have an explicit status code"}},"invalid-schema":{severity:"error",docs:dl.fromPackageRoot("src/diagnostics/invalid-schema.md"),messages:{default:M`Couldn't get schema for type ${"type"}`}},"union-null":{severity:"error",docs:dl.fromPackageRoot("src/diagnostics/union-null.md"),messages:{default:"Cannot have a union containing only null types."}},"empty-union":{severity:"error",messages:{default:"Empty unions are not supported for OpenAPI v3 - enums must have at least one value."}},"empty-enum":{severity:"error",messages:{default:"Empty enums are not supported for OpenAPI v3 - enums must have at least one value."}},"enum-unique-type":{severity:"error",messages:{default:"Enums are not supported unless all options are literals of the same type."}},"inline-cycle":{severity:"error",docs:dl.fromPackageRoot("src/diagnostics/inline-cycle.md"),messages:{default:M`Cycle detected in '${"type"}'. Use @friendlyName decorator to assign an OpenAPI definition name and make it non-inline.`}},"unsupported-status-code-range":{severity:"error",messages:{default:M`Status code range '${"start"} to '${"end"}' is not supported. OpenAPI 3.0 can only represent range 1XX, 2XX, 3XX, 4XX and 5XX. Example: \`@minValue(400) @maxValue(499)\` for 4XX.`}},"invalid-model-property":{severity:"error",messages:{default:M`'${"type"}' cannot be specified as a model property.`}},"unsupported-auth":{severity:"warning",messages:{default:M`Authentication "${"authType"}" is not a known authentication by the openapi3 emitter, it will be ignored.`}},"xml-attribute-invalid-property-type":{severity:"warning",messages:{default:M`XML \`@attribute\` can only be primitive types in the OpenAPI 3 emitter, Property '${"name"}' type will be changed to type: string.`}},"xml-unwrapped-invalid-property-type":{severity:"warning",messages:{default:M`XML \`@unwrapped\` can only used on array properties or primitive ones in the OpenAPI 3 emitter, Property '${"name"}' will be ignored.`}},"invalid-component-fixed-field-key":{severity:"warning",messages:{default:M`Invalid key '${"value"}' used in a fixed field of the Component object. Only alphanumerics, dot (.), hyphen (-), and underscore (_) characters are allowed in keys.`}},"streams-not-supported":{severity:"warning",messages:{default:"Streams with itemSchema are only fully supported in OpenAPI 3.2.0 or above. The response will be emitted without itemSchema. Consider using OpenAPI 3.2.0 for full stream support."}},"default-not-supported":{severity:"warning",messages:{default:M`Default value is not supported in OpenAPI 3.0 ${"message"}`}},"enum-strategy-not-supported":{severity:"warning",messages:{default:"`enum-strategy: annotated` is only supported for OpenAPI 3.1.0 and above. The default enum strategy will be used for OpenAPI 3.0.0."}}},emitter:{options:mMe}}),{createDiagnostic:TOt,reportDiagnostic:yMe,createStateSymbol:BR}=tte;var kOt=BR("refs");var NOt=BR("oneOf");Nn();await st();var nte=nr({name:"@typespec/sse",diagnostics:{"terminal-event-not-in-events":{severity:"error",messages:{default:"A field marked as '@terminalEvent' must be a member of a type decorated with '@TypeSpec.Events.events'."}},"sse-stream-union-not-events":{severity:"error",messages:{default:"SSEStream type parameter must be a union decorated with '@TypeSpec.Events.events'."}}},state:{terminalEvent:{description:"State for the @terminalEvent decorator."}}}),{reportDiagnostic:gMe,createDiagnostic:jOt,stateKeys:VR}=nte;var[LOt,qOt]=hr(VR.terminalEvent);await st();await st();var KR=nr({name:"@typespec/events",diagnostics:{"invalid-content-type-target":{severity:"error",messages:{default:"@contentType can only be specified on the top-level event envelope, or the event payload marked with @data"}},"multiple-event-payloads":{severity:"error",messages:{default:M`Event payload already applied to ${"dataPath"} but also exists under ${"currentPath"}`,payloadInIndexedModel:M`Event payload applied from inside a Record or Array at ${"dataPath"}`}}},state:{events:{description:"State for the @events decorator."},contentType:{description:"State for the @contentType decorator."},data:{description:"State for the @data decorator."}}}),{reportDiagnostic:VOt,createDiagnostic:bMe,stateKeys:yv}=KR;Nn();await st();var[rte,zOt]=hr(yv.events);var[ite,WOt]=ze(yv.contentType);var[ste,QOt]=hr(yv.data);await st();Nn();await st();Nn();await st();var JR=nr({name:"@typespec/http",diagnostics:{"http-verb-duplicate":{severity:"error",messages:{default:M`HTTP verb already applied to ${"entityName"}`}},"missing-uri-param":{severity:"error",messages:{default:M`Route reference parameter '${"param"}' but wasn't found in operation parameters`}},"incompatible-uri-param":{severity:"error",messages:{default:M`Parameter '${"param"}' is defined in the uri as a ${"uriKind"} but is annotated as a ${"annotationKind"}.`}},"use-uri-template":{severity:"error",messages:{default:M`Parameter '${"param"}' is already defined in the uri template. Explode, style and allowReserved property must be defined in the uri template as described by RFC 6570.`}},"double-slash":{severity:"warning",messages:{default:M`Route will result in duplicate slashes as parameter '${"paramName"}' use path expansion and is prefixed with a /`,optionalUnset:M`Route will result in duplicate slashes when optional parameter '${"paramName"}' is not set.`,optionalSet:M`Route will result in duplicate slashes when optional parameter '${"paramName"}' is set.`}},"missing-server-param":{severity:"error",messages:{default:M`Server url contains parameter '${"param"}' but wasn't found in given parameters`}},"duplicate-body":{severity:"error",messages:{default:"Operation has multiple @body parameters declared",duplicateUnannotated:"Operation has multiple unannotated parameters. There can only be one representing the body",bodyAndUnannotated:"Operation has a @body and an unannotated parameter. There can only be one representing the body"}},"duplicate-route-decorator":{severity:"error",messages:{namespace:"@route was defined twice on this namespace and has different values."}},"operation-param-duplicate-type":{severity:"error",messages:{default:M`Param ${"paramName"} has multiple types: [${"types"}]`}},"duplicate-operation":{severity:"error",messages:{default:M`Duplicate operation "${"operationName"}" routed at "${"verb"} ${"path"}".`}},"multiple-status-codes":{severity:"error",messages:{default:"Multiple `@statusCode` decorators defined for this operation response."}},"status-code-invalid":{severity:"error",messages:{default:"statusCode value must be a numeric or string literal or union of numeric or string literals",value:"statusCode value must be a three digit code between 100 and 599"}},"content-type-string":{severity:"error",messages:{default:"contentType parameter must be a string literal or union of string literals"}},"content-type-ignored":{severity:"warning",messages:{default:"`Content-Type` header ignored because there is no body."}},"metadata-ignored":{severity:"warning",messages:{default:M`${"kind"} property will be ignored as it is inside of a @body property. Use @bodyRoot instead if wanting to mix.`}},"response-cookie-not-supported":{severity:"warning",messages:{default:M`@cookie on response is not supported. Property '${"propName"}' will be ignored in the body. If you need 'Set-Cookie', use @header instead.`}},"no-service-found":{severity:"warning",messages:{default:M`No namespace with '@service' was found, but Namespace '${"namespace"}' contains routes. Did you mean to annotate this with '@service'?`}},"invalid-type-for-auth":{severity:"error",messages:{default:M`@useAuth ${"kind"} only accept Auth model, Tuple of auth model or union of auth model.`}},"shared-inconsistency":{severity:"error",messages:{default:M`Each operation routed at "${"verb"} ${"path"}" needs to have the @sharedRoute decorator.`}},"multipart-invalid-content-type":{severity:"error",messages:{default:M`Content type '${"contentType"}' is not a multipart content type. Supported content types are: ${"supportedContentTypes"}.`}},"multipart-model":{severity:"error",messages:{default:"Multipart request body must be a model or a tuple of http parts."}},"no-implicit-multipart":{severity:"error",messages:{default:"Using multipart payloads requires the use of @multipartBody and HttpPart models."}},"multipart-part":{severity:"error",messages:{default:"Expect item to be an HttpPart model."}},"multipart-nested":{severity:"error",messages:{default:"Cannot use @multipartBody inside of an HttpPart"}},"http-file-extra-property":{severity:"error",messages:{default:M`File model cannot define extra properties. Found '${"propName"}'.`}},"http-file-disallowed-metadata":{severity:"error",messages:{default:M`File model cannot define HTTP metadata type '${"metadataType"}' on property '${"propName"}'.`}},"formdata-no-part-name":{severity:"error",messages:{default:"Part used in multipart/form-data must have a name."}},"http-file-structured":{severity:"warning",messages:{default:M`HTTP File body is serialized as a structured model in '${"contentTypes"}' instead of being treated as the contents of a file because an explicit Content-Type header is defined. Override the \`contentType\` property of the file model to declare the internal media type of the file's contents, or suppress this warning if you intend to serialize the File as a model.`,union:"An HTTP File in a union is serialized as a structured model instead of being treated as the contents of a file. Declare a separate operation using `@sharedRoute` that has only the File model as the body type to treat it as a file, or suppress this warning if you intend to serialize the File as a model."}},"http-file-content-type-not-string":{severity:"error",messages:{default:M`The 'contentType' property of the file model must be 'TypeSpec.string', a string literal, or a union of string literals. Found '${"type"}'.`}},"http-file-contents-not-scalar":{severity:"error",messages:{default:M`The 'contents' property of the file model must be a scalar type that extends 'string' or 'bytes'. Found '${"type"}'.`}},"deprecated-implicit-optionality":{severity:"warning",messages:{default:"The implicitOptionality option is deprecated. To preserve previous behavior, use an explicit patch model with optional properties. For actual merge-patch semantics, use MergePatchUpdate for the @body type."}},"merge-patch-contains-null":{severity:"error",messages:{default:"Cannot convert model to a merge-patch compatible shape because it contains the 'null' intrinsic type."}},"merge-patch-content-type":{severity:"warning",messages:{default:M`The content-type of a request using a merge-patch template should be 'application/merge-patch+json' detected a header with content-type '${"contentType"}'.`}},"merge-patch-contains-metadata":{severity:"error",messages:{default:M`The MergePatch transform does not operate on http envelope metadata. Remove any http metadata decorators ('@query', '@header', '@path', '@cookie', '@statusCode') from the model passed to the MergePatch template. Found '${"metadataType"}' decorating property '${"propertyName"}'`}}},state:{authentication:{description:"State for the @auth decorator"},header:{description:"State for the @header decorator"},cookie:{description:"State for the @cookie decorator"},query:{description:"State for the @query decorator"},path:{description:"State for the @path decorator"},body:{description:"State for the @body decorator"},bodyRoot:{description:"State for the @bodyRoot decorator"},bodyIgnore:{description:"State for the @bodyIgnore decorator"},multipartBody:{description:"State for the @bodyIgnore decorator"},statusCode:{description:"State for the @statusCode decorator"},verbs:{description:"State for the verb decorators (@get, @post, @put, etc.)"},patchOptions:{description:"State for the options of the @patch decorator"},servers:{description:"State for the @server decorator"},includeInapplicableMetadataInPayload:{description:"State for the @includeInapplicableMetadataInPayload decorator"},externalInterfaces:{},routeProducer:{},routes:{},sharedRoutes:{description:"State for the @sharedRoute decorator"},routeOptions:{},file:{description:"State for the @Private.file decorator"},httpPart:{description:"State for the @Private.httpPart decorator"},mergePatchModel:{description:"State marking mergePatch models "},mergePatchProperty:{description:"State marking merge path model property source"},mergePatchPropertyOptions:{description:"Override options for a property in a merge patch transform"}}}),{reportDiagnostic:As,createDiagnostic:In,stateKeys:Qt}=JR;ka();await st();function Oy(e){return[[],[In({code:"status-code-invalid",target:e,messageId:"value"})]]}function wMe(e,t){let n=typeof e==="string"?parseInt(e,10):e;if(isNaN(n))return Oy(t);if(!Number.isInteger(n))return Oy(t);if(n<100||n>599)return Oy(t);return[[n],[]]}function GT(e,t,n){switch(t.kind){case"String":case"Number":return wMe(t.value,n);case"Union":let r=Ct(),i=[...t.variants.values()].flatMap((s)=>r.pipe(GT(e,s.type,n)));return r.wrap(i);case"Scalar":return ote(e,t,t,n);case"ModelProperty":if(t.type.kind==="Scalar")return ote(e,t,t.type,n);else return GT(e,t.type,n);default:return Oy(n)}}function ote(e,t,n,r){if(!TMe(e,n))return Oy(r);let i=GR(e,t,r);if(DMe(i))return[[i],[]];else return Oy(r)}function DMe(e){return e.start!==void 0&&e.end!==void 0}function GR(e,t,n){let r=Fm(e,t),i=Mm(e,t),s={};if(t.kind==="ModelProperty"&&(t.type.kind==="Scalar"||t.type.kind==="ModelProperty"))s=GR(e,t.type,n);else if(t.kind==="Scalar"&&t.baseScalar)s=GR(e,t.baseScalar,n);return{...s,start:r,end:i}}function TMe(e,t){let n=Kn(e);return n.type.isAssignableTo(t,n.builtin.int32,t)}function HT(e,t){return e.stateMap(Qt.header).get(t)}function hv(e,t){return e.stateMap(Qt.header).has(t)}function zT(e,t){return e.stateMap(Qt.cookie).get(t)}function gv(e,t){return e.stateMap(Qt.cookie).has(t)}var[bv,IPt]=ze(Qt.query);function lte(e){return{explode:e.explode??!1,name:e.name}}function vv(e,t){return e.stateMap(Qt.query).has(t)}var[Py,APt]=ze(Qt.path);function cte(e){return{explode:e.explode??!1,allowReserved:e.allowReserved??!1,style:e.style??"simple",name:e.name}}function _v(e,t){return e.stateMap(Qt.path).has(t)}function xv(e,t){return e.stateSet(Qt.body).has(t)}function wv(e,t){return e.stateSet(Qt.bodyRoot).has(t)}function WT(e,t){return e.stateSet(Qt.bodyIgnore).has(t)}function Dv(e,t){return e.stateSet(Qt.multipartBody).has(t)}function Oc(e,t){return e.stateSet(Qt.statusCode).has(t)}function HR(e,t){return GT(e,t,t)}function zR(e){if(typeof e==="object")return ate(e.start,e.end);let t=typeof e==="string"?parseInt(e,10):e;switch(t){case 200:return"The request has succeeded.";case 201:return"The request has succeeded and a new resource has been created as a result.";case 202:return"The request has been accepted for processing, but processing has not yet completed.";case 204:return"There is no content to send for this request, but the headers may be useful. ";case 301:return"The URL of the requested resource has been changed permanently. The new URL is given in the response.";case 304:return"The client has made a conditional request and the resource has not been modified.";case 400:return"The server could not understand the request due to invalid syntax.";case 401:return"Access is unauthorized.";case 403:return"Access is forbidden.";case 404:return"The server cannot find the requested resource.";case 409:return"The request conflicts with the current state of the server.";case 412:return"Precondition failed.";case 503:return"Service unavailable."}return ate(t,t)}function ate(e,t){if(e>=100&&t<=199)return"Informational";else if(e>=200&&t<=299)return"Successful";else if(e>=300&&t<=399)return"Redirection";else if(e>=400&&t<=499)return"Client error";else if(e>=500&&t<=599)return"Server error";return}function SMe(e,t,n){EMe(e,t),e.program.stateMap(Qt.verbs).set(t,n)}function EMe(e,t){if(t.decorators.filter((r)=>$Me.includes(r.decorator)&&r.node?.kind===re.DecoratorExpression&&r.node?.parent===t.node).length>1)return As(e.program,{code:"http-verb-duplicate",format:{entityName:t.name},target:e.decoratorTarget}),!1;return!0}function pp(e,t){return e.stateMap(Qt.verbs).get(t)}function $y(e){return(t,n)=>{SMe(t,n,e)}}var WR=$y("get"),QR=$y("put"),YR=$y("post"),XR=$y("delete"),ZR=$y("head"),kMe=$y("patch"),[NMe,OMe]=ze(Qt.patchOptions);function PMe(e,t){let n=e.decoratorTarget;if(t.interface!==void 0&&t.node!==void 0&&t.node.parent!==t.interface.node)return!1;if(t.sourceOperation!==void 0)return!1;if(n?.kind===re.DecoratorExpression&&n.parent){if(n.parent!==t.node)return!1}return!0}var ej=(e,t,n)=>{if(kMe(e,t),n){if(n.implicitOptionality===!0){if(PMe(e,t))As(e.program,{code:"deprecated-implicit-optionality",target:t})}OMe(e.program,t,n)}};function tj(e,t){return NMe(e,t)}var $Me=[WR,ZR,YR,QR,ej,XR];function Iy(e,t){return e.stateMap(Qt.authentication).get(t)}function nj(e,t){let n=Iy(e,t);if(n)return n;if(t.interface!==void 0){let i=Iy(e,t.interface);if(i)return i}let r=t.namespace;while(r){let i=Iy(e,r);if(i)return i;r=r.namespace}return}await st();function Aa(e){let t=Ct();if(e.type.kind==="String")return[[e.type.value],[]];else if(e.type.kind==="Union"){let n=[];for(let r of e.type.variants.values())if(r.type.kind==="String")n.push(r.type.value);else{t.add(In({code:"content-type-string",target:e}));continue}return t.wrap(n)}else if(e.type.kind==="Scalar"&&e.type.name==="string")return[["*/*"],[]];return[[],[In({code:"content-type-string",target:e})]]}Nn();await st();Nn();var[IMe,VPt]=ze(Qt.sharedRoutes);function Ay(e,t){return IMe(e,t)===!0}var[WPt,QPt]=ze(Qt.routes);await st();await st();await st();await st();Nn();await st();await st();function ute(e,t){return e.stateSet(Qt.file).has(t)}function pte(e,t){if(t.kind!=="Model")return!1;let n=t;while(n){if(ute(e,n))return!0;n=n.baseModel}return!1}function Tv(e,t,n){if(t.kind!=="Model")return;let r=Fd(t,"contentType"),i=Fd(t,"filename"),s=Fd(t,"contents");if(!r||!i||!s)return;if(!QT(e,r)||!QT(e,i)||!QT(e,s))return;let o=new Set(eo(t));if(n){for(let a of o)if(!n(a))o.delete(a)}if(o.size!==3)return;return{contents:s,contentType:r,filename:i,type:t}}function QT(e,t){if(t.model?pte(e,t.model):!1)return!0;if(t.sourceProperty)return QT(e,t.sourceProperty);return!1}function rj(e,t){return e.stateMap(Qt.httpPart).get(t)}var An;(function(e){e[e.Read=1]="Read",e[e.Create=2]="Create",e[e.Update=4]="Update",e[e.Delete=8]="Delete",e[e.Query=16]="Query",e[e.None=0]="None",e[e.All=31]="All",e[e.Item=1048576]="Item",e[e.Patch=2097152]="Patch",e[e.Synthetic=3145728]="Synthetic"})(An||(An={}));function RMe(e,t){let n=Ea(e);if(Qe(!t.all,"Unexpected: `all` constraint in visibility filter passed to filterToVisibility"),Qe(!t.none,"Unexpected: `none` constraint in visibility filter passed to filterToVisibility"),!t.any)return An.All;else{let r=An.None;for(let i of t.any??[]){if(i.enum!==n)continue;switch(i.name){case"Read":r|=An.Read;break;case"Create":r|=An.Create;break;case"Update":r|=An.Update;break;case"Delete":r|=An.Delete;break;case"Query":r|=An.Query;break;default:Qe(!1,`Unreachable: unrecognized Lifecycle visibility member: '${i.name}'`)}}return r}}var dte=new WeakMap;function jMe(e){let t=dte.get(e);if(!t)t=new Map,dte.set(e,t);return t}function fte(e,t){if(t&=~An.Synthetic,t===An.All)return{};let n=jMe(e),r=n.get(t);if(!r){let i=Ea(e),s={Create:i.members.get("Create"),Read:i.members.get("Read"),Update:i.members.get("Update"),Delete:i.members.get("Delete"),Query:i.members.get("Query")},o=new Set;if(t&An.Read)o.add(s.Read);if(t&An.Create)o.add(s.Create);if(t&An.Update)o.add(s.Update);if(t&An.Delete)o.add(s.Delete);if(t&An.Query)o.add(s.Query);Qe(o.size>0||t===An.None,"invalid visibility"),r={any:o},n.set(t,r)}return r}function FMe(e){switch(e){case"get":case"head":return An.Query;case"post":return An.Create;case"put":return An.Create|An.Update;case"patch":return An.Update;case"delete":return An.Delete;default:Qe(!1,`Unreachable: unrecognized HTTP verb: '${e}'`)}}function mte(e){let t=typeof e==="string";return{parameters:(n,r)=>{let i=t?e:e?.verbSelector?.(n,r)??pp(n,r);if(!i){let[{parameters:s}]=YT(n,r,void 0,{});i=s.verb}return fte(n,FMe(i))},returnType:(n,r)=>{let i=Ea(n).members.get("Read");return{any:new Set([i])}}}}function ij(e,t,n){let r=_P(e,t,mte(n)),i=RMe(e,r);if(n==="patch"){if(tj(e,t)?.implicitOptionality)i|=An.Patch}return i}function sj(e,t,n){return pc(e,t,fte(e,n))}await st();Nn();ka();Nn();await st();var[yte,hte]=ze(Qt.mergePatchModel),[oj,gte]=ze(Qt.mergePatchProperty),[bte,vte]=ze(Qt.mergePatchPropertyOptions);function aj(e,t){return yte(e,t)!==void 0}function _te(e,t){let n=new WeakMap;function r(i){if(n.has(i))return!1;if(n.set(t,!0),!Kn(e).model.is(i))return!1;if(aj(e,i))return!0;if(Kn(e).array.is(i)||Kn(e).record.is(i))return r(i.indexer.value);return!1}switch(t.kind){case"Model":return r(t)||t.sourceModels.some((i)=>r(i.model))||[...t.properties.values()].some((i)=>oj(e,i)!==void 0||r(i.type));case"ModelProperty":return r(t.type);case"Union":return[...t.variants.values()].some((i)=>r(i.type));case"UnionVariant":return r(t.type);case"Tuple":return t.values.some((i)=>r(i));default:return!1}}await st();function CMe(e,t,n,r={}){let i=[];function s(c){return[{...c,property:t,path:n},i]}let o={header:HT(e,t),cookie:zT(e,t),query:bv(e,t),path:Py(e,t),body:xv(e,t),bodyRoot:wv(e,t),multipartBody:Dv(e,t),statusCode:Oc(e,t)},a=Object.entries(o).filter((c)=>!!c[1]),l=r.implicitParameter?.(t);if(l&&a.length>0)if(l.type==="path"&&o.path){if(o.path.explode!==void 0||o.path.style!==void 0||o.path.allowReserved!==void 0)i.push(In({code:"use-uri-template",format:{param:t.name},target:t}))}else if(l.type==="query"&&o.query){if(o.query.explode!==void 0)i.push(In({code:"use-uri-template",format:{param:t.name},target:t}))}else i.push(In({code:"incompatible-uri-param",format:{param:t.name,uriKind:l.type,annotationKind:a[0][0]},target:t}));if(l)return s({kind:l.type,options:l,property:t});if(a.length===0)return WT(e,t)?s({kind:"bodyIgnore"}):s({kind:"bodyProperty"});else if(a.length>1)i.push(In({code:"operation-param-duplicate-type",format:{paramName:t.name,types:a.map((c)=>c[0]).join(", ")},target:t}));if(o.header){if(o.header.name.toLowerCase()==="content-type"&&!r.treatContentTypeAsHeader)return s({kind:"contentType"});return s({kind:"header",options:o.header})}else if(o.cookie)return s({kind:"cookie",options:o.cookie});else if(o.query)return s({kind:"query",options:lte(o.query)});else if(o.path)return s({kind:"path",options:cte(o.path)});else if(o.statusCode)return s({kind:"statusCode"});else if(o.body)return s({kind:"body"});else if(o.bodyRoot)return s({kind:"bodyRoot"});else if(o.multipartBody)return s({kind:"multipartBody"});Qe(!1,"Unexpected http property type")}function xte(e,t,n,r,i={}){let s=Ct(),o=new Map;if(t.kind!=="Model"||t.properties.size===0&&!t.baseModel)return s.wrap([]);let a=new Set;function l(c,u){a.add(c);let p=!1,d=!1;for(let f of eo(c)){let m=[...u,f.name];if(!sj(e,f,n))continue;let y=s.pipe(CMe(e,f,m,i));if(y.kind!=="bodyIgnore"&&LMe(y,r))y={kind:"bodyProperty",property:f,path:m};if(y.kind==="cookie"&&r===Kr.Response){s.add(In({code:"response-cookie-not-supported",target:f,format:{propName:f.name}}));continue}if(y.kind==="body"||y.kind==="bodyRoot"||y.kind==="multipartBody")p=!0;if(!(y.kind==="body"||y.kind==="multipartBody")&&MMe(f.type)&&!a.has(f.type)){if(l(f.type,m)){p=!0;continue}}if(y.kind==="bodyProperty")d=!0;if(y.kind!=="bodyIgnore")o.set(f,y)}return p&&!d}return l(t,[]),s.wrap([...o.values()])}function MMe(e){return e.kind==="Model"&&!e.indexer&&e.properties.size>0}function LMe(e,t){switch(t){case Kr.Request:return e.kind==="statusCode";case Kr.Response:return e.kind==="query"||e.kind==="path";case Kr.Multipart:return e.kind==="path"||e.kind==="query"||e.kind==="statusCode";default:return!1}}var Kr;(function(e){e[e.Request=0]="Request",e[e.Response=1]="Response",e[e.Multipart=2]="Multipart"})(Kr||(Kr={}));function Ry(e,t,n,r,i={}){let s=Ct(),o=s.pipe(xte(e,t,n,r,i)),a=s.pipe(qMe(e,t,o,n,r));if(a){if(a.contentTypes.some((l)=>l.startsWith("multipart/"))&&a.bodyKind!=="multipart")return s.add(In({code:"no-implicit-multipart",target:a.property??t})),s.wrap({body:void 0,metadata:o})}return s.wrap({body:a,metadata:o})}function qMe(e,t,n,r,i){let s=Ct(),o=n.find((u)=>u.kind==="contentType"),a=Tv(e,t,Ste(n));if(a!==void 0)if(!o)return s.join(Ete(a));else{let u=o&&s.pipe(Aa(o.property));As(e,{code:"http-file-structured",format:{contentTypes:u.join(", ")},target:o.property})}if(t.kind!=="Model"||Ns(t))return s.wrap({bodyKind:"single",...s.pipe(of(e,o,t)),type:t,isExplicit:!1,containsMetadataAnnotations:!1});let l=s.pipe(UMe(e,n,o,r,i));if(l===void 0){if(t.baseModel||t.indexer)return s.wrap({bodyKind:"single",...s.pipe(of(e,o,t)),type:t,isExplicit:!1,containsMetadataAnnotations:!1});if(t.derivedModels.length>0&&Ad(e,t))return s.wrap({bodyKind:"single",...s.pipe(of(e,o,t)),type:t,isExplicit:!1,containsMetadataAnnotations:!1})}let c=kD(e,t,(u)=>n.some((p)=>p.property===u&&p.kind==="bodyProperty"));if(c.properties.size>0)if(l===void 0)return s.wrap({bodyKind:"single",...s.pipe(of(e,o,t)),type:c,isExplicit:!1,containsMetadataAnnotations:!1});else s.add(In({code:"duplicate-body",messageId:"bodyAndUnannotated",target:t}));if(l===void 0&&o)s.add(In({code:"content-type-ignored",target:o.property}));return s.wrap(l)}function UMe(e,t,n,r,i){let s=Ct(),o,a=new Qs;for(let l of t){if(l.kind==="body"||l.kind==="bodyRoot"||l.kind==="multipartBody")a.track("body",l.property);switch(l.kind){case"body":case"bodyRoot":let c=!1;if(l.kind==="body")c=!s.pipe(VMe(e,l.property,i));let u=Tv(e,l.property.type,Ste(t)),p=u!==void 0&&!n;if(u&&n){let d=s.pipe(Aa(n.property));As(e,{code:"http-file-structured",format:{contentTypes:d.join(", ")},target:n.property})}if(l.property.type.kind==="Union"&&BMe(e,l.property.type))As(e,{code:"http-file-structured",messageId:"union",target:l.property.node?.kind===re.ModelProperty?l.property.node.value:l.property});o??=p?s.pipe(Ete(u,l.property)):{bodyKind:"single",...s.pipe(of(e,n,l.property.type)),type:l.property.type,isExplicit:l.kind==="body",containsMetadataAnnotations:c,property:l.property};break;case"multipartBody":o=s.pipe(KMe(e,l.property,n,r));break}}for(let[l,c]of a.entries())for(let u of c)s.add(In({code:"duplicate-body",target:u}));return s.wrap(o)}function BMe(e,t){return n(t);function n(r,i=new Set){if(i.has(r))return!1;i.add(r);for(let{type:s}of r.variants.values())if(!!Tv(e,s)||s.kind==="Union"&&n(s,i))return!0;return!1}}function VMe(e,t,n){let r=Ct();return yb(t.type,{modelProperty:(i)=>{let s=hv(e,i)?"header":(n===Kr.Request||n===Kr.Response)&&gv(e,i)?"cookie":(n===Kr.Request||n===Kr.Multipart)&&vv(e,i)?"query":n===Kr.Request&&_v(e,i)?"path":n===Kr.Response&&Oc(e,i)?"statusCode":void 0;if(s)r.add(In({code:"metadata-ignored",format:{kind:s},target:i}))}},{}),r.wrap(r.diagnostics.length===0)}function KMe(e,t,n,r){let i=Ct(),s=t.type,o=n&&i.pipe(Aa(n.property));for(let a of o??[])if(!wte.includes(a))i.add(In({code:"multipart-invalid-content-type",format:{contentType:a,supportedContentTypes:wte.join(", ")},target:s}));if(s.kind==="Model")return i.join(JMe(e,t,s,n,r));else if(s.kind==="Tuple")return i.join(GMe(e,t,s,n,r));else return i.add(In({code:"multipart-model",target:t})),i.wrap(void 0)}function JMe(e,t,n,r,i){let s=Ct(),o=[];for(let l of n.properties.values()){let c=s.pipe(Tte(e,l.type,i,l));if(c)o.push({partKind:"model",...c,name:c.name??l.name,optional:l.optional,property:l})}let a=r?{contentTypeProperty:r.property,contentTypes:s.pipe(Aa(r.property))}:{contentTypes:[XT.formData]};return s.wrap({bodyKind:"multipart",multipartKind:"model",...a,parts:o,property:t,type:n})}var XT={formData:"multipart/form-data",mixed:"multipart/mixed"},wte=Object.values(XT);function GMe(e,t,n,r,i){let s=Ct(),o=[],a=r&&s.pipe(Aa(r?.property));for(let[c,u]of n.values.entries()){let p=s.pipe(Tte(e,u,i));if(p?.name===void 0&&a?.includes(XT.formData))s.add(In({code:"formdata-no-part-name",target:n.node?.values[c]??n.values[c]}));if(p)o.push({partKind:"tuple",...p,optional:!1})}let l=r?{contentTypeProperty:r.property,contentTypes:s.pipe(Aa(r.property))}:{contentTypes:[XT.formData]};return s.wrap({bodyKind:"multipart",multipartKind:"tuple",...l,parts:o,property:t,type:n})}function Tte(e,t,n,r){if(t.kind==="Model"&&Ns(t)){let[i,s]=Dte(e,t.indexer.value,n,r);if(i)return[{...i,multi:!0},s];return[i,s]}else return Dte(e,t,n,r)}function Dte(e,t,n,r){let i=Ct(),s=rj(e,t);if(s){let{body:o,metadata:a}=i.pipe(Ry(e,s.type,n,Kr.Multipart)),l=a.find((c)=>c.kind==="contentType");if(o===void 0)return i.wrap(void 0);else if(o.bodyKind==="multipart")return i.add(In({code:"multipart-nested",target:t})),i.wrap(void 0);if(o.contentTypes.length===0)o={...o,contentTypes:i.pipe(of(e,l,o.type)).contentTypes};return i.wrap({multi:!1,property:r,name:s.options.name,body:o,optional:!1,headers:a.filter((c)=>c.kind==="header"),filename:o.bodyKind==="file"?o.filename:void 0})}return i.add(In({code:"multipart-part",target:t})),i.wrap(void 0)}function Ste(e){let t=new Map(e.map((n)=>[n.property,n]));return function(r){let i=t.get(r);if(["filename"].includes(r.name))return!0;if(!i)return!0;if(i.kind!=="bodyProperty")return!1;return!0}}function Ete(e,t){let[n,r]=Aa(e.contentType),i=s(e.contents.type);return[{bodyKind:"file",type:e.type,contents:e.contents,filename:e.filename,isText:i,contentTypeProperty:e.contentType,contentTypes:n,property:t},r];function s(o){return a(o)||!!o.baseScalar&&s(o.baseScalar);function a(l){return l.name==="string"&&!!l.namespace&&l.namespace.name==="TypeSpec"&&!!l.namespace.namespace&&l.namespace.namespace.name===""&&!l.namespace.namespace.namespace}}}function HMe(e){return e.kind==="Scalar"?"text/plain":"application/json"}function zMe(e){return e.kind==="String"||e.kind==="Number"||e.kind==="Boolean"||e.kind==="StringTemplate"}function of(e,t,n,r=HMe){let i=Ct();return i.wrap(s());function s(){let o;if(_te(e,n))o="application/merge-patch+json";if(t){let l=i.pipe(Aa(t.property));if(o){let c=l.filter((u)=>!u.startsWith(o));if(c.length>0)i.add(In({code:"merge-patch-content-type",target:t.property??n,format:{contentType:c[0]}}))}return{contentTypes:l,contentTypeProperty:t.property}}if(o)return{contentTypes:[o]};if(zMe(n))switch(n.kind){case"StringTemplate":case"String":n=e.checker.getStdType("string");break;case"Boolean":n=e.checker.getStdType("boolean");break;case"Number":n=e.checker.getStdType("numeric");break;default:}let a;while((n.kind==="Scalar"||n.kind==="ModelProperty")&&(a=uc(e,n)))n=a.type;if(n.kind==="Union"){let l=[...n.variants.values()];if(l.some((p)=>p.type.kind==="Intrinsic"&&p.type.name==="null"))return{contentTypes:["application/json"]};let u=new Set;for(let p of l){let d=i.pipe(of(e,t,p.type));for(let f of d.contentTypes)u.add(f)}return{contentTypes:[...u]}}else return{contentTypes:[dD(e,n)??r(n)]}}}var WMe=["+","#",".","/",";","?","&"],QMe=/\{([^{}]+)\}|([^{}]+)/g,YMe=/([^:*]*)(?::(\d+)|(\*))?/;function Sv(e){let t=[],n=[],r=e.matchAll(QMe);for(let[i,s,o]of r)if(s){let a;if(WMe.includes(s[0]))a=s[0],s=s.slice(1);let l=s.split(",");for(let c of l){let u=c.match(YMe),d={name:u[1],operator:a,modifier:u[3]?{type:"explode"}:u[2]?{type:"prefix",value:Number(u[2])}:void 0};t.push(d),n.push(d)}}else n.push(o);return{segments:n,parameters:t}}function ZT(e,t,n,r,i={}){let s=(i?.verbSelector&&i.verbSelector(e,t))??pp(e,t)??r?.verb;if(s)return lj(e,t,s,n);let o=lj(e,t,"post",n);return o[0].body?o:lj(e,t,"get",n)}var kte={";":"matrix","#":"fragment",".":"label","/":"path"};function lj(e,t,n,r){let i=Ct(),s=ij(e,t,n),o=Sv(r),a=[],{body:l,metadata:c}=i.pipe(Ry(e,t.parameters,s,Kr.Request,{implicitParameter:(p)=>{let d=p.model===t.parameters,f=Py(e,p),m=bv(e,p),y=f?.name??m?.name??p.name,h=d&&o.parameters.find((g)=>g.name===y);if(!h){let g=Py(e,p);if(g&&p.optional)return{type:"path",name:g.name,explode:!1,allowReserved:!1,style:kte["/"]};return}let b=h.modifier?.type==="explode";if(h.operator==="?"||h.operator==="&")return{type:"query",name:h.name,explode:b};else if(h.operator==="+")return{type:"path",name:h.name,explode:b,allowReserved:!0,style:"simple"};else return{type:"path",name:h.name,explode:b,allowReserved:!1,style:(h.operator&&kte[h.operator])??"simple"}}}));for(let p of c)switch(p.kind){case"contentType":a.push({name:"Content-Type",type:"header",param:p.property});break;case"path":case"query":case"cookie":case"header":a.push({type:p.kind,...p.options,param:p.property});break}let u=l;return i.wrap({properties:c,parameters:a,verb:n,body:u,get bodyType(){return u?.type},get bodyParameter(){return u?.property}})}var Nte=["/",":","?"];function XMe(e){return!(e.length===0||Nte.indexOf(e[0])!==-1||e[0]==="{"&&e[1]==="/")}function ZMe(e,t=!1){if(XMe(e))e=`/${e}`;if(t&&e[e.length-1]==="/")return e.slice(0,-1);return e}function Ev(e){let t="";for(let[n,r]of e.entries())t+=ZMe(r,nu==="path"||u==="query").map((u)=>u.name));tLe(a,t,o).forEach((u)=>i.add(u));for(let u of a.parameters){let p=decodeURIComponent(u.name);if(!l.has(u.name)&&!l.has(p))i.add(In({code:"missing-uri-param",format:{param:u.name},target:t}))}let c=nLe(a);return i.wrap({uriTemplate:s,path:c,parameters:o})}function tLe(e,t,n){let r=Ct();if(e.segments){let[i,...s]=e.segments,o=i;for(let a of s)if(typeof a!=="string"){let l=n.parameters.find((c)=>c.name===a.name);if(a.operator==="/"){if(typeof o==="string"&&o.endsWith("/"))r.add(In({code:"double-slash",messageId:l?.param.optional?"optionalUnset":"default",format:{paramName:a.name},target:t}))}o=a}}return r.diagnostics}function nLe(e){let t="";for(let n of e.segments??[])if(typeof n==="string")t+=n;else if(n.operator!=="?"&&n.operator!=="&")t+=`{${n.name}}`;return t}function Ote(e,t){if(t===void 0)return[[],{}];let[n,r]=Ote(e,t.namespace),i=jy(e,t)?.path,s=t.kind==="Namespace"?Pte(e,t)??{}:{};return[[...n,...i?[i]:[]],{...r,...s}]}function rLe(e,t,n,r){let[i,s]=Ote(e,t.interface??t.namespace),o=dj(e,t)??cj,[a,l]=o(e,t,i,n,{...s,...r});return[{uriTemplate:eLe([a.uriTemplate]),parameters:a.parameters},l]}function cj(e,t,n,r,i){let s=Ct(),o=jy(e,t)?.path,a=!o&&r?r.uriTemplate:Ev([...n,...o?[o]:[]]),l=Sv(a),c=s.pipe(ZT(e,t,a,r,i.paramOptions)),u=new Map(c.parameters.filter(({type:d})=>d==="path"||d==="query").map((d)=>[d.name,d]));for(let d of l.parameters)u.delete(d.name);let p=oLe(a,[...u.values()]);return s.wrap({uriTemplate:p,parameters:c})}var iLe={matrix:";",label:".",simple:"",path:"/",fragment:"#"};function uj(e){return`{${e.param.optional?"/":e.allowReserved?"+":iLe[e.style]}${e.name}${e.explode?"*":""}}`}function sLe(e){return`${aLe(e.name)}${e.explode?"*":""}`}function pj(e,t){let n=t.filter((r)=>r.type==="query");return e+(n.length>0?`{?${n.map((r)=>sLe(r)).join(",")}}`:"")}function oLe(e,t){let n=t.filter((s)=>s.type==="path").map(uj),r=t.filter((s)=>s.type==="query"),i=Ev([e,...n]);return pj(i,r)}function aLe(e){return encodeURIComponent(e).replace(/[:-]/g,function(t){return"%"+t.charCodeAt(0).toString(16).toUpperCase()})}function dj(e,t){return e.stateMap(Qt.routeProducer).get(t)}function Pte(e,t){return e.stateMap(Qt.routeOptions).get(t)}function jy(e,t){let n=e.stateMap(Qt.routes).get(t);return n?{path:n,shared:t.kind==="Operation"&&Ay(e,t)}:void 0}var $te=Cb({name:"op-reference-container-route",severity:"warning",description:"Check for referenced (`op is`) operations which have a @route on one of their containers.",url:"https://typespec.io/docs/libraries/http/rules/op-reference-container-route",docs:dl.fromPackageRoot("src/rules/op-reference-container-route.md"),messages:{default:M`Operation ${"opName"} references an operation which has a @route prefix on its namespace or interface: "${"routePrefix"}". This operation will not carry forward the route prefix so the final route may be different than the referenced operation.`},create(e){let t=new Map;function n(i){if(i===void 0)return;if(i.kind==="Operation")return n(i.interface)??n(i.namespace);let s=jy(e.program,i);return s?s.path:n(i.namespace)}function r(i,s){if(i!==void 0){let o=i.interface??i.namespace,a=s.interface??s.namespace;if(o!==a){let l=t.get(i);if(l===void 0)l=n(i),t.set(i,l);if(l){e.reportDiagnostic({target:s,format:{opName:s.name,routePrefix:l}});return}}r(i.sourceOperation,s)}}return{operation:(i)=>{r(i.sourceOperation,i)}}}});var lLe=zD({rules:[$te]});await st();BT();function fj(e,t,n,r){let i=e.currentStage;if(i!=="validating"&&i!=="linting"&&i!=="emitting")return r();if(!n.isFinished)return r();let s=e.stateMap(t),o=s.get(n);if(o!==void 0)return o;let a=r();return s.set(n,a),a}hP();Id();ka();await st();function mj(e,t){let n=Ct(),r=new Ate,i=Ite(e,t.returnType);for(let{type:s,description:o}of i)cLe(e,n,t,r,s,o);return n.wrap(r.values())}function Ite(e,t,n){let r=Kn(e);if(!r.union.is(t)||r.union.getDiscriminatedUnion(t))return[{type:t,description:n}];let i=ei(e,t)??n,s=[],o=[];for(let l of t.variants.values()){if(Zg(l.type))continue;let c=Ite(e,l.type,ei(e,l)??i);for(let u of c)if(fLe(e,u.type))s.push(u.type);else o.push(u)}let a=[];if(s.length===1)a.push({type:s[0],description:i});else if(s.length>1){let l=o.length===0?t:r.union.create(s);a.push({type:l,description:i})}return a.push(...o),a}class Ate{#e=new Map;get(e){return this.#e.get(this.#t(e))}set(e,t){this.#e.set(this.#t(e),t)}values(){return[...this.#e.values()]}#t(e){if(typeof e==="number"||e==="*")return String(e);else return`${e.start}-${e.end}`}}function cLe(e,t,n,r,i,s){let o=pp(e,n),{body:a,metadata:l}=t.pipe(Ry(e,i,An.Read,Kr.Response,{treatContentTypeAsHeader:o==="head"})),c=t.pipe(uLe(e,i,l)),u=pLe(e,l);if(c.length===0)if(fc(e,i))c.push("*");else if(Im(i))a=void 0,c.push(204);else if(a===void 0||Im(a.type))a=void 0,c.push(200);else c.push(200);for(let p of c){let d=r.get(p)??{statusCodes:p,type:i,description:mLe(e,n,i,p,l,s),responses:[]};if(a!==void 0)d.responses.push({body:a,headers:u,properties:l});else d.responses.push({headers:u,properties:l});r.set(p,d)}}function uLe(e,t,n){let r=[],i=Ct(),s=!1;for(let o of n)if(o.kind==="statusCode"){if(s)As(e,{code:"multiple-status-codes",target:t});s=!0,r.push(...i.pipe(HR(e,o.property)))}if(t.kind==="Model")for(let o=t;o;o=o.baseModel)r.push(...Rte(e,o));return i.wrap(r)}function Rte(e,t){return e.stateMap(Qt.statusCode).get(t)??[]}function pLe(e,t){let n={};for(let r of t)if(r.kind==="header")n[r.options.name]=r.property;return n}function dLe(e){return e.some((t)=>t.kind==="body"||t.kind==="bodyRoot"||t.kind==="multipartBody"||t.kind==="statusCode")}function fLe(e,t){if(Im(t)||fc(e,t))return!1;if(t.kind==="Model"&&Rte(e,t).length>0)return!1;let[n]=Ry(e,t,An.Read,Kr.Response);return!n||!n.metadata.some((r)=>r.kind!=="bodyProperty")}function mLe(e,t,n,r,i,s){if(s)return s;if(dLe(i)){let a=ei(e,n);if(a)return a}let o=fc(e,n)?AP(e,t):$P(e,t);if(o)return o;return zR(r)}var yLe=Symbol.for("@typespec/http.httpOperationCache");function yj(e,t,n){if(!n)return fj(e,yLe,t,()=>eS(e,t,n,new Map));return eS(e,t,n,new Map)}function eS(e,t,n,r){let i=r.get(t);if(i)return[i,[]];let s=Ct(),o={operation:t};r.set(t,o);let a=GP(e,t),l;if(a)l=o.overloading=s.pipe(eS(e,a,n,r));let c=s.pipe(YT(e,t,l,n??{})),u=s.pipe(mj(e,t)),p=nj(e,t),d={path:c.path,uriTemplate:c.uriTemplate,verb:c.parameters.verb,container:t.interface??t.namespace??e.getGlobalNamespaceType(),parameters:c.parameters,responses:u,operation:t,authentication:p};Object.assign(o,d);let f=xD(e,t);if(f)o.overloads=f.map((m)=>s.pipe(eS(e,m,n,r)));return s.wrap(o)}await st();ka();await st();var gLe=K$(({program:e,target:t})=>{if(t.kind!=="Operation")return;let[n]=yj(e,t);if(!n)return;let r=[`\`HTTP Route\`: \`${n.verb.toUpperCase()} ${n.uriTemplate}\``],i=n.responses.map((s)=>bLe(s.statusCodes));if(i.length>0)r.push(`\`Responses\`: ${i.map((s)=>`\`${s}\``).join(", ")}`);return{content:r.join(` -`)}});function gLe(e){if(e==="*")return"*";if(typeof e==="number")return String(e);return`${e.start}-${e.end}`}await _j();await st();var FLe=nr({name:"@typespec/versioning",diagnostics:{"versioned-dependency-tuple":{severity:"error",messages:{default:"Versioned dependency mapping must be a tuple [SourceVersion, TargetVersion]."}},"versioned-dependency-tuple-enum-member":{severity:"error",messages:{default:"Versioned dependency mapping must be between enum members."}},"versioned-dependency-same-namespace":{severity:"error",messages:{default:"Versioned dependency mapping must all point to the same namespace but 2 versions have different namespaces 'namespace1' and 'namespace2'."}},"versioned-dependency-not-picked":{severity:"error",messages:{default:M`The versionedDependency decorator must provide a version of the dependency '${"dependency"}'.`}},"version-not-found":{severity:"error",messages:{default:M`The provided version '${"version"}' from '${"enumName"}' is not declared as a version enum. Use '@versioned(${"enumName"})' on the containing namespace.`}},"version-duplicate":{severity:"error",messages:{default:M`Multiple versions from '${"name"}' resolve to the same value. Version enums must resolve to unique values.`}},"invalid-renamed-from-value":{severity:"error",messages:{default:"@renamedFrom.oldName cannot be empty string."}},"incompatible-versioned-reference":{severity:"error",messages:{default:M`'${"sourceName"}' is referencing versioned type '${"targetName"}' but is not versioned itself.`,addedAfter:M`'${"sourceName"}' was added in version '${"sourceAddedOn"}' but referencing type '${"targetName"}' added in version '${"targetAddedOn"}'.`,dependentAddedAfter:M`'${"sourceName"}' was added in version '${"sourceAddedOn"}' but contains type '${"targetName"}' added in version '${"targetAddedOn"}'.`,removedBefore:M`'${"sourceName"}' was removed in version '${"sourceRemovedOn"}' but referencing type '${"targetName"}' removed in version '${"targetRemovedOn"}'.`,dependentRemovedBefore:M`'${"sourceName"}' was removed in version '${"sourceRemovedOn"}' but contains type '${"targetName"}' removed in version '${"targetRemovedOn"}'.`,versionedDependencyAddedAfter:M`'${"sourceName"}' is referencing type '${"targetName"}' added in version '${"targetAddedOn"}' but version used is '${"dependencyVersion"}'.`,versionedDependencyRemovedBefore:M`'${"sourceName"}' is referencing type '${"targetName"}' removed in version '${"targetAddedOn"}' but version used is '${"dependencyVersion"}'.`,doesNotExist:M`'${"sourceName"}' is referencing type '${"targetName"}' which does not exist in version '${"version"}'.`}},"incompatible-versioned-namespace-use-dependency":{severity:"error",messages:{default:"The useDependency decorator can only be used on a Namespace if the namespace is unversioned. For versioned namespaces, put the useDependency decorator on the version enum members."}},"made-optional-not-optional":{severity:"error",messages:{default:M`Property '${"name"}' marked with @madeOptional but is required. Should be '${"name"}?'`}},"made-required-optional":{severity:"error",messages:{default:M`Property '${"name"}?' marked with @madeRequired but is optional. Should be '${"name"}'`}},"renamed-duplicate-property":{severity:"error",messages:{default:M`Property '${"name"}' marked with '@renamedFrom' conflicts with existing property in version ${"version"}.`}}},state:{versionIndex:{description:"Version index"},addedOn:{description:"State for @addedOn decorator"},removedOn:{description:"State for @removedOn decorator"},versions:{description:"State for @versioned decorator"},useDependencyNamespace:{description:"State for @useDependency decorator on Namespaces"},useDependencyEnum:{description:"State for @useDependency decorator on Enums"},renamedFrom:{description:"State for @renamedFrom decorator"},madeOptional:{description:"State for @madeOptional decorator"},madeRequired:{description:"State for @madeRequired decorator"},typeChangedFrom:{description:"State for @typeChangedFrom decorator"},returnTypeChangedFrom:{description:"State for @returnTypeChangedFrom decorator"}}}),{reportDiagnostic:Mte,createStateSymbol:uRt,stateKeys:CLe}=FLe;await st();await st();await st();await st();var xj;(function(e){e.Unavailable="Unavailable",e.Added="Added",e.Available="Available",e.Removed="Removed"})(xj||(xj={}));Nn();await st();await st();var Lte=nr({name:"@typespec/rest",diagnostics:{"not-key-type":{severity:"error",messages:{default:"Cannot copy keys from a non-key type (KeysOf or ParentKeysOf)"}},"resource-missing-key":{severity:"error",messages:{default:M`Type '${"modelName"}' is used as a resource and therefore must have a key. Use @key to designate a property as the key.`}},"resource-missing-error":{severity:"error",messages:{default:M`Type '${"modelName"}' is used as an error and therefore must have the @error decorator applied.`}},"duplicate-key":{severity:"error",messages:{default:M`More than one key found on model type ${"resourceName"}`}},"duplicate-parent-key":{severity:"error",messages:{default:M`Resource type '${"resourceName"}' has a key property named '${"keyName"}' which conflicts with the key name of a parent or child resource.`}},"invalid-action-name":{severity:"error",messages:{default:"Action name cannot be empty string."}},"shared-route-unspecified-action-name":{severity:"error",messages:{default:M`An operation marked as '@sharedRoute' must have an explicit collection action name passed to '${"decoratorName"}'.`}},"circular-parent-resource":{severity:"error",messages:{default:M`Resource has a parent cycle (${"cycle"})`}}}}),{reportDiagnostic:nS,createDiagnostic:zRt,createStateSymbol:Mi}=Lte;var rjt=Mi("resourceKeys"),JLe=Mi("resourceTypeForKeyParam");function qte(e,t,n){e.program.stateMap(JLe).set(t,n)}zd("Private",qte);var[GLe,ijt]=ze(Mi("parentResourceTypes"));await st();var Ute;try{Ute=(await _j().then(() => Cte)).getStreamOf}catch{Ute=()=>{throw Error("@typespec/streams was not found")}}var bjt=Mi("autoRoute");var vjt=Mi("segments");var _jt=Mi("actionSeparator");var xjt=Mi("resourceOperations");var Vte=Mi("actionSegment"),Kte=(e,t,n)=>{e.program.stateMap(Vte).set(t,n)};function zLe(e,t){return e.stateMap(Vte).get(t)}var wjt=Mi("actions");var Djt=Mi("collectionActions");var WLe=Mi("resourceLocations"),Jte=(e,t,n)=>{if(n.kind==="TemplateParameter")return;e.program.stateMap(WLe).set(t,n)};zd("Private",Jte,Kte,zLe);Nn();await st();await st();var sFt=Mi("validatedMissing");var oFt=Mi("validatedError");Nn();await st();await st();await st();var Gte=nr({name:"@typespec/openapi",diagnostics:{"invalid-extension-key":{severity:"error",messages:{default:M`OpenAPI extension must start with 'x-' but was '${"value"}'`}},"duplicate-type-name":{severity:"error",messages:{default:M`Duplicate type name: '${"value"}'. Check @friendlyName decorators and overlap with types in TypeSpec or service namespace.`,parameter:M`Duplicate parameter key: '${"value"}'. Check @friendlyName decorators and overlap with types in TypeSpec or service namespace.`}},"not-url":{severity:"error",messages:{default:M`${"property"}: ${"value"} is not a valid URL.`}},"duplicate-tag":{severity:"error",messages:{default:M`"Metadata for tag '${"tagName"}' was specified twice."`}},"mixed-tag-metadata-form":{severity:"error",messages:{default:'Cannot mix the array form and the inline form of @tagMetadata on the same namespace. Use either @tagMetadata(#[...]) or multiple @tagMetadata("name", #{...}) calls, not both.'}},"tag-metadata-array-with-metadata-arg":{severity:"error",messages:{default:"When using the array form of @tagMetadata, the second argument (tagMetadata) must not be provided. Include all tag metadata inside the array elements."}},"tag-metadata-target-service":{severity:"error",messages:{default:M`@tagMetadata must be used on the service namespace. Did you mean to annotate '${"namespace"}' with '@service'?`}},"default-response-with-status-code":{severity:"warning",messages:{statusCode:"@defaultResponse should not be used on a model that already has a status code defined. The status code will be ignored in favor of the default response.",error:"@defaultResponse should not be used on a model that is marked with @error. Use either @defaultResponse or @error, not both."}},"license-url-identifier-conflict":{severity:"error",messages:{default:"License 'url' and 'identifier' are mutually exclusive. Specify only one of them."}}},state:{tagsMetadata:{description:"State for the @tagMetadata decorator."}}}),{createDiagnostic:Hte,reportDiagnostic:zte,createStateSymbol:sf,stateKeys:Wte}=Gte;var[XLe,_Ft]=ze(sf("operationIds"));var xFt=sf("openApiExtension");var wFt=sf("defaultResponse");var DFt=sf("externalDocs");var TFt=sf("info");var[SFt,EFt]=ze(Wte.tagsMetadata),[kFt,NFt]=hr(sf("tagsMetadataArrayForm"));await vj();var Qte={"@typespec/http":{version:"1.16.0",files:{"package.json":`{ +`)}});function bLe(e){if(e==="*")return"*";if(typeof e==="number")return String(e);return`${e.start}-${e.end}`}await _j();await st();var CLe=nr({name:"@typespec/versioning",diagnostics:{"versioned-dependency-tuple":{severity:"error",messages:{default:"Versioned dependency mapping must be a tuple [SourceVersion, TargetVersion]."}},"versioned-dependency-tuple-enum-member":{severity:"error",messages:{default:"Versioned dependency mapping must be between enum members."}},"versioned-dependency-same-namespace":{severity:"error",messages:{default:"Versioned dependency mapping must all point to the same namespace but 2 versions have different namespaces 'namespace1' and 'namespace2'."}},"versioned-dependency-not-picked":{severity:"error",messages:{default:M`The versionedDependency decorator must provide a version of the dependency '${"dependency"}'.`}},"version-not-found":{severity:"error",messages:{default:M`The provided version '${"version"}' from '${"enumName"}' is not declared as a version enum. Use '@versioned(${"enumName"})' on the containing namespace.`}},"version-duplicate":{severity:"error",messages:{default:M`Multiple versions from '${"name"}' resolve to the same value. Version enums must resolve to unique values.`}},"invalid-renamed-from-value":{severity:"error",messages:{default:"@renamedFrom.oldName cannot be empty string."}},"incompatible-versioned-reference":{severity:"error",messages:{default:M`'${"sourceName"}' is referencing versioned type '${"targetName"}' but is not versioned itself.`,addedAfter:M`'${"sourceName"}' was added in version '${"sourceAddedOn"}' but referencing type '${"targetName"}' added in version '${"targetAddedOn"}'.`,dependentAddedAfter:M`'${"sourceName"}' was added in version '${"sourceAddedOn"}' but contains type '${"targetName"}' added in version '${"targetAddedOn"}'.`,removedBefore:M`'${"sourceName"}' was removed in version '${"sourceRemovedOn"}' but referencing type '${"targetName"}' removed in version '${"targetRemovedOn"}'.`,dependentRemovedBefore:M`'${"sourceName"}' was removed in version '${"sourceRemovedOn"}' but contains type '${"targetName"}' removed in version '${"targetRemovedOn"}'.`,versionedDependencyAddedAfter:M`'${"sourceName"}' is referencing type '${"targetName"}' added in version '${"targetAddedOn"}' but version used is '${"dependencyVersion"}'.`,versionedDependencyRemovedBefore:M`'${"sourceName"}' is referencing type '${"targetName"}' removed in version '${"targetAddedOn"}' but version used is '${"dependencyVersion"}'.`,doesNotExist:M`'${"sourceName"}' is referencing type '${"targetName"}' which does not exist in version '${"version"}'.`}},"incompatible-versioned-namespace-use-dependency":{severity:"error",messages:{default:"The useDependency decorator can only be used on a Namespace if the namespace is unversioned. For versioned namespaces, put the useDependency decorator on the version enum members."}},"made-optional-not-optional":{severity:"error",messages:{default:M`Property '${"name"}' marked with @madeOptional but is required. Should be '${"name"}?'`}},"made-required-optional":{severity:"error",messages:{default:M`Property '${"name"}?' marked with @madeRequired but is optional. Should be '${"name"}'`}},"renamed-duplicate-property":{severity:"error",messages:{default:M`Property '${"name"}' marked with '@renamedFrom' conflicts with existing property in version ${"version"}.`}}},state:{versionIndex:{description:"Version index"},addedOn:{description:"State for @addedOn decorator"},removedOn:{description:"State for @removedOn decorator"},versions:{description:"State for @versioned decorator"},useDependencyNamespace:{description:"State for @useDependency decorator on Namespaces"},useDependencyEnum:{description:"State for @useDependency decorator on Enums"},renamedFrom:{description:"State for @renamedFrom decorator"},madeOptional:{description:"State for @madeOptional decorator"},madeRequired:{description:"State for @madeRequired decorator"},typeChangedFrom:{description:"State for @typeChangedFrom decorator"},returnTypeChangedFrom:{description:"State for @returnTypeChangedFrom decorator"}}}),{reportDiagnostic:Mte,createStateSymbol:dRt,stateKeys:MLe}=CLe;await st();await st();await st();await st();var xj;(function(e){e.Unavailable="Unavailable",e.Added="Added",e.Available="Available",e.Removed="Removed"})(xj||(xj={}));Nn();await st();await st();var Lte=nr({name:"@typespec/rest",diagnostics:{"not-key-type":{severity:"error",messages:{default:"Cannot copy keys from a non-key type (KeysOf or ParentKeysOf)"}},"resource-missing-key":{severity:"error",messages:{default:M`Type '${"modelName"}' is used as a resource and therefore must have a key. Use @key to designate a property as the key.`}},"resource-missing-error":{severity:"error",messages:{default:M`Type '${"modelName"}' is used as an error and therefore must have the @error decorator applied.`}},"duplicate-key":{severity:"error",messages:{default:M`More than one key found on model type ${"resourceName"}`}},"duplicate-parent-key":{severity:"error",messages:{default:M`Resource type '${"resourceName"}' has a key property named '${"keyName"}' which conflicts with the key name of a parent or child resource.`}},"invalid-action-name":{severity:"error",messages:{default:"Action name cannot be empty string."}},"shared-route-unspecified-action-name":{severity:"error",messages:{default:M`An operation marked as '@sharedRoute' must have an explicit collection action name passed to '${"decoratorName"}'.`}},"circular-parent-resource":{severity:"error",messages:{default:M`Resource has a parent cycle (${"cycle"})`}}}}),{reportDiagnostic:nS,createDiagnostic:QRt,createStateSymbol:Mi}=Lte;var sjt=Mi("resourceKeys"),GLe=Mi("resourceTypeForKeyParam");function qte(e,t,n){e.program.stateMap(GLe).set(t,n)}Qd("Private",qte);var[HLe,ojt]=ze(Mi("parentResourceTypes"));await st();var Ute;try{Ute=(await _j().then(() => Cte)).getStreamOf}catch{Ute=()=>{throw Error("@typespec/streams was not found")}}var _jt=Mi("autoRoute");var xjt=Mi("segments");var wjt=Mi("actionSeparator");var Djt=Mi("resourceOperations");var Vte=Mi("actionSegment"),Kte=(e,t,n)=>{e.program.stateMap(Vte).set(t,n)};function WLe(e,t){return e.stateMap(Vte).get(t)}var Tjt=Mi("actions");var Sjt=Mi("collectionActions");var QLe=Mi("resourceLocations"),Jte=(e,t,n)=>{if(n.kind==="TemplateParameter")return;e.program.stateMap(QLe).set(t,n)};Qd("Private",Jte,Kte,WLe);Nn();await st();await st();var aFt=Mi("validatedMissing");var lFt=Mi("validatedError");Nn();await st();await st();await st();var Gte=nr({name:"@typespec/openapi",diagnostics:{"invalid-extension-key":{severity:"error",messages:{default:M`OpenAPI extension must start with 'x-' but was '${"value"}'`}},"duplicate-type-name":{severity:"error",messages:{default:M`Duplicate type name: '${"value"}'. Check @friendlyName decorators and overlap with types in TypeSpec or service namespace.`,parameter:M`Duplicate parameter key: '${"value"}'. Check @friendlyName decorators and overlap with types in TypeSpec or service namespace.`}},"not-url":{severity:"error",messages:{default:M`${"property"}: ${"value"} is not a valid URL.`}},"duplicate-tag":{severity:"error",messages:{default:M`"Metadata for tag '${"tagName"}' was specified twice."`}},"mixed-tag-metadata-form":{severity:"error",messages:{default:'Cannot mix the array form and the inline form of @tagMetadata on the same namespace. Use either @tagMetadata(#[...]) or multiple @tagMetadata("name", #{...}) calls, not both.'}},"tag-metadata-array-with-metadata-arg":{severity:"error",messages:{default:"When using the array form of @tagMetadata, the second argument (tagMetadata) must not be provided. Include all tag metadata inside the array elements."}},"tag-metadata-target-service":{severity:"error",messages:{default:M`@tagMetadata must be used on the service namespace. Did you mean to annotate '${"namespace"}' with '@service'?`}},"default-response-with-status-code":{severity:"warning",messages:{statusCode:"@defaultResponse should not be used on a model that already has a status code defined. The status code will be ignored in favor of the default response.",error:"@defaultResponse should not be used on a model that is marked with @error. Use either @defaultResponse or @error, not both."}},"license-url-identifier-conflict":{severity:"error",messages:{default:"License 'url' and 'identifier' are mutually exclusive. Specify only one of them."}}},state:{tagsMetadata:{description:"State for the @tagMetadata decorator."}}}),{createDiagnostic:Hte,reportDiagnostic:zte,createStateSymbol:af,stateKeys:Wte}=Gte;var[ZLe,wFt]=ze(af("operationIds"));var DFt=af("openApiExtension");var TFt=af("defaultResponse");var SFt=af("externalDocs");var EFt=af("info");var[kFt,NFt]=ze(Wte.tagsMetadata),[OFt,PFt]=hr(af("tagsMetadataArrayForm"));await vj();var Qte={"@typespec/http":{version:"1.16.0",files:{"package.json":`{ "name": "@typespec/http", "version": "1.16.0", "author": "Microsoft Corporation", @@ -4198,11 +4198,11 @@ extern dec contentType(target: UnionVariant | ModelProperty, contentType: valueo extern dec data(target: ModelProperty); `,"lib/main.tsp":`import "../dist/src/tsp-index.js"; import "./decorators.tsp"; -`}}};var rS=Qte;var wj={id:"umf.typespec",version:"0.1.0",coreVersion:"0.1.0",description:"TypeSpec source bundles with pinned syntax and supplied-file compilation",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:typespec:0.1.0",type:"object",required:["profile","entrypoint","files"],properties:{profile:{const:"typespec-1.16.0-sources"},entrypoint:{type:"string",minLength:1},files:{type:"object",minProperties:1,propertyNames:{type:"string",minLength:1},additionalProperties:{type:"string"}},libraries:{type:"object",propertyNames:{type:"string",minLength:1},additionalProperties:{type:"string",minLength:1}}}},scopes:["element"],semantics:"CONTRACT-013. Exact source files and explicit entrypoint; compiler validity and downstream projection fidelity are separate.",capabilities:{validation:"semantic",directions:["import","export"],native:{system:"TypeSpec",version:"1.16.0",subset:"Supplied .tsp sources with pinned compiler/standard library and eleven explicitly selected official library versions; library-owned configuration retained; separate pinned JSON Schema emission API; no arbitrary project JavaScript or lossless projection claim"},evidence:["tests/typespec/native.test.ts","fixtures/typespec/compiler-oracle-results.json","spec/extensions/typespec/standard-manifest.json","tests/typespec/semantic.test.ts","fixtures/typespec/semantic-oracle-results.json","tests/typespec/corpus.test.ts","fixtures/typespec/upstream/manifest.json","fixtures/typespec/corpus-results.json","fixtures/typespec/corpus-oracle-results.json","tests/typespec/libraries.test.ts","spec/extensions/typespec/libraries-manifest.json","fixtures/typespec/library-corpus-results.json","fixtures/typespec/library-corpus-oracle-results.json","tests/typespec/all-libraries.test.ts","fixtures/typespec/all-library-corpus-results.json","fixtures/typespec/all-library-corpus-oracle-results.json","tests/typespec/emission.test.ts","fixtures/typespec/emission-oracle-results.json","fixtures/typespec/emission-json-oracle-results.json","fixtures/typespec/emission/numeric.tsp","fixtures/typespec/emission/numeric-oracle-results.json","tests/typespec/projection.test.ts","fixtures/typespec/emission/projection-oracle-results.json"]}};ka();await st();await st();await st();var l2e=new Set(["modelPropertyReference","enumMemberReference"]);var pCt=new Set([...l2e,"booleanLiteral","stringTemplate","stringLiteral","numericLiteral","scalarInstantiation","enumMember","enumMembers","intrinsic"]);await st();await st();var _Ct=Symbol("placeholder"),xCt=Symbol("ObjectBuilder.set");Nn();bo();await st();await st();FR();jR();await st();var ene="umf.typespec",_2e=wj,x2e=mt().compile(wj.schema);function w2e(e){let t=e,n=[];for(let i of Object.keys(t))if(!["profile","entrypoint","files","libraries"].includes(i))n.push({code:"TYPESPEC_REPRESENTATION",path:"/"+Pe(i),severity:"warning",message:"Unknown source representation field cannot be emitted natively"});for(let[i,s]of Object.entries(t.libraries??{}))if(!Object.hasOwn(rS,i)||rS[i].version!==s)n.push({code:"TYPESPEC_LIBRARY_UNAVAILABLE",path:"/libraries/"+Pe(i),severity:"warning",message:"Unregistered library selection retained: "+i+"@"+s});if(!Object.hasOwn(t.files,t.entrypoint))n.push({code:"TYPESPEC_ENTRYPOINT",path:"/entrypoint",severity:"error",message:"Entrypoint must name a supplied file"});let r=0;for(let[i,s]of Object.entries(t.files)){if(!/^(?:[A-Za-z0-9_.-]+\/)*[A-Za-z0-9_.-]+\.tsp$/.test(i)||i.split("/").some((o)=>o==="."||o==="..")){n.push({code:"TYPESPEC_PATH",path:"/files/"+Pe(i),severity:"error",message:"Source paths must be relative .tsp paths without traversal"});continue}if(r+=s.length,r>Zt.maxTextLength){n.push({code:"LIMIT",path:"/files",severity:"error",message:"Source bundle exceeds text limit"});break}try{for(let o of Cd(s,{comments:!0,docs:!0}).parseDiagnostics)n.push({code:"TYPESPEC_"+o.code,path:"/files/"+Pe(i),severity:o.severity,message:o.message})}catch(o){n.push({code:"TYPESPEC_PARSE",path:"/files/"+Pe(i),severity:"error",message:String(o)})}}return n.push({code:"TYPESPEC_COMPILATION_REQUIRED",path:"",severity:"warning",message:"Syntax preservation does not establish compiler validity; call compileTypeSpecDocument with supplied imports"}),n}function D2e(){return new nt().register(_2e,w2e)}function tne(e){return We(e,D2e())}function T2e(e){let t=tne(e);if(!t.valid)throw new U("TYPESPEC_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[ene];if(e.vocabularies[ene]?.version!=="0.1.0"||!x2e(n))throw new U("TYPESPEC_PAYLOAD","Missing TypeSpec source bundle");return Ae(n)}function nne(e){let t=T2e(e);if(tne(e).diagnostics.some((n)=>n.code==="TYPESPEC_REPRESENTATION"))throw new U("TYPESPEC_REPRESENTATION","Native export would discard unknown content");return{entrypoint:t.entrypoint,files:t.files,...t.libraries?{libraries:t.libraries}:{}}}function rne(e){let t=e,n=[];for(let i of Object.keys(t))if(!["profile","files"].includes(i))n.push({code:"SMITHY_REPRESENTATION",path:"/"+Pe(i),severity:"warning",message:"Unknown source representation field has no native destination"});let r=0;for(let[i,s]of Object.entries(t.files)){if(!/^(?:[A-Za-z0-9_.-]+\/)*[A-Za-z0-9_.-]+\.(?:smithy|json)$/.test(i)||i.split("/").some((o)=>o==="."||o===".."))n.push({code:"SMITHY_SOURCE_PATH",path:"/files/"+Pe(i),severity:"error",message:"Sources require relative .smithy/.json paths without traversal"});r+=s.length}if(r>Zt.maxTextLength)n.push({code:"LIMIT",path:"/files",severity:"error",message:"Source bundle exceeds text limit"});return n.push({code:"SMITHY_SOURCE_UNVALIDATED",path:"/files",severity:"warning",message:"Source text is preserved without browser parsing or assembly; syntax and semantic validity require native compilation"}),n}var ine={id:"umf.smithy",version:"0.1.0",coreVersion:"0.1.0",description:"Smithy JSON AST and exact supplied IDL/JSON source bundles with explicit validation limits",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:smithy:0.1.0",$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}},oneOf:[{type:"object",required:["profile","root"],properties:{profile:{const:"smithy-json-ast"},root:{$ref:"#/$defs/node"},dependencies:{type:"array",items:{type:"object",required:["id","root"],properties:{id:{type:"string",minLength:1},root:{$ref:"#/$defs/node"}}}}}},{type:"object",required:["profile","files"],properties:{profile:{const:"smithy-idl-sources"},files:{type:"object",minProperties:1,additionalProperties:{type:"string"}}}}]},scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Smithy JSON AST",version:"2.0; external smithy-model 1.73.0",subset:"Exact JSON AST roots/dependencies and supplied IDL/JSON source files. Browser checks AST structure or source archive shape only; parsing, assembly, selectors, trait semantics and projections remain separately qualified. Optional pinned JavaScript assembly is explicit through a trusted backend; known reflection limitations and source normalization are reported."},evidence:["tests/smithy/native.test.ts","fixtures/smithy/oracle-results.json","tests/smithy/bundle.test.ts","fixtures/smithy/bundles/oracle-results.json","tests/smithy/sources.test.ts","fixtures/smithy/idl/oracle-results.json","tests/smithy/assembly.test.ts","fixtures/smithy/assembly-oracle-results.json"]},semantics:"CONTRACT-014. Exact native JSON AST retention and structural inspection; browser validity is not native semantic validity. Traits, references, mixins and model assembly require separate evidence."};var sne={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:smithy:native-structure:0.1.0",type:"object",required:["smithy"],properties:{smithy:{type:"string"},metadata:{type:"object"},shapes:{type:"object",propertyNames:{type:"string",pattern:"^[A-Za-z_][A-Za-z_0-9]*(\\.[A-Za-z_][A-Za-z_0-9]*)*#[A-Za-z_][A-Za-z_0-9]*(\\$[A-Za-z_][A-Za-z_0-9]*)?$"},additionalProperties:{$ref:"#/$defs/shape"}}},$defs:{reference:{type:"object",required:["target"],properties:{target:{type:"string",pattern:"^[A-Za-z_][A-Za-z_0-9]*(\\.[A-Za-z_][A-Za-z_0-9]*)*#[A-Za-z_][A-Za-z_0-9]*(\\$[A-Za-z_][A-Za-z_0-9]*)?$"}}},member:{type:"object",required:["target"],properties:{target:{type:"string",pattern:"^[A-Za-z_][A-Za-z_0-9]*(\\.[A-Za-z_][A-Za-z_0-9]*)*#[A-Za-z_][A-Za-z_0-9]*(\\$[A-Za-z_][A-Za-z_0-9]*)?$"},traits:{type:"object"}}},shape:{type:"object",required:["type"],properties:{type:{type:"string"},traits:{type:"object"},mixins:{type:"array",items:{$ref:"#/$defs/reference"}}},allOf:[{if:{properties:{type:{enum:["list"]}}},then:{properties:{member:{$ref:"#/$defs/member"}},anyOf:[{required:["member"]},{required:["mixins"],properties:{mixins:{minItems:1}}}]}},{if:{properties:{type:{enum:["map"]}}},then:{properties:{key:{$ref:"#/$defs/member"},value:{$ref:"#/$defs/member"}},anyOf:[{required:["key","value"]},{required:["mixins"],properties:{mixins:{minItems:1}}}]}},{if:{properties:{type:{enum:["structure","union","enum","intEnum"]}}},then:{properties:{members:{type:"object",additionalProperties:{$ref:"#/$defs/member"}}},required:[]}},{if:{properties:{type:{enum:["service"]}}},then:{properties:{version:{type:"string"},operations:{type:"array",items:{$ref:"#/$defs/reference"}},resources:{type:"array",items:{$ref:"#/$defs/reference"}},errors:{type:"array",items:{$ref:"#/$defs/reference"}},rename:{type:"object",additionalProperties:{type:"string"}}},required:[]}},{if:{properties:{type:{enum:["operation"]}}},then:{properties:{input:{$ref:"#/$defs/reference"},output:{$ref:"#/$defs/reference"},errors:{type:"array",items:{$ref:"#/$defs/reference"}}},required:[]}},{if:{properties:{type:{enum:["resource"]}}},then:{properties:{operations:{type:"array",items:{$ref:"#/$defs/reference"}},collectionOperations:{type:"array",items:{$ref:"#/$defs/reference"}},resources:{type:"array",items:{$ref:"#/$defs/reference"}},create:{$ref:"#/$defs/reference"},put:{$ref:"#/$defs/reference"},read:{$ref:"#/$defs/reference"},update:{$ref:"#/$defs/reference"},delete:{$ref:"#/$defs/reference"},list:{$ref:"#/$defs/reference"},identifiers:{type:"object",additionalProperties:{$ref:"#/$defs/reference"}},properties:{type:"object",additionalProperties:{$ref:"#/$defs/reference"}}},required:[]}}]}}};var kv="umf.smithy",k2e=ine,one=mt(!1).compile(sne),N2e=new Set("blob boolean document string byte short integer long float double bigInteger bigDecimal timestamp list map structure union enum intEnum service resource operation apply".split(" "));function O2e(e){if(e.profile==="smithy-idl-sources")return rne(e);let t=e,n=[],r=(o,a,l,c="warning")=>n.push({code:o,path:a,message:l,severity:c});for(let o of Object.keys(t))if(!["profile","root","dependencies"].includes(o))r("SMITHY_REPRESENTATION","/"+Pe(o),"Unknown representation field cannot be exported");function i(o,a){let l=o.kind==="null"?["kind"]:o.kind==="object"?["kind","members"]:o.kind==="array"?["kind","items"]:["kind","value"];for(let c of Object.keys(o))if(!l.includes(c))r("SMITHY_REPRESENTATION",a+"/"+Pe(c),"Unknown tagged-tree field cannot be exported");if(o.kind==="object")for(let[c,u]of Object.entries(o.members))i(u,a+"/members/"+Pe(c));if(o.kind==="array")o.items.forEach((c,u)=>i(c,a+"/items/"+u))}let s=new Set;for(let[o,a]of(t.dependencies??[]).entries()){if(s.has(a.id))r("SMITHY_DEPENDENCY_ID","/dependencies/"+o+"/id","Duplicate dependency ID","error");s.add(a.id);for(let l of Object.keys(a))if(!["id","root"].includes(l))r("SMITHY_REPRESENTATION","/dependencies/"+o+"/"+Pe(l),"Unknown dependency representation field cannot be exported")}for(let{root:o,path:a}of[{root:t.root,path:"/root"},...(t.dependencies??[]).map((l,c)=>({root:l.root,path:"/dependencies/"+c+"/root"}))]){i(o,a);let l=JSON.parse(Be(o));if(!one(l))r("SMITHY_STRUCTURE",a,JSON.stringify(one.errors),"error");if(o.kind!=="object")continue;let c=o.members;if(c.smithy?.kind==="string"&&!["2","2.0"].includes(c.smithy.value))r("SMITHY_VERSION",a+"/smithy","Uninterpreted Smithy version retained");for(let u of Object.keys(c))if(!["smithy","shapes","metadata"].includes(u))r("SMITHY_NATIVE_FIELD",a+"/"+Pe(u),"Unknown native content retained");if(c.shapes?.kind==="object"){for(let[u,p]of Object.entries(c.shapes.members))if(p.kind==="object"){let d=p.members.type;if(d?.kind==="string"&&!N2e.has(d.value))r("SMITHY_SHAPE_TYPE",a+"/shapes/"+Pe(u)+"/type","Unknown shape type retained")}}}return r("SMITHY_ASSEMBLY_REQUIRED","/root","Browser checks AST structure only. Native assembly, references, mixins, trait selectors and semantic validation require a separate Smithy model oracle"),n}function P2e(){return new nt().register(k2e,O2e)}function Nv(e){return We(e,P2e())}function $2e(e){let t=Nv(e);if(!t.valid)throw new U("SMITHY_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[kv];if(!n||e.vocabularies[kv]?.version!=="0.1.0")throw new U("SMITHY_PAYLOAD","Missing Smithy payload");if(n.profile!=="smithy-json-ast")throw new U("SMITHY_PROFILE","This operation requires a JSON AST profile");return Ae(n)}function I2e(e){let t=$2e(e);if(Nv(e).diagnostics.some((n)=>n.code==="SMITHY_REPRESENTATION"))throw new U("SMITHY_REPRESENTATION","Unknown representation content cannot be discarded");return t}function ane(e){let t=I2e(e);if(t.dependencies?.length)throw new U("SMITHY_DEPENDENCIES_REQUIRED","Use exportSmithyBundle to retain supplied dependencies");return Be(t.root)+` -`}function A2e(e){let t=Nv(e);if(!t.valid)throw new U("SMITHY_SOURCES",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[kv];if(n?.profile!=="smithy-idl-sources"||e.vocabularies[kv]?.version!=="0.1.0")throw new U("SMITHY_PROFILE","This operation requires supplied source files");return Ae(n)}function lne(e){let t=A2e(e);if(Nv(e).diagnostics.some((n)=>n.code==="SMITHY_REPRESENTATION"))throw new U("SMITHY_REPRESENTATION","Native source export would discard unknown content");return{files:t.files}}var cne={id:"umf.arrow.ipc",version:"0.1.0",coreVersion:"0.1.0",description:"Exact bounded IPC source bytes independent of native decoder support",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:arrow-ipc:0.1.0",title:"Arrow IPC source capture; structural validity is not native validity",type:"object",required:["profile","encoding","bytes"],properties:{profile:{const:"arrow-ipc-source"},encoding:{const:"hex"},bytes:{type:"string",maxLength:2000000,pattern:"^(?:[0-9a-f]{2})*$"}},additionalProperties:!0},semantics:"CONTRACT-016. Archive capture accepts uninterpreted or invalid input; it makes no native format validity claim. Schema observations are derived separately and never replace source.",scopes:["element"],capabilities:{validation:"structural",directions:["import","export"],native:{system:"Apache Arrow IPC source bytes",version:"Capture profile 0.1.0; optional observations apache-arrow 21.2.0",subset:"Exact original bytes up to 1000000 bytes, including unrecognized and invalid content. No semantic edits, complete framing validation or decoded data model."},evidence:["tests/arrow/capture.test.ts","fixtures/arrow/ipc-inputs/manifest.json","fixtures/arrow/upstream/results.json","fixtures/arrow/upstream/oracle-results.json"]}};var une="umf.arrow.ipc";var j2e=cne;function F2e(){return new nt().register(j2e)}function C2e(e){let t=We(e,F2e());return{...t,complete:!1,diagnostics:[...t.diagnostics,{code:"ARROW_IPC_UNINTERPRETED",path:"",severity:"warning",message:"Captured bytes are authoritative; complete IPC framing, native schema and data validity are unverified"}]}}function pne(e){if(!C2e(e).valid)throw new U("ARROW_IPC_CAPTURE","Invalid IPC capture envelope");let n=e.modules.find((s)=>s.id==="ipc")?.elements.find((s)=>s.id==="source")?.extensions[une];if(e.vocabularies[une]?.version!=="0.1.0"||!n||typeof n!=="object"||Array.isArray(n))throw new U("ARROW_IPC_CAPTURE","Expected pinned IPC capture");if(Object.keys(n).some((s)=>!["profile","encoding","bytes"].includes(s)))throw new U("ARROW_IPC_REPRESENTATION","Unknown capture representation fields cannot be exported as native bytes");let r=n.bytes,i=new Uint8Array(r.length/2);for(let s=0;s{throw n.push({code:"PARQUET_METADATA_SHAPE",path:l,severity:"error",message:c}),Error(c)},o=(l)=>l.ref?r[l.ref]?.kind==="enum"?"i32":"struct":l.kind==="string"?"binary":l.kind;function a(l,c,u){if(c.ref){let p=r[c.ref];if(!p)s(u,"Unknown IDL reference");if(p.kind==="enum"){if(l.kind!=="i32")s(u,"Expected i32 enumeration");let y=l.value;if(!Object.values(p.values).some((h)=>String(h)===y))n.push({code:"PARQUET_ENUM_UNKNOWN",path:u,severity:"warning",message:"Unknown "+c.ref+" code retained: "+y});return y}if(l.kind!=="struct")return s(u,"Expected struct "+c.ref);let d=Object.create(null),f=new Set,m=[];if(p.kind==="union"&&l.fields.length>1)s(u,"Union has more than one active field");for(let y of l.fields){let h=p.fields.find((b)=>b.id===y.id);if(h&&f.has(y.id))s(u,"Repeated field ID cannot be collapsed into named metadata: "+y.id);if(f.add(y.id),h)d[h.name]=a(y.value,h.type,u+"/"+h.name);else m.push(y),n.push({code:"PARQUET_FIELD_UNKNOWN",path:u,severity:"warning",message:"Unknown field "+y.id+" retained in $unknown"})}for(let y of p.fields)if(y.required&&!f.has(y.id))s(u+"/"+y.name,"Missing required IDL field");if(m.length)d.$unknown=m;return d}if(c.kind==="string"){if(l.kind!=="binary")return s(u,"Expected string wire bytes");try{return i.decode(Uint8Array.from(l.hex.match(/../g)??[],(p)=>Number.parseInt(p,16)))}catch{return s(u,"IDL string is not valid UTF-8")}}if(c.kind==="binary"){if(l.kind!=="binary")return s(u,"Expected binary wire value");return{hex:l.hex}}if(c.kind==="bool"){if(l.kind!=="bool")return s(u,"Expected boolean");return l.value}if(["i8","i16","i32","i64"].includes(c.kind)){if(l.kind!==c.kind)return s(u,"Integer width does not match IDL");return l.value}if(c.kind==="double"){if(l.kind!=="double")return s(u,"Expected double");return{bits:l.bits}}if(c.kind==="list"||c.kind==="set"){if(l.kind!==c.kind)return s(u,"Collection kind does not match IDL");if(l.elementType!==o(c.item))return s(u,"Collection element type does not match IDL");return l.items.map((p,d)=>a(p,c.item,u+"/"+d))}if(c.kind==="map"){if(l.kind!=="map")return s(u,"Expected map");if(l.entries.length&&(l.keyType!==o(c.key)||l.valueType!==o(c.value)))return s(u,"Map element types do not match IDL");return l.entries.map((p,d)=>({key:a(p.key,c.key,u+"/"+d+"/key"),value:a(p.value,c.value,u+"/"+d+"/value")}))}return s(u,"Unsupported IDL descriptor")}return a(e,{ref:t},"")}function yne(e){let t=0,n=0,r=()=>{if(t>=e.length)throw Error("Truncated Compact Protocol value");return e[t++]};function i(u){if(u>e.length-t)throw Error("Binary value exceeds footer region");let p=e.subarray(t,t+u);return t+=u,Array.from(p,(d)=>d.toString(16).padStart(2,"0")).join("")}function s(u){let p=0n;for(let d=0;d=1n<{let p=s(u);return p>>1n^-(p&1n)},a=()=>{let u=s(32);if(u>2147483647n)throw Error("Length exceeds signed int32");return Number(u)},l=(u)=>{let p=[void 0,"bool","bool","i8","i16","i32","i64","double","binary","list","set","map","struct","uuid"][u];if(!p)throw Error("Unknown Compact Protocol wire type "+u);return p};function c(u,p,d=!1){if(p>64||++n>50000)throw Error("Compact Protocol structural limit exceeded");let f=l(u);if(f==="bool"){let h=d?u:r();if(h!==1&&h!==2)throw Error("Invalid boolean encoding");return{kind:f,value:h===1}}if(f==="i8"){let h=r();return{kind:f,value:String(h<128?h:h-256)}}if(f==="i16"||f==="i32"||f==="i64")return{kind:f,value:o(Number(f.slice(1))).toString()};if(f==="double")return{kind:f,bits:i(8)};if(f==="uuid")return{kind:f,hex:i(16)};if(f==="binary")return{kind:f,hex:i(a())};if(f==="list"||f==="set"){let h=r(),b=h&15,g=h>>4===15?a():h>>4,x=l(b);if(g>50000-n)throw Error("Collection exceeds value limit");let v=[];for(let D=0;D50000-n)throw Error("Map exceeds value limit");let g=r(),x=g>>4,v=g&15,D=l(x),T=l(v);for(let N=0;N>4,x=g?y+g:Number(o(16));if(x<-32768||x>32767)throw Error("Field ID exceeds signed int16");y=x,m.push({id:x,value:c(b,p+1,!0)})}return{kind:"struct",fields:m}}return{value:c(12,0),consumedBytes:t}}function hne(e){let t=gne(e),n={source:t.source,status:"blocked",complete:!1,diagnostics:[...t.diagnostics]},r=(o,a)=>n.diagnostics.push({code:o,path:"",severity:"error",message:a});if(!t.footerRegion)return n;if(t.footerRegion.mode==="encrypted")return r("PARQUET_FOOTER_ENCRYPTED","Encrypted footer requires a separate decryption implementation"),n;let i=t.footerRegion,s=Ov(e).subarray(i.offset,i.offset+i.length);try{let{value:o,consumedBytes:a}=yne(s);if(n.status="decoded",n.value=o,n.consumedBytes=a,n.trailingBytes=s.length-a,a!==s.length)n.diagnostics.push({code:"PARQUET_FOOTER_TRAILING",path:"",severity:"warning",message:"Bytes remain after the first struct; source retains them without interpreting signatures or other content"});n.diagnostics.push({code:"PARQUET_FOOTER_SEMANTICS_UNVERIFIED",path:"",severity:"warning",message:"Unknown IDs, duplicates, ordering and exact values are retained; the Parquet IDL and logical schema are not validated"})}catch(o){r("PARQUET_FOOTER_DECODE",o.message)}return n}function bne(e){let t=hne(e),n={source:t.source,status:"blocked",complete:!1,diagnostics:[...t.diagnostics]};if(!t.value)return n;n.wire=t.value;try{n.metadata=mne(t.value,"FileMetaData",n.diagnostics),n.status="mapped",n.diagnostics.push({code:"PARQUET_METADATA_SEMANTICS_UNVERIFIED",path:"",severity:"warning",message:"Known IDL shapes mapped; schema-tree consistency, logical constraints, native reading and safe edits remain unverified"})}catch(r){if(!n.diagnostics.some((i)=>i.code==="PARQUET_METADATA_SHAPE"))n.diagnostics.push({code:"PARQUET_METADATA_SHAPE",path:"",severity:"error",message:r.message})}return n}var vne=["BOOLEAN","INT32","INT64","INT96","FLOAT","DOUBLE","BYTE_ARRAY","FIXED_LEN_BYTE_ARRAY"];function _ne(e){let t=bne(e),n={...t,status:"blocked"};if(t.status!=="mapped")return n;let r=t.metadata,i=r.schema,s=[],o=0,a=(u,p)=>{throw n.diagnostics.push({code:"PARQUET_SCHEMA_STRUCTURE",path:u,severity:"error",message:p}),Error(p)},l=(u,p,d)=>n.diagnostics.push({code:u,path:p,severity:"warning",message:d});function c(u,p,d,f){if(f>64)a("/schema","Schema nesting exceeds 64");if(o>=i.length)a("/schema","Child count exceeds remaining schema elements");let m=o++,y=i[m],h="/schema/"+m,b=m===0,g=y.type!==void 0;if(b){if(g)a(h,"Root must be a group");if(y.repetition_type!==void 0){if(y.repetition_type!=="0")a(h+"/repetition_type","Only absent or legacy REQUIRED root repetition is understood");l("PARQUET_ROOT_REPETITION",h+"/repetition_type","REQUIRED root repetition retained; root contributes no definition/repetition level")}}else{if(!["0","1","2"].includes(y.repetition_type))a(h+"/repetition_type","Non-root node requires known repetition");if(y.repetition_type!=="0")p++;if(y.repetition_type==="2")d++}let x=b?[]:[...u,y.name],v={index:m,name:y.name,path:x,definitionLevel:p,repetitionLevel:d,children:[]};if(g){if(y.num_children!==void 0)a(h,"Primitive cannot also declare children");let D=vne[Number(y.type)];if(!D)a(h+"/type","Unknown physical type cannot supply a physical schema view");if(y.type==="7"&&(y.type_length===void 0||BigInt(y.type_length)<=0n))a(h+"/type_length","Fixed byte arrays require a positive length");s.push({index:m,ordinal:s.length,path:x,physicalType:D,definitionLevel:p,repetitionLevel:d})}else{if(y.num_children===void 0||BigInt(y.num_children)<0n||BigInt(y.num_children)>BigInt(i.length-o))a(h+"/num_children","Group requires a feasible nonnegative child count");let D=new Set;for(let T=0;Tp.code==="PARQUET_SCHEMA_STRUCTURE"))n.diagnostics.push({code:"PARQUET_SCHEMA_STRUCTURE",path:"",severity:"error",message:u.message})}return n}var q2e=["STRING","MAP","MAP_KEY_VALUE","LIST","ENUM","DECIMAL","DATE","TIME_MILLIS","TIME_MICROS","TIMESTAMP_MILLIS","TIMESTAMP_MICROS","UINT_8","UINT_16","UINT_32","UINT_64","INT_8","INT_16","INT_32","INT_64","JSON","BSON","INTERVAL"];function xne(e){let t=_ne(e);if(t.status!=="checked")return t;let n=t.metadata.schema,r=[],i=(s,o,a,l=!1)=>{if(t.diagnostics.push({code:s,path:o,severity:l?"error":"warning",message:a}),l)t.status="blocked"};for(let[s,o]of n.entries()){if(!o.logicalType&&o.converted_type===void 0)continue;let a="/schema/"+s,l=o.logicalType?"logical":"converted",c=o.logicalType&&Object.keys(o.logicalType).filter((g)=>g!=="$unknown")[0],u=c??(l==="converted"?q2e[Number(o.converted_type)]:void 0),p=c?o.logicalType[c]:{};if(!u){r.push({index:s,origin:l,name:"unknown",parameters:o.logicalType??{code:o.converted_type},validation:"uninterpreted"}),i("PARQUET_LOGICAL_UNKNOWN",a,"Unknown logical/converted annotation retained without fallback interpretation");continue}if(l==="converted"){if(/^(U?INT)_/.test(u)){let[g,x]=u.split("_");u="INTEGER",p={bitWidth:x,isSigned:g==="INT"}}else if(u==="DECIMAL")p={...o.precision===void 0?{}:{precision:o.precision},scale:o.scale??"0"};else if(/^(TIME|TIMESTAMP)_/.test(u)){let[g,x]=u.split("_");u=g,p={isAdjustedToUTC:!0,unit:{[x]:{}}}}}let d={index:s,origin:l,name:u,parameters:p,validation:"checked"};r.push(d);let f=(g)=>{d.validation="invalid",i("PARQUET_LOGICAL_CONFLICT",a,g,!0)},m=(g)=>{if(d.validation!=="invalid")d.validation="uninterpreted";i("PARQUET_LOGICAL_UNVERIFIED",a,g)},y=(...g)=>{if(!g.includes(o.type))f(u+" is incompatible with this physical type")},h;if(["STRING","ENUM","JSON","BSON","GEOMETRY","GEOGRAPHY"].includes(u)){if(y("6"),h={STRING:"0",ENUM:"4",JSON:"19",BSON:"20"}[u],u==="GEOMETRY"||u==="GEOGRAPHY")m("Physical carrier checked; CRS, interpolation and WKB semantics remain unverified")}else if(u==="UUID"||u==="FLOAT16"||u==="INTERVAL"){y("7");let g={UUID:"16",FLOAT16:"2",INTERVAL:"12"}[u];if(o.type_length!==g)f(u+" requires byte length "+g);if(u==="INTERVAL")h="21"}else if(u==="DATE")y("1"),h="6";else if(u==="INTEGER"){let g=p.bitWidth;if(!["8","16","32","64"].includes(g))f("Integer bitWidth must be 8, 16, 32 or 64");else y(g==="64"?"2":"1"),h=String((p.isSigned?15:11)+["8","16","32","64"].indexOf(g))}else if(u==="DECIMAL"){y("1","2","6","7"),h="5";let g=p.precision===void 0?0n:BigInt(p.precision),x=BigInt(p.scale);if(g<=0n||x<0n||x>g)f("Decimal precision must be positive and scale between zero and precision");if(o.type==="1"&&g>9n||o.type==="2"&&g>18n)f("Decimal precision exceeds integer physical capacity");if(o.type==="2"&&g<10n)i("PARQUET_DECIMAL_SMALL_INT64",a,"Decimal precision below 10 uses an int64 carrier");if(o.type==="7"){let v=BigInt(o.type_length);if(v>4096n)m("Fixed-decimal capacity check exceeds the 4096-byte exact-arithmetic limit");else{let D=((1n<<8n*v-1n)-1n).toString().length-1;if(g>BigInt(D))f("Decimal precision exceeds fixed-byte physical capacity")}}if(l==="logical"){for(let v of["precision","scale"])if(o[v]!==void 0&&o[v]!==p[v])i("PARQUET_LEGACY_ANNOTATION_CONFLICT",a+"/"+v,"Legacy decimal parameter differs from authoritative logical annotation")}}else if(u==="TIME"||u==="TIMESTAMP"){let g=Object.keys(p.unit).filter((v)=>v!=="$unknown"),x=g[0];if(!x)if(p.unit.$unknown)m("Future temporal unit remains uninterpreted");else f("Temporal unit must select one alternative");else if(!["MILLIS","MICROS","NANOS"].includes(x))m("Future temporal unit remains uninterpreted");else y(u==="TIME"&&x==="MILLIS"?"1":"2"),h=x==="NANOS"?void 0:String((u==="TIME"?7:9)+(x==="MICROS"?1:0))}else if(["LIST","MAP","MAP_KEY_VALUE","VARIANT","FILE"].includes(u)){if(o.type!==void 0)f(u+" requires a group");m("Nested layout and value rules remain unverified"),h={LIST:"3",MAP:"1",MAP_KEY_VALUE:"2"}[u]}else if(u==="UNKNOWN")m("Always-null annotation retained; stored nullness has not been verified");else m("Logical annotation has no implemented rule set");let b=(g)=>g&&typeof g==="object"&&(Array.isArray(g.$unknown)&&g.$unknown.length>0||Object.values(g).some(b));if(b(p))m("Additional logical parameters remain uninterpreted");if(l==="logical"&&h!==void 0){if(o.converted_type===void 0)i("PARQUET_LEGACY_ANNOTATION_ABSENT",a,"Corresponding legacy annotation is absent; source remains unchanged");else if(o.converted_type!==h)i("PARQUET_LEGACY_ANNOTATION_CONFLICT",a,"Legacy annotation conflicts with authoritative logical annotation")}}return t.annotations=r,i("PARQUET_LOGICAL_VALUES_UNVERIFIED","","Annotation checks do not verify values, statistics, sort order or safe cross-system lowering"),t}var wne={"0":"boolean","1":"integer","2":"integer","4":"float","5":"float","6":"binary","7":"binary"},Dne={STRING:"string",ENUM:"string",DECIMAL:"decimal",DATE:"date",TIME:"time",TIMESTAMP:"timestamp",INTEGER:"integer",FLOAT16:"float"},Tne=(e)=>!!(e&&typeof e==="object"&&(Array.isArray(e.$unknown)&&e.$unknown.length>0||Object.values(e).some(Tne)));function U2e(e){if(!We(e,Tj()).valid)throw new U("PARQUET_CAPTURE","Invalid source envelope");let t=e.modules.find((l)=>l.id==="parquet")?.elements.find((l)=>l.id==="source")?.extensions[pp];if(!t||!e.vocabularies[pp])throw new U("PARQUET_CAPTURE","Missing Parquet source");let n={umf:"0.1.0",id:e.id,vocabularies:{[pp]:{version:e.vocabularies[pp].version}},modules:[{id:"parquet",namespace:"",elements:[{id:"source",extensions:{[pp]:Ae(t)}}]}]},r=xne(n),i={status:r.status,complete:!1,fields:[],diagnostics:r.diagnostics};if(r.status!=="checked")return i;let s=r.metadata.schema,o=new Map(r.annotations?.map((l)=>[l.index,l]));function a(l){if(l.index!==0){let c=s[l.index],u=o.get(l.index),p;if(c.type!==void 0){if(u){if(u.validation==="checked"&&Object.hasOwn(Dne,u.name))p=Dne[u.name]}else if(Object.hasOwn(wne,c.type))p=wne[c.type];if(Tne(c))p=void 0}i.fields.push({index:l.index,path:[...l.path],definitionLevel:l.definitionLevel,repetitionLevel:l.repetitionLevel,nativeField:Ae(c),element:{id:"schema:"+l.index,name:l.name,...p?{scalarType:p}:{},extensions:{}}})}l.children.forEach(a)}return a(r.tree),i}function Sne(e){let t=e.modules.find((r)=>r.id==="parquet.fields");if(!t)return;let n=U2e(e);if(n.status!=="checked"||t.namespace!==""||t.elements.length!==n.fields.length||n.fields.some((r,i)=>["id","name","scalarType"].some((s)=>t.elements[i]?.[s]!==r.element[s])))throw new U("PARQUET_FIELD_METADATA","Native schema and core field metadata disagree")}var pp="umf.parquet";var B2e=dne;function Tj(){return new nt().register(B2e)}function Ov(e){if(!We(e,Tj()).valid)throw new U("PARQUET_CAPTURE","Invalid Parquet capture envelope");if(e.modules.some((i)=>i.id==="parquet.fields"))Sne(e);let t=e.modules.find((i)=>i.id==="parquet")?.elements.find((i)=>i.id==="source")?.extensions[pp];if(e.vocabularies[pp]?.version!=="0.1.0"||!t||typeof t!=="object"||Array.isArray(t))throw new U("PARQUET_CAPTURE","Expected pinned Parquet source");if(Object.keys(t).some((i)=>!["profile","encoding","bytes"].includes(i)))throw new U("PARQUET_REPRESENTATION","Unknown capture fields cannot be discarded by native export");let n=t.bytes,r=new Uint8Array(n.length/2);for(let i=0;i(n.diagnostics.push({code:c,path:"",severity:"error",message:u}),n);if(t.length<12)return r("PARQUET_TRUNCATED","File is shorter than the framing minimum");let i=(c)=>String.fromCharCode(...t.subarray(c,c+4)),s=i(0),o=i(t.length-4);if(!["PAR1","PARE"].includes(s)||o!==s)return r("PARQUET_MAGIC","Expected matching PAR1 or PARE header and trailer");let a=new DataView(t.buffer,t.byteOffset,t.byteLength).getUint32(t.length-8,!0),l=t.length-8-a;if(a===0||l<4)return r("PARQUET_FOOTER_BOUNDS","Footer region is empty or overlaps the file header");return n.status="located",n.footerRegion={offset:l,length:a,mode:s==="PARE"?"encrypted":"plaintext-or-signed"},n.diagnostics.push({code:"PARQUET_UNINTERPRETED",path:"",severity:"warning",message:"Footer location alone does not validate Thrift metadata, schemas, pages, encryption, signatures or native values"}),n}var Pne=Ar(og(),1);var Ene={id:"umf.generalized-rdf",version:"0.1.0",coreVersion:"0.1.0",description:"JSON-LD generalized dataset JSON with blank predicates and source-local blank identity",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:generalized-rdf:0.1.0",type:"object",properties:{profile:{const:"jsonld-generalized-dataset"},blankNodeScope:{type:"string",minLength:1},root:{$ref:"#/$defs/node"},originalSource:{type:"string",maxLength:4000000}},required:["profile","blankNodeScope","root","originalSource"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-027; JSON-LD generalized RDF subset: node subjects/predicates, literal objects, named/default graphs; no RDF 1.1 syntax or entailment claim",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"JSON-LD generalized RDF dataset",version:"JSON-LD 1.0/1.1 processing API; RDFJS-shaped JSON term records",subset:"JSON array of quads, node predicates including blank nodes, exact string lexical forms and source-local blank scope; unknown structures archived and block interpretation; no literal subjects/predicates or standard N-Quads export"},evidence:["tests/generalized-rdf/dataset.test.ts","fixtures/generalized-rdf/oracle-results.json","fixtures/generalized-rdf/browser-results.json"]}};var kne={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:generalized-rdf:dataset:0.1.0",type:"array",maxItems:1e4,items:{type:"object",properties:{subject:{oneOf:[{type:"object",properties:{termType:{const:"NamedNode"},value:{type:"string"}},required:["termType","value"],additionalProperties:!0},{type:"object",properties:{termType:{const:"BlankNode"},value:{type:"string",minLength:1}},required:["termType","value"],additionalProperties:!0}]},predicate:{oneOf:[{type:"object",properties:{termType:{const:"NamedNode"},value:{type:"string"}},required:["termType","value"],additionalProperties:!0},{type:"object",properties:{termType:{const:"BlankNode"},value:{type:"string",minLength:1}},required:["termType","value"],additionalProperties:!0}]},object:{oneOf:[{type:"object",properties:{termType:{const:"NamedNode"},value:{type:"string"}},required:["termType","value"],additionalProperties:!0},{type:"object",properties:{termType:{const:"BlankNode"},value:{type:"string",minLength:1}},required:["termType","value"],additionalProperties:!0},{type:"object",properties:{termType:{const:"Literal"},value:{type:"string"},datatype:{type:"object",properties:{termType:{const:"NamedNode"},value:{type:"string"}},required:["termType","value"],additionalProperties:!0},language:{type:"string"}},required:["termType","value","datatype"],additionalProperties:!0}]},graph:{oneOf:[{type:"object",properties:{termType:{const:"NamedNode"},value:{type:"string"}},required:["termType","value"],additionalProperties:!0},{type:"object",properties:{termType:{const:"BlankNode"},value:{type:"string",minLength:1}},required:["termType","value"],additionalProperties:!0},{type:"object",properties:{termType:{const:"DefaultGraph"},value:{const:""}},required:["termType","value"],additionalProperties:!0}]}},required:["subject","predicate","object","graph"],additionalProperties:!0}};var J2e="\\u00a0-\\ud7ff\\uf900-\\ufdcf\\ufdf0-\\uffef"+Array.from({length:13},(e,t)=>`\\u{${((t+1)*65536).toString(16)}}-\\u{${((t+1)*65536+65533).toString(16)}}`).join("")+"\\u{e1000}-\\u{efffd}",G2e=`A-Za-z0-9._~${J2e}\\-`;var Nne=`(?:[${G2e}!$&'()*+,;=]|%[0-9A-Fa-f]{2})`,iS=(e)=>new RegExp(`^(?:${Nne}|[${e}])*$`,"u"),H2e=iS(":@/"),z2e=iS(":@/?\\ue000-\\uf8ff\\u{f0000}-\\u{ffffd}\\u{100000}-\\u{10fffd}"),W2e=iS(":@/?"),Q2e=iS(":"),Y2e=new RegExp(`^${Nne}*$`,"u");function X2e(e){if(e.includes(".")){let r=e.lastIndexOf(":"),i=e.slice(r+1).split(".");if(i.length!==4||i.some((s)=>!/^(0|[1-9][0-9]{0,2})$/.test(s)||Number(s)>255))return!1;e=e.slice(0,r+1)+"0:0"}let t=e.split("::");if(t.length>2)return!1;let n=t.flatMap((r)=>r?r.split(":"):[]);return n.every((r)=>/^[0-9a-f]{1,4}$/i.test(r))&&(t.length===2?n.length<8:n.length===8)}function sS(e){if(/[\u0000-\u0020\u007f]/.test(e))return!1;let t=/^[A-Za-z][A-Za-z0-9+.-]*:([\s\S]*)$/.exec(e);if(!t)return!1;let n=t[1],r=n.indexOf("#");if(r>=0){if(!W2e.test(n.slice(r+1)))return!1;n=n.slice(0,r)}let i=n.indexOf("?");if(i>=0){if(!z2e.test(n.slice(i+1)))return!1;n=n.slice(0,i)}if(n.startsWith("//")){let s=n.indexOf("/",2),o=s<0?n.slice(2):n.slice(2,s);n=s<0?"":n.slice(s);let a=o.lastIndexOf("@");if(a>=0){if(!Q2e.test(o.slice(0,a)))return!1;o=o.slice(a+1)}if(o.startsWith("[")){let l=o.indexOf("]");if(l<0)return!1;let c=o.slice(1,l),u=o.slice(l+1);if(u&&!/^:[0-9]*$/.test(u))return!1;if(!X2e(c)&&!/^v[0-9a-f]+\.[A-Za-z0-9._~!$&'()*+,;=:-]+$/i.test(c))return!1}else{let l=o.lastIndexOf(":");if(l>=0){if(!/^[0-9]*$/.test(o.slice(l+1)))return!1;o=o.slice(0,l)}if(!Y2e.test(o))return!1}}return H2e.test(n)}var Z2e=new Set("en-gb-oed i-ami i-bnn i-default i-enochian i-hak i-klingon i-lux i-mingo i-navajo i-pwn i-tao i-tay i-tsu sgn-be-fr sgn-be-nl sgn-ch-de art-lojban cel-gaulish no-bok no-nyn zh-guoyu zh-hakka zh-min zh-min-nan zh-xiang".split(" "));function Sj(e){if(/[^A-Za-z0-9-]/.test(e))return!1;let t=e.toLowerCase();if(Z2e.has(t)||/^x(?:-[a-z0-9]{1,8})+$/.test(t))return!0;let n=/^(?:[a-z]{2,3}(?:-[a-z]{3}){0,3}|[a-z]{4}|[a-z]{5,8})(?:-[a-z]{4})?(?:-(?:[a-z]{2}|[0-9]{3}))?((?:-(?:[a-z0-9]{5,8}|[0-9][a-z0-9]{3}))*)((?:-[0-9a-wy-z](?:-[a-z0-9]{2,8})+)*)(?:-x(?:-[a-z0-9]{1,8})+)?$/.exec(t);if(!n)return!1;let r=n[1].split("-").filter(Boolean),i=n[2].split("-").filter((s)=>s.length===1);return new Set(r).size===r.length&&new Set(i).size===i.length}var One="umf.generalized-rdf",eqe=Ene,tqe=new Pne.default({strict:!1,validateFormats:!1}).compile(kne);function nqe(e){let t=e,n=[{code:"GENERALIZED_RDF_SCOPE",path:"",severity:"warning",message:"JSON-LD generalized dataset subset; blank identities are local to blankNodeScope. This is not RDF 1.1 N-Quads or an entailment claim."}],r=(a,l)=>n.push({code:a,path:"",severity:"warning",message:l});if(Object.keys(t).some((a)=>!["profile","blankNodeScope","root","originalSource"].includes(a)))r("GENERALIZED_RDF_ENCODING","Unknown encoding fields retained; native export and interpretation blocked");let i=(a)=>{if(Object.keys(a).some((l)=>!(a.kind==="null"?["kind"]:a.kind==="object"?["kind","members"]:a.kind==="array"?["kind","items"]:["kind","value"]).includes(l)))r("GENERALIZED_RDF_ENCODING","Unknown NativeJson encoding field retained");if(a.kind==="object")Object.values(a.members).forEach(i);if(a.kind==="array")a.items.forEach(i)};i(t.root);try{Jt(t.originalSource)}catch(a){n.push({code:"GENERALIZED_RDF_SOURCE",path:"",severity:"error",message:String(a)})}let s=JSON.parse(Be(t.root));if(!tqe(s))return r("GENERALIZED_RDF_UNSUPPORTED","Native dataset structure is outside the declared subset; exact source retained"),n;let o=(a,l)=>{if(Object.keys(a).some((c)=>!l.includes(c)))r("GENERALIZED_RDF_UNSUPPORTED","Unknown native fields retained; interpretation and edits blocked")};for(let a of s){o(a,["subject","predicate","object","graph"]);for(let l of[a.subject,a.predicate,a.object,a.graph]){if(o(l,l.termType==="Literal"?["termType","value","datatype","language"]:["termType","value"]),l.termType==="NamedNode"&&!sS(l.value))r("GENERALIZED_RDF_UNSUPPORTED","Malformed IRI retained");if(l.termType==="Literal"){if(o(l.datatype,["termType","value"]),!sS(l.datatype.value)||(l.language??""?!Sj(l.language)||l.datatype.value!=="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString":l.datatype.value==="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString"))r("GENERALIZED_RDF_UNSUPPORTED","Malformed literal datatype/language retained")}}}return n}function rqe(){return new nt().register(eqe,nqe)}function $ne(e){return We(e,rqe())}function iqe(e){let t=$ne(e);if(!t.valid)throw new U("GENERALIZED_RDF_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="dataset")?.elements.find((r)=>r.id==="dataset")?.extensions[One];if(!n||e.vocabularies[One]?.version!=="0.1.0")throw new U("GENERALIZED_RDF_PAYLOAD","Expected pinned generalized dataset");return Ae(n)}function Ine(e){let t=iqe(e);if($ne(e).diagnostics.some((n)=>n.code==="GENERALIZED_RDF_ENCODING"))throw new U("GENERALIZED_RDF_EXPORT","Unknown encoding fields cannot be discarded");return Be(t.root)===Be(Jt(t.originalSource))?t.originalSource:Be(t.root)+` -`}var Ane={id:"umf.sqlserver",version:"0.1.0",coreVersion:"0.1.0",description:"SQL Server catalog capture and core column metadata",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:sqlserver:0.1.0",type:"object",required:["profile","root"],properties:{profile:{const:"sqlserver-catalog-v1"},root:{$ref:"#/$defs/node"}},$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-031; bounded observations, not full server semantics or reconstruction",scopes:["document"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Microsoft SQL Server",version:"SQL Server 2022; native evidence 16.0.4295.3; capture profiles v1/v2/v3",subset:"Table/column, key/foreign-key/check and index observations; exact recovery and metadata views. Permission-limited, not complete catalog or DDL reconstruction."},evidence:["tests/sqlserver/catalog.test.ts","native/sqlserver/catalog.sql","fixtures/sqlserver/oracle.json","fixtures/sqlserver/browser.json","tests/sqlserver/constraints.test.ts","fixtures/sqlserver/constraints-oracle.json","tests/sqlserver/indexes.test.ts","fixtures/sqlserver/indexes-oracle.json"]}};var Ej={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:sqlserver:capture:0.1.0",type:"object",required:["profile","state","serverVersion","query","tables"],properties:{profile:{enum:["sqlserver-catalog-v1","sqlserver-catalog-v2","sqlserver-catalog-v3"]},state:{enum:["captured","modified"]},serverVersion:{type:"string"},query:{type:"string"},tables:{type:"array",items:{type:"object",required:["schema","name","columns"],properties:{schema:{type:"string"},name:{type:"string"},columns:{type:"array",items:{type:"object",required:["name","column_id","system_type_id","user_type_id","type_schema","type_name","base_type_name","is_user_defined","is_assembly_type","max_length","precision","scale","is_nullable","is_identity","is_computed","collation_name","default_definition","computed_definition","identity_seed","identity_increment","description"],properties:{name:{type:"string"},column_id:{type:"integer",minimum:1},system_type_id:{type:"integer",minimum:0,maximum:255},user_type_id:{type:"integer"},type_schema:{type:"string"},type_name:{type:"string"},base_type_name:{type:["string","null"]},is_user_defined:{type:"boolean"},is_assembly_type:{type:"boolean"},max_length:{type:"integer",minimum:-1,maximum:32767},precision:{type:"integer",minimum:0,maximum:255},scale:{type:"integer",minimum:0,maximum:255},is_nullable:{type:"boolean"},is_identity:{type:"boolean"},is_computed:{type:"boolean"},collation_name:{type:["string","null"]},default_definition:{type:["string","null"]},computed_definition:{type:["string","null"]},identity_seed:{type:["string","null"]},identity_increment:{type:["string","null"]},description:{type:["string","null"]}}}},keys:{type:"array",items:{type:"object",required:["name","kind","is_system_named","index_type","is_disabled","ignore_dup_key","columns"],properties:{name:{type:"string"},kind:{type:"string"},is_system_named:{type:"boolean"},index_type:{type:"string"},is_disabled:{type:"boolean"},ignore_dup_key:{type:"boolean"},columns:{type:"array",items:{type:"object",required:["key_ordinal","column_id","name","is_descending_key"],properties:{key_ordinal:{type:"integer",minimum:1},column_id:{type:"integer",minimum:1},name:{type:"string"},is_descending_key:{type:"boolean"}}}}}}},foreign_keys:{type:"array",items:{type:"object",required:["name","is_system_named","is_disabled","is_not_trusted","is_not_for_replication","delete_action","update_action","referenced_schema","referenced_table","columns"],properties:{name:{type:"string"},is_system_named:{type:"boolean"},is_disabled:{type:"boolean"},is_not_trusted:{type:"boolean"},is_not_for_replication:{type:"boolean"},delete_action:{type:"string"},update_action:{type:"string"},referenced_schema:{type:["string","null"]},referenced_table:{type:["string","null"]},columns:{type:"array",items:{type:"object",required:["ordinal","column_id","column_name","referenced_column_id","referenced_column_name"],properties:{ordinal:{type:"integer",minimum:1},column_id:{type:"integer",minimum:1},column_name:{type:["string","null"]},referenced_column_id:{type:"integer",minimum:1},referenced_column_name:{type:["string","null"]}}}}}}},checks:{type:"array",items:{type:"object",required:["name","is_system_named","parent_column_id","definition","is_disabled","is_not_trusted","is_not_for_replication","uses_database_collation"],properties:{name:{type:"string"},is_system_named:{type:"boolean"},parent_column_id:{type:"integer",minimum:0},definition:{type:["string","null"]},is_disabled:{type:"boolean"},is_not_trusted:{type:"boolean"},is_not_for_replication:{type:"boolean"},uses_database_collation:{type:"boolean"}}}},indexes:{type:"array",items:{type:"object",required:["index_id","name","type","type_desc","is_unique","is_primary_key","is_unique_constraint","is_disabled","is_hypothetical","ignore_dup_key","fill_factor","is_padded","allow_row_locks","allow_page_locks","has_filter","filter_definition","compression_delay","optimize_for_sequential_key","data_space_id","data_space_name","data_space_type","columns"],properties:{index_id:{type:"integer",minimum:0,maximum:2147483647},name:{type:["string","null"]},type:{type:"integer",minimum:0,maximum:255},type_desc:{type:"string"},is_unique:{type:"boolean"},is_primary_key:{type:"boolean"},is_unique_constraint:{type:"boolean"},is_disabled:{type:"boolean"},is_hypothetical:{type:"boolean"},ignore_dup_key:{type:"boolean"},fill_factor:{type:"integer",minimum:0,maximum:100},is_padded:{type:"boolean"},allow_row_locks:{type:"boolean"},allow_page_locks:{type:"boolean"},has_filter:{type:"boolean"},filter_definition:{type:["string","null"]},compression_delay:{type:["integer","null"],minimum:0,maximum:2147483647},optimize_for_sequential_key:{type:"boolean"},data_space_id:{type:"integer",minimum:0,maximum:2147483647},data_space_name:{type:["string","null"]},data_space_type:{type:["string","null"]},columns:{type:"array",items:{type:"object",required:["index_column_id","column_id","name","key_ordinal","partition_ordinal","is_descending_key","is_included_column","column_store_order_ordinal"],properties:{index_column_id:{type:"integer",minimum:1,maximum:2147483647},column_id:{type:"integer",minimum:0,maximum:2147483647},name:{type:["string","null"]},key_ordinal:{type:"integer",minimum:0,maximum:255},partition_ordinal:{type:"integer",minimum:0,maximum:255},is_descending_key:{type:"boolean"},is_included_column:{type:"boolean"},column_store_order_ordinal:{type:"integer",minimum:0,maximum:255}}}}}}}}}}},allOf:[{if:{properties:{profile:{enum:["sqlserver-catalog-v2","sqlserver-catalog-v3"]}}},then:{properties:{tables:{type:"array",items:{type:"object",properties:{keys:{},foreign_keys:{},checks:{}},required:["keys","foreign_keys","checks"]}}}}},{if:{properties:{profile:{const:"sqlserver-catalog-v3"}}},then:{properties:{tables:{type:"array",items:{type:"object",properties:{indexes:{}},required:["indexes"]}}}}}]};function oS(e,t){let n=new Set;function r(i,s,o){if(s.$ref){if(!s.$ref.startsWith("#/$defs/"))throw Error("Unsupported catalog schema reference");r(i,t.$defs[s.$ref.slice(8)],o);return}if(s.anyOf){for(let a of s.anyOf)r(i,a,o);return}if(i.kind==="number"&&(s.type==="integer"||Array.isArray(s.type)&&s.type.includes("integer")))try{let a=ms(i.value,"json");if(typeof a!=="number"||!Number.isSafeInteger(a))throw Error("Not an exact integer")}catch{n.add(o)}if(i.kind==="object"){for(let[a,l]of Object.entries(i.members))if(s.properties&&Object.hasOwn(s.properties,a))r(l,s.properties[a],o+"/"+a.replace(/~/g,"~0").replace(/\//g,"~1"))}if(i.kind==="array"&&s.items)i.items.forEach((a,l)=>r(a,s.items,o+"/"+l))}return r(e,t,""),[...n]}var Rne="umf.sqlserver",aqe=Ane,jne=mt().compile(Ej),lqe={"104":["bit","boolean"],"48":["tinyint","integer"],"52":["smallint","integer"],"56":["int","integer"],"127":["bigint","integer"],"106":["decimal","decimal"],"108":["numeric","decimal"],"60":["money","decimal"],"122":["smallmoney","decimal"],"59":["real","float"],"62":["float","float"],"167":["varchar","string"],"175":["char","string"],"231":["nvarchar","string"],"239":["nchar","string"],"35":["text","string"],"99":["ntext","string"],"165":["varbinary","binary"],"173":["binary","binary"],"34":["image","binary"],"189":["timestamp","binary"],"40":["date","date"],"41":["time","time"],"42":["datetime2","timestamp"],"43":["datetimeoffset","timestamp"],"58":["smalldatetime","timestamp"],"61":["datetime","timestamp"]},Pv=(e)=>e?.kind==="string"?e.value:void 0;function cqe(e){let t=e,n=[{code:"SQLSERVER_CAPTURE_SCOPE",path:"",severity:"warning",message:"Permission-limited table/column observations; server correspondence and complete native semantics are unverified"}],r=(a)=>n.push({code:"SQLSERVER_ENCODING",path:a,severity:"warning",message:"Unknown encoding content must remain in UMF and blocks native export"});for(let a of Object.keys(t))if(!["profile","root"].includes(a))r("/"+a);function i(a,l){let c=a.kind==="object"?["kind","members"]:a.kind==="array"?["kind","items"]:a.kind==="null"?["kind"]:["kind","value"];if(Object.keys(a).some((u)=>!c.includes(u)))r(l);if(a.kind==="object")Object.entries(a.members).forEach(([u,p])=>i(p,l+"/"+u));if(a.kind==="array")a.items.forEach((u,p)=>i(u,l+"/"+p))}i(t.root,"/root");for(let a of oS(t.root,Ej))n.push({code:"SQLSERVER_INTEGER",path:a,severity:"error",message:"Declared catalog integers must be exact interoperable integers; numeric rounding is not permitted"});if(n.some((a)=>a.severity==="error"))return n;let s=JSON.parse(Be(t.root));if(!jne(s))return n.push({code:"SQLSERVER_CAPTURE_STRUCTURE",path:"",severity:"error",message:JSON.stringify(jne.errors)}),n;let o=new Set;for(let a of s.tables){let l=JSON.stringify([a.schema,a.name]);if(o.has(l))n.push({code:"SQLSERVER_DUPLICATE",path:"/tables",severity:"error",message:"Duplicate qualified table observation"});o.add(l);let c=new Set,u=new Set;for(let p of a.columns){if(c.has(p.name)||u.has(p.column_id))n.push({code:"SQLSERVER_DUPLICATE",path:"/tables",severity:"error",message:"Duplicate column name or native ID"});c.add(p.name),u.add(p.column_id)}}if(!s.serverVersion?.startsWith("16."))n.push({code:"SQLSERVER_VERSION",path:"/serverVersion",severity:"warning",message:"Version retained outside the SQL Server 2022 profile"});for(let[a,l]of s.tables.entries()){let c=new Set;for(let d of["keys","foreign_keys","checks"])for(let[f,m]of(l[d]??[]).entries()){let y="/tables/"+a+"/"+d+"/"+f;if(c.has(m.name))n.push({code:"SQLSERVER_DUPLICATE",path:y,severity:"error",message:"Duplicate constraint name within table"});if(c.add(m.name),d!=="checks"){let h=new Set,b=new Set;for(let g of m.columns){let x=d==="keys"?g.key_ordinal:g.ordinal;if(h.has(x)||b.has(g.column_id))n.push({code:"SQLSERVER_CONSTRAINT_COLUMNS",path:y,severity:"error",message:"Duplicate constraint column or ordinal"});h.add(x),b.add(g.column_id)}if(!m.columns.length)n.push({code:"SQLSERVER_CONSTRAINT_UNRESOLVED",path:y,severity:"warning",message:"Constraint column observations are unavailable"})}if(d==="keys"&&!["PK","UQ"].includes(m.kind)||d==="foreign_keys"&&[m.delete_action,m.update_action].some((h)=>!["NO_ACTION","CASCADE","SET_NULL","SET_DEFAULT"].includes(h)))n.push({code:"SQLSERVER_CONSTRAINT_UNKNOWN",path:y,severity:"warning",message:"Unknown native constraint kind/action retained without interpretation"})}let u=new Set,p=new Set;for(let[d,f]of(l.indexes??[]).entries()){let m="/tables/"+a+"/indexes/"+d;if(u.has(f.index_id)||f.name!==null&&p.has(f.name))n.push({code:"SQLSERVER_DUPLICATE",path:m,severity:"error",message:"Duplicate index name or native ID within table"});if(u.add(f.index_id),f.name!==null)p.add(f.name);let y=new Set,h=new Set,b=new Set,g=new Set;for(let v of f.columns){if(y.has(v.index_column_id)||v.key_ordinal>0&&h.has(v.key_ordinal)||v.column_store_order_ordinal>0&&b.has(v.column_store_order_ordinal)||v.partition_ordinal>0&&g.has(v.partition_ordinal))n.push({code:"SQLSERVER_INDEX_COLUMNS",path:m,severity:"error",message:"Duplicate index column ID or positive ordering ordinal"});if(y.add(v.index_column_id),v.key_ordinal>0)h.add(v.key_ordinal);if(v.column_store_order_ordinal>0)b.add(v.column_store_order_ordinal);if(v.partition_ordinal>0)g.add(v.partition_ordinal)}if({0:"HEAP",1:"CLUSTERED",2:"NONCLUSTERED",3:"XML",4:"SPATIAL",5:"CLUSTERED COLUMNSTORE",6:"NONCLUSTERED COLUMNSTORE",7:"NONCLUSTERED HASH"}[f.type]!==f.type_desc)n.push({code:"SQLSERVER_INDEX_UNKNOWN",path:m,severity:"warning",message:"Unknown index type identity retained without interpretation"});if([3,4,7].includes(f.type))n.push({code:"SQLSERVER_INDEX_DETAILS_UNAVAILABLE",path:m,severity:"warning",message:"Specialized XML, spatial or hash index details are outside this catalog capture"});if(f.has_filter&&f.filter_definition===null)n.push({code:"SQLSERVER_INDEX_FILTER_UNAVAILABLE",path:m,severity:"warning",message:"Filtered index predicate unavailable; do not infer an unfiltered index"})}}if(s.state==="modified")n.push({code:"SQLSERVER_MODIFIED",path:"/state",severity:"warning",message:"Candidate metadata edits do not update SQL Server or synchronize original DDL"});return n}function uqe(){return new nt().register(aqe,cqe)}function Fne(e){return We(e,uqe())}function Cne(e){let t=Fne(e);if(!t.valid||e.vocabularies[Rne]?.version!=="0.1.0")throw new U("SQLSERVER_CAPTURE",JSON.stringify(t.diagnostics));let n=e.extensions?.[Rne];if(!n)throw new U("SQLSERVER_CAPTURE","Missing SQL Server capture");return Ae(n)}function pqe(e){if(e.kind!=="object"||e.members.tables?.kind!=="array")return[];let t=[];return e.members.tables.items.forEach((n,r)=>{if(n.kind!=="object"||n.members.columns?.kind!=="array")return;n.members.columns.items.forEach((i,s)=>{if(i.kind!=="object")return;let o=i.members,a=o.system_type_id?.kind==="number"?String(Number(o.system_type_id.value)):"",l=lqe[a],c=l&&Pv(o.base_type_name)===l[0]&&o.is_assembly_type?.kind==="boolean"&&!o.is_assembly_type.value?l[1]:void 0,u="/tables/"+r+"/columns/"+s,p=Pv(o.description);t.push({path:u,table:{schema:Pv(n.members.schema),name:Pv(n.members.name)},nativeColumn:Ae(i),element:{id:u,name:Pv(o.name),...p!==void 0?{description:p}:{},...c?{scalarType:c}:{},extensions:{}}})})}),t}function dqe(e){return pqe(Cne(e).root)}function fqe(e){let t=e.modules.find((r)=>r.id==="sqlserver.columns"),n=dqe(e);if(!t||t.namespace!==""||t.elements.length!==n.length||n.some((r,i)=>["id","name","description","scalarType"].some((s)=>t.elements[i]?.[s]!==r.element[s])))throw new U("SQLSERVER_METADATA","Native columns and core metadata disagree")}function Mne(e){if(fqe(e),Fne(e).diagnostics.some((t)=>t.code==="SQLSERVER_ENCODING"))throw new U("SQLSERVER_ENCODING","Unknown source encoding cannot be discarded");return Be(Cne(e).root)+` -`}var Lne={id:"umf.postgresql.catalog",version:"0.1.0",coreVersion:"0.1.0",description:"Versioned observed PostgreSQL catalog captures with reconstruction archives",schema:{type:"object",required:["profile","state","root"],properties:{profile:{const:"postgresql-catalog-capture"},state:{enum:["captured","modified"]},root:{$ref:"#/$defs/node"}},additionalProperties:!0,$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:postgresql-catalog:0.1.0",$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-015. Captured catalog observations and original schema-only dump are retained together. Candidate edits mark the capture modified; no synchronization, execution or universal catalog coverage is implied.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"UMF PostgreSQL catalog capture profile",version:"0.1.0 / PostgreSQL 17",subset:"The exact evidence query and metadata fields in capture.schema.json, with pg_dump plain schema-only archive; no full pg_catalog or server-state validation"},evidence:["tests/postgresql/catalog.test.ts","scripts/postgresql-catalog-oracle.ts"]}};var qne={bool:"boolean",int2:"integer",int4:"integer",int8:"integer",numeric:"decimal",float4:"float",float8:"float",text:"string",varchar:"string",bpchar:"string",bytea:"binary",date:"date",time:"time",timetz:"time",timestamp:"timestamp",timestamptz:"timestamp"},Pc=(e)=>e?.kind==="string"?e.value:void 0;function Une(e){if(e.kind!=="object")return[];let t=e.members.snapshot;if(t?.kind!=="object")return[];let n=t.members.relations;if(n?.kind!=="array")return[];let r=[];return n.items.forEach((i,s)=>{if(i.kind!=="object"||i.members.columns?.kind!=="array")return;let o=i.members;i.members.columns.items.forEach((a,l)=>{if(a.kind!=="object")return;let c=a.members,u=c.nativeType,p;if(u?.kind==="object"&&Pc(u.members.schema)==="pg_catalog"&&Pc(u.members.kind)==="b"&&Pc(u.members.category)!=="A"&&u.members.dimensions?.kind==="number"&&Number(u.members.dimensions.value)===0){let m=Pc(u.members.name);if(m&&Object.hasOwn(qne,m))p=qne[m]}let d="/snapshot/relations/"+s+"/columns/"+l,f=Pc(c.comment);r.push({path:d,relation:{schema:Pc(o.schema)??"",name:Pc(o.name)??"",kind:Pc(o.kind)??""},nativeColumn:Ae(a),element:{id:d,name:Pc(c.name)??"",...f!==void 0?{description:f}:{},...p?{scalarType:p}:{},extensions:{}}})})}),r}var $v={type:"object",required:["profile","serverVersion","query","snapshot","reconstruction","state"],properties:{profile:{const:"postgresql-catalog-capture-v1"},serverVersion:{type:"integer",minimum:170000,maximum:179999},query:{type:"string"},snapshot:{$ref:"#/$defs/snapshot"},reconstruction:{type:"object",required:["format","toolVersion","sql"],properties:{format:{const:"pg-dump-plain-schema-only"},toolVersion:{type:"string"},sql:{type:"string"}},additionalProperties:!0},state:{enum:["captured","modified"]}},additionalProperties:!0,$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:postgresql-catalog:capture:0.1.0",$defs:{namespace:{type:"object",required:["name","owner","acl"],properties:{name:{type:"string"},owner:{type:"string"},acl:{type:["string","null"]}},additionalProperties:!0},column:{type:"object",required:["name","position","type","notNull","identity","generated","collation","default","comment","storage","compression","acl"],properties:{name:{type:"string"},position:{type:"integer",minimum:1,maximum:32767},type:{type:"string"},nativeType:{type:"object",required:["schema","name","kind","category","dimensions","modifier"],properties:{schema:{type:"string"},name:{type:"string"},kind:{type:"string"},category:{type:"string"},dimensions:{type:"integer",minimum:0},modifier:{type:"integer"}}},notNull:{type:"boolean"},identity:{type:"string"},generated:{type:"string"},collation:{type:["string","null"]},default:{type:["string","null"]},comment:{type:["string","null"]},storage:{type:"string"},compression:{type:"string"},acl:{type:["string","null"]}},additionalProperties:!0},constraint:{type:"object",required:["name","kind","definition","deferrable","deferred","validated"],properties:{name:{type:"string"},kind:{type:"string"},definition:{type:"string"},deferrable:{type:"boolean"},deferred:{type:"boolean"},validated:{type:"boolean"}},additionalProperties:!0},index:{type:"object",required:["definition","valid","ready","replicaIdentity"],properties:{definition:{type:"string"},valid:{type:"boolean"},ready:{type:"boolean"},replicaIdentity:{type:"boolean"}},additionalProperties:!0},policy:{type:"object",required:["name","command","permissive","roles","using","check"],properties:{name:{type:"string"},command:{type:"string"},permissive:{type:"boolean"},roles:{type:["array","null"],items:{type:"string"}},using:{type:["string","null"]},check:{type:["string","null"]}},additionalProperties:!0},sequence:{type:"object",required:["type","start","increment","min","max","cache","cycle"],properties:{type:{type:"string"},start:{type:"string",pattern:"^-?[0-9]+$"},increment:{type:"string",pattern:"^-?[0-9]+$"},min:{type:"string",pattern:"^-?[0-9]+$"},max:{type:"string",pattern:"^-?[0-9]+$"},cache:{type:"string",pattern:"^-?[0-9]+$"},cycle:{type:"boolean"}},additionalProperties:!0},relation:{type:"object",required:["schema","name","kind","persistence","owner","acl","options","rowSecurity","forceRowSecurity","comment","partitionKey","partitionBound","parents","view","columns","constraints","indexes","policies","sequence"],properties:{schema:{type:"string"},name:{type:"string"},kind:{type:"string"},persistence:{type:"string"},owner:{type:"string"},acl:{type:["string","null"]},options:{type:["array","null"],items:{type:"string"}},rowSecurity:{type:"boolean"},forceRowSecurity:{type:"boolean"},comment:{type:["string","null"]},partitionKey:{type:["string","null"]},partitionBound:{type:["string","null"]},parents:{type:["array","null"],items:{type:"string"}},view:{type:["string","null"]},columns:{type:["array","null"],items:{$ref:"#/$defs/column"}},constraints:{type:["array","null"],items:{$ref:"#/$defs/constraint"}},indexes:{type:["array","null"],items:{$ref:"#/$defs/index"}},policies:{type:["array","null"],items:{$ref:"#/$defs/policy"}},sequence:{anyOf:[{$ref:"#/$defs/sequence"},{type:"null"}]}},additionalProperties:!0},type:{type:"object",required:["schema","name","kind","owner","acl","base","notNull","default","comment","labels","constraints"],properties:{schema:{type:"string"},name:{type:"string"},kind:{type:"string"},owner:{type:"string"},acl:{type:["string","null"]},base:{type:"string"},notNull:{type:"boolean"},default:{type:["string","null"]},comment:{type:["string","null"]},labels:{type:["array","null"],items:{type:"string"}},constraints:{type:["array","null"],items:{type:"object",required:["name","definition","validated"],properties:{name:{type:"string"},definition:{type:"string"},validated:{type:"boolean"}},additionalProperties:!0}}},additionalProperties:!0},function:{type:"object",required:["schema","name","identity","definition","owner","acl","comment"],properties:{schema:{type:"string"},name:{type:"string"},identity:{type:"string"},definition:{type:"string"},owner:{type:"string"},acl:{type:["string","null"]},comment:{type:["string","null"]}},additionalProperties:!0},snapshot:{type:"object",required:["profile","namespaces","relations","types","functions"],properties:{profile:{enum:["umf-postgresql-catalog-evidence-17-v1","umf-postgresql-catalog-evidence-17-v2","umf-postgresql-catalog-evidence-17-v3"]},namespaces:{type:["array","null"],items:{$ref:"#/$defs/namespace"}},relations:{type:["array","null"],items:{$ref:"#/$defs/relation"}},types:{type:["array","null"],items:{$ref:"#/$defs/type"}},functions:{type:["array","null"],items:{$ref:"#/$defs/function"}},triggers:{type:["array","null"],items:{$ref:"#/$defs/trigger"}},compositeTypes:{type:["array","null"],items:{$ref:"#/$defs/compositeType"}},rangeTypes:{type:["array","null"],items:{$ref:"#/$defs/rangeType"}},collations:{type:["array","null"],items:{$ref:"#/$defs/collation"}},dependencies:{type:"array",items:{$ref:"#/$defs/dependency"}}},additionalProperties:!0,allOf:[{if:{properties:{profile:{enum:["umf-postgresql-catalog-evidence-17-v2","umf-postgresql-catalog-evidence-17-v3"]}}},then:{required:["triggers","compositeTypes","rangeTypes","collations"]}},{if:{properties:{profile:{const:"umf-postgresql-catalog-evidence-17-v3"}}},then:{required:["dependencies"]}}]},trigger:{type:"object",properties:{schema:{type:"string"},relation:{type:"string"},name:{type:"string"},enabled:{type:"string"},definition:{type:"string"},function:{type:"string"},deferrable:{type:"boolean"},deferred:{type:"boolean"},comment:{type:["string","null"]}},required:["schema","relation","name","enabled","definition","function","deferrable","deferred","comment"],additionalProperties:!0},compositeType:{type:"object",properties:{schema:{type:"string"},name:{type:"string"},owner:{type:"string"},acl:{type:["string","null"]},comment:{type:["string","null"]},attributes:{type:["array","null"],items:{type:"object",properties:{name:{type:"string"},position:{type:"integer",minimum:1,maximum:32767},type:{type:"string"},collation:{type:["string","null"]}},required:["name","position","type","collation"],additionalProperties:!0}}},required:["schema","name","owner","acl","comment","attributes"],additionalProperties:!0},rangeType:{type:"object",properties:{schema:{type:"string"},name:{type:"string"},owner:{type:"string"},acl:{type:["string","null"]},comment:{type:["string","null"]},subtype:{type:"string"},multirange:{type:"string"},collation:{type:["string","null"]},operatorClass:{type:"string"},canonical:{type:"string"},subtypeDifference:{type:"string"}},required:["schema","name","owner","acl","comment","subtype","multirange","collation","operatorClass","canonical","subtypeDifference"],additionalProperties:!0},collation:{type:"object",properties:{schema:{type:"string"},name:{type:"string"},owner:{type:"string"},provider:{type:"string"},deterministic:{type:"boolean"},encoding:{type:"integer",minimum:-1,maximum:2147483647},collate:{type:["string","null"]},ctype:{type:["string","null"]},locale:{type:["string","null"]},rules:{type:["string","null"]},version:{type:["string","null"]},comment:{type:["string","null"]}},required:["schema","name","owner","provider","deterministic","encoding","collate","ctype","locale","rules","version","comment"],additionalProperties:!0},dependencyObject:{type:"object",required:["catalog","type","schema","name","identity"],properties:{catalog:{type:"string"},type:{type:"string"},schema:{type:["string","null"]},name:{type:["string","null"]},identity:{type:"string"}},additionalProperties:!0},dependency:{type:"object",required:["dependent","referenced","kind"],properties:{dependent:{$ref:"#/$defs/dependencyObject"},referenced:{$ref:"#/$defs/dependencyObject"},kind:{type:"string",minLength:1,maxLength:1}},additionalProperties:!0}},description:"Observed catalog metadata for the versioned UMF PostgreSQL 17 evidence query, with original query and schema-only dump. Native expressions/ACLs/physical types remain strings. Unknown properties are retained. Not the entire PostgreSQL catalog or a guarantee of reconstruction."};var Bne="umf.postgresql.catalog",hqe=Lne,kj;function gqe(e){let t=e,n=[{code:"POSTGRESQL_CATALOG_SCOPE",path:"",severity:"warning",message:"Observed metadata is limited to the declared query/profile; server state and reconstruction correspondence are not verified"}],r=(a,l,c)=>n.push({code:a,path:l,severity:"warning",message:c});if(Object.keys(t).some((a)=>!["profile","state","root"].includes(a)))r("POSTGRESQL_CATALOG_REPRESENTATION","","Unknown representation fields must stay in UMF");function i(a,l){let c=a.kind==="null"?["kind"]:a.kind==="object"?["kind","members"]:a.kind==="array"?["kind","items"]:["kind","value"];if(Object.keys(a).some((u)=>!c.includes(u)))r("POSTGRESQL_CATALOG_REPRESENTATION",l,"Unknown tagged representation fields must stay in UMF");if(a.kind==="object")for(let[u,p]of Object.entries(a.members))i(p,l+"/"+u);if(a.kind==="array")a.items.forEach((u,p)=>i(u,l+"/"+p))}i(t.root,"/root");for(let a of oS(t.root,$v))n.push({code:"POSTGRESQL_CATALOG_INTEGER",path:a,severity:"error",message:"Declared catalog integers must be exact interoperable integers; numeric rounding is not permitted"});if(n.some((a)=>a.severity==="error"))return n;let s=JSON.parse(Be(t.root));if(s?.state!==t.state)n.push({code:"POSTGRESQL_CATALOG_STATE",path:"/root",severity:"error",message:"Capture and representation state must agree"});if(kj??=mt(!1).compile($v),!kj(s))for(let a of kj.errors??[])n.push({code:"POSTGRESQL_CATALOG_STRUCTURE",path:a.instancePath,severity:"error",message:a.message??"Invalid captured metadata"});function o(a,l,c){if(l.$ref)l=$v.$defs[l.$ref.slice(8)];if(l.anyOf){let u=l.anyOf.find((p)=>p.$ref&&a!==null);if(u)o(a,u,c);return}if(Array.isArray(a)&&l.items){a.forEach((u,p)=>o(u,l.items,c+"/"+p));return}if(a&&typeof a==="object"&&l.properties)for(let u of Object.keys(a))if(!Object.hasOwn(l.properties,u))r("POSTGRESQL_CATALOG_UNKNOWN",c+"/"+u,"Unknown native capture field retained without interpretation");else o(a[u],l.properties[u],c+"/"+u)}if(o(s,$v,""),s?.serverVersion!==170004)r("POSTGRESQL_CATALOG_VERSION","/serverVersion","Capture version retained; executed evidence currently covers PostgreSQL 17.4 only");if(t.state==="modified")r("POSTGRESQL_CATALOG_MODIFIED","","Capture has candidate edits; its reconstruction archive is not synchronized");return n}function bqe(){return new nt().register(hqe,gqe)}function Vne(e){return We(e,bqe())}function Kne(e){let t=Vne(e);if(!t.valid)throw new U("POSTGRESQL_CATALOG_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="catalog")?.elements.find((r)=>r.id==="capture")?.extensions[Bne];if(!n||e.vocabularies[Bne]?.version!=="0.1.0")throw new U("POSTGRESQL_CATALOG_PAYLOAD","Expected catalog capture");return Ae(n)}function vqe(e){return Une(Kne(e).root)}function _qe(e){let t=e.modules.find((r)=>r.id==="postgresql.columns");if(!t)return;let n=vqe(e).map((r)=>r.element);if(t.namespace!==""||t.elements.length!==n.length||n.some((r,i)=>["id","name","description","scalarType"].some((s)=>t.elements[i]?.[s]!==r[s])))throw new U("POSTGRESQL_COLUMN_METADATA","Native columns and core metadata disagree")}function Jne(e){_qe(e);let t=Kne(e);if(Vne(e).diagnostics.some((n)=>n.code==="POSTGRESQL_CATALOG_REPRESENTATION"))throw new U("POSTGRESQL_CATALOG_EXPORT","Unknown representation fields cannot be discarded");return{state:t.state,json:Be(t.root),complete:!1}}function Iv(e,t){if(!(e!==null&&typeof e=="object"&&("$typeName"in e)&&typeof e.$typeName=="string"))return!1;if(t===void 0)return!0;return t.typeName===e.$typeName}var ie;(function(e){e[e.DOUBLE=1]="DOUBLE",e[e.FLOAT=2]="FLOAT",e[e.INT64=3]="INT64",e[e.UINT64=4]="UINT64",e[e.INT32=5]="INT32",e[e.FIXED64=6]="FIXED64",e[e.FIXED32=7]="FIXED32",e[e.BOOL=8]="BOOL",e[e.STRING=9]="STRING",e[e.BYTES=12]="BYTES",e[e.UINT32=13]="UINT32",e[e.SFIXED32=15]="SFIXED32",e[e.SFIXED64=16]="SFIXED64",e[e.SINT32=17]="SINT32",e[e.SINT64=18]="SINT64"})(ie||(ie={}));function Hne(){let e=this.buf,t=this.pos,n=0,r=0;for(let s=0;s<28;s+=7){let o=e[t++];if(n|=(o&127)<>4,(i&128)==0){this.pos=t,this.assertBounds(),this.varint64Lo=n,this.varint64Hi=r;return}for(let s=3;s<=31;s+=7){let o=e[t++];if(r|=(o&127)<=aS)i=i+(r/aS|0),r=r%aS}return s(-24,-18),s(-18,-12),s(-12,-6),s(-6),t?Wne(r,i):Pj(r,i)}function zne(e,t){let n=Pj(e,t),r=n.hi&2147483648;if(r)n=Wne(n.lo,n.hi);let i=Oj(n.lo,n.hi);return r?"-"+i:i}function Oj(e,t){if({lo:e,hi:t}=xqe(e,t),t<=2097151)return String(aS*t+e);let n=e&16777215,r=(e>>>24|t<<8)&16777215,i=t>>16&65535,s=n+r*6777216+i*6710656,o=r+i*8147497,a=i*2,l=1e7;if(s>=l)o+=Math.floor(s/l),s%=l;if(o>=l)a+=Math.floor(o/l),o%=l;return a.toString()+Gne(o)+Gne(s)}function xqe(e,t){return{lo:e>>>0,hi:t>>>0}}function Pj(e,t){return{lo:e|0,hi:t|0}}function Wne(e,t){if(t=~t,e)e=~e+1;else t+=1;return Pj(e,t)}var Gne=(e)=>{let t=String(e);return"0000000".slice(t.length)+t};function Qne(e,t){if(e>>>0<128){t.push(e);return}if(e>=0){while(e>127)t.push(e&127|128),e=e>>>7;t.push(e)}else{for(let n=0;n<9;n++)t.push(e&127|128),e=e>>7;t.push(1)}}function Yne(){let e=this.buf[this.pos++];if((e&128)===0)return this.assertBounds(),e;let t=e&127;if(e=this.buf[this.pos++],t|=(e&127)<<7,(e&128)===0)return this.assertBounds(),t;if(e=this.buf[this.pos++],t|=(e&127)<<14,(e&128)===0)return this.assertBounds(),t;if(e=this.buf[this.pos++],t|=(e&127)<<21,(e&128)===0)return this.assertBounds(),t;e=this.buf[this.pos++],t|=(e&15)<<28;for(let n=5;(e&128)!==0&&n<10;n++)e=this.buf[this.pos++];if((e&128)!==0)throw Error("invalid varint");return this.assertBounds(),t>>>0}var Sn=wqe();function wqe(){let e=new DataView(new ArrayBuffer(8));if(typeof BigInt==="function"&&typeof e.getBigInt64==="function"&&typeof e.getBigUint64==="function"&&typeof e.setBigInt64==="function"&&typeof e.setBigUint64==="function"&&(!!globalThis.Deno||!!globalThis.Bun||typeof process!="object"||typeof process.env!="object"||process.env.BUF_BIGINT_DISABLE!=="1")){let n=BigInt("-9223372036854775808"),r=BigInt("9223372036854775807"),i=BigInt("0"),s=BigInt("18446744073709551615");return{zero:BigInt(0),supported:!0,parse(o){let a=typeof o=="bigint"?o:BigInt(o);if(a>r||as||ar.localName===n)}function rre(e,t){let n=t.localName;if(t.oneof)return e[t.oneof.localName].case===n;if(t.presence!=tre)return e[n]!==void 0&&Object.prototype.hasOwnProperty.call(e,n);switch(t.fieldKind){case"list":return e[n].length>0;case"map":return Object.keys(e[n]).length>0;case"scalar":return!ere(t.scalar,e[n]);case"enum":return e[n]!==t.enum.values[0].number}throw Error("message field with implicit presence")}function of(e,t){return Object.prototype.hasOwnProperty.call(e,t)&&e[t]!==void 0}function ire(e,t){if(t.oneof){let n=e[t.oneof.localName];if(n.case===t.localName)return n.value;return}return e[t.localName]}function sre(e,t,n){if(t.oneof)e[t.oneof.localName]={case:t.localName,value:n};else e[t.localName]=n}function ore(e,t){let n=t.localName;if(t.oneof){let r=t.oneof.localName;if(e[r].case===n)e[r]={case:void 0}}else if(t.presence!=tre)delete e[n];else switch(t.fieldKind){case"map":e[n]={};break;case"list":e[n]=[];break;case"enum":e[n]=t.enum.values[0].number;break;case"scalar":e[n]=$c(t.scalar,t.longAsString);break}}function ja(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function Av(e,t){var n,r,i,s;if(ja(e)&&Ra in e&&"add"in e&&"field"in e&&typeof e.field=="function"){if(t!==void 0){let o=t,a=e.field();return o.listKind==a.listKind&&o.scalar===a.scalar&&((n=o.message)===null||n===void 0?void 0:n.typeName)===((r=a.message)===null||r===void 0?void 0:r.typeName)&&((i=o.enum)===null||i===void 0?void 0:i.typeName)===((s=a.enum)===null||s===void 0?void 0:s.typeName)}return!0}return!1}function Rv(e,t){var n,r,i,s;if(ja(e)&&Ra in e&&"has"in e&&"field"in e&&typeof e.field=="function"){if(t!==void 0){let o=t,a=e.field();return o.mapKey===a.mapKey&&o.mapKind==a.mapKind&&o.scalar===a.scalar&&((n=o.message)===null||n===void 0?void 0:n.typeName)===((r=a.message)===null||r===void 0?void 0:r.typeName)&&((i=o.enum)===null||i===void 0?void 0:i.typeName)===((s=a.enum)===null||s===void 0?void 0:s.typeName)}return!0}return!1}function jv(e,t){return ja(e)&&Ra in e&&"desc"in e&&ja(e.desc)&&e.desc.kind==="message"&&(t===void 0||e.desc.typeName==t.typeName)}function are(e){return lre(e.$typeName)}function jy(e){let t=e.fields[0];return lre(e.typeName)&&t!==void 0&&t.fieldKind=="scalar"&&t.name=="value"&&t.number==1}var Dqe=new Set(["google.protobuf.DoubleValue","google.protobuf.FloatValue","google.protobuf.Int64Value","google.protobuf.UInt64Value","google.protobuf.Int32Value","google.protobuf.UInt32Value","google.protobuf.BoolValue","google.protobuf.StringValue","google.protobuf.BytesValue"]);function lre(e){return Dqe.has(e)}var Tqe=999,Sqe=998,ure=2;function af(e,t){if(Iv(t,e))return t;return pre(e)(t)}var cre=new WeakMap;function pre(e){let t=cre.get(e);if(t===void 0)t=Eqe(e),cre.set(e,t);return t}var $j=0,dre=1,fre=2,mre=3;function Eqe(e){let t=e.typeName,{properties:n,prototype:r}=kqe(e);return(i)=>{let s;if(r!==void 0)s=Object.create(r),s.$typeName=t;else s={$typeName:t};for(let o=0;ol:o.scalar==ie.BYTES?Fv:void 0});break}case"map":{r.push({name:a,kind:fre,constant:void 0,convert:o.mapKind=="message"?(n=lS(o))!==null&&n!==void 0?n:(l)=>l:o.scalar==ie.BYTES?Fv:void 0});break}default:{let l=Pqe(o);if(r.push({name:a,kind:$j,constant:o.presence==ure?l:void 0,convert:o.fieldKind=="scalar"&&o.scalar==ie.BYTES?Fv:void 0}),s)i[a]=l;break}}}return{properties:r,prototype:s?i:void 0}}function Nqe(e){let t=new Map;for(let n of e.fields){let r;if(n.fieldKind=="message")r=lS(n);else if(n.fieldKind=="scalar"&&n.scalar==ie.BYTES)r=Fv;t.set(n.localName,r!==null&&r!==void 0?r:(i)=>i)}return t}function lS(e){if(e.fieldKind=="message"&&!e.oneof&&jy(e.message))return e.message.fields[0].scalar==ie.BYTES?Fv:void 0;if(e.message.typeName=="google.protobuf.Struct"&&e.parent.typeName!=="google.protobuf.Value")return;let t=e.message,n;return(r)=>{if(!ja(r)||Iv(r,t))return r;return n!==null&&n!==void 0||(n=pre(t)),n(r)}}function Fv(e){return Array.isArray(e)?new Uint8Array(e):e}function Oqe(e){switch(e.file.edition){case Tqe:return!1;case Sqe:return!0;default:return e.fields.some((t)=>t.presence!=ure&&t.fieldKind!="message"&&!t.oneof)}}function Pqe(e){let t=e.getDefaultValue();if(t!==void 0)return e.fieldKind=="scalar"&&e.longAsString?t.toString():t;return e.fieldKind=="scalar"?$c(e.scalar,e.longAsString):e.enum.values[0].number}class Fa extends Error{constructor(e,t,n="FieldValueInvalidError"){super(t);this.name=n,this.field=()=>e}}var Ij;function $qe(e){var t;Ij=Object.assign(Object.assign({},e),{encodeUtf8Into:(t=e.encodeUtf8Into)!==null&&t!==void 0?t:Aj(e.encodeUtf8.bind(e))})}function Cv(){if(!Ij){let e=globalThis;if(!e.TextEncoder||!e.TextDecoder)throw Error("encoding API missing: install TextEncoder and TextDecoder on globalThis");let t=new e.TextEncoder,n=new e.TextDecoder,r,i={encodeUtf8(o){return t.encode(o)},decodeUtf8(o,a){if(a){if(!r)r=new e.TextDecoder("utf-8",{fatal:!0});return r.decode(o)}return n.decode(o)},checkUtf8(o){try{return encodeURIComponent(o),!0}catch(a){return!1}}};if(t.encodeInto)i.encodeUtf8Into=t.encodeInto.bind(t);let s=String.prototype.isWellFormed;if(s)i.checkUtf8=(o)=>s.call(o);$qe(i)}return Ij}function Aj(e){return(t,n)=>{let r=e(t);return n.set(r),{written:r.byteLength}}}var Zn;(function(e){e[e.Varint=0]="Varint",e[e.Bit64=1]="Bit64",e[e.LengthDelimited=2]="LengthDelimited",e[e.StartGroup=3]="StartGroup",e[e.EndGroup=4]="EndGroup",e[e.Bit32=5]="Bit32"})(Zn||(Zn={}));var Fj=340282346638528860000000000000000000000,Cj=-340282346638528860000000000000000000000,Mj=4294967295,Lj=2147483647,qj=-2147483648;class Uj{constructor(e){this.stackPos=[],this.encodeUtf8Into=e?Aj(e):Cv().encodeUtf8Into,this.buffer=hre,this.viewCache=Aqe,this.pos=0}ensureCapacity(e){let t=this.pos+e;if(t>this.buffer.length){let n=this.buffer.length||Iqe;while(n0)r.set(this.buffer);this.buffer=r}}view(){let e=this.buffer,t=this.viewCache;if(t.byteLength===e.byteLength)return t;let n=new DataView(e.buffer);return this.viewCache=n,n}finish(){let e=this.buffer.slice(0,this.pos);return this.pos=0,this.stackPos=[],e}fork(){return this.stackPos.push(this.pos),this.ensureCapacity(Mv),this.buffer[this.pos++]=0,this}join(){let e=this.stackPos.pop();if(e===void 0)throw Error("invalid state, fork stack empty");let t=this.pos-e-Mv,n=Rj(t);if(n>Mv)this.ensureCapacity(n-Mv),this.buffer.copyWithin(e+n,e+Mv,this.pos);return this.pos=e,this.uint32(t),this.pos+=t,this}tag(e,t){return this.uint32((e<<3|t)>>>0)}raw(e){return this.ensureCapacity(e.length),this.buffer.set(e,this.pos),this.pos+=e.length,this}uint32(e){if(yre(e),this.ensureCapacity(5),e<128)return this.buffer[this.pos++]=e,this;while(e>127)this.buffer[this.pos++]=e&127|128,e>>>=7;return this.buffer[this.pos++]=e,this}int32(e){if(jj(e),e>=0)return this.uint32(e);this.ensureCapacity(10);for(let t=0;t<9;t++)this.buffer[this.pos++]=e&127|128,e>>=7;return this.buffer[this.pos++]=1,this}bool(e){return this.ensureCapacity(1),this.buffer[this.pos++]=e?1:0,this}bytes(e){return this.uint32(e.byteLength),this.raw(e)}string(e){if(typeof e!=="string")e=String(e);let t=e.length;if(t<=gre){this.ensureCapacity(t+1);let a=this.buffer,l=this.pos;a[l++]=t;let c=0;for(;c127)break;a[l++]=u}if(c==t)return this.pos=l,this}this.ensureCapacity(t*3+5);let n=Rj(t),r=this.buffer,i=this.pos,{written:s}=this.encodeUtf8Into(e,r.subarray(i+n)),o=Rj(s);if(o!=n)r.copyWithin(i+o,i+n,i+n+s);return this.uint32(s),this.pos+=s,this}float(e){return Rqe(e),this.ensureCapacity(4),this.view().setFloat32(this.pos,e,!0),this.pos+=4,this}double(e){return this.ensureCapacity(8),this.view().setFloat64(this.pos,e,!0),this.pos+=8,this}fixed32(e){return yre(e),this.ensureCapacity(4),this.view().setUint32(this.pos,e,!0),this.pos+=4,this}sfixed32(e){return jj(e),this.ensureCapacity(4),this.view().setInt32(this.pos,e,!0),this.pos+=4,this}sint32(e){return jj(e),this.uint32((e<<1^e>>31)>>>0)}sfixed64(e){let t=Sn.enc(e);this.ensureCapacity(8);let n=this.view();return n.setInt32(this.pos,t.lo,!0),n.setInt32(this.pos+4,t.hi,!0),this.pos+=8,this}fixed64(e){let t=Sn.uEnc(e);this.ensureCapacity(8);let n=this.view();return n.setInt32(this.pos,t.lo,!0),n.setInt32(this.pos+4,t.hi,!0),this.pos+=8,this}int64(e){let t=Sn.enc(e);return this.writeVarint64(t.lo,t.hi)}sint64(e){let t=Sn.enc(e),n=t.hi>>31,r=t.lo<<1^n,i=(t.hi<<1|t.lo>>>31)^n;return this.writeVarint64(r,i)}uint64(e){let t=Sn.uEnc(e);return this.writeVarint64(t.lo,t.hi)}writeVarint64(e,t){this.ensureCapacity(10);let n=this.buffer,r=this.pos;for(let o=0;o<28;o=o+7){let a=e>>>o,l=!(a>>>7==0&&t==0);if(n[r++]=(l?a|128:a)&255,!l)return this.pos=r,this}let i=e>>>28&15|(t&7)<<4,s=t>>3!=0;if(n[r++]=(s?i|128:i)&255,!s)return this.pos=r,this;for(let o=3;o<31;o=o+7){let a=t>>>o,l=a>>>7!=0;if(n[r++]=(l?a|128:a)&255,!l)return this.pos=r,this}return n[r++]=t>>>31&1,this.pos=r,this}}var Iqe=128,Mv=1,hre=new Uint8Array(0),Aqe=new DataView(hre.buffer),gre=32;function Rj(e){if(e<128)return 1;if(e<16384)return 2;if(e<2097152)return 3;if(e<268435456)return 4;return 5}class Bj{constructor(e,t=Cv().decodeUtf8){this.decodeUtf8=t,this.varint64Lo=0,this.varint64Hi=0,this.varint64=Hne,this.uint32=Yne,this.buf=e,this.len=e.length,this.pos=0,this.view=new DataView(e.buffer,e.byteOffset,e.byteLength)}tag(){let e=this.pos,t=this.uint32(),n=this.pos-e;if(n>5||n==5&&this.buf[this.pos-1]>15)throw Error("illegal tag: varint overflows uint32");let r=t>>>3,i=t&7;if(r<=0||i>5)throw Error("illegal tag: field no "+r+" wire type "+i);return[r,i]}skip(e,t,n=100){let r=this.pos;switch(e){case Zn.Varint:while(this.buf[this.pos++]&128);break;case Zn.Bit64:this.pos+=4;case Zn.Bit32:this.pos+=4;break;case Zn.LengthDelimited:let i=this.uint32();this.pos+=i;break;case Zn.StartGroup:if(n<=0)throw Error("maximum recursion depth reached");for(;;){let[s,o]=this.tag();if(o===Zn.EndGroup){if(t!==void 0&&s!==t)throw Error("invalid end group tag");break}this.skip(o,s,n-1)}break;default:throw Error("cant skip wire type "+e)}return this.assertBounds(),this.buf.subarray(r,this.pos)}assertBounds(){if(this.pos>this.len)throw RangeError("premature EOF")}int32(){return this.uint32()|0}sint32(){let e=this.uint32();return e>>>1^-(e&1)}int64(){return this.varint64(),Sn.dec(this.varint64Lo,this.varint64Hi)}uint64(){return this.varint64(),Sn.uDec(this.varint64Lo,this.varint64Hi)}sint64(){this.varint64();let e=this.varint64Lo,t=this.varint64Hi,n=-(e&1);return e=(e>>>1|(t&1)<<31)^n,t=t>>>1^n,Sn.dec(e,t)}bool(){let e=this.buf[this.pos];if(e<128)return this.pos++,e!==0;return this.varint64(),this.varint64Lo!==0||this.varint64Hi!==0}fixed32(){return this.view.getUint32((this.pos+=4)-4,!0)}sfixed32(){return this.view.getInt32((this.pos+=4)-4,!0)}fixed64(){return Sn.uDec(this.sfixed32(),this.sfixed32())}sfixed64(){return Sn.dec(this.sfixed32(),this.sfixed32())}float(){return this.view.getFloat32((this.pos+=4)-4,!0)}double(){return this.view.getFloat64((this.pos+=8)-8,!0)}bytes(){let e=this.uint32(),t=this.pos;return this.pos+=e,this.assertBounds(),this.buf.subarray(t,t+e)}string(e){let t=this.bytes(),n=t.length;if(n<=gre){let r=Array(n);for(let i=0;i127)return this.decodeUtf8(t,e);r[i]=s}return String.fromCharCode.apply(String,r)}return this.decodeUtf8(t,e)}}function jj(e){if(typeof e=="string")e=Number(e);else if(typeof e!="number")throw Error("invalid int32: "+typeof e);if(!Number.isInteger(e)||e>Lj||eMj||e<0)throw Error("invalid uint32: "+e)}function Rqe(e){if(typeof e=="string"){let t=e;if(e=Number(e),Number.isNaN(e)&&t!=="NaN")throw Error("invalid float32: "+t)}else if(typeof e!="number")throw Error("invalid float32: "+typeof e);if(Number.isFinite(e)&&(e>Fj||en.number===t)}return jv(t,e.message)}function Vj(e){switch(e){case ie.DOUBLE:return(t)=>typeof t=="number";case ie.FLOAT:return(t)=>{if(typeof t!="number")return!1;if(Number.isNaN(t)||!Number.isFinite(t))return!0;if(t>Fj||t{if(typeof t!=="number"||!Number.isInteger(t))return!1;if(t>Lj||t{if(typeof t!=="number"||!Number.isInteger(t))return!1;if(t>Mj||t<0)return`${t.toFixed()} out of range`;return!0};case ie.BOOL:return(t)=>typeof t=="boolean";case ie.STRING:return(t)=>{if(typeof t!="string")return!1;return Cv().checkUtf8(t)||"invalid UTF8"};case ie.BYTES:return(t)=>t instanceof Uint8Array;case ie.INT64:case ie.SFIXED64:case ie.SINT64:return(t)=>{if(typeof t=="bigint"||typeof t=="number"||typeof t=="string"&&t.length>0)try{return Sn.parse(t),!0}catch(n){return`${t} out of range`}return!1};case ie.FIXED64:case ie.UINT64:return(t)=>{if(typeof t=="bigint"||typeof t=="number"||typeof t=="string"&&t.length>0)try{return Sn.uParse(t),!0}catch(n){return`${t} out of range`}return!1}}}function cS(e,t,n){if(n=typeof n=="string"?`: ${n}`:`, got ${uS(t)}`,e.scalar!==void 0)return`expected ${jqe(e.scalar)}`+n;if(e.enum!==void 0)return`expected ${e.enum.toString()}`+n;return`expected ${_re(e.message)}`+n}function uS(e){switch(typeof e){case"object":if(e===null)return"null";if(e instanceof Uint8Array)return`Uint8Array(${e.length})`;if(Array.isArray(e))return`Array(${e.length})`;if(Av(e))return xre(e.field());if(Rv(e))return wre(e.field());if(jv(e))return _re(e.desc);if(Iv(e))return`message ${e.$typeName}`;return"object";case"string":return e.length>30?"string":`"${e.split('"').join("\\\"")}"`;case"boolean":return String(e);case"number":return String(e);case"bigint":return String(e)+"n";default:return typeof e}}function _re(e){return`ReflectMessage (${e.typeName})`}function xre(e){switch(e.listKind){case"message":return`ReflectList (${e.message.toString()})`;case"enum":return`ReflectList (${e.enum.toString()})`;case"scalar":return`ReflectList (${ie[e.scalar]})`}}function wre(e){switch(e.mapKind){case"message":return`ReflectMap (${ie[e.mapKey]}, ${e.message.toString()})`;case"enum":return`ReflectMap (${ie[e.mapKey]}, ${e.enum.toString()})`;case"scalar":return`ReflectMap (${ie[e.mapKey]}, ${ie[e.scalar]})`}}function jqe(e){switch(e){case ie.STRING:return"string";case ie.BOOL:return"boolean";case ie.INT64:case ie.SINT64:case ie.SFIXED64:return"bigint (int64)";case ie.UINT64:case ie.FIXED64:return"bigint (uint64)";case ie.BYTES:return"Uint8Array";case ie.DOUBLE:return"number (float64)";case ie.FLOAT:return"number (float32)";case ie.FIXED32:case ie.UINT32:return"number (uint32)";case ie.INT32:case ie.SFIXED32:case ie.SINT32:return"number (int32)"}}var Fqe=0;function dp(e){if(Cqe(e))return{toMessage:(n)=>pS(n),toLocal:(n)=>dS(n)};if(e.fieldKind=="message"&&!e.oneof&&jy(e.message)){let n=e.message,r=n.fields[0].localName;return{toMessage:(i)=>{let s=af(n);if(i!==void 0)s[r]=i;return s},toLocal:(i)=>i[r]}}let t=e.message;return{toMessage:(n)=>n===void 0?af(t):n,toLocal:(n)=>n}}function Cqe(e){return e.message.typeName=="google.protobuf.Struct"&&e.parent.typeName!="google.protobuf.Value"}function pS(e){let t={$typeName:"google.protobuf.Struct",fields:{}};if(ja(e))for(let n of Object.keys(e))t.fields[n]=Tre(e[n]);return t}function dS(e){let t={};for(let n of Object.keys(e.fields))t[n]=Dre(e.fields[n]);return t}function Dre(e){switch(e.kind.case){case"structValue":return dS(e.kind.value);case"listValue":return e.kind.value.values.map(Dre);case"nullValue":case void 0:return null;default:return e.kind.value}}function Tre(e){let t={$typeName:"google.protobuf.Value",kind:{case:void 0}};switch(typeof e){case"number":t.kind={case:"numberValue",value:e};break;case"string":t.kind={case:"stringValue",value:e};break;case"boolean":t.kind={case:"boolValue",value:e};break;case"object":if(e===null)t.kind={case:"nullValue",value:Fqe};else if(Array.isArray(e)){let n={$typeName:"google.protobuf.ListValue",values:[]};if(Array.isArray(e))for(let r of e)n.values.push(Tre(r));t.kind={case:"listValue",value:n}}else t.kind={case:"structValue",value:pS(e)};break}return t}function Nre(e,t,n=!0){return new zj(e,t,n)}var Sre=new WeakMap;class zj{get sortedFields(){let e=Sre.get(this.desc);if(e)return e;let t=this.desc.fields.concat().sort((n,r)=>n.number-r.number);return Sre.set(this.desc,t),t}constructor(e,t,n=!0){this.lists=new Map,this.maps=new Map,this.check=n,this.desc=e,this.message=this[Ra]=t!==null&&t!==void 0?t:af(e),this.fields=e.fields,this.oneofs=e.oneofs,this.members=e.members}findNumber(e){if(!this._fieldsByNumber)this._fieldsByNumber=new Map(this.desc.fields.map((t)=>[t.number,t]));return this._fieldsByNumber.get(e)}oneofCase(e){return Lv(this.message,e),nre(this.message,e)}isSet(e){return Lv(this.message,e),rre(this.message,e)}clear(e){Lv(this.message,e),ore(this.message,e)}get(e){Lv(this.message,e);let t=ire(this.message,e);switch(e.fieldKind){case"list":let n=this.lists.get(e);if(!n||n[Ra]!==t)this.lists.set(e,n=new Wj(e,t,this.check));return n;case"map":let r=this.maps.get(e);if(!r||r[Ra]!==t)this.maps.set(e,r=new Pre(e,t,this.check));return r;case"message":return Yj(e,t,this.check);case"scalar":return t===void 0?$c(e.scalar,!1):Xj(e,t);case"enum":return t!==null&&t!==void 0?t:e.enum.values[0].number}}set(e,t){if(Lv(this.message,e),this.check){let r=bre(e,t);if(r)throw r}let n;if(e.fieldKind=="message")n=Qj(e,t);else if(Rv(t)||Av(t))n=t[Ra];else n=Zj(e,t);sre(this.message,e,n)}getUnknown(){return this.message.$unknown}setUnknown(e){this.message.$unknown=e}}function Lv(e,t){if(t.parent.typeName!==e.$typeName)throw new Fa(t,`cannot use ${t.toString()} with message ${e.$typeName}`,"ForeignFieldError")}function Ore(e,t,n=!0){return new Wj(e,t!==null&&t!==void 0?t:[],n)}class Wj{field(){return this._field}get size(){return this._arr.length}constructor(e,t,n){this._field=e,this._arr=this[Ra]=t,this.check=n}get(e){let t=this._arr[e];return t===void 0?void 0:Gj(this._field,t,this.check)}set(e,t){if(e<0||e>=this._arr.length)throw new Fa(this._field,`list item #${e+1}: out of range`);if(this.check){let n=Kj(this._field,e,t);if(n)throw n}this._arr[e]=Ere(this._field,t)}add(e){if(this.check){let t=Kj(this._field,this._arr.length,e);if(t)throw t}this._arr.push(Ere(this._field,e));return}clear(){this._arr.splice(0,this._arr.length)}[Symbol.iterator](){return this.values()}keys(){return this._arr.keys()}*values(){for(let e of this._arr)yield Gj(this._field,e,this.check)}*entries(){for(let e=0;er.name===t);if(!n)throw Error(`cannot parse ${e} default value: ${t}`);return n.number}function Ire(e,t){switch(e){case ie.STRING:return t;case ie.BYTES:{let n=qqe(t);if(n===!1)throw Error(`cannot parse ${ie[e]} default value: ${t}`);return n}case ie.INT64:case ie.SFIXED64:case ie.SINT64:return Sn.parse(t);case ie.UINT64:case ie.FIXED64:return Sn.uParse(t);case ie.DOUBLE:case ie.FLOAT:switch(t){case"inf":return Number.POSITIVE_INFINITY;case"-inf":return Number.NEGATIVE_INFINITY;case"nan":return Number.NaN;default:return parseFloat(t)}case ie.BOOL:return t==="true";case ie.INT32:case ie.UINT32:case ie.SINT32:case ie.FIXED32:case ie.SFIXED32:return parseInt(t,10)}}function qqe(e){let t=[],n={tail:e,c:"",next(){if(this.tail.length==0)return!1;return this.c=this.tail[0],this.tail=this.tail.substring(1),!0},take(r){if(this.tail.length>=r){let i=this.tail.substring(0,r);return this.tail=this.tail.substring(r),i}return!1}};while(n.next())switch(n.c){case"\\":if(n.next())switch(n.c){case"\\":t.push(n.c.charCodeAt(0));break;case"b":t.push(8);break;case"f":t.push(12);break;case"n":t.push(10);break;case"r":t.push(13);break;case"t":t.push(9);break;case"v":t.push(11);break;case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":{let r=n.c,i=n.take(2);if(i===!1)return!1;let s=parseInt(r+i,8);if(Number.isNaN(s))return!1;t.push(s);break}case"x":{let r=n.c,i=n.take(2);if(i===!1)return!1;let s=parseInt(r+i,16);if(Number.isNaN(s))return!1;t.push(s);break}case"u":{let r=n.c,i=n.take(4);if(i===!1)return!1;let s=parseInt(r+i,16);if(Number.isNaN(s))return!1;let o=new Uint8Array(4);new DataView(o.buffer).setInt32(0,s,!0),t.push(o[0],o[1],o[2],o[3]);break}case"U":{let r=n.c,i=n.take(8);if(i===!1)return!1;let s=Sn.uEnc(r+i),o=new Uint8Array(8),a=new DataView(o.buffer);a.setInt32(0,s.lo,!0),a.setInt32(4,s.hi,!0),t.push(o[0],o[1],o[2],o[3],o[4],o[5],o[6],o[7]);break}}break;default:t.push(n.c.charCodeAt(0))}return new Uint8Array(t)}function*mS(e){switch(e.kind){case"file":for(let t of e.messages)yield t,yield*mS(t);yield*e.enums,yield*e.services,yield*e.extensions;break;case"message":for(let t of e.nestedMessages)yield t,yield*mS(t);yield*e.nestedEnums,yield*e.nestedExtensions;break}}function yS(...e){let t=Uqe();if(!e.length)return t;if("$typeName"in e[0]&&e[0].$typeName=="google.protobuf.FileDescriptorSet"){for(let n of e[0].file)Fre(n,t);return t}if("$typeName"in e[0]){let s=function(o){let a=[];for(let l of o.dependency){if(t.getFile(l)!=null)continue;if(i.has(l))continue;let c=r(l);if(!c)throw Error(`Unable to resolve ${l}, imported by ${o.name}`);if("kind"in c)t.addFile(c,!1,!0);else i.add(c.name),a.push(c)}return a.concat(...a.map(s))},n=e[0],r=e[1],i=new Set;for(let o of[n,...s(n)].reverse())Fre(o,t)}else for(let n of e)for(let r of n.files)t.addFile(r);return t}function Uqe(){let e=new Map,t=new Map,n=new Map;return{kind:"registry",types:e,extendees:t,[Symbol.iterator](){return e.values()},get files(){return n.values()},addFile(r,i,s){if(n.set(r.proto.name,r),!i)for(let o of mS(r))this.add(o);if(s)for(let o of r.dependencies)this.addFile(o,i,s)},add(r){if(r.kind=="extension"){let i=t.get(r.extendee.typeName);if(!i)t.set(r.extendee.typeName,i=new Map);i.set(r.number,r)}e.set(r.typeName,r)},get(r){return e.get(r)},getFile(r){return n.get(r)},getMessage(r){let i=e.get(r);return(i===null||i===void 0?void 0:i.kind)=="message"?i:void 0},getEnum(r){let i=e.get(r);return(i===null||i===void 0?void 0:i.kind)=="enum"?i:void 0},getExtension(r){let i=e.get(r);return(i===null||i===void 0?void 0:i.kind)=="extension"?i:void 0},getExtensionFor(r,i){var s;return(s=t.get(r.typeName))===null||s===void 0?void 0:s.get(i)},getService(r){let i=e.get(r);return(i===null||i===void 0?void 0:i.kind)=="service"?i:void 0}}}var Bqe=998,Vqe=999,Kqe=9999,Jqe=9,Uv=10,qv=11,Gqe=12,Are=14,sF=3,Hqe=2,Rre=1,zqe=0,tF=1,jre=2,Wqe=3,Qqe=1,Yqe=2,Xqe=1,Zqe=2;var eUe=1001,Mre={998:{fieldPresence:1,enumType:2,repeatedFieldEncoding:2,utf8Validation:3,messageEncoding:1,jsonFormat:2,enforceNamingStyle:2,defaultSymbolVisibility:1},999:{fieldPresence:2,enumType:1,repeatedFieldEncoding:1,utf8Validation:2,messageEncoding:1,jsonFormat:1,enforceNamingStyle:2,defaultSymbolVisibility:1},1000:{fieldPresence:1,enumType:1,repeatedFieldEncoding:1,utf8Validation:2,messageEncoding:1,jsonFormat:1,enforceNamingStyle:2,defaultSymbolVisibility:1},1001:{fieldPresence:1,enumType:1,repeatedFieldEncoding:1,utf8Validation:2,messageEncoding:1,jsonFormat:1,enforceNamingStyle:1,defaultSymbolVisibility:2}};function Fre(e,t){var n,r;let i={kind:"file",proto:e,deprecated:(r=(n=e.options)===null||n===void 0?void 0:n.deprecated)!==null&&r!==void 0?r:!1,edition:iUe(e),name:e.name.replace(/\.proto$/,""),dependencies:sUe(e,t),enums:[],messages:[],extensions:[],services:[],toString(){return`file ${e.name}`}},s=new Map,o={get(a){return s.get(a)},add(a){var l;Ca(((l=a.proto.options)===null||l===void 0?void 0:l.mapEntry)===!0),s.set(a.typeName,a)}};for(let a of e.enumType)Lre(a,i,void 0,t);for(let a of e.messageType)qre(a,i,void 0,t,o);for(let a of e.service)tUe(a,i,t);nF(i,t);for(let a of s.values())rF(a,t,o);for(let a of i.messages)rF(a,t,o),nF(a,t);t.addFile(i,!0)}function nF(e,t){switch(e.kind){case"file":for(let n of e.proto.extension){let r=iF(n,e,t);e.extensions.push(r),t.add(r)}break;case"message":for(let n of e.proto.extension){let r=iF(n,e,t);e.nestedExtensions.push(r),t.add(r)}for(let n of e.nestedMessages)nF(n,t);break}}function rF(e,t,n){let r=e.proto.oneofDecl.map((s)=>rUe(s,e)),i=new Set;for(let s of e.proto.field){let o=lUe(s,r),a=iF(s,e,t,o,n);if(e.fields.push(a),e.field[a.localName]=a,o===void 0)e.members.push(a);else if(o.fields.push(a),!i.has(o))i.add(o),e.members.push(o)}for(let s of r.filter((o)=>i.has(o)))e.oneofs.push(s);for(let s of e.nestedMessages)rF(s,t,n)}function Lre(e,t,n,r){var i,s,o,a,l;let c=oUe(e.name,e.value),u={kind:"enum",proto:e,deprecated:(s=(i=e.options)===null||i===void 0?void 0:i.deprecated)!==null&&s!==void 0?s:!1,file:t,parent:n,open:!0,name:e.name,typeName:hS(e,n,t),value:{},values:[],sharedPrefix:c,toString(){return`enum ${this.typeName}`}};u.open=dUe(u),r.add(u);for(let p of e.value){let d=p.name;u.values.push(u.value[p.number]={kind:"enum_value",proto:p,deprecated:(a=(o=p.options)===null||o===void 0?void 0:o.deprecated)!==null&&a!==void 0?a:!1,parent:u,name:d,localName:Cy(c==null?d:d.substring(c.length)),number:p.number,toString(){return`enum value ${u.typeName}.${d}`}})}((l=n===null||n===void 0?void 0:n.nestedEnums)!==null&&l!==void 0?l:t.enums).push(u)}function qre(e,t,n,r,i){var s,o,a,l;let c={kind:"message",proto:e,deprecated:(o=(s=e.options)===null||s===void 0?void 0:s.deprecated)!==null&&o!==void 0?o:!1,file:t,parent:n,name:e.name,typeName:hS(e,n,t),fields:[],field:{},oneofs:[],members:[],nestedEnums:[],nestedMessages:[],nestedExtensions:[],toString(){return`message ${this.typeName}`}};if(((a=e.options)===null||a===void 0?void 0:a.mapEntry)===!0)i.add(c);else((l=n===null||n===void 0?void 0:n.nestedMessages)!==null&&l!==void 0?l:t.messages).push(c),r.add(c);for(let u of e.enumType)Lre(u,t,c,r);for(let u of e.nestedType)qre(u,t,c,r,i)}function tUe(e,t,n){var r,i;let s={kind:"service",proto:e,deprecated:(i=(r=e.options)===null||r===void 0?void 0:r.deprecated)!==null&&i!==void 0?i:!1,file:t,name:e.name,typeName:hS(e,void 0,t),methods:[],method:{},toString(){return`service ${this.typeName}`}};t.services.push(s),n.add(s);for(let o of e.method){let a=nUe(o,s,n);s.methods.push(a),s.method[a.localName]=a}}function nUe(e,t,n){var r,i,s,o;let a;if(e.clientStreaming&&e.serverStreaming)a="bidi_streaming";else if(e.clientStreaming)a="client_streaming";else if(e.serverStreaming)a="server_streaming";else a="unary";let l=n.getMessage(Ic(e.inputType)),c=n.getMessage(Ic(e.outputType));Ca(l,`invalid MethodDescriptorProto: input_type ${e.inputType} not found`),Ca(c,`invalid MethodDescriptorProto: output_type ${e.inputType} not found`);let u=e.name;return{kind:"rpc",proto:e,deprecated:(i=(r=e.options)===null||r===void 0?void 0:r.deprecated)!==null&&i!==void 0?i:!1,parent:t,name:u,localName:Cy(u.length?Cy(u[0].toLowerCase()+u.substring(1)):u),methodKind:a,input:l,output:c,idempotency:(o=(s=e.options)===null||s===void 0?void 0:s.idempotencyLevel)!==null&&o!==void 0?o:zqe,toString(){return`rpc ${t.typeName}.${u}`}}}function rUe(e,t){return{kind:"oneof",proto:e,deprecated:!1,parent:t,fields:[],name:e.name,localName:Cy(Fy(e.name)),toString(){return`oneof ${t.typeName}.${this.name}`}}}function iF(e,t,n,r,i){var s,o,a;let l=i===void 0,c={kind:"field",proto:e,deprecated:(o=(s=e.options)===null||s===void 0?void 0:s.deprecated)!==null&&o!==void 0?o:!1,name:e.name,number:e.number,scalar:void 0,message:void 0,enum:void 0,presence:cUe(e,r,l,t),utf8Validation:fUe(e,t),listKind:void 0,mapKind:void 0,mapKey:void 0,delimitedEncoding:void 0,packed:void 0,longAsString:!1,getDefaultValue:void 0},u;if(l){let m=t.kind=="file"?t:t.file,y=t.kind=="file"?void 0:t,h=hS(e,y,m);c.kind="extension",c.file=m,c.parent=y,c.oneof=void 0,c.typeName=h,c.jsonName=`[${h}]`,u=()=>`extension ${h}`;let b=n.getMessage(Ic(e.extendee));Ca(b,`invalid FieldDescriptorProto: extendee ${e.extendee} not found`),c.extendee=b}else{let m=t;Ca(m.kind=="message"),c.parent=m,c.oneof=r,c.localName=r?Fy(e.name):Cy(Fy(e.name)),c.jsonName=e.jsonName,u=()=>`field ${m.typeName}.${e.name}`}Object.defineProperty(c,"toString",{value:u,writable:!0,enumerable:!0,configurable:!0});let{label:p,type:d}=e,f=(a=e.options)===null||a===void 0?void 0:a.jstype;if(p===sF){let m=d==qv?i===null||i===void 0?void 0:i.get(Ic(e.typeName)):void 0;if(m){c.fieldKind="map";let{key:y,value:h}=pUe(m);return c.mapKey=y.scalar,c.mapKind=h.fieldKind,c.message=h.message,c.delimitedEncoding=!1,c.enum=h.enum,c.scalar=h.scalar,c}switch(c.fieldKind="list",d){case qv:case Uv:c.listKind="message",c.message=n.getMessage(Ic(e.typeName)),Ca(c.message),c.delimitedEncoding=Cre(e,t);break;case Are:c.listKind="enum",c.enum=n.getEnum(Ic(e.typeName)),Ca(c.enum);break;default:c.listKind="scalar",c.scalar=d,c.longAsString=f==Rre;break}return c.packed=uUe(e,t),c}switch(d){case qv:case Uv:c.fieldKind="message",c.message=n.getMessage(Ic(e.typeName)),Ca(c.message,`invalid FieldDescriptorProto: type_name ${e.typeName} not found`),c.delimitedEncoding=Cre(e,t),c.getDefaultValue=()=>{return};break;case Are:{let m=n.getEnum(Ic(e.typeName));Ca(m!==void 0,`invalid FieldDescriptorProto: type_name ${e.typeName} not found`),c.fieldKind="enum",c.enum=n.getEnum(Ic(e.typeName)),c.getDefaultValue=()=>of(e,"defaultValue")?$re(m,e.defaultValue):void 0;break}default:{c.fieldKind="scalar",c.scalar=d,c.longAsString=f==Rre,c.getDefaultValue=()=>of(e,"defaultValue")?Ire(d,e.defaultValue):void 0;break}}return c}function iUe(e){switch(e.syntax){case"":case"proto2":return Bqe;case"proto3":return Vqe;case"editions":if(e.edition===Kqe)return eUe;if(e.edition in Mre)return e.edition;throw Error(`${e.name}: unsupported edition`);default:throw Error(`${e.name}: unsupported syntax "${e.syntax}"`)}}function sUe(e,t){return e.dependency.map((n)=>{let r=t.getFile(n);if(!r)throw Error(`Cannot find ${n}, imported by ${e.name}`);return r})}function oUe(e,t){let n=aUe(e)+"_";for(let r of t){if(!r.name.toLowerCase().startsWith(n))return;let i=r.name.substring(n.length);if(i.length==0)return;if(/^\d/.test(i))return}return n}function aUe(e){return(e.substring(0,1)+e.substring(1).replace(/[A-Z]/g,(t)=>"_"+t)).toLowerCase()}function hS(e,t,n){let r;if(t)r=`${t.typeName}.${e.name}`;else if(n.proto.package.length>0)r=`${n.proto.package}.${e.name}`;else r=`${e.name}`;return r}function Ic(e){return e.startsWith(".")?e.substring(1):e}function lUe(e,t){if(!of(e,"oneofIndex"))return;if(e.proto3Optional)return;let n=t[e.oneofIndex];return Ca(n,`invalid FieldDescriptorProto: oneof #${e.oneofIndex} for field #${e.number} not found`),n}function cUe(e,t,n,r){if(e.label==Hqe)return Wqe;if(e.label==sF)return jre;if(!!t||e.proto3Optional)return tF;if(n)return tF;let i=lf("fieldPresence",{proto:e,parent:r});if(i==jre&&(e.type==qv||e.type==Uv))return tF;return i}function uUe(e,t){if(e.label!=sF)return!1;switch(e.type){case Jqe:case Gqe:case Uv:case qv:return!1}let n=e.options;if(n&&of(n,"packed"))return n.packed;return Qqe==lf("repeatedFieldEncoding",{proto:e,parent:t})}function pUe(e){let t=e.fields.find((r)=>r.number===1),n=e.fields.find((r)=>r.number===2);return Ca(t&&t.fieldKind=="scalar"&&t.scalar!=ie.BYTES&&t.scalar!=ie.FLOAT&&t.scalar!=ie.DOUBLE&&n&&n.fieldKind!="list"&&n.fieldKind!="map"),{key:t,value:n}}function dUe(e){var t;return Xqe==lf("enumType",{proto:e.proto,parent:(t=e.parent)!==null&&t!==void 0?t:e.file})}function Cre(e,t){if(e.type==Uv)return!0;return Yqe==lf("messageEncoding",{proto:e,parent:t})}function fUe(e,t){return Zqe==lf("utf8Validation",{proto:e,parent:t})}function lf(e,t){var n,r;let i=(n=t.proto.options)===null||n===void 0?void 0:n.features;if(i){let s=i[e];if(s!=0)return s}if("kind"in t){if(t.kind=="message")return lf(e,(r=t.parent)!==null&&r!==void 0?r:t.file);let s=Mre[t.edition];if(!s)throw Error(`feature default for edition ${t.edition} not found`);return s[e]}return lf(e,t.parent)}function Ca(e,t){if(!e)throw Error(t)}function Ure(e){let t=mUe(e);return t.messageType.forEach(eF),yS(t,()=>{return}).getFile(t.name)}function mUe(e){let t=Object.create({syntax:"",edition:0});return Object.assign(t,Object.assign(Object.assign({$typeName:"google.protobuf.FileDescriptorProto",dependency:[],publicDependency:[],weakDependency:[],optionDependency:[],service:[],extension:[]},e),{messageType:e.messageType.map(Bre),enumType:e.enumType.map(Vre)}))}function Bre(e){var t,n,r,i,s,o,a,l;let c=Object.create({visibility:0});return Object.assign(c,{$typeName:"google.protobuf.DescriptorProto",name:e.name,field:(n=(t=e.field)===null||t===void 0?void 0:t.map(yUe))!==null&&n!==void 0?n:[],extension:[],nestedType:(i=(r=e.nestedType)===null||r===void 0?void 0:r.map(Bre))!==null&&i!==void 0?i:[],enumType:(o=(s=e.enumType)===null||s===void 0?void 0:s.map(Vre))!==null&&o!==void 0?o:[],extensionRange:(l=(a=e.extensionRange)===null||a===void 0?void 0:a.map((u)=>Object.assign({$typeName:"google.protobuf.DescriptorProto.ExtensionRange"},u)))!==null&&l!==void 0?l:[],oneofDecl:[],reservedRange:[],reservedName:[]})}function yUe(e){let t=Object.create({label:1,typeName:"",extendee:"",defaultValue:"",oneofIndex:0,jsonName:"",proto3Optional:!1});return Object.assign(t,Object.assign(Object.assign({$typeName:"google.protobuf.FieldDescriptorProto"},e),{options:e.options?hUe(e.options):void 0}))}function hUe(e){var t,n,r;let i=Object.create({ctype:0,packed:!1,jstype:0,lazy:!1,unverifiedLazy:!1,deprecated:!1,weak:!1,debugRedact:!1,retention:0});return Object.assign(i,Object.assign(Object.assign({$typeName:"google.protobuf.FieldOptions"},e),{targets:(t=e.targets)!==null&&t!==void 0?t:[],editionDefaults:(r=(n=e.editionDefaults)===null||n===void 0?void 0:n.map((s)=>Object.assign({$typeName:"google.protobuf.FieldOptions.EditionDefault"},s)))!==null&&r!==void 0?r:[],uninterpretedOption:[]}))}function Vre(e){let t=Object.create({visibility:0});return Object.assign(t,{$typeName:"google.protobuf.EnumDescriptorProto",name:e.name,reservedName:[],reservedRange:[],value:e.value.map((n)=>Object.assign({$typeName:"google.protobuf.EnumValueDescriptorProto"},n))})}function Kre(e,t,...n){return n.reduce((r,i)=>r.nestedMessages[i],e.messages[t])}var gUe=Ure({name:"google/protobuf/descriptor.proto",package:"google.protobuf",messageType:[{name:"FileDescriptorSet",field:[{name:"file",number:1,type:11,label:3,typeName:".google.protobuf.FileDescriptorProto"}],extensionRange:[{start:536000000,end:536000001}]},{name:"FileDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"package",number:2,type:9,label:1},{name:"dependency",number:3,type:9,label:3},{name:"public_dependency",number:10,type:5,label:3},{name:"weak_dependency",number:11,type:5,label:3},{name:"option_dependency",number:15,type:9,label:3},{name:"message_type",number:4,type:11,label:3,typeName:".google.protobuf.DescriptorProto"},{name:"enum_type",number:5,type:11,label:3,typeName:".google.protobuf.EnumDescriptorProto"},{name:"service",number:6,type:11,label:3,typeName:".google.protobuf.ServiceDescriptorProto"},{name:"extension",number:7,type:11,label:3,typeName:".google.protobuf.FieldDescriptorProto"},{name:"options",number:8,type:11,label:1,typeName:".google.protobuf.FileOptions"},{name:"source_code_info",number:9,type:11,label:1,typeName:".google.protobuf.SourceCodeInfo"},{name:"syntax",number:12,type:9,label:1},{name:"edition",number:14,type:14,label:1,typeName:".google.protobuf.Edition"}]},{name:"DescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"field",number:2,type:11,label:3,typeName:".google.protobuf.FieldDescriptorProto"},{name:"extension",number:6,type:11,label:3,typeName:".google.protobuf.FieldDescriptorProto"},{name:"nested_type",number:3,type:11,label:3,typeName:".google.protobuf.DescriptorProto"},{name:"enum_type",number:4,type:11,label:3,typeName:".google.protobuf.EnumDescriptorProto"},{name:"extension_range",number:5,type:11,label:3,typeName:".google.protobuf.DescriptorProto.ExtensionRange"},{name:"oneof_decl",number:8,type:11,label:3,typeName:".google.protobuf.OneofDescriptorProto"},{name:"options",number:7,type:11,label:1,typeName:".google.protobuf.MessageOptions"},{name:"reserved_range",number:9,type:11,label:3,typeName:".google.protobuf.DescriptorProto.ReservedRange"},{name:"reserved_name",number:10,type:9,label:3},{name:"visibility",number:11,type:14,label:1,typeName:".google.protobuf.SymbolVisibility"}],nestedType:[{name:"ExtensionRange",field:[{name:"start",number:1,type:5,label:1},{name:"end",number:2,type:5,label:1},{name:"options",number:3,type:11,label:1,typeName:".google.protobuf.ExtensionRangeOptions"}]},{name:"ReservedRange",field:[{name:"start",number:1,type:5,label:1},{name:"end",number:2,type:5,label:1}]}]},{name:"ExtensionRangeOptions",field:[{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"},{name:"declaration",number:2,type:11,label:3,typeName:".google.protobuf.ExtensionRangeOptions.Declaration",options:{retention:2}},{name:"features",number:50,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"verification",number:3,type:14,label:1,typeName:".google.protobuf.ExtensionRangeOptions.VerificationState",defaultValue:"UNVERIFIED",options:{retention:2}}],nestedType:[{name:"Declaration",field:[{name:"number",number:1,type:5,label:1},{name:"full_name",number:2,type:9,label:1},{name:"type",number:3,type:9,label:1},{name:"reserved",number:5,type:8,label:1},{name:"repeated",number:6,type:8,label:1}]}],enumType:[{name:"VerificationState",value:[{name:"DECLARATION",number:0},{name:"UNVERIFIED",number:1}]}],extensionRange:[{start:1000,end:536870912}]},{name:"FieldDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"number",number:3,type:5,label:1},{name:"label",number:4,type:14,label:1,typeName:".google.protobuf.FieldDescriptorProto.Label"},{name:"type",number:5,type:14,label:1,typeName:".google.protobuf.FieldDescriptorProto.Type"},{name:"type_name",number:6,type:9,label:1},{name:"extendee",number:2,type:9,label:1},{name:"default_value",number:7,type:9,label:1},{name:"oneof_index",number:9,type:5,label:1},{name:"json_name",number:10,type:9,label:1},{name:"options",number:8,type:11,label:1,typeName:".google.protobuf.FieldOptions"},{name:"proto3_optional",number:17,type:8,label:1}],enumType:[{name:"Type",value:[{name:"TYPE_DOUBLE",number:1},{name:"TYPE_FLOAT",number:2},{name:"TYPE_INT64",number:3},{name:"TYPE_UINT64",number:4},{name:"TYPE_INT32",number:5},{name:"TYPE_FIXED64",number:6},{name:"TYPE_FIXED32",number:7},{name:"TYPE_BOOL",number:8},{name:"TYPE_STRING",number:9},{name:"TYPE_GROUP",number:10},{name:"TYPE_MESSAGE",number:11},{name:"TYPE_BYTES",number:12},{name:"TYPE_UINT32",number:13},{name:"TYPE_ENUM",number:14},{name:"TYPE_SFIXED32",number:15},{name:"TYPE_SFIXED64",number:16},{name:"TYPE_SINT32",number:17},{name:"TYPE_SINT64",number:18}]},{name:"Label",value:[{name:"LABEL_OPTIONAL",number:1},{name:"LABEL_REPEATED",number:3},{name:"LABEL_REQUIRED",number:2}]}]},{name:"OneofDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"options",number:2,type:11,label:1,typeName:".google.protobuf.OneofOptions"}]},{name:"EnumDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"value",number:2,type:11,label:3,typeName:".google.protobuf.EnumValueDescriptorProto"},{name:"options",number:3,type:11,label:1,typeName:".google.protobuf.EnumOptions"},{name:"reserved_range",number:4,type:11,label:3,typeName:".google.protobuf.EnumDescriptorProto.EnumReservedRange"},{name:"reserved_name",number:5,type:9,label:3},{name:"visibility",number:6,type:14,label:1,typeName:".google.protobuf.SymbolVisibility"}],nestedType:[{name:"EnumReservedRange",field:[{name:"start",number:1,type:5,label:1},{name:"end",number:2,type:5,label:1}]}]},{name:"EnumValueDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"number",number:2,type:5,label:1},{name:"options",number:3,type:11,label:1,typeName:".google.protobuf.EnumValueOptions"}]},{name:"ServiceDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"method",number:2,type:11,label:3,typeName:".google.protobuf.MethodDescriptorProto"},{name:"options",number:3,type:11,label:1,typeName:".google.protobuf.ServiceOptions"}]},{name:"MethodDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"input_type",number:2,type:9,label:1},{name:"output_type",number:3,type:9,label:1},{name:"options",number:4,type:11,label:1,typeName:".google.protobuf.MethodOptions"},{name:"client_streaming",number:5,type:8,label:1,defaultValue:"false"},{name:"server_streaming",number:6,type:8,label:1,defaultValue:"false"}]},{name:"FileOptions",field:[{name:"java_package",number:1,type:9,label:1},{name:"java_outer_classname",number:8,type:9,label:1},{name:"java_multiple_files",number:10,type:8,label:1,defaultValue:"false",options:{}},{name:"java_generate_equals_and_hash",number:20,type:8,label:1,options:{deprecated:!0}},{name:"java_string_check_utf8",number:27,type:8,label:1,defaultValue:"false"},{name:"optimize_for",number:9,type:14,label:1,typeName:".google.protobuf.FileOptions.OptimizeMode",defaultValue:"SPEED"},{name:"go_package",number:11,type:9,label:1},{name:"cc_generic_services",number:16,type:8,label:1,defaultValue:"false"},{name:"java_generic_services",number:17,type:8,label:1,defaultValue:"false"},{name:"py_generic_services",number:18,type:8,label:1,defaultValue:"false"},{name:"deprecated",number:23,type:8,label:1,defaultValue:"false"},{name:"cc_enable_arenas",number:31,type:8,label:1,defaultValue:"true"},{name:"objc_class_prefix",number:36,type:9,label:1},{name:"csharp_namespace",number:37,type:9,label:1},{name:"swift_prefix",number:39,type:9,label:1},{name:"php_class_prefix",number:40,type:9,label:1},{name:"php_namespace",number:41,type:9,label:1},{name:"php_metadata_namespace",number:44,type:9,label:1},{name:"ruby_package",number:45,type:9,label:1},{name:"features",number:50,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],enumType:[{name:"OptimizeMode",value:[{name:"SPEED",number:1},{name:"CODE_SIZE",number:2},{name:"LITE_RUNTIME",number:3}]}],extensionRange:[{start:1000,end:536870912}]},{name:"MessageOptions",field:[{name:"message_set_wire_format",number:1,type:8,label:1,defaultValue:"false"},{name:"no_standard_descriptor_accessor",number:2,type:8,label:1,defaultValue:"false"},{name:"deprecated",number:3,type:8,label:1,defaultValue:"false"},{name:"map_entry",number:7,type:8,label:1},{name:"deprecated_legacy_json_field_conflicts",number:11,type:8,label:1,options:{deprecated:!0}},{name:"features",number:12,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],extensionRange:[{start:1000,end:536870912}]},{name:"FieldOptions",field:[{name:"ctype",number:1,type:14,label:1,typeName:".google.protobuf.FieldOptions.CType",defaultValue:"STRING"},{name:"packed",number:2,type:8,label:1},{name:"jstype",number:6,type:14,label:1,typeName:".google.protobuf.FieldOptions.JSType",defaultValue:"JS_NORMAL"},{name:"lazy",number:5,type:8,label:1,defaultValue:"false"},{name:"unverified_lazy",number:15,type:8,label:1,defaultValue:"false"},{name:"deprecated",number:3,type:8,label:1,defaultValue:"false"},{name:"weak",number:10,type:8,label:1,defaultValue:"false",options:{deprecated:!0}},{name:"debug_redact",number:16,type:8,label:1,defaultValue:"false"},{name:"retention",number:17,type:14,label:1,typeName:".google.protobuf.FieldOptions.OptionRetention"},{name:"targets",number:19,type:14,label:3,typeName:".google.protobuf.FieldOptions.OptionTargetType"},{name:"edition_defaults",number:20,type:11,label:3,typeName:".google.protobuf.FieldOptions.EditionDefault"},{name:"features",number:21,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"feature_support",number:22,type:11,label:1,typeName:".google.protobuf.FieldOptions.FeatureSupport"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],nestedType:[{name:"EditionDefault",field:[{name:"edition",number:3,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"value",number:2,type:9,label:1}]},{name:"FeatureSupport",field:[{name:"edition_introduced",number:1,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"edition_deprecated",number:2,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"deprecation_warning",number:3,type:9,label:1},{name:"edition_removed",number:4,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"removal_error",number:5,type:9,label:1}]}],enumType:[{name:"CType",value:[{name:"STRING",number:0},{name:"CORD",number:1},{name:"STRING_PIECE",number:2}]},{name:"JSType",value:[{name:"JS_NORMAL",number:0},{name:"JS_STRING",number:1},{name:"JS_NUMBER",number:2}]},{name:"OptionRetention",value:[{name:"RETENTION_UNKNOWN",number:0},{name:"RETENTION_RUNTIME",number:1},{name:"RETENTION_SOURCE",number:2}]},{name:"OptionTargetType",value:[{name:"TARGET_TYPE_UNKNOWN",number:0},{name:"TARGET_TYPE_FILE",number:1},{name:"TARGET_TYPE_EXTENSION_RANGE",number:2},{name:"TARGET_TYPE_MESSAGE",number:3},{name:"TARGET_TYPE_FIELD",number:4},{name:"TARGET_TYPE_ONEOF",number:5},{name:"TARGET_TYPE_ENUM",number:6},{name:"TARGET_TYPE_ENUM_ENTRY",number:7},{name:"TARGET_TYPE_SERVICE",number:8},{name:"TARGET_TYPE_METHOD",number:9}]}],extensionRange:[{start:1000,end:536870912}]},{name:"OneofOptions",field:[{name:"features",number:1,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],extensionRange:[{start:1000,end:536870912}]},{name:"EnumOptions",field:[{name:"allow_alias",number:2,type:8,label:1},{name:"deprecated",number:3,type:8,label:1,defaultValue:"false"},{name:"deprecated_legacy_json_field_conflicts",number:6,type:8,label:1,options:{deprecated:!0}},{name:"features",number:7,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],extensionRange:[{start:1000,end:536870912}]},{name:"EnumValueOptions",field:[{name:"deprecated",number:1,type:8,label:1,defaultValue:"false"},{name:"features",number:2,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"debug_redact",number:3,type:8,label:1,defaultValue:"false"},{name:"feature_support",number:4,type:11,label:1,typeName:".google.protobuf.FieldOptions.FeatureSupport"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],extensionRange:[{start:1000,end:536870912}]},{name:"ServiceOptions",field:[{name:"features",number:34,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"deprecated",number:33,type:8,label:1,defaultValue:"false"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],extensionRange:[{start:1000,end:536870912}]},{name:"MethodOptions",field:[{name:"deprecated",number:33,type:8,label:1,defaultValue:"false"},{name:"idempotency_level",number:34,type:14,label:1,typeName:".google.protobuf.MethodOptions.IdempotencyLevel",defaultValue:"IDEMPOTENCY_UNKNOWN"},{name:"features",number:35,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],enumType:[{name:"IdempotencyLevel",value:[{name:"IDEMPOTENCY_UNKNOWN",number:0},{name:"NO_SIDE_EFFECTS",number:1},{name:"IDEMPOTENT",number:2}]}],extensionRange:[{start:1000,end:536870912}]},{name:"UninterpretedOption",field:[{name:"name",number:2,type:11,label:3,typeName:".google.protobuf.UninterpretedOption.NamePart"},{name:"identifier_value",number:3,type:9,label:1},{name:"positive_int_value",number:4,type:4,label:1},{name:"negative_int_value",number:5,type:3,label:1},{name:"double_value",number:6,type:1,label:1},{name:"string_value",number:7,type:12,label:1},{name:"aggregate_value",number:8,type:9,label:1}],nestedType:[{name:"NamePart",field:[{name:"name_part",number:1,type:9,label:2},{name:"is_extension",number:2,type:8,label:2}]}]},{name:"FeatureSet",field:[{name:"field_presence",number:1,type:14,label:1,typeName:".google.protobuf.FeatureSet.FieldPresence",options:{retention:1,targets:[4,1],editionDefaults:[{value:"EXPLICIT",edition:900},{value:"IMPLICIT",edition:999},{value:"EXPLICIT",edition:1000}]}},{name:"enum_type",number:2,type:14,label:1,typeName:".google.protobuf.FeatureSet.EnumType",options:{retention:1,targets:[6,1],editionDefaults:[{value:"CLOSED",edition:900},{value:"OPEN",edition:999}]}},{name:"repeated_field_encoding",number:3,type:14,label:1,typeName:".google.protobuf.FeatureSet.RepeatedFieldEncoding",options:{retention:1,targets:[4,1],editionDefaults:[{value:"EXPANDED",edition:900},{value:"PACKED",edition:999}]}},{name:"utf8_validation",number:4,type:14,label:1,typeName:".google.protobuf.FeatureSet.Utf8Validation",options:{retention:1,targets:[4,1],editionDefaults:[{value:"NONE",edition:900},{value:"VERIFY",edition:999}]}},{name:"message_encoding",number:5,type:14,label:1,typeName:".google.protobuf.FeatureSet.MessageEncoding",options:{retention:1,targets:[4,1],editionDefaults:[{value:"LENGTH_PREFIXED",edition:900}]}},{name:"json_format",number:6,type:14,label:1,typeName:".google.protobuf.FeatureSet.JsonFormat",options:{retention:1,targets:[3,6,1],editionDefaults:[{value:"LEGACY_BEST_EFFORT",edition:900},{value:"ALLOW",edition:999}]}},{name:"enforce_naming_style",number:7,type:14,label:1,typeName:".google.protobuf.FeatureSet.EnforceNamingStyle",options:{retention:2,targets:[1,2,3,4,5,6,7,8,9],editionDefaults:[{value:"STYLE_LEGACY",edition:900},{value:"STYLE2024",edition:1001}]}},{name:"default_symbol_visibility",number:8,type:14,label:1,typeName:".google.protobuf.FeatureSet.VisibilityFeature.DefaultSymbolVisibility",options:{retention:2,targets:[1],editionDefaults:[{value:"EXPORT_ALL",edition:900},{value:"EXPORT_TOP_LEVEL",edition:1001}]}}],nestedType:[{name:"VisibilityFeature",enumType:[{name:"DefaultSymbolVisibility",value:[{name:"DEFAULT_SYMBOL_VISIBILITY_UNKNOWN",number:0},{name:"EXPORT_ALL",number:1},{name:"EXPORT_TOP_LEVEL",number:2},{name:"LOCAL_ALL",number:3},{name:"STRICT",number:4}]}]}],enumType:[{name:"FieldPresence",value:[{name:"FIELD_PRESENCE_UNKNOWN",number:0},{name:"EXPLICIT",number:1},{name:"IMPLICIT",number:2},{name:"LEGACY_REQUIRED",number:3}]},{name:"EnumType",value:[{name:"ENUM_TYPE_UNKNOWN",number:0},{name:"OPEN",number:1},{name:"CLOSED",number:2}]},{name:"RepeatedFieldEncoding",value:[{name:"REPEATED_FIELD_ENCODING_UNKNOWN",number:0},{name:"PACKED",number:1},{name:"EXPANDED",number:2}]},{name:"Utf8Validation",value:[{name:"UTF8_VALIDATION_UNKNOWN",number:0},{name:"VERIFY",number:2},{name:"NONE",number:3}]},{name:"MessageEncoding",value:[{name:"MESSAGE_ENCODING_UNKNOWN",number:0},{name:"LENGTH_PREFIXED",number:1},{name:"DELIMITED",number:2}]},{name:"JsonFormat",value:[{name:"JSON_FORMAT_UNKNOWN",number:0},{name:"ALLOW",number:1},{name:"LEGACY_BEST_EFFORT",number:2}]},{name:"EnforceNamingStyle",value:[{name:"ENFORCE_NAMING_STYLE_UNKNOWN",number:0},{name:"STYLE2024",number:1},{name:"STYLE_LEGACY",number:2}]}],extensionRange:[{start:1000,end:9995},{start:9995,end:1e4},{start:1e4,end:10001}]},{name:"FeatureSetDefaults",field:[{name:"defaults",number:1,type:11,label:3,typeName:".google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault"},{name:"minimum_edition",number:4,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"maximum_edition",number:5,type:14,label:1,typeName:".google.protobuf.Edition"}],nestedType:[{name:"FeatureSetEditionDefault",field:[{name:"edition",number:3,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"overridable_features",number:4,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"fixed_features",number:5,type:11,label:1,typeName:".google.protobuf.FeatureSet"}]}]},{name:"SourceCodeInfo",field:[{name:"location",number:1,type:11,label:3,typeName:".google.protobuf.SourceCodeInfo.Location"}],nestedType:[{name:"Location",field:[{name:"path",number:1,type:5,label:3,options:{packed:!0}},{name:"span",number:2,type:5,label:3,options:{packed:!0}},{name:"leading_comments",number:3,type:9,label:1},{name:"trailing_comments",number:4,type:9,label:1},{name:"leading_detached_comments",number:6,type:9,label:3}]}],extensionRange:[{start:536000000,end:536000001}]},{name:"GeneratedCodeInfo",field:[{name:"annotation",number:1,type:11,label:3,typeName:".google.protobuf.GeneratedCodeInfo.Annotation"}],nestedType:[{name:"Annotation",field:[{name:"path",number:1,type:5,label:3,options:{packed:!0}},{name:"source_file",number:2,type:9,label:1},{name:"begin",number:3,type:5,label:1},{name:"end",number:4,type:5,label:1},{name:"semantic",number:5,type:14,label:1,typeName:".google.protobuf.GeneratedCodeInfo.Annotation.Semantic"}],enumType:[{name:"Semantic",value:[{name:"NONE",number:0},{name:"SET",number:1},{name:"ALIAS",number:2}]}]}]}],enumType:[{name:"Edition",value:[{name:"EDITION_UNKNOWN",number:0},{name:"EDITION_LEGACY",number:900},{name:"EDITION_PROTO2",number:998},{name:"EDITION_PROTO3",number:999},{name:"EDITION_2023",number:1000},{name:"EDITION_2024",number:1001},{name:"EDITION_UNSTABLE",number:9999},{name:"EDITION_1_TEST_ONLY",number:1},{name:"EDITION_2_TEST_ONLY",number:2},{name:"EDITION_99997_TEST_ONLY",number:99997},{name:"EDITION_99998_TEST_ONLY",number:99998},{name:"EDITION_99999_TEST_ONLY",number:99999},{name:"EDITION_MAX",number:2147483647}]},{name:"SymbolVisibility",value:[{name:"VISIBILITY_UNSET",number:0},{name:"VISIBILITY_LOCAL",number:1},{name:"VISIBILITY_EXPORT",number:2}]}]}),gS=Kre(gUe,0);var Jre;(function(e){e[e.DECLARATION=0]="DECLARATION",e[e.UNVERIFIED=1]="UNVERIFIED"})(Jre||(Jre={}));var Gre;(function(e){e[e.DOUBLE=1]="DOUBLE",e[e.FLOAT=2]="FLOAT",e[e.INT64=3]="INT64",e[e.UINT64=4]="UINT64",e[e.INT32=5]="INT32",e[e.FIXED64=6]="FIXED64",e[e.FIXED32=7]="FIXED32",e[e.BOOL=8]="BOOL",e[e.STRING=9]="STRING",e[e.GROUP=10]="GROUP",e[e.MESSAGE=11]="MESSAGE",e[e.BYTES=12]="BYTES",e[e.UINT32=13]="UINT32",e[e.ENUM=14]="ENUM",e[e.SFIXED32=15]="SFIXED32",e[e.SFIXED64=16]="SFIXED64",e[e.SINT32=17]="SINT32",e[e.SINT64=18]="SINT64"})(Gre||(Gre={}));var Hre;(function(e){e[e.OPTIONAL=1]="OPTIONAL",e[e.REPEATED=3]="REPEATED",e[e.REQUIRED=2]="REQUIRED"})(Hre||(Hre={}));var zre;(function(e){e[e.SPEED=1]="SPEED",e[e.CODE_SIZE=2]="CODE_SIZE",e[e.LITE_RUNTIME=3]="LITE_RUNTIME"})(zre||(zre={}));var Wre;(function(e){e[e.STRING=0]="STRING",e[e.CORD=1]="CORD",e[e.STRING_PIECE=2]="STRING_PIECE"})(Wre||(Wre={}));var Qre;(function(e){e[e.JS_NORMAL=0]="JS_NORMAL",e[e.JS_STRING=1]="JS_STRING",e[e.JS_NUMBER=2]="JS_NUMBER"})(Qre||(Qre={}));var Yre;(function(e){e[e.RETENTION_UNKNOWN=0]="RETENTION_UNKNOWN",e[e.RETENTION_RUNTIME=1]="RETENTION_RUNTIME",e[e.RETENTION_SOURCE=2]="RETENTION_SOURCE"})(Yre||(Yre={}));var Xre;(function(e){e[e.TARGET_TYPE_UNKNOWN=0]="TARGET_TYPE_UNKNOWN",e[e.TARGET_TYPE_FILE=1]="TARGET_TYPE_FILE",e[e.TARGET_TYPE_EXTENSION_RANGE=2]="TARGET_TYPE_EXTENSION_RANGE",e[e.TARGET_TYPE_MESSAGE=3]="TARGET_TYPE_MESSAGE",e[e.TARGET_TYPE_FIELD=4]="TARGET_TYPE_FIELD",e[e.TARGET_TYPE_ONEOF=5]="TARGET_TYPE_ONEOF",e[e.TARGET_TYPE_ENUM=6]="TARGET_TYPE_ENUM",e[e.TARGET_TYPE_ENUM_ENTRY=7]="TARGET_TYPE_ENUM_ENTRY",e[e.TARGET_TYPE_SERVICE=8]="TARGET_TYPE_SERVICE",e[e.TARGET_TYPE_METHOD=9]="TARGET_TYPE_METHOD"})(Xre||(Xre={}));var Zre;(function(e){e[e.IDEMPOTENCY_UNKNOWN=0]="IDEMPOTENCY_UNKNOWN",e[e.NO_SIDE_EFFECTS=1]="NO_SIDE_EFFECTS",e[e.IDEMPOTENT=2]="IDEMPOTENT"})(Zre||(Zre={}));var eie;(function(e){e[e.DEFAULT_SYMBOL_VISIBILITY_UNKNOWN=0]="DEFAULT_SYMBOL_VISIBILITY_UNKNOWN",e[e.EXPORT_ALL=1]="EXPORT_ALL",e[e.EXPORT_TOP_LEVEL=2]="EXPORT_TOP_LEVEL",e[e.LOCAL_ALL=3]="LOCAL_ALL",e[e.STRICT=4]="STRICT"})(eie||(eie={}));var tie;(function(e){e[e.FIELD_PRESENCE_UNKNOWN=0]="FIELD_PRESENCE_UNKNOWN",e[e.EXPLICIT=1]="EXPLICIT",e[e.IMPLICIT=2]="IMPLICIT",e[e.LEGACY_REQUIRED=3]="LEGACY_REQUIRED"})(tie||(tie={}));var nie;(function(e){e[e.ENUM_TYPE_UNKNOWN=0]="ENUM_TYPE_UNKNOWN",e[e.OPEN=1]="OPEN",e[e.CLOSED=2]="CLOSED"})(nie||(nie={}));var rie;(function(e){e[e.REPEATED_FIELD_ENCODING_UNKNOWN=0]="REPEATED_FIELD_ENCODING_UNKNOWN",e[e.PACKED=1]="PACKED",e[e.EXPANDED=2]="EXPANDED"})(rie||(rie={}));var iie;(function(e){e[e.UTF8_VALIDATION_UNKNOWN=0]="UTF8_VALIDATION_UNKNOWN",e[e.VERIFY=2]="VERIFY",e[e.NONE=3]="NONE"})(iie||(iie={}));var sie;(function(e){e[e.MESSAGE_ENCODING_UNKNOWN=0]="MESSAGE_ENCODING_UNKNOWN",e[e.LENGTH_PREFIXED=1]="LENGTH_PREFIXED",e[e.DELIMITED=2]="DELIMITED"})(sie||(sie={}));var oie;(function(e){e[e.JSON_FORMAT_UNKNOWN=0]="JSON_FORMAT_UNKNOWN",e[e.ALLOW=1]="ALLOW",e[e.LEGACY_BEST_EFFORT=2]="LEGACY_BEST_EFFORT"})(oie||(oie={}));var aie;(function(e){e[e.ENFORCE_NAMING_STYLE_UNKNOWN=0]="ENFORCE_NAMING_STYLE_UNKNOWN",e[e.STYLE2024=1]="STYLE2024",e[e.STYLE_LEGACY=2]="STYLE_LEGACY"})(aie||(aie={}));var lie;(function(e){e[e.NONE=0]="NONE",e[e.SET=1]="SET",e[e.ALIAS=2]="ALIAS"})(lie||(lie={}));var cie;(function(e){e[e.EDITION_UNKNOWN=0]="EDITION_UNKNOWN",e[e.EDITION_LEGACY=900]="EDITION_LEGACY",e[e.EDITION_PROTO2=998]="EDITION_PROTO2",e[e.EDITION_PROTO3=999]="EDITION_PROTO3",e[e.EDITION_2023=1000]="EDITION_2023",e[e.EDITION_2024=1001]="EDITION_2024",e[e.EDITION_UNSTABLE=9999]="EDITION_UNSTABLE",e[e.EDITION_1_TEST_ONLY=1]="EDITION_1_TEST_ONLY",e[e.EDITION_2_TEST_ONLY=2]="EDITION_2_TEST_ONLY",e[e.EDITION_99997_TEST_ONLY=99997]="EDITION_99997_TEST_ONLY",e[e.EDITION_99998_TEST_ONLY=99998]="EDITION_99998_TEST_ONLY",e[e.EDITION_99999_TEST_ONLY=99999]="EDITION_99999_TEST_ONLY",e[e.EDITION_MAX=2147483647]="EDITION_MAX"})(cie||(cie={}));var uie;(function(e){e[e.VISIBILITY_UNSET=0]="VISIBILITY_UNSET",e[e.VISIBILITY_LOCAL=1]="VISIBILITY_LOCAL",e[e.VISIBILITY_EXPORT=2]="VISIBILITY_EXPORT"})(uie||(uie={}));function bUe(e){return Object.assign(Object.assign({readUnknownFields:!0,recursionLimit:100},e),{depth:0})}function Bv(e,t,n){let r=af(e);return oF(e).read(r,new Bj(t),bUe(n),t.byteLength),r}var pie=new WeakMap;function oF(e){let t=pie.get(e);if(t===void 0)t=vUe(e);return t}function vUe(e){let t=String(e),n=new Map,r={read:_Ue(t,n),readGroup:xUe(t,n)};pie.set(e,r);for(let i of e.fields)n.set(i.number,wUe(i));return r}function _Ue(e,t){return(n,r,i,s)=>{var o;if(++i.depth>i.recursionLimit)throw Error(`cannot decode ${e} from binary: maximum recursion depth of ${i.recursionLimit} reached`);let a=r.pos+s,l=(o=n.$unknown)!==null&&o!==void 0?o:[];while(r.pos0)n.$unknown=l;i.depth--}}function xUe(e,t){return(n,r,i,s)=>{var o;if(++i.depth>i.recursionLimit)throw Error(`cannot decode ${e} from binary: maximum recursion depth of ${i.recursionLimit} reached`);let a,l,c=(o=n.$unknown)!==null&&o!==void 0?o:[];while(r.pos0)n.$unknown=c;i.depth--}}function wUe(e){switch(e.fieldKind){case"scalar":return DUe(e);case"enum":return TUe(e);case"message":return SUe(e);case"list":return EUe(e);case"map":return kUe(e)}}function DUe(e){let t=bS(e.scalar,e.utf8Validation,e.longAsString),n=e.localName;if(e.oneof){let r=e.oneof.localName;return(i,s)=>{i[r]={case:n,value:t(s)}}}return(r,i)=>{r[n]=t(i)}}function TUe(e){var t;let n=e.localName,r=(t=e.oneof)===null||t===void 0?void 0:t.localName;if(e.enum.open){if(r!==void 0)return(o,a)=>{o[r]={case:n,value:a.int32()}};return(o,a)=>{o[n]=a.int32()}}let i=e.enum.values,s=e.number;return(o,a,l,c)=>{var u;let p=a.int32();if(i.some((d)=>d.number===p))if(r!==void 0)o[r]={case:n,value:p};else o[n]=p;else if(l.readUnknownFields){let d=[];Qne(p,d);let f=(u=o.$unknown)!==null&&u!==void 0?u:[];f.push({no:s,wireType:c,data:new Uint8Array(d)}),o.$unknown=f}}}function SUe(e){let t=e.localName,{toMessage:n,toLocal:r}=dp(e),i=die(e);if(e.oneof){let s=e.oneof.localName;return(o,a,l)=>{let c=o[s],u=n(c.case===t?c.value:void 0);i(u,a,l),o[s]={case:t,value:r(u)}}}return(s,o,a)=>{let l=n(s[t]);i(l,o,a),s[t]=r(l)}}function die(e){let t=oF(e.message);if(e.delimitedEncoding){let n=e.number;return(r,i,s)=>t.readGroup(r,i,s,n)}return(n,r,i)=>t.read(n,r,i,r.uint32())}function EUe(e){let t=e.localName;if(e.listKind=="message"){let{toMessage:o,toLocal:a}=dp(e),l=die(e);return(c,u,p)=>{let d=o(void 0);l(d,u,p),c[t].push(a(d))}}let n=e.listKind=="enum"?ie.INT32:e.scalar,r=e.listKind=="scalar"?e.longAsString:!1,i=bS(n,e.utf8Validation,r),s=n!=ie.STRING&&n!=ie.BYTES;return(o,a,l,c)=>{let u=o[t];if(c==Zn.LengthDelimited&&s){let p=a.uint32()+a.pos;while(a.posa(l),o==ie.BYTES)s=()=>new Uint8Array(0);else{let l=$c(o,!1);s=()=>l}break}case"enum":{let o=e.enum.values[0].number;i=(a)=>a.int32(),s=()=>o;break}case"message":{let{toMessage:o,toLocal:a}=dp(e),l=oF(e.message).read;i=(c,u)=>{let p=o(void 0);return l(p,c,u,c.uint32()),a(p)},s=()=>a(o(void 0));break}}return(o,a,l)=>{let c=o[t],u,p,d=a.uint32(),f=a.pos+d;while(a.posr.string(t);case ie.BOOL:return(r)=>r.bool();case ie.DOUBLE:return(r)=>r.double();case ie.FLOAT:return(r)=>r.float();case ie.INT32:return(r)=>r.int32();case ie.INT64:if(n)return(r)=>String(r.int64());return(r)=>r.int64();case ie.UINT64:if(n)return(r)=>String(r.uint64());return(r)=>r.uint64();case ie.FIXED64:if(n)return(r)=>String(r.fixed64());return(r)=>r.fixed64();case ie.BYTES:return(r)=>r.bytes();case ie.FIXED32:return(r)=>r.fixed32();case ie.SFIXED32:return(r)=>r.sfixed32();case ie.SFIXED64:if(n)return(r)=>String(r.sfixed64());return(r)=>r.sfixed64();case ie.SINT64:if(n)return(r)=>String(r.sint64());return(r)=>r.sint64();case ie.UINT32:return(r)=>r.uint32();case ie.SINT32:return(r)=>r.sint32()}}var NUe=2,OUe=3,fie={writeUnknownFields:!0};function PUe(e){return e?Object.assign(Object.assign({},fie),e):fie}function aF(e,t,n){let r=new Uj;return lF(e)(r,PUe(n),t),r.finish()}var mie=new WeakMap;function lF(e){let t=mie.get(e);if(t===void 0)t=$Ue(e);return t}function $Ue(e){let t=e.typeName,n=e.fields.concat().sort((o,a)=>o.number-a.number),r=n[0],i=[],s=(o,a,l)=>{if(l.$typeName!==t&&r!==void 0)throw new Fa(r,`cannot use ${r} with message ${l.$typeName}`,"ForeignFieldError");for(let u=0;u{let a=o[r];if(a.case===n)t(i,s,a.value)}}if(e.presence!=NUe){let r=e.presence==OUe?`cannot encode ${e} to binary: required field not set`:void 0;return(i,s,o)=>{let a=o[n];if(a!==void 0&&Object.prototype.hasOwnProperty.call(o,n))t(i,s,a);else if(r!==void 0)throw Error(r)}}if(e.fieldKind=="enum"){let r=e.enum.values[0].number;return(i,s,o)=>{let a=o[n];if(a!==r)t(i,s,a)}}switch(e.scalar){case ie.BOOL:return(r,i,s)=>{let o=s[n];if(o!==!1)t(r,i,o)};case ie.STRING:return(r,i,s)=>{let o=s[n];if(o!=="")t(r,i,o)};case ie.BYTES:return(r,i,s)=>{let o=s[n];if(!(o instanceof Uint8Array)||o.byteLength>0)t(r,i,o)};case ie.DOUBLE:case ie.FLOAT:return(r,i,s)=>{let o=s[n];if(!Object.is(o,0))t(r,i,o)};default:return(r,i,s)=>{let o=s[n];if(o!=0)t(r,i,o)}}}function RUe(e){switch(e.fieldKind){case"message":{let{toMessage:t}=dp(e),n=yie(e);return(r,i,s)=>{n(r,i,t(s))}}case"scalar":case"enum":{let t=e.fieldKind=="enum"?ie.INT32:e.scalar,n=e.number,r=_S(t),i=vS(t,e.parent.typeName,e.name);return(s,o,a)=>{s.tag(n,r),i(s,a)}}}}function jUe(e){let{localName:t,number:n}=e;switch(e.listKind){case"message":{let{toMessage:r}=dp(e),i=yie(e);return(s,o,a)=>{let l=a[t];for(let c=0;c{let c=l[t];if(c.length==0)return;o.tag(n,Zn.LengthDelimited).fork();for(let u=0;u{let c=l[t];for(let u=0;u{let d=p[t],f=Object.keys(d);for(let m=0;m{let u=c[t],p=Object.keys(u);for(let d=0;d{i.tag(1,t),n(i,r(s))}}function MUe(e){switch(e){case ie.STRING:return(t)=>t;case ie.BOOL:return(t)=>t==="true"?!0:t==="false"?!1:t;case ie.UINT64:case ie.FIXED64:return(t)=>{try{return Sn.uParse(t)}catch(n){return t}};case ie.INT64:case ie.SFIXED64:case ie.SINT64:return(t)=>{try{return Sn.parse(t)}catch(n){return t}};default:return(t)=>{let n=Number.parseInt(t);return Number.isFinite(n)?n:t}}}function vS(e,t,n){let r=LUe(e);return(i,s)=>{try{r(i,s)}catch(o){if(o instanceof Error)throw Error(`cannot encode field ${t}.${n} to binary: ${o.message}`);throw o}}}function LUe(e){switch(e){case ie.STRING:return(t,n)=>t.string(n);case ie.BOOL:return(t,n)=>t.bool(n);case ie.DOUBLE:return(t,n)=>t.double(n);case ie.FLOAT:return(t,n)=>t.float(n);case ie.INT32:return(t,n)=>t.int32(n);case ie.INT64:return(t,n)=>t.int64(n);case ie.UINT64:return(t,n)=>t.uint64(n);case ie.FIXED64:return(t,n)=>t.fixed64(n);case ie.BYTES:return(t,n)=>t.bytes(n);case ie.FIXED32:return(t,n)=>t.fixed32(n);case ie.SFIXED32:return(t,n)=>t.sfixed32(n);case ie.SFIXED64:return(t,n)=>t.sfixed64(n);case ie.SINT64:return(t,n)=>t.sint64(n);case ie.UINT32:return(t,n)=>t.uint32(n);case ie.SINT32:return(t,n)=>t.sint32(n)}}function yie(e){let t=e.number,n=lF(e.message);if(e.delimitedEncoding)return(r,i,s)=>{r.tag(t,Zn.StartGroup),n(r,i,s),r.tag(t,Zn.EndGroup)};return(r,i,s)=>{r.tag(t,Zn.LengthDelimited).fork(),n(r,i,s),r.join()}}function _S(e){switch(e){case ie.BYTES:case ie.STRING:return Zn.LengthDelimited;case ie.DOUBLE:case ie.FIXED64:case ie.SFIXED64:return Zn.Bit64;case ie.FIXED32:case ie.SFIXED32:case ie.FLOAT:return Zn.Bit32;default:return Zn.Varint}}var _ie=Ar(og(),1);var cF={id:"umf.protobuf",version:"0.1.0",coreVersion:"0.1.0",description:"Native Protobuf descriptors with explicit presence and retained unknown wire fields",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:protobuf:0.1.0",title:"UMF Protobuf descriptor representation",type:"object",required:["descriptorProfile","descriptorSet"],properties:{descriptorProfile:{const:"protobuf-es-2.15.0"},descriptorSet:{$ref:"#/$defs/google.protobuf.FileDescriptorSet"},sourceArchive:{type:"object",required:["role","compiler","files","roots"],properties:{role:{const:"original"},compiler:{type:"string",minLength:1},files:{type:"object",additionalProperties:{type:"string"}},roots:{type:"array",minItems:1,uniqueItems:!0,items:{type:"string",minLength:1}}}}},$defs:{"google.protobuf.FileDescriptorSet":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FileDescriptorSet"},fields:{type:"object",properties:{file:{type:"array",items:{$ref:"#/$defs/google.protobuf.FileDescriptorProto"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.FileDescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FileDescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},package:{type:"string"},dependency:{type:"array",items:{type:"string"}},public_dependency:{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647}},weak_dependency:{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647}},option_dependency:{type:"array",items:{type:"string"}},message_type:{type:"array",items:{$ref:"#/$defs/google.protobuf.DescriptorProto"}},enum_type:{type:"array",items:{$ref:"#/$defs/google.protobuf.EnumDescriptorProto"}},service:{type:"array",items:{$ref:"#/$defs/google.protobuf.ServiceDescriptorProto"}},extension:{type:"array",items:{$ref:"#/$defs/google.protobuf.FieldDescriptorProto"}},options:{$ref:"#/$defs/google.protobuf.FileOptions"},source_code_info:{$ref:"#/$defs/google.protobuf.SourceCodeInfo"},syntax:{type:"string"},edition:{type:"integer",minimum:-2147483648,maximum:2147483647}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.DescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.DescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},field:{type:"array",items:{$ref:"#/$defs/google.protobuf.FieldDescriptorProto"}},extension:{type:"array",items:{$ref:"#/$defs/google.protobuf.FieldDescriptorProto"}},nested_type:{type:"array",items:{$ref:"#/$defs/google.protobuf.DescriptorProto"}},enum_type:{type:"array",items:{$ref:"#/$defs/google.protobuf.EnumDescriptorProto"}},extension_range:{type:"array",items:{$ref:"#/$defs/google.protobuf.DescriptorProto.ExtensionRange"}},oneof_decl:{type:"array",items:{$ref:"#/$defs/google.protobuf.OneofDescriptorProto"}},options:{$ref:"#/$defs/google.protobuf.MessageOptions"},reserved_range:{type:"array",items:{$ref:"#/$defs/google.protobuf.DescriptorProto.ReservedRange"}},reserved_name:{type:"array",items:{type:"string"}},visibility:{type:"integer",minimum:-2147483648,maximum:2147483647}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.FieldDescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FieldDescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},number:{type:"integer",minimum:-2147483648,maximum:2147483647},label:{type:"integer",minimum:-2147483648,maximum:2147483647},type:{type:"integer",minimum:-2147483648,maximum:2147483647},type_name:{type:"string"},extendee:{type:"string"},default_value:{type:"string"},oneof_index:{type:"integer",minimum:-2147483648,maximum:2147483647},json_name:{type:"string"},options:{$ref:"#/$defs/google.protobuf.FieldOptions"},proto3_optional:{type:"boolean"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.FieldOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FieldOptions"},fields:{type:"object",properties:{ctype:{type:"integer",minimum:-2147483648,maximum:2147483647},packed:{type:"boolean"},jstype:{type:"integer",minimum:-2147483648,maximum:2147483647},lazy:{type:"boolean"},unverified_lazy:{type:"boolean"},deprecated:{type:"boolean"},weak:{type:"boolean"},debug_redact:{type:"boolean"},retention:{type:"integer",minimum:-2147483648,maximum:2147483647},targets:{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647}},edition_defaults:{type:"array",items:{$ref:"#/$defs/google.protobuf.FieldOptions.EditionDefault"}},features:{$ref:"#/$defs/google.protobuf.FeatureSet"},feature_support:{$ref:"#/$defs/google.protobuf.FieldOptions.FeatureSupport"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.FieldOptions.EditionDefault":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FieldOptions.EditionDefault"},fields:{type:"object",properties:{edition:{type:"integer",minimum:-2147483648,maximum:2147483647},value:{type:"string"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.FeatureSet":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FeatureSet"},fields:{type:"object",properties:{field_presence:{type:"integer",minimum:-2147483648,maximum:2147483647},enum_type:{type:"integer",minimum:-2147483648,maximum:2147483647},repeated_field_encoding:{type:"integer",minimum:-2147483648,maximum:2147483647},utf8_validation:{type:"integer",minimum:-2147483648,maximum:2147483647},message_encoding:{type:"integer",minimum:-2147483648,maximum:2147483647},json_format:{type:"integer",minimum:-2147483648,maximum:2147483647},enforce_naming_style:{type:"integer",minimum:-2147483648,maximum:2147483647},default_symbol_visibility:{type:"integer",minimum:-2147483648,maximum:2147483647}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.FieldOptions.FeatureSupport":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FieldOptions.FeatureSupport"},fields:{type:"object",properties:{edition_introduced:{type:"integer",minimum:-2147483648,maximum:2147483647},edition_deprecated:{type:"integer",minimum:-2147483648,maximum:2147483647},deprecation_warning:{type:"string"},edition_removed:{type:"integer",minimum:-2147483648,maximum:2147483647},removal_error:{type:"string"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.UninterpretedOption":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.UninterpretedOption"},fields:{type:"object",properties:{name:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption.NamePart"}},identifier_value:{type:"string"},positive_int_value:{type:"string",pattern:"^(?:0|-?[1-9][0-9]*)$"},negative_int_value:{type:"string",pattern:"^(?:0|-?[1-9][0-9]*)$"},double_value:{anyOf:[{type:"number"},{enum:["NaN","Infinity","-Infinity","-0"]}]},string_value:{type:"string",pattern:"^(?:[0-9a-f]{2})*$"},aggregate_value:{type:"string"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.UninterpretedOption.NamePart":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.UninterpretedOption.NamePart"},fields:{type:"object",properties:{name_part:{type:"string"},is_extension:{type:"boolean"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.EnumDescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.EnumDescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},value:{type:"array",items:{$ref:"#/$defs/google.protobuf.EnumValueDescriptorProto"}},options:{$ref:"#/$defs/google.protobuf.EnumOptions"},reserved_range:{type:"array",items:{$ref:"#/$defs/google.protobuf.EnumDescriptorProto.EnumReservedRange"}},reserved_name:{type:"array",items:{type:"string"}},visibility:{type:"integer",minimum:-2147483648,maximum:2147483647}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.EnumValueDescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.EnumValueDescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},number:{type:"integer",minimum:-2147483648,maximum:2147483647},options:{$ref:"#/$defs/google.protobuf.EnumValueOptions"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.EnumValueOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.EnumValueOptions"},fields:{type:"object",properties:{deprecated:{type:"boolean"},features:{$ref:"#/$defs/google.protobuf.FeatureSet"},debug_redact:{type:"boolean"},feature_support:{$ref:"#/$defs/google.protobuf.FieldOptions.FeatureSupport"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.EnumOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.EnumOptions"},fields:{type:"object",properties:{allow_alias:{type:"boolean"},deprecated:{type:"boolean"},deprecated_legacy_json_field_conflicts:{type:"boolean"},features:{$ref:"#/$defs/google.protobuf.FeatureSet"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.EnumDescriptorProto.EnumReservedRange":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.EnumDescriptorProto.EnumReservedRange"},fields:{type:"object",properties:{start:{type:"integer",minimum:-2147483648,maximum:2147483647},end:{type:"integer",minimum:-2147483648,maximum:2147483647}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.DescriptorProto.ExtensionRange":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.DescriptorProto.ExtensionRange"},fields:{type:"object",properties:{start:{type:"integer",minimum:-2147483648,maximum:2147483647},end:{type:"integer",minimum:-2147483648,maximum:2147483647},options:{$ref:"#/$defs/google.protobuf.ExtensionRangeOptions"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.ExtensionRangeOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.ExtensionRangeOptions"},fields:{type:"object",properties:{uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}},declaration:{type:"array",items:{$ref:"#/$defs/google.protobuf.ExtensionRangeOptions.Declaration"}},features:{$ref:"#/$defs/google.protobuf.FeatureSet"},verification:{type:"integer",minimum:-2147483648,maximum:2147483647}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.ExtensionRangeOptions.Declaration":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.ExtensionRangeOptions.Declaration"},fields:{type:"object",properties:{number:{type:"integer",minimum:-2147483648,maximum:2147483647},full_name:{type:"string"},type:{type:"string"},reserved:{type:"boolean"},repeated:{type:"boolean"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.OneofDescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.OneofDescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},options:{$ref:"#/$defs/google.protobuf.OneofOptions"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.OneofOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.OneofOptions"},fields:{type:"object",properties:{features:{$ref:"#/$defs/google.protobuf.FeatureSet"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.MessageOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.MessageOptions"},fields:{type:"object",properties:{message_set_wire_format:{type:"boolean"},no_standard_descriptor_accessor:{type:"boolean"},deprecated:{type:"boolean"},map_entry:{type:"boolean"},deprecated_legacy_json_field_conflicts:{type:"boolean"},features:{$ref:"#/$defs/google.protobuf.FeatureSet"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.DescriptorProto.ReservedRange":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.DescriptorProto.ReservedRange"},fields:{type:"object",properties:{start:{type:"integer",minimum:-2147483648,maximum:2147483647},end:{type:"integer",minimum:-2147483648,maximum:2147483647}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.ServiceDescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.ServiceDescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},method:{type:"array",items:{$ref:"#/$defs/google.protobuf.MethodDescriptorProto"}},options:{$ref:"#/$defs/google.protobuf.ServiceOptions"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.MethodDescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.MethodDescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},input_type:{type:"string"},output_type:{type:"string"},options:{$ref:"#/$defs/google.protobuf.MethodOptions"},client_streaming:{type:"boolean"},server_streaming:{type:"boolean"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.MethodOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.MethodOptions"},fields:{type:"object",properties:{deprecated:{type:"boolean"},idempotency_level:{type:"integer",minimum:-2147483648,maximum:2147483647},features:{$ref:"#/$defs/google.protobuf.FeatureSet"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.ServiceOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.ServiceOptions"},fields:{type:"object",properties:{features:{$ref:"#/$defs/google.protobuf.FeatureSet"},deprecated:{type:"boolean"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.FileOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FileOptions"},fields:{type:"object",properties:{java_package:{type:"string"},java_outer_classname:{type:"string"},java_multiple_files:{type:"boolean"},java_generate_equals_and_hash:{type:"boolean"},java_string_check_utf8:{type:"boolean"},optimize_for:{type:"integer",minimum:-2147483648,maximum:2147483647},go_package:{type:"string"},cc_generic_services:{type:"boolean"},java_generic_services:{type:"boolean"},py_generic_services:{type:"boolean"},deprecated:{type:"boolean"},cc_enable_arenas:{type:"boolean"},objc_class_prefix:{type:"string"},csharp_namespace:{type:"string"},swift_prefix:{type:"string"},php_class_prefix:{type:"string"},php_namespace:{type:"string"},php_metadata_namespace:{type:"string"},ruby_package:{type:"string"},features:{$ref:"#/$defs/google.protobuf.FeatureSet"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.SourceCodeInfo":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.SourceCodeInfo"},fields:{type:"object",properties:{location:{type:"array",items:{$ref:"#/$defs/google.protobuf.SourceCodeInfo.Location"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.SourceCodeInfo.Location":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.SourceCodeInfo.Location"},fields:{type:"object",properties:{path:{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647}},span:{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647}},leading_comments:{type:"string"},trailing_comments:{type:"string"},leading_detached_comments:{type:"array",items:{type:"string"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},unknown:{type:"object",required:["number","wireType","data"],properties:{number:{type:"integer",minimum:1,maximum:536870911},wireType:{enum:[0,1,2,3,5]},data:{type:"string",pattern:"^(?:[0-9a-f]{2})*$"}}}}},semantics:"CONTRACT-003. Descriptor fields retain native types and presence; unknown fields/options are preserved without interpretation. Browser checks are not a native compiler certificate. Source compilation is available through an explicit compiler; source emission recompiles and compares descriptor semantics before returning.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Protocol Buffers .proto and FileDescriptorSet",version:"descriptor profile @bufbuild/protobuf 2.15.0; source compiler protocompile 0.14.1; printer protoprint 1.18.1; native oracle protoc 36.2",subset:"Complete pinned descriptor message graph; proto2/proto3/Editions descriptor representation. Optional WASM source compilation has authored proto2, proto3 and Edition 2023 evidence; newer Editions are not claimed. Source emission has native compiler evidence for 15 standard roots and authored proto2/proto3/Edition 2023 cases; four Edition 2024 standard roots are explicitly unsupported."},evidence:["tests/protobuf/descriptor.test.ts","tests/protobuf/source.test.ts","tests/protobuf/emission.test.ts","tests/protobuf/behavior.test.ts","scripts/browser.ts"]}};var uF=gS;function bie(e){if(typeof e!=="string"||!/^(?:[0-9a-f]{2})*$/.test(e))throw new U("PROTOBUF_BYTES","Expected lowercase hexadecimal bytes");return Uint8Array.from(e.match(/../g)??[],(t)=>parseInt(t,16))}function hie(e,t){if(t===ie.BYTES)return bie(e);if([ie.INT64,ie.UINT64,ie.SINT64,ie.FIXED64,ie.SFIXED64].includes(t)){if(typeof e!=="string"||!/^(?:0|-?[1-9][0-9]*)$/.test(e))throw new U("PROTOBUF_INTEGER","Expected canonical decimal integer");return BigInt(e)}if((t===ie.FLOAT||t===ie.DOUBLE)&&typeof e==="string"){if(!["NaN","Infinity","-Infinity","-0"].includes(e))throw new U("PROTOBUF_FLOAT","Invalid special floating value");return Number(e)}return e}function gie(e,t){for(let n of Object.keys(e))if(!t.includes(n))throw new U("PROTOBUF_REPRESENTATION","Unknown representation field cannot be discarded",n)}function pF(e,t){if(gie(e,["type","fields","unknown"]),e.type!==t.typeName)throw new U("PROTOBUF_TYPE",`Expected ${t.typeName}`);let n=Nre(t);for(let[r,i]of Object.entries(e.fields)){let s=t.fields.find((o)=>o.name===r);if(!s)throw new U("PROTOBUF_REPRESENTATION","Unknown named descriptor field: "+r);if(s.fieldKind==="message")n.set(s,pF(i,s.message));else if(s.fieldKind==="list"){if(!Array.isArray(i))throw new U("PROTOBUF_LIST","Expected descriptor list");let o=Ore(s);for(let a of i)o.add(s.listKind==="message"?pF(a,s.message):hie(a,s.listKind==="scalar"?s.scalar:void 0));n.set(s,o)}else if(s.fieldKind==="map")throw new U("PROTOBUF_DESCRIPTOR_PROFILE","Descriptor map fields require a newer profile");else n.set(s,hie(i,s.fieldKind==="scalar"?s.scalar:void 0))}return n.setUnknown(e.unknown.map((r)=>{if(gie(r,["number","wireType","data"]),!Number.isInteger(r.number)||r.number<1||r.number>536870911||![0,1,2,3,5].includes(r.wireType))throw new U("PROTOBUF_UNKNOWN","Invalid unknown wire field");return{no:r.number,wireType:r.wireType,data:bie(r.data)}})),n}function xS(e){let t=Ae(e);try{let n=aF(uF,pF(t,uF).message);if(n.length>Zt.maxTextLength)throw new U("LIMIT","Descriptor output exceeds limit");return Bv(uF,n),n}catch(n){if(n instanceof U)throw n;throw new U("PROTOBUF_DESCRIPTOR",String(n))}}var dF="umf.protobuf",BUe=cF,VUe=new _ie.default({strict:!1,allErrors:!0}).compile(cF.schema);function KUe(e){let t=e,n=[],r=(s,o,a)=>n.push({code:s,path:o,message:a,severity:"warning"});for(let s of Object.keys(t))if(!["descriptorProfile","descriptorSet","sourceArchive"].includes(s))r("PROTOBUF_REPRESENTATION","/"+s,"Unknown representation field retained; native export blocked");if(t.sourceArchive){for(let s of Object.keys(t.sourceArchive))if(!["role","compiler","files","roots"].includes(s))r("PROTOBUF_REPRESENTATION","/sourceArchive/"+s,"Unknown source archive field retained; native export blocked")}function i(s,o){if(s.unknown.length)r("PROTOBUF_UNKNOWN",o+"/unknown","Unknown native wire fields/options retained without semantic interpretation");for(let[a,l]of Object.entries(s.fields))for(let c of Array.isArray(l)?l:[l])if(c&&typeof c==="object"&&!Array.isArray(c)&&"fields"in c&&"type"in c)i(c,o+"/fields/"+a)}i(t.descriptorSet,"/descriptorSet");try{let s=xS(t.descriptorSet),o=Bv(gS,s),a=new Set;for(let l of o.file){if(!l.name||a.has(l.name))throw Error("Missing or duplicate file name");a.add(l.name)}yS(o)}catch(s){r("PROTOBUF_INTERPRETATION","/descriptorSet",String(s))}return r("PROTOBUF_COMPILER_REQUIRED","/descriptorSet","Browser descriptor checks do not certify native compiler validity; validate emitted artifacts with the pinned native compiler"),n}function JUe(){return new nt().register(BUe,KUe)}function vie(e){return We(e,JUe())}function GUe(e){let t=vie(e);if(!t.valid)throw new U("PROTOBUF_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[dF];if(e.vocabularies[dF]?.version!=="0.1.0"||!VUe(n))throw new U("PROTOBUF_PAYLOAD","Missing or malformed Protobuf payload");return Ae(n)}function fF(e){let t=GUe(e);if(Object.keys(t).some((n)=>!["descriptorProfile","descriptorSet","sourceArchive"].includes(n)))throw new U("PROTOBUF_REPRESENTATION","Unknown representation field cannot be discarded");if(t.sourceArchive&&Object.keys(t.sourceArchive).some((n)=>!["role","compiler","files","roots"].includes(n)))throw new U("PROTOBUF_REPRESENTATION","Unknown source archive field cannot be discarded");return xS(t.descriptorSet)}function xie(e,t){let n=[],r=(a,l)=>n.push({code:a,path:t,message:l,severity:"warning"}),i=/^decimal\(\s*(\d+)\s*,\s*(-?\d+)\s*\)$/.exec(e);if(i){let a=BigInt(i[1]),l=BigInt(i[2]);if(a>2147483647n||l>2147483647n||l<-2147483648n)r("SPARK_PARAMETER_INT32","Spark JVM parses decimal parameters as int32; this value exceeds that range");if(a>38n)r("SPARK_DECIMAL_PRECISION","Spark JVM decimal precision exceeds the supported maximum of 38");if(l>a)r("SPARK_DECIMAL_SCALE","Spark JVM rejects decimal scale greater than precision");if(l<0n)r("SPARK_DECIMAL_NEGATIVE_SCALE","Negative decimal scale depends on spark.sql.legacy.allowNegativeScaleOfDecimal; default JVM configuration rejects it")}let s=/^(?:char|varchar)\(\s*(\d+)\s*\)$/.exec(e);if(s&&BigInt(s[1])>2147483647n)r("SPARK_PARAMETER_INT32","Spark JVM parses character length as int32; this value exceeds that range");let o=/^interval (year|month|day|hour|minute|second) to (year|month|day|hour|minute|second)$/.exec(e);if(o){let a=["year","month","day","hour","minute","second"],l=a.indexOf(o[1]),c=a.indexOf(o[2]);if(l<2!==c<2||l>=c)r("SPARK_INTERVAL_RANGE","Spark JVM JSON interval spelling must use an increasing range within year/month or day/time units")}return n}function wie(e){let t=[],n=(s,o,a)=>t.push({code:s,path:o,message:a,severity:"warning"});function r(s,o){if(s.kind!=="object"||s.members.name?.kind!=="string"||!s.members.type)return;let a=s.members.metadata,l=a?.kind==="object"?a.members.__COLLATIONS:void 0;if(l){let c=o+"/metadata/__COLLATIONS";if(l.kind!=="object")n("SPARK_COLLATION_MAP",c,"Native collation metadata must be a path-to-string map; JVM may ignore this value while Python rejects it");else{let p=function(d,f){if(u.set(f,d),d.kind!=="object"||d.members.type?.kind!=="string")return;let m=(y)=>f?f+"."+y:y;if(d.members.type.value==="array"&&d.members.elementType)p(d.members.elementType,m("element"));if(d.members.type.value==="map"){if(d.members.keyType)p(d.members.keyType,m("key"));if(d.members.valueType)p(d.members.valueType,m("value"))}},u=new Map;p(s.members.type,s.members.name.value);for(let[d,f]of Object.entries(l.members)){let m=c+"/"+Pe(d),y=u.get(d);if(f.kind!=="string")n("SPARK_COLLATION_VALUE",m,"Native collation annotation is not a string; JVM may ignore it while Python rejects it");else if(!/^(spark|icu)\..+$/.test(f.value))n("SPARK_COLLATION_PROVIDER",m,"Expected a Spark 4.0.1 provider-qualified collation name; provider/name validity requires native verification");if(!y)n("SPARK_COLLATION_UNRESOLVED",m,"Path does not resolve within this field through known array/map types; native parsing may discard the annotation");else if(y.kind!=="string"||y.value!=="string")n("SPARK_COLLATION_TARGET",m,"Collation path targets a non-string schema node; native parsers may reject it")}}}i(s.members.type,o+"/type")}function i(s,o){if(s.kind!=="object"||s.members.type?.kind!=="string")return;if(s.members.type.value==="struct"&&s.members.fields?.kind==="array")s.members.fields.items.forEach((a,l)=>r(a,o+"/fields/"+l));if(s.members.type.value==="array"&&s.members.elementType)i(s.members.elementType,o+"/elementType");if(s.members.type.value==="map"){if(s.members.keyType)i(s.members.keyType,o+"/keyType");if(s.members.valueType)i(s.members.valueType,o+"/valueType")}}return i(e,""),t}function Die(e){let t=[],n=(o,a,l)=>t.push({code:o,path:a,severity:"warning",message:l}),r=(o)=>o.kind==="number"?/[.eE]/.test(o.value)?"double":"long":o.kind;function i(o,a){if(o.kind==="number")if(!/[.eE]/.test(o.value)){if(o.value.replace(/^-/,"").length>19||BigInt(o.value)<-9223372036854775808n||BigInt(o.value)>9223372036854775807n)n("SPARK_METADATA_INT64_OVERFLOW",a,"Spark JVM metadata converts integer tokens to int64 and can wrap this value; UMF retains the exact token")}else if(!Number.isFinite(Number(o.value)))n("SPARK_METADATA_NONFINITE",a,"Spark JVM metadata converts this number to a nonfinite double and may emit a string; UMF retains the exact token");else n("SPARK_METADATA_DOUBLE",a,"Spark JVM metadata uses binary64 for fractional/exponent tokens; precision and source spelling may change");if(o.kind==="object")for(let[l,c]of Object.entries(o.members))i(c,a+"/"+Pe(l));if(o.kind==="array"){if(!o.items.length)n("SPARK_METADATA_EMPTY_ARRAY",a,"Spark JVM infers an empty int64 array; the source JSON does not specify the array element type");else{let l=r(o.items[0]);if(l==="null"||l==="array")n("SPARK_METADATA_ARRAY_UNSUPPORTED",a,"Spark JVM metadata does not support arrays of nulls or nested arrays");if(o.items.some((c)=>r(c)!==l))n("SPARK_METADATA_ARRAY_MIXED",a,"Spark JVM metadata requires homogeneous array categories, including separate integer and double categories")}o.items.forEach((l,c)=>i(l,a+"/"+c))}}function s(o,a){if(o.kind!=="object"||o.members.type?.kind!=="string")return;if(o.members.type.value==="struct"&&o.members.fields?.kind==="array")o.members.fields.items.forEach((l,c)=>{if(l.kind!=="object")return;let u=a+"/fields/"+c;if(l.members.metadata?.kind==="object"){if(!l.members.nullable)n("SPARK_FIELD_METADATA_WITHOUT_NULLABLE",u,"Spark JVM 4.0.1 does not accept a field with metadata but no nullable property; Python may insert the default");for(let[p,d]of Object.entries(l.members.metadata.members))if(p!=="__COLLATIONS")i(d,u+"/metadata/"+Pe(p))}if(l.members.type)s(l.members.type,u+"/type")});if(o.members.type.value==="array"&&o.members.elementType)s(o.members.elementType,a+"/elementType");if(o.members.type.value==="map"){if(o.members.keyType)s(o.members.keyType,a+"/keyType");if(o.members.valueType)s(o.members.valueType,a+"/valueType")}}return s(e,""),t}var Tie={id:"umf.spark",version:"0.1.0",coreVersion:"0.1.0",description:"Exact Spark DataType/StructType JSON with preserved metadata and native interpretation limits",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:spark:0.1.0",type:"object",properties:{profile:{const:"spark-datatype-json"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-017. Source JSON is authoritative; no native parser normalization, UDT execution or engine/configuration validity is implied. Unknown properties/types and exact numeric tokens survive.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Apache Spark DataType schema JSON",version:"4.0.1 grammar baseline; Python and JVM evidence separately qualified",subset:"Known array/map/struct shape validation, exact source preservation and candidate edits. Atomic names/parameters and UDT declarations retain interpretation limits; no JVM/browser execution, DDL or data coercion claim."},evidence:["tests/spark/schema.test.ts","fixtures/spark/capability-results.json","fixtures/spark/umf-oracle-results.json","fixtures/spark/browser-results.json","tests/spark/rename.test.ts","fixtures/spark/rename-oracle-results.json","tests/spark/upstream.test.ts","fixtures/spark/upstream-oracle-results.json","tests/spark/metadata.test.ts","fixtures/spark/metadata-oracle-results.json","tests/spark/collations.test.ts","fixtures/spark/collation-oracle-results.json","tests/spark/parameters.test.ts","fixtures/spark/parameter-oracle-results.json","tests/spark/projection.test.ts","tests/spark/reverse-projection.test.ts","fixtures/projections/spark-arrow/projection-oracle-results.json","fixtures/projections/spark-arrow/reverse-oracle-results.json","tests/spark/arrow-origin.test.ts","fixtures/projections/arrow-spark/oracle-results.json","tests/spark/upstream-projection.test.ts","fixtures/projections/arrow-spark-upstream/oracle-results.json"]}};var Sie={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:spark:datatype-json:0.1.0",$ref:"#/$defs/type",$defs:{type:{anyOf:[{type:"string",minLength:1},{type:"object",properties:{type:{const:"array"},elementType:{$ref:"#/$defs/type"},containsNull:{type:"boolean"}},required:["type","elementType","containsNull"],additionalProperties:!0},{type:"object",properties:{type:{const:"map"},keyType:{$ref:"#/$defs/type"},valueType:{$ref:"#/$defs/type"},valueContainsNull:{type:"boolean"}},required:["type","keyType","valueType","valueContainsNull"],additionalProperties:!0},{type:"object",properties:{type:{const:"struct"},fields:{type:"array",items:{$ref:"#/$defs/field"}}},required:["type","fields"],additionalProperties:!0},{type:"object",properties:{type:{const:"udt"},class:{type:"string"},pyClass:{type:["string","null"]},serializedClass:{type:"string"},sqlType:{$ref:"#/$defs/type"}},required:["type"],additionalProperties:!0},{type:"object",properties:{type:{type:"string",minLength:1,not:{enum:["array","map","struct","udt"]}}},required:["type"],additionalProperties:!0}]},field:{type:"object",properties:{name:{type:"string"},type:{$ref:"#/$defs/type"},nullable:{type:"boolean"},metadata:{type:"object"}},required:["name","type"],additionalProperties:!0}}};var Eie="umf.spark",WUe=Tie,mF,QUe=new Set(["void","null","boolean","byte","short","integer","long","float","double","string","binary","date","timestamp","timestamp_ltz","timestamp_ntz","decimal","interval","variant"]),YUe=/^(?:decimal\(\s*\d+\s*,\s*-?\d+\s*\)|(?:char|varchar)\(\s*\d+\s*\)|string collate .+|interval (?:year|month|day|hour|minute|second)(?: to (?:year|month|day|hour|minute|second))?)$/;function XUe(e){let t=e,n=[{code:"SPARK_NATIVE_UNVERIFIED",path:"",severity:"warning",message:"Schema preservation is not Spark engine validity: runtime/configuration, metadata, collation and coercion checks remain separate"}],r=(l,c,u,p="warning")=>n.push({code:l,path:c,message:u,severity:p});if(Object.keys(t).some((l)=>!["profile","root"].includes(l)))r("SPARK_REPRESENTATION","","Unknown representation fields must stay in UMF");function i(l,c){let u=l.kind==="null"?["kind"]:l.kind==="array"?["kind","items"]:l.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(l).some((p)=>!u.includes(p)))r("SPARK_REPRESENTATION",c,"Unknown tagged-tree fields must stay in UMF");if(l.kind==="object")for(let[p,d]of Object.entries(l.members))i(d,c+"/"+Pe(p));if(l.kind==="array")l.items.forEach((p,d)=>i(p,c+"/"+d))}i(t.root,"/root");let s=JSON.parse(Be(t.root));if(mF??=mt().compile(Sie),!mF(s)){for(let l of mF.errors??[])r("SPARK_STRUCTURE",l.instancePath,l.message??"Invalid DataType shape","error");return n}function o(l,c,u){for(let p of Object.keys(l))if(!c.includes(p))r("SPARK_UNKNOWN",u+"/"+Pe(p),"Uninterpreted native property preserved")}function a(l,c){if(typeof l==="string"){if(n.push(...xie(l,c)),!QUe.has(l)&&!YUe.test(l))r("SPARK_UNKNOWN_TYPE",c,"Unrecognized type spelling preserved");return}switch(l.type){case"array":o(l,["type","elementType","containsNull"],c),a(l.elementType,c+"/elementType");break;case"map":o(l,["type","keyType","valueType","valueContainsNull"],c),a(l.keyType,c+"/keyType"),a(l.valueType,c+"/valueType");break;case"struct":o(l,["type","fields"],c),l.fields.forEach((u,p)=>{let d=c+"/fields/"+p;if(o(u,["name","type","nullable","metadata"],d),a(u.type,d+"/type"),u.metadata)r("SPARK_METADATA_UNVERIFIED",d+"/metadata","Metadata retained exactly; engine value restrictions, collation paths and name dependencies are not interpreted")});break;case"udt":if(o(l,["type","class","pyClass","serializedClass","sqlType"],c),r("SPARK_UDT_UNINTERPRETED",c,"UDT declaration retained without importing classes or deserializing executable content"),l.sqlType!==void 0)a(l.sqlType,c+"/sqlType");break;default:r("SPARK_UNKNOWN_TYPE",c,"Unrecognized object-form type preserved")}}return a(s,""),n.push(...Die(t.root),...wie(t.root)),n}function ZUe(){return new nt().register(WUe,XUe)}function kie(e){return We(e,ZUe())}function e3e(e){let t=kie(e);if(!t.valid)throw new U("SPARK_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[Eie];if(!n||e.vocabularies[Eie]?.version!=="0.1.0")throw new U("SPARK_PAYLOAD","Expected pinned Spark schema payload");return Ae(n)}function Nie(e){let t=e3e(e);if(kie(e).diagnostics.some((n)=>n.code==="SPARK_REPRESENTATION"))throw new U("SPARK_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var Oie={id:"umf.tablespec",version:"0.1.0",coreVersion:"0.1.0",description:"TableSpec native table schemas and derived core scalar metadata",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:tablespec:0.1.0",type:"object",required:["profile","root","originalSource","originalFormat"],properties:{profile:{const:"tablespec-table-1"},root:{$ref:"#/$defs/node"},originalSource:{type:"string",maxLength:4000000},originalFormat:{enum:["json","yaml"]},splitFiles:{type:"object",required:["table.yaml"],minProperties:2,maxProperties:1000,additionalProperties:{type:"string",maxLength:4000000},properties:{"table.yaml":{type:"string",maxLength:4000000}}}},$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-030; source preservation and scalar-family classification, not complete Pydantic validation or coercion",scopes:["document"],capabilities:{validation:"structural",directions:["import","export"],native:{system:"TableSpec",version:"source commit 647e8e566ad78b864282ec65c0b0b2237aa63084; table version 1.0",subset:"Monolithic JSON/YAML ingestion and split file-bundle capture; copied table/column metadata access and edits, core scalar families and native recovery. Schema projections are separately qualified by CONTRACT-033, CONTRACT-038 and CONTRACT-039. Split loader migrations, split-to-monolithic lowering, native validation/coercion and general value transforms remain open."},evidence:["tests/tablespec/roundtrip.test.ts","native/tablespec/sources.json","fixtures/tablespec/oracle.json","fixtures/tablespec/browser.json","tests/tablespec/split.test.ts","fixtures/tablespec/split-oracle.json","tests/tablespec/table-edits.test.ts","fixtures/tablespec/table-edits-oracle.json","tests/tablespec/table-metadata.test.ts","tests/tablespec/boundaries.test.ts","fixtures/tablespec/boundaries-oracle.json"]}};var wS="umf.tablespec",n3e=Oie,Pie={VARCHAR:"string",TEXT:"string",CHAR:"string",BOOLEAN:"boolean",INTEGER:"integer",DECIMAL:"decimal",FLOAT:"float",DATE:"date",DATETIME:"timestamp",TIMESTAMP:"timestamp"},$ie=(e,t)=>t==="json"?Jt(e):Wa(e);function Iie(e){if(e.kind!=="object"||e.members.table_name?.kind!=="string"||e.members.columns?.kind!=="array")throw new U("TABLESPEC_TABLE","Expected table_name and a monolithic columns array");if(e.members.version?.kind!=="string"||e.members.version.value!=="1.0")throw new U("TABLESPEC_VERSION","Expected TableSpec table version 1.0");let t=new Set,n=e.members.columns.items.map((r,i)=>{if(r.kind!=="object"||r.members.name?.kind!=="string"||r.members.data_type?.kind!=="string")throw new U("TABLESPEC_COLUMN","Expected native column name and data_type");let s=r.members.name.value;if(t.has(s))throw new U("TABLESPEC_COLUMN","Duplicate column name");t.add(s);let o=Object.hasOwn(Pie,r.members.data_type.value)?Pie[r.members.data_type.value]:void 0;return{id:"column:"+i,name:s,...r.members.description?.kind==="string"?{description:r.members.description.value}:{},...o?{scalarType:o}:{},extensions:{}}});return{name:e.members.table_name.value,elements:n,native:e.members.columns.items}}function Aie(e,t){if(!["json","yaml"].includes(t.format))throw new U("TABLESPEC_FORMAT","Expected json or yaml");let n=$ie(e,t.format),r=Iie(n),i={profile:"tablespec-table-1",root:n,originalSource:e,originalFormat:t.format},s={umf:"0.1.0",id:t.id,vocabularies:{[wS]:{version:"0.1.0"}},extensions:{[wS]:i},modules:[{id:"table",namespace:r.name,elements:r.elements}]};if(!DS(s).valid)throw new U("TABLESPEC_DOCUMENT","Invalid UMF representation");return s}function DS(e){return We(e,new nt().register(n3e))}function r3e(e){if(!DS(e).valid||e.vocabularies[wS]?.version!=="0.1.0")throw new U("TABLESPEC_DOCUMENT","Expected a valid pinned TableSpec document");let t=e.extensions?.[wS];if(!t)throw new U("TABLESPEC_PAYLOAD","Missing TableSpec source");return Ae(t)}function yF(e){let t=e.kind==="object"?["kind","members"]:e.kind==="array"?["kind","items"]:e.kind==="null"?["kind"]:["kind","value"];if(Object.keys(e).some((n)=>!t.includes(n)))throw new U("TABLESPEC_ENCODING","Unknown tree encoding fields retained; export blocked");if(e.kind==="object")Object.values(e.members).forEach(yF);if(e.kind==="array")e.items.forEach(yF)}function i3e(e){let t=r3e(e);if(Object.keys(t).some((i)=>!["profile","root","originalSource","originalFormat","splitFiles"].includes(i)))throw new U("TABLESPEC_ENCODING","Unknown source encoding fields retained; export blocked");yF(t.root);let n=Iie(t.root),r=e.modules.find((i)=>i.id==="table");if(!r||r.namespace!==n.name||r.elements.length!==n.elements.length||n.elements.some((i,s)=>{let o=r.elements[s];return!o||["id","name","description","scalarType"].some((a)=>o[a]!==i[a])}))throw new U("TABLESPEC_METADATA","Native source and core column metadata disagree; synchronize edits explicitly");return t}function Rie(e){let t=i3e(e);if(t.splitFiles)throw new U("TABLESPEC_SPLIT","Use exportTableSpecBundle to preserve split-file semantics");return Be($ie(t.originalSource,t.originalFormat))===Be(t.root)?t.originalSource:Be(t.root)+` -`}var jie={id:"umf.linkml",version:"0.1.0",coreVersion:"0.1.0",description:"LinkML source schemas with explicit metamodel selection and exact native preservation",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:linkml:0.1.0",type:"object",properties:{profile:{const:"linkml-json-yaml"},metamodelVersion:{type:"string",minLength:1},root:{$ref:"#/$defs/node"},originalSource:{type:"string",maxLength:4000000},originalFormat:{enum:["json","yaml"]}},required:["profile","metamodelVersion","root","originalSource","originalFormat"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-024; source is authoritative, independently of native loader normalization or schema diagnostics",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"LinkML",version:"linkml-model 1.11.0 commit 051e945bb8d64ffd60639c666615ace88d561e2f; native loader runtime 1.11.0rc2",subset:"JSON/YAML schema source, complete pinned metamodel JSON Schema, copied metadata edits, explicit supplied import graph, document-local class-slot membership and 29-field scalar induction; explicit import merge modes; no native retrieval, induced model, instance validation or generators"},evidence:["tests/linkml/linkml.test.ts","fixtures/linkml/oracle-results.json","fixtures/linkml/browser-results.json","tests/linkml/metamodel.test.ts","fixtures/linkml/metamodel/oracle-results.json","tests/linkml/imports.test.ts","fixtures/linkml/imports/oracle-results.json","fixtures/linkml/imports/browser-results.json","tests/linkml/class-slots.test.ts","fixtures/linkml/class-slots/oracle-results.json","fixtures/linkml/class-slots/browser-results.json","tests/linkml/slot-values.test.ts","fixtures/linkml/slot-values/oracle-results.json","fixtures/linkml/slot-values/browser-results.json","tests/linkml/slot-corpus.test.ts","fixtures/linkml/slot-corpus/oracle-results.json","fixtures/linkml/slot-corpus/browser-results.json","tests/linkml/merge.test.ts","fixtures/linkml/merge/oracle-results.json","fixtures/linkml/merge/browser-results.json","tests/linkml/metamodel-merge.test.ts","fixtures/linkml/metamodel-merge/oracle-results.json","fixtures/linkml/metamodel-merge/browser-results.json"]}};var zie=Ar(bF(),1);var Jie={$defs:{AliasPredicateEnum:{description:"permissible values for the relationship between an element and an alias",enum:["EXACT_SYNONYM","RELATED_SYNONYM","BROAD_SYNONYM","NARROW_SYNONYM"],title:"AliasPredicateEnum",type:"string"},AltDescription:{additionalProperties:!1,description:"an attributed description",properties:{description:{description:"text of an attributed description",type:"string"},source:{description:"the source of an attributed description",type:"string"}},required:["source","description"],title:"AltDescription",type:"object"},AltDescription__identifier_optional:{additionalProperties:!1,description:"an attributed description",properties:{description:{description:"text of an attributed description",type:"string"},source:{description:"the source of an attributed description",type:"string"}},required:["description"],title:"AltDescription",type:"object"},Annotatable:{additionalProperties:!1,description:"mixin for classes that support annotations",properties:{annotations:{additionalProperties:{anyOf:[{$ref:"#/$defs/Annotation__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a collection of tag/text tuples with the semantics of OWL Annotation",type:["object","null"]}},title:"Annotatable",type:"object"},Annotation:{additionalProperties:!1,description:"a tag/value pair with the semantics of OWL Annotation",properties:{annotations:{additionalProperties:{anyOf:[{$ref:"#/$defs/Annotation__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a collection of tag/text tuples with the semantics of OWL Annotation",type:["object","null"]},extensions:{additionalProperties:{anyOf:[{$ref:"#/$defs/Extension__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a tag/text tuple attached to an arbitrary element",type:["object","null"]},tag:{description:"a tag associated with an extension",type:"string"},value:{$ref:"#/$defs/AnyValue",description:"the actual annotation"}},required:["tag","value"],title:"Annotation",type:"object"},Annotation__identifier_optional:{additionalProperties:!1,description:"a tag/value pair with the semantics of OWL Annotation",properties:{annotations:{additionalProperties:{anyOf:[{$ref:"#/$defs/Annotation__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a collection of tag/text tuples with the semantics of OWL Annotation",type:["object","null"]},extensions:{additionalProperties:{anyOf:[{$ref:"#/$defs/Extension__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a tag/text tuple attached to an arbitrary element",type:["object","null"]},tag:{description:"a tag associated with an extension",type:"string"},value:{$ref:"#/$defs/AnyValue",description:"the actual annotation"}},required:["value"],title:"Annotation",type:"object"},AnonymousClassExpression:{additionalProperties:!1,description:"",properties:{aliases:{description:"Alternate names/labels for the element. These do not alter the semantics of the schema, but may be useful to support search and alignment.",items:{type:"string"},type:["array","null"]},all_of:{description:"holds if all of the expressions hold",items:{$ref:"#/$defs/AnonymousClassExpression"},type:["array","null"]},alt_descriptions:{additionalProperties:{anyOf:[{$ref:"#/$defs/AltDescription__identifier_optional"},{description:"text of an attributed description",type:"string"}]},description:"A sourced alternative description for an element",type:["object","null"]},annotations:{additionalProperties:{anyOf:[{$ref:"#/$defs/Annotation__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a collection of tag/text tuples with the semantics of OWL Annotation",type:["object","null"]},any_of:{description:"holds if at least one of the expressions hold",items:{$ref:"#/$defs/AnonymousClassExpression"},type:["array","null"]},broad_mappings:{description:"A list of terms from different schemas or terminology systems that have broader meaning.",items:{type:"string"},type:["array","null"]},categories:{description:"Controlled terms used to categorize an element.",items:{type:"string"},type:["array","null"]},close_mappings:{description:"A list of terms from different schemas or terminology systems that have close meaning.",items:{type:"string"},type:["array","null"]},comments:{description:"notes and comments about an element intended primarily for external consumption",items:{type:"string"},type:["array","null"]},contributors:{description:"agent that contributed to the element",items:{type:"string"},type:["array","null"]},created_by:{description:"agent that created the element",type:["string","null"]},created_on:{description:"time at which the element was created",format:"date-time",type:["string","null"]},deprecated:{description:"Description of why and when this element will no longer be used",type:["string","null"]},deprecated_element_has_exact_replacement:{description:"When an element is deprecated, it can be automatically replaced by this uri or curie",type:["string","null"]},deprecated_element_has_possible_replacement:{description:"When an element is deprecated, it can be potentially replaced by this uri or curie",type:["string","null"]},description:{description:"a textual description of the element's purpose and use",type:["string","null"]},exact_mappings:{description:"A list of terms from different schemas or terminology systems that have identical meaning.",items:{type:"string"},type:["array","null"]},exactly_one_of:{description:"holds if only one of the expressions hold",items:{$ref:"#/$defs/AnonymousClassExpression"},type:["array","null"]},examples:{description:"example usages of an element",items:{$ref:"#/$defs/Example"},type:["array","null"]},extensions:{additionalProperties:{anyOf:[{$ref:"#/$defs/Extension__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a tag/text tuple attached to an arbitrary element",type:["object","null"]},from_schema:{description:"id of the schema that defined the element",format:"uri",type:["string","null"]},imported_from:{description:"the imports entry that this element was derived from. Empty means primary source",type:["string","null"]},in_language:{description:"the primary language used in the sources",type:["string","null"]},in_subset:{description:"used to indicate membership of a term in a defined subset of terms used for a particular domain or application.",items:{type:"string"},type:["array","null"]},is_a:{description:"A primary parent class or slot from which inheritable metaslots are propagated from. While multiple inheritance is not allowed, mixins can be provided effectively providing the same thing. The semantics are the same when translated to formalisms that allow MI (e.g. RDFS/OWL). When translating to a SI framework (e.g. java classes, python classes) then is a is used. When translating a framework without polymorphism (e.g. json-schema, solr document schema) then is a and mixins are recursively unfolded",type:["string","null"]},keywords:{description:"Keywords or tags used to describe the element",items:{type:"string"},type:["array","null"]},last_updated_on:{description:"time at which the element was last updated",format:"date-time",type:["string","null"]},mappings:{description:"A list of terms from different schemas or terminology systems that have comparable meaning. These may include terms that are precisely equivalent, broader or narrower in meaning, or otherwise semantically related but not equivalent from a strict ontological perspective.",items:{type:"string"},type:["array","null"]},modified_by:{description:"agent that modified the element",type:["string","null"]},narrow_mappings:{description:"A list of terms from different schemas or terminology systems that have narrower meaning.",items:{type:"string"},type:["array","null"]},none_of:{description:"holds if none of the expressions hold",items:{$ref:"#/$defs/AnonymousClassExpression"},type:["array","null"]},notes:{description:"editorial notes about an element intended primarily for internal consumption",items:{type:"string"},type:["array","null"]},rank:{description:"the relative order in which the element occurs, lower values are given precedence",type:["integer","null"]},related_mappings:{description:"A list of terms from different schemas or terminology systems that have related meaning.",items:{type:"string"},type:["array","null"]},see_also:{description:"A list of related entities or URLs that may be of relevance",items:{type:"string"},type:["array","null"]},slot_conditions:{additionalProperties:{anyOf:[{$ref:"#/$defs/SlotDefinition__identifier_optional"},{type:"null"}]},description:"expresses constraints on a group of slots for a class expression",type:["object","null"]},source:{description:"A related resource from which the element is derived.",type:["string","null"]},status:{description:"status of the element",type:["string","null"]},structured_aliases:{description:"A list of structured_alias objects, used to provide aliases in conjunction with additional metadata.",items:{$ref:"#/$defs/StructuredAlias"},type:["array","null"]},title:{description:"A concise human-readable display label for the element. The title should mirror the name, and should use ordinary textual punctuation.",type:["string","null"]},todos:{description:"Outstanding issues that needs resolution",items:{type:"string"},type:["array","null"]}},title:"AnonymousClassExpression",type:"object"},AnonymousEnumExpression:{additionalProperties:!1,description:"An enum_expression that is not named",properties:{code_set:{description:"the identifier of an enumeration code set.",type:["string","null"]},code_set_tag:{description:"the version tag of the enumeration code set",type:["string","null"]},code_set_version:{description:"the version identifier of the enumeration code set",type:["string","null"]},concepts:{description:"A list of identifiers that are used to construct a set of permissible values",items:{type:"string"},type:["array","null"]},include:{description:"An enum expression that yields a list of permissible values that are to be included, after subtracting the minus set",items:{$ref:"#/$defs/AnonymousEnumExpression"},type:["array","null"]},inherits:{description:"An enum definition that is used as the basis to create a new enum",items:{type:"string"},type:["array","null"]},matches:{anyOf:[{$ref:"#/$defs/MatchQuery"},{type:"null"}],description:"Specifies a match query that is used to calculate the list of permissible values"},minus:{description:"An enum expression that yields a list of permissible values that are to be subtracted from the enum",items:{$ref:"#/$defs/AnonymousEnumExpression"},type:["array","null"]},permissible_values:{additionalProperties:{anyOf:[{$ref:"#/$defs/PermissibleValue__identifier_optional"},{type:"null"}]},description:"A list of possible values for a slot range",type:["object","null"]},pv_formula:{$ref:"#/$defs/PvFormulaOptions",description:"Defines the specific formula to be used to generate the permissible values."},reachable_from:{anyOf:[{$ref:"#/$defs/ReachabilityQuery"},{type:"null"}],description:"Specifies a query for obtaining a list of permissible values based on graph reachability"}},title:"AnonymousEnumExpression",type:"object"},AnonymousExpression:{additionalProperties:!1,description:"An abstract parent class for any nested expression",properties:{aliases:{description:"Alternate names/labels for the element. These do not alter the semantics of the schema, but may be useful to support search and alignment.",items:{type:"string"},type:["array","null"]},alt_descriptions:{additionalProperties:{anyOf:[{$ref:"#/$defs/AltDescription__identifier_optional"},{description:"text of an attributed description",type:"string"}]},description:"A sourced alternative description for an element",type:["object","null"]},annotations:{additionalProperties:{anyOf:[{$ref:"#/$defs/Annotation__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a collection of tag/text tuples with the semantics of OWL Annotation",type:["object","null"]},broad_mappings:{description:"A list of terms from different schemas or terminology systems that have broader meaning.",items:{type:"string"},type:["array","null"]},categories:{description:"Controlled terms used to categorize an element.",items:{type:"string"},type:["array","null"]},close_mappings:{description:"A list of terms from different schemas or terminology systems that have close meaning.",items:{type:"string"},type:["array","null"]},comments:{description:"notes and comments about an element intended primarily for external consumption",items:{type:"string"},type:["array","null"]},contributors:{description:"agent that contributed to the element",items:{type:"string"},type:["array","null"]},created_by:{description:"agent that created the element",type:["string","null"]},created_on:{description:"time at which the element was created",format:"date-time",type:["string","null"]},deprecated:{description:"Description of why and when this element will no longer be used",type:["string","null"]},deprecated_element_has_exact_replacement:{description:"When an element is deprecated, it can be automatically replaced by this uri or curie",type:["string","null"]},deprecated_element_has_possible_replacement:{description:"When an element is deprecated, it can be potentially replaced by this uri or curie",type:["string","null"]},description:{description:"a textual description of the element's purpose and use",type:["string","null"]},exact_mappings:{description:"A list of terms from different schemas or terminology systems that have identical meaning.",items:{type:"string"},type:["array","null"]},examples:{description:"example usages of an element",items:{$ref:"#/$defs/Example"},type:["array","null"]},extensions:{additionalProperties:{anyOf:[{$ref:"#/$defs/Extension__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a tag/text tuple attached to an arbitrary element",type:["object","null"]},from_schema:{description:"id of the schema that defined the element",format:"uri",type:["string","null"]},imported_from:{description:"the imports entry that this element was derived from. Empty means primary source",type:["string","null"]},in_language:{description:"the primary language used in the sources",type:["string","null"]},in_subset:{description:"used to indicate membership of a term in a defined subset of terms used for a particular domain or application.",items:{type:"string"},type:["array","null"]},keywords:{description:"Keywords or tags used to describe the element",items:{type:"string"},type:["array","null"]},last_updated_on:{description:"time at which the element was last updated",format:"date-time",type:["string","null"]},mappings:{description:"A list of terms from different schemas or terminology systems that have comparable meaning. These may include terms that are precisely equivalent, broader or narrower in meaning, or otherwise semantically related but not equivalent from a strict ontological perspective.",items:{type:"string"},type:["array","null"]},modified_by:{description:"agent that modified the element",type:["string","null"]},narrow_mappings:{description:"A list of terms from different schemas or terminology systems that have narrower meaning.",items:{type:"string"},type:["array","null"]},notes:{description:"editorial notes about an element intended primarily for internal consumption",items:{type:"string"},type:["array","null"]},rank:{description:"the relative order in which the element occurs, lower values are given precedence",type:["integer","null"]},related_mappings:{description:"A list of terms from different schemas or terminology systems that have related meaning.",items:{type:"string"},type:["array","null"]},see_also:{description:"A list of related entities or URLs that may be of relevance",items:{type:"string"},type:["array","null"]},source:{description:"A related resource from which the element is derived.",type:["string","null"]},status:{description:"status of the element",type:["string","null"]},structured_aliases:{description:"A list of structured_alias objects, used to provide aliases in conjunction with additional metadata.",items:{$ref:"#/$defs/StructuredAlias"},type:["array","null"]},title:{description:"A concise human-readable display label for the element. The title should mirror the name, and should use ordinary textual punctuation.",type:["string","null"]},todos:{description:"Outstanding issues that needs resolution",items:{type:"string"},type:["array","null"]}},title:"AnonymousExpression",type:"object"},AnonymousSlotExpression:{additionalProperties:!1,description:"",properties:{aliases:{description:"Alternate names/labels for the element. These do not alter the semantics of the schema, but may be useful to support search and alignment.",items:{type:"string"},type:["array","null"]},all_members:{anyOf:[{$ref:"#/$defs/AnonymousSlotExpression"},{type:"null"}],description:"the value of the slot is multivalued with all members satisfying the condition"},all_of:{description:"holds if all of the expressions hold",items:{$ref:"#/$defs/AnonymousSlotExpression"},type:["array","null"]},alt_descriptions:{additionalProperties:{anyOf:[{$ref:"#/$defs/AltDescription__identifier_optional"},{description:"text of an attributed description",type:"string"}]},description:"A sourced alternative description for an element",type:["object","null"]},annotations:{additionalProperties:{anyOf:[{$ref:"#/$defs/Annotation__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a collection of tag/text tuples with the semantics of OWL Annotation",type:["object","null"]},any_of:{description:"holds if at least one of the expressions hold",items:{$ref:"#/$defs/AnonymousSlotExpression"},type:["array","null"]},array:{anyOf:[{$ref:"#/$defs/ArrayExpression"},{type:"null"}],description:"coerces the value of the slot into an array and defines the dimensions of that array"},bindings:{description:`A collection of enum bindings that specify how a slot can be bound to a permissible value from an enumeration. +`}}};var rS=Qte;var wj={id:"umf.typespec",version:"0.1.0",coreVersion:"0.1.0",description:"TypeSpec source bundles with pinned syntax and supplied-file compilation",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:typespec:0.1.0",type:"object",required:["profile","entrypoint","files"],properties:{profile:{const:"typespec-1.16.0-sources"},entrypoint:{type:"string",minLength:1},files:{type:"object",minProperties:1,propertyNames:{type:"string",minLength:1},additionalProperties:{type:"string"}},libraries:{type:"object",propertyNames:{type:"string",minLength:1},additionalProperties:{type:"string",minLength:1}}}},scopes:["element"],semantics:"CONTRACT-013. Exact source files and explicit entrypoint; compiler validity and downstream projection fidelity are separate.",capabilities:{validation:"semantic",directions:["import","export"],native:{system:"TypeSpec",version:"1.16.0",subset:"Supplied .tsp sources with pinned compiler/standard library and eleven explicitly selected official library versions; library-owned configuration retained; separate pinned JSON Schema emission API; no arbitrary project JavaScript or lossless projection claim"},evidence:["tests/typespec/native.test.ts","fixtures/typespec/compiler-oracle-results.json","spec/extensions/typespec/standard-manifest.json","tests/typespec/semantic.test.ts","fixtures/typespec/semantic-oracle-results.json","tests/typespec/corpus.test.ts","fixtures/typespec/upstream/manifest.json","fixtures/typespec/corpus-results.json","fixtures/typespec/corpus-oracle-results.json","tests/typespec/libraries.test.ts","spec/extensions/typespec/libraries-manifest.json","fixtures/typespec/library-corpus-results.json","fixtures/typespec/library-corpus-oracle-results.json","tests/typespec/all-libraries.test.ts","fixtures/typespec/all-library-corpus-results.json","fixtures/typespec/all-library-corpus-oracle-results.json","tests/typespec/emission.test.ts","fixtures/typespec/emission-oracle-results.json","fixtures/typespec/emission-json-oracle-results.json","fixtures/typespec/emission/numeric.tsp","fixtures/typespec/emission/numeric-oracle-results.json","tests/typespec/projection.test.ts","fixtures/typespec/emission/projection-oracle-results.json"]}};ka();await st();await st();await st();var c2e=new Set(["modelPropertyReference","enumMemberReference"]);var fCt=new Set([...c2e,"booleanLiteral","stringTemplate","stringLiteral","numericLiteral","scalarInstantiation","enumMember","enumMembers","intrinsic"]);await st();await st();var wCt=Symbol("placeholder"),DCt=Symbol("ObjectBuilder.set");Nn();bo();await st();await st();FR();jR();await st();var ene="umf.typespec",x2e=wj,w2e=mt().compile(wj.schema);function D2e(e){let t=e,n=[];for(let i of Object.keys(t))if(!["profile","entrypoint","files","libraries"].includes(i))n.push({code:"TYPESPEC_REPRESENTATION",path:"/"+$e(i),severity:"warning",message:"Unknown source representation field cannot be emitted natively"});for(let[i,s]of Object.entries(t.libraries??{}))if(!Object.hasOwn(rS,i)||rS[i].version!==s)n.push({code:"TYPESPEC_LIBRARY_UNAVAILABLE",path:"/libraries/"+$e(i),severity:"warning",message:"Unregistered library selection retained: "+i+"@"+s});if(!Object.hasOwn(t.files,t.entrypoint))n.push({code:"TYPESPEC_ENTRYPOINT",path:"/entrypoint",severity:"error",message:"Entrypoint must name a supplied file"});let r=0;for(let[i,s]of Object.entries(t.files)){if(!/^(?:[A-Za-z0-9_.-]+\/)*[A-Za-z0-9_.-]+\.tsp$/.test(i)||i.split("/").some((o)=>o==="."||o==="..")){n.push({code:"TYPESPEC_PATH",path:"/files/"+$e(i),severity:"error",message:"Source paths must be relative .tsp paths without traversal"});continue}if(r+=s.length,r>Zt.maxTextLength){n.push({code:"LIMIT",path:"/files",severity:"error",message:"Source bundle exceeds text limit"});break}try{for(let o of Ld(s,{comments:!0,docs:!0}).parseDiagnostics)n.push({code:"TYPESPEC_"+o.code,path:"/files/"+$e(i),severity:o.severity,message:o.message})}catch(o){n.push({code:"TYPESPEC_PARSE",path:"/files/"+$e(i),severity:"error",message:String(o)})}}return n.push({code:"TYPESPEC_COMPILATION_REQUIRED",path:"",severity:"warning",message:"Syntax preservation does not establish compiler validity; call compileTypeSpecDocument with supplied imports"}),n}function T2e(){return new nt().register(x2e,D2e)}function tne(e){return We(e,T2e())}function S2e(e){let t=tne(e);if(!t.valid)throw new U("TYPESPEC_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[ene];if(e.vocabularies[ene]?.version!=="0.1.0"||!w2e(n))throw new U("TYPESPEC_PAYLOAD","Missing TypeSpec source bundle");return Ae(n)}function nne(e){let t=S2e(e);if(tne(e).diagnostics.some((n)=>n.code==="TYPESPEC_REPRESENTATION"))throw new U("TYPESPEC_REPRESENTATION","Native export would discard unknown content");return{entrypoint:t.entrypoint,files:t.files,...t.libraries?{libraries:t.libraries}:{}}}function rne(e){let t=e,n=[];for(let i of Object.keys(t))if(!["profile","files"].includes(i))n.push({code:"SMITHY_REPRESENTATION",path:"/"+$e(i),severity:"warning",message:"Unknown source representation field has no native destination"});let r=0;for(let[i,s]of Object.entries(t.files)){if(!/^(?:[A-Za-z0-9_.-]+\/)*[A-Za-z0-9_.-]+\.(?:smithy|json)$/.test(i)||i.split("/").some((o)=>o==="."||o===".."))n.push({code:"SMITHY_SOURCE_PATH",path:"/files/"+$e(i),severity:"error",message:"Sources require relative .smithy/.json paths without traversal"});r+=s.length}if(r>Zt.maxTextLength)n.push({code:"LIMIT",path:"/files",severity:"error",message:"Source bundle exceeds text limit"});return n.push({code:"SMITHY_SOURCE_UNVALIDATED",path:"/files",severity:"warning",message:"Source text is preserved without browser parsing or assembly; syntax and semantic validity require native compilation"}),n}var ine={id:"umf.smithy",version:"0.1.0",coreVersion:"0.1.0",description:"Smithy JSON AST and exact supplied IDL/JSON source bundles with explicit validation limits",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:smithy:0.1.0",$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}},oneOf:[{type:"object",required:["profile","root"],properties:{profile:{const:"smithy-json-ast"},root:{$ref:"#/$defs/node"},dependencies:{type:"array",items:{type:"object",required:["id","root"],properties:{id:{type:"string",minLength:1},root:{$ref:"#/$defs/node"}}}}}},{type:"object",required:["profile","files"],properties:{profile:{const:"smithy-idl-sources"},files:{type:"object",minProperties:1,additionalProperties:{type:"string"}}}}]},scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Smithy JSON AST",version:"2.0; external smithy-model 1.73.0",subset:"Exact JSON AST roots/dependencies and supplied IDL/JSON source files. Browser checks AST structure or source archive shape only; parsing, assembly, selectors, trait semantics and projections remain separately qualified. Optional pinned JavaScript assembly is explicit through a trusted backend; known reflection limitations and source normalization are reported."},evidence:["tests/smithy/native.test.ts","fixtures/smithy/oracle-results.json","tests/smithy/bundle.test.ts","fixtures/smithy/bundles/oracle-results.json","tests/smithy/sources.test.ts","fixtures/smithy/idl/oracle-results.json","tests/smithy/assembly.test.ts","fixtures/smithy/assembly-oracle-results.json"]},semantics:"CONTRACT-014. Exact native JSON AST retention and structural inspection; browser validity is not native semantic validity. Traits, references, mixins and model assembly require separate evidence."};var sne={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:smithy:native-structure:0.1.0",type:"object",required:["smithy"],properties:{smithy:{type:"string"},metadata:{type:"object"},shapes:{type:"object",propertyNames:{type:"string",pattern:"^[A-Za-z_][A-Za-z_0-9]*(\\.[A-Za-z_][A-Za-z_0-9]*)*#[A-Za-z_][A-Za-z_0-9]*(\\$[A-Za-z_][A-Za-z_0-9]*)?$"},additionalProperties:{$ref:"#/$defs/shape"}}},$defs:{reference:{type:"object",required:["target"],properties:{target:{type:"string",pattern:"^[A-Za-z_][A-Za-z_0-9]*(\\.[A-Za-z_][A-Za-z_0-9]*)*#[A-Za-z_][A-Za-z_0-9]*(\\$[A-Za-z_][A-Za-z_0-9]*)?$"}}},member:{type:"object",required:["target"],properties:{target:{type:"string",pattern:"^[A-Za-z_][A-Za-z_0-9]*(\\.[A-Za-z_][A-Za-z_0-9]*)*#[A-Za-z_][A-Za-z_0-9]*(\\$[A-Za-z_][A-Za-z_0-9]*)?$"},traits:{type:"object"}}},shape:{type:"object",required:["type"],properties:{type:{type:"string"},traits:{type:"object"},mixins:{type:"array",items:{$ref:"#/$defs/reference"}}},allOf:[{if:{properties:{type:{enum:["list"]}}},then:{properties:{member:{$ref:"#/$defs/member"}},anyOf:[{required:["member"]},{required:["mixins"],properties:{mixins:{minItems:1}}}]}},{if:{properties:{type:{enum:["map"]}}},then:{properties:{key:{$ref:"#/$defs/member"},value:{$ref:"#/$defs/member"}},anyOf:[{required:["key","value"]},{required:["mixins"],properties:{mixins:{minItems:1}}}]}},{if:{properties:{type:{enum:["structure","union","enum","intEnum"]}}},then:{properties:{members:{type:"object",additionalProperties:{$ref:"#/$defs/member"}}},required:[]}},{if:{properties:{type:{enum:["service"]}}},then:{properties:{version:{type:"string"},operations:{type:"array",items:{$ref:"#/$defs/reference"}},resources:{type:"array",items:{$ref:"#/$defs/reference"}},errors:{type:"array",items:{$ref:"#/$defs/reference"}},rename:{type:"object",additionalProperties:{type:"string"}}},required:[]}},{if:{properties:{type:{enum:["operation"]}}},then:{properties:{input:{$ref:"#/$defs/reference"},output:{$ref:"#/$defs/reference"},errors:{type:"array",items:{$ref:"#/$defs/reference"}}},required:[]}},{if:{properties:{type:{enum:["resource"]}}},then:{properties:{operations:{type:"array",items:{$ref:"#/$defs/reference"}},collectionOperations:{type:"array",items:{$ref:"#/$defs/reference"}},resources:{type:"array",items:{$ref:"#/$defs/reference"}},create:{$ref:"#/$defs/reference"},put:{$ref:"#/$defs/reference"},read:{$ref:"#/$defs/reference"},update:{$ref:"#/$defs/reference"},delete:{$ref:"#/$defs/reference"},list:{$ref:"#/$defs/reference"},identifiers:{type:"object",additionalProperties:{$ref:"#/$defs/reference"}},properties:{type:"object",additionalProperties:{$ref:"#/$defs/reference"}}},required:[]}}]}}};var kv="umf.smithy",N2e=ine,one=mt(!1).compile(sne),O2e=new Set("blob boolean document string byte short integer long float double bigInteger bigDecimal timestamp list map structure union enum intEnum service resource operation apply".split(" "));function P2e(e){if(e.profile==="smithy-idl-sources")return rne(e);let t=e,n=[],r=(o,a,l,c="warning")=>n.push({code:o,path:a,message:l,severity:c});for(let o of Object.keys(t))if(!["profile","root","dependencies"].includes(o))r("SMITHY_REPRESENTATION","/"+$e(o),"Unknown representation field cannot be exported");function i(o,a){let l=o.kind==="null"?["kind"]:o.kind==="object"?["kind","members"]:o.kind==="array"?["kind","items"]:["kind","value"];for(let c of Object.keys(o))if(!l.includes(c))r("SMITHY_REPRESENTATION",a+"/"+$e(c),"Unknown tagged-tree field cannot be exported");if(o.kind==="object")for(let[c,u]of Object.entries(o.members))i(u,a+"/members/"+$e(c));if(o.kind==="array")o.items.forEach((c,u)=>i(c,a+"/items/"+u))}let s=new Set;for(let[o,a]of(t.dependencies??[]).entries()){if(s.has(a.id))r("SMITHY_DEPENDENCY_ID","/dependencies/"+o+"/id","Duplicate dependency ID","error");s.add(a.id);for(let l of Object.keys(a))if(!["id","root"].includes(l))r("SMITHY_REPRESENTATION","/dependencies/"+o+"/"+$e(l),"Unknown dependency representation field cannot be exported")}for(let{root:o,path:a}of[{root:t.root,path:"/root"},...(t.dependencies??[]).map((l,c)=>({root:l.root,path:"/dependencies/"+c+"/root"}))]){i(o,a);let l=JSON.parse(Be(o));if(!one(l))r("SMITHY_STRUCTURE",a,JSON.stringify(one.errors),"error");if(o.kind!=="object")continue;let c=o.members;if(c.smithy?.kind==="string"&&!["2","2.0"].includes(c.smithy.value))r("SMITHY_VERSION",a+"/smithy","Uninterpreted Smithy version retained");for(let u of Object.keys(c))if(!["smithy","shapes","metadata"].includes(u))r("SMITHY_NATIVE_FIELD",a+"/"+$e(u),"Unknown native content retained");if(c.shapes?.kind==="object"){for(let[u,p]of Object.entries(c.shapes.members))if(p.kind==="object"){let d=p.members.type;if(d?.kind==="string"&&!O2e.has(d.value))r("SMITHY_SHAPE_TYPE",a+"/shapes/"+$e(u)+"/type","Unknown shape type retained")}}}return r("SMITHY_ASSEMBLY_REQUIRED","/root","Browser checks AST structure only. Native assembly, references, mixins, trait selectors and semantic validation require a separate Smithy model oracle"),n}function $2e(){return new nt().register(N2e,P2e)}function Nv(e){return We(e,$2e())}function I2e(e){let t=Nv(e);if(!t.valid)throw new U("SMITHY_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[kv];if(!n||e.vocabularies[kv]?.version!=="0.1.0")throw new U("SMITHY_PAYLOAD","Missing Smithy payload");if(n.profile!=="smithy-json-ast")throw new U("SMITHY_PROFILE","This operation requires a JSON AST profile");return Ae(n)}function A2e(e){let t=I2e(e);if(Nv(e).diagnostics.some((n)=>n.code==="SMITHY_REPRESENTATION"))throw new U("SMITHY_REPRESENTATION","Unknown representation content cannot be discarded");return t}function ane(e){let t=A2e(e);if(t.dependencies?.length)throw new U("SMITHY_DEPENDENCIES_REQUIRED","Use exportSmithyBundle to retain supplied dependencies");return Be(t.root)+` +`}function R2e(e){let t=Nv(e);if(!t.valid)throw new U("SMITHY_SOURCES",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[kv];if(n?.profile!=="smithy-idl-sources"||e.vocabularies[kv]?.version!=="0.1.0")throw new U("SMITHY_PROFILE","This operation requires supplied source files");return Ae(n)}function lne(e){let t=R2e(e);if(Nv(e).diagnostics.some((n)=>n.code==="SMITHY_REPRESENTATION"))throw new U("SMITHY_REPRESENTATION","Native source export would discard unknown content");return{files:t.files}}var cne={id:"umf.arrow.ipc",version:"0.1.0",coreVersion:"0.1.0",description:"Exact bounded IPC source bytes independent of native decoder support",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:arrow-ipc:0.1.0",title:"Arrow IPC source capture; structural validity is not native validity",type:"object",required:["profile","encoding","bytes"],properties:{profile:{const:"arrow-ipc-source"},encoding:{const:"hex"},bytes:{type:"string",maxLength:2000000,pattern:"^(?:[0-9a-f]{2})*$"}},additionalProperties:!0},semantics:"CONTRACT-016. Archive capture accepts uninterpreted or invalid input; it makes no native format validity claim. Schema observations are derived separately and never replace source.",scopes:["element"],capabilities:{validation:"structural",directions:["import","export"],native:{system:"Apache Arrow IPC source bytes",version:"Capture profile 0.1.0; optional observations apache-arrow 21.2.0",subset:"Exact original bytes up to 1000000 bytes, including unrecognized and invalid content. No semantic edits, complete framing validation or decoded data model."},evidence:["tests/arrow/capture.test.ts","fixtures/arrow/ipc-inputs/manifest.json","fixtures/arrow/upstream/results.json","fixtures/arrow/upstream/oracle-results.json"]}};var une="umf.arrow.ipc";var F2e=cne;function C2e(){return new nt().register(F2e)}function M2e(e){let t=We(e,C2e());return{...t,complete:!1,diagnostics:[...t.diagnostics,{code:"ARROW_IPC_UNINTERPRETED",path:"",severity:"warning",message:"Captured bytes are authoritative; complete IPC framing, native schema and data validity are unverified"}]}}function pne(e){if(!M2e(e).valid)throw new U("ARROW_IPC_CAPTURE","Invalid IPC capture envelope");let n=e.modules.find((s)=>s.id==="ipc")?.elements.find((s)=>s.id==="source")?.extensions[une];if(e.vocabularies[une]?.version!=="0.1.0"||!n||typeof n!=="object"||Array.isArray(n))throw new U("ARROW_IPC_CAPTURE","Expected pinned IPC capture");if(Object.keys(n).some((s)=>!["profile","encoding","bytes"].includes(s)))throw new U("ARROW_IPC_REPRESENTATION","Unknown capture representation fields cannot be exported as native bytes");let r=n.bytes,i=new Uint8Array(r.length/2);for(let s=0;s{throw n.push({code:"PARQUET_METADATA_SHAPE",path:l,severity:"error",message:c}),Error(c)},o=(l)=>l.ref?r[l.ref]?.kind==="enum"?"i32":"struct":l.kind==="string"?"binary":l.kind;function a(l,c,u){if(c.ref){let p=r[c.ref];if(!p)s(u,"Unknown IDL reference");if(p.kind==="enum"){if(l.kind!=="i32")s(u,"Expected i32 enumeration");let y=l.value;if(!Object.values(p.values).some((h)=>String(h)===y))n.push({code:"PARQUET_ENUM_UNKNOWN",path:u,severity:"warning",message:"Unknown "+c.ref+" code retained: "+y});return y}if(l.kind!=="struct")return s(u,"Expected struct "+c.ref);let d=Object.create(null),f=new Set,m=[];if(p.kind==="union"&&l.fields.length>1)s(u,"Union has more than one active field");for(let y of l.fields){let h=p.fields.find((b)=>b.id===y.id);if(h&&f.has(y.id))s(u,"Repeated field ID cannot be collapsed into named metadata: "+y.id);if(f.add(y.id),h)d[h.name]=a(y.value,h.type,u+"/"+h.name);else m.push(y),n.push({code:"PARQUET_FIELD_UNKNOWN",path:u,severity:"warning",message:"Unknown field "+y.id+" retained in $unknown"})}for(let y of p.fields)if(y.required&&!f.has(y.id))s(u+"/"+y.name,"Missing required IDL field");if(m.length)d.$unknown=m;return d}if(c.kind==="string"){if(l.kind!=="binary")return s(u,"Expected string wire bytes");try{return i.decode(Uint8Array.from(l.hex.match(/../g)??[],(p)=>Number.parseInt(p,16)))}catch{return s(u,"IDL string is not valid UTF-8")}}if(c.kind==="binary"){if(l.kind!=="binary")return s(u,"Expected binary wire value");return{hex:l.hex}}if(c.kind==="bool"){if(l.kind!=="bool")return s(u,"Expected boolean");return l.value}if(["i8","i16","i32","i64"].includes(c.kind)){if(l.kind!==c.kind)return s(u,"Integer width does not match IDL");return l.value}if(c.kind==="double"){if(l.kind!=="double")return s(u,"Expected double");return{bits:l.bits}}if(c.kind==="list"||c.kind==="set"){if(l.kind!==c.kind)return s(u,"Collection kind does not match IDL");if(l.elementType!==o(c.item))return s(u,"Collection element type does not match IDL");return l.items.map((p,d)=>a(p,c.item,u+"/"+d))}if(c.kind==="map"){if(l.kind!=="map")return s(u,"Expected map");if(l.entries.length&&(l.keyType!==o(c.key)||l.valueType!==o(c.value)))return s(u,"Map element types do not match IDL");return l.entries.map((p,d)=>({key:a(p.key,c.key,u+"/"+d+"/key"),value:a(p.value,c.value,u+"/"+d+"/value")}))}return s(u,"Unsupported IDL descriptor")}return a(e,{ref:t},"")}function yne(e){let t=0,n=0,r=()=>{if(t>=e.length)throw Error("Truncated Compact Protocol value");return e[t++]};function i(u){if(u>e.length-t)throw Error("Binary value exceeds footer region");let p=e.subarray(t,t+u);return t+=u,Array.from(p,(d)=>d.toString(16).padStart(2,"0")).join("")}function s(u){let p=0n;for(let d=0;d=1n<{let p=s(u);return p>>1n^-(p&1n)},a=()=>{let u=s(32);if(u>2147483647n)throw Error("Length exceeds signed int32");return Number(u)},l=(u)=>{let p=[void 0,"bool","bool","i8","i16","i32","i64","double","binary","list","set","map","struct","uuid"][u];if(!p)throw Error("Unknown Compact Protocol wire type "+u);return p};function c(u,p,d=!1){if(p>64||++n>50000)throw Error("Compact Protocol structural limit exceeded");let f=l(u);if(f==="bool"){let h=d?u:r();if(h!==1&&h!==2)throw Error("Invalid boolean encoding");return{kind:f,value:h===1}}if(f==="i8"){let h=r();return{kind:f,value:String(h<128?h:h-256)}}if(f==="i16"||f==="i32"||f==="i64")return{kind:f,value:o(Number(f.slice(1))).toString()};if(f==="double")return{kind:f,bits:i(8)};if(f==="uuid")return{kind:f,hex:i(16)};if(f==="binary")return{kind:f,hex:i(a())};if(f==="list"||f==="set"){let h=r(),b=h&15,g=h>>4===15?a():h>>4,x=l(b);if(g>50000-n)throw Error("Collection exceeds value limit");let v=[];for(let D=0;D50000-n)throw Error("Map exceeds value limit");let g=r(),x=g>>4,v=g&15,D=l(x),T=l(v);for(let N=0;N>4,x=g?y+g:Number(o(16));if(x<-32768||x>32767)throw Error("Field ID exceeds signed int16");y=x,m.push({id:x,value:c(b,p+1,!0)})}return{kind:"struct",fields:m}}return{value:c(12,0),consumedBytes:t}}function hne(e){let t=gne(e),n={source:t.source,status:"blocked",complete:!1,diagnostics:[...t.diagnostics]},r=(o,a)=>n.diagnostics.push({code:o,path:"",severity:"error",message:a});if(!t.footerRegion)return n;if(t.footerRegion.mode==="encrypted")return r("PARQUET_FOOTER_ENCRYPTED","Encrypted footer requires a separate decryption implementation"),n;let i=t.footerRegion,s=Ov(e).subarray(i.offset,i.offset+i.length);try{let{value:o,consumedBytes:a}=yne(s);if(n.status="decoded",n.value=o,n.consumedBytes=a,n.trailingBytes=s.length-a,a!==s.length)n.diagnostics.push({code:"PARQUET_FOOTER_TRAILING",path:"",severity:"warning",message:"Bytes remain after the first struct; source retains them without interpreting signatures or other content"});n.diagnostics.push({code:"PARQUET_FOOTER_SEMANTICS_UNVERIFIED",path:"",severity:"warning",message:"Unknown IDs, duplicates, ordering and exact values are retained; the Parquet IDL and logical schema are not validated"})}catch(o){r("PARQUET_FOOTER_DECODE",o.message)}return n}function bne(e){let t=hne(e),n={source:t.source,status:"blocked",complete:!1,diagnostics:[...t.diagnostics]};if(!t.value)return n;n.wire=t.value;try{n.metadata=mne(t.value,"FileMetaData",n.diagnostics),n.status="mapped",n.diagnostics.push({code:"PARQUET_METADATA_SEMANTICS_UNVERIFIED",path:"",severity:"warning",message:"Known IDL shapes mapped; schema-tree consistency, logical constraints, native reading and safe edits remain unverified"})}catch(r){if(!n.diagnostics.some((i)=>i.code==="PARQUET_METADATA_SHAPE"))n.diagnostics.push({code:"PARQUET_METADATA_SHAPE",path:"",severity:"error",message:r.message})}return n}var vne=["BOOLEAN","INT32","INT64","INT96","FLOAT","DOUBLE","BYTE_ARRAY","FIXED_LEN_BYTE_ARRAY"];function _ne(e){let t=bne(e),n={...t,status:"blocked"};if(t.status!=="mapped")return n;let r=t.metadata,i=r.schema,s=[],o=0,a=(u,p)=>{throw n.diagnostics.push({code:"PARQUET_SCHEMA_STRUCTURE",path:u,severity:"error",message:p}),Error(p)},l=(u,p,d)=>n.diagnostics.push({code:u,path:p,severity:"warning",message:d});function c(u,p,d,f){if(f>64)a("/schema","Schema nesting exceeds 64");if(o>=i.length)a("/schema","Child count exceeds remaining schema elements");let m=o++,y=i[m],h="/schema/"+m,b=m===0,g=y.type!==void 0;if(b){if(g)a(h,"Root must be a group");if(y.repetition_type!==void 0){if(y.repetition_type!=="0")a(h+"/repetition_type","Only absent or legacy REQUIRED root repetition is understood");l("PARQUET_ROOT_REPETITION",h+"/repetition_type","REQUIRED root repetition retained; root contributes no definition/repetition level")}}else{if(!["0","1","2"].includes(y.repetition_type))a(h+"/repetition_type","Non-root node requires known repetition");if(y.repetition_type!=="0")p++;if(y.repetition_type==="2")d++}let x=b?[]:[...u,y.name],v={index:m,name:y.name,path:x,definitionLevel:p,repetitionLevel:d,children:[]};if(g){if(y.num_children!==void 0)a(h,"Primitive cannot also declare children");let D=vne[Number(y.type)];if(!D)a(h+"/type","Unknown physical type cannot supply a physical schema view");if(y.type==="7"&&(y.type_length===void 0||BigInt(y.type_length)<=0n))a(h+"/type_length","Fixed byte arrays require a positive length");s.push({index:m,ordinal:s.length,path:x,physicalType:D,definitionLevel:p,repetitionLevel:d})}else{if(y.num_children===void 0||BigInt(y.num_children)<0n||BigInt(y.num_children)>BigInt(i.length-o))a(h+"/num_children","Group requires a feasible nonnegative child count");let D=new Set;for(let T=0;Tp.code==="PARQUET_SCHEMA_STRUCTURE"))n.diagnostics.push({code:"PARQUET_SCHEMA_STRUCTURE",path:"",severity:"error",message:u.message})}return n}var U2e=["STRING","MAP","MAP_KEY_VALUE","LIST","ENUM","DECIMAL","DATE","TIME_MILLIS","TIME_MICROS","TIMESTAMP_MILLIS","TIMESTAMP_MICROS","UINT_8","UINT_16","UINT_32","UINT_64","INT_8","INT_16","INT_32","INT_64","JSON","BSON","INTERVAL"];function xne(e){let t=_ne(e);if(t.status!=="checked")return t;let n=t.metadata.schema,r=[],i=(s,o,a,l=!1)=>{if(t.diagnostics.push({code:s,path:o,severity:l?"error":"warning",message:a}),l)t.status="blocked"};for(let[s,o]of n.entries()){if(!o.logicalType&&o.converted_type===void 0)continue;let a="/schema/"+s,l=o.logicalType?"logical":"converted",c=o.logicalType&&Object.keys(o.logicalType).filter((g)=>g!=="$unknown")[0],u=c??(l==="converted"?U2e[Number(o.converted_type)]:void 0),p=c?o.logicalType[c]:{};if(!u){r.push({index:s,origin:l,name:"unknown",parameters:o.logicalType??{code:o.converted_type},validation:"uninterpreted"}),i("PARQUET_LOGICAL_UNKNOWN",a,"Unknown logical/converted annotation retained without fallback interpretation");continue}if(l==="converted"){if(/^(U?INT)_/.test(u)){let[g,x]=u.split("_");u="INTEGER",p={bitWidth:x,isSigned:g==="INT"}}else if(u==="DECIMAL")p={...o.precision===void 0?{}:{precision:o.precision},scale:o.scale??"0"};else if(/^(TIME|TIMESTAMP)_/.test(u)){let[g,x]=u.split("_");u=g,p={isAdjustedToUTC:!0,unit:{[x]:{}}}}}let d={index:s,origin:l,name:u,parameters:p,validation:"checked"};r.push(d);let f=(g)=>{d.validation="invalid",i("PARQUET_LOGICAL_CONFLICT",a,g,!0)},m=(g)=>{if(d.validation!=="invalid")d.validation="uninterpreted";i("PARQUET_LOGICAL_UNVERIFIED",a,g)},y=(...g)=>{if(!g.includes(o.type))f(u+" is incompatible with this physical type")},h;if(["STRING","ENUM","JSON","BSON","GEOMETRY","GEOGRAPHY"].includes(u)){if(y("6"),h={STRING:"0",ENUM:"4",JSON:"19",BSON:"20"}[u],u==="GEOMETRY"||u==="GEOGRAPHY")m("Physical carrier checked; CRS, interpolation and WKB semantics remain unverified")}else if(u==="UUID"||u==="FLOAT16"||u==="INTERVAL"){y("7");let g={UUID:"16",FLOAT16:"2",INTERVAL:"12"}[u];if(o.type_length!==g)f(u+" requires byte length "+g);if(u==="INTERVAL")h="21"}else if(u==="DATE")y("1"),h="6";else if(u==="INTEGER"){let g=p.bitWidth;if(!["8","16","32","64"].includes(g))f("Integer bitWidth must be 8, 16, 32 or 64");else y(g==="64"?"2":"1"),h=String((p.isSigned?15:11)+["8","16","32","64"].indexOf(g))}else if(u==="DECIMAL"){y("1","2","6","7"),h="5";let g=p.precision===void 0?0n:BigInt(p.precision),x=BigInt(p.scale);if(g<=0n||x<0n||x>g)f("Decimal precision must be positive and scale between zero and precision");if(o.type==="1"&&g>9n||o.type==="2"&&g>18n)f("Decimal precision exceeds integer physical capacity");if(o.type==="2"&&g<10n)i("PARQUET_DECIMAL_SMALL_INT64",a,"Decimal precision below 10 uses an int64 carrier");if(o.type==="7"){let v=BigInt(o.type_length);if(v>4096n)m("Fixed-decimal capacity check exceeds the 4096-byte exact-arithmetic limit");else{let D=((1n<<8n*v-1n)-1n).toString().length-1;if(g>BigInt(D))f("Decimal precision exceeds fixed-byte physical capacity")}}if(l==="logical"){for(let v of["precision","scale"])if(o[v]!==void 0&&o[v]!==p[v])i("PARQUET_LEGACY_ANNOTATION_CONFLICT",a+"/"+v,"Legacy decimal parameter differs from authoritative logical annotation")}}else if(u==="TIME"||u==="TIMESTAMP"){let g=Object.keys(p.unit).filter((v)=>v!=="$unknown"),x=g[0];if(!x)if(p.unit.$unknown)m("Future temporal unit remains uninterpreted");else f("Temporal unit must select one alternative");else if(!["MILLIS","MICROS","NANOS"].includes(x))m("Future temporal unit remains uninterpreted");else y(u==="TIME"&&x==="MILLIS"?"1":"2"),h=x==="NANOS"?void 0:String((u==="TIME"?7:9)+(x==="MICROS"?1:0))}else if(["LIST","MAP","MAP_KEY_VALUE","VARIANT","FILE"].includes(u)){if(o.type!==void 0)f(u+" requires a group");m("Nested layout and value rules remain unverified"),h={LIST:"3",MAP:"1",MAP_KEY_VALUE:"2"}[u]}else if(u==="UNKNOWN")m("Always-null annotation retained; stored nullness has not been verified");else m("Logical annotation has no implemented rule set");let b=(g)=>g&&typeof g==="object"&&(Array.isArray(g.$unknown)&&g.$unknown.length>0||Object.values(g).some(b));if(b(p))m("Additional logical parameters remain uninterpreted");if(l==="logical"&&h!==void 0){if(o.converted_type===void 0)i("PARQUET_LEGACY_ANNOTATION_ABSENT",a,"Corresponding legacy annotation is absent; source remains unchanged");else if(o.converted_type!==h)i("PARQUET_LEGACY_ANNOTATION_CONFLICT",a,"Legacy annotation conflicts with authoritative logical annotation")}}return t.annotations=r,i("PARQUET_LOGICAL_VALUES_UNVERIFIED","","Annotation checks do not verify values, statistics, sort order or safe cross-system lowering"),t}var wne={"0":"boolean","1":"integer","2":"integer","4":"float","5":"float","6":"binary","7":"binary"},Dne={STRING:"string",ENUM:"string",DECIMAL:"decimal",DATE:"date",TIME:"time",TIMESTAMP:"timestamp",INTEGER:"integer",FLOAT16:"float"},Tne=(e)=>!!(e&&typeof e==="object"&&(Array.isArray(e.$unknown)&&e.$unknown.length>0||Object.values(e).some(Tne)));function B2e(e){if(!We(e,Tj()).valid)throw new U("PARQUET_CAPTURE","Invalid source envelope");let t=e.modules.find((l)=>l.id==="parquet")?.elements.find((l)=>l.id==="source")?.extensions[dp];if(!t||!e.vocabularies[dp])throw new U("PARQUET_CAPTURE","Missing Parquet source");let n={umf:"0.1.0",id:e.id,vocabularies:{[dp]:{version:e.vocabularies[dp].version}},modules:[{id:"parquet",namespace:"",elements:[{id:"source",extensions:{[dp]:Ae(t)}}]}]},r=xne(n),i={status:r.status,complete:!1,fields:[],diagnostics:r.diagnostics};if(r.status!=="checked")return i;let s=r.metadata.schema,o=new Map(r.annotations?.map((l)=>[l.index,l]));function a(l){if(l.index!==0){let c=s[l.index],u=o.get(l.index),p;if(c.type!==void 0){if(u){if(u.validation==="checked"&&Object.hasOwn(Dne,u.name))p=Dne[u.name]}else if(Object.hasOwn(wne,c.type))p=wne[c.type];if(Tne(c))p=void 0}i.fields.push({index:l.index,path:[...l.path],definitionLevel:l.definitionLevel,repetitionLevel:l.repetitionLevel,nativeField:Ae(c),element:{id:"schema:"+l.index,name:l.name,...p?{scalarType:p}:{},extensions:{}}})}l.children.forEach(a)}return a(r.tree),i}function Sne(e){let t=e.modules.find((r)=>r.id==="parquet.fields");if(!t)return;let n=B2e(e);if(n.status!=="checked"||t.namespace!==""||t.elements.length!==n.fields.length||n.fields.some((r,i)=>["id","name","scalarType"].some((s)=>t.elements[i]?.[s]!==r.element[s])))throw new U("PARQUET_FIELD_METADATA","Native schema and core field metadata disagree")}var dp="umf.parquet";var V2e=dne;function Tj(){return new nt().register(V2e)}function Ov(e){if(!We(e,Tj()).valid)throw new U("PARQUET_CAPTURE","Invalid Parquet capture envelope");if(e.modules.some((i)=>i.id==="parquet.fields"))Sne(e);let t=e.modules.find((i)=>i.id==="parquet")?.elements.find((i)=>i.id==="source")?.extensions[dp];if(e.vocabularies[dp]?.version!=="0.1.0"||!t||typeof t!=="object"||Array.isArray(t))throw new U("PARQUET_CAPTURE","Expected pinned Parquet source");if(Object.keys(t).some((i)=>!["profile","encoding","bytes"].includes(i)))throw new U("PARQUET_REPRESENTATION","Unknown capture fields cannot be discarded by native export");let n=t.bytes,r=new Uint8Array(n.length/2);for(let i=0;i(n.diagnostics.push({code:c,path:"",severity:"error",message:u}),n);if(t.length<12)return r("PARQUET_TRUNCATED","File is shorter than the framing minimum");let i=(c)=>String.fromCharCode(...t.subarray(c,c+4)),s=i(0),o=i(t.length-4);if(!["PAR1","PARE"].includes(s)||o!==s)return r("PARQUET_MAGIC","Expected matching PAR1 or PARE header and trailer");let a=new DataView(t.buffer,t.byteOffset,t.byteLength).getUint32(t.length-8,!0),l=t.length-8-a;if(a===0||l<4)return r("PARQUET_FOOTER_BOUNDS","Footer region is empty or overlaps the file header");return n.status="located",n.footerRegion={offset:l,length:a,mode:s==="PARE"?"encrypted":"plaintext-or-signed"},n.diagnostics.push({code:"PARQUET_UNINTERPRETED",path:"",severity:"warning",message:"Footer location alone does not validate Thrift metadata, schemas, pages, encryption, signatures or native values"}),n}var Pne=Rr(og(),1);var Ene={id:"umf.generalized-rdf",version:"0.1.0",coreVersion:"0.1.0",description:"JSON-LD generalized dataset JSON with blank predicates and source-local blank identity",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:generalized-rdf:0.1.0",type:"object",properties:{profile:{const:"jsonld-generalized-dataset"},blankNodeScope:{type:"string",minLength:1},root:{$ref:"#/$defs/node"},originalSource:{type:"string",maxLength:4000000}},required:["profile","blankNodeScope","root","originalSource"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-027; JSON-LD generalized RDF subset: node subjects/predicates, literal objects, named/default graphs; no RDF 1.1 syntax or entailment claim",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"JSON-LD generalized RDF dataset",version:"JSON-LD 1.0/1.1 processing API; RDFJS-shaped JSON term records",subset:"JSON array of quads, node predicates including blank nodes, exact string lexical forms and source-local blank scope; unknown structures archived and block interpretation; no literal subjects/predicates or standard N-Quads export"},evidence:["tests/generalized-rdf/dataset.test.ts","fixtures/generalized-rdf/oracle-results.json","fixtures/generalized-rdf/browser-results.json"]}};var kne={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:generalized-rdf:dataset:0.1.0",type:"array",maxItems:1e4,items:{type:"object",properties:{subject:{oneOf:[{type:"object",properties:{termType:{const:"NamedNode"},value:{type:"string"}},required:["termType","value"],additionalProperties:!0},{type:"object",properties:{termType:{const:"BlankNode"},value:{type:"string",minLength:1}},required:["termType","value"],additionalProperties:!0}]},predicate:{oneOf:[{type:"object",properties:{termType:{const:"NamedNode"},value:{type:"string"}},required:["termType","value"],additionalProperties:!0},{type:"object",properties:{termType:{const:"BlankNode"},value:{type:"string",minLength:1}},required:["termType","value"],additionalProperties:!0}]},object:{oneOf:[{type:"object",properties:{termType:{const:"NamedNode"},value:{type:"string"}},required:["termType","value"],additionalProperties:!0},{type:"object",properties:{termType:{const:"BlankNode"},value:{type:"string",minLength:1}},required:["termType","value"],additionalProperties:!0},{type:"object",properties:{termType:{const:"Literal"},value:{type:"string"},datatype:{type:"object",properties:{termType:{const:"NamedNode"},value:{type:"string"}},required:["termType","value"],additionalProperties:!0},language:{type:"string"}},required:["termType","value","datatype"],additionalProperties:!0}]},graph:{oneOf:[{type:"object",properties:{termType:{const:"NamedNode"},value:{type:"string"}},required:["termType","value"],additionalProperties:!0},{type:"object",properties:{termType:{const:"BlankNode"},value:{type:"string",minLength:1}},required:["termType","value"],additionalProperties:!0},{type:"object",properties:{termType:{const:"DefaultGraph"},value:{const:""}},required:["termType","value"],additionalProperties:!0}]}},required:["subject","predicate","object","graph"],additionalProperties:!0}};var G2e="\\u00a0-\\ud7ff\\uf900-\\ufdcf\\ufdf0-\\uffef"+Array.from({length:13},(e,t)=>`\\u{${((t+1)*65536).toString(16)}}-\\u{${((t+1)*65536+65533).toString(16)}}`).join("")+"\\u{e1000}-\\u{efffd}",H2e=`A-Za-z0-9._~${G2e}\\-`;var Nne=`(?:[${H2e}!$&'()*+,;=]|%[0-9A-Fa-f]{2})`,iS=(e)=>new RegExp(`^(?:${Nne}|[${e}])*$`,"u"),z2e=iS(":@/"),W2e=iS(":@/?\\ue000-\\uf8ff\\u{f0000}-\\u{ffffd}\\u{100000}-\\u{10fffd}"),Q2e=iS(":@/?"),Y2e=iS(":"),X2e=new RegExp(`^${Nne}*$`,"u");function Z2e(e){if(e.includes(".")){let r=e.lastIndexOf(":"),i=e.slice(r+1).split(".");if(i.length!==4||i.some((s)=>!/^(0|[1-9][0-9]{0,2})$/.test(s)||Number(s)>255))return!1;e=e.slice(0,r+1)+"0:0"}let t=e.split("::");if(t.length>2)return!1;let n=t.flatMap((r)=>r?r.split(":"):[]);return n.every((r)=>/^[0-9a-f]{1,4}$/i.test(r))&&(t.length===2?n.length<8:n.length===8)}function sS(e){if(/[\u0000-\u0020\u007f]/.test(e))return!1;let t=/^[A-Za-z][A-Za-z0-9+.-]*:([\s\S]*)$/.exec(e);if(!t)return!1;let n=t[1],r=n.indexOf("#");if(r>=0){if(!Q2e.test(n.slice(r+1)))return!1;n=n.slice(0,r)}let i=n.indexOf("?");if(i>=0){if(!W2e.test(n.slice(i+1)))return!1;n=n.slice(0,i)}if(n.startsWith("//")){let s=n.indexOf("/",2),o=s<0?n.slice(2):n.slice(2,s);n=s<0?"":n.slice(s);let a=o.lastIndexOf("@");if(a>=0){if(!Y2e.test(o.slice(0,a)))return!1;o=o.slice(a+1)}if(o.startsWith("[")){let l=o.indexOf("]");if(l<0)return!1;let c=o.slice(1,l),u=o.slice(l+1);if(u&&!/^:[0-9]*$/.test(u))return!1;if(!Z2e(c)&&!/^v[0-9a-f]+\.[A-Za-z0-9._~!$&'()*+,;=:-]+$/i.test(c))return!1}else{let l=o.lastIndexOf(":");if(l>=0){if(!/^[0-9]*$/.test(o.slice(l+1)))return!1;o=o.slice(0,l)}if(!X2e.test(o))return!1}}return z2e.test(n)}var eqe=new Set("en-gb-oed i-ami i-bnn i-default i-enochian i-hak i-klingon i-lux i-mingo i-navajo i-pwn i-tao i-tay i-tsu sgn-be-fr sgn-be-nl sgn-ch-de art-lojban cel-gaulish no-bok no-nyn zh-guoyu zh-hakka zh-min zh-min-nan zh-xiang".split(" "));function Sj(e){if(/[^A-Za-z0-9-]/.test(e))return!1;let t=e.toLowerCase();if(eqe.has(t)||/^x(?:-[a-z0-9]{1,8})+$/.test(t))return!0;let n=/^(?:[a-z]{2,3}(?:-[a-z]{3}){0,3}|[a-z]{4}|[a-z]{5,8})(?:-[a-z]{4})?(?:-(?:[a-z]{2}|[0-9]{3}))?((?:-(?:[a-z0-9]{5,8}|[0-9][a-z0-9]{3}))*)((?:-[0-9a-wy-z](?:-[a-z0-9]{2,8})+)*)(?:-x(?:-[a-z0-9]{1,8})+)?$/.exec(t);if(!n)return!1;let r=n[1].split("-").filter(Boolean),i=n[2].split("-").filter((s)=>s.length===1);return new Set(r).size===r.length&&new Set(i).size===i.length}var One="umf.generalized-rdf",tqe=Ene,nqe=new Pne.default({strict:!1,validateFormats:!1}).compile(kne);function rqe(e){let t=e,n=[{code:"GENERALIZED_RDF_SCOPE",path:"",severity:"warning",message:"JSON-LD generalized dataset subset; blank identities are local to blankNodeScope. This is not RDF 1.1 N-Quads or an entailment claim."}],r=(a,l)=>n.push({code:a,path:"",severity:"warning",message:l});if(Object.keys(t).some((a)=>!["profile","blankNodeScope","root","originalSource"].includes(a)))r("GENERALIZED_RDF_ENCODING","Unknown encoding fields retained; native export and interpretation blocked");let i=(a)=>{if(Object.keys(a).some((l)=>!(a.kind==="null"?["kind"]:a.kind==="object"?["kind","members"]:a.kind==="array"?["kind","items"]:["kind","value"]).includes(l)))r("GENERALIZED_RDF_ENCODING","Unknown NativeJson encoding field retained");if(a.kind==="object")Object.values(a.members).forEach(i);if(a.kind==="array")a.items.forEach(i)};i(t.root);try{Jt(t.originalSource)}catch(a){n.push({code:"GENERALIZED_RDF_SOURCE",path:"",severity:"error",message:String(a)})}let s=JSON.parse(Be(t.root));if(!nqe(s))return r("GENERALIZED_RDF_UNSUPPORTED","Native dataset structure is outside the declared subset; exact source retained"),n;let o=(a,l)=>{if(Object.keys(a).some((c)=>!l.includes(c)))r("GENERALIZED_RDF_UNSUPPORTED","Unknown native fields retained; interpretation and edits blocked")};for(let a of s){o(a,["subject","predicate","object","graph"]);for(let l of[a.subject,a.predicate,a.object,a.graph]){if(o(l,l.termType==="Literal"?["termType","value","datatype","language"]:["termType","value"]),l.termType==="NamedNode"&&!sS(l.value))r("GENERALIZED_RDF_UNSUPPORTED","Malformed IRI retained");if(l.termType==="Literal"){if(o(l.datatype,["termType","value"]),!sS(l.datatype.value)||(l.language??""?!Sj(l.language)||l.datatype.value!=="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString":l.datatype.value==="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString"))r("GENERALIZED_RDF_UNSUPPORTED","Malformed literal datatype/language retained")}}}return n}function iqe(){return new nt().register(tqe,rqe)}function $ne(e){return We(e,iqe())}function sqe(e){let t=$ne(e);if(!t.valid)throw new U("GENERALIZED_RDF_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="dataset")?.elements.find((r)=>r.id==="dataset")?.extensions[One];if(!n||e.vocabularies[One]?.version!=="0.1.0")throw new U("GENERALIZED_RDF_PAYLOAD","Expected pinned generalized dataset");return Ae(n)}function Ine(e){let t=sqe(e);if($ne(e).diagnostics.some((n)=>n.code==="GENERALIZED_RDF_ENCODING"))throw new U("GENERALIZED_RDF_EXPORT","Unknown encoding fields cannot be discarded");return Be(t.root)===Be(Jt(t.originalSource))?t.originalSource:Be(t.root)+` +`}var Ane={id:"umf.sqlserver",version:"0.1.0",coreVersion:"0.1.0",description:"SQL Server catalog capture and core column metadata",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:sqlserver:0.1.0",type:"object",required:["profile","root"],properties:{profile:{const:"sqlserver-catalog-v1"},root:{$ref:"#/$defs/node"}},$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-031; bounded observations, not full server semantics or reconstruction",scopes:["document"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Microsoft SQL Server",version:"SQL Server 2022; native evidence 16.0.4295.3; capture profiles v1/v2/v3",subset:"Table/column, key/foreign-key/check and index observations; exact recovery and metadata views. Permission-limited, not complete catalog or DDL reconstruction."},evidence:["tests/sqlserver/catalog.test.ts","native/sqlserver/catalog.sql","fixtures/sqlserver/oracle.json","fixtures/sqlserver/browser.json","tests/sqlserver/constraints.test.ts","fixtures/sqlserver/constraints-oracle.json","tests/sqlserver/indexes.test.ts","fixtures/sqlserver/indexes-oracle.json"]}};var Ej={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:sqlserver:capture:0.1.0",type:"object",required:["profile","state","serverVersion","query","tables"],properties:{profile:{enum:["sqlserver-catalog-v1","sqlserver-catalog-v2","sqlserver-catalog-v3"]},state:{enum:["captured","modified"]},serverVersion:{type:"string"},query:{type:"string"},tables:{type:"array",items:{type:"object",required:["schema","name","columns"],properties:{schema:{type:"string"},name:{type:"string"},columns:{type:"array",items:{type:"object",required:["name","column_id","system_type_id","user_type_id","type_schema","type_name","base_type_name","is_user_defined","is_assembly_type","max_length","precision","scale","is_nullable","is_identity","is_computed","collation_name","default_definition","computed_definition","identity_seed","identity_increment","description"],properties:{name:{type:"string"},column_id:{type:"integer",minimum:1},system_type_id:{type:"integer",minimum:0,maximum:255},user_type_id:{type:"integer"},type_schema:{type:"string"},type_name:{type:"string"},base_type_name:{type:["string","null"]},is_user_defined:{type:"boolean"},is_assembly_type:{type:"boolean"},max_length:{type:"integer",minimum:-1,maximum:32767},precision:{type:"integer",minimum:0,maximum:255},scale:{type:"integer",minimum:0,maximum:255},is_nullable:{type:"boolean"},is_identity:{type:"boolean"},is_computed:{type:"boolean"},collation_name:{type:["string","null"]},default_definition:{type:["string","null"]},computed_definition:{type:["string","null"]},identity_seed:{type:["string","null"]},identity_increment:{type:["string","null"]},description:{type:["string","null"]}}}},keys:{type:"array",items:{type:"object",required:["name","kind","is_system_named","index_type","is_disabled","ignore_dup_key","columns"],properties:{name:{type:"string"},kind:{type:"string"},is_system_named:{type:"boolean"},index_type:{type:"string"},is_disabled:{type:"boolean"},ignore_dup_key:{type:"boolean"},columns:{type:"array",items:{type:"object",required:["key_ordinal","column_id","name","is_descending_key"],properties:{key_ordinal:{type:"integer",minimum:1},column_id:{type:"integer",minimum:1},name:{type:"string"},is_descending_key:{type:"boolean"}}}}}}},foreign_keys:{type:"array",items:{type:"object",required:["name","is_system_named","is_disabled","is_not_trusted","is_not_for_replication","delete_action","update_action","referenced_schema","referenced_table","columns"],properties:{name:{type:"string"},is_system_named:{type:"boolean"},is_disabled:{type:"boolean"},is_not_trusted:{type:"boolean"},is_not_for_replication:{type:"boolean"},delete_action:{type:"string"},update_action:{type:"string"},referenced_schema:{type:["string","null"]},referenced_table:{type:["string","null"]},columns:{type:"array",items:{type:"object",required:["ordinal","column_id","column_name","referenced_column_id","referenced_column_name"],properties:{ordinal:{type:"integer",minimum:1},column_id:{type:"integer",minimum:1},column_name:{type:["string","null"]},referenced_column_id:{type:"integer",minimum:1},referenced_column_name:{type:["string","null"]}}}}}}},checks:{type:"array",items:{type:"object",required:["name","is_system_named","parent_column_id","definition","is_disabled","is_not_trusted","is_not_for_replication","uses_database_collation"],properties:{name:{type:"string"},is_system_named:{type:"boolean"},parent_column_id:{type:"integer",minimum:0},definition:{type:["string","null"]},is_disabled:{type:"boolean"},is_not_trusted:{type:"boolean"},is_not_for_replication:{type:"boolean"},uses_database_collation:{type:"boolean"}}}},indexes:{type:"array",items:{type:"object",required:["index_id","name","type","type_desc","is_unique","is_primary_key","is_unique_constraint","is_disabled","is_hypothetical","ignore_dup_key","fill_factor","is_padded","allow_row_locks","allow_page_locks","has_filter","filter_definition","compression_delay","optimize_for_sequential_key","data_space_id","data_space_name","data_space_type","columns"],properties:{index_id:{type:"integer",minimum:0,maximum:2147483647},name:{type:["string","null"]},type:{type:"integer",minimum:0,maximum:255},type_desc:{type:"string"},is_unique:{type:"boolean"},is_primary_key:{type:"boolean"},is_unique_constraint:{type:"boolean"},is_disabled:{type:"boolean"},is_hypothetical:{type:"boolean"},ignore_dup_key:{type:"boolean"},fill_factor:{type:"integer",minimum:0,maximum:100},is_padded:{type:"boolean"},allow_row_locks:{type:"boolean"},allow_page_locks:{type:"boolean"},has_filter:{type:"boolean"},filter_definition:{type:["string","null"]},compression_delay:{type:["integer","null"],minimum:0,maximum:2147483647},optimize_for_sequential_key:{type:"boolean"},data_space_id:{type:"integer",minimum:0,maximum:2147483647},data_space_name:{type:["string","null"]},data_space_type:{type:["string","null"]},columns:{type:"array",items:{type:"object",required:["index_column_id","column_id","name","key_ordinal","partition_ordinal","is_descending_key","is_included_column","column_store_order_ordinal"],properties:{index_column_id:{type:"integer",minimum:1,maximum:2147483647},column_id:{type:"integer",minimum:0,maximum:2147483647},name:{type:["string","null"]},key_ordinal:{type:"integer",minimum:0,maximum:255},partition_ordinal:{type:"integer",minimum:0,maximum:255},is_descending_key:{type:"boolean"},is_included_column:{type:"boolean"},column_store_order_ordinal:{type:"integer",minimum:0,maximum:255}}}}}}}}}}},allOf:[{if:{properties:{profile:{enum:["sqlserver-catalog-v2","sqlserver-catalog-v3"]}}},then:{properties:{tables:{type:"array",items:{type:"object",properties:{keys:{},foreign_keys:{},checks:{}},required:["keys","foreign_keys","checks"]}}}}},{if:{properties:{profile:{const:"sqlserver-catalog-v3"}}},then:{properties:{tables:{type:"array",items:{type:"object",properties:{indexes:{}},required:["indexes"]}}}}}]};function oS(e,t){let n=new Set;function r(i,s,o){if(s.$ref){if(!s.$ref.startsWith("#/$defs/"))throw Error("Unsupported catalog schema reference");r(i,t.$defs[s.$ref.slice(8)],o);return}if(s.anyOf){for(let a of s.anyOf)r(i,a,o);return}if(i.kind==="number"&&(s.type==="integer"||Array.isArray(s.type)&&s.type.includes("integer")))try{let a=ys(i.value,"json");if(typeof a!=="number"||!Number.isSafeInteger(a))throw Error("Not an exact integer")}catch{n.add(o)}if(i.kind==="object"){for(let[a,l]of Object.entries(i.members))if(s.properties&&Object.hasOwn(s.properties,a))r(l,s.properties[a],o+"/"+a.replace(/~/g,"~0").replace(/\//g,"~1"))}if(i.kind==="array"&&s.items)i.items.forEach((a,l)=>r(a,s.items,o+"/"+l))}return r(e,t,""),[...n]}var Rne="umf.sqlserver",lqe=Ane,jne=mt().compile(Ej),cqe={"104":["bit","boolean"],"48":["tinyint","integer"],"52":["smallint","integer"],"56":["int","integer"],"127":["bigint","integer"],"106":["decimal","decimal"],"108":["numeric","decimal"],"60":["money","decimal"],"122":["smallmoney","decimal"],"59":["real","float"],"62":["float","float"],"167":["varchar","string"],"175":["char","string"],"231":["nvarchar","string"],"239":["nchar","string"],"35":["text","string"],"99":["ntext","string"],"165":["varbinary","binary"],"173":["binary","binary"],"34":["image","binary"],"189":["timestamp","binary"],"40":["date","date"],"41":["time","time"],"42":["datetime2","timestamp"],"43":["datetimeoffset","timestamp"],"58":["smalldatetime","timestamp"],"61":["datetime","timestamp"]},Pv=(e)=>e?.kind==="string"?e.value:void 0;function uqe(e){let t=e,n=[{code:"SQLSERVER_CAPTURE_SCOPE",path:"",severity:"warning",message:"Permission-limited table/column observations; server correspondence and complete native semantics are unverified"}],r=(a)=>n.push({code:"SQLSERVER_ENCODING",path:a,severity:"warning",message:"Unknown encoding content must remain in UMF and blocks native export"});for(let a of Object.keys(t))if(!["profile","root"].includes(a))r("/"+a);function i(a,l){let c=a.kind==="object"?["kind","members"]:a.kind==="array"?["kind","items"]:a.kind==="null"?["kind"]:["kind","value"];if(Object.keys(a).some((u)=>!c.includes(u)))r(l);if(a.kind==="object")Object.entries(a.members).forEach(([u,p])=>i(p,l+"/"+u));if(a.kind==="array")a.items.forEach((u,p)=>i(u,l+"/"+p))}i(t.root,"/root");for(let a of oS(t.root,Ej))n.push({code:"SQLSERVER_INTEGER",path:a,severity:"error",message:"Declared catalog integers must be exact interoperable integers; numeric rounding is not permitted"});if(n.some((a)=>a.severity==="error"))return n;let s=JSON.parse(Be(t.root));if(!jne(s))return n.push({code:"SQLSERVER_CAPTURE_STRUCTURE",path:"",severity:"error",message:JSON.stringify(jne.errors)}),n;let o=new Set;for(let a of s.tables){let l=JSON.stringify([a.schema,a.name]);if(o.has(l))n.push({code:"SQLSERVER_DUPLICATE",path:"/tables",severity:"error",message:"Duplicate qualified table observation"});o.add(l);let c=new Set,u=new Set;for(let p of a.columns){if(c.has(p.name)||u.has(p.column_id))n.push({code:"SQLSERVER_DUPLICATE",path:"/tables",severity:"error",message:"Duplicate column name or native ID"});c.add(p.name),u.add(p.column_id)}}if(!s.serverVersion?.startsWith("16."))n.push({code:"SQLSERVER_VERSION",path:"/serverVersion",severity:"warning",message:"Version retained outside the SQL Server 2022 profile"});for(let[a,l]of s.tables.entries()){let c=new Set;for(let d of["keys","foreign_keys","checks"])for(let[f,m]of(l[d]??[]).entries()){let y="/tables/"+a+"/"+d+"/"+f;if(c.has(m.name))n.push({code:"SQLSERVER_DUPLICATE",path:y,severity:"error",message:"Duplicate constraint name within table"});if(c.add(m.name),d!=="checks"){let h=new Set,b=new Set;for(let g of m.columns){let x=d==="keys"?g.key_ordinal:g.ordinal;if(h.has(x)||b.has(g.column_id))n.push({code:"SQLSERVER_CONSTRAINT_COLUMNS",path:y,severity:"error",message:"Duplicate constraint column or ordinal"});h.add(x),b.add(g.column_id)}if(!m.columns.length)n.push({code:"SQLSERVER_CONSTRAINT_UNRESOLVED",path:y,severity:"warning",message:"Constraint column observations are unavailable"})}if(d==="keys"&&!["PK","UQ"].includes(m.kind)||d==="foreign_keys"&&[m.delete_action,m.update_action].some((h)=>!["NO_ACTION","CASCADE","SET_NULL","SET_DEFAULT"].includes(h)))n.push({code:"SQLSERVER_CONSTRAINT_UNKNOWN",path:y,severity:"warning",message:"Unknown native constraint kind/action retained without interpretation"})}let u=new Set,p=new Set;for(let[d,f]of(l.indexes??[]).entries()){let m="/tables/"+a+"/indexes/"+d;if(u.has(f.index_id)||f.name!==null&&p.has(f.name))n.push({code:"SQLSERVER_DUPLICATE",path:m,severity:"error",message:"Duplicate index name or native ID within table"});if(u.add(f.index_id),f.name!==null)p.add(f.name);let y=new Set,h=new Set,b=new Set,g=new Set;for(let v of f.columns){if(y.has(v.index_column_id)||v.key_ordinal>0&&h.has(v.key_ordinal)||v.column_store_order_ordinal>0&&b.has(v.column_store_order_ordinal)||v.partition_ordinal>0&&g.has(v.partition_ordinal))n.push({code:"SQLSERVER_INDEX_COLUMNS",path:m,severity:"error",message:"Duplicate index column ID or positive ordering ordinal"});if(y.add(v.index_column_id),v.key_ordinal>0)h.add(v.key_ordinal);if(v.column_store_order_ordinal>0)b.add(v.column_store_order_ordinal);if(v.partition_ordinal>0)g.add(v.partition_ordinal)}if({0:"HEAP",1:"CLUSTERED",2:"NONCLUSTERED",3:"XML",4:"SPATIAL",5:"CLUSTERED COLUMNSTORE",6:"NONCLUSTERED COLUMNSTORE",7:"NONCLUSTERED HASH"}[f.type]!==f.type_desc)n.push({code:"SQLSERVER_INDEX_UNKNOWN",path:m,severity:"warning",message:"Unknown index type identity retained without interpretation"});if([3,4,7].includes(f.type))n.push({code:"SQLSERVER_INDEX_DETAILS_UNAVAILABLE",path:m,severity:"warning",message:"Specialized XML, spatial or hash index details are outside this catalog capture"});if(f.has_filter&&f.filter_definition===null)n.push({code:"SQLSERVER_INDEX_FILTER_UNAVAILABLE",path:m,severity:"warning",message:"Filtered index predicate unavailable; do not infer an unfiltered index"})}}if(s.state==="modified")n.push({code:"SQLSERVER_MODIFIED",path:"/state",severity:"warning",message:"Candidate metadata edits do not update SQL Server or synchronize original DDL"});return n}function pqe(){return new nt().register(lqe,uqe)}function Fne(e){return We(e,pqe())}function Cne(e){let t=Fne(e);if(!t.valid||e.vocabularies[Rne]?.version!=="0.1.0")throw new U("SQLSERVER_CAPTURE",JSON.stringify(t.diagnostics));let n=e.extensions?.[Rne];if(!n)throw new U("SQLSERVER_CAPTURE","Missing SQL Server capture");return Ae(n)}function dqe(e){if(e.kind!=="object"||e.members.tables?.kind!=="array")return[];let t=[];return e.members.tables.items.forEach((n,r)=>{if(n.kind!=="object"||n.members.columns?.kind!=="array")return;n.members.columns.items.forEach((i,s)=>{if(i.kind!=="object")return;let o=i.members,a=o.system_type_id?.kind==="number"?String(Number(o.system_type_id.value)):"",l=cqe[a],c=l&&Pv(o.base_type_name)===l[0]&&o.is_assembly_type?.kind==="boolean"&&!o.is_assembly_type.value?l[1]:void 0,u="/tables/"+r+"/columns/"+s,p=Pv(o.description);t.push({path:u,table:{schema:Pv(n.members.schema),name:Pv(n.members.name)},nativeColumn:Ae(i),element:{id:u,name:Pv(o.name),...p!==void 0?{description:p}:{},...c?{scalarType:c}:{},extensions:{}}})})}),t}function fqe(e){return dqe(Cne(e).root)}function mqe(e){let t=e.modules.find((r)=>r.id==="sqlserver.columns"),n=fqe(e);if(!t||t.namespace!==""||t.elements.length!==n.length||n.some((r,i)=>["id","name","description","scalarType"].some((s)=>t.elements[i]?.[s]!==r.element[s])))throw new U("SQLSERVER_METADATA","Native columns and core metadata disagree")}function Mne(e){if(mqe(e),Fne(e).diagnostics.some((t)=>t.code==="SQLSERVER_ENCODING"))throw new U("SQLSERVER_ENCODING","Unknown source encoding cannot be discarded");return Be(Cne(e).root)+` +`}var Lne={id:"umf.postgresql.catalog",version:"0.1.0",coreVersion:"0.1.0",description:"Versioned observed PostgreSQL catalog captures with reconstruction archives",schema:{type:"object",required:["profile","state","root"],properties:{profile:{const:"postgresql-catalog-capture"},state:{enum:["captured","modified"]},root:{$ref:"#/$defs/node"}},additionalProperties:!0,$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:postgresql-catalog:0.1.0",$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-015. Captured catalog observations and original schema-only dump are retained together. Candidate edits mark the capture modified; no synchronization, execution or universal catalog coverage is implied.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"UMF PostgreSQL catalog capture profile",version:"0.1.0 / PostgreSQL 17",subset:"The exact evidence query and metadata fields in capture.schema.json, with pg_dump plain schema-only archive; no full pg_catalog or server-state validation"},evidence:["tests/postgresql/catalog.test.ts","scripts/postgresql-catalog-oracle.ts"]}};var qne={bool:"boolean",int2:"integer",int4:"integer",int8:"integer",numeric:"decimal",float4:"float",float8:"float",text:"string",varchar:"string",bpchar:"string",bytea:"binary",date:"date",time:"time",timetz:"time",timestamp:"timestamp",timestamptz:"timestamp"},Pc=(e)=>e?.kind==="string"?e.value:void 0;function Une(e){if(e.kind!=="object")return[];let t=e.members.snapshot;if(t?.kind!=="object")return[];let n=t.members.relations;if(n?.kind!=="array")return[];let r=[];return n.items.forEach((i,s)=>{if(i.kind!=="object"||i.members.columns?.kind!=="array")return;let o=i.members;i.members.columns.items.forEach((a,l)=>{if(a.kind!=="object")return;let c=a.members,u=c.nativeType,p;if(u?.kind==="object"&&Pc(u.members.schema)==="pg_catalog"&&Pc(u.members.kind)==="b"&&Pc(u.members.category)!=="A"&&u.members.dimensions?.kind==="number"&&Number(u.members.dimensions.value)===0){let m=Pc(u.members.name);if(m&&Object.hasOwn(qne,m))p=qne[m]}let d="/snapshot/relations/"+s+"/columns/"+l,f=Pc(c.comment);r.push({path:d,relation:{schema:Pc(o.schema)??"",name:Pc(o.name)??"",kind:Pc(o.kind)??""},nativeColumn:Ae(a),element:{id:d,name:Pc(c.name)??"",...f!==void 0?{description:f}:{},...p?{scalarType:p}:{},extensions:{}}})})}),r}var $v={type:"object",required:["profile","serverVersion","query","snapshot","reconstruction","state"],properties:{profile:{const:"postgresql-catalog-capture-v1"},serverVersion:{type:"integer",minimum:170000,maximum:179999},query:{type:"string"},snapshot:{$ref:"#/$defs/snapshot"},reconstruction:{type:"object",required:["format","toolVersion","sql"],properties:{format:{const:"pg-dump-plain-schema-only"},toolVersion:{type:"string"},sql:{type:"string"}},additionalProperties:!0},state:{enum:["captured","modified"]}},additionalProperties:!0,$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:postgresql-catalog:capture:0.1.0",$defs:{namespace:{type:"object",required:["name","owner","acl"],properties:{name:{type:"string"},owner:{type:"string"},acl:{type:["string","null"]}},additionalProperties:!0},column:{type:"object",required:["name","position","type","notNull","identity","generated","collation","default","comment","storage","compression","acl"],properties:{name:{type:"string"},position:{type:"integer",minimum:1,maximum:32767},type:{type:"string"},nativeType:{type:"object",required:["schema","name","kind","category","dimensions","modifier"],properties:{schema:{type:"string"},name:{type:"string"},kind:{type:"string"},category:{type:"string"},dimensions:{type:"integer",minimum:0},modifier:{type:"integer"}}},notNull:{type:"boolean"},identity:{type:"string"},generated:{type:"string"},collation:{type:["string","null"]},default:{type:["string","null"]},comment:{type:["string","null"]},storage:{type:"string"},compression:{type:"string"},acl:{type:["string","null"]}},additionalProperties:!0},constraint:{type:"object",required:["name","kind","definition","deferrable","deferred","validated"],properties:{name:{type:"string"},kind:{type:"string"},definition:{type:"string"},deferrable:{type:"boolean"},deferred:{type:"boolean"},validated:{type:"boolean"}},additionalProperties:!0},index:{type:"object",required:["definition","valid","ready","replicaIdentity"],properties:{definition:{type:"string"},valid:{type:"boolean"},ready:{type:"boolean"},replicaIdentity:{type:"boolean"}},additionalProperties:!0},policy:{type:"object",required:["name","command","permissive","roles","using","check"],properties:{name:{type:"string"},command:{type:"string"},permissive:{type:"boolean"},roles:{type:["array","null"],items:{type:"string"}},using:{type:["string","null"]},check:{type:["string","null"]}},additionalProperties:!0},sequence:{type:"object",required:["type","start","increment","min","max","cache","cycle"],properties:{type:{type:"string"},start:{type:"string",pattern:"^-?[0-9]+$"},increment:{type:"string",pattern:"^-?[0-9]+$"},min:{type:"string",pattern:"^-?[0-9]+$"},max:{type:"string",pattern:"^-?[0-9]+$"},cache:{type:"string",pattern:"^-?[0-9]+$"},cycle:{type:"boolean"}},additionalProperties:!0},relation:{type:"object",required:["schema","name","kind","persistence","owner","acl","options","rowSecurity","forceRowSecurity","comment","partitionKey","partitionBound","parents","view","columns","constraints","indexes","policies","sequence"],properties:{schema:{type:"string"},name:{type:"string"},kind:{type:"string"},persistence:{type:"string"},owner:{type:"string"},acl:{type:["string","null"]},options:{type:["array","null"],items:{type:"string"}},rowSecurity:{type:"boolean"},forceRowSecurity:{type:"boolean"},comment:{type:["string","null"]},partitionKey:{type:["string","null"]},partitionBound:{type:["string","null"]},parents:{type:["array","null"],items:{type:"string"}},view:{type:["string","null"]},columns:{type:["array","null"],items:{$ref:"#/$defs/column"}},constraints:{type:["array","null"],items:{$ref:"#/$defs/constraint"}},indexes:{type:["array","null"],items:{$ref:"#/$defs/index"}},policies:{type:["array","null"],items:{$ref:"#/$defs/policy"}},sequence:{anyOf:[{$ref:"#/$defs/sequence"},{type:"null"}]}},additionalProperties:!0},type:{type:"object",required:["schema","name","kind","owner","acl","base","notNull","default","comment","labels","constraints"],properties:{schema:{type:"string"},name:{type:"string"},kind:{type:"string"},owner:{type:"string"},acl:{type:["string","null"]},base:{type:"string"},notNull:{type:"boolean"},default:{type:["string","null"]},comment:{type:["string","null"]},labels:{type:["array","null"],items:{type:"string"}},constraints:{type:["array","null"],items:{type:"object",required:["name","definition","validated"],properties:{name:{type:"string"},definition:{type:"string"},validated:{type:"boolean"}},additionalProperties:!0}}},additionalProperties:!0},function:{type:"object",required:["schema","name","identity","definition","owner","acl","comment"],properties:{schema:{type:"string"},name:{type:"string"},identity:{type:"string"},definition:{type:"string"},owner:{type:"string"},acl:{type:["string","null"]},comment:{type:["string","null"]}},additionalProperties:!0},snapshot:{type:"object",required:["profile","namespaces","relations","types","functions"],properties:{profile:{enum:["umf-postgresql-catalog-evidence-17-v1","umf-postgresql-catalog-evidence-17-v2","umf-postgresql-catalog-evidence-17-v3"]},namespaces:{type:["array","null"],items:{$ref:"#/$defs/namespace"}},relations:{type:["array","null"],items:{$ref:"#/$defs/relation"}},types:{type:["array","null"],items:{$ref:"#/$defs/type"}},functions:{type:["array","null"],items:{$ref:"#/$defs/function"}},triggers:{type:["array","null"],items:{$ref:"#/$defs/trigger"}},compositeTypes:{type:["array","null"],items:{$ref:"#/$defs/compositeType"}},rangeTypes:{type:["array","null"],items:{$ref:"#/$defs/rangeType"}},collations:{type:["array","null"],items:{$ref:"#/$defs/collation"}},dependencies:{type:"array",items:{$ref:"#/$defs/dependency"}}},additionalProperties:!0,allOf:[{if:{properties:{profile:{enum:["umf-postgresql-catalog-evidence-17-v2","umf-postgresql-catalog-evidence-17-v3"]}}},then:{required:["triggers","compositeTypes","rangeTypes","collations"]}},{if:{properties:{profile:{const:"umf-postgresql-catalog-evidence-17-v3"}}},then:{required:["dependencies"]}}]},trigger:{type:"object",properties:{schema:{type:"string"},relation:{type:"string"},name:{type:"string"},enabled:{type:"string"},definition:{type:"string"},function:{type:"string"},deferrable:{type:"boolean"},deferred:{type:"boolean"},comment:{type:["string","null"]}},required:["schema","relation","name","enabled","definition","function","deferrable","deferred","comment"],additionalProperties:!0},compositeType:{type:"object",properties:{schema:{type:"string"},name:{type:"string"},owner:{type:"string"},acl:{type:["string","null"]},comment:{type:["string","null"]},attributes:{type:["array","null"],items:{type:"object",properties:{name:{type:"string"},position:{type:"integer",minimum:1,maximum:32767},type:{type:"string"},collation:{type:["string","null"]}},required:["name","position","type","collation"],additionalProperties:!0}}},required:["schema","name","owner","acl","comment","attributes"],additionalProperties:!0},rangeType:{type:"object",properties:{schema:{type:"string"},name:{type:"string"},owner:{type:"string"},acl:{type:["string","null"]},comment:{type:["string","null"]},subtype:{type:"string"},multirange:{type:"string"},collation:{type:["string","null"]},operatorClass:{type:"string"},canonical:{type:"string"},subtypeDifference:{type:"string"}},required:["schema","name","owner","acl","comment","subtype","multirange","collation","operatorClass","canonical","subtypeDifference"],additionalProperties:!0},collation:{type:"object",properties:{schema:{type:"string"},name:{type:"string"},owner:{type:"string"},provider:{type:"string"},deterministic:{type:"boolean"},encoding:{type:"integer",minimum:-1,maximum:2147483647},collate:{type:["string","null"]},ctype:{type:["string","null"]},locale:{type:["string","null"]},rules:{type:["string","null"]},version:{type:["string","null"]},comment:{type:["string","null"]}},required:["schema","name","owner","provider","deterministic","encoding","collate","ctype","locale","rules","version","comment"],additionalProperties:!0},dependencyObject:{type:"object",required:["catalog","type","schema","name","identity"],properties:{catalog:{type:"string"},type:{type:"string"},schema:{type:["string","null"]},name:{type:["string","null"]},identity:{type:"string"}},additionalProperties:!0},dependency:{type:"object",required:["dependent","referenced","kind"],properties:{dependent:{$ref:"#/$defs/dependencyObject"},referenced:{$ref:"#/$defs/dependencyObject"},kind:{type:"string",minLength:1,maxLength:1}},additionalProperties:!0}},description:"Observed catalog metadata for the versioned UMF PostgreSQL 17 evidence query, with original query and schema-only dump. Native expressions/ACLs/physical types remain strings. Unknown properties are retained. Not the entire PostgreSQL catalog or a guarantee of reconstruction."};var Bne="umf.postgresql.catalog",gqe=Lne,kj;function bqe(e){let t=e,n=[{code:"POSTGRESQL_CATALOG_SCOPE",path:"",severity:"warning",message:"Observed metadata is limited to the declared query/profile; server state and reconstruction correspondence are not verified"}],r=(a,l,c)=>n.push({code:a,path:l,severity:"warning",message:c});if(Object.keys(t).some((a)=>!["profile","state","root"].includes(a)))r("POSTGRESQL_CATALOG_REPRESENTATION","","Unknown representation fields must stay in UMF");function i(a,l){let c=a.kind==="null"?["kind"]:a.kind==="object"?["kind","members"]:a.kind==="array"?["kind","items"]:["kind","value"];if(Object.keys(a).some((u)=>!c.includes(u)))r("POSTGRESQL_CATALOG_REPRESENTATION",l,"Unknown tagged representation fields must stay in UMF");if(a.kind==="object")for(let[u,p]of Object.entries(a.members))i(p,l+"/"+u);if(a.kind==="array")a.items.forEach((u,p)=>i(u,l+"/"+p))}i(t.root,"/root");for(let a of oS(t.root,$v))n.push({code:"POSTGRESQL_CATALOG_INTEGER",path:a,severity:"error",message:"Declared catalog integers must be exact interoperable integers; numeric rounding is not permitted"});if(n.some((a)=>a.severity==="error"))return n;let s=JSON.parse(Be(t.root));if(s?.state!==t.state)n.push({code:"POSTGRESQL_CATALOG_STATE",path:"/root",severity:"error",message:"Capture and representation state must agree"});if(kj??=mt(!1).compile($v),!kj(s))for(let a of kj.errors??[])n.push({code:"POSTGRESQL_CATALOG_STRUCTURE",path:a.instancePath,severity:"error",message:a.message??"Invalid captured metadata"});function o(a,l,c){if(l.$ref)l=$v.$defs[l.$ref.slice(8)];if(l.anyOf){let u=l.anyOf.find((p)=>p.$ref&&a!==null);if(u)o(a,u,c);return}if(Array.isArray(a)&&l.items){a.forEach((u,p)=>o(u,l.items,c+"/"+p));return}if(a&&typeof a==="object"&&l.properties)for(let u of Object.keys(a))if(!Object.hasOwn(l.properties,u))r("POSTGRESQL_CATALOG_UNKNOWN",c+"/"+u,"Unknown native capture field retained without interpretation");else o(a[u],l.properties[u],c+"/"+u)}if(o(s,$v,""),s?.serverVersion!==170004)r("POSTGRESQL_CATALOG_VERSION","/serverVersion","Capture version retained; executed evidence currently covers PostgreSQL 17.4 only");if(t.state==="modified")r("POSTGRESQL_CATALOG_MODIFIED","","Capture has candidate edits; its reconstruction archive is not synchronized");return n}function vqe(){return new nt().register(gqe,bqe)}function Vne(e){return We(e,vqe())}function Kne(e){let t=Vne(e);if(!t.valid)throw new U("POSTGRESQL_CATALOG_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="catalog")?.elements.find((r)=>r.id==="capture")?.extensions[Bne];if(!n||e.vocabularies[Bne]?.version!=="0.1.0")throw new U("POSTGRESQL_CATALOG_PAYLOAD","Expected catalog capture");return Ae(n)}function _qe(e){return Une(Kne(e).root)}function xqe(e){let t=e.modules.find((r)=>r.id==="postgresql.columns");if(!t)return;let n=_qe(e).map((r)=>r.element);if(t.namespace!==""||t.elements.length!==n.length||n.some((r,i)=>["id","name","description","scalarType"].some((s)=>t.elements[i]?.[s]!==r[s])))throw new U("POSTGRESQL_COLUMN_METADATA","Native columns and core metadata disagree")}function Jne(e){xqe(e);let t=Kne(e);if(Vne(e).diagnostics.some((n)=>n.code==="POSTGRESQL_CATALOG_REPRESENTATION"))throw new U("POSTGRESQL_CATALOG_EXPORT","Unknown representation fields cannot be discarded");return{state:t.state,json:Be(t.root),complete:!1}}function Iv(e,t){if(!(e!==null&&typeof e=="object"&&("$typeName"in e)&&typeof e.$typeName=="string"))return!1;if(t===void 0)return!0;return t.typeName===e.$typeName}var ie;(function(e){e[e.DOUBLE=1]="DOUBLE",e[e.FLOAT=2]="FLOAT",e[e.INT64=3]="INT64",e[e.UINT64=4]="UINT64",e[e.INT32=5]="INT32",e[e.FIXED64=6]="FIXED64",e[e.FIXED32=7]="FIXED32",e[e.BOOL=8]="BOOL",e[e.STRING=9]="STRING",e[e.BYTES=12]="BYTES",e[e.UINT32=13]="UINT32",e[e.SFIXED32=15]="SFIXED32",e[e.SFIXED64=16]="SFIXED64",e[e.SINT32=17]="SINT32",e[e.SINT64=18]="SINT64"})(ie||(ie={}));function Hne(){let e=this.buf,t=this.pos,n=0,r=0;for(let s=0;s<28;s+=7){let o=e[t++];if(n|=(o&127)<>4,(i&128)==0){this.pos=t,this.assertBounds(),this.varint64Lo=n,this.varint64Hi=r;return}for(let s=3;s<=31;s+=7){let o=e[t++];if(r|=(o&127)<=aS)i=i+(r/aS|0),r=r%aS}return s(-24,-18),s(-18,-12),s(-12,-6),s(-6),t?Wne(r,i):Pj(r,i)}function zne(e,t){let n=Pj(e,t),r=n.hi&2147483648;if(r)n=Wne(n.lo,n.hi);let i=Oj(n.lo,n.hi);return r?"-"+i:i}function Oj(e,t){if({lo:e,hi:t}=wqe(e,t),t<=2097151)return String(aS*t+e);let n=e&16777215,r=(e>>>24|t<<8)&16777215,i=t>>16&65535,s=n+r*6777216+i*6710656,o=r+i*8147497,a=i*2,l=1e7;if(s>=l)o+=Math.floor(s/l),s%=l;if(o>=l)a+=Math.floor(o/l),o%=l;return a.toString()+Gne(o)+Gne(s)}function wqe(e,t){return{lo:e>>>0,hi:t>>>0}}function Pj(e,t){return{lo:e|0,hi:t|0}}function Wne(e,t){if(t=~t,e)e=~e+1;else t+=1;return Pj(e,t)}var Gne=(e)=>{let t=String(e);return"0000000".slice(t.length)+t};function Qne(e,t){if(e>>>0<128){t.push(e);return}if(e>=0){while(e>127)t.push(e&127|128),e=e>>>7;t.push(e)}else{for(let n=0;n<9;n++)t.push(e&127|128),e=e>>7;t.push(1)}}function Yne(){let e=this.buf[this.pos++];if((e&128)===0)return this.assertBounds(),e;let t=e&127;if(e=this.buf[this.pos++],t|=(e&127)<<7,(e&128)===0)return this.assertBounds(),t;if(e=this.buf[this.pos++],t|=(e&127)<<14,(e&128)===0)return this.assertBounds(),t;if(e=this.buf[this.pos++],t|=(e&127)<<21,(e&128)===0)return this.assertBounds(),t;e=this.buf[this.pos++],t|=(e&15)<<28;for(let n=5;(e&128)!==0&&n<10;n++)e=this.buf[this.pos++];if((e&128)!==0)throw Error("invalid varint");return this.assertBounds(),t>>>0}var Sn=Dqe();function Dqe(){let e=new DataView(new ArrayBuffer(8));if(typeof BigInt==="function"&&typeof e.getBigInt64==="function"&&typeof e.getBigUint64==="function"&&typeof e.setBigInt64==="function"&&typeof e.setBigUint64==="function"&&(!!globalThis.Deno||!!globalThis.Bun||typeof process!="object"||typeof process.env!="object"||process.env.BUF_BIGINT_DISABLE!=="1")){let n=BigInt("-9223372036854775808"),r=BigInt("9223372036854775807"),i=BigInt("0"),s=BigInt("18446744073709551615");return{zero:BigInt(0),supported:!0,parse(o){let a=typeof o=="bigint"?o:BigInt(o);if(a>r||as||ar.localName===n)}function rre(e,t){let n=t.localName;if(t.oneof)return e[t.oneof.localName].case===n;if(t.presence!=tre)return e[n]!==void 0&&Object.prototype.hasOwnProperty.call(e,n);switch(t.fieldKind){case"list":return e[n].length>0;case"map":return Object.keys(e[n]).length>0;case"scalar":return!ere(t.scalar,e[n]);case"enum":return e[n]!==t.enum.values[0].number}throw Error("message field with implicit presence")}function lf(e,t){return Object.prototype.hasOwnProperty.call(e,t)&&e[t]!==void 0}function ire(e,t){if(t.oneof){let n=e[t.oneof.localName];if(n.case===t.localName)return n.value;return}return e[t.localName]}function sre(e,t,n){if(t.oneof)e[t.oneof.localName]={case:t.localName,value:n};else e[t.localName]=n}function ore(e,t){let n=t.localName;if(t.oneof){let r=t.oneof.localName;if(e[r].case===n)e[r]={case:void 0}}else if(t.presence!=tre)delete e[n];else switch(t.fieldKind){case"map":e[n]={};break;case"list":e[n]=[];break;case"enum":e[n]=t.enum.values[0].number;break;case"scalar":e[n]=$c(t.scalar,t.longAsString);break}}function ja(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function Av(e,t){var n,r,i,s;if(ja(e)&&Ra in e&&"add"in e&&"field"in e&&typeof e.field=="function"){if(t!==void 0){let o=t,a=e.field();return o.listKind==a.listKind&&o.scalar===a.scalar&&((n=o.message)===null||n===void 0?void 0:n.typeName)===((r=a.message)===null||r===void 0?void 0:r.typeName)&&((i=o.enum)===null||i===void 0?void 0:i.typeName)===((s=a.enum)===null||s===void 0?void 0:s.typeName)}return!0}return!1}function Rv(e,t){var n,r,i,s;if(ja(e)&&Ra in e&&"has"in e&&"field"in e&&typeof e.field=="function"){if(t!==void 0){let o=t,a=e.field();return o.mapKey===a.mapKey&&o.mapKind==a.mapKind&&o.scalar===a.scalar&&((n=o.message)===null||n===void 0?void 0:n.typeName)===((r=a.message)===null||r===void 0?void 0:r.typeName)&&((i=o.enum)===null||i===void 0?void 0:i.typeName)===((s=a.enum)===null||s===void 0?void 0:s.typeName)}return!0}return!1}function jv(e,t){return ja(e)&&Ra in e&&"desc"in e&&ja(e.desc)&&e.desc.kind==="message"&&(t===void 0||e.desc.typeName==t.typeName)}function are(e){return lre(e.$typeName)}function Cy(e){let t=e.fields[0];return lre(e.typeName)&&t!==void 0&&t.fieldKind=="scalar"&&t.name=="value"&&t.number==1}var Tqe=new Set(["google.protobuf.DoubleValue","google.protobuf.FloatValue","google.protobuf.Int64Value","google.protobuf.UInt64Value","google.protobuf.Int32Value","google.protobuf.UInt32Value","google.protobuf.BoolValue","google.protobuf.StringValue","google.protobuf.BytesValue"]);function lre(e){return Tqe.has(e)}var Sqe=999,Eqe=998,ure=2;function cf(e,t){if(Iv(t,e))return t;return pre(e)(t)}var cre=new WeakMap;function pre(e){let t=cre.get(e);if(t===void 0)t=kqe(e),cre.set(e,t);return t}var $j=0,dre=1,fre=2,mre=3;function kqe(e){let t=e.typeName,{properties:n,prototype:r}=Nqe(e);return(i)=>{let s;if(r!==void 0)s=Object.create(r),s.$typeName=t;else s={$typeName:t};for(let o=0;ol:o.scalar==ie.BYTES?Fv:void 0});break}case"map":{r.push({name:a,kind:fre,constant:void 0,convert:o.mapKind=="message"?(n=lS(o))!==null&&n!==void 0?n:(l)=>l:o.scalar==ie.BYTES?Fv:void 0});break}default:{let l=$qe(o);if(r.push({name:a,kind:$j,constant:o.presence==ure?l:void 0,convert:o.fieldKind=="scalar"&&o.scalar==ie.BYTES?Fv:void 0}),s)i[a]=l;break}}}return{properties:r,prototype:s?i:void 0}}function Oqe(e){let t=new Map;for(let n of e.fields){let r;if(n.fieldKind=="message")r=lS(n);else if(n.fieldKind=="scalar"&&n.scalar==ie.BYTES)r=Fv;t.set(n.localName,r!==null&&r!==void 0?r:(i)=>i)}return t}function lS(e){if(e.fieldKind=="message"&&!e.oneof&&Cy(e.message))return e.message.fields[0].scalar==ie.BYTES?Fv:void 0;if(e.message.typeName=="google.protobuf.Struct"&&e.parent.typeName!=="google.protobuf.Value")return;let t=e.message,n;return(r)=>{if(!ja(r)||Iv(r,t))return r;return n!==null&&n!==void 0||(n=pre(t)),n(r)}}function Fv(e){return Array.isArray(e)?new Uint8Array(e):e}function Pqe(e){switch(e.file.edition){case Sqe:return!1;case Eqe:return!0;default:return e.fields.some((t)=>t.presence!=ure&&t.fieldKind!="message"&&!t.oneof)}}function $qe(e){let t=e.getDefaultValue();if(t!==void 0)return e.fieldKind=="scalar"&&e.longAsString?t.toString():t;return e.fieldKind=="scalar"?$c(e.scalar,e.longAsString):e.enum.values[0].number}class Fa extends Error{constructor(e,t,n="FieldValueInvalidError"){super(t);this.name=n,this.field=()=>e}}var Ij;function Iqe(e){var t;Ij=Object.assign(Object.assign({},e),{encodeUtf8Into:(t=e.encodeUtf8Into)!==null&&t!==void 0?t:Aj(e.encodeUtf8.bind(e))})}function Cv(){if(!Ij){let e=globalThis;if(!e.TextEncoder||!e.TextDecoder)throw Error("encoding API missing: install TextEncoder and TextDecoder on globalThis");let t=new e.TextEncoder,n=new e.TextDecoder,r,i={encodeUtf8(o){return t.encode(o)},decodeUtf8(o,a){if(a){if(!r)r=new e.TextDecoder("utf-8",{fatal:!0});return r.decode(o)}return n.decode(o)},checkUtf8(o){try{return encodeURIComponent(o),!0}catch(a){return!1}}};if(t.encodeInto)i.encodeUtf8Into=t.encodeInto.bind(t);let s=String.prototype.isWellFormed;if(s)i.checkUtf8=(o)=>s.call(o);Iqe(i)}return Ij}function Aj(e){return(t,n)=>{let r=e(t);return n.set(r),{written:r.byteLength}}}var Zn;(function(e){e[e.Varint=0]="Varint",e[e.Bit64=1]="Bit64",e[e.LengthDelimited=2]="LengthDelimited",e[e.StartGroup=3]="StartGroup",e[e.EndGroup=4]="EndGroup",e[e.Bit32=5]="Bit32"})(Zn||(Zn={}));var Fj=340282346638528860000000000000000000000,Cj=-340282346638528860000000000000000000000,Mj=4294967295,Lj=2147483647,qj=-2147483648;class Uj{constructor(e){this.stackPos=[],this.encodeUtf8Into=e?Aj(e):Cv().encodeUtf8Into,this.buffer=hre,this.viewCache=Rqe,this.pos=0}ensureCapacity(e){let t=this.pos+e;if(t>this.buffer.length){let n=this.buffer.length||Aqe;while(n0)r.set(this.buffer);this.buffer=r}}view(){let e=this.buffer,t=this.viewCache;if(t.byteLength===e.byteLength)return t;let n=new DataView(e.buffer);return this.viewCache=n,n}finish(){let e=this.buffer.slice(0,this.pos);return this.pos=0,this.stackPos=[],e}fork(){return this.stackPos.push(this.pos),this.ensureCapacity(Mv),this.buffer[this.pos++]=0,this}join(){let e=this.stackPos.pop();if(e===void 0)throw Error("invalid state, fork stack empty");let t=this.pos-e-Mv,n=Rj(t);if(n>Mv)this.ensureCapacity(n-Mv),this.buffer.copyWithin(e+n,e+Mv,this.pos);return this.pos=e,this.uint32(t),this.pos+=t,this}tag(e,t){return this.uint32((e<<3|t)>>>0)}raw(e){return this.ensureCapacity(e.length),this.buffer.set(e,this.pos),this.pos+=e.length,this}uint32(e){if(yre(e),this.ensureCapacity(5),e<128)return this.buffer[this.pos++]=e,this;while(e>127)this.buffer[this.pos++]=e&127|128,e>>>=7;return this.buffer[this.pos++]=e,this}int32(e){if(jj(e),e>=0)return this.uint32(e);this.ensureCapacity(10);for(let t=0;t<9;t++)this.buffer[this.pos++]=e&127|128,e>>=7;return this.buffer[this.pos++]=1,this}bool(e){return this.ensureCapacity(1),this.buffer[this.pos++]=e?1:0,this}bytes(e){return this.uint32(e.byteLength),this.raw(e)}string(e){if(typeof e!=="string")e=String(e);let t=e.length;if(t<=gre){this.ensureCapacity(t+1);let a=this.buffer,l=this.pos;a[l++]=t;let c=0;for(;c127)break;a[l++]=u}if(c==t)return this.pos=l,this}this.ensureCapacity(t*3+5);let n=Rj(t),r=this.buffer,i=this.pos,{written:s}=this.encodeUtf8Into(e,r.subarray(i+n)),o=Rj(s);if(o!=n)r.copyWithin(i+o,i+n,i+n+s);return this.uint32(s),this.pos+=s,this}float(e){return jqe(e),this.ensureCapacity(4),this.view().setFloat32(this.pos,e,!0),this.pos+=4,this}double(e){return this.ensureCapacity(8),this.view().setFloat64(this.pos,e,!0),this.pos+=8,this}fixed32(e){return yre(e),this.ensureCapacity(4),this.view().setUint32(this.pos,e,!0),this.pos+=4,this}sfixed32(e){return jj(e),this.ensureCapacity(4),this.view().setInt32(this.pos,e,!0),this.pos+=4,this}sint32(e){return jj(e),this.uint32((e<<1^e>>31)>>>0)}sfixed64(e){let t=Sn.enc(e);this.ensureCapacity(8);let n=this.view();return n.setInt32(this.pos,t.lo,!0),n.setInt32(this.pos+4,t.hi,!0),this.pos+=8,this}fixed64(e){let t=Sn.uEnc(e);this.ensureCapacity(8);let n=this.view();return n.setInt32(this.pos,t.lo,!0),n.setInt32(this.pos+4,t.hi,!0),this.pos+=8,this}int64(e){let t=Sn.enc(e);return this.writeVarint64(t.lo,t.hi)}sint64(e){let t=Sn.enc(e),n=t.hi>>31,r=t.lo<<1^n,i=(t.hi<<1|t.lo>>>31)^n;return this.writeVarint64(r,i)}uint64(e){let t=Sn.uEnc(e);return this.writeVarint64(t.lo,t.hi)}writeVarint64(e,t){this.ensureCapacity(10);let n=this.buffer,r=this.pos;for(let o=0;o<28;o=o+7){let a=e>>>o,l=!(a>>>7==0&&t==0);if(n[r++]=(l?a|128:a)&255,!l)return this.pos=r,this}let i=e>>>28&15|(t&7)<<4,s=t>>3!=0;if(n[r++]=(s?i|128:i)&255,!s)return this.pos=r,this;for(let o=3;o<31;o=o+7){let a=t>>>o,l=a>>>7!=0;if(n[r++]=(l?a|128:a)&255,!l)return this.pos=r,this}return n[r++]=t>>>31&1,this.pos=r,this}}var Aqe=128,Mv=1,hre=new Uint8Array(0),Rqe=new DataView(hre.buffer),gre=32;function Rj(e){if(e<128)return 1;if(e<16384)return 2;if(e<2097152)return 3;if(e<268435456)return 4;return 5}class Bj{constructor(e,t=Cv().decodeUtf8){this.decodeUtf8=t,this.varint64Lo=0,this.varint64Hi=0,this.varint64=Hne,this.uint32=Yne,this.buf=e,this.len=e.length,this.pos=0,this.view=new DataView(e.buffer,e.byteOffset,e.byteLength)}tag(){let e=this.pos,t=this.uint32(),n=this.pos-e;if(n>5||n==5&&this.buf[this.pos-1]>15)throw Error("illegal tag: varint overflows uint32");let r=t>>>3,i=t&7;if(r<=0||i>5)throw Error("illegal tag: field no "+r+" wire type "+i);return[r,i]}skip(e,t,n=100){let r=this.pos;switch(e){case Zn.Varint:while(this.buf[this.pos++]&128);break;case Zn.Bit64:this.pos+=4;case Zn.Bit32:this.pos+=4;break;case Zn.LengthDelimited:let i=this.uint32();this.pos+=i;break;case Zn.StartGroup:if(n<=0)throw Error("maximum recursion depth reached");for(;;){let[s,o]=this.tag();if(o===Zn.EndGroup){if(t!==void 0&&s!==t)throw Error("invalid end group tag");break}this.skip(o,s,n-1)}break;default:throw Error("cant skip wire type "+e)}return this.assertBounds(),this.buf.subarray(r,this.pos)}assertBounds(){if(this.pos>this.len)throw RangeError("premature EOF")}int32(){return this.uint32()|0}sint32(){let e=this.uint32();return e>>>1^-(e&1)}int64(){return this.varint64(),Sn.dec(this.varint64Lo,this.varint64Hi)}uint64(){return this.varint64(),Sn.uDec(this.varint64Lo,this.varint64Hi)}sint64(){this.varint64();let e=this.varint64Lo,t=this.varint64Hi,n=-(e&1);return e=(e>>>1|(t&1)<<31)^n,t=t>>>1^n,Sn.dec(e,t)}bool(){let e=this.buf[this.pos];if(e<128)return this.pos++,e!==0;return this.varint64(),this.varint64Lo!==0||this.varint64Hi!==0}fixed32(){return this.view.getUint32((this.pos+=4)-4,!0)}sfixed32(){return this.view.getInt32((this.pos+=4)-4,!0)}fixed64(){return Sn.uDec(this.sfixed32(),this.sfixed32())}sfixed64(){return Sn.dec(this.sfixed32(),this.sfixed32())}float(){return this.view.getFloat32((this.pos+=4)-4,!0)}double(){return this.view.getFloat64((this.pos+=8)-8,!0)}bytes(){let e=this.uint32(),t=this.pos;return this.pos+=e,this.assertBounds(),this.buf.subarray(t,t+e)}string(e){let t=this.bytes(),n=t.length;if(n<=gre){let r=Array(n);for(let i=0;i127)return this.decodeUtf8(t,e);r[i]=s}return String.fromCharCode.apply(String,r)}return this.decodeUtf8(t,e)}}function jj(e){if(typeof e=="string")e=Number(e);else if(typeof e!="number")throw Error("invalid int32: "+typeof e);if(!Number.isInteger(e)||e>Lj||eMj||e<0)throw Error("invalid uint32: "+e)}function jqe(e){if(typeof e=="string"){let t=e;if(e=Number(e),Number.isNaN(e)&&t!=="NaN")throw Error("invalid float32: "+t)}else if(typeof e!="number")throw Error("invalid float32: "+typeof e);if(Number.isFinite(e)&&(e>Fj||en.number===t)}return jv(t,e.message)}function Vj(e){switch(e){case ie.DOUBLE:return(t)=>typeof t=="number";case ie.FLOAT:return(t)=>{if(typeof t!="number")return!1;if(Number.isNaN(t)||!Number.isFinite(t))return!0;if(t>Fj||t{if(typeof t!=="number"||!Number.isInteger(t))return!1;if(t>Lj||t{if(typeof t!=="number"||!Number.isInteger(t))return!1;if(t>Mj||t<0)return`${t.toFixed()} out of range`;return!0};case ie.BOOL:return(t)=>typeof t=="boolean";case ie.STRING:return(t)=>{if(typeof t!="string")return!1;return Cv().checkUtf8(t)||"invalid UTF8"};case ie.BYTES:return(t)=>t instanceof Uint8Array;case ie.INT64:case ie.SFIXED64:case ie.SINT64:return(t)=>{if(typeof t=="bigint"||typeof t=="number"||typeof t=="string"&&t.length>0)try{return Sn.parse(t),!0}catch(n){return`${t} out of range`}return!1};case ie.FIXED64:case ie.UINT64:return(t)=>{if(typeof t=="bigint"||typeof t=="number"||typeof t=="string"&&t.length>0)try{return Sn.uParse(t),!0}catch(n){return`${t} out of range`}return!1}}}function cS(e,t,n){if(n=typeof n=="string"?`: ${n}`:`, got ${uS(t)}`,e.scalar!==void 0)return`expected ${Fqe(e.scalar)}`+n;if(e.enum!==void 0)return`expected ${e.enum.toString()}`+n;return`expected ${_re(e.message)}`+n}function uS(e){switch(typeof e){case"object":if(e===null)return"null";if(e instanceof Uint8Array)return`Uint8Array(${e.length})`;if(Array.isArray(e))return`Array(${e.length})`;if(Av(e))return xre(e.field());if(Rv(e))return wre(e.field());if(jv(e))return _re(e.desc);if(Iv(e))return`message ${e.$typeName}`;return"object";case"string":return e.length>30?"string":`"${e.split('"').join("\\\"")}"`;case"boolean":return String(e);case"number":return String(e);case"bigint":return String(e)+"n";default:return typeof e}}function _re(e){return`ReflectMessage (${e.typeName})`}function xre(e){switch(e.listKind){case"message":return`ReflectList (${e.message.toString()})`;case"enum":return`ReflectList (${e.enum.toString()})`;case"scalar":return`ReflectList (${ie[e.scalar]})`}}function wre(e){switch(e.mapKind){case"message":return`ReflectMap (${ie[e.mapKey]}, ${e.message.toString()})`;case"enum":return`ReflectMap (${ie[e.mapKey]}, ${e.enum.toString()})`;case"scalar":return`ReflectMap (${ie[e.mapKey]}, ${ie[e.scalar]})`}}function Fqe(e){switch(e){case ie.STRING:return"string";case ie.BOOL:return"boolean";case ie.INT64:case ie.SINT64:case ie.SFIXED64:return"bigint (int64)";case ie.UINT64:case ie.FIXED64:return"bigint (uint64)";case ie.BYTES:return"Uint8Array";case ie.DOUBLE:return"number (float64)";case ie.FLOAT:return"number (float32)";case ie.FIXED32:case ie.UINT32:return"number (uint32)";case ie.INT32:case ie.SFIXED32:case ie.SINT32:return"number (int32)"}}var Cqe=0;function fp(e){if(Mqe(e))return{toMessage:(n)=>pS(n),toLocal:(n)=>dS(n)};if(e.fieldKind=="message"&&!e.oneof&&Cy(e.message)){let n=e.message,r=n.fields[0].localName;return{toMessage:(i)=>{let s=cf(n);if(i!==void 0)s[r]=i;return s},toLocal:(i)=>i[r]}}let t=e.message;return{toMessage:(n)=>n===void 0?cf(t):n,toLocal:(n)=>n}}function Mqe(e){return e.message.typeName=="google.protobuf.Struct"&&e.parent.typeName!="google.protobuf.Value"}function pS(e){let t={$typeName:"google.protobuf.Struct",fields:{}};if(ja(e))for(let n of Object.keys(e))t.fields[n]=Tre(e[n]);return t}function dS(e){let t={};for(let n of Object.keys(e.fields))t[n]=Dre(e.fields[n]);return t}function Dre(e){switch(e.kind.case){case"structValue":return dS(e.kind.value);case"listValue":return e.kind.value.values.map(Dre);case"nullValue":case void 0:return null;default:return e.kind.value}}function Tre(e){let t={$typeName:"google.protobuf.Value",kind:{case:void 0}};switch(typeof e){case"number":t.kind={case:"numberValue",value:e};break;case"string":t.kind={case:"stringValue",value:e};break;case"boolean":t.kind={case:"boolValue",value:e};break;case"object":if(e===null)t.kind={case:"nullValue",value:Cqe};else if(Array.isArray(e)){let n={$typeName:"google.protobuf.ListValue",values:[]};if(Array.isArray(e))for(let r of e)n.values.push(Tre(r));t.kind={case:"listValue",value:n}}else t.kind={case:"structValue",value:pS(e)};break}return t}function Nre(e,t,n=!0){return new zj(e,t,n)}var Sre=new WeakMap;class zj{get sortedFields(){let e=Sre.get(this.desc);if(e)return e;let t=this.desc.fields.concat().sort((n,r)=>n.number-r.number);return Sre.set(this.desc,t),t}constructor(e,t,n=!0){this.lists=new Map,this.maps=new Map,this.check=n,this.desc=e,this.message=this[Ra]=t!==null&&t!==void 0?t:cf(e),this.fields=e.fields,this.oneofs=e.oneofs,this.members=e.members}findNumber(e){if(!this._fieldsByNumber)this._fieldsByNumber=new Map(this.desc.fields.map((t)=>[t.number,t]));return this._fieldsByNumber.get(e)}oneofCase(e){return Lv(this.message,e),nre(this.message,e)}isSet(e){return Lv(this.message,e),rre(this.message,e)}clear(e){Lv(this.message,e),ore(this.message,e)}get(e){Lv(this.message,e);let t=ire(this.message,e);switch(e.fieldKind){case"list":let n=this.lists.get(e);if(!n||n[Ra]!==t)this.lists.set(e,n=new Wj(e,t,this.check));return n;case"map":let r=this.maps.get(e);if(!r||r[Ra]!==t)this.maps.set(e,r=new Pre(e,t,this.check));return r;case"message":return Yj(e,t,this.check);case"scalar":return t===void 0?$c(e.scalar,!1):Xj(e,t);case"enum":return t!==null&&t!==void 0?t:e.enum.values[0].number}}set(e,t){if(Lv(this.message,e),this.check){let r=bre(e,t);if(r)throw r}let n;if(e.fieldKind=="message")n=Qj(e,t);else if(Rv(t)||Av(t))n=t[Ra];else n=Zj(e,t);sre(this.message,e,n)}getUnknown(){return this.message.$unknown}setUnknown(e){this.message.$unknown=e}}function Lv(e,t){if(t.parent.typeName!==e.$typeName)throw new Fa(t,`cannot use ${t.toString()} with message ${e.$typeName}`,"ForeignFieldError")}function Ore(e,t,n=!0){return new Wj(e,t!==null&&t!==void 0?t:[],n)}class Wj{field(){return this._field}get size(){return this._arr.length}constructor(e,t,n){this._field=e,this._arr=this[Ra]=t,this.check=n}get(e){let t=this._arr[e];return t===void 0?void 0:Gj(this._field,t,this.check)}set(e,t){if(e<0||e>=this._arr.length)throw new Fa(this._field,`list item #${e+1}: out of range`);if(this.check){let n=Kj(this._field,e,t);if(n)throw n}this._arr[e]=Ere(this._field,t)}add(e){if(this.check){let t=Kj(this._field,this._arr.length,e);if(t)throw t}this._arr.push(Ere(this._field,e));return}clear(){this._arr.splice(0,this._arr.length)}[Symbol.iterator](){return this.values()}keys(){return this._arr.keys()}*values(){for(let e of this._arr)yield Gj(this._field,e,this.check)}*entries(){for(let e=0;er.name===t);if(!n)throw Error(`cannot parse ${e} default value: ${t}`);return n.number}function Ire(e,t){switch(e){case ie.STRING:return t;case ie.BYTES:{let n=Uqe(t);if(n===!1)throw Error(`cannot parse ${ie[e]} default value: ${t}`);return n}case ie.INT64:case ie.SFIXED64:case ie.SINT64:return Sn.parse(t);case ie.UINT64:case ie.FIXED64:return Sn.uParse(t);case ie.DOUBLE:case ie.FLOAT:switch(t){case"inf":return Number.POSITIVE_INFINITY;case"-inf":return Number.NEGATIVE_INFINITY;case"nan":return Number.NaN;default:return parseFloat(t)}case ie.BOOL:return t==="true";case ie.INT32:case ie.UINT32:case ie.SINT32:case ie.FIXED32:case ie.SFIXED32:return parseInt(t,10)}}function Uqe(e){let t=[],n={tail:e,c:"",next(){if(this.tail.length==0)return!1;return this.c=this.tail[0],this.tail=this.tail.substring(1),!0},take(r){if(this.tail.length>=r){let i=this.tail.substring(0,r);return this.tail=this.tail.substring(r),i}return!1}};while(n.next())switch(n.c){case"\\":if(n.next())switch(n.c){case"\\":t.push(n.c.charCodeAt(0));break;case"b":t.push(8);break;case"f":t.push(12);break;case"n":t.push(10);break;case"r":t.push(13);break;case"t":t.push(9);break;case"v":t.push(11);break;case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":{let r=n.c,i=n.take(2);if(i===!1)return!1;let s=parseInt(r+i,8);if(Number.isNaN(s))return!1;t.push(s);break}case"x":{let r=n.c,i=n.take(2);if(i===!1)return!1;let s=parseInt(r+i,16);if(Number.isNaN(s))return!1;t.push(s);break}case"u":{let r=n.c,i=n.take(4);if(i===!1)return!1;let s=parseInt(r+i,16);if(Number.isNaN(s))return!1;let o=new Uint8Array(4);new DataView(o.buffer).setInt32(0,s,!0),t.push(o[0],o[1],o[2],o[3]);break}case"U":{let r=n.c,i=n.take(8);if(i===!1)return!1;let s=Sn.uEnc(r+i),o=new Uint8Array(8),a=new DataView(o.buffer);a.setInt32(0,s.lo,!0),a.setInt32(4,s.hi,!0),t.push(o[0],o[1],o[2],o[3],o[4],o[5],o[6],o[7]);break}}break;default:t.push(n.c.charCodeAt(0))}return new Uint8Array(t)}function*mS(e){switch(e.kind){case"file":for(let t of e.messages)yield t,yield*mS(t);yield*e.enums,yield*e.services,yield*e.extensions;break;case"message":for(let t of e.nestedMessages)yield t,yield*mS(t);yield*e.nestedEnums,yield*e.nestedExtensions;break}}function yS(...e){let t=Bqe();if(!e.length)return t;if("$typeName"in e[0]&&e[0].$typeName=="google.protobuf.FileDescriptorSet"){for(let n of e[0].file)Fre(n,t);return t}if("$typeName"in e[0]){let s=function(o){let a=[];for(let l of o.dependency){if(t.getFile(l)!=null)continue;if(i.has(l))continue;let c=r(l);if(!c)throw Error(`Unable to resolve ${l}, imported by ${o.name}`);if("kind"in c)t.addFile(c,!1,!0);else i.add(c.name),a.push(c)}return a.concat(...a.map(s))},n=e[0],r=e[1],i=new Set;for(let o of[n,...s(n)].reverse())Fre(o,t)}else for(let n of e)for(let r of n.files)t.addFile(r);return t}function Bqe(){let e=new Map,t=new Map,n=new Map;return{kind:"registry",types:e,extendees:t,[Symbol.iterator](){return e.values()},get files(){return n.values()},addFile(r,i,s){if(n.set(r.proto.name,r),!i)for(let o of mS(r))this.add(o);if(s)for(let o of r.dependencies)this.addFile(o,i,s)},add(r){if(r.kind=="extension"){let i=t.get(r.extendee.typeName);if(!i)t.set(r.extendee.typeName,i=new Map);i.set(r.number,r)}e.set(r.typeName,r)},get(r){return e.get(r)},getFile(r){return n.get(r)},getMessage(r){let i=e.get(r);return(i===null||i===void 0?void 0:i.kind)=="message"?i:void 0},getEnum(r){let i=e.get(r);return(i===null||i===void 0?void 0:i.kind)=="enum"?i:void 0},getExtension(r){let i=e.get(r);return(i===null||i===void 0?void 0:i.kind)=="extension"?i:void 0},getExtensionFor(r,i){var s;return(s=t.get(r.typeName))===null||s===void 0?void 0:s.get(i)},getService(r){let i=e.get(r);return(i===null||i===void 0?void 0:i.kind)=="service"?i:void 0}}}var Vqe=998,Kqe=999,Jqe=9999,Gqe=9,Uv=10,qv=11,Hqe=12,Are=14,sF=3,zqe=2,Rre=1,Wqe=0,tF=1,jre=2,Qqe=3,Yqe=1,Xqe=2,Zqe=1,eUe=2;var tUe=1001,Mre={998:{fieldPresence:1,enumType:2,repeatedFieldEncoding:2,utf8Validation:3,messageEncoding:1,jsonFormat:2,enforceNamingStyle:2,defaultSymbolVisibility:1},999:{fieldPresence:2,enumType:1,repeatedFieldEncoding:1,utf8Validation:2,messageEncoding:1,jsonFormat:1,enforceNamingStyle:2,defaultSymbolVisibility:1},1000:{fieldPresence:1,enumType:1,repeatedFieldEncoding:1,utf8Validation:2,messageEncoding:1,jsonFormat:1,enforceNamingStyle:2,defaultSymbolVisibility:1},1001:{fieldPresence:1,enumType:1,repeatedFieldEncoding:1,utf8Validation:2,messageEncoding:1,jsonFormat:1,enforceNamingStyle:1,defaultSymbolVisibility:2}};function Fre(e,t){var n,r;let i={kind:"file",proto:e,deprecated:(r=(n=e.options)===null||n===void 0?void 0:n.deprecated)!==null&&r!==void 0?r:!1,edition:sUe(e),name:e.name.replace(/\.proto$/,""),dependencies:oUe(e,t),enums:[],messages:[],extensions:[],services:[],toString(){return`file ${e.name}`}},s=new Map,o={get(a){return s.get(a)},add(a){var l;Ca(((l=a.proto.options)===null||l===void 0?void 0:l.mapEntry)===!0),s.set(a.typeName,a)}};for(let a of e.enumType)Lre(a,i,void 0,t);for(let a of e.messageType)qre(a,i,void 0,t,o);for(let a of e.service)nUe(a,i,t);nF(i,t);for(let a of s.values())rF(a,t,o);for(let a of i.messages)rF(a,t,o),nF(a,t);t.addFile(i,!0)}function nF(e,t){switch(e.kind){case"file":for(let n of e.proto.extension){let r=iF(n,e,t);e.extensions.push(r),t.add(r)}break;case"message":for(let n of e.proto.extension){let r=iF(n,e,t);e.nestedExtensions.push(r),t.add(r)}for(let n of e.nestedMessages)nF(n,t);break}}function rF(e,t,n){let r=e.proto.oneofDecl.map((s)=>iUe(s,e)),i=new Set;for(let s of e.proto.field){let o=cUe(s,r),a=iF(s,e,t,o,n);if(e.fields.push(a),e.field[a.localName]=a,o===void 0)e.members.push(a);else if(o.fields.push(a),!i.has(o))i.add(o),e.members.push(o)}for(let s of r.filter((o)=>i.has(o)))e.oneofs.push(s);for(let s of e.nestedMessages)rF(s,t,n)}function Lre(e,t,n,r){var i,s,o,a,l;let c=aUe(e.name,e.value),u={kind:"enum",proto:e,deprecated:(s=(i=e.options)===null||i===void 0?void 0:i.deprecated)!==null&&s!==void 0?s:!1,file:t,parent:n,open:!0,name:e.name,typeName:hS(e,n,t),value:{},values:[],sharedPrefix:c,toString(){return`enum ${this.typeName}`}};u.open=fUe(u),r.add(u);for(let p of e.value){let d=p.name;u.values.push(u.value[p.number]={kind:"enum_value",proto:p,deprecated:(a=(o=p.options)===null||o===void 0?void 0:o.deprecated)!==null&&a!==void 0?a:!1,parent:u,name:d,localName:Ly(c==null?d:d.substring(c.length)),number:p.number,toString(){return`enum value ${u.typeName}.${d}`}})}((l=n===null||n===void 0?void 0:n.nestedEnums)!==null&&l!==void 0?l:t.enums).push(u)}function qre(e,t,n,r,i){var s,o,a,l;let c={kind:"message",proto:e,deprecated:(o=(s=e.options)===null||s===void 0?void 0:s.deprecated)!==null&&o!==void 0?o:!1,file:t,parent:n,name:e.name,typeName:hS(e,n,t),fields:[],field:{},oneofs:[],members:[],nestedEnums:[],nestedMessages:[],nestedExtensions:[],toString(){return`message ${this.typeName}`}};if(((a=e.options)===null||a===void 0?void 0:a.mapEntry)===!0)i.add(c);else((l=n===null||n===void 0?void 0:n.nestedMessages)!==null&&l!==void 0?l:t.messages).push(c),r.add(c);for(let u of e.enumType)Lre(u,t,c,r);for(let u of e.nestedType)qre(u,t,c,r,i)}function nUe(e,t,n){var r,i;let s={kind:"service",proto:e,deprecated:(i=(r=e.options)===null||r===void 0?void 0:r.deprecated)!==null&&i!==void 0?i:!1,file:t,name:e.name,typeName:hS(e,void 0,t),methods:[],method:{},toString(){return`service ${this.typeName}`}};t.services.push(s),n.add(s);for(let o of e.method){let a=rUe(o,s,n);s.methods.push(a),s.method[a.localName]=a}}function rUe(e,t,n){var r,i,s,o;let a;if(e.clientStreaming&&e.serverStreaming)a="bidi_streaming";else if(e.clientStreaming)a="client_streaming";else if(e.serverStreaming)a="server_streaming";else a="unary";let l=n.getMessage(Ic(e.inputType)),c=n.getMessage(Ic(e.outputType));Ca(l,`invalid MethodDescriptorProto: input_type ${e.inputType} not found`),Ca(c,`invalid MethodDescriptorProto: output_type ${e.inputType} not found`);let u=e.name;return{kind:"rpc",proto:e,deprecated:(i=(r=e.options)===null||r===void 0?void 0:r.deprecated)!==null&&i!==void 0?i:!1,parent:t,name:u,localName:Ly(u.length?Ly(u[0].toLowerCase()+u.substring(1)):u),methodKind:a,input:l,output:c,idempotency:(o=(s=e.options)===null||s===void 0?void 0:s.idempotencyLevel)!==null&&o!==void 0?o:Wqe,toString(){return`rpc ${t.typeName}.${u}`}}}function iUe(e,t){return{kind:"oneof",proto:e,deprecated:!1,parent:t,fields:[],name:e.name,localName:Ly(My(e.name)),toString(){return`oneof ${t.typeName}.${this.name}`}}}function iF(e,t,n,r,i){var s,o,a;let l=i===void 0,c={kind:"field",proto:e,deprecated:(o=(s=e.options)===null||s===void 0?void 0:s.deprecated)!==null&&o!==void 0?o:!1,name:e.name,number:e.number,scalar:void 0,message:void 0,enum:void 0,presence:uUe(e,r,l,t),utf8Validation:mUe(e,t),listKind:void 0,mapKind:void 0,mapKey:void 0,delimitedEncoding:void 0,packed:void 0,longAsString:!1,getDefaultValue:void 0},u;if(l){let m=t.kind=="file"?t:t.file,y=t.kind=="file"?void 0:t,h=hS(e,y,m);c.kind="extension",c.file=m,c.parent=y,c.oneof=void 0,c.typeName=h,c.jsonName=`[${h}]`,u=()=>`extension ${h}`;let b=n.getMessage(Ic(e.extendee));Ca(b,`invalid FieldDescriptorProto: extendee ${e.extendee} not found`),c.extendee=b}else{let m=t;Ca(m.kind=="message"),c.parent=m,c.oneof=r,c.localName=r?My(e.name):Ly(My(e.name)),c.jsonName=e.jsonName,u=()=>`field ${m.typeName}.${e.name}`}Object.defineProperty(c,"toString",{value:u,writable:!0,enumerable:!0,configurable:!0});let{label:p,type:d}=e,f=(a=e.options)===null||a===void 0?void 0:a.jstype;if(p===sF){let m=d==qv?i===null||i===void 0?void 0:i.get(Ic(e.typeName)):void 0;if(m){c.fieldKind="map";let{key:y,value:h}=dUe(m);return c.mapKey=y.scalar,c.mapKind=h.fieldKind,c.message=h.message,c.delimitedEncoding=!1,c.enum=h.enum,c.scalar=h.scalar,c}switch(c.fieldKind="list",d){case qv:case Uv:c.listKind="message",c.message=n.getMessage(Ic(e.typeName)),Ca(c.message),c.delimitedEncoding=Cre(e,t);break;case Are:c.listKind="enum",c.enum=n.getEnum(Ic(e.typeName)),Ca(c.enum);break;default:c.listKind="scalar",c.scalar=d,c.longAsString=f==Rre;break}return c.packed=pUe(e,t),c}switch(d){case qv:case Uv:c.fieldKind="message",c.message=n.getMessage(Ic(e.typeName)),Ca(c.message,`invalid FieldDescriptorProto: type_name ${e.typeName} not found`),c.delimitedEncoding=Cre(e,t),c.getDefaultValue=()=>{return};break;case Are:{let m=n.getEnum(Ic(e.typeName));Ca(m!==void 0,`invalid FieldDescriptorProto: type_name ${e.typeName} not found`),c.fieldKind="enum",c.enum=n.getEnum(Ic(e.typeName)),c.getDefaultValue=()=>lf(e,"defaultValue")?$re(m,e.defaultValue):void 0;break}default:{c.fieldKind="scalar",c.scalar=d,c.longAsString=f==Rre,c.getDefaultValue=()=>lf(e,"defaultValue")?Ire(d,e.defaultValue):void 0;break}}return c}function sUe(e){switch(e.syntax){case"":case"proto2":return Vqe;case"proto3":return Kqe;case"editions":if(e.edition===Jqe)return tUe;if(e.edition in Mre)return e.edition;throw Error(`${e.name}: unsupported edition`);default:throw Error(`${e.name}: unsupported syntax "${e.syntax}"`)}}function oUe(e,t){return e.dependency.map((n)=>{let r=t.getFile(n);if(!r)throw Error(`Cannot find ${n}, imported by ${e.name}`);return r})}function aUe(e,t){let n=lUe(e)+"_";for(let r of t){if(!r.name.toLowerCase().startsWith(n))return;let i=r.name.substring(n.length);if(i.length==0)return;if(/^\d/.test(i))return}return n}function lUe(e){return(e.substring(0,1)+e.substring(1).replace(/[A-Z]/g,(t)=>"_"+t)).toLowerCase()}function hS(e,t,n){let r;if(t)r=`${t.typeName}.${e.name}`;else if(n.proto.package.length>0)r=`${n.proto.package}.${e.name}`;else r=`${e.name}`;return r}function Ic(e){return e.startsWith(".")?e.substring(1):e}function cUe(e,t){if(!lf(e,"oneofIndex"))return;if(e.proto3Optional)return;let n=t[e.oneofIndex];return Ca(n,`invalid FieldDescriptorProto: oneof #${e.oneofIndex} for field #${e.number} not found`),n}function uUe(e,t,n,r){if(e.label==zqe)return Qqe;if(e.label==sF)return jre;if(!!t||e.proto3Optional)return tF;if(n)return tF;let i=uf("fieldPresence",{proto:e,parent:r});if(i==jre&&(e.type==qv||e.type==Uv))return tF;return i}function pUe(e,t){if(e.label!=sF)return!1;switch(e.type){case Gqe:case Hqe:case Uv:case qv:return!1}let n=e.options;if(n&&lf(n,"packed"))return n.packed;return Yqe==uf("repeatedFieldEncoding",{proto:e,parent:t})}function dUe(e){let t=e.fields.find((r)=>r.number===1),n=e.fields.find((r)=>r.number===2);return Ca(t&&t.fieldKind=="scalar"&&t.scalar!=ie.BYTES&&t.scalar!=ie.FLOAT&&t.scalar!=ie.DOUBLE&&n&&n.fieldKind!="list"&&n.fieldKind!="map"),{key:t,value:n}}function fUe(e){var t;return Zqe==uf("enumType",{proto:e.proto,parent:(t=e.parent)!==null&&t!==void 0?t:e.file})}function Cre(e,t){if(e.type==Uv)return!0;return Xqe==uf("messageEncoding",{proto:e,parent:t})}function mUe(e,t){return eUe==uf("utf8Validation",{proto:e,parent:t})}function uf(e,t){var n,r;let i=(n=t.proto.options)===null||n===void 0?void 0:n.features;if(i){let s=i[e];if(s!=0)return s}if("kind"in t){if(t.kind=="message")return uf(e,(r=t.parent)!==null&&r!==void 0?r:t.file);let s=Mre[t.edition];if(!s)throw Error(`feature default for edition ${t.edition} not found`);return s[e]}return uf(e,t.parent)}function Ca(e,t){if(!e)throw Error(t)}function Ure(e){let t=yUe(e);return t.messageType.forEach(eF),yS(t,()=>{return}).getFile(t.name)}function yUe(e){let t=Object.create({syntax:"",edition:0});return Object.assign(t,Object.assign(Object.assign({$typeName:"google.protobuf.FileDescriptorProto",dependency:[],publicDependency:[],weakDependency:[],optionDependency:[],service:[],extension:[]},e),{messageType:e.messageType.map(Bre),enumType:e.enumType.map(Vre)}))}function Bre(e){var t,n,r,i,s,o,a,l;let c=Object.create({visibility:0});return Object.assign(c,{$typeName:"google.protobuf.DescriptorProto",name:e.name,field:(n=(t=e.field)===null||t===void 0?void 0:t.map(hUe))!==null&&n!==void 0?n:[],extension:[],nestedType:(i=(r=e.nestedType)===null||r===void 0?void 0:r.map(Bre))!==null&&i!==void 0?i:[],enumType:(o=(s=e.enumType)===null||s===void 0?void 0:s.map(Vre))!==null&&o!==void 0?o:[],extensionRange:(l=(a=e.extensionRange)===null||a===void 0?void 0:a.map((u)=>Object.assign({$typeName:"google.protobuf.DescriptorProto.ExtensionRange"},u)))!==null&&l!==void 0?l:[],oneofDecl:[],reservedRange:[],reservedName:[]})}function hUe(e){let t=Object.create({label:1,typeName:"",extendee:"",defaultValue:"",oneofIndex:0,jsonName:"",proto3Optional:!1});return Object.assign(t,Object.assign(Object.assign({$typeName:"google.protobuf.FieldDescriptorProto"},e),{options:e.options?gUe(e.options):void 0}))}function gUe(e){var t,n,r;let i=Object.create({ctype:0,packed:!1,jstype:0,lazy:!1,unverifiedLazy:!1,deprecated:!1,weak:!1,debugRedact:!1,retention:0});return Object.assign(i,Object.assign(Object.assign({$typeName:"google.protobuf.FieldOptions"},e),{targets:(t=e.targets)!==null&&t!==void 0?t:[],editionDefaults:(r=(n=e.editionDefaults)===null||n===void 0?void 0:n.map((s)=>Object.assign({$typeName:"google.protobuf.FieldOptions.EditionDefault"},s)))!==null&&r!==void 0?r:[],uninterpretedOption:[]}))}function Vre(e){let t=Object.create({visibility:0});return Object.assign(t,{$typeName:"google.protobuf.EnumDescriptorProto",name:e.name,reservedName:[],reservedRange:[],value:e.value.map((n)=>Object.assign({$typeName:"google.protobuf.EnumValueDescriptorProto"},n))})}function Kre(e,t,...n){return n.reduce((r,i)=>r.nestedMessages[i],e.messages[t])}var bUe=Ure({name:"google/protobuf/descriptor.proto",package:"google.protobuf",messageType:[{name:"FileDescriptorSet",field:[{name:"file",number:1,type:11,label:3,typeName:".google.protobuf.FileDescriptorProto"}],extensionRange:[{start:536000000,end:536000001}]},{name:"FileDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"package",number:2,type:9,label:1},{name:"dependency",number:3,type:9,label:3},{name:"public_dependency",number:10,type:5,label:3},{name:"weak_dependency",number:11,type:5,label:3},{name:"option_dependency",number:15,type:9,label:3},{name:"message_type",number:4,type:11,label:3,typeName:".google.protobuf.DescriptorProto"},{name:"enum_type",number:5,type:11,label:3,typeName:".google.protobuf.EnumDescriptorProto"},{name:"service",number:6,type:11,label:3,typeName:".google.protobuf.ServiceDescriptorProto"},{name:"extension",number:7,type:11,label:3,typeName:".google.protobuf.FieldDescriptorProto"},{name:"options",number:8,type:11,label:1,typeName:".google.protobuf.FileOptions"},{name:"source_code_info",number:9,type:11,label:1,typeName:".google.protobuf.SourceCodeInfo"},{name:"syntax",number:12,type:9,label:1},{name:"edition",number:14,type:14,label:1,typeName:".google.protobuf.Edition"}]},{name:"DescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"field",number:2,type:11,label:3,typeName:".google.protobuf.FieldDescriptorProto"},{name:"extension",number:6,type:11,label:3,typeName:".google.protobuf.FieldDescriptorProto"},{name:"nested_type",number:3,type:11,label:3,typeName:".google.protobuf.DescriptorProto"},{name:"enum_type",number:4,type:11,label:3,typeName:".google.protobuf.EnumDescriptorProto"},{name:"extension_range",number:5,type:11,label:3,typeName:".google.protobuf.DescriptorProto.ExtensionRange"},{name:"oneof_decl",number:8,type:11,label:3,typeName:".google.protobuf.OneofDescriptorProto"},{name:"options",number:7,type:11,label:1,typeName:".google.protobuf.MessageOptions"},{name:"reserved_range",number:9,type:11,label:3,typeName:".google.protobuf.DescriptorProto.ReservedRange"},{name:"reserved_name",number:10,type:9,label:3},{name:"visibility",number:11,type:14,label:1,typeName:".google.protobuf.SymbolVisibility"}],nestedType:[{name:"ExtensionRange",field:[{name:"start",number:1,type:5,label:1},{name:"end",number:2,type:5,label:1},{name:"options",number:3,type:11,label:1,typeName:".google.protobuf.ExtensionRangeOptions"}]},{name:"ReservedRange",field:[{name:"start",number:1,type:5,label:1},{name:"end",number:2,type:5,label:1}]}]},{name:"ExtensionRangeOptions",field:[{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"},{name:"declaration",number:2,type:11,label:3,typeName:".google.protobuf.ExtensionRangeOptions.Declaration",options:{retention:2}},{name:"features",number:50,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"verification",number:3,type:14,label:1,typeName:".google.protobuf.ExtensionRangeOptions.VerificationState",defaultValue:"UNVERIFIED",options:{retention:2}}],nestedType:[{name:"Declaration",field:[{name:"number",number:1,type:5,label:1},{name:"full_name",number:2,type:9,label:1},{name:"type",number:3,type:9,label:1},{name:"reserved",number:5,type:8,label:1},{name:"repeated",number:6,type:8,label:1}]}],enumType:[{name:"VerificationState",value:[{name:"DECLARATION",number:0},{name:"UNVERIFIED",number:1}]}],extensionRange:[{start:1000,end:536870912}]},{name:"FieldDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"number",number:3,type:5,label:1},{name:"label",number:4,type:14,label:1,typeName:".google.protobuf.FieldDescriptorProto.Label"},{name:"type",number:5,type:14,label:1,typeName:".google.protobuf.FieldDescriptorProto.Type"},{name:"type_name",number:6,type:9,label:1},{name:"extendee",number:2,type:9,label:1},{name:"default_value",number:7,type:9,label:1},{name:"oneof_index",number:9,type:5,label:1},{name:"json_name",number:10,type:9,label:1},{name:"options",number:8,type:11,label:1,typeName:".google.protobuf.FieldOptions"},{name:"proto3_optional",number:17,type:8,label:1}],enumType:[{name:"Type",value:[{name:"TYPE_DOUBLE",number:1},{name:"TYPE_FLOAT",number:2},{name:"TYPE_INT64",number:3},{name:"TYPE_UINT64",number:4},{name:"TYPE_INT32",number:5},{name:"TYPE_FIXED64",number:6},{name:"TYPE_FIXED32",number:7},{name:"TYPE_BOOL",number:8},{name:"TYPE_STRING",number:9},{name:"TYPE_GROUP",number:10},{name:"TYPE_MESSAGE",number:11},{name:"TYPE_BYTES",number:12},{name:"TYPE_UINT32",number:13},{name:"TYPE_ENUM",number:14},{name:"TYPE_SFIXED32",number:15},{name:"TYPE_SFIXED64",number:16},{name:"TYPE_SINT32",number:17},{name:"TYPE_SINT64",number:18}]},{name:"Label",value:[{name:"LABEL_OPTIONAL",number:1},{name:"LABEL_REPEATED",number:3},{name:"LABEL_REQUIRED",number:2}]}]},{name:"OneofDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"options",number:2,type:11,label:1,typeName:".google.protobuf.OneofOptions"}]},{name:"EnumDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"value",number:2,type:11,label:3,typeName:".google.protobuf.EnumValueDescriptorProto"},{name:"options",number:3,type:11,label:1,typeName:".google.protobuf.EnumOptions"},{name:"reserved_range",number:4,type:11,label:3,typeName:".google.protobuf.EnumDescriptorProto.EnumReservedRange"},{name:"reserved_name",number:5,type:9,label:3},{name:"visibility",number:6,type:14,label:1,typeName:".google.protobuf.SymbolVisibility"}],nestedType:[{name:"EnumReservedRange",field:[{name:"start",number:1,type:5,label:1},{name:"end",number:2,type:5,label:1}]}]},{name:"EnumValueDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"number",number:2,type:5,label:1},{name:"options",number:3,type:11,label:1,typeName:".google.protobuf.EnumValueOptions"}]},{name:"ServiceDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"method",number:2,type:11,label:3,typeName:".google.protobuf.MethodDescriptorProto"},{name:"options",number:3,type:11,label:1,typeName:".google.protobuf.ServiceOptions"}]},{name:"MethodDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"input_type",number:2,type:9,label:1},{name:"output_type",number:3,type:9,label:1},{name:"options",number:4,type:11,label:1,typeName:".google.protobuf.MethodOptions"},{name:"client_streaming",number:5,type:8,label:1,defaultValue:"false"},{name:"server_streaming",number:6,type:8,label:1,defaultValue:"false"}]},{name:"FileOptions",field:[{name:"java_package",number:1,type:9,label:1},{name:"java_outer_classname",number:8,type:9,label:1},{name:"java_multiple_files",number:10,type:8,label:1,defaultValue:"false",options:{}},{name:"java_generate_equals_and_hash",number:20,type:8,label:1,options:{deprecated:!0}},{name:"java_string_check_utf8",number:27,type:8,label:1,defaultValue:"false"},{name:"optimize_for",number:9,type:14,label:1,typeName:".google.protobuf.FileOptions.OptimizeMode",defaultValue:"SPEED"},{name:"go_package",number:11,type:9,label:1},{name:"cc_generic_services",number:16,type:8,label:1,defaultValue:"false"},{name:"java_generic_services",number:17,type:8,label:1,defaultValue:"false"},{name:"py_generic_services",number:18,type:8,label:1,defaultValue:"false"},{name:"deprecated",number:23,type:8,label:1,defaultValue:"false"},{name:"cc_enable_arenas",number:31,type:8,label:1,defaultValue:"true"},{name:"objc_class_prefix",number:36,type:9,label:1},{name:"csharp_namespace",number:37,type:9,label:1},{name:"swift_prefix",number:39,type:9,label:1},{name:"php_class_prefix",number:40,type:9,label:1},{name:"php_namespace",number:41,type:9,label:1},{name:"php_metadata_namespace",number:44,type:9,label:1},{name:"ruby_package",number:45,type:9,label:1},{name:"features",number:50,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],enumType:[{name:"OptimizeMode",value:[{name:"SPEED",number:1},{name:"CODE_SIZE",number:2},{name:"LITE_RUNTIME",number:3}]}],extensionRange:[{start:1000,end:536870912}]},{name:"MessageOptions",field:[{name:"message_set_wire_format",number:1,type:8,label:1,defaultValue:"false"},{name:"no_standard_descriptor_accessor",number:2,type:8,label:1,defaultValue:"false"},{name:"deprecated",number:3,type:8,label:1,defaultValue:"false"},{name:"map_entry",number:7,type:8,label:1},{name:"deprecated_legacy_json_field_conflicts",number:11,type:8,label:1,options:{deprecated:!0}},{name:"features",number:12,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],extensionRange:[{start:1000,end:536870912}]},{name:"FieldOptions",field:[{name:"ctype",number:1,type:14,label:1,typeName:".google.protobuf.FieldOptions.CType",defaultValue:"STRING"},{name:"packed",number:2,type:8,label:1},{name:"jstype",number:6,type:14,label:1,typeName:".google.protobuf.FieldOptions.JSType",defaultValue:"JS_NORMAL"},{name:"lazy",number:5,type:8,label:1,defaultValue:"false"},{name:"unverified_lazy",number:15,type:8,label:1,defaultValue:"false"},{name:"deprecated",number:3,type:8,label:1,defaultValue:"false"},{name:"weak",number:10,type:8,label:1,defaultValue:"false",options:{deprecated:!0}},{name:"debug_redact",number:16,type:8,label:1,defaultValue:"false"},{name:"retention",number:17,type:14,label:1,typeName:".google.protobuf.FieldOptions.OptionRetention"},{name:"targets",number:19,type:14,label:3,typeName:".google.protobuf.FieldOptions.OptionTargetType"},{name:"edition_defaults",number:20,type:11,label:3,typeName:".google.protobuf.FieldOptions.EditionDefault"},{name:"features",number:21,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"feature_support",number:22,type:11,label:1,typeName:".google.protobuf.FieldOptions.FeatureSupport"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],nestedType:[{name:"EditionDefault",field:[{name:"edition",number:3,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"value",number:2,type:9,label:1}]},{name:"FeatureSupport",field:[{name:"edition_introduced",number:1,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"edition_deprecated",number:2,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"deprecation_warning",number:3,type:9,label:1},{name:"edition_removed",number:4,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"removal_error",number:5,type:9,label:1}]}],enumType:[{name:"CType",value:[{name:"STRING",number:0},{name:"CORD",number:1},{name:"STRING_PIECE",number:2}]},{name:"JSType",value:[{name:"JS_NORMAL",number:0},{name:"JS_STRING",number:1},{name:"JS_NUMBER",number:2}]},{name:"OptionRetention",value:[{name:"RETENTION_UNKNOWN",number:0},{name:"RETENTION_RUNTIME",number:1},{name:"RETENTION_SOURCE",number:2}]},{name:"OptionTargetType",value:[{name:"TARGET_TYPE_UNKNOWN",number:0},{name:"TARGET_TYPE_FILE",number:1},{name:"TARGET_TYPE_EXTENSION_RANGE",number:2},{name:"TARGET_TYPE_MESSAGE",number:3},{name:"TARGET_TYPE_FIELD",number:4},{name:"TARGET_TYPE_ONEOF",number:5},{name:"TARGET_TYPE_ENUM",number:6},{name:"TARGET_TYPE_ENUM_ENTRY",number:7},{name:"TARGET_TYPE_SERVICE",number:8},{name:"TARGET_TYPE_METHOD",number:9}]}],extensionRange:[{start:1000,end:536870912}]},{name:"OneofOptions",field:[{name:"features",number:1,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],extensionRange:[{start:1000,end:536870912}]},{name:"EnumOptions",field:[{name:"allow_alias",number:2,type:8,label:1},{name:"deprecated",number:3,type:8,label:1,defaultValue:"false"},{name:"deprecated_legacy_json_field_conflicts",number:6,type:8,label:1,options:{deprecated:!0}},{name:"features",number:7,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],extensionRange:[{start:1000,end:536870912}]},{name:"EnumValueOptions",field:[{name:"deprecated",number:1,type:8,label:1,defaultValue:"false"},{name:"features",number:2,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"debug_redact",number:3,type:8,label:1,defaultValue:"false"},{name:"feature_support",number:4,type:11,label:1,typeName:".google.protobuf.FieldOptions.FeatureSupport"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],extensionRange:[{start:1000,end:536870912}]},{name:"ServiceOptions",field:[{name:"features",number:34,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"deprecated",number:33,type:8,label:1,defaultValue:"false"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],extensionRange:[{start:1000,end:536870912}]},{name:"MethodOptions",field:[{name:"deprecated",number:33,type:8,label:1,defaultValue:"false"},{name:"idempotency_level",number:34,type:14,label:1,typeName:".google.protobuf.MethodOptions.IdempotencyLevel",defaultValue:"IDEMPOTENCY_UNKNOWN"},{name:"features",number:35,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],enumType:[{name:"IdempotencyLevel",value:[{name:"IDEMPOTENCY_UNKNOWN",number:0},{name:"NO_SIDE_EFFECTS",number:1},{name:"IDEMPOTENT",number:2}]}],extensionRange:[{start:1000,end:536870912}]},{name:"UninterpretedOption",field:[{name:"name",number:2,type:11,label:3,typeName:".google.protobuf.UninterpretedOption.NamePart"},{name:"identifier_value",number:3,type:9,label:1},{name:"positive_int_value",number:4,type:4,label:1},{name:"negative_int_value",number:5,type:3,label:1},{name:"double_value",number:6,type:1,label:1},{name:"string_value",number:7,type:12,label:1},{name:"aggregate_value",number:8,type:9,label:1}],nestedType:[{name:"NamePart",field:[{name:"name_part",number:1,type:9,label:2},{name:"is_extension",number:2,type:8,label:2}]}]},{name:"FeatureSet",field:[{name:"field_presence",number:1,type:14,label:1,typeName:".google.protobuf.FeatureSet.FieldPresence",options:{retention:1,targets:[4,1],editionDefaults:[{value:"EXPLICIT",edition:900},{value:"IMPLICIT",edition:999},{value:"EXPLICIT",edition:1000}]}},{name:"enum_type",number:2,type:14,label:1,typeName:".google.protobuf.FeatureSet.EnumType",options:{retention:1,targets:[6,1],editionDefaults:[{value:"CLOSED",edition:900},{value:"OPEN",edition:999}]}},{name:"repeated_field_encoding",number:3,type:14,label:1,typeName:".google.protobuf.FeatureSet.RepeatedFieldEncoding",options:{retention:1,targets:[4,1],editionDefaults:[{value:"EXPANDED",edition:900},{value:"PACKED",edition:999}]}},{name:"utf8_validation",number:4,type:14,label:1,typeName:".google.protobuf.FeatureSet.Utf8Validation",options:{retention:1,targets:[4,1],editionDefaults:[{value:"NONE",edition:900},{value:"VERIFY",edition:999}]}},{name:"message_encoding",number:5,type:14,label:1,typeName:".google.protobuf.FeatureSet.MessageEncoding",options:{retention:1,targets:[4,1],editionDefaults:[{value:"LENGTH_PREFIXED",edition:900}]}},{name:"json_format",number:6,type:14,label:1,typeName:".google.protobuf.FeatureSet.JsonFormat",options:{retention:1,targets:[3,6,1],editionDefaults:[{value:"LEGACY_BEST_EFFORT",edition:900},{value:"ALLOW",edition:999}]}},{name:"enforce_naming_style",number:7,type:14,label:1,typeName:".google.protobuf.FeatureSet.EnforceNamingStyle",options:{retention:2,targets:[1,2,3,4,5,6,7,8,9],editionDefaults:[{value:"STYLE_LEGACY",edition:900},{value:"STYLE2024",edition:1001}]}},{name:"default_symbol_visibility",number:8,type:14,label:1,typeName:".google.protobuf.FeatureSet.VisibilityFeature.DefaultSymbolVisibility",options:{retention:2,targets:[1],editionDefaults:[{value:"EXPORT_ALL",edition:900},{value:"EXPORT_TOP_LEVEL",edition:1001}]}}],nestedType:[{name:"VisibilityFeature",enumType:[{name:"DefaultSymbolVisibility",value:[{name:"DEFAULT_SYMBOL_VISIBILITY_UNKNOWN",number:0},{name:"EXPORT_ALL",number:1},{name:"EXPORT_TOP_LEVEL",number:2},{name:"LOCAL_ALL",number:3},{name:"STRICT",number:4}]}]}],enumType:[{name:"FieldPresence",value:[{name:"FIELD_PRESENCE_UNKNOWN",number:0},{name:"EXPLICIT",number:1},{name:"IMPLICIT",number:2},{name:"LEGACY_REQUIRED",number:3}]},{name:"EnumType",value:[{name:"ENUM_TYPE_UNKNOWN",number:0},{name:"OPEN",number:1},{name:"CLOSED",number:2}]},{name:"RepeatedFieldEncoding",value:[{name:"REPEATED_FIELD_ENCODING_UNKNOWN",number:0},{name:"PACKED",number:1},{name:"EXPANDED",number:2}]},{name:"Utf8Validation",value:[{name:"UTF8_VALIDATION_UNKNOWN",number:0},{name:"VERIFY",number:2},{name:"NONE",number:3}]},{name:"MessageEncoding",value:[{name:"MESSAGE_ENCODING_UNKNOWN",number:0},{name:"LENGTH_PREFIXED",number:1},{name:"DELIMITED",number:2}]},{name:"JsonFormat",value:[{name:"JSON_FORMAT_UNKNOWN",number:0},{name:"ALLOW",number:1},{name:"LEGACY_BEST_EFFORT",number:2}]},{name:"EnforceNamingStyle",value:[{name:"ENFORCE_NAMING_STYLE_UNKNOWN",number:0},{name:"STYLE2024",number:1},{name:"STYLE_LEGACY",number:2}]}],extensionRange:[{start:1000,end:9995},{start:9995,end:1e4},{start:1e4,end:10001}]},{name:"FeatureSetDefaults",field:[{name:"defaults",number:1,type:11,label:3,typeName:".google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault"},{name:"minimum_edition",number:4,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"maximum_edition",number:5,type:14,label:1,typeName:".google.protobuf.Edition"}],nestedType:[{name:"FeatureSetEditionDefault",field:[{name:"edition",number:3,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"overridable_features",number:4,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"fixed_features",number:5,type:11,label:1,typeName:".google.protobuf.FeatureSet"}]}]},{name:"SourceCodeInfo",field:[{name:"location",number:1,type:11,label:3,typeName:".google.protobuf.SourceCodeInfo.Location"}],nestedType:[{name:"Location",field:[{name:"path",number:1,type:5,label:3,options:{packed:!0}},{name:"span",number:2,type:5,label:3,options:{packed:!0}},{name:"leading_comments",number:3,type:9,label:1},{name:"trailing_comments",number:4,type:9,label:1},{name:"leading_detached_comments",number:6,type:9,label:3}]}],extensionRange:[{start:536000000,end:536000001}]},{name:"GeneratedCodeInfo",field:[{name:"annotation",number:1,type:11,label:3,typeName:".google.protobuf.GeneratedCodeInfo.Annotation"}],nestedType:[{name:"Annotation",field:[{name:"path",number:1,type:5,label:3,options:{packed:!0}},{name:"source_file",number:2,type:9,label:1},{name:"begin",number:3,type:5,label:1},{name:"end",number:4,type:5,label:1},{name:"semantic",number:5,type:14,label:1,typeName:".google.protobuf.GeneratedCodeInfo.Annotation.Semantic"}],enumType:[{name:"Semantic",value:[{name:"NONE",number:0},{name:"SET",number:1},{name:"ALIAS",number:2}]}]}]}],enumType:[{name:"Edition",value:[{name:"EDITION_UNKNOWN",number:0},{name:"EDITION_LEGACY",number:900},{name:"EDITION_PROTO2",number:998},{name:"EDITION_PROTO3",number:999},{name:"EDITION_2023",number:1000},{name:"EDITION_2024",number:1001},{name:"EDITION_UNSTABLE",number:9999},{name:"EDITION_1_TEST_ONLY",number:1},{name:"EDITION_2_TEST_ONLY",number:2},{name:"EDITION_99997_TEST_ONLY",number:99997},{name:"EDITION_99998_TEST_ONLY",number:99998},{name:"EDITION_99999_TEST_ONLY",number:99999},{name:"EDITION_MAX",number:2147483647}]},{name:"SymbolVisibility",value:[{name:"VISIBILITY_UNSET",number:0},{name:"VISIBILITY_LOCAL",number:1},{name:"VISIBILITY_EXPORT",number:2}]}]}),gS=Kre(bUe,0);var Jre;(function(e){e[e.DECLARATION=0]="DECLARATION",e[e.UNVERIFIED=1]="UNVERIFIED"})(Jre||(Jre={}));var Gre;(function(e){e[e.DOUBLE=1]="DOUBLE",e[e.FLOAT=2]="FLOAT",e[e.INT64=3]="INT64",e[e.UINT64=4]="UINT64",e[e.INT32=5]="INT32",e[e.FIXED64=6]="FIXED64",e[e.FIXED32=7]="FIXED32",e[e.BOOL=8]="BOOL",e[e.STRING=9]="STRING",e[e.GROUP=10]="GROUP",e[e.MESSAGE=11]="MESSAGE",e[e.BYTES=12]="BYTES",e[e.UINT32=13]="UINT32",e[e.ENUM=14]="ENUM",e[e.SFIXED32=15]="SFIXED32",e[e.SFIXED64=16]="SFIXED64",e[e.SINT32=17]="SINT32",e[e.SINT64=18]="SINT64"})(Gre||(Gre={}));var Hre;(function(e){e[e.OPTIONAL=1]="OPTIONAL",e[e.REPEATED=3]="REPEATED",e[e.REQUIRED=2]="REQUIRED"})(Hre||(Hre={}));var zre;(function(e){e[e.SPEED=1]="SPEED",e[e.CODE_SIZE=2]="CODE_SIZE",e[e.LITE_RUNTIME=3]="LITE_RUNTIME"})(zre||(zre={}));var Wre;(function(e){e[e.STRING=0]="STRING",e[e.CORD=1]="CORD",e[e.STRING_PIECE=2]="STRING_PIECE"})(Wre||(Wre={}));var Qre;(function(e){e[e.JS_NORMAL=0]="JS_NORMAL",e[e.JS_STRING=1]="JS_STRING",e[e.JS_NUMBER=2]="JS_NUMBER"})(Qre||(Qre={}));var Yre;(function(e){e[e.RETENTION_UNKNOWN=0]="RETENTION_UNKNOWN",e[e.RETENTION_RUNTIME=1]="RETENTION_RUNTIME",e[e.RETENTION_SOURCE=2]="RETENTION_SOURCE"})(Yre||(Yre={}));var Xre;(function(e){e[e.TARGET_TYPE_UNKNOWN=0]="TARGET_TYPE_UNKNOWN",e[e.TARGET_TYPE_FILE=1]="TARGET_TYPE_FILE",e[e.TARGET_TYPE_EXTENSION_RANGE=2]="TARGET_TYPE_EXTENSION_RANGE",e[e.TARGET_TYPE_MESSAGE=3]="TARGET_TYPE_MESSAGE",e[e.TARGET_TYPE_FIELD=4]="TARGET_TYPE_FIELD",e[e.TARGET_TYPE_ONEOF=5]="TARGET_TYPE_ONEOF",e[e.TARGET_TYPE_ENUM=6]="TARGET_TYPE_ENUM",e[e.TARGET_TYPE_ENUM_ENTRY=7]="TARGET_TYPE_ENUM_ENTRY",e[e.TARGET_TYPE_SERVICE=8]="TARGET_TYPE_SERVICE",e[e.TARGET_TYPE_METHOD=9]="TARGET_TYPE_METHOD"})(Xre||(Xre={}));var Zre;(function(e){e[e.IDEMPOTENCY_UNKNOWN=0]="IDEMPOTENCY_UNKNOWN",e[e.NO_SIDE_EFFECTS=1]="NO_SIDE_EFFECTS",e[e.IDEMPOTENT=2]="IDEMPOTENT"})(Zre||(Zre={}));var eie;(function(e){e[e.DEFAULT_SYMBOL_VISIBILITY_UNKNOWN=0]="DEFAULT_SYMBOL_VISIBILITY_UNKNOWN",e[e.EXPORT_ALL=1]="EXPORT_ALL",e[e.EXPORT_TOP_LEVEL=2]="EXPORT_TOP_LEVEL",e[e.LOCAL_ALL=3]="LOCAL_ALL",e[e.STRICT=4]="STRICT"})(eie||(eie={}));var tie;(function(e){e[e.FIELD_PRESENCE_UNKNOWN=0]="FIELD_PRESENCE_UNKNOWN",e[e.EXPLICIT=1]="EXPLICIT",e[e.IMPLICIT=2]="IMPLICIT",e[e.LEGACY_REQUIRED=3]="LEGACY_REQUIRED"})(tie||(tie={}));var nie;(function(e){e[e.ENUM_TYPE_UNKNOWN=0]="ENUM_TYPE_UNKNOWN",e[e.OPEN=1]="OPEN",e[e.CLOSED=2]="CLOSED"})(nie||(nie={}));var rie;(function(e){e[e.REPEATED_FIELD_ENCODING_UNKNOWN=0]="REPEATED_FIELD_ENCODING_UNKNOWN",e[e.PACKED=1]="PACKED",e[e.EXPANDED=2]="EXPANDED"})(rie||(rie={}));var iie;(function(e){e[e.UTF8_VALIDATION_UNKNOWN=0]="UTF8_VALIDATION_UNKNOWN",e[e.VERIFY=2]="VERIFY",e[e.NONE=3]="NONE"})(iie||(iie={}));var sie;(function(e){e[e.MESSAGE_ENCODING_UNKNOWN=0]="MESSAGE_ENCODING_UNKNOWN",e[e.LENGTH_PREFIXED=1]="LENGTH_PREFIXED",e[e.DELIMITED=2]="DELIMITED"})(sie||(sie={}));var oie;(function(e){e[e.JSON_FORMAT_UNKNOWN=0]="JSON_FORMAT_UNKNOWN",e[e.ALLOW=1]="ALLOW",e[e.LEGACY_BEST_EFFORT=2]="LEGACY_BEST_EFFORT"})(oie||(oie={}));var aie;(function(e){e[e.ENFORCE_NAMING_STYLE_UNKNOWN=0]="ENFORCE_NAMING_STYLE_UNKNOWN",e[e.STYLE2024=1]="STYLE2024",e[e.STYLE_LEGACY=2]="STYLE_LEGACY"})(aie||(aie={}));var lie;(function(e){e[e.NONE=0]="NONE",e[e.SET=1]="SET",e[e.ALIAS=2]="ALIAS"})(lie||(lie={}));var cie;(function(e){e[e.EDITION_UNKNOWN=0]="EDITION_UNKNOWN",e[e.EDITION_LEGACY=900]="EDITION_LEGACY",e[e.EDITION_PROTO2=998]="EDITION_PROTO2",e[e.EDITION_PROTO3=999]="EDITION_PROTO3",e[e.EDITION_2023=1000]="EDITION_2023",e[e.EDITION_2024=1001]="EDITION_2024",e[e.EDITION_UNSTABLE=9999]="EDITION_UNSTABLE",e[e.EDITION_1_TEST_ONLY=1]="EDITION_1_TEST_ONLY",e[e.EDITION_2_TEST_ONLY=2]="EDITION_2_TEST_ONLY",e[e.EDITION_99997_TEST_ONLY=99997]="EDITION_99997_TEST_ONLY",e[e.EDITION_99998_TEST_ONLY=99998]="EDITION_99998_TEST_ONLY",e[e.EDITION_99999_TEST_ONLY=99999]="EDITION_99999_TEST_ONLY",e[e.EDITION_MAX=2147483647]="EDITION_MAX"})(cie||(cie={}));var uie;(function(e){e[e.VISIBILITY_UNSET=0]="VISIBILITY_UNSET",e[e.VISIBILITY_LOCAL=1]="VISIBILITY_LOCAL",e[e.VISIBILITY_EXPORT=2]="VISIBILITY_EXPORT"})(uie||(uie={}));function vUe(e){return Object.assign(Object.assign({readUnknownFields:!0,recursionLimit:100},e),{depth:0})}function Bv(e,t,n){let r=cf(e);return oF(e).read(r,new Bj(t),vUe(n),t.byteLength),r}var pie=new WeakMap;function oF(e){let t=pie.get(e);if(t===void 0)t=_Ue(e);return t}function _Ue(e){let t=String(e),n=new Map,r={read:xUe(t,n),readGroup:wUe(t,n)};pie.set(e,r);for(let i of e.fields)n.set(i.number,DUe(i));return r}function xUe(e,t){return(n,r,i,s)=>{var o;if(++i.depth>i.recursionLimit)throw Error(`cannot decode ${e} from binary: maximum recursion depth of ${i.recursionLimit} reached`);let a=r.pos+s,l=(o=n.$unknown)!==null&&o!==void 0?o:[];while(r.pos0)n.$unknown=l;i.depth--}}function wUe(e,t){return(n,r,i,s)=>{var o;if(++i.depth>i.recursionLimit)throw Error(`cannot decode ${e} from binary: maximum recursion depth of ${i.recursionLimit} reached`);let a,l,c=(o=n.$unknown)!==null&&o!==void 0?o:[];while(r.pos0)n.$unknown=c;i.depth--}}function DUe(e){switch(e.fieldKind){case"scalar":return TUe(e);case"enum":return SUe(e);case"message":return EUe(e);case"list":return kUe(e);case"map":return NUe(e)}}function TUe(e){let t=bS(e.scalar,e.utf8Validation,e.longAsString),n=e.localName;if(e.oneof){let r=e.oneof.localName;return(i,s)=>{i[r]={case:n,value:t(s)}}}return(r,i)=>{r[n]=t(i)}}function SUe(e){var t;let n=e.localName,r=(t=e.oneof)===null||t===void 0?void 0:t.localName;if(e.enum.open){if(r!==void 0)return(o,a)=>{o[r]={case:n,value:a.int32()}};return(o,a)=>{o[n]=a.int32()}}let i=e.enum.values,s=e.number;return(o,a,l,c)=>{var u;let p=a.int32();if(i.some((d)=>d.number===p))if(r!==void 0)o[r]={case:n,value:p};else o[n]=p;else if(l.readUnknownFields){let d=[];Qne(p,d);let f=(u=o.$unknown)!==null&&u!==void 0?u:[];f.push({no:s,wireType:c,data:new Uint8Array(d)}),o.$unknown=f}}}function EUe(e){let t=e.localName,{toMessage:n,toLocal:r}=fp(e),i=die(e);if(e.oneof){let s=e.oneof.localName;return(o,a,l)=>{let c=o[s],u=n(c.case===t?c.value:void 0);i(u,a,l),o[s]={case:t,value:r(u)}}}return(s,o,a)=>{let l=n(s[t]);i(l,o,a),s[t]=r(l)}}function die(e){let t=oF(e.message);if(e.delimitedEncoding){let n=e.number;return(r,i,s)=>t.readGroup(r,i,s,n)}return(n,r,i)=>t.read(n,r,i,r.uint32())}function kUe(e){let t=e.localName;if(e.listKind=="message"){let{toMessage:o,toLocal:a}=fp(e),l=die(e);return(c,u,p)=>{let d=o(void 0);l(d,u,p),c[t].push(a(d))}}let n=e.listKind=="enum"?ie.INT32:e.scalar,r=e.listKind=="scalar"?e.longAsString:!1,i=bS(n,e.utf8Validation,r),s=n!=ie.STRING&&n!=ie.BYTES;return(o,a,l,c)=>{let u=o[t];if(c==Zn.LengthDelimited&&s){let p=a.uint32()+a.pos;while(a.posa(l),o==ie.BYTES)s=()=>new Uint8Array(0);else{let l=$c(o,!1);s=()=>l}break}case"enum":{let o=e.enum.values[0].number;i=(a)=>a.int32(),s=()=>o;break}case"message":{let{toMessage:o,toLocal:a}=fp(e),l=oF(e.message).read;i=(c,u)=>{let p=o(void 0);return l(p,c,u,c.uint32()),a(p)},s=()=>a(o(void 0));break}}return(o,a,l)=>{let c=o[t],u,p,d=a.uint32(),f=a.pos+d;while(a.posr.string(t);case ie.BOOL:return(r)=>r.bool();case ie.DOUBLE:return(r)=>r.double();case ie.FLOAT:return(r)=>r.float();case ie.INT32:return(r)=>r.int32();case ie.INT64:if(n)return(r)=>String(r.int64());return(r)=>r.int64();case ie.UINT64:if(n)return(r)=>String(r.uint64());return(r)=>r.uint64();case ie.FIXED64:if(n)return(r)=>String(r.fixed64());return(r)=>r.fixed64();case ie.BYTES:return(r)=>r.bytes();case ie.FIXED32:return(r)=>r.fixed32();case ie.SFIXED32:return(r)=>r.sfixed32();case ie.SFIXED64:if(n)return(r)=>String(r.sfixed64());return(r)=>r.sfixed64();case ie.SINT64:if(n)return(r)=>String(r.sint64());return(r)=>r.sint64();case ie.UINT32:return(r)=>r.uint32();case ie.SINT32:return(r)=>r.sint32()}}var OUe=2,PUe=3,fie={writeUnknownFields:!0};function $Ue(e){return e?Object.assign(Object.assign({},fie),e):fie}function aF(e,t,n){let r=new Uj;return lF(e)(r,$Ue(n),t),r.finish()}var mie=new WeakMap;function lF(e){let t=mie.get(e);if(t===void 0)t=IUe(e);return t}function IUe(e){let t=e.typeName,n=e.fields.concat().sort((o,a)=>o.number-a.number),r=n[0],i=[],s=(o,a,l)=>{if(l.$typeName!==t&&r!==void 0)throw new Fa(r,`cannot use ${r} with message ${l.$typeName}`,"ForeignFieldError");for(let u=0;u{let a=o[r];if(a.case===n)t(i,s,a.value)}}if(e.presence!=OUe){let r=e.presence==PUe?`cannot encode ${e} to binary: required field not set`:void 0;return(i,s,o)=>{let a=o[n];if(a!==void 0&&Object.prototype.hasOwnProperty.call(o,n))t(i,s,a);else if(r!==void 0)throw Error(r)}}if(e.fieldKind=="enum"){let r=e.enum.values[0].number;return(i,s,o)=>{let a=o[n];if(a!==r)t(i,s,a)}}switch(e.scalar){case ie.BOOL:return(r,i,s)=>{let o=s[n];if(o!==!1)t(r,i,o)};case ie.STRING:return(r,i,s)=>{let o=s[n];if(o!=="")t(r,i,o)};case ie.BYTES:return(r,i,s)=>{let o=s[n];if(!(o instanceof Uint8Array)||o.byteLength>0)t(r,i,o)};case ie.DOUBLE:case ie.FLOAT:return(r,i,s)=>{let o=s[n];if(!Object.is(o,0))t(r,i,o)};default:return(r,i,s)=>{let o=s[n];if(o!=0)t(r,i,o)}}}function jUe(e){switch(e.fieldKind){case"message":{let{toMessage:t}=fp(e),n=yie(e);return(r,i,s)=>{n(r,i,t(s))}}case"scalar":case"enum":{let t=e.fieldKind=="enum"?ie.INT32:e.scalar,n=e.number,r=_S(t),i=vS(t,e.parent.typeName,e.name);return(s,o,a)=>{s.tag(n,r),i(s,a)}}}}function FUe(e){let{localName:t,number:n}=e;switch(e.listKind){case"message":{let{toMessage:r}=fp(e),i=yie(e);return(s,o,a)=>{let l=a[t];for(let c=0;c{let c=l[t];if(c.length==0)return;o.tag(n,Zn.LengthDelimited).fork();for(let u=0;u{let c=l[t];for(let u=0;u{let d=p[t],f=Object.keys(d);for(let m=0;m{let u=c[t],p=Object.keys(u);for(let d=0;d{i.tag(1,t),n(i,r(s))}}function LUe(e){switch(e){case ie.STRING:return(t)=>t;case ie.BOOL:return(t)=>t==="true"?!0:t==="false"?!1:t;case ie.UINT64:case ie.FIXED64:return(t)=>{try{return Sn.uParse(t)}catch(n){return t}};case ie.INT64:case ie.SFIXED64:case ie.SINT64:return(t)=>{try{return Sn.parse(t)}catch(n){return t}};default:return(t)=>{let n=Number.parseInt(t);return Number.isFinite(n)?n:t}}}function vS(e,t,n){let r=qUe(e);return(i,s)=>{try{r(i,s)}catch(o){if(o instanceof Error)throw Error(`cannot encode field ${t}.${n} to binary: ${o.message}`);throw o}}}function qUe(e){switch(e){case ie.STRING:return(t,n)=>t.string(n);case ie.BOOL:return(t,n)=>t.bool(n);case ie.DOUBLE:return(t,n)=>t.double(n);case ie.FLOAT:return(t,n)=>t.float(n);case ie.INT32:return(t,n)=>t.int32(n);case ie.INT64:return(t,n)=>t.int64(n);case ie.UINT64:return(t,n)=>t.uint64(n);case ie.FIXED64:return(t,n)=>t.fixed64(n);case ie.BYTES:return(t,n)=>t.bytes(n);case ie.FIXED32:return(t,n)=>t.fixed32(n);case ie.SFIXED32:return(t,n)=>t.sfixed32(n);case ie.SFIXED64:return(t,n)=>t.sfixed64(n);case ie.SINT64:return(t,n)=>t.sint64(n);case ie.UINT32:return(t,n)=>t.uint32(n);case ie.SINT32:return(t,n)=>t.sint32(n)}}function yie(e){let t=e.number,n=lF(e.message);if(e.delimitedEncoding)return(r,i,s)=>{r.tag(t,Zn.StartGroup),n(r,i,s),r.tag(t,Zn.EndGroup)};return(r,i,s)=>{r.tag(t,Zn.LengthDelimited).fork(),n(r,i,s),r.join()}}function _S(e){switch(e){case ie.BYTES:case ie.STRING:return Zn.LengthDelimited;case ie.DOUBLE:case ie.FIXED64:case ie.SFIXED64:return Zn.Bit64;case ie.FIXED32:case ie.SFIXED32:case ie.FLOAT:return Zn.Bit32;default:return Zn.Varint}}var _ie=Rr(og(),1);var cF={id:"umf.protobuf",version:"0.1.0",coreVersion:"0.1.0",description:"Native Protobuf descriptors with explicit presence and retained unknown wire fields",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:protobuf:0.1.0",title:"UMF Protobuf descriptor representation",type:"object",required:["descriptorProfile","descriptorSet"],properties:{descriptorProfile:{const:"protobuf-es-2.15.0"},descriptorSet:{$ref:"#/$defs/google.protobuf.FileDescriptorSet"},sourceArchive:{type:"object",required:["role","compiler","files","roots"],properties:{role:{const:"original"},compiler:{type:"string",minLength:1},files:{type:"object",additionalProperties:{type:"string"}},roots:{type:"array",minItems:1,uniqueItems:!0,items:{type:"string",minLength:1}}}}},$defs:{"google.protobuf.FileDescriptorSet":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FileDescriptorSet"},fields:{type:"object",properties:{file:{type:"array",items:{$ref:"#/$defs/google.protobuf.FileDescriptorProto"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.FileDescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FileDescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},package:{type:"string"},dependency:{type:"array",items:{type:"string"}},public_dependency:{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647}},weak_dependency:{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647}},option_dependency:{type:"array",items:{type:"string"}},message_type:{type:"array",items:{$ref:"#/$defs/google.protobuf.DescriptorProto"}},enum_type:{type:"array",items:{$ref:"#/$defs/google.protobuf.EnumDescriptorProto"}},service:{type:"array",items:{$ref:"#/$defs/google.protobuf.ServiceDescriptorProto"}},extension:{type:"array",items:{$ref:"#/$defs/google.protobuf.FieldDescriptorProto"}},options:{$ref:"#/$defs/google.protobuf.FileOptions"},source_code_info:{$ref:"#/$defs/google.protobuf.SourceCodeInfo"},syntax:{type:"string"},edition:{type:"integer",minimum:-2147483648,maximum:2147483647}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.DescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.DescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},field:{type:"array",items:{$ref:"#/$defs/google.protobuf.FieldDescriptorProto"}},extension:{type:"array",items:{$ref:"#/$defs/google.protobuf.FieldDescriptorProto"}},nested_type:{type:"array",items:{$ref:"#/$defs/google.protobuf.DescriptorProto"}},enum_type:{type:"array",items:{$ref:"#/$defs/google.protobuf.EnumDescriptorProto"}},extension_range:{type:"array",items:{$ref:"#/$defs/google.protobuf.DescriptorProto.ExtensionRange"}},oneof_decl:{type:"array",items:{$ref:"#/$defs/google.protobuf.OneofDescriptorProto"}},options:{$ref:"#/$defs/google.protobuf.MessageOptions"},reserved_range:{type:"array",items:{$ref:"#/$defs/google.protobuf.DescriptorProto.ReservedRange"}},reserved_name:{type:"array",items:{type:"string"}},visibility:{type:"integer",minimum:-2147483648,maximum:2147483647}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.FieldDescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FieldDescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},number:{type:"integer",minimum:-2147483648,maximum:2147483647},label:{type:"integer",minimum:-2147483648,maximum:2147483647},type:{type:"integer",minimum:-2147483648,maximum:2147483647},type_name:{type:"string"},extendee:{type:"string"},default_value:{type:"string"},oneof_index:{type:"integer",minimum:-2147483648,maximum:2147483647},json_name:{type:"string"},options:{$ref:"#/$defs/google.protobuf.FieldOptions"},proto3_optional:{type:"boolean"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.FieldOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FieldOptions"},fields:{type:"object",properties:{ctype:{type:"integer",minimum:-2147483648,maximum:2147483647},packed:{type:"boolean"},jstype:{type:"integer",minimum:-2147483648,maximum:2147483647},lazy:{type:"boolean"},unverified_lazy:{type:"boolean"},deprecated:{type:"boolean"},weak:{type:"boolean"},debug_redact:{type:"boolean"},retention:{type:"integer",minimum:-2147483648,maximum:2147483647},targets:{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647}},edition_defaults:{type:"array",items:{$ref:"#/$defs/google.protobuf.FieldOptions.EditionDefault"}},features:{$ref:"#/$defs/google.protobuf.FeatureSet"},feature_support:{$ref:"#/$defs/google.protobuf.FieldOptions.FeatureSupport"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.FieldOptions.EditionDefault":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FieldOptions.EditionDefault"},fields:{type:"object",properties:{edition:{type:"integer",minimum:-2147483648,maximum:2147483647},value:{type:"string"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.FeatureSet":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FeatureSet"},fields:{type:"object",properties:{field_presence:{type:"integer",minimum:-2147483648,maximum:2147483647},enum_type:{type:"integer",minimum:-2147483648,maximum:2147483647},repeated_field_encoding:{type:"integer",minimum:-2147483648,maximum:2147483647},utf8_validation:{type:"integer",minimum:-2147483648,maximum:2147483647},message_encoding:{type:"integer",minimum:-2147483648,maximum:2147483647},json_format:{type:"integer",minimum:-2147483648,maximum:2147483647},enforce_naming_style:{type:"integer",minimum:-2147483648,maximum:2147483647},default_symbol_visibility:{type:"integer",minimum:-2147483648,maximum:2147483647}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.FieldOptions.FeatureSupport":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FieldOptions.FeatureSupport"},fields:{type:"object",properties:{edition_introduced:{type:"integer",minimum:-2147483648,maximum:2147483647},edition_deprecated:{type:"integer",minimum:-2147483648,maximum:2147483647},deprecation_warning:{type:"string"},edition_removed:{type:"integer",minimum:-2147483648,maximum:2147483647},removal_error:{type:"string"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.UninterpretedOption":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.UninterpretedOption"},fields:{type:"object",properties:{name:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption.NamePart"}},identifier_value:{type:"string"},positive_int_value:{type:"string",pattern:"^(?:0|-?[1-9][0-9]*)$"},negative_int_value:{type:"string",pattern:"^(?:0|-?[1-9][0-9]*)$"},double_value:{anyOf:[{type:"number"},{enum:["NaN","Infinity","-Infinity","-0"]}]},string_value:{type:"string",pattern:"^(?:[0-9a-f]{2})*$"},aggregate_value:{type:"string"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.UninterpretedOption.NamePart":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.UninterpretedOption.NamePart"},fields:{type:"object",properties:{name_part:{type:"string"},is_extension:{type:"boolean"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.EnumDescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.EnumDescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},value:{type:"array",items:{$ref:"#/$defs/google.protobuf.EnumValueDescriptorProto"}},options:{$ref:"#/$defs/google.protobuf.EnumOptions"},reserved_range:{type:"array",items:{$ref:"#/$defs/google.protobuf.EnumDescriptorProto.EnumReservedRange"}},reserved_name:{type:"array",items:{type:"string"}},visibility:{type:"integer",minimum:-2147483648,maximum:2147483647}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.EnumValueDescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.EnumValueDescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},number:{type:"integer",minimum:-2147483648,maximum:2147483647},options:{$ref:"#/$defs/google.protobuf.EnumValueOptions"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.EnumValueOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.EnumValueOptions"},fields:{type:"object",properties:{deprecated:{type:"boolean"},features:{$ref:"#/$defs/google.protobuf.FeatureSet"},debug_redact:{type:"boolean"},feature_support:{$ref:"#/$defs/google.protobuf.FieldOptions.FeatureSupport"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.EnumOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.EnumOptions"},fields:{type:"object",properties:{allow_alias:{type:"boolean"},deprecated:{type:"boolean"},deprecated_legacy_json_field_conflicts:{type:"boolean"},features:{$ref:"#/$defs/google.protobuf.FeatureSet"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.EnumDescriptorProto.EnumReservedRange":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.EnumDescriptorProto.EnumReservedRange"},fields:{type:"object",properties:{start:{type:"integer",minimum:-2147483648,maximum:2147483647},end:{type:"integer",minimum:-2147483648,maximum:2147483647}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.DescriptorProto.ExtensionRange":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.DescriptorProto.ExtensionRange"},fields:{type:"object",properties:{start:{type:"integer",minimum:-2147483648,maximum:2147483647},end:{type:"integer",minimum:-2147483648,maximum:2147483647},options:{$ref:"#/$defs/google.protobuf.ExtensionRangeOptions"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.ExtensionRangeOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.ExtensionRangeOptions"},fields:{type:"object",properties:{uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}},declaration:{type:"array",items:{$ref:"#/$defs/google.protobuf.ExtensionRangeOptions.Declaration"}},features:{$ref:"#/$defs/google.protobuf.FeatureSet"},verification:{type:"integer",minimum:-2147483648,maximum:2147483647}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.ExtensionRangeOptions.Declaration":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.ExtensionRangeOptions.Declaration"},fields:{type:"object",properties:{number:{type:"integer",minimum:-2147483648,maximum:2147483647},full_name:{type:"string"},type:{type:"string"},reserved:{type:"boolean"},repeated:{type:"boolean"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.OneofDescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.OneofDescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},options:{$ref:"#/$defs/google.protobuf.OneofOptions"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.OneofOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.OneofOptions"},fields:{type:"object",properties:{features:{$ref:"#/$defs/google.protobuf.FeatureSet"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.MessageOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.MessageOptions"},fields:{type:"object",properties:{message_set_wire_format:{type:"boolean"},no_standard_descriptor_accessor:{type:"boolean"},deprecated:{type:"boolean"},map_entry:{type:"boolean"},deprecated_legacy_json_field_conflicts:{type:"boolean"},features:{$ref:"#/$defs/google.protobuf.FeatureSet"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.DescriptorProto.ReservedRange":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.DescriptorProto.ReservedRange"},fields:{type:"object",properties:{start:{type:"integer",minimum:-2147483648,maximum:2147483647},end:{type:"integer",minimum:-2147483648,maximum:2147483647}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.ServiceDescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.ServiceDescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},method:{type:"array",items:{$ref:"#/$defs/google.protobuf.MethodDescriptorProto"}},options:{$ref:"#/$defs/google.protobuf.ServiceOptions"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.MethodDescriptorProto":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.MethodDescriptorProto"},fields:{type:"object",properties:{name:{type:"string"},input_type:{type:"string"},output_type:{type:"string"},options:{$ref:"#/$defs/google.protobuf.MethodOptions"},client_streaming:{type:"boolean"},server_streaming:{type:"boolean"}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.MethodOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.MethodOptions"},fields:{type:"object",properties:{deprecated:{type:"boolean"},idempotency_level:{type:"integer",minimum:-2147483648,maximum:2147483647},features:{$ref:"#/$defs/google.protobuf.FeatureSet"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.ServiceOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.ServiceOptions"},fields:{type:"object",properties:{features:{$ref:"#/$defs/google.protobuf.FeatureSet"},deprecated:{type:"boolean"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.FileOptions":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.FileOptions"},fields:{type:"object",properties:{java_package:{type:"string"},java_outer_classname:{type:"string"},java_multiple_files:{type:"boolean"},java_generate_equals_and_hash:{type:"boolean"},java_string_check_utf8:{type:"boolean"},optimize_for:{type:"integer",minimum:-2147483648,maximum:2147483647},go_package:{type:"string"},cc_generic_services:{type:"boolean"},java_generic_services:{type:"boolean"},py_generic_services:{type:"boolean"},deprecated:{type:"boolean"},cc_enable_arenas:{type:"boolean"},objc_class_prefix:{type:"string"},csharp_namespace:{type:"string"},swift_prefix:{type:"string"},php_class_prefix:{type:"string"},php_namespace:{type:"string"},php_metadata_namespace:{type:"string"},ruby_package:{type:"string"},features:{$ref:"#/$defs/google.protobuf.FeatureSet"},uninterpreted_option:{type:"array",items:{$ref:"#/$defs/google.protobuf.UninterpretedOption"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.SourceCodeInfo":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.SourceCodeInfo"},fields:{type:"object",properties:{location:{type:"array",items:{$ref:"#/$defs/google.protobuf.SourceCodeInfo.Location"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},"google.protobuf.SourceCodeInfo.Location":{type:"object",required:["type","fields","unknown"],properties:{type:{const:"google.protobuf.SourceCodeInfo.Location"},fields:{type:"object",properties:{path:{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647}},span:{type:"array",items:{type:"integer",minimum:-2147483648,maximum:2147483647}},leading_comments:{type:"string"},trailing_comments:{type:"string"},leading_detached_comments:{type:"array",items:{type:"string"}}}},unknown:{type:"array",items:{$ref:"#/$defs/unknown"}}}},unknown:{type:"object",required:["number","wireType","data"],properties:{number:{type:"integer",minimum:1,maximum:536870911},wireType:{enum:[0,1,2,3,5]},data:{type:"string",pattern:"^(?:[0-9a-f]{2})*$"}}}}},semantics:"CONTRACT-003. Descriptor fields retain native types and presence; unknown fields/options are preserved without interpretation. Browser checks are not a native compiler certificate. Source compilation is available through an explicit compiler; source emission recompiles and compares descriptor semantics before returning.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Protocol Buffers .proto and FileDescriptorSet",version:"descriptor profile @bufbuild/protobuf 2.15.0; source compiler protocompile 0.14.1; printer protoprint 1.18.1; native oracle protoc 36.2",subset:"Complete pinned descriptor message graph; proto2/proto3/Editions descriptor representation. Optional WASM source compilation has authored proto2, proto3 and Edition 2023 evidence; newer Editions are not claimed. Source emission has native compiler evidence for 15 standard roots and authored proto2/proto3/Edition 2023 cases; four Edition 2024 standard roots are explicitly unsupported."},evidence:["tests/protobuf/descriptor.test.ts","tests/protobuf/source.test.ts","tests/protobuf/emission.test.ts","tests/protobuf/behavior.test.ts","scripts/browser.ts"]}};var uF=gS;function bie(e){if(typeof e!=="string"||!/^(?:[0-9a-f]{2})*$/.test(e))throw new U("PROTOBUF_BYTES","Expected lowercase hexadecimal bytes");return Uint8Array.from(e.match(/../g)??[],(t)=>parseInt(t,16))}function hie(e,t){if(t===ie.BYTES)return bie(e);if([ie.INT64,ie.UINT64,ie.SINT64,ie.FIXED64,ie.SFIXED64].includes(t)){if(typeof e!=="string"||!/^(?:0|-?[1-9][0-9]*)$/.test(e))throw new U("PROTOBUF_INTEGER","Expected canonical decimal integer");return BigInt(e)}if((t===ie.FLOAT||t===ie.DOUBLE)&&typeof e==="string"){if(!["NaN","Infinity","-Infinity","-0"].includes(e))throw new U("PROTOBUF_FLOAT","Invalid special floating value");return Number(e)}return e}function gie(e,t){for(let n of Object.keys(e))if(!t.includes(n))throw new U("PROTOBUF_REPRESENTATION","Unknown representation field cannot be discarded",n)}function pF(e,t){if(gie(e,["type","fields","unknown"]),e.type!==t.typeName)throw new U("PROTOBUF_TYPE",`Expected ${t.typeName}`);let n=Nre(t);for(let[r,i]of Object.entries(e.fields)){let s=t.fields.find((o)=>o.name===r);if(!s)throw new U("PROTOBUF_REPRESENTATION","Unknown named descriptor field: "+r);if(s.fieldKind==="message")n.set(s,pF(i,s.message));else if(s.fieldKind==="list"){if(!Array.isArray(i))throw new U("PROTOBUF_LIST","Expected descriptor list");let o=Ore(s);for(let a of i)o.add(s.listKind==="message"?pF(a,s.message):hie(a,s.listKind==="scalar"?s.scalar:void 0));n.set(s,o)}else if(s.fieldKind==="map")throw new U("PROTOBUF_DESCRIPTOR_PROFILE","Descriptor map fields require a newer profile");else n.set(s,hie(i,s.fieldKind==="scalar"?s.scalar:void 0))}return n.setUnknown(e.unknown.map((r)=>{if(gie(r,["number","wireType","data"]),!Number.isInteger(r.number)||r.number<1||r.number>536870911||![0,1,2,3,5].includes(r.wireType))throw new U("PROTOBUF_UNKNOWN","Invalid unknown wire field");return{no:r.number,wireType:r.wireType,data:bie(r.data)}})),n}function xS(e){let t=Ae(e);try{let n=aF(uF,pF(t,uF).message);if(n.length>Zt.maxTextLength)throw new U("LIMIT","Descriptor output exceeds limit");return Bv(uF,n),n}catch(n){if(n instanceof U)throw n;throw new U("PROTOBUF_DESCRIPTOR",String(n))}}var dF="umf.protobuf",VUe=cF,KUe=new _ie.default({strict:!1,allErrors:!0}).compile(cF.schema);function JUe(e){let t=e,n=[],r=(s,o,a)=>n.push({code:s,path:o,message:a,severity:"warning"});for(let s of Object.keys(t))if(!["descriptorProfile","descriptorSet","sourceArchive"].includes(s))r("PROTOBUF_REPRESENTATION","/"+s,"Unknown representation field retained; native export blocked");if(t.sourceArchive){for(let s of Object.keys(t.sourceArchive))if(!["role","compiler","files","roots"].includes(s))r("PROTOBUF_REPRESENTATION","/sourceArchive/"+s,"Unknown source archive field retained; native export blocked")}function i(s,o){if(s.unknown.length)r("PROTOBUF_UNKNOWN",o+"/unknown","Unknown native wire fields/options retained without semantic interpretation");for(let[a,l]of Object.entries(s.fields))for(let c of Array.isArray(l)?l:[l])if(c&&typeof c==="object"&&!Array.isArray(c)&&"fields"in c&&"type"in c)i(c,o+"/fields/"+a)}i(t.descriptorSet,"/descriptorSet");try{let s=xS(t.descriptorSet),o=Bv(gS,s),a=new Set;for(let l of o.file){if(!l.name||a.has(l.name))throw Error("Missing or duplicate file name");a.add(l.name)}yS(o)}catch(s){r("PROTOBUF_INTERPRETATION","/descriptorSet",String(s))}return r("PROTOBUF_COMPILER_REQUIRED","/descriptorSet","Browser descriptor checks do not certify native compiler validity; validate emitted artifacts with the pinned native compiler"),n}function GUe(){return new nt().register(VUe,JUe)}function vie(e){return We(e,GUe())}function HUe(e){let t=vie(e);if(!t.valid)throw new U("PROTOBUF_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[dF];if(e.vocabularies[dF]?.version!=="0.1.0"||!KUe(n))throw new U("PROTOBUF_PAYLOAD","Missing or malformed Protobuf payload");return Ae(n)}function fF(e){let t=HUe(e);if(Object.keys(t).some((n)=>!["descriptorProfile","descriptorSet","sourceArchive"].includes(n)))throw new U("PROTOBUF_REPRESENTATION","Unknown representation field cannot be discarded");if(t.sourceArchive&&Object.keys(t.sourceArchive).some((n)=>!["role","compiler","files","roots"].includes(n)))throw new U("PROTOBUF_REPRESENTATION","Unknown source archive field cannot be discarded");return xS(t.descriptorSet)}function xie(e,t){let n=[],r=(a,l)=>n.push({code:a,path:t,message:l,severity:"warning"}),i=/^decimal\(\s*(\d+)\s*,\s*(-?\d+)\s*\)$/.exec(e);if(i){let a=BigInt(i[1]),l=BigInt(i[2]);if(a>2147483647n||l>2147483647n||l<-2147483648n)r("SPARK_PARAMETER_INT32","Spark JVM parses decimal parameters as int32; this value exceeds that range");if(a>38n)r("SPARK_DECIMAL_PRECISION","Spark JVM decimal precision exceeds the supported maximum of 38");if(l>a)r("SPARK_DECIMAL_SCALE","Spark JVM rejects decimal scale greater than precision");if(l<0n)r("SPARK_DECIMAL_NEGATIVE_SCALE","Negative decimal scale depends on spark.sql.legacy.allowNegativeScaleOfDecimal; default JVM configuration rejects it")}let s=/^(?:char|varchar)\(\s*(\d+)\s*\)$/.exec(e);if(s&&BigInt(s[1])>2147483647n)r("SPARK_PARAMETER_INT32","Spark JVM parses character length as int32; this value exceeds that range");let o=/^interval (year|month|day|hour|minute|second) to (year|month|day|hour|minute|second)$/.exec(e);if(o){let a=["year","month","day","hour","minute","second"],l=a.indexOf(o[1]),c=a.indexOf(o[2]);if(l<2!==c<2||l>=c)r("SPARK_INTERVAL_RANGE","Spark JVM JSON interval spelling must use an increasing range within year/month or day/time units")}return n}function wie(e){let t=[],n=(s,o,a)=>t.push({code:s,path:o,message:a,severity:"warning"});function r(s,o){if(s.kind!=="object"||s.members.name?.kind!=="string"||!s.members.type)return;let a=s.members.metadata,l=a?.kind==="object"?a.members.__COLLATIONS:void 0;if(l){let c=o+"/metadata/__COLLATIONS";if(l.kind!=="object")n("SPARK_COLLATION_MAP",c,"Native collation metadata must be a path-to-string map; JVM may ignore this value while Python rejects it");else{let p=function(d,f){if(u.set(f,d),d.kind!=="object"||d.members.type?.kind!=="string")return;let m=(y)=>f?f+"."+y:y;if(d.members.type.value==="array"&&d.members.elementType)p(d.members.elementType,m("element"));if(d.members.type.value==="map"){if(d.members.keyType)p(d.members.keyType,m("key"));if(d.members.valueType)p(d.members.valueType,m("value"))}},u=new Map;p(s.members.type,s.members.name.value);for(let[d,f]of Object.entries(l.members)){let m=c+"/"+$e(d),y=u.get(d);if(f.kind!=="string")n("SPARK_COLLATION_VALUE",m,"Native collation annotation is not a string; JVM may ignore it while Python rejects it");else if(!/^(spark|icu)\..+$/.test(f.value))n("SPARK_COLLATION_PROVIDER",m,"Expected a Spark 4.0.1 provider-qualified collation name; provider/name validity requires native verification");if(!y)n("SPARK_COLLATION_UNRESOLVED",m,"Path does not resolve within this field through known array/map types; native parsing may discard the annotation");else if(y.kind!=="string"||y.value!=="string")n("SPARK_COLLATION_TARGET",m,"Collation path targets a non-string schema node; native parsers may reject it")}}}i(s.members.type,o+"/type")}function i(s,o){if(s.kind!=="object"||s.members.type?.kind!=="string")return;if(s.members.type.value==="struct"&&s.members.fields?.kind==="array")s.members.fields.items.forEach((a,l)=>r(a,o+"/fields/"+l));if(s.members.type.value==="array"&&s.members.elementType)i(s.members.elementType,o+"/elementType");if(s.members.type.value==="map"){if(s.members.keyType)i(s.members.keyType,o+"/keyType");if(s.members.valueType)i(s.members.valueType,o+"/valueType")}}return i(e,""),t}function Die(e){let t=[],n=(o,a,l)=>t.push({code:o,path:a,severity:"warning",message:l}),r=(o)=>o.kind==="number"?/[.eE]/.test(o.value)?"double":"long":o.kind;function i(o,a){if(o.kind==="number")if(!/[.eE]/.test(o.value)){if(o.value.replace(/^-/,"").length>19||BigInt(o.value)<-9223372036854775808n||BigInt(o.value)>9223372036854775807n)n("SPARK_METADATA_INT64_OVERFLOW",a,"Spark JVM metadata converts integer tokens to int64 and can wrap this value; UMF retains the exact token")}else if(!Number.isFinite(Number(o.value)))n("SPARK_METADATA_NONFINITE",a,"Spark JVM metadata converts this number to a nonfinite double and may emit a string; UMF retains the exact token");else n("SPARK_METADATA_DOUBLE",a,"Spark JVM metadata uses binary64 for fractional/exponent tokens; precision and source spelling may change");if(o.kind==="object")for(let[l,c]of Object.entries(o.members))i(c,a+"/"+$e(l));if(o.kind==="array"){if(!o.items.length)n("SPARK_METADATA_EMPTY_ARRAY",a,"Spark JVM infers an empty int64 array; the source JSON does not specify the array element type");else{let l=r(o.items[0]);if(l==="null"||l==="array")n("SPARK_METADATA_ARRAY_UNSUPPORTED",a,"Spark JVM metadata does not support arrays of nulls or nested arrays");if(o.items.some((c)=>r(c)!==l))n("SPARK_METADATA_ARRAY_MIXED",a,"Spark JVM metadata requires homogeneous array categories, including separate integer and double categories")}o.items.forEach((l,c)=>i(l,a+"/"+c))}}function s(o,a){if(o.kind!=="object"||o.members.type?.kind!=="string")return;if(o.members.type.value==="struct"&&o.members.fields?.kind==="array")o.members.fields.items.forEach((l,c)=>{if(l.kind!=="object")return;let u=a+"/fields/"+c;if(l.members.metadata?.kind==="object"){if(!l.members.nullable)n("SPARK_FIELD_METADATA_WITHOUT_NULLABLE",u,"Spark JVM 4.0.1 does not accept a field with metadata but no nullable property; Python may insert the default");for(let[p,d]of Object.entries(l.members.metadata.members))if(p!=="__COLLATIONS")i(d,u+"/metadata/"+$e(p))}if(l.members.type)s(l.members.type,u+"/type")});if(o.members.type.value==="array"&&o.members.elementType)s(o.members.elementType,a+"/elementType");if(o.members.type.value==="map"){if(o.members.keyType)s(o.members.keyType,a+"/keyType");if(o.members.valueType)s(o.members.valueType,a+"/valueType")}}return s(e,""),t}var Tie={id:"umf.spark",version:"0.1.0",coreVersion:"0.1.0",description:"Exact Spark DataType/StructType JSON with preserved metadata and native interpretation limits",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:spark:0.1.0",type:"object",properties:{profile:{const:"spark-datatype-json"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-017. Source JSON is authoritative; no native parser normalization, UDT execution or engine/configuration validity is implied. Unknown properties/types and exact numeric tokens survive.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Apache Spark DataType schema JSON",version:"4.0.1 grammar baseline; Python and JVM evidence separately qualified",subset:"Known array/map/struct shape validation, exact source preservation and candidate edits. Atomic names/parameters and UDT declarations retain interpretation limits; no JVM/browser execution, DDL or data coercion claim."},evidence:["tests/spark/schema.test.ts","fixtures/spark/capability-results.json","fixtures/spark/umf-oracle-results.json","fixtures/spark/browser-results.json","tests/spark/rename.test.ts","fixtures/spark/rename-oracle-results.json","tests/spark/upstream.test.ts","fixtures/spark/upstream-oracle-results.json","tests/spark/metadata.test.ts","fixtures/spark/metadata-oracle-results.json","tests/spark/collations.test.ts","fixtures/spark/collation-oracle-results.json","tests/spark/parameters.test.ts","fixtures/spark/parameter-oracle-results.json","tests/spark/projection.test.ts","tests/spark/reverse-projection.test.ts","fixtures/projections/spark-arrow/projection-oracle-results.json","fixtures/projections/spark-arrow/reverse-oracle-results.json","tests/spark/arrow-origin.test.ts","fixtures/projections/arrow-spark/oracle-results.json","tests/spark/upstream-projection.test.ts","fixtures/projections/arrow-spark-upstream/oracle-results.json"]}};var Sie={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:spark:datatype-json:0.1.0",$ref:"#/$defs/type",$defs:{type:{anyOf:[{type:"string",minLength:1},{type:"object",properties:{type:{const:"array"},elementType:{$ref:"#/$defs/type"},containsNull:{type:"boolean"}},required:["type","elementType","containsNull"],additionalProperties:!0},{type:"object",properties:{type:{const:"map"},keyType:{$ref:"#/$defs/type"},valueType:{$ref:"#/$defs/type"},valueContainsNull:{type:"boolean"}},required:["type","keyType","valueType","valueContainsNull"],additionalProperties:!0},{type:"object",properties:{type:{const:"struct"},fields:{type:"array",items:{$ref:"#/$defs/field"}}},required:["type","fields"],additionalProperties:!0},{type:"object",properties:{type:{const:"udt"},class:{type:"string"},pyClass:{type:["string","null"]},serializedClass:{type:"string"},sqlType:{$ref:"#/$defs/type"}},required:["type"],additionalProperties:!0},{type:"object",properties:{type:{type:"string",minLength:1,not:{enum:["array","map","struct","udt"]}}},required:["type"],additionalProperties:!0}]},field:{type:"object",properties:{name:{type:"string"},type:{$ref:"#/$defs/type"},nullable:{type:"boolean"},metadata:{type:"object"}},required:["name","type"],additionalProperties:!0}}};var Eie="umf.spark",QUe=Tie,mF,YUe=new Set(["void","null","boolean","byte","short","integer","long","float","double","string","binary","date","timestamp","timestamp_ltz","timestamp_ntz","decimal","interval","variant"]),XUe=/^(?:decimal\(\s*\d+\s*,\s*-?\d+\s*\)|(?:char|varchar)\(\s*\d+\s*\)|string collate .+|interval (?:year|month|day|hour|minute|second)(?: to (?:year|month|day|hour|minute|second))?)$/;function ZUe(e){let t=e,n=[{code:"SPARK_NATIVE_UNVERIFIED",path:"",severity:"warning",message:"Schema preservation is not Spark engine validity: runtime/configuration, metadata, collation and coercion checks remain separate"}],r=(l,c,u,p="warning")=>n.push({code:l,path:c,message:u,severity:p});if(Object.keys(t).some((l)=>!["profile","root"].includes(l)))r("SPARK_REPRESENTATION","","Unknown representation fields must stay in UMF");function i(l,c){let u=l.kind==="null"?["kind"]:l.kind==="array"?["kind","items"]:l.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(l).some((p)=>!u.includes(p)))r("SPARK_REPRESENTATION",c,"Unknown tagged-tree fields must stay in UMF");if(l.kind==="object")for(let[p,d]of Object.entries(l.members))i(d,c+"/"+$e(p));if(l.kind==="array")l.items.forEach((p,d)=>i(p,c+"/"+d))}i(t.root,"/root");let s=JSON.parse(Be(t.root));if(mF??=mt().compile(Sie),!mF(s)){for(let l of mF.errors??[])r("SPARK_STRUCTURE",l.instancePath,l.message??"Invalid DataType shape","error");return n}function o(l,c,u){for(let p of Object.keys(l))if(!c.includes(p))r("SPARK_UNKNOWN",u+"/"+$e(p),"Uninterpreted native property preserved")}function a(l,c){if(typeof l==="string"){if(n.push(...xie(l,c)),!YUe.has(l)&&!XUe.test(l))r("SPARK_UNKNOWN_TYPE",c,"Unrecognized type spelling preserved");return}switch(l.type){case"array":o(l,["type","elementType","containsNull"],c),a(l.elementType,c+"/elementType");break;case"map":o(l,["type","keyType","valueType","valueContainsNull"],c),a(l.keyType,c+"/keyType"),a(l.valueType,c+"/valueType");break;case"struct":o(l,["type","fields"],c),l.fields.forEach((u,p)=>{let d=c+"/fields/"+p;if(o(u,["name","type","nullable","metadata"],d),a(u.type,d+"/type"),u.metadata)r("SPARK_METADATA_UNVERIFIED",d+"/metadata","Metadata retained exactly; engine value restrictions, collation paths and name dependencies are not interpreted")});break;case"udt":if(o(l,["type","class","pyClass","serializedClass","sqlType"],c),r("SPARK_UDT_UNINTERPRETED",c,"UDT declaration retained without importing classes or deserializing executable content"),l.sqlType!==void 0)a(l.sqlType,c+"/sqlType");break;default:r("SPARK_UNKNOWN_TYPE",c,"Unrecognized object-form type preserved")}}return a(s,""),n.push(...Die(t.root),...wie(t.root)),n}function e3e(){return new nt().register(QUe,ZUe)}function kie(e){return We(e,e3e())}function t3e(e){let t=kie(e);if(!t.valid)throw new U("SPARK_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[Eie];if(!n||e.vocabularies[Eie]?.version!=="0.1.0")throw new U("SPARK_PAYLOAD","Expected pinned Spark schema payload");return Ae(n)}function Nie(e){let t=t3e(e);if(kie(e).diagnostics.some((n)=>n.code==="SPARK_REPRESENTATION"))throw new U("SPARK_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var Oie={id:"umf.tablespec",version:"0.1.0",coreVersion:"0.1.0",description:"TableSpec native table schemas and derived core scalar metadata",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:tablespec:0.1.0",type:"object",required:["profile","root","originalSource","originalFormat"],properties:{profile:{const:"tablespec-table-1"},root:{$ref:"#/$defs/node"},originalSource:{type:"string",maxLength:4000000},originalFormat:{enum:["json","yaml"]},splitFiles:{type:"object",required:["table.yaml"],minProperties:2,maxProperties:1000,additionalProperties:{type:"string",maxLength:4000000},properties:{"table.yaml":{type:"string",maxLength:4000000}}}},$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-030; source preservation and scalar-family classification, not complete Pydantic validation or coercion",scopes:["document"],capabilities:{validation:"structural",directions:["import","export"],native:{system:"TableSpec",version:"source commit 647e8e566ad78b864282ec65c0b0b2237aa63084; table version 1.0",subset:"Monolithic JSON/YAML ingestion and split file-bundle capture; copied table/column metadata access and edits, core scalar families and native recovery. Schema projections are separately qualified by CONTRACT-033, CONTRACT-038 and CONTRACT-039. Split loader migrations, split-to-monolithic lowering, native validation/coercion and general value transforms remain open."},evidence:["tests/tablespec/roundtrip.test.ts","native/tablespec/sources.json","fixtures/tablespec/oracle.json","fixtures/tablespec/browser.json","tests/tablespec/split.test.ts","fixtures/tablespec/split-oracle.json","tests/tablespec/table-edits.test.ts","fixtures/tablespec/table-edits-oracle.json","tests/tablespec/table-metadata.test.ts","tests/tablespec/boundaries.test.ts","fixtures/tablespec/boundaries-oracle.json"]}};var wS="umf.tablespec",r3e=Oie,Pie={VARCHAR:"string",TEXT:"string",CHAR:"string",BOOLEAN:"boolean",INTEGER:"integer",DECIMAL:"decimal",FLOAT:"float",DATE:"date",DATETIME:"timestamp",TIMESTAMP:"timestamp"},$ie=(e,t)=>t==="json"?Jt(e):Wa(e);function Iie(e){if(e.kind!=="object"||e.members.table_name?.kind!=="string"||e.members.columns?.kind!=="array")throw new U("TABLESPEC_TABLE","Expected table_name and a monolithic columns array");if(e.members.version?.kind!=="string"||e.members.version.value!=="1.0")throw new U("TABLESPEC_VERSION","Expected TableSpec table version 1.0");let t=new Set,n=e.members.columns.items.map((r,i)=>{if(r.kind!=="object"||r.members.name?.kind!=="string"||r.members.data_type?.kind!=="string")throw new U("TABLESPEC_COLUMN","Expected native column name and data_type");let s=r.members.name.value;if(t.has(s))throw new U("TABLESPEC_COLUMN","Duplicate column name");t.add(s);let o=Object.hasOwn(Pie,r.members.data_type.value)?Pie[r.members.data_type.value]:void 0;return{id:"column:"+i,name:s,...r.members.description?.kind==="string"?{description:r.members.description.value}:{},...o?{scalarType:o}:{},extensions:{}}});return{name:e.members.table_name.value,elements:n,native:e.members.columns.items}}function Aie(e,t){if(!["json","yaml"].includes(t.format))throw new U("TABLESPEC_FORMAT","Expected json or yaml");let n=$ie(e,t.format),r=Iie(n),i={profile:"tablespec-table-1",root:n,originalSource:e,originalFormat:t.format},s={umf:"0.1.0",id:t.id,vocabularies:{[wS]:{version:"0.1.0"}},extensions:{[wS]:i},modules:[{id:"table",namespace:r.name,elements:r.elements}]};if(!DS(s).valid)throw new U("TABLESPEC_DOCUMENT","Invalid UMF representation");return s}function DS(e){return We(e,new nt().register(r3e))}function i3e(e){if(!DS(e).valid||e.vocabularies[wS]?.version!=="0.1.0")throw new U("TABLESPEC_DOCUMENT","Expected a valid pinned TableSpec document");let t=e.extensions?.[wS];if(!t)throw new U("TABLESPEC_PAYLOAD","Missing TableSpec source");return Ae(t)}function yF(e){let t=e.kind==="object"?["kind","members"]:e.kind==="array"?["kind","items"]:e.kind==="null"?["kind"]:["kind","value"];if(Object.keys(e).some((n)=>!t.includes(n)))throw new U("TABLESPEC_ENCODING","Unknown tree encoding fields retained; export blocked");if(e.kind==="object")Object.values(e.members).forEach(yF);if(e.kind==="array")e.items.forEach(yF)}function s3e(e){let t=i3e(e);if(Object.keys(t).some((i)=>!["profile","root","originalSource","originalFormat","splitFiles"].includes(i)))throw new U("TABLESPEC_ENCODING","Unknown source encoding fields retained; export blocked");yF(t.root);let n=Iie(t.root),r=e.modules.find((i)=>i.id==="table");if(!r||r.namespace!==n.name||r.elements.length!==n.elements.length||n.elements.some((i,s)=>{let o=r.elements[s];return!o||["id","name","description","scalarType"].some((a)=>o[a]!==i[a])}))throw new U("TABLESPEC_METADATA","Native source and core column metadata disagree; synchronize edits explicitly");return t}function Rie(e){let t=s3e(e);if(t.splitFiles)throw new U("TABLESPEC_SPLIT","Use exportTableSpecBundle to preserve split-file semantics");return Be($ie(t.originalSource,t.originalFormat))===Be(t.root)?t.originalSource:Be(t.root)+` +`}var jie={id:"umf.linkml",version:"0.1.0",coreVersion:"0.1.0",description:"LinkML source schemas with explicit metamodel selection and exact native preservation",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:linkml:0.1.0",type:"object",properties:{profile:{const:"linkml-json-yaml"},metamodelVersion:{type:"string",minLength:1},root:{$ref:"#/$defs/node"},originalSource:{type:"string",maxLength:4000000},originalFormat:{enum:["json","yaml"]}},required:["profile","metamodelVersion","root","originalSource","originalFormat"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-024; source is authoritative, independently of native loader normalization or schema diagnostics",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"LinkML",version:"linkml-model 1.11.0 commit 051e945bb8d64ffd60639c666615ace88d561e2f; native loader runtime 1.11.0rc2",subset:"JSON/YAML schema source, complete pinned metamodel JSON Schema, copied metadata edits, explicit supplied import graph, document-local class-slot membership and 29-field scalar induction; explicit import merge modes; no native retrieval, induced model, instance validation or generators"},evidence:["tests/linkml/linkml.test.ts","fixtures/linkml/oracle-results.json","fixtures/linkml/browser-results.json","tests/linkml/metamodel.test.ts","fixtures/linkml/metamodel/oracle-results.json","tests/linkml/imports.test.ts","fixtures/linkml/imports/oracle-results.json","fixtures/linkml/imports/browser-results.json","tests/linkml/class-slots.test.ts","fixtures/linkml/class-slots/oracle-results.json","fixtures/linkml/class-slots/browser-results.json","tests/linkml/slot-values.test.ts","fixtures/linkml/slot-values/oracle-results.json","fixtures/linkml/slot-values/browser-results.json","tests/linkml/slot-corpus.test.ts","fixtures/linkml/slot-corpus/oracle-results.json","fixtures/linkml/slot-corpus/browser-results.json","tests/linkml/merge.test.ts","fixtures/linkml/merge/oracle-results.json","fixtures/linkml/merge/browser-results.json","tests/linkml/metamodel-merge.test.ts","fixtures/linkml/metamodel-merge/oracle-results.json","fixtures/linkml/metamodel-merge/browser-results.json"]}};var zie=Rr(bF(),1);var Jie={$defs:{AliasPredicateEnum:{description:"permissible values for the relationship between an element and an alias",enum:["EXACT_SYNONYM","RELATED_SYNONYM","BROAD_SYNONYM","NARROW_SYNONYM"],title:"AliasPredicateEnum",type:"string"},AltDescription:{additionalProperties:!1,description:"an attributed description",properties:{description:{description:"text of an attributed description",type:"string"},source:{description:"the source of an attributed description",type:"string"}},required:["source","description"],title:"AltDescription",type:"object"},AltDescription__identifier_optional:{additionalProperties:!1,description:"an attributed description",properties:{description:{description:"text of an attributed description",type:"string"},source:{description:"the source of an attributed description",type:"string"}},required:["description"],title:"AltDescription",type:"object"},Annotatable:{additionalProperties:!1,description:"mixin for classes that support annotations",properties:{annotations:{additionalProperties:{anyOf:[{$ref:"#/$defs/Annotation__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a collection of tag/text tuples with the semantics of OWL Annotation",type:["object","null"]}},title:"Annotatable",type:"object"},Annotation:{additionalProperties:!1,description:"a tag/value pair with the semantics of OWL Annotation",properties:{annotations:{additionalProperties:{anyOf:[{$ref:"#/$defs/Annotation__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a collection of tag/text tuples with the semantics of OWL Annotation",type:["object","null"]},extensions:{additionalProperties:{anyOf:[{$ref:"#/$defs/Extension__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a tag/text tuple attached to an arbitrary element",type:["object","null"]},tag:{description:"a tag associated with an extension",type:"string"},value:{$ref:"#/$defs/AnyValue",description:"the actual annotation"}},required:["tag","value"],title:"Annotation",type:"object"},Annotation__identifier_optional:{additionalProperties:!1,description:"a tag/value pair with the semantics of OWL Annotation",properties:{annotations:{additionalProperties:{anyOf:[{$ref:"#/$defs/Annotation__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a collection of tag/text tuples with the semantics of OWL Annotation",type:["object","null"]},extensions:{additionalProperties:{anyOf:[{$ref:"#/$defs/Extension__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a tag/text tuple attached to an arbitrary element",type:["object","null"]},tag:{description:"a tag associated with an extension",type:"string"},value:{$ref:"#/$defs/AnyValue",description:"the actual annotation"}},required:["value"],title:"Annotation",type:"object"},AnonymousClassExpression:{additionalProperties:!1,description:"",properties:{aliases:{description:"Alternate names/labels for the element. These do not alter the semantics of the schema, but may be useful to support search and alignment.",items:{type:"string"},type:["array","null"]},all_of:{description:"holds if all of the expressions hold",items:{$ref:"#/$defs/AnonymousClassExpression"},type:["array","null"]},alt_descriptions:{additionalProperties:{anyOf:[{$ref:"#/$defs/AltDescription__identifier_optional"},{description:"text of an attributed description",type:"string"}]},description:"A sourced alternative description for an element",type:["object","null"]},annotations:{additionalProperties:{anyOf:[{$ref:"#/$defs/Annotation__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a collection of tag/text tuples with the semantics of OWL Annotation",type:["object","null"]},any_of:{description:"holds if at least one of the expressions hold",items:{$ref:"#/$defs/AnonymousClassExpression"},type:["array","null"]},broad_mappings:{description:"A list of terms from different schemas or terminology systems that have broader meaning.",items:{type:"string"},type:["array","null"]},categories:{description:"Controlled terms used to categorize an element.",items:{type:"string"},type:["array","null"]},close_mappings:{description:"A list of terms from different schemas or terminology systems that have close meaning.",items:{type:"string"},type:["array","null"]},comments:{description:"notes and comments about an element intended primarily for external consumption",items:{type:"string"},type:["array","null"]},contributors:{description:"agent that contributed to the element",items:{type:"string"},type:["array","null"]},created_by:{description:"agent that created the element",type:["string","null"]},created_on:{description:"time at which the element was created",format:"date-time",type:["string","null"]},deprecated:{description:"Description of why and when this element will no longer be used",type:["string","null"]},deprecated_element_has_exact_replacement:{description:"When an element is deprecated, it can be automatically replaced by this uri or curie",type:["string","null"]},deprecated_element_has_possible_replacement:{description:"When an element is deprecated, it can be potentially replaced by this uri or curie",type:["string","null"]},description:{description:"a textual description of the element's purpose and use",type:["string","null"]},exact_mappings:{description:"A list of terms from different schemas or terminology systems that have identical meaning.",items:{type:"string"},type:["array","null"]},exactly_one_of:{description:"holds if only one of the expressions hold",items:{$ref:"#/$defs/AnonymousClassExpression"},type:["array","null"]},examples:{description:"example usages of an element",items:{$ref:"#/$defs/Example"},type:["array","null"]},extensions:{additionalProperties:{anyOf:[{$ref:"#/$defs/Extension__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a tag/text tuple attached to an arbitrary element",type:["object","null"]},from_schema:{description:"id of the schema that defined the element",format:"uri",type:["string","null"]},imported_from:{description:"the imports entry that this element was derived from. Empty means primary source",type:["string","null"]},in_language:{description:"the primary language used in the sources",type:["string","null"]},in_subset:{description:"used to indicate membership of a term in a defined subset of terms used for a particular domain or application.",items:{type:"string"},type:["array","null"]},is_a:{description:"A primary parent class or slot from which inheritable metaslots are propagated from. While multiple inheritance is not allowed, mixins can be provided effectively providing the same thing. The semantics are the same when translated to formalisms that allow MI (e.g. RDFS/OWL). When translating to a SI framework (e.g. java classes, python classes) then is a is used. When translating a framework without polymorphism (e.g. json-schema, solr document schema) then is a and mixins are recursively unfolded",type:["string","null"]},keywords:{description:"Keywords or tags used to describe the element",items:{type:"string"},type:["array","null"]},last_updated_on:{description:"time at which the element was last updated",format:"date-time",type:["string","null"]},mappings:{description:"A list of terms from different schemas or terminology systems that have comparable meaning. These may include terms that are precisely equivalent, broader or narrower in meaning, or otherwise semantically related but not equivalent from a strict ontological perspective.",items:{type:"string"},type:["array","null"]},modified_by:{description:"agent that modified the element",type:["string","null"]},narrow_mappings:{description:"A list of terms from different schemas or terminology systems that have narrower meaning.",items:{type:"string"},type:["array","null"]},none_of:{description:"holds if none of the expressions hold",items:{$ref:"#/$defs/AnonymousClassExpression"},type:["array","null"]},notes:{description:"editorial notes about an element intended primarily for internal consumption",items:{type:"string"},type:["array","null"]},rank:{description:"the relative order in which the element occurs, lower values are given precedence",type:["integer","null"]},related_mappings:{description:"A list of terms from different schemas or terminology systems that have related meaning.",items:{type:"string"},type:["array","null"]},see_also:{description:"A list of related entities or URLs that may be of relevance",items:{type:"string"},type:["array","null"]},slot_conditions:{additionalProperties:{anyOf:[{$ref:"#/$defs/SlotDefinition__identifier_optional"},{type:"null"}]},description:"expresses constraints on a group of slots for a class expression",type:["object","null"]},source:{description:"A related resource from which the element is derived.",type:["string","null"]},status:{description:"status of the element",type:["string","null"]},structured_aliases:{description:"A list of structured_alias objects, used to provide aliases in conjunction with additional metadata.",items:{$ref:"#/$defs/StructuredAlias"},type:["array","null"]},title:{description:"A concise human-readable display label for the element. The title should mirror the name, and should use ordinary textual punctuation.",type:["string","null"]},todos:{description:"Outstanding issues that needs resolution",items:{type:"string"},type:["array","null"]}},title:"AnonymousClassExpression",type:"object"},AnonymousEnumExpression:{additionalProperties:!1,description:"An enum_expression that is not named",properties:{code_set:{description:"the identifier of an enumeration code set.",type:["string","null"]},code_set_tag:{description:"the version tag of the enumeration code set",type:["string","null"]},code_set_version:{description:"the version identifier of the enumeration code set",type:["string","null"]},concepts:{description:"A list of identifiers that are used to construct a set of permissible values",items:{type:"string"},type:["array","null"]},include:{description:"An enum expression that yields a list of permissible values that are to be included, after subtracting the minus set",items:{$ref:"#/$defs/AnonymousEnumExpression"},type:["array","null"]},inherits:{description:"An enum definition that is used as the basis to create a new enum",items:{type:"string"},type:["array","null"]},matches:{anyOf:[{$ref:"#/$defs/MatchQuery"},{type:"null"}],description:"Specifies a match query that is used to calculate the list of permissible values"},minus:{description:"An enum expression that yields a list of permissible values that are to be subtracted from the enum",items:{$ref:"#/$defs/AnonymousEnumExpression"},type:["array","null"]},permissible_values:{additionalProperties:{anyOf:[{$ref:"#/$defs/PermissibleValue__identifier_optional"},{type:"null"}]},description:"A list of possible values for a slot range",type:["object","null"]},pv_formula:{$ref:"#/$defs/PvFormulaOptions",description:"Defines the specific formula to be used to generate the permissible values."},reachable_from:{anyOf:[{$ref:"#/$defs/ReachabilityQuery"},{type:"null"}],description:"Specifies a query for obtaining a list of permissible values based on graph reachability"}},title:"AnonymousEnumExpression",type:"object"},AnonymousExpression:{additionalProperties:!1,description:"An abstract parent class for any nested expression",properties:{aliases:{description:"Alternate names/labels for the element. These do not alter the semantics of the schema, but may be useful to support search and alignment.",items:{type:"string"},type:["array","null"]},alt_descriptions:{additionalProperties:{anyOf:[{$ref:"#/$defs/AltDescription__identifier_optional"},{description:"text of an attributed description",type:"string"}]},description:"A sourced alternative description for an element",type:["object","null"]},annotations:{additionalProperties:{anyOf:[{$ref:"#/$defs/Annotation__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a collection of tag/text tuples with the semantics of OWL Annotation",type:["object","null"]},broad_mappings:{description:"A list of terms from different schemas or terminology systems that have broader meaning.",items:{type:"string"},type:["array","null"]},categories:{description:"Controlled terms used to categorize an element.",items:{type:"string"},type:["array","null"]},close_mappings:{description:"A list of terms from different schemas or terminology systems that have close meaning.",items:{type:"string"},type:["array","null"]},comments:{description:"notes and comments about an element intended primarily for external consumption",items:{type:"string"},type:["array","null"]},contributors:{description:"agent that contributed to the element",items:{type:"string"},type:["array","null"]},created_by:{description:"agent that created the element",type:["string","null"]},created_on:{description:"time at which the element was created",format:"date-time",type:["string","null"]},deprecated:{description:"Description of why and when this element will no longer be used",type:["string","null"]},deprecated_element_has_exact_replacement:{description:"When an element is deprecated, it can be automatically replaced by this uri or curie",type:["string","null"]},deprecated_element_has_possible_replacement:{description:"When an element is deprecated, it can be potentially replaced by this uri or curie",type:["string","null"]},description:{description:"a textual description of the element's purpose and use",type:["string","null"]},exact_mappings:{description:"A list of terms from different schemas or terminology systems that have identical meaning.",items:{type:"string"},type:["array","null"]},examples:{description:"example usages of an element",items:{$ref:"#/$defs/Example"},type:["array","null"]},extensions:{additionalProperties:{anyOf:[{$ref:"#/$defs/Extension__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a tag/text tuple attached to an arbitrary element",type:["object","null"]},from_schema:{description:"id of the schema that defined the element",format:"uri",type:["string","null"]},imported_from:{description:"the imports entry that this element was derived from. Empty means primary source",type:["string","null"]},in_language:{description:"the primary language used in the sources",type:["string","null"]},in_subset:{description:"used to indicate membership of a term in a defined subset of terms used for a particular domain or application.",items:{type:"string"},type:["array","null"]},keywords:{description:"Keywords or tags used to describe the element",items:{type:"string"},type:["array","null"]},last_updated_on:{description:"time at which the element was last updated",format:"date-time",type:["string","null"]},mappings:{description:"A list of terms from different schemas or terminology systems that have comparable meaning. These may include terms that are precisely equivalent, broader or narrower in meaning, or otherwise semantically related but not equivalent from a strict ontological perspective.",items:{type:"string"},type:["array","null"]},modified_by:{description:"agent that modified the element",type:["string","null"]},narrow_mappings:{description:"A list of terms from different schemas or terminology systems that have narrower meaning.",items:{type:"string"},type:["array","null"]},notes:{description:"editorial notes about an element intended primarily for internal consumption",items:{type:"string"},type:["array","null"]},rank:{description:"the relative order in which the element occurs, lower values are given precedence",type:["integer","null"]},related_mappings:{description:"A list of terms from different schemas or terminology systems that have related meaning.",items:{type:"string"},type:["array","null"]},see_also:{description:"A list of related entities or URLs that may be of relevance",items:{type:"string"},type:["array","null"]},source:{description:"A related resource from which the element is derived.",type:["string","null"]},status:{description:"status of the element",type:["string","null"]},structured_aliases:{description:"A list of structured_alias objects, used to provide aliases in conjunction with additional metadata.",items:{$ref:"#/$defs/StructuredAlias"},type:["array","null"]},title:{description:"A concise human-readable display label for the element. The title should mirror the name, and should use ordinary textual punctuation.",type:["string","null"]},todos:{description:"Outstanding issues that needs resolution",items:{type:"string"},type:["array","null"]}},title:"AnonymousExpression",type:"object"},AnonymousSlotExpression:{additionalProperties:!1,description:"",properties:{aliases:{description:"Alternate names/labels for the element. These do not alter the semantics of the schema, but may be useful to support search and alignment.",items:{type:"string"},type:["array","null"]},all_members:{anyOf:[{$ref:"#/$defs/AnonymousSlotExpression"},{type:"null"}],description:"the value of the slot is multivalued with all members satisfying the condition"},all_of:{description:"holds if all of the expressions hold",items:{$ref:"#/$defs/AnonymousSlotExpression"},type:["array","null"]},alt_descriptions:{additionalProperties:{anyOf:[{$ref:"#/$defs/AltDescription__identifier_optional"},{description:"text of an attributed description",type:"string"}]},description:"A sourced alternative description for an element",type:["object","null"]},annotations:{additionalProperties:{anyOf:[{$ref:"#/$defs/Annotation__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a collection of tag/text tuples with the semantics of OWL Annotation",type:["object","null"]},any_of:{description:"holds if at least one of the expressions hold",items:{$ref:"#/$defs/AnonymousSlotExpression"},type:["array","null"]},array:{anyOf:[{$ref:"#/$defs/ArrayExpression"},{type:"null"}],description:"coerces the value of the slot into an array and defines the dimensions of that array"},bindings:{description:`A collection of enum bindings that specify how a slot can be bound to a permissible value from an enumeration. LinkML provides enums to allow string values to be restricted to one of a set of permissible values (specified statically or dynamically). Enum bindings allow enums to be bound to any object, including complex nested objects. For example, given a (generic) class Concept with slots id and label, it may be desirable to restrict the values the id takes on in a given context. For example, a HumanSample class may have a slot for representing sample site, with a range of concept, but the values of that slot may be restricted to concepts from a particular branch of an anatomy ontology.`,items:{$ref:"#/$defs/EnumBinding"},type:["array","null"]},broad_mappings:{description:"A list of terms from different schemas or terminology systems that have broader meaning.",items:{type:"string"},type:["array","null"]},categories:{description:"Controlled terms used to categorize an element.",items:{type:"string"},type:["array","null"]},close_mappings:{description:"A list of terms from different schemas or terminology systems that have close meaning.",items:{type:"string"},type:["array","null"]},comments:{description:"notes and comments about an element intended primarily for external consumption",items:{type:"string"},type:["array","null"]},contributors:{description:"agent that contributed to the element",items:{type:"string"},type:["array","null"]},created_by:{description:"agent that created the element",type:["string","null"]},created_on:{description:"time at which the element was created",format:"date-time",type:["string","null"]},deprecated:{description:"Description of why and when this element will no longer be used",type:["string","null"]},deprecated_element_has_exact_replacement:{description:"When an element is deprecated, it can be automatically replaced by this uri or curie",type:["string","null"]},deprecated_element_has_possible_replacement:{description:"When an element is deprecated, it can be potentially replaced by this uri or curie",type:["string","null"]},description:{description:"a textual description of the element's purpose and use",type:["string","null"]},enum_range:{anyOf:[{$ref:"#/$defs/EnumExpression"},{type:"null"}],description:"An inlined enumeration"},equals_expression:{description:"the value of the slot must equal the value of the evaluated expression",type:["string","null"]},equals_number:{description:"the slot must have range of a number and the value of the slot must equal the specified value",type:["integer","null"]},equals_string:{description:"the slot must have range string and the value of the slot must equal the specified value",type:["string","null"]},equals_string_in:{description:"the slot must have range string and the value of the slot must equal one of the specified values",items:{type:"string"},type:["array","null"]},exact_cardinality:{description:"the exact number of entries for a multivalued slot",type:["integer","null"]},exact_mappings:{description:"A list of terms from different schemas or terminology systems that have identical meaning.",items:{type:"string"},type:["array","null"]},exactly_one_of:{description:"holds if only one of the expressions hold",items:{$ref:"#/$defs/AnonymousSlotExpression"},type:["array","null"]},examples:{description:"example usages of an element",items:{$ref:"#/$defs/Example"},type:["array","null"]},extensions:{additionalProperties:{anyOf:[{$ref:"#/$defs/Extension__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a tag/text tuple attached to an arbitrary element",type:["object","null"]},from_schema:{description:"id of the schema that defined the element",format:"uri",type:["string","null"]},has_member:{anyOf:[{$ref:"#/$defs/AnonymousSlotExpression"},{type:"null"}],description:"the value of the slot is multivalued with at least one member satisfying the condition"},implicit_prefix:{description:"Causes the slot value to be interpreted as a uriorcurie after prefixing with this string",type:["string","null"]},imported_from:{description:"the imports entry that this element was derived from. Empty means primary source",type:["string","null"]},in_language:{description:"the primary language used in the sources",type:["string","null"]},in_subset:{description:"used to indicate membership of a term in a defined subset of terms used for a particular domain or application.",items:{type:"string"},type:["array","null"]},inlined:{description:"True means that keyed or identified slot appears in an outer structure by value. False means that only the key or identifier for the slot appears within the domain, referencing a structure that appears elsewhere.",type:["boolean","null"]},inlined_as_list:{description:"True means that an inlined slot is represented as a list of range instances. False means that an inlined slot is represented as a dictionary, whose key is the slot key or identifier and whose value is the range instance.",type:["boolean","null"]},keywords:{description:"Keywords or tags used to describe the element",items:{type:"string"},type:["array","null"]},last_updated_on:{description:"time at which the element was last updated",format:"date-time",type:["string","null"]},mappings:{description:"A list of terms from different schemas or terminology systems that have comparable meaning. These may include terms that are precisely equivalent, broader or narrower in meaning, or otherwise semantically related but not equivalent from a strict ontological perspective.",items:{type:"string"},type:["array","null"]},maximum_cardinality:{description:"the maximum number of entries for a multivalued slot",type:["integer","null"]},maximum_value:{anyOf:[{$ref:"#/$defs/Anything"},{type:"null"}],description:"For ordinal ranges, the value must be equal to or lower than this"},minimum_cardinality:{description:"the minimum number of entries for a multivalued slot",type:["integer","null"]},minimum_value:{anyOf:[{$ref:"#/$defs/Anything"},{type:"null"}],description:"For ordinal ranges, the value must be equal to or higher than this"},modified_by:{description:"agent that modified the element",type:["string","null"]},multivalued:{description:"true means that slot can have more than one value and should be represented using a list or collection structure.",type:["boolean","null"]},narrow_mappings:{description:"A list of terms from different schemas or terminology systems that have narrower meaning.",items:{type:"string"},type:["array","null"]},none_of:{description:"holds if none of the expressions hold",items:{$ref:"#/$defs/AnonymousSlotExpression"},type:["array","null"]},notes:{description:"editorial notes about an element intended primarily for internal consumption",items:{type:"string"},type:["array","null"]},pattern:{description:"the string value of the slot must conform to this regular expression expressed in the string",type:["string","null"]},range:{description:`defines the type of the object of the slot. Given the following slot definition S1: @@ -4328,20 +4328,20 @@ We call the slot with the serialization the s-slot, the slots used in the {}s ar Implementations of frameworks may choose to use this property to either (a) PARSE: implement automated normalizations by parsing denormalized strings into complex objects (b) GENERATE: implement automated to_string labeling of complex objects For example, a Measurement class may have 3 fields: unit, value, and string_value. The string_value slot may have a string_serialization of {value}{unit} such that if unit=cm and value=2, the value of string_value shouldd be 2cm`,type:["string","null"]},structured_aliases:{description:"A list of structured_alias objects, used to provide aliases in conjunction with additional metadata.",items:{$ref:"#/$defs/StructuredAlias"},type:["array","null"]},title:{description:"A concise human-readable display label for the element. The title should mirror the name, and should use ordinary textual punctuation.",type:["string","null"]},todos:{description:"Outstanding issues that needs resolution",items:{type:"string"},type:["array","null"]},type:{description:"type to coerce to",type:["string","null"]}},required:[],title:"TypeMapping",type:"object"},UniqueKey:{additionalProperties:!1,description:"a collection of slots whose values uniquely identify an instance of a class",properties:{aliases:{description:"Alternate names/labels for the element. These do not alter the semantics of the schema, but may be useful to support search and alignment.",items:{type:"string"},type:["array","null"]},alt_descriptions:{additionalProperties:{anyOf:[{$ref:"#/$defs/AltDescription__identifier_optional"},{description:"text of an attributed description",type:"string"}]},description:"A sourced alternative description for an element",type:["object","null"]},annotations:{additionalProperties:{anyOf:[{$ref:"#/$defs/Annotation__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a collection of tag/text tuples with the semantics of OWL Annotation",type:["object","null"]},broad_mappings:{description:"A list of terms from different schemas or terminology systems that have broader meaning.",items:{type:"string"},type:["array","null"]},categories:{description:"Controlled terms used to categorize an element.",items:{type:"string"},type:["array","null"]},close_mappings:{description:"A list of terms from different schemas or terminology systems that have close meaning.",items:{type:"string"},type:["array","null"]},comments:{description:"notes and comments about an element intended primarily for external consumption",items:{type:"string"},type:["array","null"]},consider_nulls_inequal:{description:"By default, None values are considered equal for the purposes of comparisons in determining uniqueness. Set this to true to treat missing values as per ANSI-SQL NULLs, i.e NULL=NULL is always False.",type:["boolean","null"]},contributors:{description:"agent that contributed to the element",items:{type:"string"},type:["array","null"]},created_by:{description:"agent that created the element",type:["string","null"]},created_on:{description:"time at which the element was created",format:"date-time",type:["string","null"]},deprecated:{description:"Description of why and when this element will no longer be used",type:["string","null"]},deprecated_element_has_exact_replacement:{description:"When an element is deprecated, it can be automatically replaced by this uri or curie",type:["string","null"]},deprecated_element_has_possible_replacement:{description:"When an element is deprecated, it can be potentially replaced by this uri or curie",type:["string","null"]},description:{description:"a textual description of the element's purpose and use",type:["string","null"]},exact_mappings:{description:"A list of terms from different schemas or terminology systems that have identical meaning.",items:{type:"string"},type:["array","null"]},examples:{description:"example usages of an element",items:{$ref:"#/$defs/Example"},type:["array","null"]},extensions:{additionalProperties:{anyOf:[{$ref:"#/$defs/Extension__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a tag/text tuple attached to an arbitrary element",type:["object","null"]},from_schema:{description:"id of the schema that defined the element",format:"uri",type:["string","null"]},imported_from:{description:"the imports entry that this element was derived from. Empty means primary source",type:["string","null"]},in_language:{description:"the primary language used in the sources",type:["string","null"]},in_subset:{description:"used to indicate membership of a term in a defined subset of terms used for a particular domain or application.",items:{type:"string"},type:["array","null"]},keywords:{description:"Keywords or tags used to describe the element",items:{type:"string"},type:["array","null"]},last_updated_on:{description:"time at which the element was last updated",format:"date-time",type:["string","null"]},mappings:{description:"A list of terms from different schemas or terminology systems that have comparable meaning. These may include terms that are precisely equivalent, broader or narrower in meaning, or otherwise semantically related but not equivalent from a strict ontological perspective.",items:{type:"string"},type:["array","null"]},modified_by:{description:"agent that modified the element",type:["string","null"]},narrow_mappings:{description:"A list of terms from different schemas or terminology systems that have narrower meaning.",items:{type:"string"},type:["array","null"]},notes:{description:"editorial notes about an element intended primarily for internal consumption",items:{type:"string"},type:["array","null"]},rank:{description:"the relative order in which the element occurs, lower values are given precedence",type:["integer","null"]},related_mappings:{description:"A list of terms from different schemas or terminology systems that have related meaning.",items:{type:"string"},type:["array","null"]},see_also:{description:"A list of related entities or URLs that may be of relevance",items:{type:"string"},type:["array","null"]},source:{description:"A related resource from which the element is derived.",type:["string","null"]},status:{description:"status of the element",type:["string","null"]},structured_aliases:{description:"A list of structured_alias objects, used to provide aliases in conjunction with additional metadata.",items:{$ref:"#/$defs/StructuredAlias"},type:["array","null"]},title:{description:"A concise human-readable display label for the element. The title should mirror the name, and should use ordinary textual punctuation.",type:["string","null"]},todos:{description:"Outstanding issues that needs resolution",items:{type:"string"},type:["array","null"]},unique_key_name:{description:"name of the unique key",type:"string"},unique_key_slots:{description:"list of slot names that form a key. The tuple formed from the values of all these slots should be unique.",items:{type:"string"},type:"array"}},required:["unique_key_name","unique_key_slots"],title:"UniqueKey",type:"object"},UniqueKey__identifier_optional:{additionalProperties:!1,description:"a collection of slots whose values uniquely identify an instance of a class",properties:{aliases:{description:"Alternate names/labels for the element. These do not alter the semantics of the schema, but may be useful to support search and alignment.",items:{type:"string"},type:["array","null"]},alt_descriptions:{additionalProperties:{anyOf:[{$ref:"#/$defs/AltDescription__identifier_optional"},{description:"text of an attributed description",type:"string"}]},description:"A sourced alternative description for an element",type:["object","null"]},annotations:{additionalProperties:{anyOf:[{$ref:"#/$defs/Annotation__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a collection of tag/text tuples with the semantics of OWL Annotation",type:["object","null"]},broad_mappings:{description:"A list of terms from different schemas or terminology systems that have broader meaning.",items:{type:"string"},type:["array","null"]},categories:{description:"Controlled terms used to categorize an element.",items:{type:"string"},type:["array","null"]},close_mappings:{description:"A list of terms from different schemas or terminology systems that have close meaning.",items:{type:"string"},type:["array","null"]},comments:{description:"notes and comments about an element intended primarily for external consumption",items:{type:"string"},type:["array","null"]},consider_nulls_inequal:{description:"By default, None values are considered equal for the purposes of comparisons in determining uniqueness. Set this to true to treat missing values as per ANSI-SQL NULLs, i.e NULL=NULL is always False.",type:["boolean","null"]},contributors:{description:"agent that contributed to the element",items:{type:"string"},type:["array","null"]},created_by:{description:"agent that created the element",type:["string","null"]},created_on:{description:"time at which the element was created",format:"date-time",type:["string","null"]},deprecated:{description:"Description of why and when this element will no longer be used",type:["string","null"]},deprecated_element_has_exact_replacement:{description:"When an element is deprecated, it can be automatically replaced by this uri or curie",type:["string","null"]},deprecated_element_has_possible_replacement:{description:"When an element is deprecated, it can be potentially replaced by this uri or curie",type:["string","null"]},description:{description:"a textual description of the element's purpose and use",type:["string","null"]},exact_mappings:{description:"A list of terms from different schemas or terminology systems that have identical meaning.",items:{type:"string"},type:["array","null"]},examples:{description:"example usages of an element",items:{$ref:"#/$defs/Example"},type:["array","null"]},extensions:{additionalProperties:{anyOf:[{$ref:"#/$defs/Extension__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a tag/text tuple attached to an arbitrary element",type:["object","null"]},from_schema:{description:"id of the schema that defined the element",format:"uri",type:["string","null"]},imported_from:{description:"the imports entry that this element was derived from. Empty means primary source",type:["string","null"]},in_language:{description:"the primary language used in the sources",type:["string","null"]},in_subset:{description:"used to indicate membership of a term in a defined subset of terms used for a particular domain or application.",items:{type:"string"},type:["array","null"]},keywords:{description:"Keywords or tags used to describe the element",items:{type:"string"},type:["array","null"]},last_updated_on:{description:"time at which the element was last updated",format:"date-time",type:["string","null"]},mappings:{description:"A list of terms from different schemas or terminology systems that have comparable meaning. These may include terms that are precisely equivalent, broader or narrower in meaning, or otherwise semantically related but not equivalent from a strict ontological perspective.",items:{type:"string"},type:["array","null"]},modified_by:{description:"agent that modified the element",type:["string","null"]},narrow_mappings:{description:"A list of terms from different schemas or terminology systems that have narrower meaning.",items:{type:"string"},type:["array","null"]},notes:{description:"editorial notes about an element intended primarily for internal consumption",items:{type:"string"},type:["array","null"]},rank:{description:"the relative order in which the element occurs, lower values are given precedence",type:["integer","null"]},related_mappings:{description:"A list of terms from different schemas or terminology systems that have related meaning.",items:{type:"string"},type:["array","null"]},see_also:{description:"A list of related entities or URLs that may be of relevance",items:{type:"string"},type:["array","null"]},source:{description:"A related resource from which the element is derived.",type:["string","null"]},status:{description:"status of the element",type:["string","null"]},structured_aliases:{description:"A list of structured_alias objects, used to provide aliases in conjunction with additional metadata.",items:{$ref:"#/$defs/StructuredAlias"},type:["array","null"]},title:{description:"A concise human-readable display label for the element. The title should mirror the name, and should use ordinary textual punctuation.",type:["string","null"]},todos:{description:"Outstanding issues that needs resolution",items:{type:"string"},type:["array","null"]},unique_key_name:{description:"name of the unique key",type:"string"},unique_key_slots:{description:"list of slot names that form a key. The tuple formed from the values of all these slots should be unique.",items:{type:"string"},type:"array"}},required:["unique_key_slots"],title:"UniqueKey",type:"object"},UnitOfMeasure:{additionalProperties:!1,description:"A unit of measure, or unit, is a particular quantity value that has been chosen as a scale for measuring other quantities the same kind (more generally of equivalent dimension).",properties:{abbreviation:{description:"An abbreviation for a unit is a short ASCII string that is used in place of the full name for the unit in contexts where non-ASCII characters would be problematic, or where using the abbreviation will enhance readability. When a power of a base unit needs to be expressed, such as squares this can be done using abbreviations rather than symbols (source: qudt)",type:["string","null"]},derivation:{description:"Expression for deriving this unit from other units",type:["string","null"]},descriptive_name:{description:"the spelled out name of the unit, for example, meter",type:["string","null"]},exact_mappings:{description:"Used to link a unit to equivalent concepts in ontologies such as UO, SNOMED, OEM, OBOE, NCIT",items:{type:"string"},type:["array","null"]},has_quantity_kind:{description:"Concept in a vocabulary or ontology that denotes the kind of quantity being measured, e.g. length",type:["string","null"]},iec61360code:{type:["string","null"]},symbol:{description:"name of the unit encoded as a symbol",type:["string","null"]},ucum_code:{description:"associates a QUDT unit with its UCUM code (case-sensitive).",type:["string","null"]}},title:"UnitOfMeasure",type:"object"}},$id:"https://w3id.org/linkml/meta",$schema:"https://json-schema.org/draft/2019-09/schema",additionalProperties:!0,description:"A collection of definitions that make up a schema or a data model.",metamodel_version:"1.11.0",properties:{aliases:{description:"Alternate names/labels for the element. These do not alter the semantics of the schema, but may be useful to support search and alignment.",items:{type:"string"},type:["array","null"]},alt_descriptions:{additionalProperties:{anyOf:[{$ref:"#/$defs/AltDescription__identifier_optional"},{description:"text of an attributed description",type:"string"}]},description:"A sourced alternative description for an element",type:["object","null"]},annotations:{additionalProperties:{anyOf:[{$ref:"#/$defs/Annotation__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a collection of tag/text tuples with the semantics of OWL Annotation",type:["object","null"]},bindings:{description:`A collection of enum bindings that specify how a slot can be bound to a permissible value from an enumeration. LinkML provides enums to allow string values to be restricted to one of a set of permissible values (specified statically or dynamically). -Enum bindings allow enums to be bound to any object, including complex nested objects. For example, given a (generic) class Concept with slots id and label, it may be desirable to restrict the values the id takes on in a given context. For example, a HumanSample class may have a slot for representing sample site, with a range of concept, but the values of that slot may be restricted to concepts from a particular branch of an anatomy ontology.`,items:{$ref:"#/$defs/EnumBinding"},type:["array","null"]},broad_mappings:{description:"A list of terms from different schemas or terminology systems that have broader meaning.",items:{type:"string"},type:["array","null"]},categories:{description:"Controlled terms used to categorize an element.",items:{type:"string"},type:["array","null"]},classes:{additionalProperties:{anyOf:[{$ref:"#/$defs/ClassDefinition__identifier_optional"},{type:"null"}]},description:"An index to the collection of all class definitions in the schema",type:["object","null"]},close_mappings:{description:"A list of terms from different schemas or terminology systems that have close meaning.",items:{type:"string"},type:["array","null"]},comments:{description:"notes and comments about an element intended primarily for external consumption",items:{type:"string"},type:["array","null"]},conforms_to:{description:"An established standard to which the element conforms.",type:["string","null"]},contributors:{description:"agent that contributed to the element",items:{type:"string"},type:["array","null"]},created_by:{description:"agent that created the element",type:["string","null"]},created_on:{description:"time at which the element was created",format:"date-time",type:["string","null"]},default_curi_maps:{description:"ordered list of prefixcommon biocontexts to be fetched to resolve id prefixes and inline prefix variables",items:{type:"string"},type:["array","null"]},default_prefix:{description:"The prefix that is used for all elements within a schema",type:["string","null"]},default_range:{description:"default slot range to be used if range element is omitted from a slot definition",type:["string","null"]},definition_uri:{description:"The native URI of the element. This is always within the namespace of the containing schema. Contrast with the assigned URI, via class_uri or slot_uri",type:["string","null"]},deprecated:{description:"Description of why and when this element will no longer be used",type:["string","null"]},deprecated_element_has_exact_replacement:{description:"When an element is deprecated, it can be automatically replaced by this uri or curie",type:["string","null"]},deprecated_element_has_possible_replacement:{description:"When an element is deprecated, it can be potentially replaced by this uri or curie",type:["string","null"]},description:{description:"a textual description of the element's purpose and use",type:["string","null"]},emit_prefixes:{description:"a list of Curie prefixes that are used in the representation of instances of the model. All prefixes in this list are added to the prefix sections of the target models.",items:{pattern:"^[a-zA-Z_][\\w.-]*$",type:"string"},type:["array","null"]},enums:{additionalProperties:{anyOf:[{$ref:"#/$defs/EnumDefinition__identifier_optional"},{type:"null"}]},description:"An index to the collection of all enum definitions in the schema",type:["object","null"]},exact_mappings:{description:"A list of terms from different schemas or terminology systems that have identical meaning.",items:{type:"string"},type:["array","null"]},examples:{description:"example usages of an element",items:{$ref:"#/$defs/Example"},type:["array","null"]},extensions:{additionalProperties:{anyOf:[{$ref:"#/$defs/Extension__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a tag/text tuple attached to an arbitrary element",type:["object","null"]},from_schema:{description:"id of the schema that defined the element",format:"uri",type:["string","null"]},generation_date:{description:"date and time that the schema was loaded/generated",format:"date-time",type:["string","null"]},id:{description:"The official schema URI",format:"uri",type:"string"},id_prefixes:{description:"An allowed list of prefixes for which identifiers must conform. The identifier of this class or slot must begin with the URIs referenced by this prefix",items:{pattern:"^[a-zA-Z_][\\w.-]*$",type:"string"},type:["array","null"]},id_prefixes_are_closed:{description:"If true, then the id_prefixes slot is treated as being closed, and any use of an id that does not have this prefix is considered a violation.",type:["boolean","null"]},implements:{description:"An element in another schema which this element conforms to. The referenced element is not imported into the schema for the implementing element. However, the referenced schema may be used to check conformance of the implementing element.",items:{type:"string"},type:["array","null"]},imported_from:{description:"the imports entry that this element was derived from. Empty means primary source",type:["string","null"]},imports:{description:"A list of schemas that are to be included in this schema",items:{type:"string"},type:["array","null"]},in_language:{description:"the primary language used in the sources",type:["string","null"]},in_subset:{description:"used to indicate membership of a term in a defined subset of terms used for a particular domain or application.",items:{type:"string"},type:["array","null"]},instantiates:{description:"An element in another schema which this element instantiates.",items:{type:"string"},type:["array","null"]},keywords:{description:"Keywords or tags used to describe the element",items:{type:"string"},type:["array","null"]},last_updated_on:{description:"time at which the element was last updated",format:"date-time",type:["string","null"]},license:{description:"license for the schema",type:["string","null"]},local_names:{additionalProperties:{anyOf:[{$ref:"#/$defs/LocalName__identifier_optional"},{description:"a name assigned to an element in a given ontology",type:"string"}]},type:["object","null"]},mappings:{description:"A list of terms from different schemas or terminology systems that have comparable meaning. These may include terms that are precisely equivalent, broader or narrower in meaning, or otherwise semantically related but not equivalent from a strict ontological perspective.",items:{type:"string"},type:["array","null"]},metamodel_version:{description:"Version of the metamodel used to load the schema",type:["string","null"]},modified_by:{description:"agent that modified the element",type:["string","null"]},name:{description:"a unique name for the schema that is both human-readable and consists of only characters from the NCName set",pattern:"^[a-zA-Z_][\\w.-]*$",type:"string"},narrow_mappings:{description:"A list of terms from different schemas or terminology systems that have narrower meaning.",items:{type:"string"},type:["array","null"]},notes:{description:"editorial notes about an element intended primarily for internal consumption",items:{type:"string"},type:["array","null"]},prefixes:{additionalProperties:{anyOf:[{$ref:"#/$defs/Prefix__identifier_optional"},{description:"The namespace to which a prefix expands to.",format:"uri",type:"string"}]},description:"A collection of prefix expansions that specify how CURIEs can be expanded to URIs",type:["object","null"]},rank:{description:"the relative order in which the element occurs, lower values are given precedence",type:["integer","null"]},related_mappings:{description:"A list of terms from different schemas or terminology systems that have related meaning.",items:{type:"string"},type:["array","null"]},see_also:{description:"A list of related entities or URLs that may be of relevance",items:{type:"string"},type:["array","null"]},settings:{additionalProperties:{anyOf:[{$ref:"#/$defs/Setting__identifier_optional"},{description:"The value assigned for a setting",type:"string"}]},description:"A collection of global variable settings",type:["object","null"]},slot_names_unique:{description:"if true then induced/mangled slot names are not created for class_usage and attributes",type:["boolean","null"]},slots:{additionalProperties:{anyOf:[{$ref:"#/$defs/SlotDefinition__identifier_optional"},{type:"null"}]},description:"An index to the collection of all slot definitions in the schema",type:["object","null"]},source:{description:"A related resource from which the element is derived.",type:["string","null"]},source_file:{description:"name, uri or description of the source of the schema",type:["string","null"]},source_file_date:{description:"modification date of the source of the schema",format:"date-time",type:["string","null"]},source_file_size:{description:"size in bytes of the source of the schema",type:["integer","null"]},status:{description:"status of the element",type:["string","null"]},structured_aliases:{description:"A list of structured_alias objects, used to provide aliases in conjunction with additional metadata.",items:{$ref:"#/$defs/StructuredAlias"},type:["array","null"]},subsets:{additionalProperties:{anyOf:[{$ref:"#/$defs/SubsetDefinition__identifier_optional"},{type:"null"}]},description:"An index to the collection of all subset definitions in the schema",type:["object","null"]},title:{description:"A concise human-readable display label for the element. The title should mirror the name, and should use ordinary textual punctuation.",type:["string","null"]},todos:{description:"Outstanding issues that needs resolution",items:{type:"string"},type:["array","null"]},types:{additionalProperties:{anyOf:[{$ref:"#/$defs/TypeDefinition__identifier_optional"},{type:"null"}]},description:"An index to the collection of all type definitions in the schema",type:["object","null"]},version:{description:"particular version of schema",type:["string","null"]}},required:["id","name"],title:"meta",type:"object",version:null};var Gie="umf.linkml",F3e=jie,Wie=(e,t)=>t==="json"?Jt(e):Wa(e,{version:"1.1",dateOnly:"string",booleanLexicon:"pyyaml"}),Hie=new Map;function C3e(e){let t=e,n=[{code:"LINKML_CONTEXT",path:"",severity:"warning",message:"YAML 1.1 date-only scalars become lexical strings in the JSON tree; their original spelling remains archived. Metamodel shape checks do not resolve imports, induce classes/slots, normalize defaults, validate instances or run generators; JS numeric precision limits apply and edits regenerate layout with original source retained"}],r=(a,l,c,u="warning")=>n.push({code:a,path:l,message:c,severity:u});if(Object.keys(t).some((a)=>!["profile","metamodelVersion","root","originalSource","originalFormat"].includes(a)))r("LINKML_REPRESENTATION","","Unknown representation fields remain in UMF");function i(a,l){let c=a.kind==="null"?["kind"]:a.kind==="array"?["kind","items"]:a.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(a).some((u)=>!c.includes(u)))r("LINKML_REPRESENTATION",l,"Unknown tagged-tree fields remain in UMF");if(a.kind==="object")for(let[u,p]of Object.entries(a.members))i(p,l+"/"+Pe(u));if(a.kind==="array")a.items.forEach((u,p)=>i(u,l+"/"+p))}if(i(t.root,""),t.root.kind!=="object")return r("LINKML_STRUCTURE","","Expected LINKML contract object","error"),n;try{Wie(t.originalSource,t.originalFormat)}catch(a){return r("LINKML_ARCHIVE","/originalSource",String(a),"error"),n}let s=t.root.members.metamodel_version;if(t.metamodelVersion!=="1.11.0"||s&&!(s.kind==="string"&&s.value===t.metamodelVersion))return r("LINKML_VERSION","/metamodel_version","Unrecognized or conflicting metamodel version preserved without interpretation"),n;let o=Hie.get("1.11.0");if(!o){let a=new zie.default({allErrors:!0,strict:!1,validateFormats:!1,ownProperties:!0});Gp(a),o=a.compile(Jie),Hie.set("1.11.0",o)}if(!o(JSON.parse(Be(t.root))))for(let a of(o.errors??[]).slice(0,100))r("LINKML_NATIVE_SCHEMA",a.instancePath,a.message??"Native metamodel shape mismatch");if((o.errors?.length??0)>100)r("LINKML_DIAGNOSTICS_TRUNCATED","","More than 100 native schema diagnostics; first 100 retained");return n}function M3e(){return new nt().register(F3e,C3e)}function Qie(e){return We(e,M3e())}function L3e(e){let t=Qie(e);if(!t.valid)throw new U("LINKML_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[Gie];if(!n||e.vocabularies[Gie]?.version!=="0.1.0")throw new U("LINKML_PAYLOAD","Expected pinned LINKML payload");return Ae(n)}function Yie(e,t){let n=L3e(e);if(t!==void 0&&!["json","yaml"].includes(t))throw new U("LINKML_FORMAT","Unsupported native format");if(Qie(e).diagnostics.some((r)=>r.code==="LINKML_REPRESENTATION"))throw new U("LINKML_EXPORT","Unknown representation fields cannot be discarded");if((t??n.originalFormat)===n.originalFormat&&Be(Wie(n.originalSource,n.originalFormat))===Be(n.root))return n.originalSource;return Be(n.root)+` -`}var Xie={id:"umf.odcs",version:"0.1.0",coreVersion:"0.1.0",description:"ODCS source contracts, native schema shapes and copied candidates",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:odcs:0.1.0",type:"object",properties:{profile:{const:"odcs-json-yaml"},root:{$ref:"#/$defs/node"},originalSource:{type:"string",maxLength:4000000},originalFormat:{enum:["json","yaml"]}},required:["profile","root","originalSource","originalFormat"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-023; preserve exact source and unknown values; native shape validity does not enforce a data contract",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Open Data Contract Standard",version:"3.0.0/3.0.1/3.0.2/3.1.0/3.2.0 schemas at f0bdad95346905d500be5ef4b2c2d9b1d95223b7",subset:"JSON/YAML preservation and native shapes; local v3.2.0 reference/relationship checks and ID-selected rename candidates; no external resolution, quality/SLA execution or physical lowering"},evidence:["tests/odcs/odcs.test.ts","fixtures/odcs/oracle-results.json","fixtures/odcs/browser-results.json","tests/odcs/references.test.ts","tests/odcs/relationships.test.ts","tests/odcs/rename.test.ts","fixtures/odcs/rename/oracle-results.json","fixtures/odcs/rename/browser-results.json"]}};var ase=Ar(bF(),1);var Zie={$schema:"https://json-schema.org/draft/2019-09/schema",title:"Open Data Contract Standard (ODCS)",description:"An open data contract specification to establish agreement between data producers and consumers.",type:"object",properties:{version:{type:"string",description:"Current version of the data contract."},kind:{type:"string",default:"DataContract",description:"The kind of file this is. Valid value is `DataContract`.",enum:["DataContract"]},apiVersion:{type:"string",default:"v3.0.0",description:"Version of the standard used to build data contract. Default value is v3.0.0.",enum:["v3.0.0","v2.2.2","v2.2.1","v2.2.0"]},id:{type:"string",description:"A unique identifier used to reduce the risk of dataset name collisions, such as a UUID."},name:{type:"string",description:"Name of the data contract."},tenant:{type:"string",description:"Indicates the property the data is primarily associated with. Value is case insensitive."},tags:{$ref:"#/$defs/Tags"},status:{type:"string",description:"Current status of the dataset. Valid values are `production`, `test`, or `development`.",examples:["production","test","development"]},servers:{type:"array",description:"List of servers where the datasets reside.",items:{$ref:"#/$defs/Server"}},dataProduct:{type:"string",description:"The name of the data product."},description:{type:"object",description:"High level description of the dataset.",properties:{usage:{type:"string",description:"Intended usage of the dataset."},purpose:{type:"string",description:"Purpose of the dataset."},limitations:{type:"string",description:"Limitations of the dataset."}}},domain:{type:"string",description:"Name of the logical data domain.",examples:["imdb_ds_aggregate","receiver_profile_out","transaction_profile_out"]},schema:{type:"array",description:"A list of elements within the schema to be cataloged.",items:{$ref:"#/$defs/SchemaObject"}},support:{$ref:"#/$defs/Support"},price:{$ref:"#/$defs/Pricing"},team:{type:"array",items:{$ref:"#/$defs/Team"}},roles:{type:"array",description:"A list of roles that will provide user access to the dataset.",items:{$ref:"#/$defs/Role"}},slaDefaultElement:{type:"string",description:"Element (using the element path notation) to do the checks on."},slaProperties:{type:"array",description:"A list of key/value pairs for SLA specific properties. There is no limit on the type of properties (more details to come).",items:{$ref:"#/$defs/ServiceLevelAgreementProperty"}},customProperties:{$ref:"#/$defs/CustomProperties"},contractCreatedTs:{type:"string",format:"date-time",description:"Timestamp in UTC of when the data contract was created."}},required:["version","apiVersion","kind","id","status"],additionalProperties:!1,$defs:{Server:{type:"object",description:"Data source details of where data is physically stored.",properties:{server:{type:"string",description:"Identifier of the server."},type:{type:"string",description:"Type of the server.",enum:["api","athena","azure","bigquery","clickhouse","databricks","denodo","dremio","duckdb","glue","cloudsql","db2","informix","kafka","kinesis","local","mysql","oracle","postgresql","postgres","presto","pubsub","redshift","s3","sftp","snowflake","sqlserver","synapse","trino","vertica","custom"]},description:{type:"string",description:"Description of the server."},environment:{type:"string",description:"Environment of the server.",examples:["prod","preprod","dev","uat"]},roles:{type:"array",description:"List of roles that have access to the server.",items:{$ref:"#/$defs/Role"}},customProperties:{$ref:"#/$defs/CustomProperties"}},allOf:[{if:{properties:{type:{const:"api"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ApiServer"}},{if:{properties:{type:{const:"athena"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AthenaServer"}},{if:{properties:{type:{const:"azure"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AzureServer"}},{if:{properties:{type:{const:"bigquery"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/BigQueryServer"}},{if:{properties:{type:{const:"clickhouse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ClickHouseServer"}},{if:{properties:{type:{const:"databricks"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DatabricksServer"}},{if:{properties:{type:{const:"denodo"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DenodoServer"}},{if:{properties:{type:{const:"dremio"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DremioServer"}},{if:{properties:{type:{const:"duckdb"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DuckdbServer"}},{if:{properties:{type:{const:"glue"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GlueServer"}},{if:{properties:{type:{const:"cloudsql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GoogleCloudSqlServer"}},{if:{properties:{type:{const:"db2"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/IBMDB2Server"}},{if:{properties:{type:{const:"informix"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/InformixServer"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/CustomServer"}},{if:{properties:{type:{const:"kafka"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KafkaServer"}},{if:{properties:{type:{const:"kinesis"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KinesisServer"}},{if:{properties:{type:{const:"local"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/LocalServer"}},{if:{properties:{type:{const:"mysql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/MySqlServer"}},{if:{properties:{type:{const:"oracle"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/OracleServer"}},{if:{properties:{type:{const:"postgresql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"postgres"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"presto"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PrestoServer"}},{if:{properties:{type:{const:"pubsub"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PubSubServer"}},{if:{properties:{type:{const:"redshift"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/RedshiftServer"}},{if:{properties:{type:{const:"s3"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/S3Server"}},{if:{properties:{type:{const:"sftp"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SftpServer"}},{if:{properties:{type:{const:"snowflake"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SnowflakeServer"}},{if:{properties:{type:{const:"sqlserver"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SqlserverServer"}},{if:{properties:{type:{const:"synapse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SynapseServer"}},{if:{properties:{type:{const:"trino"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/TrinoServer"}},{if:{properties:{type:{const:"vertica"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/VerticaServer"}}],required:["server","type"]},ServerSource:{ApiServer:{type:"object",title:"AthenaServer",properties:{location:{type:"string",format:"uri",description:"The url to the API.",examples:["https://api.example.com/v1"]}},required:["location"]},AthenaServer:{type:"object",title:"AthenaServer",properties:{stagingDir:{type:"string",format:"uri",description:"Amazon Athena automatically stores query results and metadata information for each query that runs in a query result location that you can specify in Amazon S3.",examples:["s3://my_storage_account_name/my_container/path"]},schema:{type:"string",description:"Identify the schema in the data source in which your tables exist."},catalog:{type:"string",description:"Identify the name of the Data Source, also referred to as a Catalog.",default:"awsdatacatalog"},regionName:{type:"string",description:"The region your AWS account uses.",examples:["eu-west-1"]}},required:["staging_dir","schema"]},AzureServer:{type:"object",title:"AzureServer",properties:{location:{type:"string",format:"uri",description:"Fully qualified path to Azure Blob Storage or Azure Data Lake Storage (ADLS), supports globs.",examples:["az://my_storage_account_name.blob.core.windows.net/my_container/path/*.parquet","abfss://my_storage_account_name.dfs.core.windows.net/my_container_name/path/*.parquet"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location","format"]},BigQueryServer:{type:"object",title:"BigQueryServer",properties:{project:{type:"string",description:"The GCP project name."},dataset:{type:"string",description:"The GCP dataset name."}},required:["project","dataset"]},ClickHouseServer:{type:"object",title:"ClickHouseServer",properties:{host:{type:"string",description:"The host of the ClickHouse server."},port:{type:"integer",description:"The port to the ClickHouse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},DatabricksServer:{type:"object",title:"DatabricksServer",properties:{host:{type:"string",description:"The Databricks host",examples:["dbc-abcdefgh-1234.cloud.databricks.com"]},catalog:{type:"string",description:"The name of the Hive or Unity catalog"},schema:{type:"string",description:"The schema name in the catalog"}},required:["catalog","schema"]},DenodoServer:{type:"object",title:"DenodoServer",properties:{host:{type:"string",description:"The host of the Denodo server."},port:{type:"integer",description:"The port of the Denodo server."},database:{type:"string",description:"The name of the database."}},required:["host","port"]},DremioServer:{type:"object",title:"DremioServer",properties:{host:{type:"string",description:"The host of the Dremio server."},port:{type:"integer",description:"The port of the Dremio server."},schema:{type:"string",description:"The name of the schema."}},required:["host","port"]},DuckdbServer:{type:"object",title:"DuckdbServer",properties:{database:{type:"string",description:"Path to duckdb database file."},schema:{type:"integer",description:"The name of the schema."}},required:["database"]},GlueServer:{type:"object",title:"GlueServer",properties:{account:{type:"string",description:"The AWS Glue account",examples:["1234-5678-9012"]},database:{type:"string",description:"The AWS Glue database name",examples:["my_database"]},location:{type:"string",format:"uri",description:"The AWS S3 path. Must be in the form of a URL.",examples:["s3://datacontract-example-orders-latest/data/{model}"]},format:{type:"string",description:"The format of the files",examples:["parquet","csv","json","delta"]}},required:["account","database"]},GoogleCloudSqlServer:{type:"object",title:"GoogleCloudSqlServer",properties:{host:{type:"string",description:"The host of the Google Cloud Sql server."},port:{type:"integer",description:"The port of the Google Cloud Sql server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]},IBMDB2Server:{type:"object",title:"IBMDB2Server",properties:{host:{type:"string",description:"The host of the IBM DB2 server."},port:{type:"integer",description:"The port of the IBM DB2 server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database"]},InformixServer:{type:"object",title:"InformixServer",properties:{host:{type:"string",description:"The host to the Informix server. "},port:{type:"integer",description:"The port to the Informix server. Defaults to 9088."},database:{type:"string",description:"The name of the database."}},required:["host","database"]},CustomServer:{type:"object",title:"CustomServer",properties:{account:{type:"string",description:"Account used by the server."},catalog:{type:"string",description:"Name of the catalog."},database:{type:"string",description:"Name of the database."},dataset:{type:"string",description:"Name of the dataset."},delimiter:{type:"string",description:"Delimiter."},endpointUrl:{type:"string",description:"Server endpoint.",format:"uri"},format:{type:"string",description:"File format."},host:{type:"string",description:"Host name or IP address."},location:{type:"string",description:"A URL to a location.",format:"uri"},path:{type:"string",description:"Relative or absolute path to the data file(s)."},port:{type:"integer",description:"Port to the server. No default value is assumed for custom servers."},project:{type:"string",description:"Project name."},region:{type:"string",description:"Cloud region."},regionName:{type:"string",description:"Region name."},schema:{type:"string",description:"Name of the schema."},serviceName:{type:"string",description:"Name of the service."},stagingDir:{type:"string",description:"Staging directory."},warehouse:{type:"string",description:"Name of the cluster or warehouse."}}},KafkaServer:{type:"object",title:"KafkaServer",description:"Kafka Server",properties:{host:{type:"string",description:"The bootstrap server of the kafka cluster."},format:{type:"string",description:"The format of the messages.",examples:["json","avro","protobuf","xml"],default:"json"}},required:["host"]},KinesisServer:{type:"object",title:"KinesisDataStreamsServer",description:"Kinesis Data Streams Server",properties:{region:{type:"string",description:"AWS region.",examples:["eu-west-1"]},format:{type:"string",description:"The format of the record",examples:["json","avro","protobuf"]}}},LocalServer:{type:"object",title:"LocalServer",properties:{path:{type:"string",description:"The relative or absolute path to the data file(s).",examples:["./folder/data.parquet","./folder/*.parquet"]},format:{type:"string",description:"The format of the file(s)",examples:["json","parquet","delta","csv"]}},required:["path","format"]},MySqlServer:{type:"object",title:"MySqlServer",properties:{host:{type:"string",description:"The host of the MySql server."},port:{type:"integer",description:"The port of the MySql server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},OracleServer:{type:"object",title:"OracleServer",properties:{host:{type:"string",description:"The host to the oracle server",examples:["localhost"]},port:{type:"integer",description:"The port to the oracle server.",examples:[1523]},serviceName:{type:"string",description:"The name of the service.",examples:["service"]}},required:["host","port","serviceName"]},PostgresServer:{type:"object",title:"PostgresServer",properties:{host:{type:"string",description:"The host to the Postgres server"},port:{type:"integer",description:"The port to the Postgres server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema in the database."}},required:["host","port","database","schema"]},PrestoServer:{type:"object",title:"PrestoServer",properties:{host:{type:"string",description:"The host to the Presto server",examples:["localhost:8080"]},catalog:{type:"string",description:"The name of the catalog.",examples:["postgres"]},schema:{type:"string",description:"The name of the schema.",examples:["public"]}},required:["host"]},PubSubServer:{type:"object",title:"PubSubServer",properties:{project:{type:"string",description:"The GCP project name."}},required:["project"]},RedshiftServer:{type:"object",title:"RedshiftServer",properties:{host:{type:"string",description:"An optional string describing the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},region:{type:"string",description:"AWS region of Redshift server.",examples:["us-east-1"]},account:{type:"string",description:"The account used by the server."}},required:["database","schema"]},S3Server:{type:"object",title:"S3Server",properties:{location:{type:"string",format:"uri",description:"S3 URL, starting with `s3://`",examples:["s3://datacontract-example-orders-latest/data/{model}/*.json"]},endpointUrl:{type:"string",format:"uri",description:"The server endpoint for S3-compatible servers.",examples:["https://minio.example.com"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SftpServer:{type:"object",title:"SftpServer",properties:{location:{type:"string",format:"uri",pattern:"^sftp://.*",description:"SFTP URL, starting with `sftp://`",examples:["sftp://123.123.12.123/{model}/*.json"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SnowflakeServer:{type:"object",title:"SnowflakeServer",properties:{host:{type:"string",description:"The host to the Snowflake server"},port:{type:"integer",description:"The port to the Snowflake server."},account:{type:"string",description:"The Snowflake account used by the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},warehouse:{type:"string",description:"The name of the cluster of resources that is a Snowflake virtual warehouse."}},required:["account","database","schema"]},SqlserverServer:{type:"object",title:"SqlserverServer",properties:{host:{type:"string",description:"The host to the database server",examples:["localhost"]},port:{type:"integer",description:"The port to the database server.",default:1433,examples:[1433]},database:{type:"string",description:"The name of the database.",examples:["database"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["dbo"]}},required:["host","database","schema"]},SynapseServer:{type:"object",title:"SynapseServer",properties:{host:{type:"string",description:"The host of the Synapse server."},port:{type:"integer",description:"The port of the Synapse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},TrinoServer:{type:"object",title:"TrinoServer",properties:{host:{type:"string",description:"The Trino host URL.",examples:["localhost"]},port:{type:"integer",description:"The Trino port."},catalog:{type:"string",description:"The name of the catalog.",examples:["hive"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["my_schema"]}},required:["host","port","catalog","schema"]},VerticaServer:{type:"object",title:"VerticaServer",properties:{host:{type:"string",description:"The host of the Vertica server."},port:{type:"integer",description:"The port of the Vertica server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]}},SchemaElement:{type:"object",properties:{name:{type:"string",description:"Name of the element."},physicalType:{type:"string",description:"The physical element data type in the data source.",examples:["table","view","topic","file"]},description:{type:"string",description:"Description of the element."},businessName:{type:"string",description:"The business name of the element."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{$ref:"#/$defs/Tags"},customProperties:{$ref:"#/$defs/CustomProperties"}}},SchemaObject:{type:"object",properties:{logicalType:{type:"string",description:"The logical element data type.",enum:["object"]},physicalName:{type:"string",description:"Physical name.",examples:["table_1_2_0"]},dataGranularityDescription:{type:"string",description:"Granular level of the data in the object.",examples:["Aggregation by country"]},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"}],required:["name"],unevaluatedProperties:!1},SchemaBaseProperty:{type:"object",properties:{primaryKey:{type:"boolean",description:"Boolean value specifying whether the element is primary or not. Default is false."},primaryKeyPosition:{type:"integer",default:-1,description:"If element is a primary key, the position of the primary key element. Starts from 1. Example of `account_id, name` being primary key columns, `account_id` has primaryKeyPosition 1 and `name` primaryKeyPosition 2. Default to -1."},logicalType:{type:"string",description:"The logical element data type.",enum:["string","date","number","integer","object","array","boolean"]},logicalTypeOptions:{type:"object",description:"Additional optional metadata to describe the logical type."},physicalType:{type:"string",description:"The physical element data type in the data source. For example, VARCHAR(2), DOUBLE, INT."},required:{type:"boolean",default:!1,description:"Indicates if the element may contain Null values; possible values are true and false. Default is false."},unique:{type:"boolean",default:!1,description:"Indicates if the element contains unique values; possible values are true and false. Default is false."},partitioned:{type:"boolean",default:!1,description:"Indicates if the element is partitioned; possible values are true and false."},partitionKeyPosition:{type:"integer",default:-1,description:"If element is used for partitioning, the position of the partition element. Starts from 1. Example of `country, year` being partition columns, `country` has partitionKeyPosition 1 and `year` partitionKeyPosition 2. Default to -1."},classification:{type:"string",description:"Can be anything, like confidential, restricted, and public to more advanced categorization. Some companies like PayPal, use data classification indicating the class of data in the element; expected values are 1, 2, 3, 4, or 5.",examples:["confidential","restricted","public"]},encryptedName:{type:"string",description:"The element name within the dataset that contains the encrypted element value. For example, unencrypted element `email_address` might have an encryptedName of `email_address_encrypt`."},transformSourceObjects:{type:"array",description:"List of objects in the data source used in the transformation.",items:{type:"string"}},transformLogic:{type:"string",description:"Logic used in the element transformation."},transformDescription:{type:"string",description:"Describes the transform logic in very simple terms."},examples:{type:"array",description:"List of sample element values.",items:{$ref:"#/$defs/AnyType"}},criticalDataElement:{type:"boolean",default:!1,description:"True or false indicator; If element is considered a critical data element (CDE) then true else false."},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"},{if:{properties:{logicalType:{const:"string"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{minLength:{type:"integer",minimum:0,description:"Minimum length of the string."},maxLength:{type:"integer",minimum:0,description:"Maximum length of the string."},pattern:{type:"string",description:"Regular expression pattern to define valid value. Follows regular expression syntax from ECMA-262 (https://262.ecma-international.org/5.1/#sec-15.10.1)."},format:{type:"string",examples:["password","byte","binary","email","uuid","uri","hostname","ipv4","ipv6"],description:"Provides extra context about what format the string follows."}},additionalProperties:!1}}}},{if:{properties:{logicalType:{const:"date"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{format:{type:"string",examples:["yyyy-MM-dd","yyyy-MM-dd HH:mm:ss","HH:mm:ss"],description:"Format of the date. Follows the format as prescribed by [JDK DateTimeFormatter](https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html). For example, format 'yyyy-MM-dd'."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},maximum:{type:"string",description:"All date values are less than or equal to this value (values <= maximum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},minimum:{type:"string",description:"All date values are greater than or equal to this value (values >= minimum)."}},additionalProperties:!1}}}},{if:{anyOf:[{properties:{logicalType:{const:"integer"}}}]},then:{properties:{logicalTypeOptions:{type:"object",properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use and whether it is signed or unsigned (follows the Rust integer types).",enum:["i8","i16","i32","i64","i128","u8","u16","u32","u64","u128"]}},additionalProperties:!1}}}},{if:{anyOf:[{properties:{logicalType:{const:"number"}}}]},then:{properties:{logicalTypeOptions:{type:"object",properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use (follows the Rust float types).",enum:["f32","f64"]}},additionalProperties:!1}}}},{if:{properties:{logicalType:{const:"object"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{maxProperties:{type:"integer",minimum:0,description:"Maximum number of properties."},minProperties:{type:"integer",minimum:0,default:0,description:"Minimum number of properties."},required:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0,description:"Property names that are required to exist in the object."}},additionalProperties:!1},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}}}},{if:{properties:{logicalType:{const:"array"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{maxItems:{type:"integer",minimum:0,description:"Maximum number of items."},minItems:{type:"integer",minimum:0,default:0,description:"Minimum number of items"},uniqueItems:{type:"boolean",default:!1,description:"If set to true, all items in the array are unique."}},additionalProperties:!1},items:{$ref:"#/$defs/SchemaItemProperty",description:"List of items in an array (only applicable when `logicalType: array`)."}}}}]},SchemaProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",required:["name"],unevaluatedProperties:!1},SchemaItemProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",properties:{properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}},unevaluatedProperties:!1},Tags:{type:"array",description:"A list of tags that may be assigned to the elements (object or property); the tags keyword may appear at any level.",items:{type:"string"}},DataQuality:{type:"object",properties:{authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},businessImpact:{type:"string",description:"Consequences of the rule failure.",examples:["operational","regulatory"]},customProperties:{type:"array",description:"Additional properties required for rule execution.",items:{$ref:"#/$defs/CustomProperty"}},description:{type:"string",description:"Describe the quality check to be completed."},dimension:{type:"string",description:"The key performance indicator (KPI) or dimension for data quality.",enum:["accuracy","completeness","conformity","consistency","coverage","timeliness","uniqueness"]},method:{type:"string",examples:["reconciliation"]},name:{type:"string",description:"Name of the data quality check."},schedule:{type:"string",description:"Rule execution schedule details.",examples:["0 20 * * *"]},scheduler:{type:"string",description:"The name or type of scheduler used to start the data quality check.",examples:["cron"]},severity:{type:"string",description:"The severance of the quality rule.",examples:["info","warning","error"]},tags:{$ref:"#/$defs/Tags"},type:{type:"string",description:"The type of quality check. 'text' is human-readable text that describes the quality of the data. 'library' is a set of maintained predefined quality attributes such as row count or unique. 'sql' is an individual SQL query that returns a value that can be compared. 'custom' is quality attributes that are vendor-specific, such as Soda or Great Expectations.",enum:["text","library","sql","custom"],default:"library"},unit:{type:"string",description:"Unit the rule is using, popular values are `rows` or `percent`, but any value is allowed.",examples:["rows","percent"]}},allOf:[{if:{properties:{type:{const:"library"}}},then:{$ref:"#/$defs/DataQualityLibrary"}},{if:{properties:{type:{const:"sql"}},required:["type"]},then:{$ref:"#/$defs/DataQualitySql"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/DataQualityCustom"}}]},DataQualityChecks:{type:"array",description:"Data quality rules with all the relevant information for rule setup and execution.",items:{$ref:"#/$defs/DataQuality"}},DataQualityLibrary:{type:"object",properties:{rule:{type:"string",description:"Define a data quality check based on the predefined rules as per ODCS.",examples:["duplicateCount","validValues","rowCount"]},mustBe:{description:"Must be equal to the value to be valid. When using numbers, it is equivalent to '='."},mustNotBe:{description:"Must not be equal to the value to be valid. When using numbers, it is equivalent to '!='."},mustBeGreaterThan:{type:"number",description:"Must be greater than the value to be valid. It is equivalent to '>'."},mustBeGreaterOrEqualTo:{type:"number",description:"Must be greater than or equal to the value to be valid. It is equivalent to '>='."},mustBeLessThan:{type:"number",description:"Must be less than the value to be valid. It is equivalent to '<'."},mustBeLessOrEqualTo:{type:"number",description:"Must be less than or equal to the value to be valid. It is equivalent to '<='."},mustBeBetween:{type:"array",description:"Must be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}},mustNotBeBetween:{type:"array",description:"Must not be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}}},required:["rule"]},DataQualitySql:{type:"object",properties:{query:{type:"string",description:"Query string that adheres to the dialect of the provided server.",examples:["SELECT COUNT(*) FROM ${table} WHERE ${column} IS NOT NULL"]}},required:["query"]},DataQualityCustom:{type:"object",properties:{engine:{type:"string",description:"Name of the engine which executes the data quality checks.",examples:["soda","great-expectations","monte-carlo","dbt"]},implementation:{oneOf:[{type:"string"},{type:"object"}]}},required:["engine","implementation"]},AuthoritativeDefinitions:{type:"array",description:"List of links to sources that provide more details on the dataset; examples would be a link to an external definition, a training video, a GitHub repo, Collibra, or another tool. Authoritative definitions follow the same structure in the standard.",items:{type:"object",properties:{url:{type:"string",description:"URL to the authority."},type:{type:"string",description:"Type of definition for authority: v2.3 adds standard values: `businessDefinition`, `transformationImplementation`, `videoTutorial`, `tutorial`, and `implementation`.",examples:["businessDefinition","transformationImplementation","videoTutorial","tutorial","implementation"]}},required:["url","type"]}},Support:{type:"array",description:"Top level for support channels.",items:{$ref:"#/$defs/SupportItem"}},SupportItem:{type:"object",properties:{channel:{type:"string",description:"Channel name or identifier."},url:{type:"string",description:"Access URL using normal [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax) (https, mailto, etc.)."},description:{type:"string",description:"Description of the channel, free text."},tool:{type:"string",description:"Name of the tool, value can be `email`, `slack`, `teams`, `discord`, `ticket`, or `other`.",examples:["email","slack","teams","discord","ticket","other"]},scope:{type:"string",description:"Scope can be: `interactive`, `announcements`, `issues`.",examples:["interactive","announcements","issues"]},invitationUrl:{type:"string",description:"Some tools uses invitation URL for requesting or subscribing. Follows the [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax)."}},required:["channel","url"]},Pricing:{type:"object",properties:{priceAmount:{type:"number",description:"Subscription price per unit of measure in `priceUnit`."},priceCurrency:{type:"string",description:"Currency of the subscription price in `price.priceAmount`."},priceUnit:{type:"string",description:"The unit of measure for calculating cost. Examples megabyte, gigabyte."}}},Team:{type:"object",properties:{username:{type:"string",description:"The user's username or email."},role:{type:"string",description:"The user's job role; Examples might be owner, data steward. There is no limit on the role."},dateIn:{type:"string",format:"date",description:"The date when the user joined the team."},dateOut:{type:"string",format:"date",description:"The date when the user ceased to be part of the team."},replacedByUsername:{type:"string",description:"The username of the user who replaced the previous user."}}},Role:{type:"object",properties:{role:{type:"string",description:"Name of the IAM role that provides access to the dataset."},description:{type:"string",description:"Description of the IAM role and its permissions."},access:{type:"string",description:"The type of access provided by the IAM role."},firstLevelApprovers:{type:"string",description:"The name(s) of the first-level approver(s) of the role."},secondLevelApprovers:{type:"string",description:"The name(s) of the second-level approver(s) of the role."}},required:["role"]},ServiceLevelAgreementProperty:{type:"object",properties:{property:{type:"string",description:"Specific property in SLA, check the periodic table. May requires units (more details to come)."},value:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}],description:"Agreement value. The label will change based on the property itself."},valueExt:{$ref:"#/$defs/AnyNonCollectionType",description:"Extended agreement value. The label will change based on the property itself."},unit:{type:"string",description:"**d**, day, days for days; **y**, yr, years for years, etc. Units use the ISO standard."},element:{type:"string",description:"Element(s) to check on. Multiple elements should be extremely rare and, if so, separated by commas."},driver:{type:"string",description:"Describes the importance of the SLA from the list of: `regulatory`, `analytics`, or `operational`.",examples:["regulatory","analytics","operational"]}},required:["property","value"]},CustomProperties:{type:"array",description:"A list of key/value pairs for custom properties.",items:{$ref:"#/$defs/CustomProperty"}},CustomProperty:{type:"object",properties:{property:{type:"string",description:"The name of the key. Names should be in camel case–the same as if they were permanent properties in the contract."},value:{$ref:"#/$defs/AnyType",description:"The value of the key."}}},AnyType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"},{type:"array"},{type:"object"}]},AnyNonCollectionType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}]}}};var ese={$schema:"https://json-schema.org/draft/2019-09/schema",title:"Open Data Contract Standard (ODCS)",description:"An open data contract specification to establish agreement between data producers and consumers.",type:"object",properties:{version:{type:"string",description:"Current version of the data contract."},kind:{type:"string",default:"DataContract",description:"The kind of file this is. Valid value is `DataContract`.",enum:["DataContract"]},apiVersion:{type:"string",default:"v3.0.1",description:"Version of the standard used to build data contract. Default value is v3.0.1.",enum:["v3.0.1","v3.0.0","v2.2.2","v2.2.1","v2.2.0"]},id:{type:"string",description:"A unique identifier used to reduce the risk of dataset name collisions, such as a UUID."},name:{type:"string",description:"Name of the data contract."},tenant:{type:"string",description:"Indicates the property the data is primarily associated with. Value is case insensitive."},tags:{$ref:"#/$defs/Tags"},status:{type:"string",description:"Current status of the dataset.",examples:["proposed","draft","active","deprecated","retired"]},servers:{type:"array",description:"List of servers where the datasets reside.",items:{$ref:"#/$defs/Server"}},dataProduct:{type:"string",description:"The name of the data product."},description:{type:"object",description:"High level description of the dataset.",properties:{usage:{type:"string",description:"Intended usage of the dataset."},purpose:{type:"string",description:"Purpose of the dataset."},limitations:{type:"string",description:"Limitations of the dataset."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"}}},domain:{type:"string",description:"Name of the logical data domain.",examples:["imdb_ds_aggregate","receiver_profile_out","transaction_profile_out"]},schema:{type:"array",description:"A list of elements within the schema to be cataloged.",items:{$ref:"#/$defs/SchemaObject"}},support:{$ref:"#/$defs/Support"},price:{$ref:"#/$defs/Pricing"},team:{type:"array",items:{$ref:"#/$defs/Team"}},roles:{type:"array",description:"A list of roles that will provide user access to the dataset.",items:{$ref:"#/$defs/Role"}},slaDefaultElement:{type:"string",description:"Element (using the element path notation) to do the checks on."},slaProperties:{type:"array",description:"A list of key/value pairs for SLA specific properties. There is no limit on the type of properties (more details to come).",items:{$ref:"#/$defs/ServiceLevelAgreementProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"},contractCreatedTs:{type:"string",format:"date-time",description:"Timestamp in UTC of when the data contract was created."}},required:["version","apiVersion","kind","id","status"],additionalProperties:!1,$defs:{Server:{type:"object",description:"Data source details of where data is physically stored.",properties:{server:{type:"string",description:"Identifier of the server."},type:{type:"string",description:"Type of the server.",enum:["api","athena","azure","bigquery","clickhouse","databricks","denodo","dremio","duckdb","glue","cloudsql","db2","informix","kafka","kinesis","local","mysql","oracle","postgresql","postgres","presto","pubsub","redshift","s3","sftp","snowflake","sqlserver","synapse","trino","vertica","custom"]},description:{type:"string",description:"Description of the server."},environment:{type:"string",description:"Environment of the server.",examples:["prod","preprod","dev","uat"]},roles:{type:"array",description:"List of roles that have access to the server.",items:{$ref:"#/$defs/Role"}},customProperties:{$ref:"#/$defs/CustomProperties"}},allOf:[{if:{properties:{type:{const:"api"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ApiServer"}},{if:{properties:{type:{const:"athena"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AthenaServer"}},{if:{properties:{type:{const:"azure"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AzureServer"}},{if:{properties:{type:{const:"bigquery"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/BigQueryServer"}},{if:{properties:{type:{const:"clickhouse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ClickHouseServer"}},{if:{properties:{type:{const:"databricks"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DatabricksServer"}},{if:{properties:{type:{const:"denodo"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DenodoServer"}},{if:{properties:{type:{const:"dremio"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DremioServer"}},{if:{properties:{type:{const:"duckdb"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DuckdbServer"}},{if:{properties:{type:{const:"glue"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GlueServer"}},{if:{properties:{type:{const:"cloudsql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GoogleCloudSqlServer"}},{if:{properties:{type:{const:"db2"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/IBMDB2Server"}},{if:{properties:{type:{const:"informix"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/InformixServer"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/CustomServer"}},{if:{properties:{type:{const:"kafka"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KafkaServer"}},{if:{properties:{type:{const:"kinesis"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KinesisServer"}},{if:{properties:{type:{const:"local"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/LocalServer"}},{if:{properties:{type:{const:"mysql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/MySqlServer"}},{if:{properties:{type:{const:"oracle"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/OracleServer"}},{if:{properties:{type:{const:"postgresql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"postgres"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"presto"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PrestoServer"}},{if:{properties:{type:{const:"pubsub"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PubSubServer"}},{if:{properties:{type:{const:"redshift"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/RedshiftServer"}},{if:{properties:{type:{const:"s3"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/S3Server"}},{if:{properties:{type:{const:"sftp"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SftpServer"}},{if:{properties:{type:{const:"snowflake"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SnowflakeServer"}},{if:{properties:{type:{const:"sqlserver"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SqlserverServer"}},{if:{properties:{type:{const:"synapse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SynapseServer"}},{if:{properties:{type:{const:"trino"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/TrinoServer"}},{if:{properties:{type:{const:"vertica"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/VerticaServer"}}],required:["server","type"]},ServerSource:{ApiServer:{type:"object",title:"AthenaServer",properties:{location:{type:"string",format:"uri",description:"The url to the API.",examples:["https://api.example.com/v1"]}},required:["location"]},AthenaServer:{type:"object",title:"AthenaServer",properties:{stagingDir:{type:"string",format:"uri",description:"Amazon Athena automatically stores query results and metadata information for each query that runs in a query result location that you can specify in Amazon S3.",examples:["s3://my_storage_account_name/my_container/path"]},schema:{type:"string",description:"Identify the schema in the data source in which your tables exist."},catalog:{type:"string",description:"Identify the name of the Data Source, also referred to as a Catalog.",default:"awsdatacatalog"},regionName:{type:"string",description:"The region your AWS account uses.",examples:["eu-west-1"]}},required:["staging_dir","schema"]},AzureServer:{type:"object",title:"AzureServer",properties:{location:{type:"string",format:"uri",description:"Fully qualified path to Azure Blob Storage or Azure Data Lake Storage (ADLS), supports globs.",examples:["az://my_storage_account_name.blob.core.windows.net/my_container/path/*.parquet","abfss://my_storage_account_name.dfs.core.windows.net/my_container_name/path/*.parquet"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location","format"]},BigQueryServer:{type:"object",title:"BigQueryServer",properties:{project:{type:"string",description:"The GCP project name."},dataset:{type:"string",description:"The GCP dataset name."}},required:["project","dataset"]},ClickHouseServer:{type:"object",title:"ClickHouseServer",properties:{host:{type:"string",description:"The host of the ClickHouse server."},port:{type:"integer",description:"The port to the ClickHouse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},DatabricksServer:{type:"object",title:"DatabricksServer",properties:{host:{type:"string",description:"The Databricks host",examples:["dbc-abcdefgh-1234.cloud.databricks.com"]},catalog:{type:"string",description:"The name of the Hive or Unity catalog"},schema:{type:"string",description:"The schema name in the catalog"}},required:["catalog","schema"]},DenodoServer:{type:"object",title:"DenodoServer",properties:{host:{type:"string",description:"The host of the Denodo server."},port:{type:"integer",description:"The port of the Denodo server."},database:{type:"string",description:"The name of the database."}},required:["host","port"]},DremioServer:{type:"object",title:"DremioServer",properties:{host:{type:"string",description:"The host of the Dremio server."},port:{type:"integer",description:"The port of the Dremio server."},schema:{type:"string",description:"The name of the schema."}},required:["host","port"]},DuckdbServer:{type:"object",title:"DuckdbServer",properties:{database:{type:"string",description:"Path to duckdb database file."},schema:{type:"integer",description:"The name of the schema."}},required:["database"]},GlueServer:{type:"object",title:"GlueServer",properties:{account:{type:"string",description:"The AWS Glue account",examples:["1234-5678-9012"]},database:{type:"string",description:"The AWS Glue database name",examples:["my_database"]},location:{type:"string",format:"uri",description:"The AWS S3 path. Must be in the form of a URL.",examples:["s3://datacontract-example-orders-latest/data/{model}"]},format:{type:"string",description:"The format of the files",examples:["parquet","csv","json","delta"]}},required:["account","database"]},GoogleCloudSqlServer:{type:"object",title:"GoogleCloudSqlServer",properties:{host:{type:"string",description:"The host of the Google Cloud Sql server."},port:{type:"integer",description:"The port of the Google Cloud Sql server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]},IBMDB2Server:{type:"object",title:"IBMDB2Server",properties:{host:{type:"string",description:"The host of the IBM DB2 server."},port:{type:"integer",description:"The port of the IBM DB2 server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database"]},InformixServer:{type:"object",title:"InformixServer",properties:{host:{type:"string",description:"The host to the Informix server. "},port:{type:"integer",description:"The port to the Informix server. Defaults to 9088."},database:{type:"string",description:"The name of the database."}},required:["host","database"]},CustomServer:{type:"object",title:"CustomServer",properties:{account:{type:"string",description:"Account used by the server."},catalog:{type:"string",description:"Name of the catalog."},database:{type:"string",description:"Name of the database."},dataset:{type:"string",description:"Name of the dataset."},delimiter:{type:"string",description:"Delimiter."},endpointUrl:{type:"string",description:"Server endpoint.",format:"uri"},format:{type:"string",description:"File format."},host:{type:"string",description:"Host name or IP address."},location:{type:"string",description:"A URL to a location.",format:"uri"},path:{type:"string",description:"Relative or absolute path to the data file(s)."},port:{type:"integer",description:"Port to the server. No default value is assumed for custom servers."},project:{type:"string",description:"Project name."},region:{type:"string",description:"Cloud region."},regionName:{type:"string",description:"Region name."},schema:{type:"string",description:"Name of the schema."},serviceName:{type:"string",description:"Name of the service."},stagingDir:{type:"string",description:"Staging directory."},warehouse:{type:"string",description:"Name of the cluster or warehouse."}}},KafkaServer:{type:"object",title:"KafkaServer",description:"Kafka Server",properties:{host:{type:"string",description:"The bootstrap server of the kafka cluster."},format:{type:"string",description:"The format of the messages.",examples:["json","avro","protobuf","xml"],default:"json"}},required:["host"]},KinesisServer:{type:"object",title:"KinesisDataStreamsServer",description:"Kinesis Data Streams Server",properties:{region:{type:"string",description:"AWS region.",examples:["eu-west-1"]},format:{type:"string",description:"The format of the record",examples:["json","avro","protobuf"]}}},LocalServer:{type:"object",title:"LocalServer",properties:{path:{type:"string",description:"The relative or absolute path to the data file(s).",examples:["./folder/data.parquet","./folder/*.parquet"]},format:{type:"string",description:"The format of the file(s)",examples:["json","parquet","delta","csv"]}},required:["path","format"]},MySqlServer:{type:"object",title:"MySqlServer",properties:{host:{type:"string",description:"The host of the MySql server."},port:{type:"integer",description:"The port of the MySql server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},OracleServer:{type:"object",title:"OracleServer",properties:{host:{type:"string",description:"The host to the oracle server",examples:["localhost"]},port:{type:"integer",description:"The port to the oracle server.",examples:[1523]},serviceName:{type:"string",description:"The name of the service.",examples:["service"]}},required:["host","port","serviceName"]},PostgresServer:{type:"object",title:"PostgresServer",properties:{host:{type:"string",description:"The host to the Postgres server"},port:{type:"integer",description:"The port to the Postgres server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema in the database."}},required:["host","port","database","schema"]},PrestoServer:{type:"object",title:"PrestoServer",properties:{host:{type:"string",description:"The host to the Presto server",examples:["localhost:8080"]},catalog:{type:"string",description:"The name of the catalog.",examples:["postgres"]},schema:{type:"string",description:"The name of the schema.",examples:["public"]}},required:["host"]},PubSubServer:{type:"object",title:"PubSubServer",properties:{project:{type:"string",description:"The GCP project name."}},required:["project"]},RedshiftServer:{type:"object",title:"RedshiftServer",properties:{host:{type:"string",description:"An optional string describing the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},region:{type:"string",description:"AWS region of Redshift server.",examples:["us-east-1"]},account:{type:"string",description:"The account used by the server."}},required:["database","schema"]},S3Server:{type:"object",title:"S3Server",properties:{location:{type:"string",format:"uri",description:"S3 URL, starting with `s3://`",examples:["s3://datacontract-example-orders-latest/data/{model}/*.json"]},endpointUrl:{type:"string",format:"uri",description:"The server endpoint for S3-compatible servers.",examples:["https://minio.example.com"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SftpServer:{type:"object",title:"SftpServer",properties:{location:{type:"string",format:"uri",pattern:"^sftp://.*",description:"SFTP URL, starting with `sftp://`",examples:["sftp://123.123.12.123/{model}/*.json"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SnowflakeServer:{type:"object",title:"SnowflakeServer",properties:{host:{type:"string",description:"The host to the Snowflake server"},port:{type:"integer",description:"The port to the Snowflake server."},account:{type:"string",description:"The Snowflake account used by the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},warehouse:{type:"string",description:"The name of the cluster of resources that is a Snowflake virtual warehouse."}},required:["account","database","schema"]},SqlserverServer:{type:"object",title:"SqlserverServer",properties:{host:{type:"string",description:"The host to the database server",examples:["localhost"]},port:{type:"integer",description:"The port to the database server.",default:1433,examples:[1433]},database:{type:"string",description:"The name of the database.",examples:["database"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["dbo"]}},required:["host","database","schema"]},SynapseServer:{type:"object",title:"SynapseServer",properties:{host:{type:"string",description:"The host of the Synapse server."},port:{type:"integer",description:"The port of the Synapse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},TrinoServer:{type:"object",title:"TrinoServer",properties:{host:{type:"string",description:"The Trino host URL.",examples:["localhost"]},port:{type:"integer",description:"The Trino port."},catalog:{type:"string",description:"The name of the catalog.",examples:["hive"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["my_schema"]}},required:["host","port","catalog","schema"]},VerticaServer:{type:"object",title:"VerticaServer",properties:{host:{type:"string",description:"The host of the Vertica server."},port:{type:"integer",description:"The port of the Vertica server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]}},SchemaElement:{type:"object",properties:{name:{type:"string",description:"Name of the element."},physicalType:{type:"string",description:"The physical element data type in the data source.",examples:["table","view","topic","file"]},description:{type:"string",description:"Description of the element."},businessName:{type:"string",description:"The business name of the element."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{$ref:"#/$defs/Tags"},customProperties:{$ref:"#/$defs/CustomProperties"}}},SchemaObject:{type:"object",properties:{logicalType:{type:"string",description:"The logical element data type.",enum:["object"]},physicalName:{type:"string",description:"Physical name.",examples:["table_1_2_0"]},dataGranularityDescription:{type:"string",description:"Granular level of the data in the object.",examples:["Aggregation by country"]},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"}],required:["name"],unevaluatedProperties:!1},SchemaBaseProperty:{type:"object",properties:{primaryKey:{type:"boolean",description:"Boolean value specifying whether the element is primary or not. Default is false."},primaryKeyPosition:{type:"integer",default:-1,description:"If element is a primary key, the position of the primary key element. Starts from 1. Example of `account_id, name` being primary key columns, `account_id` has primaryKeyPosition 1 and `name` primaryKeyPosition 2. Default to -1."},logicalType:{type:"string",description:"The logical element data type.",enum:["string","date","number","integer","object","array","boolean"]},logicalTypeOptions:{type:"object",description:"Additional optional metadata to describe the logical type."},physicalType:{type:"string",description:"The physical element data type in the data source. For example, VARCHAR(2), DOUBLE, INT."},required:{type:"boolean",default:!1,description:"Indicates if the element may contain Null values; possible values are true and false. Default is false."},unique:{type:"boolean",default:!1,description:"Indicates if the element contains unique values; possible values are true and false. Default is false."},partitioned:{type:"boolean",default:!1,description:"Indicates if the element is partitioned; possible values are true and false."},partitionKeyPosition:{type:"integer",default:-1,description:"If element is used for partitioning, the position of the partition element. Starts from 1. Example of `country, year` being partition columns, `country` has partitionKeyPosition 1 and `year` partitionKeyPosition 2. Default to -1."},classification:{type:"string",description:"Can be anything, like confidential, restricted, and public to more advanced categorization. Some companies like PayPal, use data classification indicating the class of data in the element; expected values are 1, 2, 3, 4, or 5.",examples:["confidential","restricted","public"]},encryptedName:{type:"string",description:"The element name within the dataset that contains the encrypted element value. For example, unencrypted element `email_address` might have an encryptedName of `email_address_encrypt`."},transformSourceObjects:{type:"array",description:"List of objects in the data source used in the transformation.",items:{type:"string"}},transformLogic:{type:"string",description:"Logic used in the element transformation."},transformDescription:{type:"string",description:"Describes the transform logic in very simple terms."},examples:{type:"array",description:"List of sample element values.",items:{$ref:"#/$defs/AnyType"}},criticalDataElement:{type:"boolean",default:!1,description:"True or false indicator; If element is considered a critical data element (CDE) then true else false."},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"},{if:{properties:{logicalType:{const:"string"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{minLength:{type:"integer",minimum:0,description:"Minimum length of the string."},maxLength:{type:"integer",minimum:0,description:"Maximum length of the string."},pattern:{type:"string",description:"Regular expression pattern to define valid value. Follows regular expression syntax from ECMA-262 (https://262.ecma-international.org/5.1/#sec-15.10.1)."},format:{type:"string",examples:["password","byte","binary","email","uuid","uri","hostname","ipv4","ipv6"],description:"Provides extra context about what format the string follows."}},additionalProperties:!1}}}},{if:{properties:{logicalType:{const:"date"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{format:{type:"string",examples:["yyyy-MM-dd","yyyy-MM-dd HH:mm:ss","HH:mm:ss"],description:"Format of the date. Follows the format as prescribed by [JDK DateTimeFormatter](https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html). For example, format 'yyyy-MM-dd'."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},maximum:{type:"string",description:"All date values are less than or equal to this value (values <= maximum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},minimum:{type:"string",description:"All date values are greater than or equal to this value (values >= minimum)."}},additionalProperties:!1}}}},{if:{anyOf:[{properties:{logicalType:{const:"integer"}}}]},then:{properties:{logicalTypeOptions:{type:"object",properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use and whether it is signed or unsigned (follows the Rust integer types).",enum:["i8","i16","i32","i64","i128","u8","u16","u32","u64","u128"]}},additionalProperties:!1}}}},{if:{anyOf:[{properties:{logicalType:{const:"number"}}}]},then:{properties:{logicalTypeOptions:{type:"object",properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use (follows the Rust float types).",enum:["f32","f64"]}},additionalProperties:!1}}}},{if:{properties:{logicalType:{const:"object"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{maxProperties:{type:"integer",minimum:0,description:"Maximum number of properties."},minProperties:{type:"integer",minimum:0,default:0,description:"Minimum number of properties."},required:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0,description:"Property names that are required to exist in the object."}},additionalProperties:!1},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}}}},{if:{properties:{logicalType:{const:"array"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{maxItems:{type:"integer",minimum:0,description:"Maximum number of items."},minItems:{type:"integer",minimum:0,default:0,description:"Minimum number of items"},uniqueItems:{type:"boolean",default:!1,description:"If set to true, all items in the array are unique."}},additionalProperties:!1},items:{$ref:"#/$defs/SchemaItemProperty",description:"List of items in an array (only applicable when `logicalType: array`)."}}}}]},SchemaProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",required:["name"],unevaluatedProperties:!1},SchemaItemProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",properties:{properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}},unevaluatedProperties:!1},Tags:{type:"array",description:"A list of tags that may be assigned to the elements (object or property); the tags keyword may appear at any level. Tags may be used to better categorize an element. For example, `finance`, `sensitive`, `employee_record`.",examples:["finance","sensitive","employee_record"],items:{type:"string"}},DataQuality:{type:"object",properties:{authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},businessImpact:{type:"string",description:"Consequences of the rule failure.",examples:["operational","regulatory"]},customProperties:{type:"array",description:"Additional properties required for rule execution.",items:{$ref:"#/$defs/CustomProperty"}},description:{type:"string",description:"Describe the quality check to be completed."},dimension:{type:"string",description:"The key performance indicator (KPI) or dimension for data quality.",enum:["accuracy","completeness","conformity","consistency","coverage","timeliness","uniqueness"]},method:{type:"string",examples:["reconciliation"]},name:{type:"string",description:"Name of the data quality check."},schedule:{type:"string",description:"Rule execution schedule details.",examples:["0 20 * * *"]},scheduler:{type:"string",description:"The name or type of scheduler used to start the data quality check.",examples:["cron"]},severity:{type:"string",description:"The severance of the quality rule.",examples:["info","warning","error"]},tags:{$ref:"#/$defs/Tags"},type:{type:"string",description:"The type of quality check. 'text' is human-readable text that describes the quality of the data. 'library' is a set of maintained predefined quality attributes such as row count or unique. 'sql' is an individual SQL query that returns a value that can be compared. 'custom' is quality attributes that are vendor-specific, such as Soda or Great Expectations.",enum:["text","library","sql","custom"],default:"library"},unit:{type:"string",description:"Unit the rule is using, popular values are `rows` or `percent`, but any value is allowed.",examples:["rows","percent"]}},allOf:[{if:{properties:{type:{const:"library"}}},then:{$ref:"#/$defs/DataQualityLibrary"}},{if:{properties:{type:{const:"sql"}},required:["type"]},then:{$ref:"#/$defs/DataQualitySql"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/DataQualityCustom"}}]},DataQualityChecks:{type:"array",description:"Data quality rules with all the relevant information for rule setup and execution.",items:{$ref:"#/$defs/DataQuality"}},DataQualityLibrary:{type:"object",properties:{rule:{type:"string",description:"Define a data quality check based on the predefined rules as per ODCS.",examples:["duplicateCount","validValues","rowCount"]},mustBe:{description:"Must be equal to the value to be valid. When using numbers, it is equivalent to '='."},mustNotBe:{description:"Must not be equal to the value to be valid. When using numbers, it is equivalent to '!='."},mustBeGreaterThan:{type:"number",description:"Must be greater than the value to be valid. It is equivalent to '>'."},mustBeGreaterOrEqualTo:{type:"number",description:"Must be greater than or equal to the value to be valid. It is equivalent to '>='."},mustBeLessThan:{type:"number",description:"Must be less than the value to be valid. It is equivalent to '<'."},mustBeLessOrEqualTo:{type:"number",description:"Must be less than or equal to the value to be valid. It is equivalent to '<='."},mustBeBetween:{type:"array",description:"Must be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}},mustNotBeBetween:{type:"array",description:"Must not be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}}},required:["rule"]},DataQualitySql:{type:"object",properties:{query:{type:"string",description:"Query string that adheres to the dialect of the provided server.",examples:["SELECT COUNT(*) FROM ${table} WHERE ${column} IS NOT NULL"]}},required:["query"]},DataQualityCustom:{type:"object",properties:{engine:{type:"string",description:"Name of the engine which executes the data quality checks.",examples:["soda","great-expectations","monte-carlo","dbt"]},implementation:{oneOf:[{type:"string"},{type:"object"}]}},required:["engine","implementation"]},AuthoritativeDefinitions:{type:"array",description:"List of links to sources that provide more details on the dataset; examples would be a link to an external definition, a training video, a git repo, data catalog, or another tool. Authoritative definitions follow the same structure in the standard.",items:{type:"object",properties:{url:{type:"string",description:"URL to the authority."},type:{type:"string",description:"Type of definition for authority: v2.3 adds standard values: `businessDefinition`, `transformationImplementation`, `videoTutorial`, `tutorial`, and `implementation`.",examples:["businessDefinition","transformationImplementation","videoTutorial","tutorial","implementation"]}},required:["url","type"]}},Support:{type:"array",description:"Top level for support channels.",items:{$ref:"#/$defs/SupportItem"}},SupportItem:{type:"object",properties:{channel:{type:"string",description:"Channel name or identifier."},url:{type:"string",description:"Access URL using normal [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax) (https, mailto, etc.)."},description:{type:"string",description:"Description of the channel, free text."},tool:{type:"string",description:"Name of the tool, value can be `email`, `slack`, `teams`, `discord`, `ticket`, or `other`.",examples:["email","slack","teams","discord","ticket","other"]},scope:{type:"string",description:"Scope can be: `interactive`, `announcements`, `issues`.",examples:["interactive","announcements","issues"]},invitationUrl:{type:"string",description:"Some tools uses invitation URL for requesting or subscribing. Follows the [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax)."}},required:["channel","url"]},Pricing:{type:"object",properties:{priceAmount:{type:"number",description:"Subscription price per unit of measure in `priceUnit`."},priceCurrency:{type:"string",description:"Currency of the subscription price in `price.priceAmount`."},priceUnit:{type:"string",description:"The unit of measure for calculating cost. Examples megabyte, gigabyte."}}},Team:{type:"object",properties:{username:{type:"string",description:"The user's username or email."},role:{type:"string",description:"The user's job role; Examples might be owner, data steward. There is no limit on the role."},dateIn:{type:"string",format:"date",description:"The date when the user joined the team."},dateOut:{type:"string",format:"date",description:"The date when the user ceased to be part of the team."},replacedByUsername:{type:"string",description:"The username of the user who replaced the previous user."}}},Role:{type:"object",properties:{role:{type:"string",description:"Name of the IAM role that provides access to the dataset."},description:{type:"string",description:"Description of the IAM role and its permissions."},access:{type:"string",description:"The type of access provided by the IAM role."},firstLevelApprovers:{type:"string",description:"The name(s) of the first-level approver(s) of the role."},secondLevelApprovers:{type:"string",description:"The name(s) of the second-level approver(s) of the role."},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["role"]},ServiceLevelAgreementProperty:{type:"object",properties:{property:{type:"string",description:"Specific property in SLA, check the periodic table. May requires units (more details to come)."},value:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}],description:"Agreement value. The label will change based on the property itself."},valueExt:{$ref:"#/$defs/AnyNonCollectionType",description:"Extended agreement value. The label will change based on the property itself."},unit:{type:"string",description:"**d**, day, days for days; **y**, yr, years for years, etc. Units use the ISO standard."},element:{type:"string",description:"Element(s) to check on. Multiple elements should be extremely rare and, if so, separated by commas."},driver:{type:"string",description:"Describes the importance of the SLA from the list of: `regulatory`, `analytics`, or `operational`.",examples:["regulatory","analytics","operational"]}},required:["property","value"]},CustomProperties:{type:"array",description:"A list of key/value pairs for custom properties.",items:{$ref:"#/$defs/CustomProperty"}},CustomProperty:{type:"object",properties:{property:{type:"string",description:"The name of the key. Names should be in camel case–the same as if they were permanent properties in the contract."},value:{$ref:"#/$defs/AnyType",description:"The value of the key."}}},AnyType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"},{type:"array"},{type:"object"}]},AnyNonCollectionType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}]}}};var tse={$schema:"https://json-schema.org/draft/2019-09/schema",title:"Open Data Contract Standard (ODCS)",description:"An open data contract specification to establish agreement between data producers and consumers.",type:"object",properties:{version:{type:"string",description:"Current version of the data contract."},kind:{type:"string",default:"DataContract",description:"The kind of file this is. Valid value is `DataContract`.",enum:["DataContract"]},apiVersion:{type:"string",default:"v3.0.2",description:"Version of the standard used to build data contract. Default value is v3.0.2.",enum:["v3.0.2","v3.0.1","v3.0.0","v2.2.2","v2.2.1","v2.2.0"]},id:{type:"string",description:"A unique identifier used to reduce the risk of dataset name collisions, such as a UUID."},name:{type:"string",description:"Name of the data contract."},tenant:{type:"string",description:"Indicates the property the data is primarily associated with. Value is case insensitive."},tags:{$ref:"#/$defs/Tags"},status:{type:"string",description:"Current status of the dataset.",examples:["proposed","draft","active","deprecated","retired"]},servers:{type:"array",description:"List of servers where the datasets reside.",items:{$ref:"#/$defs/Server"}},dataProduct:{type:"string",description:"The name of the data product."},description:{type:"object",description:"High level description of the dataset.",properties:{usage:{type:"string",description:"Intended usage of the dataset."},purpose:{type:"string",description:"Purpose of the dataset."},limitations:{type:"string",description:"Limitations of the dataset."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"}}},domain:{type:"string",description:"Name of the logical data domain.",examples:["imdb_ds_aggregate","receiver_profile_out","transaction_profile_out"]},schema:{type:"array",description:"A list of elements within the schema to be cataloged.",items:{$ref:"#/$defs/SchemaObject"}},support:{$ref:"#/$defs/Support"},price:{$ref:"#/$defs/Pricing"},team:{type:"array",items:{$ref:"#/$defs/Team"}},roles:{type:"array",description:"A list of roles that will provide user access to the dataset.",items:{$ref:"#/$defs/Role"}},slaDefaultElement:{type:"string",description:"Element (using the element path notation) to do the checks on."},slaProperties:{type:"array",description:"A list of key/value pairs for SLA specific properties. There is no limit on the type of properties (more details to come).",items:{$ref:"#/$defs/ServiceLevelAgreementProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"},contractCreatedTs:{type:"string",format:"date-time",description:"Timestamp in UTC of when the data contract was created."}},required:["version","apiVersion","kind","id","status"],additionalProperties:!1,$defs:{Server:{type:"object",description:"Data source details of where data is physically stored.",properties:{server:{type:"string",description:"Identifier of the server."},type:{type:"string",description:"Type of the server.",enum:["api","athena","azure","bigquery","clickhouse","databricks","denodo","dremio","duckdb","glue","cloudsql","db2","informix","kafka","kinesis","local","mysql","oracle","postgresql","postgres","presto","pubsub","redshift","s3","sftp","snowflake","sqlserver","synapse","trino","vertica","custom"]},description:{type:"string",description:"Description of the server."},environment:{type:"string",description:"Environment of the server.",examples:["prod","preprod","dev","uat"]},roles:{type:"array",description:"List of roles that have access to the server.",items:{$ref:"#/$defs/Role"}},customProperties:{$ref:"#/$defs/CustomProperties"}},allOf:[{if:{properties:{type:{const:"api"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ApiServer"}},{if:{properties:{type:{const:"athena"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AthenaServer"}},{if:{properties:{type:{const:"azure"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AzureServer"}},{if:{properties:{type:{const:"bigquery"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/BigQueryServer"}},{if:{properties:{type:{const:"clickhouse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ClickHouseServer"}},{if:{properties:{type:{const:"databricks"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DatabricksServer"}},{if:{properties:{type:{const:"denodo"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DenodoServer"}},{if:{properties:{type:{const:"dremio"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DremioServer"}},{if:{properties:{type:{const:"duckdb"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DuckdbServer"}},{if:{properties:{type:{const:"glue"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GlueServer"}},{if:{properties:{type:{const:"cloudsql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GoogleCloudSqlServer"}},{if:{properties:{type:{const:"db2"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/IBMDB2Server"}},{if:{properties:{type:{const:"informix"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/InformixServer"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/CustomServer"}},{if:{properties:{type:{const:"kafka"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KafkaServer"}},{if:{properties:{type:{const:"kinesis"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KinesisServer"}},{if:{properties:{type:{const:"local"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/LocalServer"}},{if:{properties:{type:{const:"mysql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/MySqlServer"}},{if:{properties:{type:{const:"oracle"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/OracleServer"}},{if:{properties:{type:{const:"postgresql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"postgres"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"presto"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PrestoServer"}},{if:{properties:{type:{const:"pubsub"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PubSubServer"}},{if:{properties:{type:{const:"redshift"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/RedshiftServer"}},{if:{properties:{type:{const:"s3"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/S3Server"}},{if:{properties:{type:{const:"sftp"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SftpServer"}},{if:{properties:{type:{const:"snowflake"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SnowflakeServer"}},{if:{properties:{type:{const:"sqlserver"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SqlserverServer"}},{if:{properties:{type:{const:"synapse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SynapseServer"}},{if:{properties:{type:{const:"trino"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/TrinoServer"}},{if:{properties:{type:{const:"vertica"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/VerticaServer"}}],required:["server","type"]},ServerSource:{ApiServer:{type:"object",title:"AthenaServer",properties:{location:{type:"string",format:"uri",description:"The url to the API.",examples:["https://api.example.com/v1"]}},required:["location"]},AthenaServer:{type:"object",title:"AthenaServer",properties:{stagingDir:{type:"string",format:"uri",description:"Amazon Athena automatically stores query results and metadata information for each query that runs in a query result location that you can specify in Amazon S3.",examples:["s3://my_storage_account_name/my_container/path"]},schema:{type:"string",description:"Identify the schema in the data source in which your tables exist."},catalog:{type:"string",description:"Identify the name of the Data Source, also referred to as a Catalog.",default:"awsdatacatalog"},regionName:{type:"string",description:"The region your AWS account uses.",examples:["eu-west-1"]}},required:["stagingDir","schema"]},AzureServer:{type:"object",title:"AzureServer",properties:{location:{type:"string",format:"uri",description:"Fully qualified path to Azure Blob Storage or Azure Data Lake Storage (ADLS), supports globs.",examples:["az://my_storage_account_name.blob.core.windows.net/my_container/path/*.parquet","abfss://my_storage_account_name.dfs.core.windows.net/my_container_name/path/*.parquet"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location","format"]},BigQueryServer:{type:"object",title:"BigQueryServer",properties:{project:{type:"string",description:"The GCP project name."},dataset:{type:"string",description:"The GCP dataset name."}},required:["project","dataset"]},ClickHouseServer:{type:"object",title:"ClickHouseServer",properties:{host:{type:"string",description:"The host of the ClickHouse server."},port:{type:"integer",description:"The port to the ClickHouse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},DatabricksServer:{type:"object",title:"DatabricksServer",properties:{host:{type:"string",description:"The Databricks host",examples:["dbc-abcdefgh-1234.cloud.databricks.com"]},catalog:{type:"string",description:"The name of the Hive or Unity catalog"},schema:{type:"string",description:"The schema name in the catalog"}},required:["catalog","schema"]},DenodoServer:{type:"object",title:"DenodoServer",properties:{host:{type:"string",description:"The host of the Denodo server."},port:{type:"integer",description:"The port of the Denodo server."},database:{type:"string",description:"The name of the database."}},required:["host","port"]},DremioServer:{type:"object",title:"DremioServer",properties:{host:{type:"string",description:"The host of the Dremio server."},port:{type:"integer",description:"The port of the Dremio server."},schema:{type:"string",description:"The name of the schema."}},required:["host","port"]},DuckdbServer:{type:"object",title:"DuckdbServer",properties:{database:{type:"string",description:"Path to duckdb database file."},schema:{type:"integer",description:"The name of the schema."}},required:["database"]},GlueServer:{type:"object",title:"GlueServer",properties:{account:{type:"string",description:"The AWS Glue account",examples:["1234-5678-9012"]},database:{type:"string",description:"The AWS Glue database name",examples:["my_database"]},location:{type:"string",format:"uri",description:"The AWS S3 path. Must be in the form of a URL.",examples:["s3://datacontract-example-orders-latest/data/{model}"]},format:{type:"string",description:"The format of the files",examples:["parquet","csv","json","delta"]}},required:["account","database"]},GoogleCloudSqlServer:{type:"object",title:"GoogleCloudSqlServer",properties:{host:{type:"string",description:"The host of the Google Cloud Sql server."},port:{type:"integer",description:"The port of the Google Cloud Sql server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]},IBMDB2Server:{type:"object",title:"IBMDB2Server",properties:{host:{type:"string",description:"The host of the IBM DB2 server."},port:{type:"integer",description:"The port of the IBM DB2 server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database"]},InformixServer:{type:"object",title:"InformixServer",properties:{host:{type:"string",description:"The host to the Informix server. "},port:{type:"integer",description:"The port to the Informix server. Defaults to 9088."},database:{type:"string",description:"The name of the database."}},required:["host","database"]},CustomServer:{type:"object",title:"CustomServer",properties:{account:{type:"string",description:"Account used by the server."},catalog:{type:"string",description:"Name of the catalog."},database:{type:"string",description:"Name of the database."},dataset:{type:"string",description:"Name of the dataset."},delimiter:{type:"string",description:"Delimiter."},endpointUrl:{type:"string",description:"Server endpoint.",format:"uri"},format:{type:"string",description:"File format."},host:{type:"string",description:"Host name or IP address."},location:{type:"string",description:"A URL to a location.",format:"uri"},path:{type:"string",description:"Relative or absolute path to the data file(s)."},port:{type:"integer",description:"Port to the server. No default value is assumed for custom servers."},project:{type:"string",description:"Project name."},region:{type:"string",description:"Cloud region."},regionName:{type:"string",description:"Region name."},schema:{type:"string",description:"Name of the schema."},serviceName:{type:"string",description:"Name of the service."},stagingDir:{type:"string",description:"Staging directory."},warehouse:{type:"string",description:"Name of the cluster or warehouse."}}},KafkaServer:{type:"object",title:"KafkaServer",description:"Kafka Server",properties:{host:{type:"string",description:"The bootstrap server of the kafka cluster."},format:{type:"string",description:"The format of the messages.",examples:["json","avro","protobuf","xml"],default:"json"}},required:["host"]},KinesisServer:{type:"object",title:"KinesisDataStreamsServer",description:"Kinesis Data Streams Server",properties:{region:{type:"string",description:"AWS region.",examples:["eu-west-1"]},format:{type:"string",description:"The format of the record",examples:["json","avro","protobuf"]}}},LocalServer:{type:"object",title:"LocalServer",properties:{path:{type:"string",description:"The relative or absolute path to the data file(s).",examples:["./folder/data.parquet","./folder/*.parquet"]},format:{type:"string",description:"The format of the file(s)",examples:["json","parquet","delta","csv"]}},required:["path","format"]},MySqlServer:{type:"object",title:"MySqlServer",properties:{host:{type:"string",description:"The host of the MySql server."},port:{type:"integer",description:"The port of the MySql server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},OracleServer:{type:"object",title:"OracleServer",properties:{host:{type:"string",description:"The host to the oracle server",examples:["localhost"]},port:{type:"integer",description:"The port to the oracle server.",examples:[1523]},serviceName:{type:"string",description:"The name of the service.",examples:["service"]}},required:["host","port","serviceName"]},PostgresServer:{type:"object",title:"PostgresServer",properties:{host:{type:"string",description:"The host to the Postgres server"},port:{type:"integer",description:"The port to the Postgres server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema in the database."}},required:["host","port","database","schema"]},PrestoServer:{type:"object",title:"PrestoServer",properties:{host:{type:"string",description:"The host to the Presto server",examples:["localhost:8080"]},catalog:{type:"string",description:"The name of the catalog.",examples:["postgres"]},schema:{type:"string",description:"The name of the schema.",examples:["public"]}},required:["host"]},PubSubServer:{type:"object",title:"PubSubServer",properties:{project:{type:"string",description:"The GCP project name."}},required:["project"]},RedshiftServer:{type:"object",title:"RedshiftServer",properties:{host:{type:"string",description:"An optional string describing the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},region:{type:"string",description:"AWS region of Redshift server.",examples:["us-east-1"]},account:{type:"string",description:"The account used by the server."}},required:["database","schema"]},S3Server:{type:"object",title:"S3Server",properties:{location:{type:"string",format:"uri",description:"S3 URL, starting with `s3://`",examples:["s3://datacontract-example-orders-latest/data/{model}/*.json"]},endpointUrl:{type:"string",format:"uri",description:"The server endpoint for S3-compatible servers.",examples:["https://minio.example.com"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SftpServer:{type:"object",title:"SftpServer",properties:{location:{type:"string",format:"uri",pattern:"^sftp://.*",description:"SFTP URL, starting with `sftp://`",examples:["sftp://123.123.12.123/{model}/*.json"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SnowflakeServer:{type:"object",title:"SnowflakeServer",properties:{host:{type:"string",description:"The host to the Snowflake server"},port:{type:"integer",description:"The port to the Snowflake server."},account:{type:"string",description:"The Snowflake account used by the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},warehouse:{type:"string",description:"The name of the cluster of resources that is a Snowflake virtual warehouse."}},required:["account","database","schema"]},SqlserverServer:{type:"object",title:"SqlserverServer",properties:{host:{type:"string",description:"The host to the database server",examples:["localhost"]},port:{type:"integer",description:"The port to the database server.",default:1433,examples:[1433]},database:{type:"string",description:"The name of the database.",examples:["database"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["dbo"]}},required:["host","database","schema"]},SynapseServer:{type:"object",title:"SynapseServer",properties:{host:{type:"string",description:"The host of the Synapse server."},port:{type:"integer",description:"The port of the Synapse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},TrinoServer:{type:"object",title:"TrinoServer",properties:{host:{type:"string",description:"The Trino host URL.",examples:["localhost"]},port:{type:"integer",description:"The Trino port."},catalog:{type:"string",description:"The name of the catalog.",examples:["hive"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["my_schema"]}},required:["host","port","catalog","schema"]},VerticaServer:{type:"object",title:"VerticaServer",properties:{host:{type:"string",description:"The host of the Vertica server."},port:{type:"integer",description:"The port of the Vertica server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]}},SchemaElement:{type:"object",properties:{name:{type:"string",description:"Name of the element."},physicalType:{type:"string",description:"The physical element data type in the data source.",examples:["table","view","topic","file"]},description:{type:"string",description:"Description of the element."},businessName:{type:"string",description:"The business name of the element."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{$ref:"#/$defs/Tags"},customProperties:{$ref:"#/$defs/CustomProperties"}}},SchemaObject:{type:"object",properties:{logicalType:{type:"string",description:"The logical element data type.",enum:["object"]},physicalName:{type:"string",description:"Physical name.",examples:["table_1_2_0"]},dataGranularityDescription:{type:"string",description:"Granular level of the data in the object.",examples:["Aggregation by country"]},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"}],required:["name"],unevaluatedProperties:!1},SchemaBaseProperty:{type:"object",properties:{primaryKey:{type:"boolean",description:"Boolean value specifying whether the element is primary or not. Default is false."},primaryKeyPosition:{type:"integer",default:-1,description:"If element is a primary key, the position of the primary key element. Starts from 1. Example of `account_id, name` being primary key columns, `account_id` has primaryKeyPosition 1 and `name` primaryKeyPosition 2. Default to -1."},logicalType:{type:"string",description:"The logical element data type.",enum:["string","date","number","integer","object","array","boolean"]},logicalTypeOptions:{type:"object",description:"Additional optional metadata to describe the logical type."},physicalType:{type:"string",description:"The physical element data type in the data source. For example, VARCHAR(2), DOUBLE, INT."},physicalName:{type:"string",description:"Physical name.",examples:["col_str_a"]},required:{type:"boolean",default:!1,description:"Indicates if the element may contain Null values; possible values are true and false. Default is false."},unique:{type:"boolean",default:!1,description:"Indicates if the element contains unique values; possible values are true and false. Default is false."},partitioned:{type:"boolean",default:!1,description:"Indicates if the element is partitioned; possible values are true and false."},partitionKeyPosition:{type:"integer",default:-1,description:"If element is used for partitioning, the position of the partition element. Starts from 1. Example of `country, year` being partition columns, `country` has partitionKeyPosition 1 and `year` partitionKeyPosition 2. Default to -1."},classification:{type:"string",description:"Can be anything, like confidential, restricted, and public to more advanced categorization. Some companies like PayPal, use data classification indicating the class of data in the element; expected values are 1, 2, 3, 4, or 5.",examples:["confidential","restricted","public"]},encryptedName:{type:"string",description:"The element name within the dataset that contains the encrypted element value. For example, unencrypted element `email_address` might have an encryptedName of `email_address_encrypt`."},transformSourceObjects:{type:"array",description:"List of objects in the data source used in the transformation.",items:{type:"string"}},transformLogic:{type:"string",description:"Logic used in the element transformation."},transformDescription:{type:"string",description:"Describes the transform logic in very simple terms."},examples:{type:"array",description:"List of sample element values.",items:{$ref:"#/$defs/AnyType"}},criticalDataElement:{type:"boolean",default:!1,description:"True or false indicator; If element is considered a critical data element (CDE) then true else false."},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"},{if:{properties:{logicalType:{const:"string"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{minLength:{type:"integer",minimum:0,description:"Minimum length of the string."},maxLength:{type:"integer",minimum:0,description:"Maximum length of the string."},pattern:{type:"string",description:"Regular expression pattern to define valid value. Follows regular expression syntax from ECMA-262 (https://262.ecma-international.org/5.1/#sec-15.10.1)."},format:{type:"string",examples:["password","byte","binary","email","uuid","uri","hostname","ipv4","ipv6"],description:"Provides extra context about what format the string follows."}},additionalProperties:!1}}}},{if:{properties:{logicalType:{const:"date"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{format:{type:"string",examples:["yyyy-MM-dd","yyyy-MM-dd HH:mm:ss","HH:mm:ss"],description:"Format of the date. Follows the format as prescribed by [JDK DateTimeFormatter](https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html). For example, format 'yyyy-MM-dd'."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},maximum:{type:"string",description:"All date values are less than or equal to this value (values <= maximum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},minimum:{type:"string",description:"All date values are greater than or equal to this value (values >= minimum)."}},additionalProperties:!1}}}},{if:{anyOf:[{properties:{logicalType:{const:"integer"}}}]},then:{properties:{logicalTypeOptions:{type:"object",properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use and whether it is signed or unsigned (follows the Rust integer types).",enum:["i8","i16","i32","i64","i128","u8","u16","u32","u64","u128"]}},additionalProperties:!1}}}},{if:{anyOf:[{properties:{logicalType:{const:"number"}}}]},then:{properties:{logicalTypeOptions:{type:"object",properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use (follows the Rust float types).",enum:["f32","f64"]}},additionalProperties:!1}}}},{if:{properties:{logicalType:{const:"object"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{maxProperties:{type:"integer",minimum:0,description:"Maximum number of properties."},minProperties:{type:"integer",minimum:0,default:0,description:"Minimum number of properties."},required:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0,description:"Property names that are required to exist in the object."}},additionalProperties:!1},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}}}},{if:{properties:{logicalType:{const:"array"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{maxItems:{type:"integer",minimum:0,description:"Maximum number of items."},minItems:{type:"integer",minimum:0,default:0,description:"Minimum number of items"},uniqueItems:{type:"boolean",default:!1,description:"If set to true, all items in the array are unique."}},additionalProperties:!1},items:{$ref:"#/$defs/SchemaItemProperty",description:"List of items in an array (only applicable when `logicalType: array`)."}}}}]},SchemaProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",required:["name"],unevaluatedProperties:!1},SchemaItemProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",properties:{properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}},unevaluatedProperties:!1},Tags:{type:"array",description:"A list of tags that may be assigned to the elements (object or property); the tags keyword may appear at any level. Tags may be used to better categorize an element. For example, `finance`, `sensitive`, `employee_record`.",examples:["finance","sensitive","employee_record"],items:{type:"string"}},DataQuality:{type:"object",properties:{authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},businessImpact:{type:"string",description:"Consequences of the rule failure.",examples:["operational","regulatory"]},customProperties:{type:"array",description:"Additional properties required for rule execution.",items:{$ref:"#/$defs/CustomProperty"}},description:{type:"string",description:"Describe the quality check to be completed."},dimension:{type:"string",description:"The key performance indicator (KPI) or dimension for data quality.",enum:["accuracy","completeness","conformity","consistency","coverage","timeliness","uniqueness"]},method:{type:"string",examples:["reconciliation"]},name:{type:"string",description:"Name of the data quality check."},schedule:{type:"string",description:"Rule execution schedule details.",examples:["0 20 * * *"]},scheduler:{type:"string",description:"The name or type of scheduler used to start the data quality check.",examples:["cron"]},severity:{type:"string",description:"The severance of the quality rule.",examples:["info","warning","error"]},tags:{$ref:"#/$defs/Tags"},type:{type:"string",description:"The type of quality check. 'text' is human-readable text that describes the quality of the data. 'library' is a set of maintained predefined quality attributes such as row count or unique. 'sql' is an individual SQL query that returns a value that can be compared. 'custom' is quality attributes that are vendor-specific, such as Soda or Great Expectations.",enum:["text","library","sql","custom"],default:"library"},unit:{type:"string",description:"Unit the rule is using, popular values are `rows` or `percent`, but any value is allowed.",examples:["rows","percent"]}},allOf:[{if:{properties:{type:{const:"library"}}},then:{$ref:"#/$defs/DataQualityLibrary"}},{if:{properties:{type:{const:"sql"}},required:["type"]},then:{$ref:"#/$defs/DataQualitySql"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/DataQualityCustom"}}]},DataQualityChecks:{type:"array",description:"Data quality rules with all the relevant information for rule setup and execution.",items:{$ref:"#/$defs/DataQuality"}},DataQualityLibrary:{type:"object",properties:{rule:{type:"string",description:"Define a data quality check based on the predefined rules as per ODCS.",examples:["duplicateCount","validValues","rowCount"]},mustBe:{description:"Must be equal to the value to be valid. When using numbers, it is equivalent to '='."},mustNotBe:{description:"Must not be equal to the value to be valid. When using numbers, it is equivalent to '!='."},mustBeGreaterThan:{type:"number",description:"Must be greater than the value to be valid. It is equivalent to '>'."},mustBeGreaterOrEqualTo:{type:"number",description:"Must be greater than or equal to the value to be valid. It is equivalent to '>='."},mustBeLessThan:{type:"number",description:"Must be less than the value to be valid. It is equivalent to '<'."},mustBeLessOrEqualTo:{type:"number",description:"Must be less than or equal to the value to be valid. It is equivalent to '<='."},mustBeBetween:{type:"array",description:"Must be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}},mustNotBeBetween:{type:"array",description:"Must not be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}}},required:["rule"]},DataQualitySql:{type:"object",properties:{query:{type:"string",description:"Query string that adheres to the dialect of the provided server.",examples:["SELECT COUNT(*) FROM ${table} WHERE ${column} IS NOT NULL"]}},required:["query"]},DataQualityCustom:{type:"object",properties:{engine:{type:"string",description:"Name of the engine which executes the data quality checks.",examples:["soda","great-expectations","monte-carlo","dbt"]},implementation:{oneOf:[{type:"string"},{type:"object"}]}},required:["engine","implementation"]},AuthoritativeDefinitions:{type:"array",description:"List of links to sources that provide more details on the dataset; examples would be a link to an external definition, a training video, a git repo, data catalog, or another tool. Authoritative definitions follow the same structure in the standard.",items:{type:"object",properties:{url:{type:"string",description:"URL to the authority."},type:{type:"string",description:"Type of definition for authority: v2.3 adds standard values: `businessDefinition`, `transformationImplementation`, `videoTutorial`, `tutorial`, and `implementation`.",examples:["businessDefinition","transformationImplementation","videoTutorial","tutorial","implementation"]}},required:["url","type"]}},Support:{type:"array",description:"Top level for support channels.",items:{$ref:"#/$defs/SupportItem"}},SupportItem:{type:"object",properties:{channel:{type:"string",description:"Channel name or identifier."},url:{type:"string",description:"Access URL using normal [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax) (https, mailto, etc.)."},description:{type:"string",description:"Description of the channel, free text."},tool:{type:"string",description:"Name of the tool, value can be `email`, `slack`, `teams`, `discord`, `ticket`, or `other`.",examples:["email","slack","teams","discord","ticket","other"]},scope:{type:"string",description:"Scope can be: `interactive`, `announcements`, `issues`.",examples:["interactive","announcements","issues"]},invitationUrl:{type:"string",description:"Some tools uses invitation URL for requesting or subscribing. Follows the [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax)."}},required:["channel","url"]},Pricing:{type:"object",properties:{priceAmount:{type:"number",description:"Subscription price per unit of measure in `priceUnit`."},priceCurrency:{type:"string",description:"Currency of the subscription price in `price.priceAmount`."},priceUnit:{type:"string",description:"The unit of measure for calculating cost. Examples megabyte, gigabyte."}}},Team:{type:"object",properties:{username:{type:"string",description:"The user's username or email.",examples:["mail@example.com","uid12345678"]},name:{type:"string",description:"The user's name.",examples:["Jane Doe"]},description:{type:"string",description:"The user's description."},role:{type:"string",description:"The user's job role; Examples might be owner, data steward. There is no limit on the role."},dateIn:{type:"string",format:"date",description:"The date when the user joined the team."},dateOut:{type:"string",format:"date",description:"The date when the user ceased to be part of the team."},replacedByUsername:{type:"string",description:"The username of the user who replaced the previous user."}}},Role:{type:"object",properties:{role:{type:"string",description:"Name of the IAM role that provides access to the dataset."},description:{type:"string",description:"Description of the IAM role and its permissions."},access:{type:"string",description:"The type of access provided by the IAM role."},firstLevelApprovers:{type:"string",description:"The name(s) of the first-level approver(s) of the role."},secondLevelApprovers:{type:"string",description:"The name(s) of the second-level approver(s) of the role."},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["role"]},ServiceLevelAgreementProperty:{type:"object",properties:{property:{type:"string",description:"Specific property in SLA, check the periodic table. May requires units (more details to come)."},value:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}],description:"Agreement value. The label will change based on the property itself."},valueExt:{$ref:"#/$defs/AnyNonCollectionType",description:"Extended agreement value. The label will change based on the property itself."},unit:{type:"string",description:"**d**, day, days for days; **y**, yr, years for years, etc. Units use the ISO standard."},element:{type:"string",description:"Element(s) to check on. Multiple elements should be extremely rare and, if so, separated by commas."},driver:{type:"string",description:"Describes the importance of the SLA from the list of: `regulatory`, `analytics`, or `operational`.",examples:["regulatory","analytics","operational"]}},required:["property","value"]},CustomProperties:{type:"array",description:"A list of key/value pairs for custom properties.",items:{$ref:"#/$defs/CustomProperty"}},CustomProperty:{type:"object",properties:{property:{type:"string",description:"The name of the key. Names should be in camel case–the same as if they were permanent properties in the contract."},value:{$ref:"#/$defs/AnyType",description:"The value of the key."}}},AnyType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"},{type:"array"},{type:"object"}]},AnyNonCollectionType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}]}}};var nse={$schema:"https://json-schema.org/draft/2019-09/schema",title:"Open Data Contract Standard (ODCS)",description:"An open data contract specification to establish agreement between data producers and consumers.",type:"object",properties:{version:{type:"string",description:"Current version of the data contract."},kind:{type:"string",default:"DataContract",description:"The kind of file this is. Valid value is `DataContract`.",enum:["DataContract"]},apiVersion:{type:"string",default:"v3.1.0",description:"Version of the standard used to build data contract. Default value is v3.1.0.",enum:["v3.1.0","v3.0.2","v3.0.1","v3.0.0","v2.2.2","v2.2.1","v2.2.0"]},id:{type:"string",description:"A unique identifier used to reduce the risk of dataset name collisions, such as a UUID."},name:{type:"string",description:"Name of the data contract."},tenant:{type:"string",description:"Indicates the property the data is primarily associated with. Value is case insensitive."},tags:{$ref:"#/$defs/Tags"},status:{type:"string",description:"Current status of the dataset.",examples:["proposed","draft","active","deprecated","retired"]},servers:{type:"array",description:"List of servers where the datasets reside.",items:{$ref:"#/$defs/Server"}},dataProduct:{type:"string",description:"The name of the data product. DEPRECATED since v3.1.0.",deprecated:!0},description:{type:"object",description:"High level description of the dataset.",properties:{usage:{type:"string",description:"Intended usage of the dataset."},purpose:{type:"string",description:"Purpose of the dataset."},limitations:{type:"string",description:"Limitations of the dataset."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"}}},domain:{type:"string",description:"Name of the logical data domain.",examples:["imdb_ds_aggregate","receiver_profile_out","transaction_profile_out"]},schema:{type:"array",description:"A list of elements within the schema to be cataloged.",items:{$ref:"#/$defs/SchemaObject"}},support:{$ref:"#/$defs/Support"},price:{$ref:"#/$defs/Pricing"},team:{oneOf:[{$ref:"#/$defs/Team",description:"Team information object with members array (v3.1.0+)."},{type:"array",description:"DEPRECATED: Array of team members. Use the Team object structure instead. This array format is maintained for backward compatibility with v3.0.2 and earlier versions and will be removed in ODCS 4.0.",deprecated:!0,items:{$ref:"#/$defs/TeamMember"}}]},roles:{type:"array",description:"A list of roles that will provide user access to the dataset.",items:{$ref:"#/$defs/Role"}},slaDefaultElement:{type:"string",description:"DEPRECATED SINCE 3.1. WILL BE REMOVED IN ODCS 4.0. Element (using the element path notation) to do the checks on.",deprecated:!0},slaProperties:{type:"array",description:"A list of key/value pairs for SLA specific properties. There is no limit on the type of properties (more details to come).",items:{$ref:"#/$defs/ServiceLevelAgreementProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"},contractCreatedTs:{type:"string",format:"date-time",description:"Timestamp in UTC of when the data contract was created."}},required:["version","apiVersion","kind","id","status"],additionalProperties:!1,unevaluatedProperties:!1,$defs:{ShorthandReference:{type:"string",description:"Shorthand notation using name fields (table_name.column_name)",pattern:"^[A-Za-z_][A-Za-z0-9_\\-]*(\\.[A-Za-z_][A-Za-z0-9_\\-]*)+$"},FullyQualifiedReference:{type:"string",description:"Fully qualified notation using id fields (section/id/properties/id), optionally prefixed with external file reference",pattern:"^(?:(?:https?:\\/\\/)?[A-Za-z0-9._\\-\\/]+\\.yaml#)?\\/?[A-Za-z_][A-Za-z0-9_]*\\/[^\\s.#/\\\\@!%&^]+(?:\\/[A-Za-z_][A-Za-z0-9_]*\\/[^\\s.#/\\\\@!%&^]+)*$"},StableId:{type:"string",description:"Stable technical identifier for references. Must be unique within its containing array. Per RFC-0026a an id cannot contain '.', '#', '/', '\\', '@', '!', '%', '&' or '^', nor whitespace.",pattern:"^[^\\s.#/\\\\@!%&^]+$"},Server:{type:"object",description:"Data source details of where data is physically stored.",properties:{id:{$ref:"#/$defs/StableId"},server:{type:"string",description:"Identifier of the server."},type:{type:"string",description:"Type of the server.",enum:["api","athena","azure","bigquery","clickhouse","databricks","denodo","dremio","duckdb","glue","cloudsql","db2","hive","impala","informix","kafka","kinesis","local","mysql","oracle","postgresql","postgres","presto","pubsub","redshift","s3","sftp","snowflake","sqlserver","synapse","trino","vertica","zen","custom"]},description:{type:"string",description:"Description of the server."},environment:{type:"string",description:"Environment of the server.",examples:["prod","preprod","dev","uat"]},roles:{type:"array",description:"List of roles that have access to the server.",items:{$ref:"#/$defs/Role"}},customProperties:{$ref:"#/$defs/CustomProperties"}},allOf:[{if:{properties:{type:{const:"api"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ApiServer"}},{if:{properties:{type:{const:"athena"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AthenaServer"}},{if:{properties:{type:{const:"azure"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AzureServer"}},{if:{properties:{type:{const:"bigquery"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/BigQueryServer"}},{if:{properties:{type:{const:"clickhouse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ClickHouseServer"}},{if:{properties:{type:{const:"databricks"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DatabricksServer"}},{if:{properties:{type:{const:"denodo"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DenodoServer"}},{if:{properties:{type:{const:"dremio"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DremioServer"}},{if:{properties:{type:{const:"duckdb"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DuckdbServer"}},{if:{properties:{type:{const:"glue"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GlueServer"}},{if:{properties:{type:{const:"cloudsql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GoogleCloudSqlServer"}},{if:{properties:{type:{const:"db2"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/IBMDB2Server"}},{if:{properties:{type:{const:"hive"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/HiveServer"}},{if:{properties:{type:{const:"impala"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ImpalaServer"}},{if:{properties:{type:{const:"informix"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/InformixServer"}},{if:{properties:{type:{const:"zen"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ZenServer"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/CustomServer"}},{if:{properties:{type:{const:"kafka"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KafkaServer"}},{if:{properties:{type:{const:"kinesis"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KinesisServer"}},{if:{properties:{type:{const:"local"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/LocalServer"}},{if:{properties:{type:{const:"mysql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/MySqlServer"}},{if:{properties:{type:{const:"oracle"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/OracleServer"}},{if:{properties:{type:{const:"postgresql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"postgres"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"presto"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PrestoServer"}},{if:{properties:{type:{const:"pubsub"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PubSubServer"}},{if:{properties:{type:{const:"redshift"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/RedshiftServer"}},{if:{properties:{type:{const:"s3"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/S3Server"}},{if:{properties:{type:{const:"sftp"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SftpServer"}},{if:{properties:{type:{const:"snowflake"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SnowflakeServer"}},{if:{properties:{type:{const:"sqlserver"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SqlserverServer"}},{if:{properties:{type:{const:"synapse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SynapseServer"}},{if:{properties:{type:{const:"trino"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/TrinoServer"}},{if:{properties:{type:{const:"vertica"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/VerticaServer"}}],required:["server","type"],unevaluatedProperties:!1},ServerSource:{ApiServer:{type:"object",title:"ApiServer",properties:{location:{type:"string",format:"uri",description:"The url to the API.",examples:["https://api.example.com/v1"]}},required:["location"]},AthenaServer:{type:"object",title:"AthenaServer",properties:{stagingDir:{type:"string",format:"uri",description:"Amazon Athena automatically stores query results and metadata information for each query that runs in a query result location that you can specify in Amazon S3.",examples:["s3://my_storage_account_name/my_container/path"]},schema:{type:"string",description:"Identify the schema in the data source in which your tables exist."},catalog:{type:"string",description:"Identify the name of the Data Source, also referred to as a Catalog.",default:"awsdatacatalog"},regionName:{type:"string",description:"The region your AWS account uses.",examples:["eu-west-1"]}},required:["stagingDir","schema"]},AzureServer:{type:"object",title:"AzureServer",properties:{location:{type:"string",format:"uri",description:"Fully qualified path to Azure Blob Storage or Azure Data Lake Storage (ADLS), supports globs.",examples:["az://my_storage_account_name.blob.core.windows.net/my_container/path/*.parquet","abfss://my_storage_account_name.dfs.core.windows.net/my_container_name/path/*.parquet"]},format:{type:"string",examples:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",examples:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location","format"]},BigQueryServer:{type:"object",title:"BigQueryServer",properties:{project:{type:"string",description:"The GCP project name."},dataset:{type:"string",description:"The GCP dataset name."}},required:["project","dataset"]},ClickHouseServer:{type:"object",title:"ClickHouseServer",properties:{host:{type:"string",description:"The host of the ClickHouse server."},port:{type:"integer",description:"The port to the ClickHouse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},DatabricksServer:{type:"object",title:"DatabricksServer",properties:{host:{type:"string",description:"The Databricks host",examples:["dbc-abcdefgh-1234.cloud.databricks.com"]},catalog:{type:"string",description:"The name of the Hive or Unity catalog"},schema:{type:"string",description:"The schema name in the catalog"}},required:["catalog","schema"]},DenodoServer:{type:"object",title:"DenodoServer",properties:{host:{type:"string",description:"The host of the Denodo server."},port:{type:"integer",description:"The port of the Denodo server."},database:{type:"string",description:"The name of the database."}},required:["host","port"]},DremioServer:{type:"object",title:"DremioServer",properties:{host:{type:"string",description:"The host of the Dremio server."},port:{type:"integer",description:"The port of the Dremio server."},schema:{type:"string",description:"The name of the schema."}},required:["host","port"]},DuckdbServer:{type:"object",title:"DuckdbServer",properties:{database:{type:"string",description:"Path to duckdb database file."},schema:{type:"string",description:"The name of the schema."}},required:["database"]},GlueServer:{type:"object",title:"GlueServer",properties:{account:{type:"string",description:"The AWS Glue account",examples:["1234-5678-9012"]},database:{type:"string",description:"The AWS Glue database name",examples:["my_database"]},location:{type:"string",format:"uri",description:"The AWS S3 path. Must be in the form of a URL.",examples:["s3://datacontract-example-orders-latest/data/{model}"]},format:{type:"string",description:"The format of the files",examples:["parquet","csv","json","delta"]}},required:["account","database"]},GoogleCloudSqlServer:{type:"object",title:"GoogleCloudSqlServer",properties:{host:{type:"string",description:"The host of the Google Cloud Sql server."},port:{type:"integer",description:"The port of the Google Cloud Sql server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]},IBMDB2Server:{type:"object",title:"IBMDB2Server",properties:{host:{type:"string",description:"The host of the IBM DB2 server."},port:{type:"integer",description:"The port of the IBM DB2 server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database"]},HiveServer:{type:"object",title:"HiveServer",properties:{host:{type:"string",description:"The host to the Hive server. "},port:{type:"integer",description:"The port to the Hive server. Defaults to 10000."},database:{type:"string",description:"The name of the Hive database."}},required:["host","database"]},ImpalaServer:{type:"object",title:"ImpalaServer",properties:{host:{type:"string",description:"The host to the Impala server."},port:{type:"integer",description:"The port to the Impala server. Defaults to 21050."},database:{type:"string",description:"The name of the Impala database."}},required:["host","database"]},InformixServer:{type:"object",title:"InformixServer",properties:{host:{type:"string",description:"The host to the Informix server. "},port:{type:"integer",description:"The port to the Informix server. Defaults to 9088."},database:{type:"string",description:"The name of the database."}},required:["host","database"]},ZenServer:{type:"object",title:"ZenServer",properties:{host:{type:"string",description:"Hostname or IP address of the Zen server."},port:{type:"integer",description:"Zen server SQL connections port. Defaults to 1583."},database:{type:"string",description:"Database name to connect to on the Zen server."}},required:["host","database"]},CustomServer:{type:"object",title:"CustomServer",properties:{account:{type:"string",description:"Account used by the server."},catalog:{type:"string",description:"Name of the catalog."},database:{type:"string",description:"Name of the database."},dataset:{type:"string",description:"Name of the dataset."},delimiter:{type:"string",description:"Delimiter."},endpointUrl:{type:"string",description:"Server endpoint.",format:"uri"},format:{type:"string",description:"File format."},host:{type:"string",description:"Host name or IP address."},location:{type:"string",description:"A URL to a location.",format:"uri"},path:{type:"string",description:"Relative or absolute path to the data file(s)."},port:{type:"integer",description:"Port to the server. No default value is assumed for custom servers."},project:{type:"string",description:"Project name."},region:{type:"string",description:"Cloud region."},regionName:{type:"string",description:"Region name."},schema:{type:"string",description:"Name of the schema."},serviceName:{type:"string",description:"Name of the service."},stagingDir:{type:"string",description:"Staging directory."},warehouse:{type:"string",description:"Name of the cluster or warehouse."},stream:{type:"string",description:"Name of the data stream."}}},KafkaServer:{type:"object",title:"KafkaServer",description:"Kafka Server",properties:{host:{type:"string",description:"The bootstrap server of the kafka cluster."},format:{type:"string",description:"The format of the messages.",examples:["json","avro","protobuf","xml"],default:"json"}},required:["host"]},KinesisServer:{type:"object",title:"KinesisDataStreamsServer",description:"Kinesis Data Streams Server",properties:{region:{type:"string",description:"AWS region.",examples:["eu-west-1"]},format:{type:"string",description:"The format of the record",examples:["json","avro","protobuf"]}}},LocalServer:{type:"object",title:"LocalServer",properties:{path:{type:"string",description:"The relative or absolute path to the data file(s).",examples:["./folder/data.parquet","./folder/*.parquet"]},format:{type:"string",description:"The format of the file(s)",examples:["json","parquet","delta","csv"]}},required:["path","format"]},MySqlServer:{type:"object",title:"MySqlServer",properties:{host:{type:"string",description:"The host of the MySql server."},port:{type:"integer",description:"The port of the MySql server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},OracleServer:{type:"object",title:"OracleServer",properties:{host:{type:"string",description:"The host to the oracle server",examples:["localhost"]},port:{type:"integer",description:"The port to the oracle server.",examples:[1523]},serviceName:{type:"string",description:"The name of the service.",examples:["service"]}},required:["host","port","serviceName"]},PostgresServer:{type:"object",title:"PostgresServer",properties:{host:{type:"string",description:"The host to the Postgres server"},port:{type:"integer",description:"The port to the Postgres server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema in the database."}},required:["host","port","database","schema"]},PrestoServer:{type:"object",title:"PrestoServer",properties:{host:{type:"string",description:"The host to the Presto server",examples:["localhost:8080"]},catalog:{type:"string",description:"The name of the catalog.",examples:["postgres"]},schema:{type:"string",description:"The name of the schema.",examples:["public"]}},required:["host"]},PubSubServer:{type:"object",title:"PubSubServer",properties:{project:{type:"string",description:"The GCP project name."}},required:["project"]},RedshiftServer:{type:"object",title:"RedshiftServer",properties:{host:{type:"string",description:"An optional string describing the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},region:{type:"string",description:"AWS region of Redshift server.",examples:["us-east-1"]},account:{type:"string",description:"The account used by the server."}},required:["database","schema"]},S3Server:{type:"object",title:"S3Server",properties:{location:{type:"string",format:"uri",description:"S3 URL, starting with `s3://`",examples:["s3://datacontract-example-orders-latest/data/{model}/*.json"]},endpointUrl:{type:"string",format:"uri",description:"The server endpoint for S3-compatible servers.",examples:["https://minio.example.com"]},format:{type:"string",examples:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",examples:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SftpServer:{type:"object",title:"SftpServer",properties:{location:{type:"string",format:"uri",pattern:"^sftp://.*",description:"SFTP URL, starting with `sftp://`",examples:["sftp://123.123.12.123/{model}/*.json"]},format:{type:"string",examples:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",examples:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SnowflakeServer:{type:"object",title:"SnowflakeServer",properties:{host:{type:"string",description:"The host to the Snowflake server"},port:{type:"integer",description:"The port to the Snowflake server."},account:{type:"string",description:"The Snowflake account used by the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},warehouse:{type:"string",description:"The name of the cluster of resources that is a Snowflake virtual warehouse."}},required:["account","database","schema"]},SqlserverServer:{type:"object",title:"SqlserverServer",properties:{host:{type:"string",description:"The host to the database server",examples:["localhost"]},port:{type:"integer",description:"The port to the database server.",default:1433,examples:[1433]},database:{type:"string",description:"The name of the database.",examples:["database"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["dbo"]}},required:["host","database","schema"]},SynapseServer:{type:"object",title:"SynapseServer",properties:{host:{type:"string",description:"The host of the Synapse server."},port:{type:"integer",description:"The port of the Synapse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},TrinoServer:{type:"object",title:"TrinoServer",properties:{host:{type:"string",description:"The Trino host URL.",examples:["localhost"]},port:{type:"integer",description:"The Trino port."},catalog:{type:"string",description:"The name of the catalog.",examples:["hive"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["my_schema"]}},required:["host","port","catalog","schema"]},VerticaServer:{type:"object",title:"VerticaServer",properties:{host:{type:"string",description:"The host of the Vertica server."},port:{type:"integer",description:"The port of the Vertica server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]}},SchemaElement:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},name:{type:"string",description:"Name of the element."},physicalType:{type:"string",description:"The physical element data type in the data source.",examples:["table","view","topic","file"]},description:{type:"string",description:"Description of the element."},businessName:{type:"string",description:"The business name of the element."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{$ref:"#/$defs/Tags"},customProperties:{$ref:"#/$defs/CustomProperties"}}},SchemaObject:{type:"object",properties:{logicalType:{type:"string",description:"The logical element data type.",enum:["object"]},physicalName:{type:"string",description:"Physical name.",examples:["table_1_2_0"]},dataGranularityDescription:{type:"string",description:"Granular level of the data in the object.",examples:["Aggregation by country"]},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}},relationships:{type:"array",description:"A list of relationships to other properties. Each relationship must have 'from', 'to' and optionally 'type' field.",items:{$ref:"#/$defs/RelationshipSchemaLevel"}},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"}],required:["name"],unevaluatedProperties:!1},SchemaBaseProperty:{type:"object",properties:{primaryKey:{type:"boolean",description:"Boolean value specifying whether the element is primary or not. Default is false."},primaryKeyPosition:{type:"integer",default:-1,description:"If element is a primary key, the position of the primary key element. Starts from 1. Example of `account_id, name` being primary key columns, `account_id` has primaryKeyPosition 1 and `name` primaryKeyPosition 2. Default to -1."},logicalType:{type:"string",description:"The logical element data type.",enum:["string","date","timestamp","time","number","integer","object","array","boolean"]},logicalTypeOptions:{type:"object",description:"Additional optional metadata to describe the logical type."},physicalType:{type:"string",description:"The physical element data type in the data source. For example, VARCHAR(2), DOUBLE, INT."},physicalName:{type:"string",description:"Physical name.",examples:["col_str_a"]},required:{type:"boolean",default:!1,description:"Indicates if the element may contain Null values; possible values are true and false. Default is false."},unique:{type:"boolean",default:!1,description:"Indicates if the element contains unique values; possible values are true and false. Default is false."},partitioned:{type:"boolean",default:!1,description:"Indicates if the element is partitioned; possible values are true and false."},partitionKeyPosition:{type:"integer",default:-1,description:"If element is used for partitioning, the position of the partition element. Starts from 1. Example of `country, year` being partition columns, `country` has partitionKeyPosition 1 and `year` partitionKeyPosition 2. Default to -1."},classification:{type:"string",description:"Can be anything, like confidential, restricted, and public to more advanced categorization. Some companies like PayPal, use data classification indicating the class of data in the element; expected values are 1, 2, 3, 4, or 5.",examples:["confidential","restricted","public"]},encryptedName:{type:"string",description:"The element name within the dataset that contains the encrypted element value. For example, unencrypted element `email_address` might have an encryptedName of `email_address_encrypt`."},transformSourceObjects:{type:"array",description:"List of objects in the data source used in the transformation.",items:{type:"string"}},transformLogic:{type:"string",description:"Logic used in the element transformation."},transformDescription:{type:"string",description:"Describes the transform logic in very simple terms."},examples:{type:"array",description:"List of sample element values.",items:{$ref:"#/$defs/AnyType"}},criticalDataElement:{type:"boolean",default:!1,description:"True or false indicator; If element is considered a critical data element (CDE) then true else false."},relationships:{type:"array",description:"A list of relationships to other properties. When defined at property level, the 'from' field is implicit and should not be specified.",items:{$ref:"#/$defs/RelationshipPropertyLevel"}},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"},{if:{properties:{logicalType:{const:"string"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{minLength:{type:"integer",minimum:0,description:"Minimum length of the string."},maxLength:{type:"integer",minimum:0,description:"Maximum length of the string."},pattern:{type:"string",description:"Regular expression pattern to define valid value. Follows regular expression syntax from ECMA-262 (https://262.ecma-international.org/5.1/#sec-15.10.1)."},format:{type:"string",examples:["password","byte","binary","email","uuid","uri","hostname","ipv4","ipv6"],description:"Provides extra context about what format the string follows."}}}}}},{if:{properties:{logicalType:{const:"date"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{format:{type:"string",examples:["yyyy-MM-dd","yyyy-MM-dd HH:mm:ss","HH:mm:ss"],description:"Format of the date. Follows the format as prescribed by [JDK DateTimeFormatter](https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html). For example, format 'yyyy-MM-dd'."},exclusiveMaximum:{type:"string",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},maximum:{type:"string",description:"All date values are less than or equal to this value (values <= maximum)."},exclusiveMinimum:{type:"string",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},minimum:{type:"string",description:"All date values are greater than or equal to this value (values >= minimum)."}}}}}},{if:{anyOf:[{properties:{logicalType:{const:"timestamp"}}},{properties:{logicalType:{const:"time"}}}]},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{format:{type:"string",examples:["yyyy-MM-dd","yyyy-MM-dd HH:mm:ss","HH:mm:ss"],description:"Format of the date. Follows the format as prescribed by [JDK DateTimeFormatter](https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html). For example, format 'yyyy-MM-dd'."},exclusiveMaximum:{type:"string",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},maximum:{type:"string",description:"All date values are less than or equal to this value (values <= maximum)."},exclusiveMinimum:{type:"string",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},minimum:{type:"string",description:"All date values are greater than or equal to this value (values >= minimum)."},timezone:{type:"boolean",description:"Whether the timestamp defines the timezone or not. If true, timezone information is included in the timestamp."},defaultTimezone:{type:"string",description:"The default timezone of the timestamp. If timezone is not defined, the default timezone UTC is used.",default:"Etc/UTC"}}}}}},{if:{anyOf:[{properties:{logicalType:{const:"integer"}}}]},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"number",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"number",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use and whether it is signed or unsigned (follows the Rust integer types).",enum:["i8","i16","i32","i64","i128","u8","u16","u32","u64","u128"]}}}}}},{if:{anyOf:[{properties:{logicalType:{const:"number"}}}]},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"number",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"number",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use (follows the Rust float types).",enum:["f32","f64"]}}}}}},{if:{properties:{logicalType:{const:"object"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{maxProperties:{type:"integer",minimum:0,description:"Maximum number of properties."},minProperties:{type:"integer",minimum:0,default:0,description:"Minimum number of properties."},required:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0,description:"Property names that are required to exist in the object."}}},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}}}},{if:{properties:{logicalType:{const:"array"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{maxItems:{type:"integer",minimum:0,description:"Maximum number of items."},minItems:{type:"integer",minimum:0,default:0,description:"Minimum number of items"},uniqueItems:{type:"boolean",default:!1,description:"If set to true, all items in the array are unique."}}},items:{$ref:"#/$defs/SchemaItemProperty",description:"List of items in an array (only applicable when `logicalType: array`)."}}}}],unevaluatedProperties:!1},SchemaProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",required:["name"],unevaluatedProperties:!1},SchemaItemProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",properties:{properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}},unevaluatedProperties:!1},Tags:{type:"array",description:"A list of tags that may be assigned to the elements (object or property); the tags keyword may appear at any level. Tags may be used to better categorize an element. For example, `finance`, `sensitive`, `employee_record`.",examples:["finance","sensitive","employee_record"],items:{type:"string"}},DataQuality:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},businessImpact:{type:"string",description:"Consequences of the rule failure.",examples:["operational","regulatory"]},customProperties:{type:"array",description:"Additional properties required for rule execution.",items:{$ref:"#/$defs/CustomProperty"}},description:{type:"string",description:"Describe the quality check to be completed."},dimension:{type:"string",description:"The key performance indicator (KPI) or dimension for data quality.",enum:["accuracy","completeness","conformity","consistency","coverage","timeliness","uniqueness"]},method:{type:"string",examples:["reconciliation"]},name:{type:"string",description:"Name of the data quality check."},schedule:{type:"string",description:"Rule execution schedule details.",examples:["0 20 * * *"]},scheduler:{type:"string",description:"The name or type of scheduler used to start the data quality check.",examples:["cron"]},severity:{type:"string",description:"The severance of the quality rule.",examples:["info","warning","error"]},tags:{$ref:"#/$defs/Tags"},type:{type:"string",description:"The type of quality check. 'text' is human-readable text that describes the quality of the data. 'library' is a set of maintained predefined quality attributes such as row count or unique. 'sql' is an individual SQL query that returns a value that can be compared. 'custom' is quality attributes that are vendor-specific, such as Soda or Great Expectations.",enum:["text","library","sql","custom"],default:"library"},unit:{type:"string",description:"Unit the rule is using, popular values are `rows` or `percent`, but any value is allowed.",examples:["rows","percent"]}},allOf:[{if:{anyOf:[{properties:{type:{const:"library"}},required:["type"]},{properties:{metric:{type:"string"}},required:["metric"]}]},then:{$ref:"#/$defs/DataQualityLibrary"}},{if:{properties:{type:{const:"sql"}},required:["type"]},then:{$ref:"#/$defs/DataQualitySql"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/DataQualityCustom"}}],unevaluatedProperties:!1},DataQualityChecks:{type:"array",description:"Data quality rules with all the relevant information for rule setup and execution.",items:{$ref:"#/$defs/DataQuality"}},DataQualityOperators:{type:"object",description:"Common comparison operators for data quality checks.",oneOf:[{properties:{mustBe:{description:"Must be equal to the value to be valid. When using numbers, it is equivalent to '='."}},required:["mustBe"]},{properties:{mustNotBe:{description:"Must not be equal to the value to be valid. When using numbers, it is equivalent to '!='."}},required:["mustNotBe"]},{properties:{mustBeGreaterThan:{type:"number",description:"Must be greater than the value to be valid. It is equivalent to '>'."}},required:["mustBeGreaterThan"]},{properties:{mustBeGreaterOrEqualTo:{type:"number",description:"Must be greater than or equal to the value to be valid. It is equivalent to '>='."}},required:["mustBeGreaterOrEqualTo"]},{properties:{mustBeLessThan:{type:"number",description:"Must be less than the value to be valid. It is equivalent to '<'."}},required:["mustBeLessThan"]},{properties:{mustBeLessOrEqualTo:{type:"number",description:"Must be less than or equal to the value to be valid. It is equivalent to '<='."}},required:["mustBeLessOrEqualTo"]},{properties:{mustBeBetween:{type:"array",description:"Must be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}}},required:["mustBeBetween"]},{properties:{mustNotBeBetween:{type:"array",description:"Must not be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}}},required:["mustNotBeBetween"]}]},DataQualityLibrary:{type:"object",allOf:[{$ref:"#/$defs/DataQualityOperators"}],properties:{metric:{type:"string",description:"Define a data quality check based on the predefined metrics as per ODCS.",enum:["nullValues","missingValues","invalidValues","duplicateValues","rowCount"]},rule:{type:"string",deprecated:!0,description:"Use metric instead"},arguments:{type:"object",description:"Additional arguments for the metric, if needed."}},required:["metric"]},DataQualitySql:{type:"object",allOf:[{$ref:"#/$defs/DataQualityOperators"}],properties:{query:{type:"string",description:"Query string that adheres to the dialect of the provided server.",examples:["SELECT COUNT(*) FROM ${table} WHERE ${column} IS NOT NULL"]}},required:["query"]},DataQualityCustom:{type:"object",properties:{engine:{type:"string",description:"Name of the engine which executes the data quality checks.",examples:["soda","great-expectations","monte-carlo","dbt"]},implementation:{oneOf:[{type:"string"},{type:"object"}]}},required:["engine","implementation"]},AuthoritativeDefinitions:{type:"array",description:"List of links to sources that provide more details on the dataset; examples would be a link to an external definition, a training video, a git repo, data catalog, or another tool. Authoritative definitions follow the same structure in the standard.",items:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},url:{type:"string",description:"URL to the authority."},type:{type:"string",description:"Type of definition for authority: v2.3 adds standard values: `businessDefinition`, `transformationImplementation`, `videoTutorial`, `tutorial`, and `implementation`.",examples:["businessDefinition","transformationImplementation","videoTutorial","tutorial","implementation"]},description:{type:"string",description:"Description of the authoritative definition for humans."}},required:["url","type"],additionalProperties:!1}},Support:{type:"array",description:"Top level for support channels.",items:{$ref:"#/$defs/SupportItem"}},SupportItem:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},channel:{type:"string",description:"Channel name or identifier."},url:{type:"string",description:"Access URL using normal [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax) (https, mailto, etc.)."},description:{type:"string",description:"Description of the channel, free text."},tool:{type:"string",description:"Name of the tool, value can be `email`, `slack`, `teams`, `discord`, `ticket`, `googlechat`, or `other`.",examples:["email","slack","teams","discord","ticket","googlechat","other"]},scope:{type:"string",description:"Scope can be: `interactive`, `announcements`, `issues`, `notifications`.",examples:["interactive","announcements","issues","notifications"]},invitationUrl:{type:"string",description:"Some tools uses invitation URL for requesting or subscribing. Follows the [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax)."},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["channel"],additionalProperties:!1},Pricing:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},priceAmount:{type:"number",description:"Subscription price per unit of measure in `priceUnit`."},priceCurrency:{type:"string",description:"Currency of the subscription price in `price.priceAmount`."},priceUnit:{type:"string",description:"The unit of measure for calculating cost. Examples megabyte, gigabyte."}},additionalProperties:!1},TeamMember:{type:"object",description:"Team member information.",additionalProperties:!1,properties:{id:{$ref:"#/$defs/StableId"},username:{type:"string",description:"The user's username or email."},name:{type:"string",description:"The user's name."},description:{type:"string",description:"The user's description."},role:{type:"string",description:"The user's job role; Examples might be owner, data steward. There is no limit on the role."},dateIn:{type:"string",format:"date",description:"The date when the user joined the team."},dateOut:{type:"string",format:"date",description:"The date when the user ceased to be part of the team."},replacedByUsername:{type:"string",description:"The username of the user who replaced the previous user."},tags:{$ref:"#/$defs/Tags"},customProperties:{type:"array",description:"Custom properties block.",items:{$ref:"#/$defs/CustomProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"}},required:["username"]},Team:{type:"object",description:"Team information.",additionalProperties:!1,properties:{id:{$ref:"#/$defs/StableId"},name:{type:"string",description:"Team name."},description:{type:"string",description:"Team description."},members:{type:"array",description:"List of members.",items:{$ref:"#/$defs/TeamMember"}},tags:{$ref:"#/$defs/Tags"},customProperties:{type:"array",description:"Custom properties block.",items:{$ref:"#/$defs/CustomProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"}}},Role:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},role:{type:"string",description:"Name of the IAM role that provides access to the dataset."},description:{type:"string",description:"Description of the IAM role and its permissions."},access:{type:"string",description:"The type of access provided by the IAM role."},firstLevelApprovers:{type:"string",description:"The name(s) of the first-level approver(s) of the role."},secondLevelApprovers:{type:"string",description:"The name(s) of the second-level approver(s) of the role."},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["role"],additionalProperties:!1},ServiceLevelAgreementProperty:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},property:{type:"string",description:"Specific property in SLA, check the periodic table. May requires units (more details to come)."},value:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}],description:"Agreement value. The label will change based on the property itself."},valueExt:{$ref:"#/$defs/AnyNonCollectionType",description:"Extended agreement value. The label will change based on the property itself."},unit:{type:"string",description:"**d**, day, days for days; **y**, yr, years for years, etc. Units use the ISO standard."},element:{type:"string",description:"Element(s) to check on. Multiple elements should be extremely rare and, if so, separated by commas."},driver:{type:"string",description:"Describes the importance of the SLA from the list of: `regulatory`, `analytics`, or `operational`.",examples:["regulatory","analytics","operational"]},description:{type:"string",description:"Description of the SLA for humans.",examples:["99.9% of the time, data is available by 6 AM UTC"]},scheduler:{type:"string",description:"Name of the scheduler, can be cron or any tool your organization support.",examples:["cron"]},schedule:{type:"string",description:"Configuration information for the scheduling tool, for cron a possible value is 0 20 * * *.",examples:["0 20 * * *"]}},required:["property","value"],additionalProperties:!1},CustomProperties:{type:"array",description:"A list of key/value pairs for custom properties.",items:{$ref:"#/$defs/CustomProperty"}},CustomProperty:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},property:{type:"string",description:"The name of the key. Names should be in camel case–the same as if they were permanent properties in the contract."},value:{$ref:"#/$defs/AnyType",description:"The value of the key."},description:{type:"string",description:"Description of the custom property."}},required:["property","value"],additionalProperties:!1},AnyType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"},{type:"array"},{type:"object"}]},AnyNonCollectionType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}]},RelationshipBase:{type:"object",description:"Base definition for relationships between properties, typically for foreign key constraints.",properties:{type:{type:"string",description:"The type of relationship. Defaults to 'foreignKey'.",default:"foreignKey",enum:["foreignKey"]},from:{oneOf:[{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}],description:"Source property reference using fully qualified or shorthand notation."},{type:"array",description:"Array of source properties for composite keys.",items:{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}]},minItems:1}],description:"Source property or properties."},to:{oneOf:[{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}],description:"Target property reference using fully qualified or shorthand notation."},{type:"array",description:"Array of target properties for composite keys.",items:{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}]},minItems:1}],description:"Target property or properties to reference."},customProperties:{$ref:"#/$defs/CustomProperties"}}},RelationshipSchemaLevel:{type:"object",description:"Relationship definition at schema level, requiring both 'from' and 'to' fields with matching types.",allOf:[{$ref:"#/$defs/RelationshipBase"},{required:["from","to"]},{oneOf:[{description:"Single-column relationship - both fields must be strings",properties:{from:{type:"string"},to:{type:"string"}}},{description:"Composite key relationship - both fields must be arrays with matching lengths",properties:{from:{type:"array",items:{type:"string"},minItems:1},to:{type:"array",items:{type:"string"},minItems:1}}}]}],unevaluatedProperties:!1},RelationshipPropertyLevel:{type:"object",description:"Relationship definition at property level, where 'from' is implicitly the current property.",allOf:[{$ref:"#/$defs/RelationshipBase"},{type:"object",required:["to"]},{not:{required:["from"]},description:"The 'from' field must not be specified at property level as it is implicitly derived from the property context"}],unevaluatedProperties:!1},Relationship:{description:"Compatibility wrapper for relationship definitions.",oneOf:[{$ref:"#/$defs/RelationshipSchemaLevel"},{$ref:"#/$defs/RelationshipPropertyLevel"}]}}};var rse={$schema:"https://json-schema.org/draft/2019-09/schema",title:"Open Data Contract Standard (ODCS)",description:"An open data contract specification to establish agreement between data producers and consumers.",type:"object",properties:{version:{type:"string",description:"Current version of the data contract."},kind:{type:"string",default:"DataContract",description:"The kind of file this is. Valid value is `DataContract`.",enum:["DataContract"]},apiVersion:{type:"string",default:"v3.2.0",description:"Version of the standard used to build data contract. Default value is v3.2.0.",enum:["v3.2.0","v3.1.0","v3.0.2","v3.0.1","v3.0.0","v2.2.2","v2.2.1","v2.2.0"]},id:{type:"string",description:"A unique identifier used to reduce the risk of dataset name collisions, such as a UUID."},name:{type:"string",description:"Name of the data contract."},tenant:{type:"string",description:"Indicates the property the data is primarily associated with. Value is case insensitive."},tags:{$ref:"#/$defs/Tags"},status:{type:"string",description:"Current status of the dataset.",examples:["proposed","draft","active","deprecated","retired"]},servers:{type:"array",description:"List of servers where the datasets reside.",items:{$ref:"#/$defs/Server"}},dataProduct:{type:"string",description:"The name of the data product. DEPRECATED since v3.1.0.",deprecated:!0},description:{type:"object",description:"High level description of the dataset.",properties:{usage:{type:"string",description:"Intended usage of the dataset."},purpose:{type:"string",description:"Purpose of the dataset."},limitations:{type:"string",description:"Limitations of the dataset."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"}}},domain:{type:"string",description:"Name of the logical data domain.",examples:["imdb_ds_aggregate","receiver_profile_out","transaction_profile_out"]},context:{$ref:"#/$defs/Context"},schema:{type:"array",description:"A list of elements within the schema to be cataloged.",items:{$ref:"#/$defs/SchemaObject"}},support:{$ref:"#/$defs/Support"},price:{$ref:"#/$defs/Pricing"},team:{oneOf:[{$ref:"#/$defs/Team",description:"Team information object with members array (v3.1.0+)."},{type:"array",description:"DEPRECATED: Array of team members. Use the Team object structure instead. This array format is maintained for backward compatibility with v3.0.2 and earlier versions and will be removed in ODCS 4.0.",deprecated:!0,items:{$ref:"#/$defs/TeamMember"}}]},roles:{type:"array",description:"A list of roles that will provide user access to the dataset.",items:{$ref:"#/$defs/Role"}},slaDefaultElement:{type:"string",description:"DEPRECATED SINCE 3.1. WILL BE REMOVED IN ODCS 4.0. Element (using the element path notation) to do the checks on.",deprecated:!0},slaProperties:{type:"array",description:"A list of key/value pairs for SLA specific properties. There is no limit on the type of properties (more details to come).",items:{$ref:"#/$defs/ServiceLevelAgreementProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"},contractCreatedTs:{type:"string",format:"date-time",description:"Timestamp in UTC of when the data contract was created."}},required:["version","apiVersion","kind","id"],additionalProperties:!1,unevaluatedProperties:!1,$defs:{Context:{description:"AI and semantic context block (RFC-0038). Structured guidance for AI agents, LLMs, BI tools, and semantic layer platforms. Optional and additive.",oneOf:[{type:"string",description:"Shorthand: equivalent to providing instructions only."},{type:"object",properties:{instructions:{type:"string",description:"Natural language guidance for AI agents and tools on how to use this entity. Equivalent to a system prompt scoped to this level."},verifiedStatements:{type:"array",description:"Canonical questions (entries without `answer`) and verified Q&A pairs (entries with `answer`).",items:{type:"object",properties:{id:{type:"string",description:"Stable identifier for the entry."},question:{type:"string",description:"The canonical question."},answer:{type:"string",description:"The expected response or result description."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{type:"array",items:{type:"string"}},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["question"],additionalProperties:!1}},constraints:{type:"array",description:"Negative guidance: what AI agents must NOT do with this entity.",items:{type:"object",properties:{id:{type:"string",description:"Stable identifier for the constraint."},constraint:{type:"string",description:"The constraint text (negative guidance for AI agents)."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{type:"array",items:{type:"string"}},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["constraint"],additionalProperties:!1}}},additionalProperties:!1}]},ShorthandReference:{type:"string",description:"Shorthand notation using name fields (table_name.column_name)",pattern:"^[A-Za-z_][A-Za-z0-9_\\-]*(\\.[A-Za-z_][A-Za-z0-9_\\-]*)+$"},FullyQualifiedReference:{type:"string",description:"Fully qualified notation using id fields (section/id/properties/id), optionally prefixed with external file reference",pattern:"^(?:(?:https?:\\/\\/)?[A-Za-z0-9._\\-\\/]+\\.ya?ml#)?\\/?[A-Za-z_][A-Za-z0-9_]*\\/[^\\s.#/\\\\@!%&^]+(?:\\/[A-Za-z_][A-Za-z0-9_]*\\/[^\\s.#/\\\\@!%&^]+)*$"},StableId:{type:"string",description:"Stable technical identifier for references. Must be unique within its containing array. Per RFC-0026a an id cannot contain '.', '#', '/', '\\', '@', '!', '%', '&' or '^', nor whitespace.",pattern:"^[^\\s.#/\\\\@!%&^]+$"},Port:{type:["integer","string"],description:"A network port: an integer, or a string, e.g. to hold a variable reference such as ${DB_PORT} resolved at runtime (RFC 0050)."},Server:{type:"object",description:"Data source details of where data is physically stored.",properties:{id:{$ref:"#/$defs/StableId"},server:{type:"string",description:"Identifier of the server."},type:{type:"string",description:"Type of the server.",enum:["api","athena","azure","bigquery","btrieve","clickhouse","databricks","denodo","dremio","duckdb","exasol","fastobjects","glue","hana","cloudsql","db2","hive","iceberg","impala","informix","ingres","kafka","kinesis","local","mysql","oracle","poet","postgresql","postgres","presto","pubsub","redshift","s3","sftp","snowflake","sqlserver","synapse","teradata","trino","vectorwise","versant","vertica","zen","custom"]},description:{type:"string",description:"Description of the server."},environment:{type:"string",description:"Environment of the server.",examples:["prod","preprod","dev","uat"]},roles:{type:"array",description:"List of roles that have access to the server.",items:{$ref:"#/$defs/Role"}},customProperties:{$ref:"#/$defs/CustomProperties"}},allOf:[{if:{properties:{type:{const:"api"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ApiServer"}},{if:{properties:{type:{const:"athena"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AthenaServer"}},{if:{properties:{type:{const:"azure"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AzureServer"}},{if:{properties:{type:{const:"bigquery"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/BigQueryServer"}},{if:{properties:{type:{const:"btrieve"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ZenServer"}},{if:{properties:{type:{const:"clickhouse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ClickHouseServer"}},{if:{properties:{type:{const:"databricks"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DatabricksServer"}},{if:{properties:{type:{const:"denodo"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DenodoServer"}},{if:{properties:{type:{const:"dremio"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DremioServer"}},{if:{properties:{type:{const:"duckdb"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DuckdbServer"}},{if:{properties:{type:{const:"exasol"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ExasolServer"}},{if:{properties:{type:{const:"fastobjects"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PoetServer"}},{if:{properties:{type:{const:"glue"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GlueServer"}},{if:{properties:{type:{const:"cloudsql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GoogleCloudSqlServer"}},{if:{properties:{type:{const:"db2"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/IBMDB2Server"}},{if:{properties:{type:{const:"hive"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/HiveServer"}},{if:{properties:{type:{const:"impala"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ImpalaServer"}},{if:{properties:{type:{const:"informix"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/InformixServer"}},{if:{properties:{type:{const:"ingres"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/IngresServer"}},{if:{properties:{type:{const:"zen"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ZenServer"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/CustomServer"}},{if:{properties:{type:{const:"kafka"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KafkaServer"}},{if:{properties:{type:{const:"kinesis"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KinesisServer"}},{if:{properties:{type:{const:"local"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/LocalServer"}},{if:{properties:{type:{const:"mysql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/MySqlServer"}},{if:{properties:{type:{const:"oracle"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/OracleServer"}},{if:{properties:{type:{const:"poet"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PoetServer"}},{if:{properties:{type:{const:"hana"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/HanaServer"}},{if:{properties:{type:{const:"iceberg"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/IcebergServer"}},{if:{properties:{type:{const:"postgresql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"postgres"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"presto"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PrestoServer"}},{if:{properties:{type:{const:"pubsub"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PubSubServer"}},{if:{properties:{type:{const:"redshift"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/RedshiftServer"}},{if:{properties:{type:{const:"s3"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/S3Server"}},{if:{properties:{type:{const:"sftp"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SftpServer"}},{if:{properties:{type:{const:"snowflake"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SnowflakeServer"}},{if:{properties:{type:{const:"sqlserver"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SqlserverServer"}},{if:{properties:{type:{const:"synapse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SynapseServer"}},{if:{properties:{type:{const:"teradata"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/TeradataServer"}},{if:{properties:{type:{const:"trino"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/TrinoServer"}},{if:{properties:{type:{const:"vectorwise"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/VectorwiseServer"}},{if:{properties:{type:{const:"versant"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/VersantServer"}},{if:{properties:{type:{const:"vertica"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/VerticaServer"}}],required:["server","type"],unevaluatedProperties:!1},ServerSource:{ApiServer:{type:"object",title:"AthenaServer",properties:{location:{type:"string",format:"uri",description:"The url to the API.",examples:["https://api.example.com/v1"]}},required:["location"]},AthenaServer:{type:"object",title:"AthenaServer",properties:{stagingDir:{type:"string",format:"uri",description:"Amazon Athena automatically stores query results and metadata information for each query that runs in a query result location that you can specify in Amazon S3.",examples:["s3://my_storage_account_name/my_container/path"]},schema:{type:"string",description:"Identify the schema in the data source in which your tables exist."},catalog:{type:"string",description:"Identify the name of the Data Source, also referred to as a Catalog.",default:"awsdatacatalog"},regionName:{type:"string",description:"The region your AWS account uses.",examples:["eu-west-1"]},workgroup:{type:"string",description:"The Athena workgroup to use. Workgroups can enforce query result location and other client-side settings via the 'Override client-side settings' option.",examples:["primary"]}},required:["schema"]},AzureServer:{type:"object",title:"AzureServer",properties:{location:{type:"string",format:"uri",description:"Fully qualified path to Azure Blob Storage or Azure Data Lake Storage (ADLS), supports globs.",examples:["az://my_storage_account_name.blob.core.windows.net/my_container/path/*.parquet","abfss://my_storage_account_name.dfs.core.windows.net/my_container_name/path/*.parquet"]},format:{type:"string",examples:["parquet","delta","json","csv"],description:"File format."},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]},delimiter:{type:"string",examples:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location","format"]},BigQueryServer:{type:"object",title:"BigQueryServer",properties:{project:{type:"string",description:"The GCP project name."},dataset:{type:"string",description:"The GCP dataset name."}},required:["project","dataset"]},ClickHouseServer:{type:"object",title:"ClickHouseServer",properties:{host:{type:"string",description:"The host of the ClickHouse server."},port:{$ref:"#/$defs/Port",description:"The port to the ClickHouse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},DatabricksServer:{type:"object",title:"DatabricksServer",properties:{host:{type:"string",description:"The Databricks host",examples:["dbc-abcdefgh-1234.cloud.databricks.com"]},catalog:{type:"string",description:"The name of the Hive or Unity catalog"},schema:{type:"string",description:"The schema name in the catalog"}},required:["catalog","schema"]},DenodoServer:{type:"object",title:"DenodoServer",properties:{host:{type:"string",description:"The host of the Denodo server."},port:{$ref:"#/$defs/Port",description:"The port of the Denodo server."},database:{type:"string",description:"The name of the database."}},required:["host","port"]},DremioServer:{type:"object",title:"DremioServer",properties:{host:{type:"string",description:"The host of the Dremio server."},port:{$ref:"#/$defs/Port",description:"The port of the Dremio server."},schema:{type:"string",description:"The name of the schema."}},required:["host","port"]},DuckdbServer:{type:"object",title:"DuckdbServer",properties:{database:{type:"string",description:"Path to duckdb database file."},schema:{type:"string",description:"The name of the schema."}},required:["database"]},ExasolServer:{type:"object",title:"ExasolServer",properties:{host:{type:"string",description:"Host of the Exasol server. May be a cluster connection range.",examples:["exasol.acme.com","n11..14.acme.com"]},port:{$ref:"#/$defs/Port",description:"Port of the Exasol server.",default:8563,examples:[8563]},schema:{type:"string",description:"Name of the schema."}},required:["host"]},GlueServer:{type:"object",title:"GlueServer",properties:{account:{type:"string",description:"The AWS Glue account",examples:["1234-5678-9012"]},database:{type:"string",description:"The AWS Glue database name",examples:["my_database"]},location:{type:"string",format:"uri",description:"The AWS S3 path. Must be in the form of a URL.",examples:["s3://datacontract-example-orders-latest/data/{model}"]},format:{type:"string",description:"The format of the files",examples:["parquet","csv","json","delta"]},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]}},required:["account","database"]},GoogleCloudSqlServer:{type:"object",title:"GoogleCloudSqlServer",properties:{host:{type:"string",description:"The host of the Google Cloud Sql server."},port:{$ref:"#/$defs/Port",description:"The port of the Google Cloud Sql server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]},IBMDB2Server:{type:"object",title:"IBMDB2Server",properties:{host:{type:"string",description:"The host of the IBM DB2 server."},port:{$ref:"#/$defs/Port",description:"The port of the IBM DB2 server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database"]},HiveServer:{type:"object",title:"HiveServer",properties:{host:{type:"string",description:"The host to the Hive server. "},port:{$ref:"#/$defs/Port",description:"The port to the Hive server. Defaults to 10000."},database:{type:"string",description:"The name of the Hive database."}},required:["host","database"]},ImpalaServer:{type:"object",title:"ImpalaServer",properties:{host:{type:"string",description:"The host to the Impala server."},port:{$ref:"#/$defs/Port",description:"The port to the Impala server. Defaults to 21050."},database:{type:"string",description:"The name of the Impala database."}},required:["host","database"]},InformixServer:{type:"object",title:"InformixServer",properties:{host:{type:"string",description:"The host to the Informix server. "},port:{$ref:"#/$defs/Port",description:"The port to the Informix server. Defaults to 9088."},database:{type:"string",description:"The name of the database."}},required:["host","database"]},IngresServer:{type:"object",title:"IngresServer",properties:{database:{type:"string",description:"Database name to connect to on the Ingres instance.",examples:["sales"]},host:{type:"string",description:"Hostname or IP address of the Ingres server.",examples:["ingres.acme.com"]},port:{$ref:"#/$defs/Port",description:"Connection port for the Ingres Data Access Server (DAS) / SQL connections.",default:21064,examples:[21064]}},required:["database","host"]},ZenServer:{type:"object",title:"ZenServer",properties:{host:{type:"string",description:"Hostname or IP address of the Zen server."},port:{$ref:"#/$defs/Port",description:"Zen server SQL connections port. Defaults to 1583."},database:{type:"string",description:"Database name to connect to on the Zen server."}},required:["host","database"]},CustomServer:{type:"object",title:"CustomServer",properties:{account:{type:"string",description:"Account used by the server."},catalog:{type:"string",description:"Name of the catalog."},database:{type:"string",description:"Name of the database."},dataset:{type:"string",description:"Name of the dataset."},delimiter:{type:"string",description:"Delimiter."},endpointUrl:{type:"string",description:"Server endpoint.",format:"uri"},format:{type:"string",description:"File format."},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]},host:{type:"string",description:"Host name or IP address."},location:{type:"string",description:"A URL to a location.",format:"uri"},path:{type:"string",description:"Relative or absolute path to the data file(s)."},port:{$ref:"#/$defs/Port",description:"Port to the server. No default value is assumed for custom servers."},project:{type:"string",description:"Project name."},region:{type:"string",description:"Cloud region."},regionName:{type:"string",description:"Region name."},schema:{type:"string",description:"Name of the schema."},serviceName:{type:"string",description:"Name of the service."},stagingDir:{type:"string",description:"Staging directory."},warehouse:{type:"string",description:"Name of the cluster or warehouse."},stream:{type:"string",description:"Name of the data stream."}}},KafkaServer:{type:"object",title:"KafkaServer",description:"Kafka Server",properties:{host:{type:"string",description:"The bootstrap server of the kafka cluster."},format:{type:"string",description:"The format of the messages.",examples:["json","avro","protobuf","xml"],default:"json"},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]}},required:["host"]},KinesisServer:{type:"object",title:"KinesisDataStreamsServer",description:"Kinesis Data Streams Server",properties:{region:{type:"string",description:"AWS region.",examples:["eu-west-1"]},format:{type:"string",description:"The format of the record",examples:["json","avro","protobuf"]},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]}}},LocalServer:{type:"object",title:"LocalServer",properties:{path:{type:"string",description:"The relative or absolute path to the data file(s).",examples:["./folder/data.parquet","./folder/*.parquet"]},format:{type:"string",description:"The format of the file(s)",examples:["json","parquet","delta","csv"]},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]}},required:["path","format"]},MySqlServer:{type:"object",title:"MySqlServer",properties:{host:{type:"string",description:"The host of the MySql server."},port:{$ref:"#/$defs/Port",description:"The port of the MySql server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},OracleServer:{type:"object",title:"OracleServer",properties:{host:{type:"string",description:"The host to the oracle server",examples:["localhost"]},port:{$ref:"#/$defs/Port",description:"The port to the oracle server.",examples:[1523]},serviceName:{type:"string",description:"The name of the service.",examples:["service"]}},required:["host","port","serviceName"]},PoetServer:{type:"object",title:"PoetServer",properties:{database:{type:"string",description:"Database name to connect to on the FastObjects instance.",examples:["parts_catalog"]},host:{type:"string",description:"Hostname or IP address of the FastObjects server. The literal LOCAL selects the in-process embedded engine.",default:"LOCAL",examples:["LOCAL","fastobjects02.acme.com"]},port:{$ref:"#/$defs/Port",description:"Connection port for FastObjects connections.",default:6001,examples:[6001]}},required:["database"]},PostgresServer:{type:"object",title:"PostgresServer",properties:{host:{type:"string",description:"The host to the Postgres server"},port:{$ref:"#/$defs/Port",description:"The port to the Postgres server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema in the database."}},required:["host","port","database","schema"]},HanaServer:{type:"object",title:"HanaServer",properties:{host:{type:"string",description:"Host of the HANA server."},port:{$ref:"#/$defs/Port",description:"Port of the HANA server."},database:{type:"string",description:"Name of the database (tenant)."},schema:{type:"string",description:"Name of the schema."}},required:["host"]},IcebergServer:{type:"object",title:"IcebergServer",properties:{catalog:{type:"string",description:"Catalog name as registered in the query engine or catalog service.",examples:["my_catalog"]},catalogUrl:{type:"string",format:"uri",description:"URL of the Iceberg compatible REST catalog service (Polaris, S3 Tables, Nessie, Unity Catalog, Glue, etc.)",examples:["https://my-catalog-service.com"]},namespace:{type:"string",description:"Dot-separated namespace/schema path within the catalog (e.g. db.schema or just db)."},warehouse:{type:"string",description:"Logical catalog or base location for the catalog to use.",examples:["s3://my-bucket/warehouse/sales/","production","development"]}},required:["catalog","catalogUrl"]},PrestoServer:{type:"object",title:"PrestoServer",properties:{host:{type:"string",description:"The host to the Presto server",examples:["localhost:8080"]},catalog:{type:"string",description:"The name of the catalog.",examples:["postgres"]},schema:{type:"string",description:"The name of the schema.",examples:["public"]}},required:["host"]},PubSubServer:{type:"object",title:"PubSubServer",properties:{project:{type:"string",description:"The GCP project name."}},required:["project"]},RedshiftServer:{type:"object",title:"RedshiftServer",properties:{host:{type:"string",description:"An optional string describing the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},region:{type:"string",description:"AWS region of Redshift server.",examples:["us-east-1"]},account:{type:"string",description:"The account used by the server."}},required:["database","schema"]},S3Server:{type:"object",title:"S3Server",properties:{location:{type:"string",format:"uri",description:"S3 URL, starting with `s3://`",examples:["s3://datacontract-example-orders-latest/data/{model}/*.json"]},endpointUrl:{type:"string",format:"uri",description:"The server endpoint for S3-compatible servers.",examples:["https://minio.example.com"]},format:{type:"string",examples:["parquet","delta","json","csv"],description:"File format."},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]},delimiter:{type:"string",examples:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SftpServer:{type:"object",title:"SftpServer",properties:{location:{type:"string",format:"uri",pattern:"^sftp://.*",description:"SFTP URL, starting with `sftp://`",examples:["sftp://123.123.12.123/{model}/*.json"]},format:{type:"string",examples:["parquet","delta","json","csv"],description:"File format."},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]},delimiter:{type:"string",examples:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SnowflakeServer:{type:"object",title:"SnowflakeServer",properties:{host:{type:"string",description:"The host to the Snowflake server"},port:{$ref:"#/$defs/Port",description:"The port to the Snowflake server."},account:{type:"string",description:"The Snowflake account used by the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},warehouse:{type:"string",description:"The name of the cluster of resources that is a Snowflake virtual warehouse."}},required:["account","database","schema"]},SqlserverServer:{type:"object",title:"SqlserverServer",properties:{host:{type:"string",description:"The host to the database server",examples:["localhost"]},port:{$ref:"#/$defs/Port",description:"The port to the database server.",default:1433,examples:[1433]},database:{type:"string",description:"The name of the database.",examples:["database"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["dbo"]}},required:["host","database","schema"]},SynapseServer:{type:"object",title:"SynapseServer",properties:{host:{type:"string",description:"The host of the Synapse server."},port:{$ref:"#/$defs/Port",description:"The port of the Synapse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},TeradataServer:{type:"object",title:"TeradataServer",properties:{host:{type:"string",description:"Host of the Teradata server.",examples:["teradata.acme.com"]},port:{$ref:"#/$defs/Port",description:"Port of the Teradata server.",default:1025,examples:[1025]},database:{type:"string",description:"Name of the database."}},required:["host"]},TrinoServer:{type:"object",title:"TrinoServer",properties:{host:{type:"string",description:"The Trino host URL.",examples:["localhost"]},port:{$ref:"#/$defs/Port",description:"The Trino port."},catalog:{type:"string",description:"The name of the catalog.",examples:["hive"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["my_schema"]}},required:["host","port","catalog","schema"]},VectorwiseServer:{type:"object",title:"VectorwiseServer",properties:{database:{type:"string",description:"Database name to connect to on the Analytics Engine server.",examples:["warehouse"]},host:{type:"string",description:"Hostname or IP address of the Analytics Engine server.",examples:["analytics.acme.com"]},port:{$ref:"#/$defs/Port",description:"Connection port for the Data Access Server (DAS) / SQL connections.",default:21064,examples:[21064]}},required:["database","host"]},VersantServer:{type:"object",title:"VersantServer",properties:{database:{type:"string",description:"Database name to connect to on the NoSQL Database instance.",examples:["policies"]},host:{type:"string",description:"Hostname or IP address of the NoSQL Database server.",default:"localhost",examples:["nosql.acme.com"]},port:{$ref:"#/$defs/Port",description:"Connection port for Actian NoSQL Database connections.",default:5019,examples:[5019]}},required:["database"]},VerticaServer:{type:"object",title:"VerticaServer",properties:{host:{type:"string",description:"The host of the Vertica server."},port:{$ref:"#/$defs/Port",description:"The port of the Vertica server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]}},SchemaElement:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},name:{type:"string",description:"Name of the element."},physicalType:{type:"string",description:"The physical element data type in the data source.",examples:["table","view","topic","file"]},description:{type:"string",description:"Description of the element."},businessName:{type:"string",description:"The business name of the element."},deprecated:{type:"boolean",description:"Indicates this element is deprecated and should not be used in new implementations. Defaults to false.",default:!1},synonyms:{$ref:"#/$defs/Synonyms"},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{$ref:"#/$defs/Tags"},customProperties:{$ref:"#/$defs/CustomProperties"}}},SchemaObject:{type:"object",properties:{logicalType:{type:"string",description:"The logical element data type.",enum:["object"]},physicalName:{type:"string",description:"Physical name.",examples:["table_1_2_0"]},dataGranularityDescription:{type:"string",description:"Granular level of the data in the object.",examples:["Aggregation by country"]},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}},relationships:{type:"array",description:"A list of relationships to other properties. Each relationship must have 'from', 'to' and optionally 'type' field.",items:{$ref:"#/$defs/RelationshipSchemaLevel"}},quality:{$ref:"#/$defs/DataQualityChecks"},context:{$ref:"#/$defs/Context"}},allOf:[{$ref:"#/$defs/SchemaElement"}],required:["name"],unevaluatedProperties:!1},SchemaBaseProperty:{type:"object",properties:{primaryKey:{type:"boolean",description:"Boolean value specifying whether the element is primary or not. Default is false."},primaryKeyPosition:{type:"integer",default:-1,description:"If element is a primary key, the position of the primary key element. Starts from 1. Example of `account_id, name` being primary key columns, `account_id` has primaryKeyPosition 1 and `name` primaryKeyPosition 2. Default to -1."},logicalType:{type:"string",description:"The logical element data type.",enum:["string","date","timestamp","time","number","integer","object","array","boolean","map","vector"]},logicalTypeOptions:{type:"object",description:"Additional optional metadata to describe the logical type."},physicalType:{type:"string",description:"The physical element data type in the data source. For example, VARCHAR(2), DOUBLE, INT."},physicalName:{type:"string",description:"Physical name.",examples:["col_str_a"]},required:{type:"boolean",default:!1,description:"Indicates if the element may contain Null values; possible values are true and false. Default is false."},unique:{type:"boolean",default:!1,description:"Indicates if the element contains unique values; possible values are true and false. Default is false."},semanticType:{type:"string",enum:["column","measure","dimension"],default:"column",description:"The semantic role the property plays in the data model. `column` (the default) is a physical column in the underlying data store; `measure` is an aggregated value (e.g., `SUM(revenue)`) whose aggregation expression is held in `transformLogic`; `dimension` is a categorical attribute used for grouping and filtering. See RFC 0034."},partitioned:{type:"boolean",default:!1,description:"Indicates if the element is partitioned; possible values are true and false."},partitionKeyPosition:{type:"integer",default:-1,description:"If element is used for partitioning, the position of the partition element. Starts from 1. Example of `country, year` being partition columns, `country` has partitionKeyPosition 1 and `year` partitionKeyPosition 2. Default to -1."},classification:{type:"string",description:"Can be anything, like confidential, restricted, and public to more advanced categorization. Some companies like PayPal, use data classification indicating the class of data in the element; expected values are 1, 2, 3, 4, or 5.",examples:["confidential","restricted","public"]},encryptedName:{type:"string",description:"The element name within the dataset that contains the encrypted element value. For example, unencrypted element `email_address` might have an encryptedName of `email_address_encrypt`."},transformSourceObjects:{type:"array",description:"List of objects in the data source used in the transformation.",items:{type:"string"}},transformLogic:{type:"string",description:"Logic used in the element transformation."},transformDescription:{type:"string",description:"Describes the transform logic in very simple terms."},examples:{type:"array",description:"List of sample element values.",items:{$ref:"#/$defs/AnyType"}},enum:{type:"array",description:"Enumeration of allowed values for this property. Each entry is an object with at least a `value`. See RFC 0033.",minItems:1,uniqueItems:!0,items:{$ref:"#/$defs/EnumValue"}},criticalDataElement:{type:"boolean",default:!1,description:"True or false indicator; If element is considered a critical data element (CDE) then true else false."},relationships:{type:"array",description:"A list of relationships to other properties. When defined at property level, the 'from' field is implicit and should not be specified.",items:{$ref:"#/$defs/RelationshipPropertyLevel"}},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"},{if:{properties:{logicalType:{const:"string"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{minLength:{type:"integer",minimum:0,description:"Minimum length of the string."},maxLength:{type:"integer",minimum:0,description:"Maximum length of the string."},pattern:{type:"string",description:"Regular expression pattern to define valid value. Follows regular expression syntax from ECMA-262 (https://262.ecma-international.org/5.1/#sec-15.10.1)."},format:{type:"string",examples:["password","byte","binary","email","uuid","uri","hostname","ipv4","ipv6"],description:"Provides extra context about what format the string follows."}}}}}},{if:{properties:{logicalType:{const:"date"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{format:{type:"string",examples:["yyyy-MM-dd","yyyy-MM-dd HH:mm:ss","HH:mm:ss"],description:"Format of the date. Follows the format as prescribed by [JDK DateTimeFormatter](https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html). For example, format 'yyyy-MM-dd'."},exclusiveMaximum:{type:"string",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},maximum:{type:"string",description:"All date values are less than or equal to this value (values <= maximum)."},exclusiveMinimum:{type:"string",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},minimum:{type:"string",description:"All date values are greater than or equal to this value (values >= minimum)."}}}}}},{if:{anyOf:[{properties:{logicalType:{const:"timestamp"}}},{properties:{logicalType:{const:"time"}}}]},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{format:{type:"string",examples:["yyyy-MM-dd","yyyy-MM-dd HH:mm:ss","HH:mm:ss"],description:"Format of the date. Follows the format as prescribed by [JDK DateTimeFormatter](https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html). For example, format 'yyyy-MM-dd'."},exclusiveMaximum:{type:"string",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},maximum:{type:"string",description:"All date values are less than or equal to this value (values <= maximum)."},exclusiveMinimum:{type:"string",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},minimum:{type:"string",description:"All date values are greater than or equal to this value (values >= minimum)."},timezone:{type:"boolean",description:"Whether the timestamp defines the timezone or not. If true, timezone information is included in the timestamp."},defaultTimezone:{type:"string",description:"The default timezone of the timestamp. If timezone is not defined, the default timezone UTC is used.",default:"Etc/UTC"}}}}}},{if:{anyOf:[{properties:{logicalType:{const:"integer"}}}]},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"number",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"number",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use and whether it is signed or unsigned (follows the Rust integer types).",enum:["i8","i16","i32","i64","i128","u8","u16","u32","u64","u128"]}}}}}},{if:{anyOf:[{properties:{logicalType:{const:"number"}}}]},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"number",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"number",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use (follows the Rust float types).",enum:["f32","f64"]}}}}}},{if:{properties:{logicalType:{const:"object"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{maxProperties:{type:"integer",minimum:0,description:"Maximum number of properties."},minProperties:{type:"integer",minimum:0,default:0,description:"Minimum number of properties."},required:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0,description:"Property names that are required to exist in the object."}}},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}}}},{if:{properties:{logicalType:{const:"array"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{maxItems:{type:"integer",minimum:0,description:"Maximum number of items."},minItems:{type:"integer",minimum:0,default:0,description:"Minimum number of items"},uniqueItems:{type:"boolean",default:!1,description:"If set to true, all items in the array are unique."}}},items:{$ref:"#/$defs/SchemaItemProperty",description:"List of items in an array (only applicable when `logicalType: array`)."}}}},{if:{properties:{logicalType:{const:"map"}},required:["logicalType"]},then:{properties:{map:{type:"object",description:"Key/value definition for a map (only applicable when `logicalType: map`). See RFC 0030.",additionalProperties:!1,properties:{key:{$ref:"#/$defs/SchemaItemProperty",description:"Definition of the map's key."},value:{$ref:"#/$defs/SchemaItemProperty",description:"Definition of the map's value."}},required:["key","value"]}},required:["map"]}},{if:{properties:{logicalType:{const:"vector"}},required:["logicalType"]},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{dimensions:{type:"integer",minimum:1,description:"The fixed length of the vector. Positive integer (only applicable when `logicalType: vector`). See RFC 0042.",examples:[384,768,1024,1536,3072]},elementType:{type:"string",enum:["bfloat16","binary","float16","float32","float64","int8","uint8"],default:"float32",description:"Numeric type of each vector element. `binary` means each element is one bit (binary-quantized vectors)."},distanceMetric:{type:"string",enum:["cosine","dotProduct","euclidean","hamming","manhattan"],description:"Intended similarity metric. Advisory — the physical index may differ."},embeddingModel:{type:"string",description:"Identifier of the model used to produce the vectors.",examples:["openai/text-embedding-3-small","cohere/embed-english-v3.0"]},embeddingModelVersion:{type:"string",description:"Version or revision of the embedding model, when the model identifier does not already carry one."},normalized:{type:"boolean",default:!1,description:"True if vectors are L2-normalized before storage, which makes cosine and dotProduct equivalent."}},required:["dimensions"]}}}}],unevaluatedProperties:!1},SchemaProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",required:["name"],unevaluatedProperties:!1},SchemaItemProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",properties:{properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}},unevaluatedProperties:!1},Tags:{type:"array",description:"A list of tags that may be assigned to the elements (object or property); the tags keyword may appear at any level. Tags may be used to better categorize an element. For example, `finance`, `sensitive`, `employee_record`.",examples:["finance","sensitive","employee_record"],items:{type:"string"}},DataQuality:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},businessImpact:{type:"string",description:"Consequences of the rule failure.",examples:["operational","regulatory"]},customProperties:{type:"array",description:"Additional properties required for rule execution.",items:{$ref:"#/$defs/CustomProperty"}},description:{type:"string",description:"Describe the quality check to be completed."},dimension:{type:"string",description:"The key performance indicator (KPI) or dimension for data quality.",enum:["accuracy","completeness","conformity","consistency","coverage","timeliness","uniqueness"]},method:{type:"string",examples:["reconciliation"]},name:{type:"string",description:"Name of the data quality check."},schedule:{type:"string",description:"Rule execution schedule details.",examples:["0 20 * * *"]},scheduler:{type:"string",description:"The name or type of scheduler used to start the data quality check.",examples:["cron"]},severity:{type:"string",description:"The severance of the quality rule.",examples:["info","warning","error"]},tags:{$ref:"#/$defs/Tags"},type:{type:"string",description:"The type of quality check. 'text' is human-readable text that describes the quality of the data. 'library' is a set of maintained predefined quality attributes such as row count or unique. 'sql' is an individual SQL query that returns a value that can be compared. 'custom' is quality attributes that are vendor-specific, such as Soda or Great Expectations.",enum:["text","library","sql","custom"],default:"library"},unit:{type:"string",description:"Unit the rule is using, popular values are `rows` or `percent`, but any value is allowed.",examples:["rows","percent"]}},allOf:[{if:{anyOf:[{properties:{type:{const:"library"}},required:["type"]},{properties:{metric:{type:"string"}},required:["metric"]}]},then:{$ref:"#/$defs/DataQualityLibrary"}},{if:{properties:{type:{const:"sql"}},required:["type"]},then:{$ref:"#/$defs/DataQualitySql"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/DataQualityCustom"}}],unevaluatedProperties:!1},DataQualityChecks:{type:"array",description:"Data quality rules with all the relevant information for rule setup and execution.",items:{$ref:"#/$defs/DataQuality"}},DataQualityOperators:{type:"object",description:"Common comparison operators for data quality checks.",oneOf:[{properties:{mustBe:{description:"Must be equal to the value to be valid. When using numbers, it is equivalent to '='."}},required:["mustBe"]},{properties:{mustNotBe:{description:"Must not be equal to the value to be valid. When using numbers, it is equivalent to '!='."}},required:["mustNotBe"]},{properties:{mustBeGreaterThan:{type:"number",description:"Must be greater than the value to be valid. It is equivalent to '>'."}},required:["mustBeGreaterThan"]},{properties:{mustBeGreaterOrEqualTo:{type:"number",description:"Must be greater than or equal to the value to be valid. It is equivalent to '>='."}},required:["mustBeGreaterOrEqualTo"]},{properties:{mustBeLessThan:{type:"number",description:"Must be less than the value to be valid. It is equivalent to '<'."}},required:["mustBeLessThan"]},{properties:{mustBeLessOrEqualTo:{type:"number",description:"Must be less than or equal to the value to be valid. It is equivalent to '<='."}},required:["mustBeLessOrEqualTo"]},{properties:{mustBeBetween:{type:"array",description:"Must be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}}},required:["mustBeBetween"]},{properties:{mustNotBeBetween:{type:"array",description:"Must not be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}}},required:["mustNotBeBetween"]}]},DataQualityLibrary:{type:"object",allOf:[{$ref:"#/$defs/DataQualityOperators"}],properties:{metric:{type:"string",description:"Define a data quality check based on the predefined metrics as per ODCS.",enum:["nullValues","missingValues","invalidValues","duplicateValues","rowCount"]},rule:{type:"string",deprecated:!0,description:"Use metric instead"},arguments:{type:"object",description:"Additional arguments for the metric, if needed."}},required:["metric"]},DataQualitySql:{type:"object",allOf:[{$ref:"#/$defs/DataQualityOperators"}],properties:{query:{type:"string",description:"Query string that adheres to the dialect of the provided server.",examples:["SELECT COUNT(*) FROM ${table} WHERE ${column} IS NOT NULL"]}},required:["query"]},DataQualityCustom:{type:"object",properties:{engine:{type:"string",description:"Name of the engine which executes the data quality checks.",examples:["soda","great-expectations","monte-carlo","dbt"]},implementation:{oneOf:[{type:"string"},{type:"object"}]}},required:["engine","implementation"]},AuthoritativeDefinitions:{type:"array",description:"List of links to sources that provide more details on the dataset; examples would be a link to an external definition, a training video, a git repo, data catalog, or another tool. Authoritative definitions follow the same structure in the standard.",items:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},url:{type:"string",description:"URL to the authority."},type:{type:"string",description:"Type of definition for authority. See the recommended values in the documentation.",examples:["businessDefinition","canonicalUrl","glossary","implementation","ontology","taxonomy","transformationImplementation","tutorial","videoTutorial"]},description:{type:"string",description:"Description of the authoritative definition for humans."}},required:["url","type"],additionalProperties:!1}},Support:{type:"array",description:"Top level for support channels.",items:{$ref:"#/$defs/SupportItem"}},SupportItem:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},channel:{type:"string",description:"Channel name or identifier."},url:{type:"string",description:"Access URL using normal [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax) (https, mailto, etc.)."},description:{type:"string",description:"Description of the channel, free text."},tool:{type:"string",description:"Name of the tool, value can be `email`, `slack`, `teams`, `discord`, `ticket`, `googlechat`, or `other`.",examples:["email","slack","teams","discord","ticket","googlechat","other"]},scope:{type:"string",description:"Scope can be: `interactive`, `announcements`, `issues`, `notifications`.",examples:["interactive","announcements","issues","notifications"]},invitationUrl:{type:"string",description:"Some tools uses invitation URL for requesting or subscribing. Follows the [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax)."},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["channel"],additionalProperties:!1},Pricing:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},priceAmount:{type:"number",description:"Subscription price per unit of measure in `priceUnit`."},priceCurrency:{type:"string",description:"Currency of the subscription price in `price.priceAmount`."},priceUnit:{type:"string",description:"The unit of measure for calculating cost. Examples megabyte, gigabyte."}},additionalProperties:!1},TeamMember:{type:"object",description:"Team member information.",additionalProperties:!1,properties:{id:{$ref:"#/$defs/StableId"},username:{type:"string",description:"The user's username or email."},name:{type:"string",description:"The user's name."},description:{type:"string",description:"The user's description."},role:{type:"string",description:"The user's job role; Examples might be owner, data steward. There is no limit on the role."},dateIn:{type:"string",format:"date",description:"The date when the user joined the team."},dateOut:{type:"string",format:"date",description:"The date when the user ceased to be part of the team."},replacedByUsername:{type:"string",description:"The username of the user who replaced the previous user."},tags:{$ref:"#/$defs/Tags"},customProperties:{type:"array",description:"Custom properties block.",items:{$ref:"#/$defs/CustomProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"}},required:["username"]},Team:{type:"object",description:"Team information.",additionalProperties:!1,properties:{id:{$ref:"#/$defs/StableId"},name:{type:"string",description:"Team name."},description:{type:"string",description:"Team description."},members:{type:"array",description:"List of members.",items:{$ref:"#/$defs/TeamMember"}},tags:{$ref:"#/$defs/Tags"},customProperties:{type:"array",description:"Custom properties block.",items:{$ref:"#/$defs/CustomProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"}}},Role:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},role:{type:"string",description:"Name of the IAM role that provides access to the dataset."},description:{type:"string",description:"Description of the IAM role and its permissions."},access:{type:"string",description:"The type of access provided by the IAM role."},firstLevelApprovers:{type:"string",description:"The name(s) of the first-level approver(s) of the role."},secondLevelApprovers:{type:"string",description:"The name(s) of the second-level approver(s) of the role."},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["role"],additionalProperties:!1},ServiceLevelAgreementProperty:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},property:{type:"string",description:"Specific property in SLA, check the periodic table. May requires units (more details to come)."},value:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}],description:"Agreement value. The label will change based on the property itself."},valueExt:{$ref:"#/$defs/AnyNonCollectionType",description:"Extended agreement value. The label will change based on the property itself."},unit:{type:"string",description:"**d**, day, days for days; **y**, yr, years for years, etc. Units use the ISO standard."},element:{type:"string",description:"Element(s) to check on. Multiple elements should be extremely rare and, if so, separated by commas."},driver:{type:"string",description:"Describes the importance of the SLA from the list of: `regulatory`, `analytics`, or `operational`.",examples:["regulatory","analytics","operational"]},description:{type:"string",description:"Description of the SLA for humans.",examples:["99.9% of the time, data is available by 6 AM UTC"]},scheduler:{type:"string",description:"Name of the scheduler, can be cron or any tool your organization support.",examples:["cron"]},schedule:{type:"string",description:"Configuration information for the scheduling tool, for cron a possible value is 0 20 * * *.",examples:["0 20 * * *"]},customProperties:{$ref:"#/$defs/CustomProperties"},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"}},required:["property","value"],additionalProperties:!1},CustomProperties:{type:"array",description:"A list of key/value pairs for custom properties.",items:{$ref:"#/$defs/CustomProperty"}},EnumValue:{type:"object",description:"An allowed value within a property's enumeration. See RFC 0033.",properties:{value:{$ref:"#/$defs/AnyNonCollectionType",description:"The allowed value. Required."},label:{type:"string",description:"Human-readable label for the value, suitable for UI display."},id:{$ref:"#/$defs/StableId"},description:{type:"string",description:"Optional description of what this enum value represents."},customProperties:{type:"array",description:"Custom properties attached to this enum value (e.g., translations).",items:{$ref:"#/$defs/CustomProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{$ref:"#/$defs/Tags"}},required:["value"],additionalProperties:!1},Synonyms:{type:"array",description:"A list of alternative names for the object. See RFC 0041.",items:{$ref:"#/$defs/Synonym"}},Synonym:{type:"object",description:"An alternative name for a named object, helping catalogs, AI/LLM tools, and natural language interfaces resolve business vocabulary to the underlying object. See RFC 0041.",properties:{id:{$ref:"#/$defs/StableId"},synonym:{type:"string",description:"The synonymous term."},description:{type:"string",description:"Short human-readable note about when or why this synonym is used."},locale:{type:"string",description:"BCP 47 language tag (e.g., `en-US`, `fr-FR`) when the synonym is language-specific."},source:{type:"string",description:"Origin of the synonym (e.g., `glossary`, `finance-team`, `legacy-system`)."},status:{type:"string",description:"Lifecycle status of the synonym (e.g., `active`, `deprecated`)."},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["synonym"],additionalProperties:!1},CustomProperty:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},property:{type:"string",description:"The name of the key. Names should be in camel case–the same as if they were permanent properties in the contract."},value:{$ref:"#/$defs/AnyType",description:"The value of the key."},description:{type:"string",description:"Description of the custom property."},vendor:{type:"string",description:"Identifies the vendor, provider, or external system associated with this custom property. SHOULD be a stable, lowercase identifier matching ^[a-z0-9][a-z0-9-]*$ (e.g. confluent, zeenea, atlan, soda). Tools MUST preserve unknown vendor values.",examples:["confluent","zeenea","atlan","soda"]}},required:["property","value"],additionalProperties:!1},AnyType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"},{type:"array"},{type:"object"}]},AnyNonCollectionType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}]},RelationshipBase:{type:"object",description:"Base definition for relationships between properties, typically for foreign key constraints.",properties:{id:{type:"string",description:"Optional stable identifier for this relationship, unique within its containing relationships array. SHOULD remain stable across contract versions. Cannot contain: . # / \\ @ ! % & ^"},type:{type:"string",description:"The type of relationship. Defaults to 'foreignKey'.",default:"foreignKey",enum:["foreignKey"]},from:{oneOf:[{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}],description:"Source property reference using fully qualified or shorthand notation."},{type:"array",description:"Array of source properties for composite keys.",items:{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}]},minItems:1}],description:"Source property or properties."},to:{oneOf:[{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}],description:"Target property reference using fully qualified or shorthand notation."},{type:"array",description:"Array of target properties for composite keys.",items:{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}]},minItems:1}],description:"Target property or properties to reference."},customProperties:{$ref:"#/$defs/CustomProperties"}}},RelationshipSchemaLevel:{type:"object",description:"Relationship definition at schema level, requiring both 'from' and 'to' fields with matching types.",allOf:[{$ref:"#/$defs/RelationshipBase"},{required:["from","to"]},{oneOf:[{description:"Single-column relationship - both fields must be strings",properties:{from:{type:"string"},to:{type:"string"}}},{description:"Composite key relationship - both fields must be arrays with matching lengths",properties:{from:{type:"array",items:{type:"string"},minItems:1},to:{type:"array",items:{type:"string"},minItems:1}}}]}],unevaluatedProperties:!1},RelationshipPropertyLevel:{type:"object",description:"Relationship definition at property level, where 'from' is implicitly the current property.",allOf:[{$ref:"#/$defs/RelationshipBase"},{type:"object",required:["to"]},{not:{required:["from"]},description:"The 'from' field must not be specified at property level as it is implicitly derived from the property context"}],unevaluatedProperties:!1},Relationship:{description:"Compatibility wrapper for relationship definitions.",oneOf:[{$ref:"#/$defs/RelationshipSchemaLevel"},{$ref:"#/$defs/RelationshipPropertyLevel"}]}}};var ise="umf.odcs",G3e=Xie,lse=(e,t)=>t==="json"?Jt(e):Wa(e),sse={"v3.0.0":Zie,"v3.0.1":ese,"v3.0.2":tse,"v3.1.0":nse,"v3.2.0":rse},ose=new Map;function H3e(e){let t=e,n=[{code:"ODCS_CONTEXT",path:"",severity:"warning",message:"Contract shape checks do not enforce data quality/SLA rules, resolve references, map physical types or prove exact-number constraints beyond JS precision; edits regenerate layout while retaining original source"}],r=(a,l,c,u="warning")=>n.push({code:a,path:l,message:c,severity:u});if(Object.keys(t).some((a)=>!["profile","root","originalSource","originalFormat"].includes(a)))r("ODCS_REPRESENTATION","","Unknown representation fields remain in UMF");function i(a,l){let c=a.kind==="null"?["kind"]:a.kind==="array"?["kind","items"]:a.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(a).some((u)=>!c.includes(u)))r("ODCS_REPRESENTATION",l,"Unknown tagged-tree fields remain in UMF");if(a.kind==="object")for(let[u,p]of Object.entries(a.members))i(p,l+"/"+Pe(u));if(a.kind==="array")a.items.forEach((u,p)=>i(u,l+"/"+p))}if(i(t.root,""),t.root.kind!=="object")return r("ODCS_STRUCTURE","","Expected ODCS contract object","error"),n;try{lse(t.originalSource,t.originalFormat)}catch(a){return r("ODCS_ARCHIVE","/originalSource",String(a),"error"),n}let s=t.root.members.apiVersion;if(s?.kind!=="string"||!Object.hasOwn(sse,s.value))return r("ODCS_VERSION","/apiVersion","Missing or unknown ODCS version preserved without interpretation"),n;let o=ose.get(s.value);if(!o){let a=new ase.default({allErrors:!0,strict:!1,validateFormats:!1,ownProperties:!0});Gp(a),o=a.compile(sse[s.value]),ose.set(s.value,o)}if(!o(JSON.parse(Be(t.root))))for(let a of(o.errors??[]).slice(0,100))r("ODCS_NATIVE_SCHEMA",a.instancePath,a.message??"Native contract shape mismatch");if((o.errors?.length??0)>100)r("ODCS_DIAGNOSTICS_TRUNCATED","","More than 100 native schema diagnostics; first 100 retained");return n}function z3e(){return new nt().register(G3e,H3e)}function cse(e){return We(e,z3e())}function W3e(e){let t=cse(e);if(!t.valid)throw new U("ODCS_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="contract")?.elements.find((r)=>r.id==="contract")?.extensions[ise];if(!n||e.vocabularies[ise]?.version!=="0.1.0")throw new U("ODCS_PAYLOAD","Expected pinned ODCS payload");return Ae(n)}function use(e,t){let n=W3e(e);if(t!==void 0&&!["json","yaml"].includes(t))throw new U("ODCS_FORMAT","Unsupported native format");if(cse(e).diagnostics.some((r)=>r.code==="ODCS_REPRESENTATION"))throw new U("ODCS_EXPORT","Unknown representation fields cannot be discarded");if((t??n.originalFormat)===n.originalFormat&&Be(lse(n.originalSource,n.originalFormat))===Be(n.root))return n.originalSource;return Be(n.root)+` -`}var e6e=Ar(fae(),1);var{create:W8e,defineProperty:ZS,defineProperties:Q8e,getOwnPropertyDescriptor:Y8e,getOwnPropertyDescriptors:X8e,getOwnPropertyNames:Z8e,getOwnPropertySymbols:mae,getPrototypeOf:eVe}=Object,Eae=Object.prototype.hasOwnProperty,tVe=Object.prototype.propertyIsEnumerable,Xy=(e,t)=>(t=Symbol[e])?t:Symbol.for("Symbol."+e),nVe=(e)=>{throw TypeError(e)},yae=(e,t,n)=>(t in e)?ZS(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ms=(e,t)=>{for(var n in t||(t={}))Eae.call(t,n)&&yae(e,n,t[n]);if(mae)for(var n of mae(t))tVe.call(t,n)&&yae(e,n,t[n]);return e},eE=(e,t)=>Q8e(e,X8e(t)),un=(e,t)=>()=>{try{return t||e((t={exports:{}}).exports,t),t.exports}catch(n){throw t=0,n}},rVe=(e,t)=>{for(var n in t)ZS(e,n,{get:t[n],enumerable:!0})},iVe=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of Z8e(t))!Eae.call(e,i)&&i!==n&&ZS(e,i,{get:()=>t[i],enumerable:!(r=Y8e(t,i))||r.enumerable});return e},tE=(e,t,n)=>(n=e!=null?W8e(eVe(e)):{},iVe(t||!e||!e.__esModule?ZS(n,"default",{value:e,enumerable:!0}):n,e)),Cs=function(e,t){this[0]=e,this[1]=t},xp=(e,t,n)=>{var r=(a,l,c,u)=>{try{var p=n[a](l),d=(l=p.value)instanceof Cs,f=p.done;Promise.resolve(d?l[0]:l).then((m)=>d?r(a==="return"?a:"next",l[1]?{done:m.done,value:m.value}:m,c,u):c({value:m,done:f})).catch((m)=>r("throw",m,c,u))}catch(m){u(m)}},i=(a,l,c,u)=>o[a]=(p)=>(l=new Promise((d,f,m)=>(m=()=>r(a,p,d,f),s?s.then(m):m())),u=()=>s===c&&(s=0),s=c=l.then(u,u),l),s,o={};return n=n.apply(e,t),o[Xy("asyncIterator")]=()=>o,i("next"),i("throw"),i("return"),o},_f=(e)=>{var t=e[Xy("asyncIterator")],n=!1,r,i={};return t==null?(t=e[Xy("iterator")](),r=(s)=>i[s]=(o)=>t[s](o)):(t=t.call(e),r=(s)=>i[s]=(o)=>{if(n){if(n=!1,s==="throw")throw o;return o}return n=!0,{done:!1,value:new Cs(new Promise((a)=>{var l=t[s](o);l instanceof Object||nVe("Object expected"),a(l)}),1)}}),i[Xy("iterator")]=()=>i,r("next"),"throw"in t?r("throw"):i.throw=(s)=>{throw s},"return"in t&&r("return"),i},sa=(e,t,n)=>(t=e[Xy("asyncIterator")])?t.call(e):(e=e[Xy("iterator")](),t={},n=(r,i)=>(i=e[r])&&(t[r]=(s)=>new Promise((o,a,l)=>(s=i.call(e,s),l=s.done,Promise.resolve(s.value).then((c)=>o({value:c,done:l}),a)))),n("next"),n("return"),t),sVe=un((e)=>{e.byteLength=l,e.toByteArray=u,e.fromByteArray=f;var t=[],n=[],r=typeof Uint8Array<"u"?Uint8Array:Array,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(s=0,o=i.length;s0)throw Error("Invalid string. Length must be a multiple of 4");var h=m.indexOf("=");h===-1&&(h=y);var b=h===y?0:4-h%4;return[h,b]}function l(m){var y=a(m),h=y[0],b=y[1];return(h+b)*3/4-b}function c(m,y,h){return(y+h)*3/4-h}function u(m){var y,h=a(m),b=h[0],g=h[1],x=new r(c(m,b,g)),v=0,D=g>0?b-4:b,T;for(T=0;T>16&255,x[v++]=y>>8&255,x[v++]=y&255;return g===2&&(y=n[m.charCodeAt(T)]<<2|n[m.charCodeAt(T+1)]>>4,x[v++]=y&255),g===1&&(y=n[m.charCodeAt(T)]<<10|n[m.charCodeAt(T+1)]<<4|n[m.charCodeAt(T+2)]>>2,x[v++]=y>>8&255,x[v++]=y&255),x}function p(m){return t[m>>18&63]+t[m>>12&63]+t[m>>6&63]+t[m&63]}function d(m,y,h){for(var b,g=[],x=y;xD?D:v+x));return b===1?(y=m[h-1],g.push(t[y>>2]+t[y<<4&63]+"==")):b===2&&(y=(m[h-2]<<8)+m[h-1],g.push(t[y>>10]+t[y>>4&63]+t[y<<2&63]+"=")),g.join("")}}),oVe=un((e)=>{e.read=function(t,n,r,i,s){var o,a,l=s*8-i-1,c=(1<>1,p=-7,d=r?s-1:0,f=r?-1:1,m=t[n+d];for(d+=f,o=m&(1<<-p)-1,m>>=-p,p+=l;p>0;o=o*256+t[n+d],d+=f,p-=8);for(a=o&(1<<-p)-1,o>>=-p,p+=i;p>0;a=a*256+t[n+d],d+=f,p-=8);if(o===0)o=1-u;else{if(o===c)return a?NaN:(m?-1:1)*(1/0);a=a+Math.pow(2,i),o=o-u}return(m?-1:1)*a*Math.pow(2,o-i)},e.write=function(t,n,r,i,s,o){var a,l,c,u=o*8-s-1,p=(1<>1,f=s===23?Math.pow(2,-24)-Math.pow(2,-77):0,m=i?0:o-1,y=i?1:-1,h=n<0||n===0&&1/n<0?1:0;for(n=Math.abs(n),isNaN(n)||n===1/0?(l=isNaN(n)?1:0,a=p):(a=Math.floor(Math.log(n)/Math.LN2),n*(c=Math.pow(2,-a))<1&&(a--,c*=2),a+d>=1?n+=f/c:n+=f*Math.pow(2,1-d),n*c>=2&&(a++,c/=2),a+d>=p?(l=0,a=p):a+d>=1?(l=(n*c-1)*Math.pow(2,s),a=a+d):(l=n*Math.pow(2,d-1)*Math.pow(2,s),a=0));s>=8;t[r+m]=l&255,m+=y,l/=256,s-=8);for(a=a<0;t[r+m]=a&255,m+=y,a/=256,u-=8);t[r+m-y]|=h*128}}),Uc=un((e)=>{var t=sVe(),n=oVe(),r=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;e.Buffer=a,e.SlowBuffer=g,e.INSPECT_MAX_BYTES=50;var i=2147483647;e.kMaxLength=i,a.TYPED_ARRAY_SUPPORT=s(),!a.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function s(){try{let _=new Uint8Array(1),S={foo:function(){return 42}};return Object.setPrototypeOf(S,Uint8Array.prototype),Object.setPrototypeOf(_,S),_.foo()===42}catch(_){return!1}}Object.defineProperty(a.prototype,"parent",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.buffer}}),Object.defineProperty(a.prototype,"offset",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.byteOffset}});function o(_){if(_>i)throw RangeError('The value "'+_+'" is invalid for option "size"');let S=new Uint8Array(_);return Object.setPrototypeOf(S,a.prototype),S}function a(_,S,k){if(typeof _=="number"){if(typeof S=="string")throw TypeError('The "string" argument must be of type string. Received type number');return p(_)}return l(_,S,k)}a.poolSize=8192;function l(_,S,k){if(typeof _=="string")return d(_,S);if(ArrayBuffer.isView(_))return m(_);if(_==null)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof _);if(ye(_,ArrayBuffer)||_&&ye(_.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(ye(_,SharedArrayBuffer)||_&&ye(_.buffer,SharedArrayBuffer)))return y(_,S,k);if(typeof _=="number")throw TypeError('The "value" argument must not be of type number. Received type number');let E=_.valueOf&&_.valueOf();if(E!=null&&E!==_)return a.from(E,S,k);let A=h(_);if(A)return A;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof _[Symbol.toPrimitive]=="function")return a.from(_[Symbol.toPrimitive]("string"),S,k);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof _)}a.from=function(_,S,k){return l(_,S,k)},Object.setPrototypeOf(a.prototype,Uint8Array.prototype),Object.setPrototypeOf(a,Uint8Array);function c(_){if(typeof _!="number")throw TypeError('"size" argument must be of type number');if(_<0)throw RangeError('The value "'+_+'" is invalid for option "size"')}function u(_,S,k){return c(_),_<=0?o(_):S!==void 0?typeof k=="string"?o(_).fill(S,k):o(_).fill(S):o(_)}a.alloc=function(_,S,k){return u(_,S,k)};function p(_){return c(_),o(_<0?0:b(_)|0)}a.allocUnsafe=function(_){return p(_)},a.allocUnsafeSlow=function(_){return p(_)};function d(_,S){if((typeof S!="string"||S==="")&&(S="utf8"),!a.isEncoding(S))throw TypeError("Unknown encoding: "+S);let k=x(_,S)|0,E=o(k),A=E.write(_,S);return A!==k&&(E=E.slice(0,A)),E}function f(_){let S=_.length<0?0:b(_.length)|0,k=o(S);for(let E=0;E=i)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+i.toString(16)+" bytes");return _|0}function g(_){return+_!=_&&(_=0),a.alloc(+_)}a.isBuffer=function(_){return _!=null&&_._isBuffer===!0&&_!==a.prototype},a.compare=function(_,S){if(ye(_,Uint8Array)&&(_=a.from(_,_.offset,_.byteLength)),ye(S,Uint8Array)&&(S=a.from(S,S.offset,S.byteLength)),!a.isBuffer(_)||!a.isBuffer(S))throw TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(_===S)return 0;let k=_.length,E=S.length;for(let A=0,Q=Math.min(k,E);AE.length?(a.isBuffer(Q)||(Q=a.from(Q)),Q.copy(E,A)):Uint8Array.prototype.set.call(E,Q,A);else if(a.isBuffer(Q))Q.copy(E,A);else throw TypeError('"list" argument must be an Array of Buffers');A+=Q.length}return E};function x(_,S){if(a.isBuffer(_))return _.length;if(ArrayBuffer.isView(_)||ye(_,ArrayBuffer))return _.byteLength;if(typeof _!="string")throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof _);let k=_.length,E=arguments.length>2&&arguments[2]===!0;if(!E&&k===0)return 0;let A=!1;for(;;)switch(S){case"ascii":case"latin1":case"binary":return k;case"utf8":case"utf-8":return j(_).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return k*2;case"hex":return k>>>1;case"base64":return fe(_).length;default:if(A)return E?-1:j(_).length;S=(""+S).toLowerCase(),A=!0}}a.byteLength=x;function v(_,S,k){let E=!1;if((S===void 0||S<0)&&(S=0),S>this.length||((k===void 0||k>this.length)&&(k=this.length),k<=0)||(k>>>=0,S>>>=0,k<=S))return"";for(_||(_="utf8");;)switch(_){case"hex":return je(this,S,k);case"utf8":case"utf-8":return me(this,S,k);case"ascii":return pe(this,S,k);case"latin1":case"binary":return de(this,S,k);case"base64":return Y(this,S,k);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return be(this,S,k);default:if(E)throw TypeError("Unknown encoding: "+_);_=(_+"").toLowerCase(),E=!0}}a.prototype._isBuffer=!0;function D(_,S,k){let E=_[S];_[S]=_[k],_[k]=E}a.prototype.swap16=function(){let _=this.length;if(_%2!==0)throw RangeError("Buffer size must be a multiple of 16-bits");for(let S=0;S<_;S+=2)D(this,S,S+1);return this},a.prototype.swap32=function(){let _=this.length;if(_%4!==0)throw RangeError("Buffer size must be a multiple of 32-bits");for(let S=0;S<_;S+=4)D(this,S,S+3),D(this,S+1,S+2);return this},a.prototype.swap64=function(){let _=this.length;if(_%8!==0)throw RangeError("Buffer size must be a multiple of 64-bits");for(let S=0;S<_;S+=8)D(this,S,S+7),D(this,S+1,S+6),D(this,S+2,S+5),D(this,S+3,S+4);return this},a.prototype.toString=function(){let _=this.length;return _===0?"":arguments.length===0?me(this,0,_):v.apply(this,arguments)},a.prototype.toLocaleString=a.prototype.toString,a.prototype.equals=function(_){if(!a.isBuffer(_))throw TypeError("Argument must be a Buffer");return this===_?!0:a.compare(this,_)===0},a.prototype.inspect=function(){let _="",S=e.INSPECT_MAX_BYTES;return _=this.toString("hex",0,S).replace(/(.{2})/g,"$1 ").trim(),this.length>S&&(_+=" ... "),""},r&&(a.prototype[r]=a.prototype.inspect),a.prototype.compare=function(_,S,k,E,A){if(ye(_,Uint8Array)&&(_=a.from(_,_.offset,_.byteLength)),!a.isBuffer(_))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof _);if(S===void 0&&(S=0),k===void 0&&(k=_?_.length:0),E===void 0&&(E=0),A===void 0&&(A=this.length),S<0||k>_.length||E<0||A>this.length)throw RangeError("out of range index");if(E>=A&&S>=k)return 0;if(E>=A)return-1;if(S>=k)return 1;if(S>>>=0,k>>>=0,E>>>=0,A>>>=0,this===_)return 0;let Q=A-E,le=k-S,Je=Math.min(Q,le),St=this.slice(E,A),ut=_.slice(S,k);for(let xt=0;xt2147483647?k=2147483647:k<-2147483648&&(k=-2147483648),k=+k,Oe(k)&&(k=A?0:_.length-1),k<0&&(k=_.length+k),k>=_.length){if(A)return-1;k=_.length-1}else if(k<0)if(A)k=0;else return-1;if(typeof S=="string"&&(S=a.from(S,E)),a.isBuffer(S))return S.length===0?-1:N(_,S,k,E,A);if(typeof S=="number")return S=S&255,typeof Uint8Array.prototype.indexOf=="function"?A?Uint8Array.prototype.indexOf.call(_,S,k):Uint8Array.prototype.lastIndexOf.call(_,S,k):N(_,[S],k,E,A);throw TypeError("val must be string, number or Buffer")}function N(_,S,k,E,A){let Q=1,le=_.length,Je=S.length;if(E!==void 0&&(E=String(E).toLowerCase(),E==="ucs2"||E==="ucs-2"||E==="utf16le"||E==="utf-16le")){if(_.length<2||S.length<2)return-1;Q=2,le/=2,Je/=2,k/=2}function St(xt,At){return Q===1?xt[At]:xt.readUInt16BE(At*Q)}let ut;if(A){let xt=-1;for(ut=k;utle&&(k=le-Je),ut=k;ut>=0;ut--){let xt=!0;for(let At=0;AtA&&(E=A)):E=A;let Q=S.length;E>Q/2&&(E=Q/2);let le;for(le=0;le>>0,isFinite(k)?(k=k>>>0,E===void 0&&(E="utf8")):(E=k,k=void 0);else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");let A=this.length-S;if((k===void 0||k>A)&&(k=A),_.length>0&&(k<0||S<0)||S>this.length)throw RangeError("Attempt to write outside buffer bounds");E||(E="utf8");let Q=!1;for(;;)switch(E){case"hex":return O(this,_,S,k);case"utf8":case"utf-8":return C(this,_,S,k);case"ascii":case"latin1":case"binary":return X(this,_,S,k);case"base64":return te(this,_,S,k);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return L(this,_,S,k);default:if(Q)throw TypeError("Unknown encoding: "+E);E=(""+E).toLowerCase(),Q=!0}},a.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function Y(_,S,k){return S===0&&k===_.length?t.fromByteArray(_):t.fromByteArray(_.slice(S,k))}function me(_,S,k){k=Math.min(_.length,k);let E=[],A=S;for(;A239?4:Q>223?3:Q>191?2:1;if(A+Je<=k){let St,ut,xt,At;switch(Je){case 1:Q<128&&(le=Q);break;case 2:St=_[A+1],(St&192)===128&&(At=(Q&31)<<6|St&63,At>127&&(le=At));break;case 3:St=_[A+1],ut=_[A+2],(St&192)===128&&(ut&192)===128&&(At=(Q&15)<<12|(St&63)<<6|ut&63,At>2047&&(At<55296||At>57343)&&(le=At));break;case 4:St=_[A+1],ut=_[A+2],xt=_[A+3],(St&192)===128&&(ut&192)===128&&(xt&192)===128&&(At=(Q&15)<<18|(St&63)<<12|(ut&63)<<6|xt&63,At>65535&&At<1114112&&(le=At))}}le===null?(le=65533,Je=1):le>65535&&(le-=65536,E.push(le>>>10&1023|55296),le=56320|le&1023),E.push(le),A+=Je}return Z(E)}var I=4096;function Z(_){let S=_.length;if(S<=I)return String.fromCharCode.apply(String,_);let k="",E=0;for(;EE)&&(k=E);let A="";for(let Q=S;Qk&&(_=k),S<0?(S+=k,S<0&&(S=0)):S>k&&(S=k),S<_&&(S=_);let E=this.subarray(_,S);return Object.setPrototypeOf(E,a.prototype),E};function Ie(_,S,k){if(_%1!==0||_<0)throw RangeError("offset is not uint");if(_+S>k)throw RangeError("Trying to access beyond buffer length")}a.prototype.readUintLE=a.prototype.readUIntLE=function(_,S,k){_=_>>>0,S=S>>>0,k||Ie(_,S,this.length);let E=this[_],A=1,Q=0;for(;++Q>>0,S=S>>>0,k||Ie(_,S,this.length);let E=this[_+--S],A=1;for(;S>0&&(A*=256);)E+=this[_+--S]*A;return E},a.prototype.readUint8=a.prototype.readUInt8=function(_,S){return _=_>>>0,S||Ie(_,1,this.length),this[_]},a.prototype.readUint16LE=a.prototype.readUInt16LE=function(_,S){return _=_>>>0,S||Ie(_,2,this.length),this[_]|this[_+1]<<8},a.prototype.readUint16BE=a.prototype.readUInt16BE=function(_,S){return _=_>>>0,S||Ie(_,2,this.length),this[_]<<8|this[_+1]},a.prototype.readUint32LE=a.prototype.readUInt32LE=function(_,S){return _=_>>>0,S||Ie(_,4,this.length),(this[_]|this[_+1]<<8|this[_+2]<<16)+this[_+3]*16777216},a.prototype.readUint32BE=a.prototype.readUInt32BE=function(_,S){return _=_>>>0,S||Ie(_,4,this.length),this[_]*16777216+(this[_+1]<<16|this[_+2]<<8|this[_+3])},a.prototype.readBigUInt64LE=Ce(function(_){_=_>>>0,Re(_,"offset");let S=this[_],k=this[_+7];(S===void 0||k===void 0)&&Ne(_,this.length-8);let E=S+this[++_]*256+this[++_]*65536+this[++_]*16777216,A=this[++_]+this[++_]*256+this[++_]*65536+k*16777216;return BigInt(E)+(BigInt(A)<>>0,Re(_,"offset");let S=this[_],k=this[_+7];(S===void 0||k===void 0)&&Ne(_,this.length-8);let E=S*16777216+this[++_]*65536+this[++_]*256+this[++_],A=this[++_]*16777216+this[++_]*65536+this[++_]*256+k;return(BigInt(E)<>>0,S=S>>>0,k||Ie(_,S,this.length);let E=this[_],A=1,Q=0;for(;++Q=A&&(E-=Math.pow(2,8*S)),E},a.prototype.readIntBE=function(_,S,k){_=_>>>0,S=S>>>0,k||Ie(_,S,this.length);let E=S,A=1,Q=this[_+--E];for(;E>0&&(A*=256);)Q+=this[_+--E]*A;return A*=128,Q>=A&&(Q-=Math.pow(2,8*S)),Q},a.prototype.readInt8=function(_,S){return _=_>>>0,S||Ie(_,1,this.length),this[_]&128?(255-this[_]+1)*-1:this[_]},a.prototype.readInt16LE=function(_,S){_=_>>>0,S||Ie(_,2,this.length);let k=this[_]|this[_+1]<<8;return k&32768?k|4294901760:k},a.prototype.readInt16BE=function(_,S){_=_>>>0,S||Ie(_,2,this.length);let k=this[_+1]|this[_]<<8;return k&32768?k|4294901760:k},a.prototype.readInt32LE=function(_,S){return _=_>>>0,S||Ie(_,4,this.length),this[_]|this[_+1]<<8|this[_+2]<<16|this[_+3]<<24},a.prototype.readInt32BE=function(_,S){return _=_>>>0,S||Ie(_,4,this.length),this[_]<<24|this[_+1]<<16|this[_+2]<<8|this[_+3]},a.prototype.readBigInt64LE=Ce(function(_){_=_>>>0,Re(_,"offset");let S=this[_],k=this[_+7];(S===void 0||k===void 0)&&Ne(_,this.length-8);let E=this[_+4]+this[_+5]*256+this[_+6]*65536+(k<<24);return(BigInt(E)<>>0,Re(_,"offset");let S=this[_],k=this[_+7];(S===void 0||k===void 0)&&Ne(_,this.length-8);let E=(S<<24)+this[++_]*65536+this[++_]*256+this[++_];return(BigInt(E)<>>0,S||Ie(_,4,this.length),n.read(this,_,!0,23,4)},a.prototype.readFloatBE=function(_,S){return _=_>>>0,S||Ie(_,4,this.length),n.read(this,_,!1,23,4)},a.prototype.readDoubleLE=function(_,S){return _=_>>>0,S||Ie(_,8,this.length),n.read(this,_,!0,52,8)},a.prototype.readDoubleBE=function(_,S){return _=_>>>0,S||Ie(_,8,this.length),n.read(this,_,!1,52,8)};function J(_,S,k,E,A,Q){if(!a.isBuffer(_))throw TypeError('"buffer" argument must be a Buffer instance');if(S>A||S_.length)throw RangeError("Index out of range")}a.prototype.writeUintLE=a.prototype.writeUIntLE=function(_,S,k,E){if(_=+_,S=S>>>0,k=k>>>0,!E){let le=Math.pow(2,8*k)-1;J(this,_,S,k,le,0)}let A=1,Q=0;for(this[S]=_&255;++Q>>0,k=k>>>0,!E){let le=Math.pow(2,8*k)-1;J(this,_,S,k,le,0)}let A=k-1,Q=1;for(this[S+A]=_&255;--A>=0&&(Q*=256);)this[S+A]=_/Q&255;return S+k},a.prototype.writeUint8=a.prototype.writeUInt8=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,1,255,0),this[S]=_&255,S+1},a.prototype.writeUint16LE=a.prototype.writeUInt16LE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,2,65535,0),this[S]=_&255,this[S+1]=_>>>8,S+2},a.prototype.writeUint16BE=a.prototype.writeUInt16BE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,2,65535,0),this[S]=_>>>8,this[S+1]=_&255,S+2},a.prototype.writeUint32LE=a.prototype.writeUInt32LE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,4,4294967295,0),this[S+3]=_>>>24,this[S+2]=_>>>16,this[S+1]=_>>>8,this[S]=_&255,S+4},a.prototype.writeUint32BE=a.prototype.writeUInt32BE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,4,4294967295,0),this[S]=_>>>24,this[S+1]=_>>>16,this[S+2]=_>>>8,this[S+3]=_&255,S+4};function _e(_,S,k,E,A){ke(S,E,A,_,k,7);let Q=Number(S&BigInt(4294967295));_[k++]=Q,Q=Q>>8,_[k++]=Q,Q=Q>>8,_[k++]=Q,Q=Q>>8,_[k++]=Q;let le=Number(S>>BigInt(32)&BigInt(4294967295));return _[k++]=le,le=le>>8,_[k++]=le,le=le>>8,_[k++]=le,le=le>>8,_[k++]=le,k}function ue(_,S,k,E,A){ke(S,E,A,_,k,7);let Q=Number(S&BigInt(4294967295));_[k+7]=Q,Q=Q>>8,_[k+6]=Q,Q=Q>>8,_[k+5]=Q,Q=Q>>8,_[k+4]=Q;let le=Number(S>>BigInt(32)&BigInt(4294967295));return _[k+3]=le,le=le>>8,_[k+2]=le,le=le>>8,_[k+1]=le,le=le>>8,_[k]=le,k+8}a.prototype.writeBigUInt64LE=Ce(function(_,S=0){return _e(this,_,S,BigInt(0),BigInt("0xffffffffffffffff"))}),a.prototype.writeBigUInt64BE=Ce(function(_,S=0){return ue(this,_,S,BigInt(0),BigInt("0xffffffffffffffff"))}),a.prototype.writeIntLE=function(_,S,k,E){if(_=+_,S=S>>>0,!E){let Je=Math.pow(2,8*k-1);J(this,_,S,k,Je-1,-Je)}let A=0,Q=1,le=0;for(this[S]=_&255;++A>0)-le&255;return S+k},a.prototype.writeIntBE=function(_,S,k,E){if(_=+_,S=S>>>0,!E){let Je=Math.pow(2,8*k-1);J(this,_,S,k,Je-1,-Je)}let A=k-1,Q=1,le=0;for(this[S+A]=_&255;--A>=0&&(Q*=256);)_<0&&le===0&&this[S+A+1]!==0&&(le=1),this[S+A]=(_/Q>>0)-le&255;return S+k},a.prototype.writeInt8=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,1,127,-128),_<0&&(_=255+_+1),this[S]=_&255,S+1},a.prototype.writeInt16LE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,2,32767,-32768),this[S]=_&255,this[S+1]=_>>>8,S+2},a.prototype.writeInt16BE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,2,32767,-32768),this[S]=_>>>8,this[S+1]=_&255,S+2},a.prototype.writeInt32LE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,4,2147483647,-2147483648),this[S]=_&255,this[S+1]=_>>>8,this[S+2]=_>>>16,this[S+3]=_>>>24,S+4},a.prototype.writeInt32BE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,4,2147483647,-2147483648),_<0&&(_=4294967295+_+1),this[S]=_>>>24,this[S+1]=_>>>16,this[S+2]=_>>>8,this[S+3]=_&255,S+4},a.prototype.writeBigInt64LE=Ce(function(_,S=0){return _e(this,_,S,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),a.prototype.writeBigInt64BE=Ce(function(_,S=0){return ue(this,_,S,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function ce(_,S,k,E,A,Q){if(k+E>_.length)throw RangeError("Index out of range");if(k<0)throw RangeError("Index out of range")}function Le(_,S,k,E,A){return S=+S,k=k>>>0,A||ce(_,S,k,4,340282346638528860000000000000000000000,-340282346638528860000000000000000000000),n.write(_,S,k,E,23,4),k+4}a.prototype.writeFloatLE=function(_,S,k){return Le(this,_,S,!0,k)},a.prototype.writeFloatBE=function(_,S,k){return Le(this,_,S,!1,k)};function Ke(_,S,k,E,A){return S=+S,k=k>>>0,A||ce(_,S,k,8,179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000,-179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000),n.write(_,S,k,E,52,8),k+8}a.prototype.writeDoubleLE=function(_,S,k){return Ke(this,_,S,!0,k)},a.prototype.writeDoubleBE=function(_,S,k){return Ke(this,_,S,!1,k)},a.prototype.copy=function(_,S,k,E){if(!a.isBuffer(_))throw TypeError("argument should be a Buffer");if(k||(k=0),!E&&E!==0&&(E=this.length),S>=_.length&&(S=_.length),S||(S=0),E>0&&E=this.length)throw RangeError("Index out of range");if(E<0)throw RangeError("sourceEnd out of bounds");E>this.length&&(E=this.length),_.length-S>>0,k=k===void 0?this.length:k>>>0,_||(_=0);let A;if(typeof _=="number")for(A=S;A4294967296?A=se(String(k)):typeof k=="bigint"&&(A=String(k),(k>BigInt(2)**BigInt(32)||k<-(BigInt(2)**BigInt(32)))&&(A=se(A)),A+="n"),E+=` It must be ${S}. Received ${A}`,E},RangeError);function se(_){let S="",k=_.length,E=_[0]==="-"?1:0;for(;k>=E+4;k-=3)S=`_${_.slice(k-3,k)}${S}`;return`${_.slice(0,k)}${S}`}function he(_,S,k){Re(S,"offset"),(_[S]===void 0||_[S+k]===void 0)&&Ne(S,_.length-(k+1))}function ke(_,S,k,E,A,Q){if(_>k||_3?S===0||S===BigInt(0)?Je=`>= 0${le} and < 2${le} ** ${(Q+1)*8}${le}`:Je=`>= -(2${le} ** ${(Q+1)*8-1}${le}) and < 2 ** ${(Q+1)*8-1}${le}`:Je=`>= ${S}${le} and <= ${k}${le}`,new ct.ERR_OUT_OF_RANGE("value",Je,_)}he(E,A,Q)}function Re(_,S){if(typeof _!="number")throw new ct.ERR_INVALID_ARG_TYPE(S,"number",_)}function Ne(_,S,k){throw Math.floor(_)!==_?(Re(_,k),new ct.ERR_OUT_OF_RANGE(k||"offset","an integer",_)):S<0?new ct.ERR_BUFFER_OUT_OF_BOUNDS:new ct.ERR_OUT_OF_RANGE(k||"offset",`>= ${k?1:0} and <= ${S}`,_)}var G=/[^+/0-9A-Za-z-_]/g;function V(_){if(_=_.split("=")[0],_=_.trim().replace(G,""),_.length<2)return"";for(;_.length%4!==0;)_=_+"=";return _}function j(_,S){S=S||1/0;let k,E=_.length,A=null,Q=[];for(let le=0;le55295&&k<57344){if(!A){if(k>56319){(S-=3)>-1&&Q.push(239,191,189);continue}else if(le+1===E){(S-=3)>-1&&Q.push(239,191,189);continue}A=k;continue}if(k<56320){(S-=3)>-1&&Q.push(239,191,189),A=k;continue}k=(A-55296<<10|k-56320)+65536}else A&&(S-=3)>-1&&Q.push(239,191,189);if(A=null,k<128){if((S-=1)<0)break;Q.push(k)}else if(k<2048){if((S-=2)<0)break;Q.push(k>>6|192,k&63|128)}else if(k<65536){if((S-=3)<0)break;Q.push(k>>12|224,k>>6&63|128,k&63|128)}else if(k<1114112){if((S-=4)<0)break;Q.push(k>>18|240,k>>12&63|128,k>>6&63|128,k&63|128)}else throw Error("Invalid code point")}return Q}function H(_){let S=[];for(let k=0;k<_.length;++k)S.push(_.charCodeAt(k)&255);return S}function ge(_,S){let k,E,A,Q=[];for(let le=0;le<_.length&&!((S-=2)<0);++le)k=_.charCodeAt(le),E=k>>8,A=k%256,Q.push(A),Q.push(E);return Q}function fe(_){return t.toByteArray(V(_))}function W(_,S,k,E){let A;for(A=0;A=S.length||A>=_.length);++A)S[A+k]=_[A];return A}function ye(_,S){return _ instanceof S||_!=null&&_.constructor!=null&&_.constructor.name!=null&&_.constructor.name===S.name}function Oe(_){return _!==_}var Se=function(){let _="0123456789abcdef",S=Array(256);for(let k=0;k<16;++k){let E=k*16;for(let A=0;A<16;++A)S[E+A]=_[k]+_[A]}return S}();function Ce(_){return typeof BigInt>"u"?Bt:_}function Bt(){throw Error("BigInt not supported")}}),or=un((e,t)=>{var n=class extends Error{constructor(r){if(!Array.isArray(r))throw TypeError(`Expected input to be an Array, got ${typeof r}`);let i="";for(let s=0;s{t.exports={format(n,...r){return n.replace(/%([sdifj])/g,function(...[i,s]){let o=r.shift();return s==="f"?o.toFixed(6):s==="j"?JSON.stringify(o):s==="s"&&typeof o=="object"?`${o.constructor!==Object?o.constructor.name:""} {}`.trim():o.toString()})},inspect(n){switch(typeof n){case"string":if(n.includes("'"))if(n.includes('"')){if(!n.includes("`")&&!n.includes("${"))return`\`${n}\``}else return`"${n}"`;return`'${n}'`;case"number":return isNaN(n)?"NaN":Object.is(n,-0)?String(n):n;case"bigint":return`${String(n)}n`;case"boolean":case"undefined":return String(n);case"object":return"{}"}}}}),is=un((e,t)=>{var{format:n,inspect:r}=kae(),{AggregateError:i}=or(),s=globalThis.AggregateError||i,o=Symbol("kIsNodeError"),a=["string","function","number","object","Function","Object","boolean","bigint","symbol"],l=/^([A-Z][a-z0-9]*)+$/,c="__node_internal_",u={};function p(g,x){if(!g)throw new u.ERR_INTERNAL_ASSERTION(x)}function d(g){let x="",v=g.length,D=g[0]==="-"?1:0;for(;v>=D+4;v-=3)x=`_${g.slice(v-3,v)}${x}`;return`${g.slice(0,v)}${x}`}function f(g,x,v){if(typeof x=="function")return p(x.length<=v.length,`Code: ${g}; The provided arguments length (${v.length}) does not match the required ones (${x.length}).`),x(...v);let D=(x.match(/%[dfijoOs]/g)||[]).length;return p(D===v.length,`Code: ${g}; The provided arguments length (${v.length}) does not match the required ones (${D}).`),v.length===0?x:n(x,...v)}function m(g,x,v){v||(v=Error);class D extends v{constructor(...T){super(f(g,x,T))}toString(){return`${this.name} [${g}]: ${this.message}`}}Object.defineProperties(D.prototype,{name:{value:v.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${g}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),D.prototype.code=g,D.prototype[o]=!0,u[g]=D}function y(g){let x=c+g.name;return Object.defineProperty(g,"name",{value:x}),g}function h(g,x){if(g&&x&&g!==x){if(Array.isArray(x.errors))return x.errors.push(g),x;let v=new s([x,g],x.message);return v.code=x.code,v}return g||x}var b=class extends Error{constructor(g="The operation was aborted",x=void 0){if(x!==void 0&&typeof x!="object")throw new u.ERR_INVALID_ARG_TYPE("options","Object",x);super(g,x),this.code="ABORT_ERR",this.name="AbortError"}};m("ERR_ASSERTION","%s",Error),m("ERR_INVALID_ARG_TYPE",(g,x,v)=>{p(typeof g=="string","'name' must be a string"),Array.isArray(x)||(x=[x]);let D="The ";g.endsWith(" argument")?D+=`${g} `:D+=`"${g}" ${g.includes(".")?"property":"argument"} `,D+="must be ";let T=[],N=[],O=[];for(let X of x)p(typeof X=="string","All expected entries have to be of type string"),a.includes(X)?T.push(X.toLowerCase()):l.test(X)?N.push(X):(p(X!=="object",'The value "object" should be written as "Object"'),O.push(X));if(N.length>0){let X=T.indexOf("object");X!==-1&&(T.splice(T,X,1),N.push("Object"))}if(T.length>0){switch(T.length){case 1:D+=`of type ${T[0]}`;break;case 2:D+=`one of type ${T[0]} or ${T[1]}`;break;default:{let X=T.pop();D+=`one of type ${T.join(", ")}, or ${X}`}}(N.length>0||O.length>0)&&(D+=" or ")}if(N.length>0){switch(N.length){case 1:D+=`an instance of ${N[0]}`;break;case 2:D+=`an instance of ${N[0]} or ${N[1]}`;break;default:{let X=N.pop();D+=`an instance of ${N.join(", ")}, or ${X}`}}O.length>0&&(D+=" or ")}switch(O.length){case 0:break;case 1:O[0].toLowerCase()!==O[0]&&(D+="an "),D+=`${O[0]}`;break;case 2:D+=`one of ${O[0]} or ${O[1]}`;break;default:{let X=O.pop();D+=`one of ${O.join(", ")}, or ${X}`}}if(v==null)D+=`. Received ${v}`;else if(typeof v=="function"&&v.name)D+=`. Received function ${v.name}`;else if(typeof v=="object"){var C;if((C=v.constructor)!==null&&C!==void 0&&C.name)D+=`. Received an instance of ${v.constructor.name}`;else{let X=r(v,{depth:-1});D+=`. Received ${X}`}}else{let X=r(v,{colors:!1});X.length>25&&(X=`${X.slice(0,25)}...`),D+=`. Received type ${typeof v} (${X})`}return D},TypeError),m("ERR_INVALID_ARG_VALUE",(g,x,v="is invalid")=>{let D=r(x);return D.length>128&&(D=D.slice(0,128)+"..."),`The ${g.includes(".")?"property":"argument"} '${g}' ${v}. Received ${D}`},TypeError),m("ERR_INVALID_RETURN_VALUE",(g,x,v)=>{var D;let T=v!=null&&(D=v.constructor)!==null&&D!==void 0&&D.name?`instance of ${v.constructor.name}`:`type ${typeof v}`;return`Expected ${g} to be returned from the "${x}" function but got ${T}.`},TypeError),m("ERR_MISSING_ARGS",(...g)=>{p(g.length>0,"At least one arg needs to be specified");let x,v=g.length;switch(g=(Array.isArray(g)?g:[g]).map((D)=>`"${D}"`).join(" or "),v){case 1:x+=`The ${g[0]} argument`;break;case 2:x+=`The ${g[0]} and ${g[1]} arguments`;break;default:{let D=g.pop();x+=`The ${g.join(", ")}, and ${D} arguments`}break}return`${x} must be specified`},TypeError),m("ERR_OUT_OF_RANGE",(g,x,v)=>{p(x,'Missing "range" argument');let D;if(Number.isInteger(v)&&Math.abs(v)>4294967296)D=d(String(v));else if(typeof v=="bigint"){D=String(v);let T=BigInt(2)**BigInt(32);(v>T||v<-T)&&(D=d(D)),D+="n"}else D=r(v);return`The value of "${g}" is out of range. It must be ${x}. Received ${D}`},RangeError),m("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error),m("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error),m("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error),m("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error),m("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error),m("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),m("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error),m("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error),m("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error),m("ERR_STREAM_WRITE_AFTER_END","write after end",Error),m("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError),t.exports={AbortError:b,aggregateTwoErrors:y(h),hideStackFrames:y,codes:u}}),c_=un((e,t)=>{var{AbortController:n,AbortSignal:r}=typeof self<"u"?self:typeof window<"u"?window:void 0;t.exports=n,t.exports.AbortSignal=r,t.exports.default=n}),nE=un((e,t)=>{var n=typeof Reflect=="object"?Reflect:null,r=n&&typeof n.apply=="function"?n.apply:function(T,N,O){return Function.prototype.apply.call(T,N,O)},i;n&&typeof n.ownKeys=="function"?i=n.ownKeys:Object.getOwnPropertySymbols?i=function(T){return Object.getOwnPropertyNames(T).concat(Object.getOwnPropertySymbols(T))}:i=function(T){return Object.getOwnPropertyNames(T)};function s(T){console&&console.warn&&console.warn(T)}var o=Number.isNaN||function(T){return T!==T};function a(){a.init.call(this)}t.exports=a,t.exports.once=x,a.EventEmitter=a,a.prototype._events=void 0,a.prototype._eventsCount=0,a.prototype._maxListeners=void 0;var l=10;function c(T){if(typeof T!="function")throw TypeError('The "listener" argument must be of type Function. Received type '+typeof T)}Object.defineProperty(a,"defaultMaxListeners",{enumerable:!0,get:function(){return l},set:function(T){if(typeof T!="number"||T<0||o(T))throw RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+T+".");l=T}}),a.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},a.prototype.setMaxListeners=function(T){if(typeof T!="number"||T<0||o(T))throw RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+T+".");return this._maxListeners=T,this};function u(T){return T._maxListeners===void 0?a.defaultMaxListeners:T._maxListeners}a.prototype.getMaxListeners=function(){return u(this)},a.prototype.emit=function(T){for(var N=[],O=1;O0&&(te=N[0]),te instanceof Error)throw te;var L=Error("Unhandled error."+(te?" ("+te.message+")":""));throw L.context=te,L}var Y=X[T];if(Y===void 0)return!1;if(typeof Y=="function")r(Y,this,N);else for(var me=Y.length,I=h(Y,me),O=0;O0&&L.length>X&&!L.warned){L.warned=!0;var Y=Error("Possible EventEmitter memory leak detected. "+L.length+" "+String(N)+" listeners added. Use emitter.setMaxListeners() to increase limit");Y.name="MaxListenersExceededWarning",Y.emitter=T,Y.type=N,Y.count=L.length,s(Y)}return T}a.prototype.addListener=function(T,N){return p(this,T,N,!1)},a.prototype.on=a.prototype.addListener,a.prototype.prependListener=function(T,N){return p(this,T,N,!0)};function d(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function f(T,N,O){var C={fired:!1,wrapFn:void 0,target:T,type:N,listener:O},X=d.bind(C);return X.listener=O,C.wrapFn=X,X}a.prototype.once=function(T,N){return c(N),this.on(T,f(this,T,N)),this},a.prototype.prependOnceListener=function(T,N){return c(N),this.prependListener(T,f(this,T,N)),this},a.prototype.removeListener=function(T,N){var O,C,X,te,L;if(c(N),C=this._events,C===void 0)return this;if(O=C[T],O===void 0)return this;if(O===N||O.listener===N)--this._eventsCount===0?this._events=Object.create(null):(delete C[T],C.removeListener&&this.emit("removeListener",T,O.listener||N));else if(typeof O!="function"){for(X=-1,te=O.length-1;te>=0;te--)if(O[te]===N||O[te].listener===N){L=O[te].listener,X=te;break}if(X<0)return this;X===0?O.shift():b(O,X),O.length===1&&(C[T]=O[0]),C.removeListener!==void 0&&this.emit("removeListener",T,L||N)}return this},a.prototype.off=a.prototype.removeListener,a.prototype.removeAllListeners=function(T){var N,O,C;if(O=this._events,O===void 0)return this;if(O.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):O[T]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete O[T]),this;if(arguments.length===0){var X=Object.keys(O),te;for(C=0;C=0;C--)this.removeListener(T,N[C]);return this};function m(T,N,O){var C=T._events;if(C===void 0)return[];var X=C[N];return X===void 0?[]:typeof X=="function"?O?[X.listener||X]:[X]:O?g(X):h(X,X.length)}a.prototype.listeners=function(T){return m(this,T,!0)},a.prototype.rawListeners=function(T){return m(this,T,!1)},a.listenerCount=function(T,N){return typeof T.listenerCount=="function"?T.listenerCount(N):y.call(T,N)},a.prototype.listenerCount=y;function y(T){var N=this._events;if(N!==void 0){var O=N[T];if(typeof O=="function")return 1;if(O!==void 0)return O.length}return 0}a.prototype.eventNames=function(){return this._eventsCount>0?i(this._events):[]};function h(T,N){for(var O=Array(N),C=0;C{var n=Uc(),{format:r,inspect:i}=kae(),{codes:{ERR_INVALID_ARG_TYPE:s}}=is(),{kResistStopPropagation:o,AggregateError:a,SymbolDispose:l}=or(),c=globalThis.AbortSignal||c_().AbortSignal,u=globalThis.AbortController||c_().AbortController,p=Object.getPrototypeOf(async function(){}).constructor,d=globalThis.Blob||n.Blob,f=typeof d<"u"?function(h){return h instanceof d}:function(h){return!1},m=(h,b)=>{if(h!==void 0&&(h===null||typeof h!="object"||!("aborted"in h)))throw new s(b,"AbortSignal",h)},y=(h,b)=>{if(typeof h!="function")throw new s(b,"Function",h)};t.exports={AggregateError:a,kEmptyObject:Object.freeze({}),once(h){let b=!1;return function(...g){b||(b=!0,h.apply(this,g))}},createDeferredPromise:function(){let h,b;return{promise:new Promise((g,x)=>{h=g,b=x}),resolve:h,reject:b}},promisify(h){return new Promise((b,g)=>{h((x,...v)=>x?g(x):b(...v))})},debuglog(){return function(){}},format:r,inspect:i,types:{isAsyncFunction(h){return h instanceof p},isArrayBufferView(h){return ArrayBuffer.isView(h)}},isBlob:f,deprecate(h,b){return h},addAbortListener:nE().addAbortListener||function(h,b){if(h===void 0)throw new s("signal","AbortSignal",h);m(h,"signal"),y(b,"listener");let g;return h.aborted?queueMicrotask(()=>b()):(h.addEventListener("abort",b,{__proto__:null,once:!0,[o]:!0}),g=()=>{h.removeEventListener("abort",b)}),{__proto__:null,[l](){var x;(x=g)===null||x===void 0||x()}}},AbortSignalAny:c.any||function(h){if(h.length===1)return h[0];let b=new u,g=()=>b.abort();return h.forEach((x)=>{m(x,"signals"),x.addEventListener("abort",g,{once:!0})}),b.signal.addEventListener("abort",()=>{h.forEach((x)=>x.removeEventListener("abort",g))},{once:!0}),b.signal}},t.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")}),u_=un((e,t)=>{var{ArrayIsArray:n,ArrayPrototypeIncludes:r,ArrayPrototypeJoin:i,ArrayPrototypeMap:s,NumberIsInteger:o,NumberIsNaN:a,NumberMAX_SAFE_INTEGER:l,NumberMIN_SAFE_INTEGER:c,NumberParseInt:u,ObjectPrototypeHasOwnProperty:p,RegExpPrototypeExec:d,String:f,StringPrototypeToUpperCase:m,StringPrototypeTrim:y}=or(),{hideStackFrames:h,codes:{ERR_SOCKET_BAD_PORT:b,ERR_INVALID_ARG_TYPE:g,ERR_INVALID_ARG_VALUE:x,ERR_OUT_OF_RANGE:v,ERR_UNKNOWN_SIGNAL:D}}=is(),{normalizeEncoding:T}=Ls(),{isAsyncFunction:N,isArrayBufferView:O}=Ls().types,C={};function X(W){return W===(W|0)}function te(W){return W===W>>>0}var L=/^[0-7]+$/,Y="must be a 32-bit unsigned integer or an octal string";function me(W,ye,Oe){if(typeof W>"u"&&(W=Oe),typeof W=="string"){if(d(L,W)===null)throw new x(ye,W,Y);W=u(W,8)}return pe(W,ye),W}var I=h((W,ye,Oe=c,Se=l)=>{if(typeof W!="number")throw new g(ye,"number",W);if(!o(W))throw new v(ye,"an integer",W);if(WSe)throw new v(ye,`>= ${Oe} && <= ${Se}`,W)}),Z=h((W,ye,Oe=-2147483648,Se=2147483647)=>{if(typeof W!="number")throw new g(ye,"number",W);if(!o(W))throw new v(ye,"an integer",W);if(WSe)throw new v(ye,`>= ${Oe} && <= ${Se}`,W)}),pe=h((W,ye,Oe=!1)=>{if(typeof W!="number")throw new g(ye,"number",W);if(!o(W))throw new v(ye,"an integer",W);let Se=Oe?1:0,Ce=4294967295;if(WCe)throw new v(ye,`>= ${Se} && <= ${Ce}`,W)});function de(W,ye){if(typeof W!="string")throw new g(ye,"string",W)}function je(W,ye,Oe=void 0,Se){if(typeof W!="number")throw new g(ye,"number",W);if(Oe!=null&&WSe||(Oe!=null||Se!=null)&&a(W))throw new v(ye,`${Oe!=null?`>= ${Oe}`:""}${Oe!=null&&Se!=null?" && ":""}${Se!=null?`<= ${Se}`:""}`,W)}var be=h((W,ye,Oe)=>{if(!r(Oe,W)){let Se="must be one of: "+i(s(Oe,(Ce)=>typeof Ce=="string"?`'${Ce}'`:f(Ce)),", ");throw new x(ye,W,Se)}});function Ie(W,ye){if(typeof W!="boolean")throw new g(ye,"boolean",W)}function J(W,ye,Oe){return W==null||!p(W,ye)?Oe:W[ye]}var _e=h((W,ye,Oe=null)=>{let Se=J(Oe,"allowArray",!1),Ce=J(Oe,"allowFunction",!1);if(!J(Oe,"nullable",!1)&&W===null||!Se&&n(W)||typeof W!="object"&&(!Ce||typeof W!="function"))throw new g(ye,"Object",W)}),ue=h((W,ye)=>{if(W!=null&&typeof W!="object"&&typeof W!="function")throw new g(ye,"a dictionary",W)}),ce=h((W,ye,Oe=0)=>{if(!n(W))throw new g(ye,"Array",W);if(W.length{if(!O(W))throw new g(ye,["Buffer","TypedArray","DataView"],W)});function he(W,ye){let Oe=T(ye),Se=W.length;if(Oe==="hex"&&Se%2!==0)throw new x("encoding",ye,`is invalid for data of length ${Se}`)}function ke(W,ye="Port",Oe=!0){if(typeof W!="number"&&typeof W!="string"||typeof W=="string"&&y(W).length===0||+W!==+W>>>0||W>65535||W===0&&!Oe)throw new b(ye,W,Oe);return W|0}var Re=h((W,ye)=>{if(W!==void 0&&(W===null||typeof W!="object"||!("aborted"in W)))throw new g(ye,"AbortSignal",W)}),Ne=h((W,ye)=>{if(typeof W!="function")throw new g(ye,"Function",W)}),G=h((W,ye)=>{if(typeof W!="function"||N(W))throw new g(ye,"Function",W)}),V=h((W,ye)=>{if(W!==void 0)throw new g(ye,"undefined",W)});function j(W,ye,Oe){if(!r(Oe,W))throw new g(ye,`('${i(Oe,"|")}')`,W)}var H=/^(?:<[^>]*>)(?:\s*;\s*[^;"\s]+(?:=(")?[^;"\s]*\1)?)*$/;function ge(W,ye){if(typeof W>"u"||!d(H,W))throw new x(ye,W,'must be an array or string of format "; rel=preload; as=style"')}function fe(W){if(typeof W=="string")return ge(W,"hints"),W;if(n(W)){let ye=W.length,Oe="";if(ye===0)return Oe;for(let Se=0;Se; rel=preload; as=style"')}t.exports={isInt32:X,isUint32:te,parseFileMode:me,validateArray:ce,validateStringArray:Le,validateBooleanArray:Ke,validateAbortSignalArray:ct,validateBoolean:Ie,validateBuffer:se,validateDictionary:ue,validateEncoding:he,validateFunction:Ne,validateInt32:Z,validateInteger:I,validateNumber:je,validateObject:_e,validateOneOf:be,validatePlainFunction:G,validatePort:ke,validateSignalName:lt,validateString:de,validateUint32:pe,validateUndefined:V,validateUnion:j,validateAbortSignal:Re,validateLinkHeaderValue:fe}}),wf=un((e,t)=>{var n=t.exports={},r,i;function s(){throw Error("setTimeout has not been defined")}function o(){throw Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?r=setTimeout:r=s}catch(b){r=s}try{typeof clearTimeout=="function"?i=clearTimeout:i=o}catch(b){i=o}})();function a(b){if(r===setTimeout)return setTimeout(b,0);if((r===s||!r)&&setTimeout)return r=setTimeout,setTimeout(b,0);try{return r(b,0)}catch(g){try{return r.call(null,b,0)}catch(x){return r.call(this,b,0)}}}function l(b){if(i===clearTimeout)return clearTimeout(b);if((i===o||!i)&&clearTimeout)return i=clearTimeout,clearTimeout(b);try{return i(b)}catch(g){try{return i.call(null,b)}catch(x){return i.call(this,b)}}}var c=[],u=!1,p,d=-1;function f(){!u||!p||(u=!1,p.length?c=p.concat(c):d=-1,c.length&&m())}function m(){if(!u){var b=a(f);u=!0;for(var g=c.length;g;){for(p=c,c=[];++d1)for(var x=1;x{var{SymbolAsyncIterator:n,SymbolIterator:r,SymbolFor:i}=or(),s=i("nodejs.stream.destroyed"),o=i("nodejs.stream.errored"),a=i("nodejs.stream.readable"),l=i("nodejs.stream.writable"),c=i("nodejs.stream.disturbed"),u=i("nodejs.webstream.isClosedPromise"),p=i("nodejs.webstream.controllerErrorFunction");function d(J,_e=!1){var ue;return!!(J&&typeof J.pipe=="function"&&typeof J.on=="function"&&(!_e||typeof J.pause=="function"&&typeof J.resume=="function")&&(!J._writableState||((ue=J._readableState)===null||ue===void 0?void 0:ue.readable)!==!1)&&(!J._writableState||J._readableState))}function f(J){var _e;return!!(J&&typeof J.write=="function"&&typeof J.on=="function"&&(!J._readableState||((_e=J._writableState)===null||_e===void 0?void 0:_e.writable)!==!1))}function m(J){return!!(J&&typeof J.pipe=="function"&&J._readableState&&typeof J.on=="function"&&typeof J.write=="function")}function y(J){return J&&(J._readableState||J._writableState||typeof J.write=="function"&&typeof J.on=="function"||typeof J.pipe=="function"&&typeof J.on=="function")}function h(J){return!!(J&&!y(J)&&typeof J.pipeThrough=="function"&&typeof J.getReader=="function"&&typeof J.cancel=="function")}function b(J){return!!(J&&!y(J)&&typeof J.getWriter=="function"&&typeof J.abort=="function")}function g(J){return!!(J&&!y(J)&&typeof J.readable=="object"&&typeof J.writable=="object")}function x(J){return h(J)||b(J)||g(J)}function v(J,_e){return J==null?!1:_e===!0?typeof J[n]=="function":_e===!1?typeof J[r]=="function":typeof J[n]=="function"||typeof J[r]=="function"}function D(J){if(!y(J))return null;let{_writableState:_e,_readableState:ue}=J,ce=_e||ue;return!!(J.destroyed||J[s]||ce!=null&&ce.destroyed)}function T(J){if(!f(J))return null;if(J.writableEnded===!0)return!0;let _e=J._writableState;return _e!=null&&_e.errored?!1:typeof(_e==null?void 0:_e.ended)!="boolean"?null:_e.ended}function N(J,_e){if(!f(J))return null;if(J.writableFinished===!0)return!0;let ue=J._writableState;return ue!=null&&ue.errored?!1:typeof(ue==null?void 0:ue.finished)!="boolean"?null:!!(ue.finished||_e===!1&&ue.ended===!0&&ue.length===0)}function O(J){if(!d(J))return null;if(J.readableEnded===!0)return!0;let _e=J._readableState;return!_e||_e.errored?!1:typeof(_e==null?void 0:_e.ended)!="boolean"?null:_e.ended}function C(J,_e){if(!d(J))return null;let ue=J._readableState;return ue!=null&&ue.errored?!1:typeof(ue==null?void 0:ue.endEmitted)!="boolean"?null:!!(ue.endEmitted||_e===!1&&ue.ended===!0&&ue.length===0)}function X(J){return J&&J[a]!=null?J[a]:typeof(J==null?void 0:J.readable)!="boolean"?null:D(J)?!1:d(J)&&J.readable&&!C(J)}function te(J){return J&&J[l]!=null?J[l]:typeof(J==null?void 0:J.writable)!="boolean"?null:D(J)?!1:f(J)&&J.writable&&!T(J)}function L(J,_e){return y(J)?D(J)?!0:!((_e==null?void 0:_e.readable)!==!1&&X(J)||(_e==null?void 0:_e.writable)!==!1&&te(J)):null}function Y(J){var _e,ue;return y(J)?J.writableErrored?J.writableErrored:(_e=(ue=J._writableState)===null||ue===void 0?void 0:ue.errored)!==null&&_e!==void 0?_e:null:null}function me(J){var _e,ue;return y(J)?J.readableErrored?J.readableErrored:(_e=(ue=J._readableState)===null||ue===void 0?void 0:ue.errored)!==null&&_e!==void 0?_e:null:null}function I(J){if(!y(J))return null;if(typeof J.closed=="boolean")return J.closed;let{_writableState:_e,_readableState:ue}=J;return typeof(_e==null?void 0:_e.closed)=="boolean"||typeof(ue==null?void 0:ue.closed)=="boolean"?(_e==null?void 0:_e.closed)||(ue==null?void 0:ue.closed):typeof J._closed=="boolean"&&Z(J)?J._closed:null}function Z(J){return typeof J._closed=="boolean"&&typeof J._defaultKeepAlive=="boolean"&&typeof J._removedConnection=="boolean"&&typeof J._removedContLen=="boolean"}function pe(J){return typeof J._sent100=="boolean"&&Z(J)}function de(J){var _e;return typeof J._consuming=="boolean"&&typeof J._dumped=="boolean"&&((_e=J.req)===null||_e===void 0?void 0:_e.upgradeOrConnect)===void 0}function je(J){if(!y(J))return null;let{_writableState:_e,_readableState:ue}=J,ce=_e||ue;return!ce&&pe(J)||!!(ce&&ce.autoDestroy&&ce.emitClose&&ce.closed===!1)}function be(J){var _e;return!!(J&&((_e=J[c])!==null&&_e!==void 0?_e:J.readableDidRead||J.readableAborted))}function Ie(J){var _e,ue,ce,Le,Ke,ct,lt,se,he,ke;return!!(J&&((_e=(ue=(ce=(Le=(Ke=(ct=J[o])!==null&&ct!==void 0?ct:J.readableErrored)!==null&&Ke!==void 0?Ke:J.writableErrored)!==null&&Le!==void 0?Le:(lt=J._readableState)===null||lt===void 0?void 0:lt.errorEmitted)!==null&&ce!==void 0?ce:(se=J._writableState)===null||se===void 0?void 0:se.errorEmitted)!==null&&ue!==void 0?ue:(he=J._readableState)===null||he===void 0?void 0:he.errored)!==null&&_e!==void 0?_e:!((ke=J._writableState)===null||ke===void 0)&&ke.errored))}t.exports={isDestroyed:D,kIsDestroyed:s,isDisturbed:be,kIsDisturbed:c,isErrored:Ie,kIsErrored:o,isReadable:X,kIsReadable:a,kIsClosedPromise:u,kControllerErrorFunction:p,kIsWritable:l,isClosed:I,isDuplexNodeStream:m,isFinished:L,isIterable:v,isReadableNodeStream:d,isReadableStream:h,isReadableEnded:O,isReadableFinished:C,isReadableErrored:me,isNodeStream:y,isWebStream:x,isWritable:te,isWritableNodeStream:f,isWritableStream:b,isWritableEnded:T,isWritableFinished:N,isWritableErrored:Y,isServerRequest:de,isServerResponse:pe,willEmitClose:je,isTransformStream:g}}),wp=un((e,t)=>{var n=wf(),{AbortError:r,codes:i}=is(),{ERR_INVALID_ARG_TYPE:s,ERR_STREAM_PREMATURE_CLOSE:o}=i,{kEmptyObject:a,once:l}=Ls(),{validateAbortSignal:c,validateFunction:u,validateObject:p,validateBoolean:d}=u_(),{Promise:f,PromisePrototypeThen:m,SymbolDispose:y}=or(),{isClosed:h,isReadable:b,isReadableNodeStream:g,isReadableStream:x,isReadableFinished:v,isReadableErrored:D,isWritable:T,isWritableNodeStream:N,isWritableStream:O,isWritableFinished:C,isWritableErrored:X,isNodeStream:te,willEmitClose:L,kIsClosedPromise:Y}=Bc(),me;function I(be){return be.setHeader&&typeof be.abort=="function"}var Z=()=>{};function pe(be,Ie,J){var _e,ue;if(arguments.length===2?(J=Ie,Ie=a):Ie==null?Ie=a:p(Ie,"options"),u(J,"callback"),c(Ie.signal,"options.signal"),J=l(J),x(be)||O(be))return de(be,Ie,J);if(!te(be))throw new s("stream",["ReadableStream","WritableStream","Stream"],be);let ce=(_e=Ie.readable)!==null&&_e!==void 0?_e:g(be),Le=(ue=Ie.writable)!==null&&ue!==void 0?ue:N(be),{_writableState:Ke,_readableState:ct}=be,lt=()=>{be.writable||ke()},se=L(be)&&g(be)===ce&&N(be)===Le,he=C(be,!1),ke=()=>{he=!0,be.destroyed&&(se=!1),!(se&&(!be.readable||ce))&&(!ce||Re)&&J.call(be)},Re=v(be,!1),Ne=()=>{Re=!0,be.destroyed&&(se=!1),!(se&&(!be.writable||Le))&&(!Le||he)&&J.call(be)},G=(W)=>{J.call(be,W)},V=h(be),j=()=>{V=!0;let W=X(be)||D(be);if(W&&typeof W!="boolean")return J.call(be,W);if(ce&&!Re&&g(be,!0)&&!v(be,!1))return J.call(be,new o);if(Le&&!he&&!C(be,!1))return J.call(be,new o);J.call(be)},H=()=>{V=!0;let W=X(be)||D(be);if(W&&typeof W!="boolean")return J.call(be,W);J.call(be)},ge=()=>{be.req.on("finish",ke)};I(be)?(be.on("complete",ke),se||be.on("abort",j),be.req?ge():be.on("request",ge)):Le&&!Ke&&(be.on("end",lt),be.on("close",lt)),!se&&typeof be.aborted=="boolean"&&be.on("aborted",j),be.on("end",Ne),be.on("finish",ke),Ie.error!==!1&&be.on("error",G),be.on("close",j),V?n.nextTick(j):Ke!=null&&Ke.errorEmitted||ct!=null&&ct.errorEmitted?se||n.nextTick(H):(!ce&&(!se||b(be))&&(he||T(be)===!1)||!Le&&(!se||T(be))&&(Re||b(be)===!1)||ct&&be.req&&be.aborted)&&n.nextTick(H);let fe=()=>{J=Z,be.removeListener("aborted",j),be.removeListener("complete",ke),be.removeListener("abort",j),be.removeListener("request",ge),be.req&&be.req.removeListener("finish",ke),be.removeListener("end",lt),be.removeListener("close",lt),be.removeListener("finish",ke),be.removeListener("end",Ne),be.removeListener("error",G),be.removeListener("close",j)};if(Ie.signal&&!V){let W=()=>{let ye=J;fe(),ye.call(be,new r(void 0,{cause:Ie.signal.reason}))};if(Ie.signal.aborted)n.nextTick(W);else{me=me||Ls().addAbortListener;let ye=me(Ie.signal,W),Oe=J;J=l((...Se)=>{ye[y](),Oe.apply(be,Se)})}}return fe}function de(be,Ie,J){let _e=!1,ue=Z;if(Ie.signal)if(ue=()=>{_e=!0,J.call(be,new r(void 0,{cause:Ie.signal.reason}))},Ie.signal.aborted)n.nextTick(ue);else{me=me||Ls().addAbortListener;let Le=me(Ie.signal,ue),Ke=J;J=l((...ct)=>{Le[y](),Ke.apply(be,ct)})}let ce=(...Le)=>{_e||n.nextTick(()=>J.apply(be,Le))};return m(be[Y].promise,ce,ce),Z}function je(be,Ie){var J;let _e=!1;return Ie===null&&(Ie=a),(J=Ie)!==null&&J!==void 0&&J.cleanup&&(d(Ie.cleanup,"cleanup"),_e=Ie.cleanup),new f((ue,ce)=>{let Le=pe(be,Ie,(Ke)=>{_e&&Le(),Ke?ce(Ke):ue()})})}t.exports=pe,t.exports.finished=je}),eh=un((e,t)=>{var n=wf(),{aggregateTwoErrors:r,codes:{ERR_MULTIPLE_CALLBACK:i},AbortError:s}=is(),{Symbol:o}=or(),{kIsDestroyed:a,isDestroyed:l,isFinished:c,isServerRequest:u}=Bc(),p=o("kDestroy"),d=o("kConstruct");function f(L,Y,me){L&&(L.stack,Y&&!Y.errored&&(Y.errored=L),me&&!me.errored&&(me.errored=L))}function m(L,Y){let me=this._readableState,I=this._writableState,Z=I||me;return I!=null&&I.destroyed||me!=null&&me.destroyed?(typeof Y=="function"&&Y(),this):(f(L,I,me),I&&(I.destroyed=!0),me&&(me.destroyed=!0),Z.constructed?y(this,L,Y):this.once(p,function(pe){y(this,r(pe,L),Y)}),this)}function y(L,Y,me){let I=!1;function Z(pe){if(I)return;I=!0;let{_readableState:de,_writableState:je}=L;f(pe,je,de),je&&(je.closed=!0),de&&(de.closed=!0),typeof me=="function"&&me(pe),pe?n.nextTick(h,L,pe):n.nextTick(b,L)}try{L._destroy(Y||null,Z)}catch(pe){Z(pe)}}function h(L,Y){g(L,Y),b(L)}function b(L){let{_readableState:Y,_writableState:me}=L;me&&(me.closeEmitted=!0),Y&&(Y.closeEmitted=!0),(me!=null&&me.emitClose||Y!=null&&Y.emitClose)&&L.emit("close")}function g(L,Y){let{_readableState:me,_writableState:I}=L;I!=null&&I.errorEmitted||me!=null&&me.errorEmitted||(I&&(I.errorEmitted=!0),me&&(me.errorEmitted=!0),L.emit("error",Y))}function x(){let L=this._readableState,Y=this._writableState;L&&(L.constructed=!0,L.closed=!1,L.closeEmitted=!1,L.destroyed=!1,L.errored=null,L.errorEmitted=!1,L.reading=!1,L.ended=L.readable===!1,L.endEmitted=L.readable===!1),Y&&(Y.constructed=!0,Y.destroyed=!1,Y.closed=!1,Y.closeEmitted=!1,Y.errored=null,Y.errorEmitted=!1,Y.finalCalled=!1,Y.prefinished=!1,Y.ended=Y.writable===!1,Y.ending=Y.writable===!1,Y.finished=Y.writable===!1)}function v(L,Y,me){let{_readableState:I,_writableState:Z}=L;if(Z!=null&&Z.destroyed||I!=null&&I.destroyed)return this;I!=null&&I.autoDestroy||Z!=null&&Z.autoDestroy?L.destroy(Y):Y&&(Y.stack,Z&&!Z.errored&&(Z.errored=Y),I&&!I.errored&&(I.errored=Y),me?n.nextTick(g,L,Y):g(L,Y))}function D(L,Y){if(typeof L._construct!="function")return;let{_readableState:me,_writableState:I}=L;me&&(me.constructed=!1),I&&(I.constructed=!1),L.once(d,Y),!(L.listenerCount(d)>1)&&n.nextTick(T,L)}function T(L){let Y=!1;function me(I){if(Y){v(L,I!=null?I:new i);return}Y=!0;let{_readableState:Z,_writableState:pe}=L,de=pe||Z;Z&&(Z.constructed=!0),pe&&(pe.constructed=!0),de.destroyed?L.emit(p,I):I?v(L,I,!0):n.nextTick(N,L)}try{L._construct((I)=>{n.nextTick(me,I)})}catch(I){n.nextTick(me,I)}}function N(L){L.emit(d)}function O(L){return(L==null?void 0:L.setHeader)&&typeof L.abort=="function"}function C(L){L.emit("close")}function X(L,Y){L.emit("error",Y),n.nextTick(C,L)}function te(L,Y){!L||l(L)||(!Y&&!c(L)&&(Y=new s),u(L)?(L.socket=null,L.destroy(Y)):O(L)?L.abort():O(L.req)?L.req.abort():typeof L.destroy=="function"?L.destroy(Y):typeof L.close=="function"?L.close():Y?n.nextTick(X,L,Y):n.nextTick(C,L),L.destroyed||(L[a]=!0))}t.exports={construct:D,destroyer:te,destroy:m,undestroy:x,errorOrDestroy:v}}),cC=un((e,t)=>{var{ArrayIsArray:n,ObjectSetPrototypeOf:r}=or(),{EventEmitter:i}=nE();function s(a){i.call(this,a)}r(s.prototype,i.prototype),r(s,i),s.prototype.pipe=function(a,l){let c=this;function u(b){a.writable&&a.write(b)===!1&&c.pause&&c.pause()}c.on("data",u);function p(){c.readable&&c.resume&&c.resume()}a.on("drain",p),!a._isStdio&&(!l||l.end!==!1)&&(c.on("end",f),c.on("close",m));let d=!1;function f(){d||(d=!0,a.end())}function m(){d||(d=!0,typeof a.destroy=="function"&&a.destroy())}function y(b){h(),i.listenerCount(this,"error")===0&&this.emit("error",b)}o(c,"error",y),o(a,"error",y);function h(){c.removeListener("data",u),a.removeListener("drain",p),c.removeListener("end",f),c.removeListener("close",m),c.removeListener("error",y),a.removeListener("error",y),c.removeListener("end",h),c.removeListener("close",h),a.removeListener("close",h)}return c.on("end",h),c.on("close",h),a.on("close",h),a.emit("pipe",c),a};function o(a,l,c){if(typeof a.prependListener=="function")return a.prependListener(l,c);!a._events||!a._events[l]?a.on(l,c):n(a._events[l])?a._events[l].unshift(c):a._events[l]=[c,a._events[l]]}t.exports={Stream:s,prependListener:o}}),rE=un((e,t)=>{var{SymbolDispose:n}=or(),{AbortError:r,codes:i}=is(),{isNodeStream:s,isWebStream:o,kControllerErrorFunction:a}=Bc(),l=wp(),{ERR_INVALID_ARG_TYPE:c}=i,u,p=(d,f)=>{if(typeof d!="object"||!("aborted"in d))throw new c(f,"AbortSignal",d)};t.exports.addAbortSignal=function(d,f){if(p(d,"signal"),!s(f)&&!o(f))throw new c("stream",["ReadableStream","WritableStream","Stream"],f);return t.exports.addAbortSignalNoValidate(d,f)},t.exports.addAbortSignalNoValidate=function(d,f){if(typeof d!="object"||!("aborted"in d))return f;let m=s(f)?()=>{f.destroy(new r(void 0,{cause:d.reason}))}:()=>{f[a](new r(void 0,{cause:d.reason}))};if(d.aborted)m();else{u=u||Ls().addAbortListener;let y=u(d,m);l(f,y[n])}return f}}),aVe=un((e,t)=>{var{StringPrototypeSlice:n,SymbolIterator:r,TypedArrayPrototypeSet:i,Uint8Array:s}=or(),{Buffer:o}=Uc(),{inspect:a}=Ls();t.exports=class{constructor(){this.head=null,this.tail=null,this.length=0}push(l){let c={data:l,next:null};this.length>0?this.tail.next=c:this.head=c,this.tail=c,++this.length}unshift(l){let c={data:l,next:this.head};this.length===0&&(this.tail=c),this.head=c,++this.length}shift(){if(this.length===0)return;let l=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,l}clear(){this.head=this.tail=null,this.length=0}join(l){if(this.length===0)return"";let c=this.head,u=""+c.data;for(;(c=c.next)!==null;)u+=l+c.data;return u}concat(l){if(this.length===0)return o.alloc(0);let c=o.allocUnsafe(l>>>0),u=this.head,p=0;for(;u;)i(c,u.data,p),p+=u.data.length,u=u.next;return c}consume(l,c){let u=this.head.data;if(ld.length)c+=d,l-=d.length;else{l===d.length?(c+=d,++p,u.next?this.head=u.next:this.head=this.tail=null):(c+=n(d,0,l),this.head=u,u.data=n(d,l));break}++p}while((u=u.next)!==null);return this.length-=p,c}_getBuffer(l){let c=o.allocUnsafe(l),u=l,p=this.head,d=0;do{let f=p.data;if(l>f.length)i(c,f,u-l),l-=f.length;else{l===f.length?(i(c,f,u-l),++d,p.next?this.head=p.next:this.head=this.tail=null):(i(c,new s(f.buffer,f.byteOffset,l),u-l),this.head=p,p.data=f.slice(l));break}++d}while((p=p.next)!==null);return this.length-=d,c}[Symbol.for("nodejs.util.inspect.custom")](l,c){return a(this,eE(Ms({},c),{depth:0,customInspect:!1}))}}}),iE=un((e,t)=>{var{MathFloor:n,NumberIsInteger:r}=or(),{validateInteger:i}=u_(),{ERR_INVALID_ARG_VALUE:s}=is().codes,o=16384,a=16;function l(d,f,m){return d.highWaterMark!=null?d.highWaterMark:f?d[m]:null}function c(d){return d?a:o}function u(d,f){i(f,"value",0),d?a=f:o=f}function p(d,f,m,y){let h=l(f,y,m);if(h!=null){if(!r(h)||h<0){let b=y?`options.${m}`:"options.highWaterMark";throw new s(b,h)}return n(h)}return c(d.objectMode)}t.exports={getHighWaterMark:p,getDefaultHighWaterMark:c,setDefaultHighWaterMark:u}}),lVe=un((e,t)=>{var n=Uc(),r=n.Buffer;function i(o,a){for(var l in o)a[l]=o[l]}r.from&&r.alloc&&r.allocUnsafe&&r.allocUnsafeSlow?t.exports=n:(i(n,e),e.Buffer=s);function s(o,a,l){return r(o,a,l)}s.prototype=Object.create(r.prototype),i(r,s),s.from=function(o,a,l){if(typeof o=="number")throw TypeError("Argument must not be a number");return r(o,a,l)},s.alloc=function(o,a,l){if(typeof o!="number")throw TypeError("Argument must be a number");var c=r(o);return a!==void 0?typeof l=="string"?c.fill(a,l):c.fill(a):c.fill(0),c},s.allocUnsafe=function(o){if(typeof o!="number")throw TypeError("Argument must be a number");return r(o)},s.allocUnsafeSlow=function(o){if(typeof o!="number")throw TypeError("Argument must be a number");return n.SlowBuffer(o)}}),cVe=un((e)=>{var t=lVe().Buffer,n=t.isEncoding||function(g){switch(g=""+g,g&&g.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function r(g){if(!g)return"utf8";for(var x;;)switch(g){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return g;default:if(x)return;g=(""+g).toLowerCase(),x=!0}}function i(g){var x=r(g);if(typeof x!="string"&&(t.isEncoding===n||!n(g)))throw Error("Unknown encoding: "+g);return x||g}e.StringDecoder=s;function s(g){this.encoding=i(g);var x;switch(this.encoding){case"utf16le":this.text=d,this.end=f,x=4;break;case"utf8":this.fillLast=c,x=4;break;case"base64":this.text=m,this.end=y,x=3;break;default:this.write=h,this.end=b;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=t.allocUnsafe(x)}s.prototype.write=function(g){if(g.length===0)return"";var x,v;if(this.lastNeed){if(x=this.fillLast(g),x===void 0)return"";v=this.lastNeed,this.lastNeed=0}else v=0;return v>5===6?2:g>>4===14?3:g>>3===30?4:g>>6===2?-1:-2}function a(g,x,v){var D=x.length-1;if(D=0?(T>0&&(g.lastNeed=T-1),T):--D=0?(T>0&&(g.lastNeed=T-2),T):--D=0?(T>0&&(T===2?T=0:g.lastNeed=T-3),T):0))}function l(g,x,v){if((x[0]&192)!==128)return g.lastNeed=0,"�";if(g.lastNeed>1&&x.length>1){if((x[1]&192)!==128)return g.lastNeed=1,"�";if(g.lastNeed>2&&x.length>2&&(x[2]&192)!==128)return g.lastNeed=2,"�"}}function c(g){var x=this.lastTotal-this.lastNeed,v=l(this,g,x);if(v!==void 0)return v;if(this.lastNeed<=g.length)return g.copy(this.lastChar,x,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);g.copy(this.lastChar,x,0,g.length),this.lastNeed-=g.length}function u(g,x){var v=a(this,g,x);if(!this.lastNeed)return g.toString("utf8",x);this.lastTotal=v;var D=g.length-(v-this.lastNeed);return g.copy(this.lastChar,0,D),g.toString("utf8",x,D)}function p(g){var x=g&&g.length?this.write(g):"";return this.lastNeed?x+"�":x}function d(g,x){if((g.length-x)%2===0){var v=g.toString("utf16le",x);if(v){var D=v.charCodeAt(v.length-1);if(D>=55296&&D<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=g[g.length-2],this.lastChar[1]=g[g.length-1],v.slice(0,-1)}return v}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=g[g.length-1],g.toString("utf16le",x,g.length-1)}function f(g){var x=g&&g.length?this.write(g):"";if(this.lastNeed){var v=this.lastTotal-this.lastNeed;return x+this.lastChar.toString("utf16le",0,v)}return x}function m(g,x){var v=(g.length-x)%3;return v===0?g.toString("base64",x):(this.lastNeed=3-v,this.lastTotal=3,v===1?this.lastChar[0]=g[g.length-1]:(this.lastChar[0]=g[g.length-2],this.lastChar[1]=g[g.length-1]),g.toString("base64",x,g.length-v))}function y(g){var x=g&&g.length?this.write(g):"";return this.lastNeed?x+this.lastChar.toString("base64",0,3-this.lastNeed):x}function h(g){return g.toString(this.encoding)}function b(g){return g&&g.length?this.write(g):""}}),Nae=un((e,t)=>{var n=wf(),{PromisePrototypeThen:r,SymbolAsyncIterator:i,SymbolIterator:s}=or(),{Buffer:o}=Uc(),{ERR_INVALID_ARG_TYPE:a,ERR_STREAM_NULL_VALUES:l}=is().codes;function c(u,p,d){let f;if(typeof p=="string"||p instanceof o)return new u(eE(Ms({objectMode:!0},d),{read(){this.push(p),this.push(null)}}));let m;if(p&&p[i])m=!0,f=p[i]();else if(p&&p[s])m=!1,f=p[s]();else throw new a("iterable",["Iterable"],p);let y=new u(Ms({objectMode:!0,highWaterMark:1},d)),h=!1;y._read=function(){h||(h=!0,g())},y._destroy=function(x,v){r(b(x),()=>n.nextTick(v,x),(D)=>n.nextTick(v,D||x))};async function b(x){let v=x!=null,D=typeof f.throw=="function";if(v&&D){let{value:T,done:N}=await f.throw(x);if(await T,N)return}if(typeof f.return=="function"){let{value:T}=await f.return();await T}}async function g(){for(;;){try{let{value:x,done:v}=m?await f.next():f.next();if(v)y.push(null);else{let D=x&&typeof x.then=="function"?await x:x;if(D===null)throw h=!1,new l;if(y.push(D))continue;h=!1}}catch(x){y.destroy(x)}break}}return y}t.exports=c}),sE=un((e,t)=>{var n=wf(),{ArrayPrototypeIndexOf:r,NumberIsInteger:i,NumberIsNaN:s,NumberParseInt:o,ObjectDefineProperties:a,ObjectKeys:l,ObjectSetPrototypeOf:c,Promise:u,SafeSet:p,SymbolAsyncDispose:d,SymbolAsyncIterator:f,Symbol:m}=or();t.exports=Se,Se.ReadableState=Oe;var{EventEmitter:y}=nE(),{Stream:h,prependListener:b}=cC(),{Buffer:g}=Uc(),{addAbortSignal:x}=rE(),v=wp(),D=Ls().debuglog("stream",(R)=>{D=R}),T=aVe(),N=eh(),{getHighWaterMark:O,getDefaultHighWaterMark:C}=iE(),{aggregateTwoErrors:X,codes:{ERR_INVALID_ARG_TYPE:te,ERR_METHOD_NOT_IMPLEMENTED:L,ERR_OUT_OF_RANGE:Y,ERR_STREAM_PUSH_AFTER_EOF:me,ERR_STREAM_UNSHIFT_AFTER_END_EVENT:I},AbortError:Z}=is(),{validateObject:pe}=u_(),de=m("kPaused"),{StringDecoder:je}=cVe(),be=Nae();c(Se.prototype,h.prototype),c(Se,h);var Ie=()=>{},{errorOrDestroy:J}=N,_e=1,ue=2,ce=4,Le=8,Ke=16,ct=32,lt=64,se=128,he=256,ke=512,Re=1024,Ne=2048,G=4096,V=8192,j=16384,H=32768,ge=65536,fe=131072,W=262144;function ye(R){return{enumerable:!1,get(){return(this.state&R)!==0},set(K){K?this.state|=R:this.state&=~R}}}a(Oe.prototype,{objectMode:ye(_e),ended:ye(ue),endEmitted:ye(ce),reading:ye(Le),constructed:ye(Ke),sync:ye(ct),needReadable:ye(lt),emittedReadable:ye(se),readableListening:ye(he),resumeScheduled:ye(ke),errorEmitted:ye(Re),emitClose:ye(Ne),autoDestroy:ye(G),destroyed:ye(V),closed:ye(j),closeEmitted:ye(H),multiAwaitDrain:ye(ge),readingMore:ye(fe),dataEmitted:ye(W)});function Oe(R,K,Fe){typeof Fe!="boolean"&&(Fe=K instanceof qc()),this.state=Ne|G|Ke|ct,R&&R.objectMode&&(this.state|=_e),Fe&&R&&R.readableObjectMode&&(this.state|=_e),this.highWaterMark=R?O(this,R,"readableHighWaterMark",Fe):C(!1),this.buffer=new T,this.length=0,this.pipes=[],this.flowing=null,this[de]=null,R&&R.emitClose===!1&&(this.state&=~Ne),R&&R.autoDestroy===!1&&(this.state&=~G),this.errored=null,this.defaultEncoding=R&&R.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.decoder=null,this.encoding=null,R&&R.encoding&&(this.decoder=new je(R.encoding),this.encoding=R.encoding)}function Se(R){if(!(this instanceof Se))return new Se(R);let K=this instanceof qc();this._readableState=new Oe(R,this,K),R&&(typeof R.read=="function"&&(this._read=R.read),typeof R.destroy=="function"&&(this._destroy=R.destroy),typeof R.construct=="function"&&(this._construct=R.construct),R.signal&&!K&&x(R.signal,this)),h.call(this,R),N.construct(this,()=>{this._readableState.needReadable&&le(this,this._readableState)})}Se.prototype.destroy=N.destroy,Se.prototype._undestroy=N.undestroy,Se.prototype._destroy=function(R,K){K(R)},Se.prototype[y.captureRejectionSymbol]=function(R){this.destroy(R)},Se.prototype[d]=function(){let R;return this.destroyed||(R=this.readableEnded?null:new Z,this.destroy(R)),new u((K,Fe)=>v(this,(Ge)=>Ge&&Ge!==R?Fe(Ge):K(null)))},Se.prototype.push=function(R,K){return Ce(this,R,K,!1)},Se.prototype.unshift=function(R,K){return Ce(this,R,K,!0)};function Ce(R,K,Fe,Ge){D("readableAddChunk",K);let tt=R._readableState,Ir;if((tt.state&_e)===0&&(typeof K=="string"?(Fe=Fe||tt.defaultEncoding,tt.encoding!==Fe&&(Ge&&tt.encoding?K=g.from(K,Fe).toString(tt.encoding):(K=g.from(K,Fe),Fe=""))):K instanceof g?Fe="":h._isUint8Array(K)?(K=h._uint8ArrayToBuffer(K),Fe=""):K!=null&&(Ir=new te("chunk",["string","Buffer","Uint8Array"],K))),Ir)J(R,Ir);else if(K===null)tt.state&=~Le,E(R,tt);else if((tt.state&_e)!==0||K&&K.length>0)if(Ge)if((tt.state&ce)!==0)J(R,new I);else{if(tt.destroyed||tt.errored)return!1;Bt(R,tt,K,!0)}else if(tt.ended)J(R,new me);else{if(tt.destroyed||tt.errored)return!1;tt.state&=~Le,tt.decoder&&!Fe?(K=tt.decoder.write(K),tt.objectMode||K.length!==0?Bt(R,tt,K,!1):le(R,tt)):Bt(R,tt,K,!1)}else Ge||(tt.state&=~Le,le(R,tt));return!tt.ended&&(tt.length0?((K.state&ge)!==0?K.awaitDrainWriters.clear():K.awaitDrainWriters=null,K.dataEmitted=!0,R.emit("data",Fe)):(K.length+=K.objectMode?1:Fe.length,Ge?K.buffer.unshift(Fe):K.buffer.push(Fe),(K.state<)!==0&&A(R)),le(R,K)}Se.prototype.isPaused=function(){let R=this._readableState;return R[de]===!0||R.flowing===!1},Se.prototype.setEncoding=function(R){let K=new je(R);this._readableState.decoder=K,this._readableState.encoding=this._readableState.decoder.encoding;let Fe=this._readableState.buffer,Ge="";for(let tt of Fe)Ge+=K.write(tt);return Fe.clear(),Ge!==""&&Fe.push(Ge),this._readableState.length=Ge.length,this};var _=1073741824;function S(R){if(R>_)throw new Y("size","<= 1GiB",R);return R--,R|=R>>>1,R|=R>>>2,R|=R>>>4,R|=R>>>8,R|=R>>>16,R++,R}function k(R,K){return R<=0||K.length===0&&K.ended?0:(K.state&_e)!==0?1:s(R)?K.flowing&&K.length?K.buffer.first().length:K.length:R<=K.length?R:K.ended?K.length:0}Se.prototype.read=function(R){D("read",R),R===void 0?R=NaN:i(R)||(R=o(R,10));let K=this._readableState,Fe=R;if(R>K.highWaterMark&&(K.highWaterMark=S(R)),R!==0&&(K.state&=~se),R===0&&K.needReadable&&((K.highWaterMark!==0?K.length>=K.highWaterMark:K.length>0)||K.ended))return D("read: emitReadable",K.length,K.ended),K.length===0&&K.ended?Us(this):A(this),null;if(R=k(R,K),R===0&&K.ended)return K.length===0&&Us(this),null;let Ge=(K.state<)!==0;if(D("need readable",Ge),(K.length===0||K.length-R0?tt=qa(R,K):tt=null,tt===null?(K.needReadable=K.length<=K.highWaterMark,R=0):(K.length-=R,K.multiAwaitDrain?K.awaitDrainWriters.clear():K.awaitDrainWriters=null),K.length===0&&(K.ended||(K.needReadable=!0),Fe!==R&&K.ended&&Us(this)),tt!==null&&!K.errorEmitted&&!K.closeEmitted&&(K.dataEmitted=!0,this.emit("data",tt)),tt};function E(R,K){if(D("onEofChunk"),!K.ended){if(K.decoder){let Fe=K.decoder.end();Fe&&Fe.length&&(K.buffer.push(Fe),K.length+=K.objectMode?1:Fe.length)}K.ended=!0,K.sync?A(R):(K.needReadable=!1,K.emittedReadable=!0,Q(R))}}function A(R){let K=R._readableState;D("emitReadable",K.needReadable,K.emittedReadable),K.needReadable=!1,K.emittedReadable||(D("emitReadable",K.flowing),K.emittedReadable=!0,n.nextTick(Q,R))}function Q(R){let K=R._readableState;D("emitReadable_",K.destroyed,K.length,K.ended),!K.destroyed&&!K.errored&&(K.length||K.ended)&&(R.emit("readable"),K.emittedReadable=!1),K.needReadable=!K.flowing&&!K.ended&&K.length<=K.highWaterMark,Rn(R)}function le(R,K){!K.readingMore&&K.constructed&&(K.readingMore=!0,n.nextTick(Je,R,K))}function Je(R,K){for(;!K.reading&&!K.ended&&(K.length1&&Ge.pipes.includes(R)&&(D("false write response, pause",Ge.awaitDrainWriters.size),Ge.awaitDrainWriters.add(R)),Fe.pause()),wn||(wn=St(Fe,R),R.on("drain",wn))}Fe.on("data",__);function __(Al){D("ondata");let po=R.write(Al);D("dest.write",po),po===!1&&v_()}function uh(Al){if(D("onerror",Al),Ep(),R.removeListener("error",uh),R.listenerCount("error")===0){let po=R._writableState||R._readableState;po&&!po.errorEmitted?J(R,Al):R.emit("error",Al)}}b(R,"error",uh);function Hc(){R.removeListener("finish",ph),Ep()}R.once("close",Hc);function ph(){D("onfinish"),R.removeListener("close",Hc),Ep()}R.once("finish",ph);function Ep(){D("unpipe"),Fe.unpipe(R)}return R.emit("pipe",Fe),R.writableNeedDrain===!0?v_():Ge.flowing||(D("pipe resume"),Fe.resume()),R};function St(R,K){return function(){let Fe=R._readableState;Fe.awaitDrainWriters===K?(D("pipeOnDrain",1),Fe.awaitDrainWriters=null):Fe.multiAwaitDrain&&(D("pipeOnDrain",Fe.awaitDrainWriters.size),Fe.awaitDrainWriters.delete(K)),(!Fe.awaitDrainWriters||Fe.awaitDrainWriters.size===0)&&R.listenerCount("data")&&R.resume()}}Se.prototype.unpipe=function(R){let K=this._readableState,Fe={hasUnpiped:!1};if(K.pipes.length===0)return this;if(!R){let tt=K.pipes;K.pipes=[],this.pause();for(let Ir=0;Ir0,Ge.flowing!==!1&&this.resume()):R==="readable"&&!Ge.endEmitted&&!Ge.readableListening&&(Ge.readableListening=Ge.needReadable=!0,Ge.flowing=!1,Ge.emittedReadable=!1,D("on readable",Ge.length,Ge.reading),Ge.length?A(this):Ge.reading||n.nextTick(xt,this)),Fe},Se.prototype.addListener=Se.prototype.on,Se.prototype.removeListener=function(R,K){let Fe=h.prototype.removeListener.call(this,R,K);return R==="readable"&&n.nextTick(ut,this),Fe},Se.prototype.off=Se.prototype.removeListener,Se.prototype.removeAllListeners=function(R){let K=h.prototype.removeAllListeners.apply(this,arguments);return(R==="readable"||R===void 0)&&n.nextTick(ut,this),K};function ut(R){let K=R._readableState;K.readableListening=R.listenerCount("readable")>0,K.resumeScheduled&&K[de]===!1?K.flowing=!0:R.listenerCount("data")>0?R.resume():K.readableListening||(K.flowing=null)}function xt(R){D("readable nexttick read 0"),R.read(0)}Se.prototype.resume=function(){let R=this._readableState;return R.flowing||(D("resume"),R.flowing=!R.readableListening,At(this,R)),R[de]=!1,this};function At(R,K){K.resumeScheduled||(K.resumeScheduled=!0,n.nextTick(Ln,R,K))}function Ln(R,K){D("resume",K.reading),K.reading||R.read(0),K.resumeScheduled=!1,R.emit("resume"),Rn(R),K.flowing&&!K.reading&&R.read(0)}Se.prototype.pause=function(){return D("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(D("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState[de]=!0,this};function Rn(R){let K=R._readableState;for(D("flow",K.flowing);K.flowing&&R.read()!==null;);}Se.prototype.wrap=function(R){let K=!1;R.on("data",(Ge)=>{!this.push(Ge)&&R.pause&&(K=!0,R.pause())}),R.on("end",()=>{this.push(null)}),R.on("error",(Ge)=>{J(this,Ge)}),R.on("close",()=>{this.destroy()}),R.on("destroy",()=>{this.destroy()}),this._read=()=>{K&&R.resume&&(K=!1,R.resume())};let Fe=l(R);for(let Ge=1;Ge{tt=Ui?X(tt,Ui):null,Fe(),Fe=Ie});try{for(;;){let Ui=R.destroyed?null:R.read();if(Ui!==null)yield Ui;else{if(tt)throw tt;if(tt===null)return;yield new Cs(new u(Ge))}}}catch(Ui){throw tt=X(tt,Ui),tt}finally{(tt||(K==null?void 0:K.destroyOnReturn)!==!1)&&(tt===void 0||R._readableState.autoDestroy)?N.destroyer(R,null):(R.off("readable",Ge),Ir())}})}a(Se.prototype,{readable:{__proto__:null,get(){let R=this._readableState;return!!R&&R.readable!==!1&&!R.destroyed&&!R.errorEmitted&&!R.endEmitted},set(R){this._readableState&&(this._readableState.readable=!!R)}},readableDidRead:{__proto__:null,enumerable:!1,get:function(){return this._readableState.dataEmitted}},readableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._readableState.readable!==!1&&(this._readableState.destroyed||this._readableState.errored)&&!this._readableState.endEmitted)}},readableHighWaterMark:{__proto__:null,enumerable:!1,get:function(){return this._readableState.highWaterMark}},readableBuffer:{__proto__:null,enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}},readableFlowing:{__proto__:null,enumerable:!1,get:function(){return this._readableState.flowing},set:function(R){this._readableState&&(this._readableState.flowing=R)}},readableLength:{__proto__:null,enumerable:!1,get(){return this._readableState.length}},readableObjectMode:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.objectMode:!1}},readableEncoding:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.encoding:null}},errored:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.errored:null}},closed:{__proto__:null,get(){return this._readableState?this._readableState.closed:!1}},destroyed:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.destroyed:!1},set(R){this._readableState&&(this._readableState.destroyed=R)}},readableEnded:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.endEmitted:!1}}}),a(Oe.prototype,{pipesCount:{__proto__:null,get(){return this.pipes.length}},paused:{__proto__:null,get(){return this[de]!==!1},set(R){this[de]=!!R}}}),Se._fromList=qa;function qa(R,K){if(K.length===0)return null;let Fe;return K.objectMode?Fe=K.buffer.shift():!R||R>=K.length?(K.decoder?Fe=K.buffer.join(""):K.buffer.length===1?Fe=K.buffer.first():Fe=K.buffer.concat(K.length),K.buffer.clear()):Fe=K.buffer.consume(R,K.decoder),Fe}function Us(R){let K=R._readableState;D("endReadable",K.endEmitted),K.endEmitted||(K.ended=!0,n.nextTick(as,K,R))}function as(R,K){if(D("endReadableNT",R.endEmitted,R.length),!R.errored&&!R.closeEmitted&&!R.endEmitted&&R.length===0){if(R.endEmitted=!0,K.emit("end"),K.writable&&K.allowHalfOpen===!1)n.nextTick(ah,K);else if(R.autoDestroy){let Fe=K._writableState;(!Fe||Fe.autoDestroy&&(Fe.finished||Fe.writable===!1))&&K.destroy()}}}function ah(R){R.writable&&!R.writableEnded&&!R.destroyed&&R.end()}Se.from=function(R,K){return be(Se,R,K)};var Gc;function lh(){return Gc===void 0&&(Gc={}),Gc}Se.fromWeb=function(R,K){return lh().newStreamReadableFromReadableStream(R,K)},Se.toWeb=function(R,K){return lh().newReadableStreamFromStreamReadable(R,K)},Se.wrap=function(R,K){var Fe,Ge;return new Se(eE(Ms({objectMode:(Fe=(Ge=R.readableObjectMode)!==null&&Ge!==void 0?Ge:R.objectMode)!==null&&Fe!==void 0?Fe:!0},K),{destroy(tt,Ir){N.destroyer(R,tt),Ir(tt)}})).wrap(R)}}),uC=un((e,t)=>{var n=wf(),{ArrayPrototypeSlice:r,Error:i,FunctionPrototypeSymbolHasInstance:s,ObjectDefineProperty:o,ObjectDefineProperties:a,ObjectSetPrototypeOf:l,StringPrototypeToLowerCase:c,Symbol:u,SymbolHasInstance:p}=or();t.exports=pe,pe.WritableState=I;var{EventEmitter:d}=nE(),f=cC().Stream,{Buffer:m}=Uc(),y=eh(),{addAbortSignal:h}=rE(),{getHighWaterMark:b,getDefaultHighWaterMark:g}=iE(),{ERR_INVALID_ARG_TYPE:x,ERR_METHOD_NOT_IMPLEMENTED:v,ERR_MULTIPLE_CALLBACK:D,ERR_STREAM_CANNOT_PIPE:T,ERR_STREAM_DESTROYED:N,ERR_STREAM_ALREADY_FINISHED:O,ERR_STREAM_NULL_VALUES:C,ERR_STREAM_WRITE_AFTER_END:X,ERR_UNKNOWN_ENCODING:te}=is().codes,{errorOrDestroy:L}=y;l(pe.prototype,f.prototype),l(pe,f);function Y(){}var me=u("kOnFinished");function I(G,V,j){typeof j!="boolean"&&(j=V instanceof qc()),this.objectMode=!!(G&&G.objectMode),j&&(this.objectMode=this.objectMode||!!(G&&G.writableObjectMode)),this.highWaterMark=G?b(this,G,"writableHighWaterMark",j):g(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;let H=!!(G&&G.decodeStrings===!1);this.decodeStrings=!H,this.defaultEncoding=G&&G.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=J.bind(void 0,V),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,Z(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!G||G.emitClose!==!1,this.autoDestroy=!G||G.autoDestroy!==!1,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[me]=[]}function Z(G){G.buffered=[],G.bufferedIndex=0,G.allBuffers=!0,G.allNoop=!0}I.prototype.getBuffer=function(){return r(this.buffered,this.bufferedIndex)},o(I.prototype,"bufferedRequestCount",{__proto__:null,get(){return this.buffered.length-this.bufferedIndex}});function pe(G){let V=this instanceof qc();if(!V&&!s(pe,this))return new pe(G);this._writableState=new I(G,this,V),G&&(typeof G.write=="function"&&(this._write=G.write),typeof G.writev=="function"&&(this._writev=G.writev),typeof G.destroy=="function"&&(this._destroy=G.destroy),typeof G.final=="function"&&(this._final=G.final),typeof G.construct=="function"&&(this._construct=G.construct),G.signal&&h(G.signal,this)),f.call(this,G),y.construct(this,()=>{let j=this._writableState;j.writing||Le(this,j),se(this,j)})}o(pe,p,{__proto__:null,value:function(G){return s(this,G)?!0:this!==pe?!1:G&&G._writableState instanceof I}}),pe.prototype.pipe=function(){L(this,new T)};function de(G,V,j,H){let ge=G._writableState;if(typeof j=="function")H=j,j=ge.defaultEncoding;else{if(!j)j=ge.defaultEncoding;else if(j!=="buffer"&&!m.isEncoding(j))throw new te(j);typeof H!="function"&&(H=Y)}if(V===null)throw new C;if(!ge.objectMode)if(typeof V=="string")ge.decodeStrings!==!1&&(V=m.from(V,j),j="buffer");else if(V instanceof m)j="buffer";else if(f._isUint8Array(V))V=f._uint8ArrayToBuffer(V),j="buffer";else throw new x("chunk",["string","Buffer","Uint8Array"],V);let fe;return ge.ending?fe=new X:ge.destroyed&&(fe=new N("write")),fe?(n.nextTick(H,fe),L(G,fe,!0),fe):(ge.pendingcb++,je(G,ge,V,j,H))}pe.prototype.write=function(G,V,j){return de(this,G,V,j)===!0},pe.prototype.cork=function(){this._writableState.corked++},pe.prototype.uncork=function(){let G=this._writableState;G.corked&&(G.corked--,G.writing||Le(this,G))},pe.prototype.setDefaultEncoding=function(G){if(typeof G=="string"&&(G=c(G)),!m.isEncoding(G))throw new te(G);return this._writableState.defaultEncoding=G,this};function je(G,V,j,H,ge){let fe=V.objectMode?1:j.length;V.length+=fe;let W=V.lengthj.bufferedIndex&&Le(G,j),H?j.afterWriteTickInfo!==null&&j.afterWriteTickInfo.cb===ge?j.afterWriteTickInfo.count++:(j.afterWriteTickInfo={count:1,cb:ge,stream:G,state:j},n.nextTick(_e,j.afterWriteTickInfo)):ue(G,j,1,ge))}function _e({stream:G,state:V,count:j,cb:H}){return V.afterWriteTickInfo=null,ue(G,V,j,H)}function ue(G,V,j,H){for(!V.ending&&!G.destroyed&&V.length===0&&V.needDrain&&(V.needDrain=!1,G.emit("drain"));j-- >0;)V.pendingcb--,H();V.destroyed&&ce(V),se(G,V)}function ce(G){if(G.writing)return;for(let ge=G.bufferedIndex;ge1&&G._writev){V.pendingcb-=fe-1;let ye=V.allNoop?Y:(Se)=>{for(let Ce=W;Ce256?(j.splice(0,W),V.bufferedIndex=0):V.bufferedIndex=W}V.bufferProcessing=!1}pe.prototype._write=function(G,V,j){if(this._writev)this._writev([{chunk:G,encoding:V}],j);else throw new v("_write()")},pe.prototype._writev=null,pe.prototype.end=function(G,V,j){let H=this._writableState;typeof G=="function"?(j=G,G=null,V=null):typeof V=="function"&&(j=V,V=null);let ge;if(G!=null){let fe=de(this,G,V);fe instanceof i&&(ge=fe)}return H.corked&&(H.corked=1,this.uncork()),ge||(!H.errored&&!H.ending?(H.ending=!0,se(this,H,!0),H.ended=!0):H.finished?ge=new O("end"):H.destroyed&&(ge=new N("end"))),typeof j=="function"&&(ge||H.finished?n.nextTick(j,ge):H[me].push(j)),this};function Ke(G){return G.ending&&!G.destroyed&&G.constructed&&G.length===0&&!G.errored&&G.buffered.length===0&&!G.finished&&!G.writing&&!G.errorEmitted&&!G.closeEmitted}function ct(G,V){let j=!1;function H(ge){if(j){L(G,ge!=null?ge:D());return}if(j=!0,V.pendingcb--,ge){let fe=V[me].splice(0);for(let W=0;W{Ke(ge)?he(H,ge):ge.pendingcb--},G,V)):Ke(V)&&(V.pendingcb++,he(G,V))))}function he(G,V){V.pendingcb--,V.finished=!0;let j=V[me].splice(0);for(let H=0;H{var n=wf(),r=Uc(),{isReadable:i,isWritable:s,isIterable:o,isNodeStream:a,isReadableNodeStream:l,isWritableNodeStream:c,isDuplexNodeStream:u,isReadableStream:p,isWritableStream:d}=Bc(),f=wp(),{AbortError:m,codes:{ERR_INVALID_ARG_TYPE:y,ERR_INVALID_RETURN_VALUE:h}}=is(),{destroyer:b}=eh(),g=qc(),x=sE(),v=uC(),{createDeferredPromise:D}=Ls(),T=Nae(),N=globalThis.Blob||r.Blob,O=typeof N<"u"?function(me){return me instanceof N}:function(me){return!1},C=globalThis.AbortController||c_().AbortController,{FunctionPrototypeCall:X}=or(),te=class extends g{constructor(me){super(me),(me==null?void 0:me.readable)===!1&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),(me==null?void 0:me.writable)===!1&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)}};t.exports=function me(I,Z){if(u(I))return I;if(l(I))return Y({readable:I});if(c(I))return Y({writable:I});if(a(I))return Y({writable:!1,readable:!1});if(p(I))return Y({readable:x.fromWeb(I)});if(d(I))return Y({writable:v.fromWeb(I)});if(typeof I=="function"){let{value:de,write:je,final:be,destroy:Ie}=L(I);if(o(de))return T(te,de,{objectMode:!0,write:je,final:be,destroy:Ie});let J=de==null?void 0:de.then;if(typeof J=="function"){let _e,ue=X(J,de,(ce)=>{if(ce!=null)throw new h("nully","body",ce)},(ce)=>{b(_e,ce)});return _e=new te({objectMode:!0,readable:!1,write:je,final(ce){be(async()=>{try{await ue,n.nextTick(ce,null)}catch(Le){n.nextTick(ce,Le)}})},destroy:Ie})}throw new h("Iterable, AsyncIterable or AsyncFunction",Z,de)}if(O(I))return me(I.arrayBuffer());if(o(I))return T(te,I,{objectMode:!0,writable:!1});if(p(I==null?void 0:I.readable)&&d(I==null?void 0:I.writable))return te.fromWeb(I);if(typeof(I==null?void 0:I.writable)=="object"||typeof(I==null?void 0:I.readable)=="object"){let de=I!=null&&I.readable?l(I==null?void 0:I.readable)?I==null?void 0:I.readable:me(I.readable):void 0,je=I!=null&&I.writable?c(I==null?void 0:I.writable)?I==null?void 0:I.writable:me(I.writable):void 0;return Y({readable:de,writable:je})}let pe=I==null?void 0:I.then;if(typeof pe=="function"){let de;return X(pe,I,(je)=>{je!=null&&de.push(je),de.push(null)},(je)=>{b(de,je)}),de=new te({objectMode:!0,writable:!1,read(){}})}throw new y(Z,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],I)};function L(me){let{promise:I,resolve:Z}=D(),pe=new C,de=pe.signal;return{value:me(function(){return xp(this,null,function*(){for(;;){let je=I;I=null;let{chunk:be,done:Ie,cb:J}=yield new Cs(je);if(n.nextTick(J),Ie)return;if(de.aborted)throw new m(void 0,{cause:de.reason});({promise:I,resolve:Z}=D()),yield be}})}(),{signal:de}),write(je,be,Ie){let J=Z;Z=null,J({chunk:je,done:!1,cb:Ie})},final(je){let be=Z;Z=null,be({done:!0,cb:je})},destroy(je,be){pe.abort(),be(je)}}}function Y(me){let I=me.readable&&typeof me.readable.read!="function"?x.wrap(me.readable):me.readable,Z=me.writable,pe=!!i(I),de=!!s(Z),je,be,Ie,J,_e;function ue(ce){let Le=J;J=null,Le?Le(ce):ce&&_e.destroy(ce)}return _e=new te({readableObjectMode:!!(I!=null&&I.readableObjectMode),writableObjectMode:!!(Z!=null&&Z.writableObjectMode),readable:pe,writable:de}),de&&(f(Z,(ce)=>{de=!1,ce&&b(I,ce),ue(ce)}),_e._write=function(ce,Le,Ke){Z.write(ce,Le)?Ke():je=Ke},_e._final=function(ce){Z.end(),be=ce},Z.on("drain",function(){if(je){let ce=je;je=null,ce()}}),Z.on("finish",function(){if(be){let ce=be;be=null,ce()}})),pe&&(f(I,(ce)=>{pe=!1,ce&&b(I,ce),ue(ce)}),I.on("readable",function(){if(Ie){let ce=Ie;Ie=null,ce()}}),I.on("end",function(){_e.push(null)}),_e._read=function(){for(;;){let ce=I.read();if(ce===null){Ie=_e._read;return}if(!_e.push(ce))return}}),_e._destroy=function(ce,Le){!ce&&J!==null&&(ce=new m),Ie=null,je=null,be=null,J===null?Le(ce):(J=Le,b(Z,ce),b(I,ce))},_e}}),qc=un((e,t)=>{var{ObjectDefineProperties:n,ObjectGetOwnPropertyDescriptor:r,ObjectKeys:i,ObjectSetPrototypeOf:s}=or();t.exports=l;var o=sE(),a=uC();s(l.prototype,o.prototype),s(l,o);{let d=i(a.prototype);for(let f=0;f{var{ObjectSetPrototypeOf:n,Symbol:r}=or();t.exports=l;var{ERR_METHOD_NOT_IMPLEMENTED:i}=is().codes,s=qc(),{getHighWaterMark:o}=iE();n(l.prototype,s.prototype),n(l,s);var a=r("kCallback");function l(p){if(!(this instanceof l))return new l(p);let d=p?o(this,p,"readableHighWaterMark",!0):null;d===0&&(p=eE(Ms({},p),{highWaterMark:null,readableHighWaterMark:d,writableHighWaterMark:p.writableHighWaterMark||0})),s.call(this,p),this._readableState.sync=!1,this[a]=null,p&&(typeof p.transform=="function"&&(this._transform=p.transform),typeof p.flush=="function"&&(this._flush=p.flush)),this.on("prefinish",u)}function c(p){typeof this._flush=="function"&&!this.destroyed?this._flush((d,f)=>{if(d){p?p(d):this.destroy(d);return}f!=null&&this.push(f),this.push(null),p&&p()}):(this.push(null),p&&p())}function u(){this._final!==c&&c.call(this)}l.prototype._final=c,l.prototype._transform=function(p,d,f){throw new i("_transform()")},l.prototype._write=function(p,d,f){let m=this._readableState,y=this._writableState,h=m.length;this._transform(p,d,(b,g)=>{if(b){f(b);return}g!=null&&this.push(g),y.ended||h===m.length||m.length{var{ObjectSetPrototypeOf:n}=or();t.exports=i;var r=Oae();n(i.prototype,r.prototype),n(i,r);function i(s){if(!(this instanceof i))return new i(s);r.call(this,s)}i.prototype._transform=function(s,o,a){a(null,s)}}),pC=un((e,t)=>{var n=wf(),{ArrayIsArray:r,Promise:i,SymbolAsyncIterator:s,SymbolDispose:o}=or(),a=wp(),{once:l}=Ls(),c=eh(),u=qc(),{aggregateTwoErrors:p,codes:{ERR_INVALID_ARG_TYPE:d,ERR_INVALID_RETURN_VALUE:f,ERR_MISSING_ARGS:m,ERR_STREAM_DESTROYED:y,ERR_STREAM_PREMATURE_CLOSE:h},AbortError:b}=is(),{validateFunction:g,validateAbortSignal:x}=u_(),{isIterable:v,isReadable:D,isReadableNodeStream:T,isNodeStream:N,isTransformStream:O,isWebStream:C,isReadableStream:X,isReadableFinished:te}=Bc(),L=globalThis.AbortController||c_().AbortController,Y,me,I;function Z(ce,Le,Ke){let ct=!1;ce.on("close",()=>{ct=!0});let lt=a(ce,{readable:Le,writable:Ke},(se)=>{ct=!se});return{destroy:(se)=>{ct||(ct=!0,c.destroyer(ce,se||new y("pipe")))},cleanup:lt}}function pe(ce){return g(ce[ce.length-1],"streams[stream.length - 1]"),ce.pop()}function de(ce){if(v(ce))return ce;if(T(ce))return je(ce);throw new d("val",["Readable","Iterable","AsyncIterable"],ce)}function je(ce){return xp(this,null,function*(){me||(me=sE()),yield*_f(me.prototype[s].call(ce))})}async function be(ce,Le,Ke,{end:ct}){let lt,se=null,he=(H)=>{if(H&&(lt=H),se){let ge=se;se=null,ge()}},ke=()=>new i((H,ge)=>{lt?ge(lt):se=()=>{lt?ge(lt):H()}});Le.on("drain",he);let Re=a(Le,{readable:!1},he);try{Le.writableNeedDrain&&await ke();try{for(var Ne=sa(ce),G,V,j;G=!(V=await Ne.next()).done;G=!1){let H=V.value;Le.write(H)||await ke()}}catch(H){j=[H]}finally{try{G&&(V=Ne.return)&&await V.call(Ne)}finally{if(j)throw j[0]}}ct&&(Le.end(),await ke()),Ke()}catch(H){Ke(lt!==H?p(lt,H):H)}finally{Re(),Le.off("drain",he)}}async function Ie(ce,Le,Ke,{end:ct}){O(Le)&&(Le=Le.writable);let lt=Le.getWriter();try{try{for(var se=sa(ce),he,ke,Re;he=!(ke=await se.next()).done;he=!1){let Ne=ke.value;await lt.ready,lt.write(Ne).catch(()=>{})}}catch(Ne){Re=[Ne]}finally{try{he&&(ke=se.return)&&await ke.call(se)}finally{if(Re)throw Re[0]}}await lt.ready,ct&&await lt.close(),Ke()}catch(Ne){try{await lt.abort(Ne),Ke(Ne)}catch(G){Ke(G)}}}function J(...ce){return _e(ce,l(pe(ce)))}function _e(ce,Le,Ke){if(ce.length===1&&r(ce[0])&&(ce=ce[0]),ce.length<2)throw new m("streams");let ct=new L,lt=ct.signal,se=Ke==null?void 0:Ke.signal,he=[];x(se,"options.signal");function ke(){ge(new b)}I=I||Ls().addAbortListener;let Re;se&&(Re=I(se,ke));let Ne,G,V=[],j=0;function H(Se){ge(Se,--j===0)}function ge(Se,Ce){var Bt;if(Se&&(!Ne||Ne.code==="ERR_STREAM_PREMATURE_CLOSE")&&(Ne=Se),!(!Ne&&!Ce)){for(;V.length;)V.shift()(Ne);(Bt=Re)===null||Bt===void 0||Bt[o](),ct.abort(),Ce&&(Ne||he.forEach((_)=>_()),n.nextTick(Le,Ne,G))}}let fe;for(let Se=0;Se0,S=Bt||(Ke==null?void 0:Ke.end)!==!1,k=Se===ce.length-1;if(N(Ce)){let E=function(A){A&&A.name!=="AbortError"&&A.code!=="ERR_STREAM_PREMATURE_CLOSE"&&H(A)};var W=E;if(S){let{destroy:A,cleanup:Q}=Z(Ce,Bt,_);V.push(A),D(Ce)&&k&&he.push(Q)}Ce.on("error",E),D(Ce)&&k&&he.push(()=>{Ce.removeListener("error",E)})}if(Se===0)if(typeof Ce=="function"){if(fe=Ce({signal:lt}),!v(fe))throw new f("Iterable, AsyncIterable or Stream","source",fe)}else v(Ce)||T(Ce)||O(Ce)?fe=Ce:fe=u.from(Ce);else if(typeof Ce=="function"){if(O(fe)){var ye;fe=de((ye=fe)===null||ye===void 0?void 0:ye.readable)}else fe=de(fe);if(fe=Ce(fe,{signal:lt}),Bt){if(!v(fe,!0))throw new f("AsyncIterable",`transform[${Se-1}]`,fe)}else{var Oe;Y||(Y=Pae());let E=new Y({objectMode:!0}),A=(Oe=fe)===null||Oe===void 0?void 0:Oe.then;if(typeof A=="function")j++,A.call(fe,(Je)=>{G=Je,Je!=null&&E.write(Je),S&&E.end(),n.nextTick(H)},(Je)=>{E.destroy(Je),n.nextTick(H,Je)});else if(v(fe,!0))j++,be(fe,E,H,{end:S});else if(X(fe)||O(fe)){let Je=fe.readable||fe;j++,be(Je,E,H,{end:S})}else throw new f("AsyncIterable or Promise","destination",fe);fe=E;let{destroy:Q,cleanup:le}=Z(fe,!1,!0);V.push(Q),k&&he.push(le)}}else if(N(Ce)){if(T(fe)){j+=2;let E=ue(fe,Ce,H,{end:S});D(Ce)&&k&&he.push(E)}else if(O(fe)||X(fe)){let E=fe.readable||fe;j++,be(E,Ce,H,{end:S})}else if(v(fe))j++,be(fe,Ce,H,{end:S});else throw new d("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],fe);fe=Ce}else if(C(Ce)){if(T(fe))j++,Ie(de(fe),Ce,H,{end:S});else if(X(fe)||v(fe))j++,Ie(fe,Ce,H,{end:S});else if(O(fe))j++,Ie(fe.readable,Ce,H,{end:S});else throw new d("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],fe);fe=Ce}else fe=u.from(Ce)}return(lt!=null&<.aborted||se!=null&&se.aborted)&&n.nextTick(ke),fe}function ue(ce,Le,Ke,{end:ct}){let lt=!1;if(Le.on("close",()=>{lt||Ke(new h)}),ce.pipe(Le,{end:!1}),ct){let he=function(){lt=!0,Le.end()};var se=he;te(ce)?n.nextTick(he):ce.once("end",he)}else Ke();return a(ce,{readable:!0,writable:!1},(he)=>{let ke=ce._readableState;he&&he.code==="ERR_STREAM_PREMATURE_CLOSE"&&ke&&ke.ended&&!ke.errored&&!ke.errorEmitted?ce.once("end",Ke).once("error",Ke):Ke(he)}),a(Le,{readable:!1,writable:!0},Ke)}t.exports={pipelineImpl:_e,pipeline:J}}),$ae=un((e,t)=>{var{pipeline:n}=pC(),r=qc(),{destroyer:i}=eh(),{isNodeStream:s,isReadable:o,isWritable:a,isWebStream:l,isTransformStream:c,isWritableStream:u,isReadableStream:p}=Bc(),{AbortError:d,codes:{ERR_INVALID_ARG_VALUE:f,ERR_MISSING_ARGS:m}}=is(),y=wp();t.exports=function(...h){if(h.length===0)throw new m("streams");if(h.length===1)return r.from(h[0]);let b=[...h];if(typeof h[0]=="function"&&(h[0]=r.from(h[0])),typeof h[h.length-1]=="function"){let L=h.length-1;h[L]=r.from(h[L])}for(let L=0;L0&&!(a(h[L])||u(h[L])||c(h[L])))throw new f(`streams[${L}]`,b[L],"must be writable")}let g,x,v,D,T;function N(L){let Y=D;D=null,Y?Y(L):L?T.destroy(L):!te&&!X&&T.destroy()}let O=h[0],C=n(h,N),X=!!(a(O)||u(O)||c(O)),te=!!(o(C)||p(C)||c(C));if(T=new r({writableObjectMode:!!(O!=null&&O.writableObjectMode),readableObjectMode:!!(C!=null&&C.readableObjectMode),writable:X,readable:te}),X){if(s(O))T._write=function(Y,me,I){O.write(Y,me)?I():g=I},T._final=function(Y){O.end(),x=Y},O.on("drain",function(){if(g){let Y=g;g=null,Y()}});else if(l(O)){let Y=(c(O)?O.writable:O).getWriter();T._write=async function(me,I,Z){try{await Y.ready,Y.write(me).catch(()=>{}),Z()}catch(pe){Z(pe)}},T._final=async function(me){try{await Y.ready,Y.close().catch(()=>{}),x=me}catch(I){me(I)}}}let L=c(C)?C.readable:C;y(L,()=>{if(x){let Y=x;x=null,Y()}})}if(te){if(s(C))C.on("readable",function(){if(v){let L=v;v=null,L()}}),C.on("end",function(){T.push(null)}),T._read=function(){for(;;){let L=C.read();if(L===null){v=T._read;return}if(!T.push(L))return}};else if(l(C)){let L=(c(C)?C.readable:C).getReader();T._read=async function(){for(;;)try{let{value:Y,done:me}=await L.read();if(!T.push(Y))return;if(me){T.push(null);return}}catch(Y){return}}}}return T._destroy=function(L,Y){!L&&D!==null&&(L=new d),v=null,g=null,x=null,D===null?Y(L):(D=Y,s(C)&&i(C,L))},T}}),pVe=un((e,t)=>{var n=globalThis.AbortController||c_().AbortController,{codes:{ERR_INVALID_ARG_VALUE:r,ERR_INVALID_ARG_TYPE:i,ERR_MISSING_ARGS:s,ERR_OUT_OF_RANGE:o},AbortError:a}=is(),{validateAbortSignal:l,validateInteger:c,validateObject:u}=u_(),p=or().Symbol("kWeak"),d=or().Symbol("kResistStopPropagation"),{finished:f}=wp(),m=$ae(),{addAbortSignalNoValidate:y}=rE(),{isWritable:h,isNodeStream:b}=Bc(),{deprecate:g}=Ls(),{ArrayPrototypePush:x,Boolean:v,MathFloor:D,Number:T,NumberIsNaN:N,Promise:O,PromiseReject:C,PromiseResolve:X,PromisePrototypeThen:te,Symbol:L}=or(),Y=L("kEmpty"),me=L("kEof");function I(se,he){if(he!=null&&u(he,"options"),(he==null?void 0:he.signal)!=null&&l(he.signal,"options.signal"),b(se)&&!h(se))throw new r("stream",se,"must be writable");let ke=m(this,se);return he!=null&&he.signal&&y(he.signal,ke),ke}function Z(se,he){if(typeof se!="function")throw new i("fn",["Function","AsyncFunction"],se);he!=null&&u(he,"options"),(he==null?void 0:he.signal)!=null&&l(he.signal,"options.signal");let ke=1;(he==null?void 0:he.concurrency)!=null&&(ke=D(he.concurrency));let Re=ke-1;return(he==null?void 0:he.highWaterMark)!=null&&(Re=D(he.highWaterMark)),c(ke,"options.concurrency",1),c(Re,"options.highWaterMark",0),Re+=ke,function(){return xp(this,null,function*(){let Ne=Ls().AbortSignalAny([he==null?void 0:he.signal].filter(v)),G=this,V=[],j={signal:Ne},H,ge,fe=!1,W=0;function ye(){fe=!0,Oe()}function Oe(){W-=1,Se()}function Se(){ge&&!fe&&W=Re||W>=ke)&&await new O((A)=>{ge=A})}}catch(E){k=[E]}finally{try{_&&(S=Bt.return)&&await S.call(Bt)}finally{if(k)throw k[0]}}V.push(me)}catch(E){let A=C(E);te(A,Oe,ye),V.push(A)}finally{fe=!0,H&&(H(),H=null)}}Ce();try{for(;;){for(;V.length>0;){let Bt=yield new Cs(V[0]);if(Bt===me)return;if(Ne.aborted)throw new a;Bt!==Y&&(yield Bt),V.shift(),Se()}yield new Cs(new O((Bt)=>{H=Bt}))}}finally{fe=!0,ge&&(ge(),ge=null)}})}.call(this)}function pe(se=void 0){return se!=null&&u(se,"options"),(se==null?void 0:se.signal)!=null&&l(se.signal,"options.signal"),function(){return xp(this,null,function*(){let he=0;try{for(var ke=sa(this),Re,Ne,G;Re=!(Ne=yield new Cs(ke.next())).done;Re=!1){let j=Ne.value;var V;if(se!=null&&(V=se.signal)!==null&&V!==void 0&&V.aborted)throw new a({cause:se.signal.reason});yield[he++,j]}}catch(j){G=[j]}finally{try{Re&&(Ne=ke.return)&&(yield new Cs(Ne.call(ke)))}finally{if(G)throw G[0]}}})}.call(this)}async function de(se,he=void 0){try{for(var ke=sa(J.call(this,se,he)),Re,Ne,G;Re=!(Ne=await ke.next()).done;Re=!1){let V=Ne.value;return!0}}catch(V){G=[V]}finally{try{Re&&(Ne=ke.return)&&await Ne.call(ke)}finally{if(G)throw G[0]}}return!1}async function je(se,he=void 0){if(typeof se!="function")throw new i("fn",["Function","AsyncFunction"],se);return!await de.call(this,async(...ke)=>!await se(...ke),he)}async function be(se,he){try{for(var ke=sa(J.call(this,se,he)),Re,Ne,G;Re=!(Ne=await ke.next()).done;Re=!1)return Ne.value}catch(V){G=[V]}finally{try{Re&&(Ne=ke.return)&&await Ne.call(ke)}finally{if(G)throw G[0]}}}async function Ie(se,he){if(typeof se!="function")throw new i("fn",["Function","AsyncFunction"],se);async function ke(j,H){return await se(j,H),Y}try{for(var Re=sa(Z.call(this,ke,he)),Ne,G,V;Ne=!(G=await Re.next()).done;Ne=!1){let j=G.value}}catch(j){V=[j]}finally{try{Ne&&(G=Re.return)&&await G.call(Re)}finally{if(V)throw V[0]}}}function J(se,he){if(typeof se!="function")throw new i("fn",["Function","AsyncFunction"],se);async function ke(Re,Ne){return await se(Re,Ne)?Re:Y}return Z.call(this,ke,he)}var _e=class extends s{constructor(){super("reduce"),this.message="Reduce of an empty stream requires an initial value"}};async function ue(se,he,ke){var Re;if(typeof se!="function")throw new i("reducer",["Function","AsyncFunction"],se);ke!=null&&u(ke,"options"),(ke==null?void 0:ke.signal)!=null&&l(ke.signal,"options.signal");let Ne=arguments.length>1;if(ke!=null&&(Re=ke.signal)!==null&&Re!==void 0&&Re.aborted){let Oe=new a(void 0,{cause:ke.signal.reason});throw this.once("error",()=>{}),await f(this.destroy(Oe)),Oe}let G=new n,V=G.signal;if(ke!=null&&ke.signal){let Oe={once:!0,[p]:this,[d]:!0};ke.signal.addEventListener("abort",()=>G.abort(),Oe)}let j=!1;try{try{for(var H=sa(this),ge,fe,W;ge=!(fe=await H.next()).done;ge=!1){let Oe=fe.value;var ye;if(j=!0,ke!=null&&(ye=ke.signal)!==null&&ye!==void 0&&ye.aborted)throw new a;Ne?he=await se(he,Oe,{signal:V}):(he=Oe,Ne=!0)}}catch(Oe){W=[Oe]}finally{try{ge&&(fe=H.return)&&await fe.call(H)}finally{if(W)throw W[0]}}if(!j&&!Ne)throw new _e}finally{G.abort()}return he}async function ce(se){se!=null&&u(se,"options"),(se==null?void 0:se.signal)!=null&&l(se.signal,"options.signal");let he=[];try{for(var ke=sa(this),Re,Ne,G;Re=!(Ne=await ke.next()).done;Re=!1){let j=Ne.value;var V;if(se!=null&&(V=se.signal)!==null&&V!==void 0&&V.aborted)throw new a(void 0,{cause:se.signal.reason});x(he,j)}}catch(j){G=[j]}finally{try{Re&&(Ne=ke.return)&&await Ne.call(ke)}finally{if(G)throw G[0]}}return he}function Le(se,he){let ke=Z.call(this,se,he);return function(){return xp(this,null,function*(){try{for(var Re=sa(ke),Ne,G,V;Ne=!(G=yield new Cs(Re.next())).done;Ne=!1){let j=G.value;yield*_f(j)}}catch(j){V=[j]}finally{try{Ne&&(G=Re.return)&&(yield new Cs(G.call(Re)))}finally{if(V)throw V[0]}}})}.call(this)}function Ke(se){if(se=T(se),N(se))return 0;if(se<0)throw new o("number",">= 0",se);return se}function ct(se,he=void 0){return he!=null&&u(he,"options"),(he==null?void 0:he.signal)!=null&&l(he.signal,"options.signal"),se=Ke(se),function(){return xp(this,null,function*(){var ke;if(he!=null&&(ke=he.signal)!==null&&ke!==void 0&&ke.aborted)throw new a;try{for(var Re=sa(this),Ne,G,V;Ne=!(G=yield new Cs(Re.next())).done;Ne=!1){let H=G.value;var j;if(he!=null&&(j=he.signal)!==null&&j!==void 0&&j.aborted)throw new a;se--<=0&&(yield H)}}catch(H){V=[H]}finally{try{Ne&&(G=Re.return)&&(yield new Cs(G.call(Re)))}finally{if(V)throw V[0]}}})}.call(this)}function lt(se,he=void 0){return he!=null&&u(he,"options"),(he==null?void 0:he.signal)!=null&&l(he.signal,"options.signal"),se=Ke(se),function(){return xp(this,null,function*(){var ke;if(he!=null&&(ke=he.signal)!==null&&ke!==void 0&&ke.aborted)throw new a;try{for(var Re=sa(this),Ne,G,V;Ne=!(G=yield new Cs(Re.next())).done;Ne=!1){let H=G.value;var j;if(he!=null&&(j=he.signal)!==null&&j!==void 0&&j.aborted)throw new a;if(se-- >0&&(yield H),se<=0)return}}catch(H){V=[H]}finally{try{Ne&&(G=Re.return)&&(yield new Cs(G.call(Re)))}finally{if(V)throw V[0]}}})}.call(this)}t.exports.streamReturningOperators={asIndexedPairs:g(pe,"readable.asIndexedPairs will be removed in a future version."),drop:ct,filter:J,flatMap:Le,map:Z,take:lt,compose:I},t.exports.promiseReturningOperators={every:je,forEach:Ie,reduce:ue,toArray:ce,some:de,find:be}}),Iae=un((e,t)=>{var{ArrayPrototypePop:n,Promise:r}=or(),{isIterable:i,isNodeStream:s,isWebStream:o}=Bc(),{pipelineImpl:a}=pC(),{finished:l}=wp();Aae();function c(...u){return new r((p,d)=>{let f,m,y=u[u.length-1];if(y&&typeof y=="object"&&!s(y)&&!i(y)&&!o(y)){let h=n(u);f=h.signal,m=h.end}a(u,(h,b)=>{h?d(h):p(b)},{signal:f,end:m})})}t.exports={finished:l,pipeline:c}}),Aae=un((e,t)=>{var{Buffer:n}=Uc(),{ObjectDefineProperty:r,ObjectKeys:i,ReflectApply:s}=or(),{promisify:{custom:o}}=Ls(),{streamReturningOperators:a,promiseReturningOperators:l}=pVe(),{codes:{ERR_ILLEGAL_CONSTRUCTOR:c}}=is(),u=$ae(),{setDefaultHighWaterMark:p,getDefaultHighWaterMark:d}=iE(),{pipeline:f}=pC(),{destroyer:m}=eh(),y=wp(),h=Iae(),b=Bc(),g=t.exports=cC().Stream;g.isDestroyed=b.isDestroyed,g.isDisturbed=b.isDisturbed,g.isErrored=b.isErrored,g.isReadable=b.isReadable,g.isWritable=b.isWritable,g.Readable=sE();for(let v of i(a)){let D=function(...N){if(new.target)throw c();return g.Readable.from(s(T,this,N))},T=a[v];r(D,"name",{__proto__:null,value:T.name}),r(D,"length",{__proto__:null,value:T.length}),r(g.Readable.prototype,v,{__proto__:null,value:D,enumerable:!1,configurable:!0,writable:!0})}for(let v of i(l)){let D=function(...N){if(new.target)throw c();return s(T,this,N)},T=l[v];r(D,"name",{__proto__:null,value:T.name}),r(D,"length",{__proto__:null,value:T.length}),r(g.Readable.prototype,v,{__proto__:null,value:D,enumerable:!1,configurable:!0,writable:!0})}g.Writable=uC(),g.Duplex=qc(),g.Transform=Oae(),g.PassThrough=Pae(),g.pipeline=f;var{addAbortSignal:x}=rE();g.addAbortSignal=x,g.finished=y,g.destroy=m,g.compose=u,g.setDefaultHighWaterMark=p,g.getDefaultHighWaterMark=d,r(g,"promises",{__proto__:null,configurable:!0,enumerable:!0,get(){return h}}),r(f,o,{__proto__:null,enumerable:!0,get(){return h.pipeline}}),r(y,o,{__proto__:null,enumerable:!0,get(){return h.finished}}),g.Stream=g,g._isUint8Array=function(v){return v instanceof Uint8Array},g._uint8ArrayToBuffer=function(v){return n.from(v.buffer,v.byteOffset,v.byteLength)}}),dC=un((e,t)=>{var n=Aae(),r=Iae(),i=n.Readable.destroy;t.exports=n.Readable,t.exports._uint8ArrayToBuffer=n._uint8ArrayToBuffer,t.exports._isUint8Array=n._isUint8Array,t.exports.isDisturbed=n.isDisturbed,t.exports.isErrored=n.isErrored,t.exports.isReadable=n.isReadable,t.exports.Readable=n.Readable,t.exports.Writable=n.Writable,t.exports.Duplex=n.Duplex,t.exports.Transform=n.Transform,t.exports.PassThrough=n.PassThrough,t.exports.addAbortSignal=n.addAbortSignal,t.exports.finished=n.finished,t.exports.destroy=n.destroy,t.exports.destroy=i,t.exports.pipeline=n.pipeline,t.exports.compose=n.compose,Object.defineProperty(n,"promises",{configurable:!0,enumerable:!0,get(){return r}}),t.exports.Stream=n.Stream,t.exports.default=t.exports}),dVe=tE(Uc()),vf="http://www.w3.org/1999/02/22-rdf-syntax-ns#",zy="http://www.w3.org/2001/XMLSchema#",HS="http://www.w3.org/2000/10/swap/",br={xsd:{decimal:`${zy}decimal`,boolean:`${zy}boolean`,dateTime:`${zy}dateTime`,double:`${zy}double`,integer:`${zy}integer`,string:`${zy}string`},rdf:{type:`${vf}type`,nil:`${vf}nil`,first:`${vf}first`,rest:`${vf}rest`,langString:`${vf}langString`,dirLangString:`${vf}dirLangString`,reifies:`${vf}reifies`},owl:{sameAs:"http://www.w3.org/2002/07/owl#sameAs"},r:{forSome:`${HS}reify#forSome`,forAll:`${HS}reify#forAll`},log:{implies:`${HS}log#implies`,isImpliedBy:`${HS}log#isImpliedBy`}},{xsd:zS}=br,WS=32,QS=9,hae=10,YS=13,fVe=35,mVe=/\\u([a-fA-F0-9]{4})|\\U([a-fA-F0-9]{8})|\\([^])/g,gae={"\\":"\\","'":"'",'"':'"',n:` -`,r:"\r",t:"\t",f:"\f",b:"\b"},yVe={_:"_","~":"~",".":".","-":"-","!":"!",$:"$","&":"&","'":"'","(":"(",")":")","*":"*","+":"+",",":",",";":";","=":"=","/":"/","?":"?","#":"#","@":"@","%":"%"},hVe=/[\x00-\x20<>\\"\{\}\|\^\`]/;function bae(e){return e<=1114111&&(e<55296||e>57343)}var gVe={_iri:!0,_unescapedIri:!0,_simpleQuotedString:!0,_langcode:!0,_blank:!0,_commentLine:!0,_whitespace:!0},bVe=/$0^/,vVe=class{constructor(e){if(this._iri=/^<((?:[^ <>{}\\]|\\[uU])+)>[ \t]*/,this._unescapedIri=/^<([^\x00-\x20<>\\"\{\}\|\^\`]*)>[ \t]*/,this._simpleQuotedString=/^"([^"\\\r\n]*)"(?=[^"])/,this._simpleApostropheString=/^'([^'\\\r\n]*)'(?=[^'])/,this._langcode=/^@([a-z]+(?:-[a-z0-9]+)*)(?=[^a-z0-9])/i,this._prefix=/^((?:[A-Za-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)?:(?=[#\s<])/,this._prefixed=/^((?:[A-Za-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)?:((?:(?:[0-:A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~])(?:(?:[\.\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~])*(?:[\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~]))?)?)(?:[ \t]+|(?=\.?[,;!\^\s#()\[\]\{\}"'<>]))/,this._variable=/^\?(?:(?:[A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:[\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)(?=[.,;!\^\s#()\[\]\{\}"'<>])/,this._blank=/^_:((?:[0-9A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)(?:[ \t]+|(?=\.?[,;:!\^\s#()\[\]\{\}"'<>]))/,this._number=/^[\-+]?(?:(\d+\.\d*|\.?\d+)[eE][\-+]?|\d*(\.)?)\d+(?=\.?[,;:!\^\s#()\[\]\{\}"'<>])/,this._boolean=/^(?:true|false)(?=[.,;!\^\s#()\[\]\{\}"'<>])/,this._atKeyword=/^@[a-z]+(?=[\s#<:])/i,this._keyword=/^(?:PREFIX|BASE|VERSION|GRAPH)(?=[\s#<])/i,this._n3Verb=/^(?:has|is|of)(?=[\s#()\[\]\{\}"'<>?_+\-0-9])/,this._n3Id=/^id(?=[\s#<])/,this._shortPredicates=/^a(?=[\s#()\[\]\{\}"'<>])/,this._commentLine=/^[ \t]*#([^\n\r]*)(?:\r\n|\n|\r)([ \t]*)/,this._whitespace=/^[ \t]+/,e=e||{},this._isImpliedBy=e.isImpliedBy,this._lineMode=!!e.lineMode){this._n3Mode=!1;for(let t in this)!(t in gVe)&&this[t]instanceof RegExp&&(this[t]=bVe)}else this._n3Mode=e.n3!==!1;this.comments=!!e.comments,this._literalClosingPos=0}_tokenizeToEnd(e,t){let n=this._input,r=this._linePosition+n.length;for(;;){for(;;){let x=n.charCodeAt(0),v=0;if(x===WS||x===QS){let D=n.charCodeAt(1);v=D===WS||D===QS?this._whitespace.exec(n)[0].length:1,x=n.charCodeAt(v)}if(x===fVe){let D=this._commentLine.exec(n);if(D){let T=D[0].length;if(!t&&T===n.length&&n.charCodeAt(T-1)===YS)return this._linePosition=r-n.length,this._input=n;this.comments&&i(D[1],this._line,v),n=n.slice(T),r=n.length+D[2].length,this._line++}else{if(n=n.slice(v),!t)return this._linePosition=r-n.length,this._input=n;this.comments&&i(n.slice(1),this._line,0),n="";break}}else if(x===hae||x===YS){if(!t&&x===YS&&v+1===n.length)return this._linePosition=r-n.length,this._input=n;v+=x===YS&&n.charCodeAt(v+1)===hae?2:1;let D=0,T=n.charCodeAt(v);if(T===WS||T===QS){let N=n.charCodeAt(v+1);D=N===WS||N===QS?this._whitespace.exec(n.slice(v))[0].length:1}n=n.slice(v+D),r=n.length+D,this._line++}else{v!==0&&(n=n.slice(v));break}}if(n.length===0)return t&&(n=null,s("eof","","",this._line,0)),this._linePosition=r,this._input=n;let a=this._line,l=n[0],c="",u="",p="",d=null,f=0,m=0,y=0,h=!1;switch(l){case"^":if(n.length<3)break;if(n[1]==="^"){if(this._previousMarker="^^",n=n.slice(2),n[0]!=="<"){h=!0;break}}else{this._n3Mode&&(f=1,c="^");break}case"<":if(d=this._unescapedIri.exec(n))c="IRI",u=d[1],m=d[1].length+2;else if(d=this._iri.exec(n)){if(u=this._unescape(d[1],gae),u===null||hVe.test(u))return o(this);c="IRI",m=d[1].length+2}else n.length>2&&n[1]==="<"&&n[2]==="("?(c="<<(",f=3):!this._lineMode&&n.length>(t?1:2)&&n[1]==="<"?(c="<<",f=2):this._n3Mode&&n.length>1&&n[1]==="="?(f=2,this._isImpliedBy?(c="abbreviation",u="<"):(c="inverse",u=">")):this._n3Mode&&n.length>1&&n[1]==="-"&&(c="inversePredicate",f=2);break;case">":n.length>1&&n[1]===">"&&(c=">>",f=2);break;case"_":((d=this._blank.exec(n))||t&&(d=this._blank.exec(`${n} `)))&&(c="blank",p="_",u=d[1],m=d[1].length+2);break;case'"':if(d=this._simpleQuotedString.exec(n))u=d[1];else if({value:u,matchLength:f,finalLineLength:y}=this._parseLiteral(n),u===null)return o(this);(d!==null||f!==0)&&(c="literal",this._literalClosingPos=0);break;case"'":if(!this._lineMode){if(d=this._simpleApostropheString.exec(n))u=d[1];else if({value:u,matchLength:f,finalLineLength:y}=this._parseLiteral(n),u===null)return o(this);(d!==null||f!==0)&&(c="literal",this._literalClosingPos=0)}break;case"?":this._n3Mode&&(d=this._variable.exec(n))&&(c="var",u=d[0]);break;case"@":this._previousMarker==="literal"&&(d=this._langcode.exec(n))&&d[1]!=="version"?!t&&n[d[0].length]==="-"&&n[d[0].length+1]!=="-"?d=null:(c="langcode",u=d[1]):(d=this._atKeyword.exec(n))&&(c=d[0]);break;case".":if(n.length===1?t:n[1]<"0"||n[1]>"9"){c=".",f=1;break}case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":case"+":case"-":if(n[1]==="-"){this._previousMarker==="langcode"&&(n.startsWith("--ltr")?(c="dircode",u="ltr",f=5):n.startsWith("--rtl")&&(c="dircode",u="rtl",f=5));break}(d=this._number.exec(n)||t&&(d=this._number.exec(`${n} `)))&&(c="literal",u=d[0],p=typeof d[1]=="string"?zS.double:typeof d[2]=="string"?zS.decimal:zS.integer);break;case"B":case"b":case"p":case"P":case"G":case"g":case"V":case"v":(d=this._keyword.exec(n))?c=d[0].toUpperCase():h=!0;break;case"f":case"t":this._boolean.test(n)?(c="literal",u=l==="t"?"true":"false",p=zS.boolean,f=u.length):h=!0;break;case"a":this._shortPredicates.test(n)?(c="abbreviation",u="a",f=1):h=!0;break;case"h":case"o":this._n3Mode&&(d=this._matchN3Verb(n,t))?c=d[0]:h=!0;break;case"i":this._n3Mode&&this._n3Id.test(n)?(c="id",f=2):this._n3Mode&&(d=this._matchN3Verb(n,t))?c=d[0]:h=!0;break;case"=":this._n3Mode&&n.length>1&&(c="abbreviation",n[1]!==">"?(f=1,u="="):(f=2,u=">"));break;case"!":if(!this._n3Mode)break;case")":if(!t&&(n.length===1||n.length===2&&n[1]===">"))break;if(n.length>2&&n[1]===">"&&n[2]===">"){c=")>>",f=3;break}case",":case";":case"[":case"]":case"(":case"}":case"~":this._lineMode||(f=1,c=l);break;case"{":!this._lineMode&&n.length>=2&&(n[1]==="|"?(c="{|",f=2):(c=l,f=1));break;case"|":n.length>=2&&n[1]==="}"&&(c="|}",f=2);break;default:h=!0}if(h&&((this._previousMarker==="@prefix"||this._previousMarker==="PREFIX")&&(d=this._prefix.exec(n))?(c="prefix",u=d[1]||""):((d=this._prefixed.exec(n))||t&&(d=this._prefixed.exec(`${n} `)))&&(c="prefixed",p=d[1]||"",u=this._unescape(d[2],yVe),m=p.length+d[2].length+1)),this._previousMarker==="^^")switch(c){case"prefixed":c="type";break;case"IRI":c="typeIRI";break;default:c=""}if(!c)return t||!/^'''|^"""/.test(n)&&/\n|\r/.test(n)?o(this):(this._linePosition=r-n.length,this._input=n);let b=f||d[0].length,g;y?(g={type:c,value:u,prefix:p,line:a,start:r-n.length,end:y,endLine:this._line},e(null,g)):g=s(c,u,p,a,m||b),this.previousToken=g,this._previousMarker=c,n=n.slice(b),y&&(r=n.length+y)}function i(a,l,c){let u=r-n.length+c;e(null,{type:"comment",value:a,prefix:"",line:l,start:u,end:u+a.length+1})}function s(a,l,c,u,p){let d=n?r-n.length:r,f=d+p,m={type:a,value:l,prefix:c,line:u,start:d,end:f};return e(null,m),m}function o(a){e(a._syntaxError(/^\S*/.exec(n)[0]))}}_matchN3Verb(e,t){let n=this._n3Verb.exec(e);if(!n)return null;let r=e[n[0].length];return r!=="-"&&r!=="_"&&(r<"0"||r>"9")?n:this._prefixed.exec(e)||this._prefixed.exec(`${e} `)||!t&&this._prefix.exec(`${e}: `)?null:n}_unescape(e,t){if(e.indexOf("\\")<0)return e;let n=!1,r=e.replace(mVe,(i,s,o,a)=>{if(typeof s=="string"){let l=Number.parseInt(s,16);return bae(l)?String.fromCharCode(l):(n=!0,"")}if(typeof o=="string"){let l=Number.parseInt(o,16);return bae(l)?l<=65535?String.fromCharCode(Number.parseInt(o,16)):String.fromCharCode(55296+((l-=65536)>>10),56320+(l&1023)):(n=!0,"")}return a in t?t[a]:(n=!0,"")});return n?null:r}_parseLiteral(e){if(e.length>=3){let t=e[0],n=e[1]===t&&e[2]===t?3:1,r=t;n===3&&(r=t==='"'?'"""':"'''");let i=Math.max(this._literalClosingPos,n);for(;(i=e.indexOf(r,i))>0;){let s=0;for(;e[i-s-1]==="\\";)s++;if(s%2===0){let o=e.substring(n,i),a=o.split(/\r\n|\r|\n/),l=a.length-1,c=i+n;if(n===1&&l!==0||n===3&&this._lineMode)break;this._line+=l;let u=l===0?0:a[a.length-1].length+n;return{value:this._unescape(o,gae),matchLength:c,finalLineLength:u}}i++}this._literalClosingPos=e.length-n+1}return{value:"",matchLength:0,finalLineLength:0}}_syntaxError(e){this._input=null;let t=Error(`Unexpected "${e}" on line ${this._line}.`);return t.context={token:void 0,line:this._line,previousToken:this.previousToken},t}_readStartingBom(e){return e.startsWith("\uFEFF")?(this._linePosition=1,e.slice(1)):e}tokenize(e,t){let n=this._tokenization={};if(this._line=1,this._linePosition=0,this._previousMarker=void 0,this.previousToken=void 0,this._literalClosingPos=0,this._input=void 0,typeof e=="string")if(this._input=this._readStartingBom(e),typeof t=="function")queueMicrotask(()=>{this._tokenization===n&&this._tokenizeToEnd(t,!0)});else{let r=[],i;if(this._tokenizeToEnd((s,o)=>s?i=s:r.push(o),!0),i)throw i;return r}else this._pendingBuffer=null,typeof e.setEncoding=="function"&&e.setEncoding("utf8"),e.on("data",(r)=>{this._tokenization===n&&this._input!==null&&r.length!==0&&(this._pendingBuffer&&(r=dVe.Buffer.concat([this._pendingBuffer,r]),this._pendingBuffer=null),r[r.length-1]&128?this._pendingBuffer=r:(typeof this._input>"u"?this._input=this._readStartingBom(typeof r=="string"?r:r.toString()):this._input+=r,this._tokenizeToEnd(t,!1)))}),e.on("end",()=>{this._tokenization===n&&typeof this._input=="string"&&this._tokenizeToEnd(t,!0)}),e.on("error",(r)=>{this._tokenization===n&&t(r)})}};var{rdf:vae,xsd:_p}=br,th,_Ve=0,aC={namedNode:Fae,blankNode:Cae,variable:Lae,literal:Mae,defaultGraph:TVe,quad:lC,triple:lC,fromTerm:l_,fromQuad:qae},ss=aC,Vc=class e{constructor(t){this.id=t}get value(){return this.id}equals(t){return t instanceof e?this.id===t.id:!!t&&this.termType===t.termType&&this.value===t.value}hashCode(){return 0}toJSON(){return{termType:this.termType,value:this.value}}},Rae=class extends Vc{constructor(e){super(e)}get termType(){return"NamedNode"}},o_=class e extends Vc{constructor(t){super(t)}get termType(){return"Literal"}get value(){return this.id.substring(1,this.id.lastIndexOf('"'))}get language(){let t=this.id,n=t.lastIndexOf('"')+1,r=t.lastIndexOf("--");return nn?t.substr(0,r):t).substr(n).toLowerCase():""}get direction(){let t=this.id,n=t.lastIndexOf('"'),r=t.lastIndexOf("--");return r>n&&r+20?vae.dirLangString:vae.langString}equals(t){return t instanceof e?this.id===t.id:!!t&&!!t.datatype&&this.termType===t.termType&&this.value===t.value&&this.language===t.language&&(this.direction===t.direction||this.direction===""&&!t.direction)&&this.datatype.value===t.datatype.value}toJSON(){return{termType:this.termType,value:this.value,language:this.language,direction:this.direction,datatype:{termType:"NamedNode",value:this.datatypeString}}}},xVe=class extends Vc{constructor(e){super(`_:${e}`)}get termType(){return"BlankNode"}get value(){return this.id.substr(2)}},wVe=class extends Vc{constructor(e){super(`?${e}`)}get termType(){return"Variable"}get value(){return this.id.substr(1)}},DVe=class extends Vc{constructor(){return super(""),th||this}get termType(){return"DefaultGraph"}equals(e){return this===e||!!e&&this.termType===e.termType}};th=new DVe;function a_(e,t,n){if(t=t||aC,!e)return t.defaultGraph();switch(e[0]){case"?":return t.variable(e.substr(1));case"_":return t.blankNode(e.substr(2));case'"':if(t===aC)return new o_(e);if(e[e.length-1]==='"')return t.literal(e.substr(1,e.length-2));let r=e.lastIndexOf('"',e.length-1),i;if(e[r+1]==="@"){i=e.substr(r+2);let s=i.lastIndexOf("--");s>0&&s0?"INF":"-INF")):e instanceof Date&&!Number.isNaN(e.getTime())&&(n=_p.dateTime,e=e.toISOString())),n===""||n===_p.string?new o_(`"${e}"`):new o_(`"${e}"^^${n}`)}function Lae(e){return new wVe(e)}function TVe(){return th}function lC(e,t,n,r){return new jae(e,t,n,r)}function l_(e){if(e instanceof Vc)return e;switch(e.termType){case"NamedNode":return Fae(e.value);case"BlankNode":return Cae(e.value);case"Variable":return Lae(e.value);case"DefaultGraph":return th;case"Literal":return Mae(e.value,e.language||e.datatype);case"Quad":return qae(e);default:throw Error(`Unexpected termType: ${e.termType}`)}}function qae(e){if(e instanceof jae)return e;if(e.termType!=="Quad")throw Error(`Unexpected termType: ${e.termType}`);return lC(l_(e.subject),l_(e.predicate),l_(e.object),l_(e.graph))}var _ae=0,p_=class e{constructor(t){this._contextStack=[],this._graph=null,t=t||{},this._setBase(t.baseIRI),t.factory&&Uae(this,t.factory);let n=typeof t.format=="string"?t.format.match(/\w*$/)[0].toLowerCase():"",r=/turtle/.test(n),i=/trig/.test(n),s=/triple/.test(n),o=/quad/.test(n),a=this._n3Mode=/n3/.test(n),l=s||o;this._emitCurrent=this._emit,a&&(this._createQuad=this._createQuadInDirection,this._emit=this._emitInDirection,this._emitCurrent=this._emitCurrentInDirection),(this._supportsNamedGraphs=!(r||a))||(this._readPredicateOrNamedGraph=this._readPredicate),this._supportsQuads=!(r||i||s||a),this._isImpliedBy=t.isImpliedBy,this._implicitEmptyPrefix=!!t.implicitEmptyPrefix,this._emptyFormulaAsTrue=!!t.emptyFormulaAsTrue,l&&(this._resolveRelativeIRI=(c)=>null),this._blankNodePrefix=typeof t.blankNodePrefix!="string"?"":t.blankNodePrefix.replace(/^(?!_:)/,"_:"),this._lexer=t.lexer||new vVe({lineMode:l,n3:a,isImpliedBy:this._isImpliedBy}),this._explicitQuantifiers=!!t.explicitQuantifiers,this._parseUnsupportedVersions=!!t.parseUnsupportedVersions,this._version=t.version}static _resetBlankNodePrefix(){_ae=0}_setBase(t){if(!t)this._base="",this._basePath="";else{let n=t.indexOf("#");n>=0&&(t=t.substr(0,n)),this._base=t,this._basePath=t.indexOf("/")<0?t:t.replace(/[^\/?]*(?:\?.*)?$/,""),t=t.match(/^(?:([a-z][a-z0-9+.-]*:))?(?:\/\/[^\/]*)?/i),this._baseRoot=t[0],this._baseScheme=t[1]}}_saveContext(t,n,r,i,s){if(!this._n3Mode){this._contextStack.push({type:t,subject:r,predicate:i,object:s,graph:n});return}let o={type:t,subject:r,predicate:i,object:s,graph:n,inverse:this._inversePredicate,expectOf:this._expectOf,blankPrefix:this._prefixes._,quantified:this._quantified,emptyFormula:this._emptyFormula};t==="formula"&&(o.prefixes=this._prefixes,o.base=[this._base,this._basePath,this._baseRoot,this._baseScheme],this._prefixes=Object.create(this._prefixes)),this._contextStack.push(o),this._inversePredicate=!1,this._expectOf=!1,this._prefixes._=this._graph?`${this._graph.value}.`:".",this._quantified=Object.create(this._quantified),t==="formula"&&(this._subject=null,this._emptyFormula=!0)}_restoreContext(t,n){let r=this._contextStack.pop();if(!r||r.type!==t)return this._error(`Unexpected ${n.type}`,n);this._subject=r.subject,this._predicate=r.predicate,this._object=r.object,this._graph=r.graph,this._n3Mode&&(this._inversePredicate=r.inverse,this._expectOf=r.expectOf,t==="formula"?(this._prefixes=r.prefixes,[this._base,this._basePath,this._baseRoot,this._baseScheme]=r.base):this._prefixes._=r.blankPrefix,this._quantified=r.quantified,this._emptyFormula=r.emptyFormula)}_readBeforeTopContext(t){return this._version&&!this._isValidVersion(this._version)?this._error(`Detected unsupported version as media type parameter: "${this._version}"`,t):this._readInTopContext(t)}_readInTopContext(t){switch(t.type){case"eof":return this._graph!==null?this._error("Unclosed graph",t):(delete this._prefixes._,this._callback(null,null,this._prefixes));case"PREFIX":this._sparqlStyle=!0;case"@prefix":return this._readPrefix;case"BASE":this._sparqlStyle=!0;case"@base":return this._readBaseIRI;case"VERSION":this._sparqlStyle=!0;case"@version":return this._readVersion;case"{":if(this._supportsNamedGraphs)return this._graph="",this._subject=null,this._readSubject;case"GRAPH":if(this._supportsNamedGraphs)return this._readNamedGraphLabel;default:return this._readSubject(t)}}_readInFormulaContext(t){switch(t.type){case"PREFIX":this._sparqlStyle=!0;case"@prefix":return this._readPrefix;case"BASE":this._sparqlStyle=!0;case"@base":return this._readBaseIRI;default:return this._readSubject(t)}}_getStatementReader(){let t=this._contextStack[this._contextStack.length-1];return t&&t.type==="formula"?this._readInFormulaContext:this._readInTopContext}_readEntity(t,n){let r;switch(t.type){case"IRI":case"typeIRI":let i=this._resolveIRI(t.value);if(i===null)return this._error("Invalid IRI",t);r=this._factory.namedNode(i);break;case"type":case"prefixed":let s=this._prefixes[t.prefix];if(s===void 0)return this._error(`Undefined prefix "${t.prefix}:"`,t);r=this._factory.namedNode(s+t.value);break;case"blank":r=this._factory.blankNode(this._prefixes[t.prefix]+t.value);break;case"var":r=this._factory.variable(t.value.substr(1));break;default:return this._error(`Expected entity but got ${t.type}`,t)}return!n&&this._n3Mode&&r.id in this._quantified&&(r=this._quantified[r.id]),r}_readList(t,n,r,i){let s=this._contextStack;return(s.length&&s[s.length-1]).type==="<<"?this._error("Unexpected list in reified triple",t):(this._saveContext("list",this._graph,n,r,i),this._subject=null,this._readListItem)}_readSubject(t){switch(this._predicate=null,t.type!=="}"&&(this._emptyFormula=!1),t.type){case"[":return this._saveContext("blank",this._graph,this._subject=this._factory.blankNode(),null,null),this._readBlankNodeHead;case"(":return this._readList(t,this.RDF_NIL,null,null);case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._graph=this._factory.blankNode(),null,null),this._readInFormulaContext):this._error("Unexpected graph",t);case"}":return this._readPunctuation(t);case"@forSome":return this._n3Mode?(this._subject=null,this._predicate=this.N3_FORSOME,this._quantifier="blankNode",this._readQuantifierList):this._error('Unexpected "@forSome"',t);case"@forAll":return this._n3Mode?(this._subject=null,this._predicate=this.N3_FORALL,this._quantifier="variable",this._readQuantifierList):this._error('Unexpected "@forAll"',t);case"literal":return this._n3Mode?t.prefix.length===0?(this._literalValue=t.value,this._completeSubjectLiteral):(this._subject=this._factory.literal(t.value,this._factory.namedNode(t.prefix)),this._getPathReader(this._readPredicateOrNamedGraph)):this._error("Unexpected literal",t);case"<<(":return this._n3Mode?(this._saveContext("<<(",this._graph,null,null,null),this._graph=null,this._readSubject):this._error("Disallowed triple term as subject",t);case"<<":return this._saveContext("<<",this._graph,null,null,null),this._graph=null,this._readSubject;default:if((this._subject=this._readEntity(t))===void 0)return;if(this._n3Mode)return this._getPathReader(this._readPredicateOrNamedGraph)}return this._readPredicateOrNamedGraph}_readPredicate(t){let n=t.type,r=!1;switch(n){case"inverse":this._inversePredicate=!0;case"abbreviation":this._predicate=this.ABBREVIATIONS[t.value];break;case"has":return this._readPredicateAfterVerb;case"is":return this._inversePredicate=!0,this._expectOf=!0,this._readPredicateAfterVerb;case"inversePredicate":return this._inversePredicate=!0,this._readPredicateAfterVerb;case".":case"]":case"}":case"|}":return this._predicate===null&&!this._n3Mode?this._error(`Unexpected ${n}`,t):(this._subject=null,n==="]"?this._readBlankNodeTail(t):this._readPunctuation(t));case";":return this._predicate!==null?this._readPredicate:this._error("Expected predicate but got ;",t);case"literal":if(!this._n3Mode)return this._error("Unexpected literal",t);if(t.prefix.length===0)return this._literalValue=t.value,this._completePredicateLiteral;this._predicate=this._factory.literal(t.value,this._factory.namedNode(t.prefix)),r=!0;break;case"(":return this._n3Mode?this._readList(t,this._subject,this.RDF_NIL,null):this._error(`Expected entity but got ${n}`,t);case"[":return this._n3Mode?(this._saveContext("blank",this._graph,this._subject,this._subject=this._factory.blankNode(),null),this._readBlankNodeHead):this._error("Disallowed blank node as predicate",t);case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._subject,this._graph=this._factory.blankNode(),null),this._readSubject):this._readEntity(t);case"blank":if(!this._n3Mode)return this._error("Disallowed blank node as predicate",t);default:if((this._predicate=this._readEntity(t))===void 0)return;r=this._n3Mode}return this._validAnnotation=!0,r?this._getPathReader(this._readObject,"predicate"):this._readObject}_readPredicateAfterVerb(t){return t.type==="has"||t.type==="is"||t.type==="of"||t.type==="inversePredicate"?this._error(`Expected expression but got ${t.type}`,t):this._readPredicate(t)}_readObject(t){if(this._expectOf)return t.type!=="of"?this._error(`Expected of but got ${t.type}`,t):(this._expectOf=!1,this._readObject);switch(t.type){case"literal":if(t.prefix.length===0)return this._literalValue=t.value,this._readDataTypeOrLang;if(this._object=this._factory.literal(t.value,this._factory.namedNode(t.prefix)),this._n3Mode)return this._getPathReader(this._getContextEndReader());break;case"[":return this._saveContext("blank",this._graph,this._subject,this._predicate,this._subject=this._factory.blankNode()),this._readBlankNodeHead;case"(":return this._readList(t,this._subject,this._predicate,this.RDF_NIL);case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._subject,this._predicate,this._graph=this._factory.blankNode()),this._readInFormulaContext):this._error("Unexpected graph",t);case"<<(":return this._saveContext("<<(",this._graph,this._subject,this._predicate,null),this._graph=null,this._readSubject;case"<<":return this._saveContext("<<",this._graph,this._subject,this._predicate,null),this._graph=null,this._readSubject;default:if((this._object=this._readEntity(t))===void 0)return;if(this._n3Mode)return this._getPathReader(this._getContextEndReader())}return this._getContextEndReader()}_readPredicateOrNamedGraph(t){return t.type==="{"?this._readGraph(t):this._readPredicate(t)}_readGraph(t){return t.type!=="{"?this._error(`Expected graph but got ${t.type}`,t):(this._graph=this._subject,this._subject=null,this._readSubject)}_readBlankNodeHead(t){if(t.type==="]")return this._subject=null,this._readBlankNodeTail(t);{let n=this._contextStack;return(n.length>1&&n[n.length-2]).type==="<<"?this._error("Unexpected compound blank node expression in reified triple",t):t.type==="id"?this._readIriPropertyListId:(this._predicate=null,this._readPredicate(t))}}_readIriPropertyListId(t){let n=this._readEntity(t);if(n===void 0)return;if(n.termType!=="NamedNode")return this._error(`Expected IRI after id but got ${t.type}`,t);let r=this._subject;this._subject=n;let i=this._contextStack[this._contextStack.length-1];return i.subject===r&&(i.subject=n),i.predicate===r&&(i.predicate=n),i.object===r&&(i.object=n),this._predicate=null,this._readIriPropertyListPredicate}_readIriPropertyListPredicate(t){return t.type===";"||t.type==="]"||t.type==="."||t.type==="}"?this._error(`Expected predicate but got ${t.type}`,t):this._readPredicate(t)}_readBlankNodeTail(t){if(t.type!=="]")return this._readBlankNodePunctuation(t);this._subject!==null&&this._emitCurrent(this._subject,this._predicate,this._object,this._graph);let n=this._predicate===null;return this._restoreContext("blank",t),this._object!==null?this._getContextEndReader():this._predicate!==null?this._getPathReader(this._readObject,"predicate"):n?this._readPredicateOrNamedGraph:this._readPredicateAfterBlank}_readPredicateAfterBlank(t){switch(t.type){case".":case"}":return this._subject=null,this._readPunctuation(t);default:return this._readPredicate(t)}}_readListItem(t){let n=null,r=null,i=this._readListItem,s=this._subject,o=this._contextStack,a=o[o.length-1];switch(t.type){case"[":this._saveContext("blank",this._graph,r=this._factory.blankNode(),this.RDF_FIRST,this._subject=n=this._factory.blankNode()),i=this._readBlankNodeHead;break;case"(":this._saveContext("list",this._graph,r=this._factory.blankNode(),this.RDF_FIRST,this.RDF_NIL),this._subject=null;break;case")":if(this._restoreContext("list",t),o.length!==0&&o[o.length-1].type==="list"){if(this._n3Mode)return s!==null&&this._emit(s,this.RDF_REST,this.RDF_NIL,this._graph),this._saveContext("item",this._graph,this._subject,this._predicate,this._object),this._subject=this._object,this._predicate=null,this._getPathReader(this._readListItem);this._emit(this._subject,this._predicate,this._object,this._graph)}if(this._predicate===null){if(i=this._n3Mode?this._getPathReader(this._readPredicate):this._readPredicate,this._subject===this.RDF_NIL)return i}else if(this._object===null){if(i=this._getPathReader(this._readObject,"predicate"),this._predicate===this.RDF_NIL)return i}else if(i=this._getContextEndReader(),this._n3Mode&&(i=this._getPathReader(i)),this._object===this.RDF_NIL)return i;r=this.RDF_NIL;break;case"literal":t.prefix.length===0?(this._literalValue=t.value,i=this._readListItemDataTypeOrLang):(n=this._factory.literal(t.value,this._factory.namedNode(t.prefix)),i=this._getContextEndReader());break;case"{":return this._n3Mode?(r=this._factory.blankNode(),n=this._factory.blankNode(),s===null?a.predicate===null?a.subject=r:a.object=r:this._emit(s,this.RDF_REST,r,this._graph),this._emit(r,this.RDF_FIRST,n,this._graph),this._saveContext("formula",this._graph,r,this.RDF_FIRST,this._graph=n),this._subject=null,this._readInFormulaContext):this._error("Unexpected graph",t);case"<<(":this._saveContext("<<(",this._graph,null,null,null),this._graph=null,i=this._readSubject;break;case"<<":this._saveContext("<<",this._graph,null,null,null),this._graph=null,i=this._readSubject;break;default:if((n=this._readEntity(t))===void 0)return}if(r===null&&(this._subject=r=this._factory.blankNode()),(t.type==="<<"||t.type==="<<(")&&(o[o.length-1].subject=this._subject),s===null?a.predicate===null?a.subject=r:a.object===null?a.predicate=r:a.object=r:this._emit(s,this.RDF_REST,r,this._graph),n!==null){if(this._n3Mode&&(t.type==="IRI"||t.type==="prefixed"||t.type==="var"||t.type==="blank"||t.type==="literal"))return this._saveContext("item",this._graph,r,this.RDF_FIRST,n),this._subject=n,this._predicate=null,this._getPathReader(this._readListItem);this._emit(r,this.RDF_FIRST,n,this._graph)}return i}_readDataTypeOrLang(t){return this._completeObjectLiteral(t,!1)}_readListItemDataTypeOrLang(t){return this._completeObjectLiteral(t,!0)}_completeLiteral(t,n){let r,i=!1;switch(t.type){case"type":case"typeIRI":let s=this._readEntity(t);if(s===void 0)return;if(s.value===br.rdf.langString||s.value===br.rdf.dirLangString)return this._error("Detected illegal (directional) languaged-tagged string with explicit datatype",t);r=this._factory.literal(this._literalValue,s),t=null;break;case"langcode":if(t.value.split("-").some((o)=>o.length>8))return this._error("Detected language tag with subtag longer than 8 characters",t);r=this._factory.literal(this._literalValue,t.value),this._literalLanguage=t.value,t=null,this._literalComponent=n,i=!0;break;default:r=this._factory.literal(this._literalValue)}return{token:t,literal:r,readCb:i}}_readDirCode(t){let n=this._literalComponent,r=this._literalListItem;if(t.type==="dircode"){let i=this._factory.literal(this._literalValue,{language:this._literalLanguage,direction:t.value});n==="subject"?this._subject=i:n==="predicate"?this._predicate=i:this._object=i,this._literalLanguage=void 0,t=null}if(n==="subject"||n==="predicate"){let i=n==="subject"?this._readPredicateOrNamedGraph:this._readObject;return this._getPathEndReader(t,i,n)||i.call(this,t)}return this._completeObjectLiteralPost(t,r)}_completeTermLiteral(t,n){let r=this._completeLiteral(t,n);if(!r)return;let i;if(n==="subject"?(this._subject=r.literal,i=this._readPredicateOrNamedGraph):(this._predicate=r.literal,this._validAnnotation=!0,i=this._readObject),r.readCb)return this._literalListItem=!1,this._readDirCode;return this._getPathEndReader(r.token,i,n)||i.call(this,r.token)}_completeSubjectLiteral(t){return this._completeTermLiteral(t,"subject")}_completePredicateLiteral(t){return this._completeTermLiteral(t,"predicate")}_completeObjectLiteral(t,n){let r=this._completeLiteral(t,"object");if(r)return this._object=r.literal,r.readCb?(this._literalListItem=n,this._readDirCode):this._completeObjectLiteralPost(r.token,n)}_completeObjectLiteralPost(t,n){return this._n3Mode&&(t===null||t.type==="!"||t.type==="^")?n?(this._saveContext("item",this._graph,this._subject,this.RDF_FIRST,this._object),this._subject=this._object,this._predicate=null,this._getPathEndReader(t,this._readListItem)):this._getPathEndReader(t,this._getContextEndReader()):(n&&this._emit(this._subject,this.RDF_FIRST,this._object,this._graph),t===null?this._getContextEndReader():(this._readCallback=this._getContextEndReader(),this._readCallback(t)))}_readFormulaTail(t){if(t.type!=="}")return this._readPunctuation(t);this._subject!==null&&this._emitCurrent(this._subject,this._predicate,this._object,this._graph);let n=this._graph,r=this._emptyFormula;return this._restoreContext("formula",t),r&&this._emptyFormulaAsTrue&&(this._subject===n?this._subject=this.N3_TRUE:this._predicate===n?this._predicate=this.N3_TRUE:this._object=this.N3_TRUE),this._object!==null?this._getPathReader(this._getContextEndReader(),"object"):this._predicate!==null?this._getPathReader(this._readObject,"predicate"):this._getPathReader(this._readPredicate,"subject")}_readPunctuation(t){let n,r=this._graph,i=!1,s=this._subject,o=this._inversePredicate;switch(t.type){case"}":if(this._graph===null)return this._error("Unexpected graph closing",t);if(this._n3Mode)return this._readFormulaTail(t);this._graph=null;case".":this._subject=null,this._tripleTerm=null,n=this._getStatementReader(),o&&(this._inversePredicate=!1);break;case";":o&&(this._inversePredicate=!1),n=this._readPredicate;break;case",":n=this._readObject;break;case"~":s!==null&&(this._tripleTerm=null),n=this._readReifierInAnnotation,i=!0;break;case"{|":s!==null&&(this._tripleTerm=null),this._subject=this._readTripleTerm(),this._inversePredicate=!1,this._validAnnotation=!1,i=!0,n=this._readPredicate;break;case"|}":if(!this._annotation)return this._error("Unexpected annotation syntax closing",t);if(!this._validAnnotation)return this._error("Annotation block can not be empty",t);this._subject=null,this._annotation=!1,this._inversePredicate=!1,n=this._getContextEndReader();break;default:if(this._supportsQuads&&this._graph===null&&(r=this._readEntity(t))!==void 0){n=this._readQuadPunctuation;break}return this._error(`Expected punctuation to follow "${this._object.id}"`,t)}if(s!==null&&(!i||i&&!this._annotation)){let a=this._predicate,l=this._object;this._emit(s,a,l,r,o)}return i&&(this._annotation=!0),n}_readBlankNodePunctuation(t){let n,r=!1;switch(t.type){case";":r=this._inversePredicate,n=this._readPredicate;break;case",":n=this._readObject;break;case"~":case"{|":case"|}":return this._readPunctuation(t);default:return this._error(`Expected punctuation to follow "${this._object.id}"`,t)}return this._subject===null?this._error("Expected ] to follow annotation",t):(this._emitCurrent(this._subject,this._predicate,this._object,this._graph),r&&(this._inversePredicate=!1),n)}_readQuadPunctuation(t){return t.type!=="."?this._error("Expected dot to follow quad",t):this._readInTopContext}_readPrefix(t){return t.type!=="prefix"?this._error("Expected prefix to follow @prefix",t):(this._prefix=t.value,this._readPrefixIRI)}_readPrefixIRI(t){if(t.type!=="IRI")return this._error(`Expected IRI to follow prefix "${this._prefix}:"`,t);let n=this._readEntity(t);return this._prefixes[this._prefix]=n.value,this._prefixCallback(this._prefix,n),this._readDeclarationPunctuation}_readBaseIRI(t){let n=t.type==="IRI"&&this._resolveIRI(t.value);return n?(this._setBase(n),this._readDeclarationPunctuation):this._error("Expected valid IRI to follow base declaration",t)}_isValidVersion(t){return this._parseUnsupportedVersions||e.SUPPORTED_VERSIONS.includes(t)}_readVersion(t){return t.type!=="literal"?this._error("Expected literal to follow version declaration",t):t.end-t.start!==t.value.length+2?this._error("Version declarations must use single quotes",t):(this._versionCallback(t.value),this._isValidVersion(t.value)?this._readDeclarationPunctuation:this._error(`Detected unsupported version: "${t.value}"`,t))}_readNamedGraphLabel(t){switch(t.type){case"IRI":case"blank":case"prefixed":return this._readSubject(t),this._readGraph;case"[":return this._readNamedGraphBlankLabel;default:return this._error("Invalid graph label",t)}}_readNamedGraphBlankLabel(t){return t.type!=="]"?this._error("Invalid graph label",t):(this._subject=this._factory.blankNode(),this._readGraph)}_readDeclarationPunctuation(t){return this._sparqlStyle?(this._sparqlStyle=!1,this._getStatementReader().call(this,t)):t.type!=="."?this._error("Expected declaration to end with a dot",t):this._getStatementReader()}_readQuantifierList(t){let n;switch(t.type){case"IRI":case"prefixed":if((n=this._readEntity(t,!0))!==void 0)break;default:return this._error(`Unexpected ${t.type}`,t)}return this._explicitQuantifiers?(this._subject===null?this._emit(this._graph||this.DEFAULTGRAPH,this._predicate,this._subject=this._factory.blankNode(),this.QUANTIFIERS_GRAPH):this._emit(this._subject,this.RDF_REST,this._subject=this._factory.blankNode(),this.QUANTIFIERS_GRAPH),this._emit(this._subject,this.RDF_FIRST,n,this.QUANTIFIERS_GRAPH)):this._quantified[n.id]=this._factory[this._quantifier](this._factory.blankNode().value),this._readQuantifierPunctuation}_readQuantifierPunctuation(t){return t.type===","?this._readQuantifierList:(this._explicitQuantifiers&&(this._emit(this._subject,this.RDF_REST,this.RDF_NIL,this.QUANTIFIERS_GRAPH),this._subject=null),this._readCallback=this._getContextEndReader(),this._readCallback(t))}_getPathReader(t,n){return this._afterPath=t,this._pathPosition=n||(this._predicate===null?"subject":"object"),this._readPath}_getPathEndReader(t,n,r){if(t!==null&&t.type!=="!"&&t.type!=="^")return null;let i=this._getPathReader(n,r);return t===null?i:i.call(this,t)}_readPath(t){switch(t.type){case"!":return this._readForwardPath;case"^":return this._readBackwardPath;default:let n=this._afterPath,r=this._contextStack,i=r.length&&r[r.length-1];if(i&&i.type==="item"){let s=this._subject;this._restoreContext("item",t),this._emit(this._subject,this.RDF_FIRST,s,this._graph)}return this._afterPath=null,this._pathPosition=null,n.call(this,t)}}_readForwardPath(t){let n,r,i=this._factory.blankNode();if((r=this._readEntity(t))!==void 0)return this._pathPosition==="subject"?(n=this._subject,this._subject=i):this._pathPosition==="predicate"?(n=this._predicate,this._predicate=i):(n=this._object,this._object=i),this._emit(n,r,i,this._graph),this._readPath}_readBackwardPath(t){let n=this._factory.blankNode(),r,i;if((r=this._readEntity(t))!==void 0)return this._pathPosition==="subject"?(i=this._subject,this._subject=n):this._pathPosition==="predicate"?(i=this._predicate,this._predicate=n):(i=this._object,this._object=n),this._emit(n,r,i,this._graph),this._readPath}_readTripleTermTail(t){if(t.type!==")>>")return this._error(`Expected )>> but got ${t.type}`,t);let n=this._createQuad(this._subject,this._predicate,this._object,this._graph,this._inversePredicate);this._restoreContext("<<(",t);let r=this._contextStack,i=r.length&&r[r.length-1];return i&&i.type==="list"?(this._emit(this._subject,this.RDF_FIRST,n,this._graph),this._getContextEndReader()):this._subject===null?(this._subject=n,this._readPredicate):(this._object=n,this._getContextEndReader())}_readReifiedTripleTailOrReifier(t){return t.type==="~"?this._readReifier:this._readReifiedTripleTail(t)}_readReifiedTripleTail(t){if(t.type!==">>")return this._error(`Expected >> but got ${t.type}`,t);this._tripleTerm=null;let n=this._readTripleTerm();this._restoreContext("<<",t);let r=this._contextStack,i=r.length&&r[r.length-1];return i&&i.type==="list"?(this._emit(this._subject,this.RDF_FIRST,n,this._graph),this._getContextEndReader()):this._subject===null?(this._subject=n,this._readPredicateOrReifierTripleEnd):(this._object=n,this._getContextEndReader())}_readPredicateOrReifierTripleEnd(t){return t.type==="."?(this._subject=null,this._readPunctuation(t)):this._readPredicate(t)}_readReifier(t){return this._reifier=this._readEntity(t),this._readReifiedTripleTail}_readReifierInAnnotation(t){return t.type==="IRI"||t.type==="typeIRI"||t.type==="type"||t.type==="prefixed"||t.type==="blank"||t.type==="var"?(this._reifier=this._readEntity(t),this._readAnnotationBlockOrPunctuation):(this._readTripleTerm(),this._subject=null,this._getContextEndReader().call(this,t))}_readAnnotationBlockOrPunctuation(t){if(t.type==="{|")return this._readPunctuation(t);switch(this._readTripleTerm(),this._annotation=!1,this._tripleTerm=null,t.type){case";":return this._inversePredicate=!1,this._readPredicate;case",":return this._readObject;default:return this._subject=null,this._getContextEndReader().call(this,t)}}_readTripleTerm(){let t=this._contextStack,n=t.length&&t[t.length-1],r=n?n.graph:void 0,i=this._reifier||this._factory.blankNode();return this._reifier=null,this._tripleTerm=this._tripleTerm||this._createQuad(this._subject,this._predicate,this._object,null,this._inversePredicate),this._emit(i,this.RDF_REIFIES,this._tripleTerm,r||this._graph||this.DEFAULTGRAPH),i}_getContextEndReader(){let t=this._contextStack;if(!t.length)return this._readPunctuation;switch(t[t.length-1].type){case"blank":return this._readBlankNodeTail;case"list":return this._readListItem;case"formula":return this._readFormulaTail;case"<<(":return this._readTripleTermTail;case"<<":return this._readReifiedTripleTailOrReifier}}_createQuad(t,n,r,i){return this._factory.quad(t,n,r,i||this.DEFAULTGRAPH)}_createQuadInDirection(t,n,r,i,s){return s?this._factory.quad(r,n,t,i||this.DEFAULTGRAPH):this._factory.quad(t,n,r,i||this.DEFAULTGRAPH)}_emitInDirection(t,n,r,i,s){this._callback(null,this._createQuad(t,n,r,i,s))}_emitCurrentInDirection(t,n,r,i){this._callback(null,this._createQuad(t,n,r,i,this._inversePredicate))}_emit(t,n,r,i){this._callback(null,this._factory.quad(t,n,r,i||this.DEFAULTGRAPH))}_error(t,n){let r=` on line ${n.line}.`;t.length+r.length>200&&(t=`${t.slice(0,199-r.length)}…`);let i=Error(`${t}${r}`);i.context={token:n,line:n.line,previousToken:this._lexer.previousToken},this._callback(i),this._callback=r_}_resolveIRI(t){return/^[a-z][a-z0-9+.-]*:/i.test(t)?t:this._resolveRelativeIRI(t)}_resolveRelativeIRI(t){if(!t.length)return this._base;switch(t[0]){case"#":return this._base+t;case"?":return this._base.replace(/(?:\?.*)?$/,t);case"/":return(t[1]==="/"?this._baseScheme:this._baseRoot)+this._removeDotSegments(t);default:return/^[^/:]*:/.test(t)?null:this._removeDotSegments(this._basePath+t)}}_removeDotSegments(t){if(!/(^|\/)\.\.?($|[/#?])/.test(t))return t;let n=t.length,r="",i=-1,s=-1,o=0,a="/";for(;i=s&&(r=r.substr(0,o)),a!=="/")return`${r}/${t.substr(i+1)}`;o=i+1}}}a=t[++i]}return r+t.substring(o)}parse(t,n,r,i){let s,o,a,l;if(n&&(n.onQuad||n.onPrefix||n.onComment||n.onVersion)?(s=n.onQuad,o=n.onPrefix,a=n.onComment,l=n.onVersion):(s=n,o=r,l=i),this._readCallback=this._readBeforeTopContext,this._sparqlStyle=!1,this._prefixes=Object.create(null),this._prefixes._=this._blankNodePrefix?this._blankNodePrefix.substr(2):`b${_ae++}_`,this._n3Mode&&this._implicitEmptyPrefix&&this._base&&(this._prefixes[""]=this._resolveIRI("#")),this._prefixCallback=o||r_,this._versionCallback=l||r_,this._inversePredicate=!1,this._expectOf=!1,this._quantified=Object.create(null),this._emptyFormula=!1,!s){let u=[],p;if(this._callback=(d,f)=>{d?p=d:f&&u.push(f)},this._lexer.tokenize(t).every((d)=>this._readCallback=this._readCallback(d)),p)throw p;return u}let c=(u,p)=>{u!==null?(this._callback(u),this._callback=r_):this._readCallback&&(this._readCallback=this._readCallback(p))};a&&(this._lexer.comments=!0,c=(u,p)=>{u!==null?(this._callback(u),this._callback=r_):this._readCallback&&(p.type==="comment"?a(p.value):this._readCallback=this._readCallback(p))}),this._callback=s,this._lexer.tokenize(t,c)}};function r_(){}function Uae(e,t){e._factory=t,e.DEFAULTGRAPH=t.defaultGraph(),e.RDF_FIRST=t.namedNode(br.rdf.first),e.RDF_REST=t.namedNode(br.rdf.rest),e.RDF_NIL=t.namedNode(br.rdf.nil),e.RDF_REIFIES=t.namedNode(br.rdf.reifies),e.N3_FORALL=t.namedNode(br.r.forAll),e.N3_FORSOME=t.namedNode(br.r.forSome),e.N3_TRUE=t.literal("true",t.namedNode(br.xsd.boolean)),e.ABBREVIATIONS={a:t.namedNode(br.rdf.type),"=":t.namedNode(br.owl.sameAs),">":t.namedNode(br.log.implies),"<":t.namedNode(br.log.isImpliedBy)},e.QUANTIFIERS_GRAPH=t.namedNode("urn:n3:quantifiers")}p_.SUPPORTED_VERSIONS=["1.2","1.2-basic","1.1"];Uae(p_.prototype,ss);var SVe={};rVe(SVe,{inDefaultGraph:()=>$Ve,isBlankNode:()=>kVe,isDefaultGraph:()=>xf,isLiteral:()=>NVe,isNamedNode:()=>EVe,isQuad:()=>PVe,isVariable:()=>OVe,prefix:()=>IVe,prefixes:()=>Bae});function EVe(e){return!!e&&e.termType==="NamedNode"}function kVe(e){return!!e&&e.termType==="BlankNode"}function NVe(e){return!!e&&e.termType==="Literal"}function OVe(e){return!!e&&e.termType==="Variable"}function PVe(e){return!!e&&e.termType==="Quad"}function xf(e){return!!e&&e.termType==="DefaultGraph"}function $Ve(e){return xf(e.graph)}function IVe(e,t){return Bae({"":e.value||e},t)("")}function Bae(e,t){let n=Object.create(null);for(let i in e)r(i,e[i]);t=t||ss;function r(i,s){if(typeof s=="string"){let o=Object.create(null);n[i]=(a)=>o[a]||(o[a]=t.namedNode(s+a))}else if(!(i in n))throw Error(`Unknown prefix: ${i}`);return n[i]}return r}function XS(e){return e.replace(/[\]\/\(\)\*\+\?\.\\\$]/g,"\\$&")}var AVe=/^:?[^:?#]*(?:[?#]|$)|^file:|^[^:]*:\/*[^?#]+?\/(?:\.\.?(?:\/|$)|\/)/i,RVe=/^(?:(?:[^/?#]{3,}|\.?[^/?#.]\.?)(?:\/[^/?#]{3,}|\.?[^/?#.]\.?)*\/?)?(?:[?#]|$)/,xae="./",jVe="../",sC="?",wae="#",FVe=class e{constructor(t){this.base=t,this._baseLength=0,this._baseMatcher=null,this._pathReplacements=Array(t.length+1)}static supports(t){return!AVe.test(t)}_getBaseMatcher(){if(this._baseMatcher)return this._baseMatcher;if(!e.supports(this.base))return this._baseMatcher=/.^/;let t=/^[^:]*:\/*/.exec(this.base)[0],n=["^",XS(t)],r=[],i=[],s=/[^/?#]*([/?#])/y,o,a=0,l=0,c=s.lastIndex=t.length;for(;!a&&!l&&(o=s.exec(this.base));)o[1]===wae?l=s.lastIndex-1:(n.push(XS(o[0]),"(?:"),r.push(")?"),o[1]!==sC?i.push(c=s.lastIndex):(a=c=s.lastIndex,l=this.base.indexOf(wae,a),this._pathReplacements[a]=sC));for(let u=0;u0?l:this.base.length,n.push(XS(this.base.substring(c,this._baseLength)),a?"(?:#|$)":"(?:[?#]|$)"),this._baseMatcher=new RegExp([...n,...r].join(""))}toRelative(t){let n=this._getBaseMatcher().exec(t);if(!n)return t;let r=n[0].length;if(r===this._baseLength&&r===t.length)return"";let i=this._pathReplacements[r];if(i){let s=t.substring(r);return i!==sC&&!RVe.test(s)?t:i===xae&&/^[^?#]/.test(s)?s:i+s}return t.substring(r-1)}},i_=ss.defaultGraph(),{rdf:CVe,xsd:Wy}=br,Dae=/["\\\t\n\r\b\f\u0000-\u0019\ud800-\udbff]/,Tae=/["\\\t\n\r\b\f\u0000-\u0019]|[\ud800-\udbff][\udc00-\udfff]/g,MVe={"\\":"\\\\",'"':"\\\"","\t":"\\t","\n":"\\n","\r":"\\r","\b":"\\b","\f":"\\f"},s_=class extends Vc{equals(e){return e===this}},d_=class{constructor(e,t){if(this._prefixRegex=/$0^/,this._hasPrefixes=!1,e&&typeof e.write!="function"&&(t=e,e=null),t=t||{},this._lists=t.lists,e)this._outputStream=e,this._endStream=t.end===void 0?!0:!!t.end;else{let n="";this._outputStream={write(r,i,s){n+=r,s&&s()},end:(r)=>{r&&r(null,n)}},this._endStream=!0}this._subject=null,/triple|quad/i.test(t.format)?(this._lineMode=!0,this._writeQuad=this._writeQuadLine):(this._lineMode=!1,this._graph=i_,this._prefixIRIs=Object.create(null),t.baseIRI&&(this._baseIri=new FVe(t.baseIRI),t.writeBase&&this._write(`@base <${t.baseIRI}>. +Enum bindings allow enums to be bound to any object, including complex nested objects. For example, given a (generic) class Concept with slots id and label, it may be desirable to restrict the values the id takes on in a given context. For example, a HumanSample class may have a slot for representing sample site, with a range of concept, but the values of that slot may be restricted to concepts from a particular branch of an anatomy ontology.`,items:{$ref:"#/$defs/EnumBinding"},type:["array","null"]},broad_mappings:{description:"A list of terms from different schemas or terminology systems that have broader meaning.",items:{type:"string"},type:["array","null"]},categories:{description:"Controlled terms used to categorize an element.",items:{type:"string"},type:["array","null"]},classes:{additionalProperties:{anyOf:[{$ref:"#/$defs/ClassDefinition__identifier_optional"},{type:"null"}]},description:"An index to the collection of all class definitions in the schema",type:["object","null"]},close_mappings:{description:"A list of terms from different schemas or terminology systems that have close meaning.",items:{type:"string"},type:["array","null"]},comments:{description:"notes and comments about an element intended primarily for external consumption",items:{type:"string"},type:["array","null"]},conforms_to:{description:"An established standard to which the element conforms.",type:["string","null"]},contributors:{description:"agent that contributed to the element",items:{type:"string"},type:["array","null"]},created_by:{description:"agent that created the element",type:["string","null"]},created_on:{description:"time at which the element was created",format:"date-time",type:["string","null"]},default_curi_maps:{description:"ordered list of prefixcommon biocontexts to be fetched to resolve id prefixes and inline prefix variables",items:{type:"string"},type:["array","null"]},default_prefix:{description:"The prefix that is used for all elements within a schema",type:["string","null"]},default_range:{description:"default slot range to be used if range element is omitted from a slot definition",type:["string","null"]},definition_uri:{description:"The native URI of the element. This is always within the namespace of the containing schema. Contrast with the assigned URI, via class_uri or slot_uri",type:["string","null"]},deprecated:{description:"Description of why and when this element will no longer be used",type:["string","null"]},deprecated_element_has_exact_replacement:{description:"When an element is deprecated, it can be automatically replaced by this uri or curie",type:["string","null"]},deprecated_element_has_possible_replacement:{description:"When an element is deprecated, it can be potentially replaced by this uri or curie",type:["string","null"]},description:{description:"a textual description of the element's purpose and use",type:["string","null"]},emit_prefixes:{description:"a list of Curie prefixes that are used in the representation of instances of the model. All prefixes in this list are added to the prefix sections of the target models.",items:{pattern:"^[a-zA-Z_][\\w.-]*$",type:"string"},type:["array","null"]},enums:{additionalProperties:{anyOf:[{$ref:"#/$defs/EnumDefinition__identifier_optional"},{type:"null"}]},description:"An index to the collection of all enum definitions in the schema",type:["object","null"]},exact_mappings:{description:"A list of terms from different schemas or terminology systems that have identical meaning.",items:{type:"string"},type:["array","null"]},examples:{description:"example usages of an element",items:{$ref:"#/$defs/Example"},type:["array","null"]},extensions:{additionalProperties:{anyOf:[{$ref:"#/$defs/Extension__identifier_optional"},{$ref:"#/$defs/AnyValue",description:"the actual annotation"}]},description:"a tag/text tuple attached to an arbitrary element",type:["object","null"]},from_schema:{description:"id of the schema that defined the element",format:"uri",type:["string","null"]},generation_date:{description:"date and time that the schema was loaded/generated",format:"date-time",type:["string","null"]},id:{description:"The official schema URI",format:"uri",type:"string"},id_prefixes:{description:"An allowed list of prefixes for which identifiers must conform. The identifier of this class or slot must begin with the URIs referenced by this prefix",items:{pattern:"^[a-zA-Z_][\\w.-]*$",type:"string"},type:["array","null"]},id_prefixes_are_closed:{description:"If true, then the id_prefixes slot is treated as being closed, and any use of an id that does not have this prefix is considered a violation.",type:["boolean","null"]},implements:{description:"An element in another schema which this element conforms to. The referenced element is not imported into the schema for the implementing element. However, the referenced schema may be used to check conformance of the implementing element.",items:{type:"string"},type:["array","null"]},imported_from:{description:"the imports entry that this element was derived from. Empty means primary source",type:["string","null"]},imports:{description:"A list of schemas that are to be included in this schema",items:{type:"string"},type:["array","null"]},in_language:{description:"the primary language used in the sources",type:["string","null"]},in_subset:{description:"used to indicate membership of a term in a defined subset of terms used for a particular domain or application.",items:{type:"string"},type:["array","null"]},instantiates:{description:"An element in another schema which this element instantiates.",items:{type:"string"},type:["array","null"]},keywords:{description:"Keywords or tags used to describe the element",items:{type:"string"},type:["array","null"]},last_updated_on:{description:"time at which the element was last updated",format:"date-time",type:["string","null"]},license:{description:"license for the schema",type:["string","null"]},local_names:{additionalProperties:{anyOf:[{$ref:"#/$defs/LocalName__identifier_optional"},{description:"a name assigned to an element in a given ontology",type:"string"}]},type:["object","null"]},mappings:{description:"A list of terms from different schemas or terminology systems that have comparable meaning. These may include terms that are precisely equivalent, broader or narrower in meaning, or otherwise semantically related but not equivalent from a strict ontological perspective.",items:{type:"string"},type:["array","null"]},metamodel_version:{description:"Version of the metamodel used to load the schema",type:["string","null"]},modified_by:{description:"agent that modified the element",type:["string","null"]},name:{description:"a unique name for the schema that is both human-readable and consists of only characters from the NCName set",pattern:"^[a-zA-Z_][\\w.-]*$",type:"string"},narrow_mappings:{description:"A list of terms from different schemas or terminology systems that have narrower meaning.",items:{type:"string"},type:["array","null"]},notes:{description:"editorial notes about an element intended primarily for internal consumption",items:{type:"string"},type:["array","null"]},prefixes:{additionalProperties:{anyOf:[{$ref:"#/$defs/Prefix__identifier_optional"},{description:"The namespace to which a prefix expands to.",format:"uri",type:"string"}]},description:"A collection of prefix expansions that specify how CURIEs can be expanded to URIs",type:["object","null"]},rank:{description:"the relative order in which the element occurs, lower values are given precedence",type:["integer","null"]},related_mappings:{description:"A list of terms from different schemas or terminology systems that have related meaning.",items:{type:"string"},type:["array","null"]},see_also:{description:"A list of related entities or URLs that may be of relevance",items:{type:"string"},type:["array","null"]},settings:{additionalProperties:{anyOf:[{$ref:"#/$defs/Setting__identifier_optional"},{description:"The value assigned for a setting",type:"string"}]},description:"A collection of global variable settings",type:["object","null"]},slot_names_unique:{description:"if true then induced/mangled slot names are not created for class_usage and attributes",type:["boolean","null"]},slots:{additionalProperties:{anyOf:[{$ref:"#/$defs/SlotDefinition__identifier_optional"},{type:"null"}]},description:"An index to the collection of all slot definitions in the schema",type:["object","null"]},source:{description:"A related resource from which the element is derived.",type:["string","null"]},source_file:{description:"name, uri or description of the source of the schema",type:["string","null"]},source_file_date:{description:"modification date of the source of the schema",format:"date-time",type:["string","null"]},source_file_size:{description:"size in bytes of the source of the schema",type:["integer","null"]},status:{description:"status of the element",type:["string","null"]},structured_aliases:{description:"A list of structured_alias objects, used to provide aliases in conjunction with additional metadata.",items:{$ref:"#/$defs/StructuredAlias"},type:["array","null"]},subsets:{additionalProperties:{anyOf:[{$ref:"#/$defs/SubsetDefinition__identifier_optional"},{type:"null"}]},description:"An index to the collection of all subset definitions in the schema",type:["object","null"]},title:{description:"A concise human-readable display label for the element. The title should mirror the name, and should use ordinary textual punctuation.",type:["string","null"]},todos:{description:"Outstanding issues that needs resolution",items:{type:"string"},type:["array","null"]},types:{additionalProperties:{anyOf:[{$ref:"#/$defs/TypeDefinition__identifier_optional"},{type:"null"}]},description:"An index to the collection of all type definitions in the schema",type:["object","null"]},version:{description:"particular version of schema",type:["string","null"]}},required:["id","name"],title:"meta",type:"object",version:null};var Gie="umf.linkml",C3e=jie,Wie=(e,t)=>t==="json"?Jt(e):Wa(e,{version:"1.1",dateOnly:"string",booleanLexicon:"pyyaml"}),Hie=new Map;function M3e(e){let t=e,n=[{code:"LINKML_CONTEXT",path:"",severity:"warning",message:"YAML 1.1 date-only scalars become lexical strings in the JSON tree; their original spelling remains archived. Metamodel shape checks do not resolve imports, induce classes/slots, normalize defaults, validate instances or run generators; JS numeric precision limits apply and edits regenerate layout with original source retained"}],r=(a,l,c,u="warning")=>n.push({code:a,path:l,message:c,severity:u});if(Object.keys(t).some((a)=>!["profile","metamodelVersion","root","originalSource","originalFormat"].includes(a)))r("LINKML_REPRESENTATION","","Unknown representation fields remain in UMF");function i(a,l){let c=a.kind==="null"?["kind"]:a.kind==="array"?["kind","items"]:a.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(a).some((u)=>!c.includes(u)))r("LINKML_REPRESENTATION",l,"Unknown tagged-tree fields remain in UMF");if(a.kind==="object")for(let[u,p]of Object.entries(a.members))i(p,l+"/"+$e(u));if(a.kind==="array")a.items.forEach((u,p)=>i(u,l+"/"+p))}if(i(t.root,""),t.root.kind!=="object")return r("LINKML_STRUCTURE","","Expected LINKML contract object","error"),n;try{Wie(t.originalSource,t.originalFormat)}catch(a){return r("LINKML_ARCHIVE","/originalSource",String(a),"error"),n}let s=t.root.members.metamodel_version;if(t.metamodelVersion!=="1.11.0"||s&&!(s.kind==="string"&&s.value===t.metamodelVersion))return r("LINKML_VERSION","/metamodel_version","Unrecognized or conflicting metamodel version preserved without interpretation"),n;let o=Hie.get("1.11.0");if(!o){let a=new zie.default({allErrors:!0,strict:!1,validateFormats:!1,ownProperties:!0});zp(a),o=a.compile(Jie),Hie.set("1.11.0",o)}if(!o(JSON.parse(Be(t.root))))for(let a of(o.errors??[]).slice(0,100))r("LINKML_NATIVE_SCHEMA",a.instancePath,a.message??"Native metamodel shape mismatch");if((o.errors?.length??0)>100)r("LINKML_DIAGNOSTICS_TRUNCATED","","More than 100 native schema diagnostics; first 100 retained");return n}function L3e(){return new nt().register(C3e,M3e)}function Qie(e){return We(e,L3e())}function q3e(e){let t=Qie(e);if(!t.valid)throw new U("LINKML_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[Gie];if(!n||e.vocabularies[Gie]?.version!=="0.1.0")throw new U("LINKML_PAYLOAD","Expected pinned LINKML payload");return Ae(n)}function Yie(e,t){let n=q3e(e);if(t!==void 0&&!["json","yaml"].includes(t))throw new U("LINKML_FORMAT","Unsupported native format");if(Qie(e).diagnostics.some((r)=>r.code==="LINKML_REPRESENTATION"))throw new U("LINKML_EXPORT","Unknown representation fields cannot be discarded");if((t??n.originalFormat)===n.originalFormat&&Be(Wie(n.originalSource,n.originalFormat))===Be(n.root))return n.originalSource;return Be(n.root)+` +`}var Xie={id:"umf.odcs",version:"0.1.0",coreVersion:"0.1.0",description:"ODCS source contracts, native schema shapes and copied candidates",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:odcs:0.1.0",type:"object",properties:{profile:{const:"odcs-json-yaml"},root:{$ref:"#/$defs/node"},originalSource:{type:"string",maxLength:4000000},originalFormat:{enum:["json","yaml"]}},required:["profile","root","originalSource","originalFormat"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-023; preserve exact source and unknown values; native shape validity does not enforce a data contract",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Open Data Contract Standard",version:"3.0.0/3.0.1/3.0.2/3.1.0/3.2.0 schemas at f0bdad95346905d500be5ef4b2c2d9b1d95223b7",subset:"JSON/YAML preservation and native shapes; local v3.2.0 reference/relationship checks and ID-selected rename candidates; no external resolution, quality/SLA execution or physical lowering"},evidence:["tests/odcs/odcs.test.ts","fixtures/odcs/oracle-results.json","fixtures/odcs/browser-results.json","tests/odcs/references.test.ts","tests/odcs/relationships.test.ts","tests/odcs/rename.test.ts","fixtures/odcs/rename/oracle-results.json","fixtures/odcs/rename/browser-results.json"]}};var ase=Rr(bF(),1);var Zie={$schema:"https://json-schema.org/draft/2019-09/schema",title:"Open Data Contract Standard (ODCS)",description:"An open data contract specification to establish agreement between data producers and consumers.",type:"object",properties:{version:{type:"string",description:"Current version of the data contract."},kind:{type:"string",default:"DataContract",description:"The kind of file this is. Valid value is `DataContract`.",enum:["DataContract"]},apiVersion:{type:"string",default:"v3.0.0",description:"Version of the standard used to build data contract. Default value is v3.0.0.",enum:["v3.0.0","v2.2.2","v2.2.1","v2.2.0"]},id:{type:"string",description:"A unique identifier used to reduce the risk of dataset name collisions, such as a UUID."},name:{type:"string",description:"Name of the data contract."},tenant:{type:"string",description:"Indicates the property the data is primarily associated with. Value is case insensitive."},tags:{$ref:"#/$defs/Tags"},status:{type:"string",description:"Current status of the dataset. Valid values are `production`, `test`, or `development`.",examples:["production","test","development"]},servers:{type:"array",description:"List of servers where the datasets reside.",items:{$ref:"#/$defs/Server"}},dataProduct:{type:"string",description:"The name of the data product."},description:{type:"object",description:"High level description of the dataset.",properties:{usage:{type:"string",description:"Intended usage of the dataset."},purpose:{type:"string",description:"Purpose of the dataset."},limitations:{type:"string",description:"Limitations of the dataset."}}},domain:{type:"string",description:"Name of the logical data domain.",examples:["imdb_ds_aggregate","receiver_profile_out","transaction_profile_out"]},schema:{type:"array",description:"A list of elements within the schema to be cataloged.",items:{$ref:"#/$defs/SchemaObject"}},support:{$ref:"#/$defs/Support"},price:{$ref:"#/$defs/Pricing"},team:{type:"array",items:{$ref:"#/$defs/Team"}},roles:{type:"array",description:"A list of roles that will provide user access to the dataset.",items:{$ref:"#/$defs/Role"}},slaDefaultElement:{type:"string",description:"Element (using the element path notation) to do the checks on."},slaProperties:{type:"array",description:"A list of key/value pairs for SLA specific properties. There is no limit on the type of properties (more details to come).",items:{$ref:"#/$defs/ServiceLevelAgreementProperty"}},customProperties:{$ref:"#/$defs/CustomProperties"},contractCreatedTs:{type:"string",format:"date-time",description:"Timestamp in UTC of when the data contract was created."}},required:["version","apiVersion","kind","id","status"],additionalProperties:!1,$defs:{Server:{type:"object",description:"Data source details of where data is physically stored.",properties:{server:{type:"string",description:"Identifier of the server."},type:{type:"string",description:"Type of the server.",enum:["api","athena","azure","bigquery","clickhouse","databricks","denodo","dremio","duckdb","glue","cloudsql","db2","informix","kafka","kinesis","local","mysql","oracle","postgresql","postgres","presto","pubsub","redshift","s3","sftp","snowflake","sqlserver","synapse","trino","vertica","custom"]},description:{type:"string",description:"Description of the server."},environment:{type:"string",description:"Environment of the server.",examples:["prod","preprod","dev","uat"]},roles:{type:"array",description:"List of roles that have access to the server.",items:{$ref:"#/$defs/Role"}},customProperties:{$ref:"#/$defs/CustomProperties"}},allOf:[{if:{properties:{type:{const:"api"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ApiServer"}},{if:{properties:{type:{const:"athena"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AthenaServer"}},{if:{properties:{type:{const:"azure"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AzureServer"}},{if:{properties:{type:{const:"bigquery"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/BigQueryServer"}},{if:{properties:{type:{const:"clickhouse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ClickHouseServer"}},{if:{properties:{type:{const:"databricks"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DatabricksServer"}},{if:{properties:{type:{const:"denodo"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DenodoServer"}},{if:{properties:{type:{const:"dremio"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DremioServer"}},{if:{properties:{type:{const:"duckdb"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DuckdbServer"}},{if:{properties:{type:{const:"glue"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GlueServer"}},{if:{properties:{type:{const:"cloudsql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GoogleCloudSqlServer"}},{if:{properties:{type:{const:"db2"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/IBMDB2Server"}},{if:{properties:{type:{const:"informix"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/InformixServer"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/CustomServer"}},{if:{properties:{type:{const:"kafka"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KafkaServer"}},{if:{properties:{type:{const:"kinesis"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KinesisServer"}},{if:{properties:{type:{const:"local"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/LocalServer"}},{if:{properties:{type:{const:"mysql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/MySqlServer"}},{if:{properties:{type:{const:"oracle"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/OracleServer"}},{if:{properties:{type:{const:"postgresql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"postgres"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"presto"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PrestoServer"}},{if:{properties:{type:{const:"pubsub"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PubSubServer"}},{if:{properties:{type:{const:"redshift"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/RedshiftServer"}},{if:{properties:{type:{const:"s3"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/S3Server"}},{if:{properties:{type:{const:"sftp"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SftpServer"}},{if:{properties:{type:{const:"snowflake"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SnowflakeServer"}},{if:{properties:{type:{const:"sqlserver"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SqlserverServer"}},{if:{properties:{type:{const:"synapse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SynapseServer"}},{if:{properties:{type:{const:"trino"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/TrinoServer"}},{if:{properties:{type:{const:"vertica"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/VerticaServer"}}],required:["server","type"]},ServerSource:{ApiServer:{type:"object",title:"AthenaServer",properties:{location:{type:"string",format:"uri",description:"The url to the API.",examples:["https://api.example.com/v1"]}},required:["location"]},AthenaServer:{type:"object",title:"AthenaServer",properties:{stagingDir:{type:"string",format:"uri",description:"Amazon Athena automatically stores query results and metadata information for each query that runs in a query result location that you can specify in Amazon S3.",examples:["s3://my_storage_account_name/my_container/path"]},schema:{type:"string",description:"Identify the schema in the data source in which your tables exist."},catalog:{type:"string",description:"Identify the name of the Data Source, also referred to as a Catalog.",default:"awsdatacatalog"},regionName:{type:"string",description:"The region your AWS account uses.",examples:["eu-west-1"]}},required:["staging_dir","schema"]},AzureServer:{type:"object",title:"AzureServer",properties:{location:{type:"string",format:"uri",description:"Fully qualified path to Azure Blob Storage or Azure Data Lake Storage (ADLS), supports globs.",examples:["az://my_storage_account_name.blob.core.windows.net/my_container/path/*.parquet","abfss://my_storage_account_name.dfs.core.windows.net/my_container_name/path/*.parquet"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location","format"]},BigQueryServer:{type:"object",title:"BigQueryServer",properties:{project:{type:"string",description:"The GCP project name."},dataset:{type:"string",description:"The GCP dataset name."}},required:["project","dataset"]},ClickHouseServer:{type:"object",title:"ClickHouseServer",properties:{host:{type:"string",description:"The host of the ClickHouse server."},port:{type:"integer",description:"The port to the ClickHouse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},DatabricksServer:{type:"object",title:"DatabricksServer",properties:{host:{type:"string",description:"The Databricks host",examples:["dbc-abcdefgh-1234.cloud.databricks.com"]},catalog:{type:"string",description:"The name of the Hive or Unity catalog"},schema:{type:"string",description:"The schema name in the catalog"}},required:["catalog","schema"]},DenodoServer:{type:"object",title:"DenodoServer",properties:{host:{type:"string",description:"The host of the Denodo server."},port:{type:"integer",description:"The port of the Denodo server."},database:{type:"string",description:"The name of the database."}},required:["host","port"]},DremioServer:{type:"object",title:"DremioServer",properties:{host:{type:"string",description:"The host of the Dremio server."},port:{type:"integer",description:"The port of the Dremio server."},schema:{type:"string",description:"The name of the schema."}},required:["host","port"]},DuckdbServer:{type:"object",title:"DuckdbServer",properties:{database:{type:"string",description:"Path to duckdb database file."},schema:{type:"integer",description:"The name of the schema."}},required:["database"]},GlueServer:{type:"object",title:"GlueServer",properties:{account:{type:"string",description:"The AWS Glue account",examples:["1234-5678-9012"]},database:{type:"string",description:"The AWS Glue database name",examples:["my_database"]},location:{type:"string",format:"uri",description:"The AWS S3 path. Must be in the form of a URL.",examples:["s3://datacontract-example-orders-latest/data/{model}"]},format:{type:"string",description:"The format of the files",examples:["parquet","csv","json","delta"]}},required:["account","database"]},GoogleCloudSqlServer:{type:"object",title:"GoogleCloudSqlServer",properties:{host:{type:"string",description:"The host of the Google Cloud Sql server."},port:{type:"integer",description:"The port of the Google Cloud Sql server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]},IBMDB2Server:{type:"object",title:"IBMDB2Server",properties:{host:{type:"string",description:"The host of the IBM DB2 server."},port:{type:"integer",description:"The port of the IBM DB2 server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database"]},InformixServer:{type:"object",title:"InformixServer",properties:{host:{type:"string",description:"The host to the Informix server. "},port:{type:"integer",description:"The port to the Informix server. Defaults to 9088."},database:{type:"string",description:"The name of the database."}},required:["host","database"]},CustomServer:{type:"object",title:"CustomServer",properties:{account:{type:"string",description:"Account used by the server."},catalog:{type:"string",description:"Name of the catalog."},database:{type:"string",description:"Name of the database."},dataset:{type:"string",description:"Name of the dataset."},delimiter:{type:"string",description:"Delimiter."},endpointUrl:{type:"string",description:"Server endpoint.",format:"uri"},format:{type:"string",description:"File format."},host:{type:"string",description:"Host name or IP address."},location:{type:"string",description:"A URL to a location.",format:"uri"},path:{type:"string",description:"Relative or absolute path to the data file(s)."},port:{type:"integer",description:"Port to the server. No default value is assumed for custom servers."},project:{type:"string",description:"Project name."},region:{type:"string",description:"Cloud region."},regionName:{type:"string",description:"Region name."},schema:{type:"string",description:"Name of the schema."},serviceName:{type:"string",description:"Name of the service."},stagingDir:{type:"string",description:"Staging directory."},warehouse:{type:"string",description:"Name of the cluster or warehouse."}}},KafkaServer:{type:"object",title:"KafkaServer",description:"Kafka Server",properties:{host:{type:"string",description:"The bootstrap server of the kafka cluster."},format:{type:"string",description:"The format of the messages.",examples:["json","avro","protobuf","xml"],default:"json"}},required:["host"]},KinesisServer:{type:"object",title:"KinesisDataStreamsServer",description:"Kinesis Data Streams Server",properties:{region:{type:"string",description:"AWS region.",examples:["eu-west-1"]},format:{type:"string",description:"The format of the record",examples:["json","avro","protobuf"]}}},LocalServer:{type:"object",title:"LocalServer",properties:{path:{type:"string",description:"The relative or absolute path to the data file(s).",examples:["./folder/data.parquet","./folder/*.parquet"]},format:{type:"string",description:"The format of the file(s)",examples:["json","parquet","delta","csv"]}},required:["path","format"]},MySqlServer:{type:"object",title:"MySqlServer",properties:{host:{type:"string",description:"The host of the MySql server."},port:{type:"integer",description:"The port of the MySql server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},OracleServer:{type:"object",title:"OracleServer",properties:{host:{type:"string",description:"The host to the oracle server",examples:["localhost"]},port:{type:"integer",description:"The port to the oracle server.",examples:[1523]},serviceName:{type:"string",description:"The name of the service.",examples:["service"]}},required:["host","port","serviceName"]},PostgresServer:{type:"object",title:"PostgresServer",properties:{host:{type:"string",description:"The host to the Postgres server"},port:{type:"integer",description:"The port to the Postgres server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema in the database."}},required:["host","port","database","schema"]},PrestoServer:{type:"object",title:"PrestoServer",properties:{host:{type:"string",description:"The host to the Presto server",examples:["localhost:8080"]},catalog:{type:"string",description:"The name of the catalog.",examples:["postgres"]},schema:{type:"string",description:"The name of the schema.",examples:["public"]}},required:["host"]},PubSubServer:{type:"object",title:"PubSubServer",properties:{project:{type:"string",description:"The GCP project name."}},required:["project"]},RedshiftServer:{type:"object",title:"RedshiftServer",properties:{host:{type:"string",description:"An optional string describing the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},region:{type:"string",description:"AWS region of Redshift server.",examples:["us-east-1"]},account:{type:"string",description:"The account used by the server."}},required:["database","schema"]},S3Server:{type:"object",title:"S3Server",properties:{location:{type:"string",format:"uri",description:"S3 URL, starting with `s3://`",examples:["s3://datacontract-example-orders-latest/data/{model}/*.json"]},endpointUrl:{type:"string",format:"uri",description:"The server endpoint for S3-compatible servers.",examples:["https://minio.example.com"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SftpServer:{type:"object",title:"SftpServer",properties:{location:{type:"string",format:"uri",pattern:"^sftp://.*",description:"SFTP URL, starting with `sftp://`",examples:["sftp://123.123.12.123/{model}/*.json"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SnowflakeServer:{type:"object",title:"SnowflakeServer",properties:{host:{type:"string",description:"The host to the Snowflake server"},port:{type:"integer",description:"The port to the Snowflake server."},account:{type:"string",description:"The Snowflake account used by the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},warehouse:{type:"string",description:"The name of the cluster of resources that is a Snowflake virtual warehouse."}},required:["account","database","schema"]},SqlserverServer:{type:"object",title:"SqlserverServer",properties:{host:{type:"string",description:"The host to the database server",examples:["localhost"]},port:{type:"integer",description:"The port to the database server.",default:1433,examples:[1433]},database:{type:"string",description:"The name of the database.",examples:["database"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["dbo"]}},required:["host","database","schema"]},SynapseServer:{type:"object",title:"SynapseServer",properties:{host:{type:"string",description:"The host of the Synapse server."},port:{type:"integer",description:"The port of the Synapse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},TrinoServer:{type:"object",title:"TrinoServer",properties:{host:{type:"string",description:"The Trino host URL.",examples:["localhost"]},port:{type:"integer",description:"The Trino port."},catalog:{type:"string",description:"The name of the catalog.",examples:["hive"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["my_schema"]}},required:["host","port","catalog","schema"]},VerticaServer:{type:"object",title:"VerticaServer",properties:{host:{type:"string",description:"The host of the Vertica server."},port:{type:"integer",description:"The port of the Vertica server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]}},SchemaElement:{type:"object",properties:{name:{type:"string",description:"Name of the element."},physicalType:{type:"string",description:"The physical element data type in the data source.",examples:["table","view","topic","file"]},description:{type:"string",description:"Description of the element."},businessName:{type:"string",description:"The business name of the element."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{$ref:"#/$defs/Tags"},customProperties:{$ref:"#/$defs/CustomProperties"}}},SchemaObject:{type:"object",properties:{logicalType:{type:"string",description:"The logical element data type.",enum:["object"]},physicalName:{type:"string",description:"Physical name.",examples:["table_1_2_0"]},dataGranularityDescription:{type:"string",description:"Granular level of the data in the object.",examples:["Aggregation by country"]},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"}],required:["name"],unevaluatedProperties:!1},SchemaBaseProperty:{type:"object",properties:{primaryKey:{type:"boolean",description:"Boolean value specifying whether the element is primary or not. Default is false."},primaryKeyPosition:{type:"integer",default:-1,description:"If element is a primary key, the position of the primary key element. Starts from 1. Example of `account_id, name` being primary key columns, `account_id` has primaryKeyPosition 1 and `name` primaryKeyPosition 2. Default to -1."},logicalType:{type:"string",description:"The logical element data type.",enum:["string","date","number","integer","object","array","boolean"]},logicalTypeOptions:{type:"object",description:"Additional optional metadata to describe the logical type."},physicalType:{type:"string",description:"The physical element data type in the data source. For example, VARCHAR(2), DOUBLE, INT."},required:{type:"boolean",default:!1,description:"Indicates if the element may contain Null values; possible values are true and false. Default is false."},unique:{type:"boolean",default:!1,description:"Indicates if the element contains unique values; possible values are true and false. Default is false."},partitioned:{type:"boolean",default:!1,description:"Indicates if the element is partitioned; possible values are true and false."},partitionKeyPosition:{type:"integer",default:-1,description:"If element is used for partitioning, the position of the partition element. Starts from 1. Example of `country, year` being partition columns, `country` has partitionKeyPosition 1 and `year` partitionKeyPosition 2. Default to -1."},classification:{type:"string",description:"Can be anything, like confidential, restricted, and public to more advanced categorization. Some companies like PayPal, use data classification indicating the class of data in the element; expected values are 1, 2, 3, 4, or 5.",examples:["confidential","restricted","public"]},encryptedName:{type:"string",description:"The element name within the dataset that contains the encrypted element value. For example, unencrypted element `email_address` might have an encryptedName of `email_address_encrypt`."},transformSourceObjects:{type:"array",description:"List of objects in the data source used in the transformation.",items:{type:"string"}},transformLogic:{type:"string",description:"Logic used in the element transformation."},transformDescription:{type:"string",description:"Describes the transform logic in very simple terms."},examples:{type:"array",description:"List of sample element values.",items:{$ref:"#/$defs/AnyType"}},criticalDataElement:{type:"boolean",default:!1,description:"True or false indicator; If element is considered a critical data element (CDE) then true else false."},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"},{if:{properties:{logicalType:{const:"string"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{minLength:{type:"integer",minimum:0,description:"Minimum length of the string."},maxLength:{type:"integer",minimum:0,description:"Maximum length of the string."},pattern:{type:"string",description:"Regular expression pattern to define valid value. Follows regular expression syntax from ECMA-262 (https://262.ecma-international.org/5.1/#sec-15.10.1)."},format:{type:"string",examples:["password","byte","binary","email","uuid","uri","hostname","ipv4","ipv6"],description:"Provides extra context about what format the string follows."}},additionalProperties:!1}}}},{if:{properties:{logicalType:{const:"date"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{format:{type:"string",examples:["yyyy-MM-dd","yyyy-MM-dd HH:mm:ss","HH:mm:ss"],description:"Format of the date. Follows the format as prescribed by [JDK DateTimeFormatter](https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html). For example, format 'yyyy-MM-dd'."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},maximum:{type:"string",description:"All date values are less than or equal to this value (values <= maximum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},minimum:{type:"string",description:"All date values are greater than or equal to this value (values >= minimum)."}},additionalProperties:!1}}}},{if:{anyOf:[{properties:{logicalType:{const:"integer"}}}]},then:{properties:{logicalTypeOptions:{type:"object",properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use and whether it is signed or unsigned (follows the Rust integer types).",enum:["i8","i16","i32","i64","i128","u8","u16","u32","u64","u128"]}},additionalProperties:!1}}}},{if:{anyOf:[{properties:{logicalType:{const:"number"}}}]},then:{properties:{logicalTypeOptions:{type:"object",properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use (follows the Rust float types).",enum:["f32","f64"]}},additionalProperties:!1}}}},{if:{properties:{logicalType:{const:"object"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{maxProperties:{type:"integer",minimum:0,description:"Maximum number of properties."},minProperties:{type:"integer",minimum:0,default:0,description:"Minimum number of properties."},required:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0,description:"Property names that are required to exist in the object."}},additionalProperties:!1},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}}}},{if:{properties:{logicalType:{const:"array"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{maxItems:{type:"integer",minimum:0,description:"Maximum number of items."},minItems:{type:"integer",minimum:0,default:0,description:"Minimum number of items"},uniqueItems:{type:"boolean",default:!1,description:"If set to true, all items in the array are unique."}},additionalProperties:!1},items:{$ref:"#/$defs/SchemaItemProperty",description:"List of items in an array (only applicable when `logicalType: array`)."}}}}]},SchemaProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",required:["name"],unevaluatedProperties:!1},SchemaItemProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",properties:{properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}},unevaluatedProperties:!1},Tags:{type:"array",description:"A list of tags that may be assigned to the elements (object or property); the tags keyword may appear at any level.",items:{type:"string"}},DataQuality:{type:"object",properties:{authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},businessImpact:{type:"string",description:"Consequences of the rule failure.",examples:["operational","regulatory"]},customProperties:{type:"array",description:"Additional properties required for rule execution.",items:{$ref:"#/$defs/CustomProperty"}},description:{type:"string",description:"Describe the quality check to be completed."},dimension:{type:"string",description:"The key performance indicator (KPI) or dimension for data quality.",enum:["accuracy","completeness","conformity","consistency","coverage","timeliness","uniqueness"]},method:{type:"string",examples:["reconciliation"]},name:{type:"string",description:"Name of the data quality check."},schedule:{type:"string",description:"Rule execution schedule details.",examples:["0 20 * * *"]},scheduler:{type:"string",description:"The name or type of scheduler used to start the data quality check.",examples:["cron"]},severity:{type:"string",description:"The severance of the quality rule.",examples:["info","warning","error"]},tags:{$ref:"#/$defs/Tags"},type:{type:"string",description:"The type of quality check. 'text' is human-readable text that describes the quality of the data. 'library' is a set of maintained predefined quality attributes such as row count or unique. 'sql' is an individual SQL query that returns a value that can be compared. 'custom' is quality attributes that are vendor-specific, such as Soda or Great Expectations.",enum:["text","library","sql","custom"],default:"library"},unit:{type:"string",description:"Unit the rule is using, popular values are `rows` or `percent`, but any value is allowed.",examples:["rows","percent"]}},allOf:[{if:{properties:{type:{const:"library"}}},then:{$ref:"#/$defs/DataQualityLibrary"}},{if:{properties:{type:{const:"sql"}},required:["type"]},then:{$ref:"#/$defs/DataQualitySql"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/DataQualityCustom"}}]},DataQualityChecks:{type:"array",description:"Data quality rules with all the relevant information for rule setup and execution.",items:{$ref:"#/$defs/DataQuality"}},DataQualityLibrary:{type:"object",properties:{rule:{type:"string",description:"Define a data quality check based on the predefined rules as per ODCS.",examples:["duplicateCount","validValues","rowCount"]},mustBe:{description:"Must be equal to the value to be valid. When using numbers, it is equivalent to '='."},mustNotBe:{description:"Must not be equal to the value to be valid. When using numbers, it is equivalent to '!='."},mustBeGreaterThan:{type:"number",description:"Must be greater than the value to be valid. It is equivalent to '>'."},mustBeGreaterOrEqualTo:{type:"number",description:"Must be greater than or equal to the value to be valid. It is equivalent to '>='."},mustBeLessThan:{type:"number",description:"Must be less than the value to be valid. It is equivalent to '<'."},mustBeLessOrEqualTo:{type:"number",description:"Must be less than or equal to the value to be valid. It is equivalent to '<='."},mustBeBetween:{type:"array",description:"Must be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}},mustNotBeBetween:{type:"array",description:"Must not be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}}},required:["rule"]},DataQualitySql:{type:"object",properties:{query:{type:"string",description:"Query string that adheres to the dialect of the provided server.",examples:["SELECT COUNT(*) FROM ${table} WHERE ${column} IS NOT NULL"]}},required:["query"]},DataQualityCustom:{type:"object",properties:{engine:{type:"string",description:"Name of the engine which executes the data quality checks.",examples:["soda","great-expectations","monte-carlo","dbt"]},implementation:{oneOf:[{type:"string"},{type:"object"}]}},required:["engine","implementation"]},AuthoritativeDefinitions:{type:"array",description:"List of links to sources that provide more details on the dataset; examples would be a link to an external definition, a training video, a GitHub repo, Collibra, or another tool. Authoritative definitions follow the same structure in the standard.",items:{type:"object",properties:{url:{type:"string",description:"URL to the authority."},type:{type:"string",description:"Type of definition for authority: v2.3 adds standard values: `businessDefinition`, `transformationImplementation`, `videoTutorial`, `tutorial`, and `implementation`.",examples:["businessDefinition","transformationImplementation","videoTutorial","tutorial","implementation"]}},required:["url","type"]}},Support:{type:"array",description:"Top level for support channels.",items:{$ref:"#/$defs/SupportItem"}},SupportItem:{type:"object",properties:{channel:{type:"string",description:"Channel name or identifier."},url:{type:"string",description:"Access URL using normal [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax) (https, mailto, etc.)."},description:{type:"string",description:"Description of the channel, free text."},tool:{type:"string",description:"Name of the tool, value can be `email`, `slack`, `teams`, `discord`, `ticket`, or `other`.",examples:["email","slack","teams","discord","ticket","other"]},scope:{type:"string",description:"Scope can be: `interactive`, `announcements`, `issues`.",examples:["interactive","announcements","issues"]},invitationUrl:{type:"string",description:"Some tools uses invitation URL for requesting or subscribing. Follows the [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax)."}},required:["channel","url"]},Pricing:{type:"object",properties:{priceAmount:{type:"number",description:"Subscription price per unit of measure in `priceUnit`."},priceCurrency:{type:"string",description:"Currency of the subscription price in `price.priceAmount`."},priceUnit:{type:"string",description:"The unit of measure for calculating cost. Examples megabyte, gigabyte."}}},Team:{type:"object",properties:{username:{type:"string",description:"The user's username or email."},role:{type:"string",description:"The user's job role; Examples might be owner, data steward. There is no limit on the role."},dateIn:{type:"string",format:"date",description:"The date when the user joined the team."},dateOut:{type:"string",format:"date",description:"The date when the user ceased to be part of the team."},replacedByUsername:{type:"string",description:"The username of the user who replaced the previous user."}}},Role:{type:"object",properties:{role:{type:"string",description:"Name of the IAM role that provides access to the dataset."},description:{type:"string",description:"Description of the IAM role and its permissions."},access:{type:"string",description:"The type of access provided by the IAM role."},firstLevelApprovers:{type:"string",description:"The name(s) of the first-level approver(s) of the role."},secondLevelApprovers:{type:"string",description:"The name(s) of the second-level approver(s) of the role."}},required:["role"]},ServiceLevelAgreementProperty:{type:"object",properties:{property:{type:"string",description:"Specific property in SLA, check the periodic table. May requires units (more details to come)."},value:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}],description:"Agreement value. The label will change based on the property itself."},valueExt:{$ref:"#/$defs/AnyNonCollectionType",description:"Extended agreement value. The label will change based on the property itself."},unit:{type:"string",description:"**d**, day, days for days; **y**, yr, years for years, etc. Units use the ISO standard."},element:{type:"string",description:"Element(s) to check on. Multiple elements should be extremely rare and, if so, separated by commas."},driver:{type:"string",description:"Describes the importance of the SLA from the list of: `regulatory`, `analytics`, or `operational`.",examples:["regulatory","analytics","operational"]}},required:["property","value"]},CustomProperties:{type:"array",description:"A list of key/value pairs for custom properties.",items:{$ref:"#/$defs/CustomProperty"}},CustomProperty:{type:"object",properties:{property:{type:"string",description:"The name of the key. Names should be in camel case–the same as if they were permanent properties in the contract."},value:{$ref:"#/$defs/AnyType",description:"The value of the key."}}},AnyType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"},{type:"array"},{type:"object"}]},AnyNonCollectionType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}]}}};var ese={$schema:"https://json-schema.org/draft/2019-09/schema",title:"Open Data Contract Standard (ODCS)",description:"An open data contract specification to establish agreement between data producers and consumers.",type:"object",properties:{version:{type:"string",description:"Current version of the data contract."},kind:{type:"string",default:"DataContract",description:"The kind of file this is. Valid value is `DataContract`.",enum:["DataContract"]},apiVersion:{type:"string",default:"v3.0.1",description:"Version of the standard used to build data contract. Default value is v3.0.1.",enum:["v3.0.1","v3.0.0","v2.2.2","v2.2.1","v2.2.0"]},id:{type:"string",description:"A unique identifier used to reduce the risk of dataset name collisions, such as a UUID."},name:{type:"string",description:"Name of the data contract."},tenant:{type:"string",description:"Indicates the property the data is primarily associated with. Value is case insensitive."},tags:{$ref:"#/$defs/Tags"},status:{type:"string",description:"Current status of the dataset.",examples:["proposed","draft","active","deprecated","retired"]},servers:{type:"array",description:"List of servers where the datasets reside.",items:{$ref:"#/$defs/Server"}},dataProduct:{type:"string",description:"The name of the data product."},description:{type:"object",description:"High level description of the dataset.",properties:{usage:{type:"string",description:"Intended usage of the dataset."},purpose:{type:"string",description:"Purpose of the dataset."},limitations:{type:"string",description:"Limitations of the dataset."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"}}},domain:{type:"string",description:"Name of the logical data domain.",examples:["imdb_ds_aggregate","receiver_profile_out","transaction_profile_out"]},schema:{type:"array",description:"A list of elements within the schema to be cataloged.",items:{$ref:"#/$defs/SchemaObject"}},support:{$ref:"#/$defs/Support"},price:{$ref:"#/$defs/Pricing"},team:{type:"array",items:{$ref:"#/$defs/Team"}},roles:{type:"array",description:"A list of roles that will provide user access to the dataset.",items:{$ref:"#/$defs/Role"}},slaDefaultElement:{type:"string",description:"Element (using the element path notation) to do the checks on."},slaProperties:{type:"array",description:"A list of key/value pairs for SLA specific properties. There is no limit on the type of properties (more details to come).",items:{$ref:"#/$defs/ServiceLevelAgreementProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"},contractCreatedTs:{type:"string",format:"date-time",description:"Timestamp in UTC of when the data contract was created."}},required:["version","apiVersion","kind","id","status"],additionalProperties:!1,$defs:{Server:{type:"object",description:"Data source details of where data is physically stored.",properties:{server:{type:"string",description:"Identifier of the server."},type:{type:"string",description:"Type of the server.",enum:["api","athena","azure","bigquery","clickhouse","databricks","denodo","dremio","duckdb","glue","cloudsql","db2","informix","kafka","kinesis","local","mysql","oracle","postgresql","postgres","presto","pubsub","redshift","s3","sftp","snowflake","sqlserver","synapse","trino","vertica","custom"]},description:{type:"string",description:"Description of the server."},environment:{type:"string",description:"Environment of the server.",examples:["prod","preprod","dev","uat"]},roles:{type:"array",description:"List of roles that have access to the server.",items:{$ref:"#/$defs/Role"}},customProperties:{$ref:"#/$defs/CustomProperties"}},allOf:[{if:{properties:{type:{const:"api"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ApiServer"}},{if:{properties:{type:{const:"athena"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AthenaServer"}},{if:{properties:{type:{const:"azure"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AzureServer"}},{if:{properties:{type:{const:"bigquery"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/BigQueryServer"}},{if:{properties:{type:{const:"clickhouse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ClickHouseServer"}},{if:{properties:{type:{const:"databricks"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DatabricksServer"}},{if:{properties:{type:{const:"denodo"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DenodoServer"}},{if:{properties:{type:{const:"dremio"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DremioServer"}},{if:{properties:{type:{const:"duckdb"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DuckdbServer"}},{if:{properties:{type:{const:"glue"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GlueServer"}},{if:{properties:{type:{const:"cloudsql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GoogleCloudSqlServer"}},{if:{properties:{type:{const:"db2"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/IBMDB2Server"}},{if:{properties:{type:{const:"informix"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/InformixServer"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/CustomServer"}},{if:{properties:{type:{const:"kafka"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KafkaServer"}},{if:{properties:{type:{const:"kinesis"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KinesisServer"}},{if:{properties:{type:{const:"local"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/LocalServer"}},{if:{properties:{type:{const:"mysql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/MySqlServer"}},{if:{properties:{type:{const:"oracle"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/OracleServer"}},{if:{properties:{type:{const:"postgresql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"postgres"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"presto"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PrestoServer"}},{if:{properties:{type:{const:"pubsub"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PubSubServer"}},{if:{properties:{type:{const:"redshift"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/RedshiftServer"}},{if:{properties:{type:{const:"s3"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/S3Server"}},{if:{properties:{type:{const:"sftp"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SftpServer"}},{if:{properties:{type:{const:"snowflake"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SnowflakeServer"}},{if:{properties:{type:{const:"sqlserver"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SqlserverServer"}},{if:{properties:{type:{const:"synapse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SynapseServer"}},{if:{properties:{type:{const:"trino"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/TrinoServer"}},{if:{properties:{type:{const:"vertica"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/VerticaServer"}}],required:["server","type"]},ServerSource:{ApiServer:{type:"object",title:"AthenaServer",properties:{location:{type:"string",format:"uri",description:"The url to the API.",examples:["https://api.example.com/v1"]}},required:["location"]},AthenaServer:{type:"object",title:"AthenaServer",properties:{stagingDir:{type:"string",format:"uri",description:"Amazon Athena automatically stores query results and metadata information for each query that runs in a query result location that you can specify in Amazon S3.",examples:["s3://my_storage_account_name/my_container/path"]},schema:{type:"string",description:"Identify the schema in the data source in which your tables exist."},catalog:{type:"string",description:"Identify the name of the Data Source, also referred to as a Catalog.",default:"awsdatacatalog"},regionName:{type:"string",description:"The region your AWS account uses.",examples:["eu-west-1"]}},required:["staging_dir","schema"]},AzureServer:{type:"object",title:"AzureServer",properties:{location:{type:"string",format:"uri",description:"Fully qualified path to Azure Blob Storage or Azure Data Lake Storage (ADLS), supports globs.",examples:["az://my_storage_account_name.blob.core.windows.net/my_container/path/*.parquet","abfss://my_storage_account_name.dfs.core.windows.net/my_container_name/path/*.parquet"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location","format"]},BigQueryServer:{type:"object",title:"BigQueryServer",properties:{project:{type:"string",description:"The GCP project name."},dataset:{type:"string",description:"The GCP dataset name."}},required:["project","dataset"]},ClickHouseServer:{type:"object",title:"ClickHouseServer",properties:{host:{type:"string",description:"The host of the ClickHouse server."},port:{type:"integer",description:"The port to the ClickHouse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},DatabricksServer:{type:"object",title:"DatabricksServer",properties:{host:{type:"string",description:"The Databricks host",examples:["dbc-abcdefgh-1234.cloud.databricks.com"]},catalog:{type:"string",description:"The name of the Hive or Unity catalog"},schema:{type:"string",description:"The schema name in the catalog"}},required:["catalog","schema"]},DenodoServer:{type:"object",title:"DenodoServer",properties:{host:{type:"string",description:"The host of the Denodo server."},port:{type:"integer",description:"The port of the Denodo server."},database:{type:"string",description:"The name of the database."}},required:["host","port"]},DremioServer:{type:"object",title:"DremioServer",properties:{host:{type:"string",description:"The host of the Dremio server."},port:{type:"integer",description:"The port of the Dremio server."},schema:{type:"string",description:"The name of the schema."}},required:["host","port"]},DuckdbServer:{type:"object",title:"DuckdbServer",properties:{database:{type:"string",description:"Path to duckdb database file."},schema:{type:"integer",description:"The name of the schema."}},required:["database"]},GlueServer:{type:"object",title:"GlueServer",properties:{account:{type:"string",description:"The AWS Glue account",examples:["1234-5678-9012"]},database:{type:"string",description:"The AWS Glue database name",examples:["my_database"]},location:{type:"string",format:"uri",description:"The AWS S3 path. Must be in the form of a URL.",examples:["s3://datacontract-example-orders-latest/data/{model}"]},format:{type:"string",description:"The format of the files",examples:["parquet","csv","json","delta"]}},required:["account","database"]},GoogleCloudSqlServer:{type:"object",title:"GoogleCloudSqlServer",properties:{host:{type:"string",description:"The host of the Google Cloud Sql server."},port:{type:"integer",description:"The port of the Google Cloud Sql server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]},IBMDB2Server:{type:"object",title:"IBMDB2Server",properties:{host:{type:"string",description:"The host of the IBM DB2 server."},port:{type:"integer",description:"The port of the IBM DB2 server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database"]},InformixServer:{type:"object",title:"InformixServer",properties:{host:{type:"string",description:"The host to the Informix server. "},port:{type:"integer",description:"The port to the Informix server. Defaults to 9088."},database:{type:"string",description:"The name of the database."}},required:["host","database"]},CustomServer:{type:"object",title:"CustomServer",properties:{account:{type:"string",description:"Account used by the server."},catalog:{type:"string",description:"Name of the catalog."},database:{type:"string",description:"Name of the database."},dataset:{type:"string",description:"Name of the dataset."},delimiter:{type:"string",description:"Delimiter."},endpointUrl:{type:"string",description:"Server endpoint.",format:"uri"},format:{type:"string",description:"File format."},host:{type:"string",description:"Host name or IP address."},location:{type:"string",description:"A URL to a location.",format:"uri"},path:{type:"string",description:"Relative or absolute path to the data file(s)."},port:{type:"integer",description:"Port to the server. No default value is assumed for custom servers."},project:{type:"string",description:"Project name."},region:{type:"string",description:"Cloud region."},regionName:{type:"string",description:"Region name."},schema:{type:"string",description:"Name of the schema."},serviceName:{type:"string",description:"Name of the service."},stagingDir:{type:"string",description:"Staging directory."},warehouse:{type:"string",description:"Name of the cluster or warehouse."}}},KafkaServer:{type:"object",title:"KafkaServer",description:"Kafka Server",properties:{host:{type:"string",description:"The bootstrap server of the kafka cluster."},format:{type:"string",description:"The format of the messages.",examples:["json","avro","protobuf","xml"],default:"json"}},required:["host"]},KinesisServer:{type:"object",title:"KinesisDataStreamsServer",description:"Kinesis Data Streams Server",properties:{region:{type:"string",description:"AWS region.",examples:["eu-west-1"]},format:{type:"string",description:"The format of the record",examples:["json","avro","protobuf"]}}},LocalServer:{type:"object",title:"LocalServer",properties:{path:{type:"string",description:"The relative or absolute path to the data file(s).",examples:["./folder/data.parquet","./folder/*.parquet"]},format:{type:"string",description:"The format of the file(s)",examples:["json","parquet","delta","csv"]}},required:["path","format"]},MySqlServer:{type:"object",title:"MySqlServer",properties:{host:{type:"string",description:"The host of the MySql server."},port:{type:"integer",description:"The port of the MySql server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},OracleServer:{type:"object",title:"OracleServer",properties:{host:{type:"string",description:"The host to the oracle server",examples:["localhost"]},port:{type:"integer",description:"The port to the oracle server.",examples:[1523]},serviceName:{type:"string",description:"The name of the service.",examples:["service"]}},required:["host","port","serviceName"]},PostgresServer:{type:"object",title:"PostgresServer",properties:{host:{type:"string",description:"The host to the Postgres server"},port:{type:"integer",description:"The port to the Postgres server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema in the database."}},required:["host","port","database","schema"]},PrestoServer:{type:"object",title:"PrestoServer",properties:{host:{type:"string",description:"The host to the Presto server",examples:["localhost:8080"]},catalog:{type:"string",description:"The name of the catalog.",examples:["postgres"]},schema:{type:"string",description:"The name of the schema.",examples:["public"]}},required:["host"]},PubSubServer:{type:"object",title:"PubSubServer",properties:{project:{type:"string",description:"The GCP project name."}},required:["project"]},RedshiftServer:{type:"object",title:"RedshiftServer",properties:{host:{type:"string",description:"An optional string describing the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},region:{type:"string",description:"AWS region of Redshift server.",examples:["us-east-1"]},account:{type:"string",description:"The account used by the server."}},required:["database","schema"]},S3Server:{type:"object",title:"S3Server",properties:{location:{type:"string",format:"uri",description:"S3 URL, starting with `s3://`",examples:["s3://datacontract-example-orders-latest/data/{model}/*.json"]},endpointUrl:{type:"string",format:"uri",description:"The server endpoint for S3-compatible servers.",examples:["https://minio.example.com"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SftpServer:{type:"object",title:"SftpServer",properties:{location:{type:"string",format:"uri",pattern:"^sftp://.*",description:"SFTP URL, starting with `sftp://`",examples:["sftp://123.123.12.123/{model}/*.json"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SnowflakeServer:{type:"object",title:"SnowflakeServer",properties:{host:{type:"string",description:"The host to the Snowflake server"},port:{type:"integer",description:"The port to the Snowflake server."},account:{type:"string",description:"The Snowflake account used by the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},warehouse:{type:"string",description:"The name of the cluster of resources that is a Snowflake virtual warehouse."}},required:["account","database","schema"]},SqlserverServer:{type:"object",title:"SqlserverServer",properties:{host:{type:"string",description:"The host to the database server",examples:["localhost"]},port:{type:"integer",description:"The port to the database server.",default:1433,examples:[1433]},database:{type:"string",description:"The name of the database.",examples:["database"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["dbo"]}},required:["host","database","schema"]},SynapseServer:{type:"object",title:"SynapseServer",properties:{host:{type:"string",description:"The host of the Synapse server."},port:{type:"integer",description:"The port of the Synapse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},TrinoServer:{type:"object",title:"TrinoServer",properties:{host:{type:"string",description:"The Trino host URL.",examples:["localhost"]},port:{type:"integer",description:"The Trino port."},catalog:{type:"string",description:"The name of the catalog.",examples:["hive"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["my_schema"]}},required:["host","port","catalog","schema"]},VerticaServer:{type:"object",title:"VerticaServer",properties:{host:{type:"string",description:"The host of the Vertica server."},port:{type:"integer",description:"The port of the Vertica server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]}},SchemaElement:{type:"object",properties:{name:{type:"string",description:"Name of the element."},physicalType:{type:"string",description:"The physical element data type in the data source.",examples:["table","view","topic","file"]},description:{type:"string",description:"Description of the element."},businessName:{type:"string",description:"The business name of the element."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{$ref:"#/$defs/Tags"},customProperties:{$ref:"#/$defs/CustomProperties"}}},SchemaObject:{type:"object",properties:{logicalType:{type:"string",description:"The logical element data type.",enum:["object"]},physicalName:{type:"string",description:"Physical name.",examples:["table_1_2_0"]},dataGranularityDescription:{type:"string",description:"Granular level of the data in the object.",examples:["Aggregation by country"]},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"}],required:["name"],unevaluatedProperties:!1},SchemaBaseProperty:{type:"object",properties:{primaryKey:{type:"boolean",description:"Boolean value specifying whether the element is primary or not. Default is false."},primaryKeyPosition:{type:"integer",default:-1,description:"If element is a primary key, the position of the primary key element. Starts from 1. Example of `account_id, name` being primary key columns, `account_id` has primaryKeyPosition 1 and `name` primaryKeyPosition 2. Default to -1."},logicalType:{type:"string",description:"The logical element data type.",enum:["string","date","number","integer","object","array","boolean"]},logicalTypeOptions:{type:"object",description:"Additional optional metadata to describe the logical type."},physicalType:{type:"string",description:"The physical element data type in the data source. For example, VARCHAR(2), DOUBLE, INT."},required:{type:"boolean",default:!1,description:"Indicates if the element may contain Null values; possible values are true and false. Default is false."},unique:{type:"boolean",default:!1,description:"Indicates if the element contains unique values; possible values are true and false. Default is false."},partitioned:{type:"boolean",default:!1,description:"Indicates if the element is partitioned; possible values are true and false."},partitionKeyPosition:{type:"integer",default:-1,description:"If element is used for partitioning, the position of the partition element. Starts from 1. Example of `country, year` being partition columns, `country` has partitionKeyPosition 1 and `year` partitionKeyPosition 2. Default to -1."},classification:{type:"string",description:"Can be anything, like confidential, restricted, and public to more advanced categorization. Some companies like PayPal, use data classification indicating the class of data in the element; expected values are 1, 2, 3, 4, or 5.",examples:["confidential","restricted","public"]},encryptedName:{type:"string",description:"The element name within the dataset that contains the encrypted element value. For example, unencrypted element `email_address` might have an encryptedName of `email_address_encrypt`."},transformSourceObjects:{type:"array",description:"List of objects in the data source used in the transformation.",items:{type:"string"}},transformLogic:{type:"string",description:"Logic used in the element transformation."},transformDescription:{type:"string",description:"Describes the transform logic in very simple terms."},examples:{type:"array",description:"List of sample element values.",items:{$ref:"#/$defs/AnyType"}},criticalDataElement:{type:"boolean",default:!1,description:"True or false indicator; If element is considered a critical data element (CDE) then true else false."},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"},{if:{properties:{logicalType:{const:"string"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{minLength:{type:"integer",minimum:0,description:"Minimum length of the string."},maxLength:{type:"integer",minimum:0,description:"Maximum length of the string."},pattern:{type:"string",description:"Regular expression pattern to define valid value. Follows regular expression syntax from ECMA-262 (https://262.ecma-international.org/5.1/#sec-15.10.1)."},format:{type:"string",examples:["password","byte","binary","email","uuid","uri","hostname","ipv4","ipv6"],description:"Provides extra context about what format the string follows."}},additionalProperties:!1}}}},{if:{properties:{logicalType:{const:"date"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{format:{type:"string",examples:["yyyy-MM-dd","yyyy-MM-dd HH:mm:ss","HH:mm:ss"],description:"Format of the date. Follows the format as prescribed by [JDK DateTimeFormatter](https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html). For example, format 'yyyy-MM-dd'."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},maximum:{type:"string",description:"All date values are less than or equal to this value (values <= maximum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},minimum:{type:"string",description:"All date values are greater than or equal to this value (values >= minimum)."}},additionalProperties:!1}}}},{if:{anyOf:[{properties:{logicalType:{const:"integer"}}}]},then:{properties:{logicalTypeOptions:{type:"object",properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use and whether it is signed or unsigned (follows the Rust integer types).",enum:["i8","i16","i32","i64","i128","u8","u16","u32","u64","u128"]}},additionalProperties:!1}}}},{if:{anyOf:[{properties:{logicalType:{const:"number"}}}]},then:{properties:{logicalTypeOptions:{type:"object",properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use (follows the Rust float types).",enum:["f32","f64"]}},additionalProperties:!1}}}},{if:{properties:{logicalType:{const:"object"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{maxProperties:{type:"integer",minimum:0,description:"Maximum number of properties."},minProperties:{type:"integer",minimum:0,default:0,description:"Minimum number of properties."},required:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0,description:"Property names that are required to exist in the object."}},additionalProperties:!1},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}}}},{if:{properties:{logicalType:{const:"array"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{maxItems:{type:"integer",minimum:0,description:"Maximum number of items."},minItems:{type:"integer",minimum:0,default:0,description:"Minimum number of items"},uniqueItems:{type:"boolean",default:!1,description:"If set to true, all items in the array are unique."}},additionalProperties:!1},items:{$ref:"#/$defs/SchemaItemProperty",description:"List of items in an array (only applicable when `logicalType: array`)."}}}}]},SchemaProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",required:["name"],unevaluatedProperties:!1},SchemaItemProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",properties:{properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}},unevaluatedProperties:!1},Tags:{type:"array",description:"A list of tags that may be assigned to the elements (object or property); the tags keyword may appear at any level. Tags may be used to better categorize an element. For example, `finance`, `sensitive`, `employee_record`.",examples:["finance","sensitive","employee_record"],items:{type:"string"}},DataQuality:{type:"object",properties:{authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},businessImpact:{type:"string",description:"Consequences of the rule failure.",examples:["operational","regulatory"]},customProperties:{type:"array",description:"Additional properties required for rule execution.",items:{$ref:"#/$defs/CustomProperty"}},description:{type:"string",description:"Describe the quality check to be completed."},dimension:{type:"string",description:"The key performance indicator (KPI) or dimension for data quality.",enum:["accuracy","completeness","conformity","consistency","coverage","timeliness","uniqueness"]},method:{type:"string",examples:["reconciliation"]},name:{type:"string",description:"Name of the data quality check."},schedule:{type:"string",description:"Rule execution schedule details.",examples:["0 20 * * *"]},scheduler:{type:"string",description:"The name or type of scheduler used to start the data quality check.",examples:["cron"]},severity:{type:"string",description:"The severance of the quality rule.",examples:["info","warning","error"]},tags:{$ref:"#/$defs/Tags"},type:{type:"string",description:"The type of quality check. 'text' is human-readable text that describes the quality of the data. 'library' is a set of maintained predefined quality attributes such as row count or unique. 'sql' is an individual SQL query that returns a value that can be compared. 'custom' is quality attributes that are vendor-specific, such as Soda or Great Expectations.",enum:["text","library","sql","custom"],default:"library"},unit:{type:"string",description:"Unit the rule is using, popular values are `rows` or `percent`, but any value is allowed.",examples:["rows","percent"]}},allOf:[{if:{properties:{type:{const:"library"}}},then:{$ref:"#/$defs/DataQualityLibrary"}},{if:{properties:{type:{const:"sql"}},required:["type"]},then:{$ref:"#/$defs/DataQualitySql"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/DataQualityCustom"}}]},DataQualityChecks:{type:"array",description:"Data quality rules with all the relevant information for rule setup and execution.",items:{$ref:"#/$defs/DataQuality"}},DataQualityLibrary:{type:"object",properties:{rule:{type:"string",description:"Define a data quality check based on the predefined rules as per ODCS.",examples:["duplicateCount","validValues","rowCount"]},mustBe:{description:"Must be equal to the value to be valid. When using numbers, it is equivalent to '='."},mustNotBe:{description:"Must not be equal to the value to be valid. When using numbers, it is equivalent to '!='."},mustBeGreaterThan:{type:"number",description:"Must be greater than the value to be valid. It is equivalent to '>'."},mustBeGreaterOrEqualTo:{type:"number",description:"Must be greater than or equal to the value to be valid. It is equivalent to '>='."},mustBeLessThan:{type:"number",description:"Must be less than the value to be valid. It is equivalent to '<'."},mustBeLessOrEqualTo:{type:"number",description:"Must be less than or equal to the value to be valid. It is equivalent to '<='."},mustBeBetween:{type:"array",description:"Must be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}},mustNotBeBetween:{type:"array",description:"Must not be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}}},required:["rule"]},DataQualitySql:{type:"object",properties:{query:{type:"string",description:"Query string that adheres to the dialect of the provided server.",examples:["SELECT COUNT(*) FROM ${table} WHERE ${column} IS NOT NULL"]}},required:["query"]},DataQualityCustom:{type:"object",properties:{engine:{type:"string",description:"Name of the engine which executes the data quality checks.",examples:["soda","great-expectations","monte-carlo","dbt"]},implementation:{oneOf:[{type:"string"},{type:"object"}]}},required:["engine","implementation"]},AuthoritativeDefinitions:{type:"array",description:"List of links to sources that provide more details on the dataset; examples would be a link to an external definition, a training video, a git repo, data catalog, or another tool. Authoritative definitions follow the same structure in the standard.",items:{type:"object",properties:{url:{type:"string",description:"URL to the authority."},type:{type:"string",description:"Type of definition for authority: v2.3 adds standard values: `businessDefinition`, `transformationImplementation`, `videoTutorial`, `tutorial`, and `implementation`.",examples:["businessDefinition","transformationImplementation","videoTutorial","tutorial","implementation"]}},required:["url","type"]}},Support:{type:"array",description:"Top level for support channels.",items:{$ref:"#/$defs/SupportItem"}},SupportItem:{type:"object",properties:{channel:{type:"string",description:"Channel name or identifier."},url:{type:"string",description:"Access URL using normal [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax) (https, mailto, etc.)."},description:{type:"string",description:"Description of the channel, free text."},tool:{type:"string",description:"Name of the tool, value can be `email`, `slack`, `teams`, `discord`, `ticket`, or `other`.",examples:["email","slack","teams","discord","ticket","other"]},scope:{type:"string",description:"Scope can be: `interactive`, `announcements`, `issues`.",examples:["interactive","announcements","issues"]},invitationUrl:{type:"string",description:"Some tools uses invitation URL for requesting or subscribing. Follows the [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax)."}},required:["channel","url"]},Pricing:{type:"object",properties:{priceAmount:{type:"number",description:"Subscription price per unit of measure in `priceUnit`."},priceCurrency:{type:"string",description:"Currency of the subscription price in `price.priceAmount`."},priceUnit:{type:"string",description:"The unit of measure for calculating cost. Examples megabyte, gigabyte."}}},Team:{type:"object",properties:{username:{type:"string",description:"The user's username or email."},role:{type:"string",description:"The user's job role; Examples might be owner, data steward. There is no limit on the role."},dateIn:{type:"string",format:"date",description:"The date when the user joined the team."},dateOut:{type:"string",format:"date",description:"The date when the user ceased to be part of the team."},replacedByUsername:{type:"string",description:"The username of the user who replaced the previous user."}}},Role:{type:"object",properties:{role:{type:"string",description:"Name of the IAM role that provides access to the dataset."},description:{type:"string",description:"Description of the IAM role and its permissions."},access:{type:"string",description:"The type of access provided by the IAM role."},firstLevelApprovers:{type:"string",description:"The name(s) of the first-level approver(s) of the role."},secondLevelApprovers:{type:"string",description:"The name(s) of the second-level approver(s) of the role."},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["role"]},ServiceLevelAgreementProperty:{type:"object",properties:{property:{type:"string",description:"Specific property in SLA, check the periodic table. May requires units (more details to come)."},value:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}],description:"Agreement value. The label will change based on the property itself."},valueExt:{$ref:"#/$defs/AnyNonCollectionType",description:"Extended agreement value. The label will change based on the property itself."},unit:{type:"string",description:"**d**, day, days for days; **y**, yr, years for years, etc. Units use the ISO standard."},element:{type:"string",description:"Element(s) to check on. Multiple elements should be extremely rare and, if so, separated by commas."},driver:{type:"string",description:"Describes the importance of the SLA from the list of: `regulatory`, `analytics`, or `operational`.",examples:["regulatory","analytics","operational"]}},required:["property","value"]},CustomProperties:{type:"array",description:"A list of key/value pairs for custom properties.",items:{$ref:"#/$defs/CustomProperty"}},CustomProperty:{type:"object",properties:{property:{type:"string",description:"The name of the key. Names should be in camel case–the same as if they were permanent properties in the contract."},value:{$ref:"#/$defs/AnyType",description:"The value of the key."}}},AnyType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"},{type:"array"},{type:"object"}]},AnyNonCollectionType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}]}}};var tse={$schema:"https://json-schema.org/draft/2019-09/schema",title:"Open Data Contract Standard (ODCS)",description:"An open data contract specification to establish agreement between data producers and consumers.",type:"object",properties:{version:{type:"string",description:"Current version of the data contract."},kind:{type:"string",default:"DataContract",description:"The kind of file this is. Valid value is `DataContract`.",enum:["DataContract"]},apiVersion:{type:"string",default:"v3.0.2",description:"Version of the standard used to build data contract. Default value is v3.0.2.",enum:["v3.0.2","v3.0.1","v3.0.0","v2.2.2","v2.2.1","v2.2.0"]},id:{type:"string",description:"A unique identifier used to reduce the risk of dataset name collisions, such as a UUID."},name:{type:"string",description:"Name of the data contract."},tenant:{type:"string",description:"Indicates the property the data is primarily associated with. Value is case insensitive."},tags:{$ref:"#/$defs/Tags"},status:{type:"string",description:"Current status of the dataset.",examples:["proposed","draft","active","deprecated","retired"]},servers:{type:"array",description:"List of servers where the datasets reside.",items:{$ref:"#/$defs/Server"}},dataProduct:{type:"string",description:"The name of the data product."},description:{type:"object",description:"High level description of the dataset.",properties:{usage:{type:"string",description:"Intended usage of the dataset."},purpose:{type:"string",description:"Purpose of the dataset."},limitations:{type:"string",description:"Limitations of the dataset."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"}}},domain:{type:"string",description:"Name of the logical data domain.",examples:["imdb_ds_aggregate","receiver_profile_out","transaction_profile_out"]},schema:{type:"array",description:"A list of elements within the schema to be cataloged.",items:{$ref:"#/$defs/SchemaObject"}},support:{$ref:"#/$defs/Support"},price:{$ref:"#/$defs/Pricing"},team:{type:"array",items:{$ref:"#/$defs/Team"}},roles:{type:"array",description:"A list of roles that will provide user access to the dataset.",items:{$ref:"#/$defs/Role"}},slaDefaultElement:{type:"string",description:"Element (using the element path notation) to do the checks on."},slaProperties:{type:"array",description:"A list of key/value pairs for SLA specific properties. There is no limit on the type of properties (more details to come).",items:{$ref:"#/$defs/ServiceLevelAgreementProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"},contractCreatedTs:{type:"string",format:"date-time",description:"Timestamp in UTC of when the data contract was created."}},required:["version","apiVersion","kind","id","status"],additionalProperties:!1,$defs:{Server:{type:"object",description:"Data source details of where data is physically stored.",properties:{server:{type:"string",description:"Identifier of the server."},type:{type:"string",description:"Type of the server.",enum:["api","athena","azure","bigquery","clickhouse","databricks","denodo","dremio","duckdb","glue","cloudsql","db2","informix","kafka","kinesis","local","mysql","oracle","postgresql","postgres","presto","pubsub","redshift","s3","sftp","snowflake","sqlserver","synapse","trino","vertica","custom"]},description:{type:"string",description:"Description of the server."},environment:{type:"string",description:"Environment of the server.",examples:["prod","preprod","dev","uat"]},roles:{type:"array",description:"List of roles that have access to the server.",items:{$ref:"#/$defs/Role"}},customProperties:{$ref:"#/$defs/CustomProperties"}},allOf:[{if:{properties:{type:{const:"api"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ApiServer"}},{if:{properties:{type:{const:"athena"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AthenaServer"}},{if:{properties:{type:{const:"azure"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AzureServer"}},{if:{properties:{type:{const:"bigquery"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/BigQueryServer"}},{if:{properties:{type:{const:"clickhouse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ClickHouseServer"}},{if:{properties:{type:{const:"databricks"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DatabricksServer"}},{if:{properties:{type:{const:"denodo"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DenodoServer"}},{if:{properties:{type:{const:"dremio"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DremioServer"}},{if:{properties:{type:{const:"duckdb"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DuckdbServer"}},{if:{properties:{type:{const:"glue"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GlueServer"}},{if:{properties:{type:{const:"cloudsql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GoogleCloudSqlServer"}},{if:{properties:{type:{const:"db2"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/IBMDB2Server"}},{if:{properties:{type:{const:"informix"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/InformixServer"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/CustomServer"}},{if:{properties:{type:{const:"kafka"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KafkaServer"}},{if:{properties:{type:{const:"kinesis"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KinesisServer"}},{if:{properties:{type:{const:"local"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/LocalServer"}},{if:{properties:{type:{const:"mysql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/MySqlServer"}},{if:{properties:{type:{const:"oracle"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/OracleServer"}},{if:{properties:{type:{const:"postgresql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"postgres"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"presto"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PrestoServer"}},{if:{properties:{type:{const:"pubsub"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PubSubServer"}},{if:{properties:{type:{const:"redshift"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/RedshiftServer"}},{if:{properties:{type:{const:"s3"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/S3Server"}},{if:{properties:{type:{const:"sftp"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SftpServer"}},{if:{properties:{type:{const:"snowflake"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SnowflakeServer"}},{if:{properties:{type:{const:"sqlserver"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SqlserverServer"}},{if:{properties:{type:{const:"synapse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SynapseServer"}},{if:{properties:{type:{const:"trino"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/TrinoServer"}},{if:{properties:{type:{const:"vertica"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/VerticaServer"}}],required:["server","type"]},ServerSource:{ApiServer:{type:"object",title:"AthenaServer",properties:{location:{type:"string",format:"uri",description:"The url to the API.",examples:["https://api.example.com/v1"]}},required:["location"]},AthenaServer:{type:"object",title:"AthenaServer",properties:{stagingDir:{type:"string",format:"uri",description:"Amazon Athena automatically stores query results and metadata information for each query that runs in a query result location that you can specify in Amazon S3.",examples:["s3://my_storage_account_name/my_container/path"]},schema:{type:"string",description:"Identify the schema in the data source in which your tables exist."},catalog:{type:"string",description:"Identify the name of the Data Source, also referred to as a Catalog.",default:"awsdatacatalog"},regionName:{type:"string",description:"The region your AWS account uses.",examples:["eu-west-1"]}},required:["stagingDir","schema"]},AzureServer:{type:"object",title:"AzureServer",properties:{location:{type:"string",format:"uri",description:"Fully qualified path to Azure Blob Storage or Azure Data Lake Storage (ADLS), supports globs.",examples:["az://my_storage_account_name.blob.core.windows.net/my_container/path/*.parquet","abfss://my_storage_account_name.dfs.core.windows.net/my_container_name/path/*.parquet"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location","format"]},BigQueryServer:{type:"object",title:"BigQueryServer",properties:{project:{type:"string",description:"The GCP project name."},dataset:{type:"string",description:"The GCP dataset name."}},required:["project","dataset"]},ClickHouseServer:{type:"object",title:"ClickHouseServer",properties:{host:{type:"string",description:"The host of the ClickHouse server."},port:{type:"integer",description:"The port to the ClickHouse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},DatabricksServer:{type:"object",title:"DatabricksServer",properties:{host:{type:"string",description:"The Databricks host",examples:["dbc-abcdefgh-1234.cloud.databricks.com"]},catalog:{type:"string",description:"The name of the Hive or Unity catalog"},schema:{type:"string",description:"The schema name in the catalog"}},required:["catalog","schema"]},DenodoServer:{type:"object",title:"DenodoServer",properties:{host:{type:"string",description:"The host of the Denodo server."},port:{type:"integer",description:"The port of the Denodo server."},database:{type:"string",description:"The name of the database."}},required:["host","port"]},DremioServer:{type:"object",title:"DremioServer",properties:{host:{type:"string",description:"The host of the Dremio server."},port:{type:"integer",description:"The port of the Dremio server."},schema:{type:"string",description:"The name of the schema."}},required:["host","port"]},DuckdbServer:{type:"object",title:"DuckdbServer",properties:{database:{type:"string",description:"Path to duckdb database file."},schema:{type:"integer",description:"The name of the schema."}},required:["database"]},GlueServer:{type:"object",title:"GlueServer",properties:{account:{type:"string",description:"The AWS Glue account",examples:["1234-5678-9012"]},database:{type:"string",description:"The AWS Glue database name",examples:["my_database"]},location:{type:"string",format:"uri",description:"The AWS S3 path. Must be in the form of a URL.",examples:["s3://datacontract-example-orders-latest/data/{model}"]},format:{type:"string",description:"The format of the files",examples:["parquet","csv","json","delta"]}},required:["account","database"]},GoogleCloudSqlServer:{type:"object",title:"GoogleCloudSqlServer",properties:{host:{type:"string",description:"The host of the Google Cloud Sql server."},port:{type:"integer",description:"The port of the Google Cloud Sql server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]},IBMDB2Server:{type:"object",title:"IBMDB2Server",properties:{host:{type:"string",description:"The host of the IBM DB2 server."},port:{type:"integer",description:"The port of the IBM DB2 server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database"]},InformixServer:{type:"object",title:"InformixServer",properties:{host:{type:"string",description:"The host to the Informix server. "},port:{type:"integer",description:"The port to the Informix server. Defaults to 9088."},database:{type:"string",description:"The name of the database."}},required:["host","database"]},CustomServer:{type:"object",title:"CustomServer",properties:{account:{type:"string",description:"Account used by the server."},catalog:{type:"string",description:"Name of the catalog."},database:{type:"string",description:"Name of the database."},dataset:{type:"string",description:"Name of the dataset."},delimiter:{type:"string",description:"Delimiter."},endpointUrl:{type:"string",description:"Server endpoint.",format:"uri"},format:{type:"string",description:"File format."},host:{type:"string",description:"Host name or IP address."},location:{type:"string",description:"A URL to a location.",format:"uri"},path:{type:"string",description:"Relative or absolute path to the data file(s)."},port:{type:"integer",description:"Port to the server. No default value is assumed for custom servers."},project:{type:"string",description:"Project name."},region:{type:"string",description:"Cloud region."},regionName:{type:"string",description:"Region name."},schema:{type:"string",description:"Name of the schema."},serviceName:{type:"string",description:"Name of the service."},stagingDir:{type:"string",description:"Staging directory."},warehouse:{type:"string",description:"Name of the cluster or warehouse."}}},KafkaServer:{type:"object",title:"KafkaServer",description:"Kafka Server",properties:{host:{type:"string",description:"The bootstrap server of the kafka cluster."},format:{type:"string",description:"The format of the messages.",examples:["json","avro","protobuf","xml"],default:"json"}},required:["host"]},KinesisServer:{type:"object",title:"KinesisDataStreamsServer",description:"Kinesis Data Streams Server",properties:{region:{type:"string",description:"AWS region.",examples:["eu-west-1"]},format:{type:"string",description:"The format of the record",examples:["json","avro","protobuf"]}}},LocalServer:{type:"object",title:"LocalServer",properties:{path:{type:"string",description:"The relative or absolute path to the data file(s).",examples:["./folder/data.parquet","./folder/*.parquet"]},format:{type:"string",description:"The format of the file(s)",examples:["json","parquet","delta","csv"]}},required:["path","format"]},MySqlServer:{type:"object",title:"MySqlServer",properties:{host:{type:"string",description:"The host of the MySql server."},port:{type:"integer",description:"The port of the MySql server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},OracleServer:{type:"object",title:"OracleServer",properties:{host:{type:"string",description:"The host to the oracle server",examples:["localhost"]},port:{type:"integer",description:"The port to the oracle server.",examples:[1523]},serviceName:{type:"string",description:"The name of the service.",examples:["service"]}},required:["host","port","serviceName"]},PostgresServer:{type:"object",title:"PostgresServer",properties:{host:{type:"string",description:"The host to the Postgres server"},port:{type:"integer",description:"The port to the Postgres server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema in the database."}},required:["host","port","database","schema"]},PrestoServer:{type:"object",title:"PrestoServer",properties:{host:{type:"string",description:"The host to the Presto server",examples:["localhost:8080"]},catalog:{type:"string",description:"The name of the catalog.",examples:["postgres"]},schema:{type:"string",description:"The name of the schema.",examples:["public"]}},required:["host"]},PubSubServer:{type:"object",title:"PubSubServer",properties:{project:{type:"string",description:"The GCP project name."}},required:["project"]},RedshiftServer:{type:"object",title:"RedshiftServer",properties:{host:{type:"string",description:"An optional string describing the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},region:{type:"string",description:"AWS region of Redshift server.",examples:["us-east-1"]},account:{type:"string",description:"The account used by the server."}},required:["database","schema"]},S3Server:{type:"object",title:"S3Server",properties:{location:{type:"string",format:"uri",description:"S3 URL, starting with `s3://`",examples:["s3://datacontract-example-orders-latest/data/{model}/*.json"]},endpointUrl:{type:"string",format:"uri",description:"The server endpoint for S3-compatible servers.",examples:["https://minio.example.com"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SftpServer:{type:"object",title:"SftpServer",properties:{location:{type:"string",format:"uri",pattern:"^sftp://.*",description:"SFTP URL, starting with `sftp://`",examples:["sftp://123.123.12.123/{model}/*.json"]},format:{type:"string",enum:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",enum:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SnowflakeServer:{type:"object",title:"SnowflakeServer",properties:{host:{type:"string",description:"The host to the Snowflake server"},port:{type:"integer",description:"The port to the Snowflake server."},account:{type:"string",description:"The Snowflake account used by the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},warehouse:{type:"string",description:"The name of the cluster of resources that is a Snowflake virtual warehouse."}},required:["account","database","schema"]},SqlserverServer:{type:"object",title:"SqlserverServer",properties:{host:{type:"string",description:"The host to the database server",examples:["localhost"]},port:{type:"integer",description:"The port to the database server.",default:1433,examples:[1433]},database:{type:"string",description:"The name of the database.",examples:["database"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["dbo"]}},required:["host","database","schema"]},SynapseServer:{type:"object",title:"SynapseServer",properties:{host:{type:"string",description:"The host of the Synapse server."},port:{type:"integer",description:"The port of the Synapse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},TrinoServer:{type:"object",title:"TrinoServer",properties:{host:{type:"string",description:"The Trino host URL.",examples:["localhost"]},port:{type:"integer",description:"The Trino port."},catalog:{type:"string",description:"The name of the catalog.",examples:["hive"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["my_schema"]}},required:["host","port","catalog","schema"]},VerticaServer:{type:"object",title:"VerticaServer",properties:{host:{type:"string",description:"The host of the Vertica server."},port:{type:"integer",description:"The port of the Vertica server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]}},SchemaElement:{type:"object",properties:{name:{type:"string",description:"Name of the element."},physicalType:{type:"string",description:"The physical element data type in the data source.",examples:["table","view","topic","file"]},description:{type:"string",description:"Description of the element."},businessName:{type:"string",description:"The business name of the element."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{$ref:"#/$defs/Tags"},customProperties:{$ref:"#/$defs/CustomProperties"}}},SchemaObject:{type:"object",properties:{logicalType:{type:"string",description:"The logical element data type.",enum:["object"]},physicalName:{type:"string",description:"Physical name.",examples:["table_1_2_0"]},dataGranularityDescription:{type:"string",description:"Granular level of the data in the object.",examples:["Aggregation by country"]},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"}],required:["name"],unevaluatedProperties:!1},SchemaBaseProperty:{type:"object",properties:{primaryKey:{type:"boolean",description:"Boolean value specifying whether the element is primary or not. Default is false."},primaryKeyPosition:{type:"integer",default:-1,description:"If element is a primary key, the position of the primary key element. Starts from 1. Example of `account_id, name` being primary key columns, `account_id` has primaryKeyPosition 1 and `name` primaryKeyPosition 2. Default to -1."},logicalType:{type:"string",description:"The logical element data type.",enum:["string","date","number","integer","object","array","boolean"]},logicalTypeOptions:{type:"object",description:"Additional optional metadata to describe the logical type."},physicalType:{type:"string",description:"The physical element data type in the data source. For example, VARCHAR(2), DOUBLE, INT."},physicalName:{type:"string",description:"Physical name.",examples:["col_str_a"]},required:{type:"boolean",default:!1,description:"Indicates if the element may contain Null values; possible values are true and false. Default is false."},unique:{type:"boolean",default:!1,description:"Indicates if the element contains unique values; possible values are true and false. Default is false."},partitioned:{type:"boolean",default:!1,description:"Indicates if the element is partitioned; possible values are true and false."},partitionKeyPosition:{type:"integer",default:-1,description:"If element is used for partitioning, the position of the partition element. Starts from 1. Example of `country, year` being partition columns, `country` has partitionKeyPosition 1 and `year` partitionKeyPosition 2. Default to -1."},classification:{type:"string",description:"Can be anything, like confidential, restricted, and public to more advanced categorization. Some companies like PayPal, use data classification indicating the class of data in the element; expected values are 1, 2, 3, 4, or 5.",examples:["confidential","restricted","public"]},encryptedName:{type:"string",description:"The element name within the dataset that contains the encrypted element value. For example, unencrypted element `email_address` might have an encryptedName of `email_address_encrypt`."},transformSourceObjects:{type:"array",description:"List of objects in the data source used in the transformation.",items:{type:"string"}},transformLogic:{type:"string",description:"Logic used in the element transformation."},transformDescription:{type:"string",description:"Describes the transform logic in very simple terms."},examples:{type:"array",description:"List of sample element values.",items:{$ref:"#/$defs/AnyType"}},criticalDataElement:{type:"boolean",default:!1,description:"True or false indicator; If element is considered a critical data element (CDE) then true else false."},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"},{if:{properties:{logicalType:{const:"string"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{minLength:{type:"integer",minimum:0,description:"Minimum length of the string."},maxLength:{type:"integer",minimum:0,description:"Maximum length of the string."},pattern:{type:"string",description:"Regular expression pattern to define valid value. Follows regular expression syntax from ECMA-262 (https://262.ecma-international.org/5.1/#sec-15.10.1)."},format:{type:"string",examples:["password","byte","binary","email","uuid","uri","hostname","ipv4","ipv6"],description:"Provides extra context about what format the string follows."}},additionalProperties:!1}}}},{if:{properties:{logicalType:{const:"date"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{format:{type:"string",examples:["yyyy-MM-dd","yyyy-MM-dd HH:mm:ss","HH:mm:ss"],description:"Format of the date. Follows the format as prescribed by [JDK DateTimeFormatter](https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html). For example, format 'yyyy-MM-dd'."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},maximum:{type:"string",description:"All date values are less than or equal to this value (values <= maximum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},minimum:{type:"string",description:"All date values are greater than or equal to this value (values >= minimum)."}},additionalProperties:!1}}}},{if:{anyOf:[{properties:{logicalType:{const:"integer"}}}]},then:{properties:{logicalTypeOptions:{type:"object",properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use and whether it is signed or unsigned (follows the Rust integer types).",enum:["i8","i16","i32","i64","i128","u8","u16","u32","u64","u128"]}},additionalProperties:!1}}}},{if:{anyOf:[{properties:{logicalType:{const:"number"}}}]},then:{properties:{logicalTypeOptions:{type:"object",properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"boolean",default:!1,description:"If set to true, all values are strictly less than the maximum value (values < maximum). Otherwise, less than or equal to the maximum value (values <= maximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"boolean",default:!1,description:"If set to true, all values are strictly greater than the minimum value (values > minimum). Otherwise, greater than or equal to the minimum value (values >= minimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use (follows the Rust float types).",enum:["f32","f64"]}},additionalProperties:!1}}}},{if:{properties:{logicalType:{const:"object"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{maxProperties:{type:"integer",minimum:0,description:"Maximum number of properties."},minProperties:{type:"integer",minimum:0,default:0,description:"Minimum number of properties."},required:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0,description:"Property names that are required to exist in the object."}},additionalProperties:!1},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}}}},{if:{properties:{logicalType:{const:"array"}}},then:{properties:{logicalTypeOptions:{type:"object",properties:{maxItems:{type:"integer",minimum:0,description:"Maximum number of items."},minItems:{type:"integer",minimum:0,default:0,description:"Minimum number of items"},uniqueItems:{type:"boolean",default:!1,description:"If set to true, all items in the array are unique."}},additionalProperties:!1},items:{$ref:"#/$defs/SchemaItemProperty",description:"List of items in an array (only applicable when `logicalType: array`)."}}}}]},SchemaProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",required:["name"],unevaluatedProperties:!1},SchemaItemProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",properties:{properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}},unevaluatedProperties:!1},Tags:{type:"array",description:"A list of tags that may be assigned to the elements (object or property); the tags keyword may appear at any level. Tags may be used to better categorize an element. For example, `finance`, `sensitive`, `employee_record`.",examples:["finance","sensitive","employee_record"],items:{type:"string"}},DataQuality:{type:"object",properties:{authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},businessImpact:{type:"string",description:"Consequences of the rule failure.",examples:["operational","regulatory"]},customProperties:{type:"array",description:"Additional properties required for rule execution.",items:{$ref:"#/$defs/CustomProperty"}},description:{type:"string",description:"Describe the quality check to be completed."},dimension:{type:"string",description:"The key performance indicator (KPI) or dimension for data quality.",enum:["accuracy","completeness","conformity","consistency","coverage","timeliness","uniqueness"]},method:{type:"string",examples:["reconciliation"]},name:{type:"string",description:"Name of the data quality check."},schedule:{type:"string",description:"Rule execution schedule details.",examples:["0 20 * * *"]},scheduler:{type:"string",description:"The name or type of scheduler used to start the data quality check.",examples:["cron"]},severity:{type:"string",description:"The severance of the quality rule.",examples:["info","warning","error"]},tags:{$ref:"#/$defs/Tags"},type:{type:"string",description:"The type of quality check. 'text' is human-readable text that describes the quality of the data. 'library' is a set of maintained predefined quality attributes such as row count or unique. 'sql' is an individual SQL query that returns a value that can be compared. 'custom' is quality attributes that are vendor-specific, such as Soda or Great Expectations.",enum:["text","library","sql","custom"],default:"library"},unit:{type:"string",description:"Unit the rule is using, popular values are `rows` or `percent`, but any value is allowed.",examples:["rows","percent"]}},allOf:[{if:{properties:{type:{const:"library"}}},then:{$ref:"#/$defs/DataQualityLibrary"}},{if:{properties:{type:{const:"sql"}},required:["type"]},then:{$ref:"#/$defs/DataQualitySql"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/DataQualityCustom"}}]},DataQualityChecks:{type:"array",description:"Data quality rules with all the relevant information for rule setup and execution.",items:{$ref:"#/$defs/DataQuality"}},DataQualityLibrary:{type:"object",properties:{rule:{type:"string",description:"Define a data quality check based on the predefined rules as per ODCS.",examples:["duplicateCount","validValues","rowCount"]},mustBe:{description:"Must be equal to the value to be valid. When using numbers, it is equivalent to '='."},mustNotBe:{description:"Must not be equal to the value to be valid. When using numbers, it is equivalent to '!='."},mustBeGreaterThan:{type:"number",description:"Must be greater than the value to be valid. It is equivalent to '>'."},mustBeGreaterOrEqualTo:{type:"number",description:"Must be greater than or equal to the value to be valid. It is equivalent to '>='."},mustBeLessThan:{type:"number",description:"Must be less than the value to be valid. It is equivalent to '<'."},mustBeLessOrEqualTo:{type:"number",description:"Must be less than or equal to the value to be valid. It is equivalent to '<='."},mustBeBetween:{type:"array",description:"Must be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}},mustNotBeBetween:{type:"array",description:"Must not be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}}},required:["rule"]},DataQualitySql:{type:"object",properties:{query:{type:"string",description:"Query string that adheres to the dialect of the provided server.",examples:["SELECT COUNT(*) FROM ${table} WHERE ${column} IS NOT NULL"]}},required:["query"]},DataQualityCustom:{type:"object",properties:{engine:{type:"string",description:"Name of the engine which executes the data quality checks.",examples:["soda","great-expectations","monte-carlo","dbt"]},implementation:{oneOf:[{type:"string"},{type:"object"}]}},required:["engine","implementation"]},AuthoritativeDefinitions:{type:"array",description:"List of links to sources that provide more details on the dataset; examples would be a link to an external definition, a training video, a git repo, data catalog, or another tool. Authoritative definitions follow the same structure in the standard.",items:{type:"object",properties:{url:{type:"string",description:"URL to the authority."},type:{type:"string",description:"Type of definition for authority: v2.3 adds standard values: `businessDefinition`, `transformationImplementation`, `videoTutorial`, `tutorial`, and `implementation`.",examples:["businessDefinition","transformationImplementation","videoTutorial","tutorial","implementation"]}},required:["url","type"]}},Support:{type:"array",description:"Top level for support channels.",items:{$ref:"#/$defs/SupportItem"}},SupportItem:{type:"object",properties:{channel:{type:"string",description:"Channel name or identifier."},url:{type:"string",description:"Access URL using normal [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax) (https, mailto, etc.)."},description:{type:"string",description:"Description of the channel, free text."},tool:{type:"string",description:"Name of the tool, value can be `email`, `slack`, `teams`, `discord`, `ticket`, or `other`.",examples:["email","slack","teams","discord","ticket","other"]},scope:{type:"string",description:"Scope can be: `interactive`, `announcements`, `issues`.",examples:["interactive","announcements","issues"]},invitationUrl:{type:"string",description:"Some tools uses invitation URL for requesting or subscribing. Follows the [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax)."}},required:["channel","url"]},Pricing:{type:"object",properties:{priceAmount:{type:"number",description:"Subscription price per unit of measure in `priceUnit`."},priceCurrency:{type:"string",description:"Currency of the subscription price in `price.priceAmount`."},priceUnit:{type:"string",description:"The unit of measure for calculating cost. Examples megabyte, gigabyte."}}},Team:{type:"object",properties:{username:{type:"string",description:"The user's username or email.",examples:["mail@example.com","uid12345678"]},name:{type:"string",description:"The user's name.",examples:["Jane Doe"]},description:{type:"string",description:"The user's description."},role:{type:"string",description:"The user's job role; Examples might be owner, data steward. There is no limit on the role."},dateIn:{type:"string",format:"date",description:"The date when the user joined the team."},dateOut:{type:"string",format:"date",description:"The date when the user ceased to be part of the team."},replacedByUsername:{type:"string",description:"The username of the user who replaced the previous user."}}},Role:{type:"object",properties:{role:{type:"string",description:"Name of the IAM role that provides access to the dataset."},description:{type:"string",description:"Description of the IAM role and its permissions."},access:{type:"string",description:"The type of access provided by the IAM role."},firstLevelApprovers:{type:"string",description:"The name(s) of the first-level approver(s) of the role."},secondLevelApprovers:{type:"string",description:"The name(s) of the second-level approver(s) of the role."},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["role"]},ServiceLevelAgreementProperty:{type:"object",properties:{property:{type:"string",description:"Specific property in SLA, check the periodic table. May requires units (more details to come)."},value:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}],description:"Agreement value. The label will change based on the property itself."},valueExt:{$ref:"#/$defs/AnyNonCollectionType",description:"Extended agreement value. The label will change based on the property itself."},unit:{type:"string",description:"**d**, day, days for days; **y**, yr, years for years, etc. Units use the ISO standard."},element:{type:"string",description:"Element(s) to check on. Multiple elements should be extremely rare and, if so, separated by commas."},driver:{type:"string",description:"Describes the importance of the SLA from the list of: `regulatory`, `analytics`, or `operational`.",examples:["regulatory","analytics","operational"]}},required:["property","value"]},CustomProperties:{type:"array",description:"A list of key/value pairs for custom properties.",items:{$ref:"#/$defs/CustomProperty"}},CustomProperty:{type:"object",properties:{property:{type:"string",description:"The name of the key. Names should be in camel case–the same as if they were permanent properties in the contract."},value:{$ref:"#/$defs/AnyType",description:"The value of the key."}}},AnyType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"},{type:"array"},{type:"object"}]},AnyNonCollectionType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}]}}};var nse={$schema:"https://json-schema.org/draft/2019-09/schema",title:"Open Data Contract Standard (ODCS)",description:"An open data contract specification to establish agreement between data producers and consumers.",type:"object",properties:{version:{type:"string",description:"Current version of the data contract."},kind:{type:"string",default:"DataContract",description:"The kind of file this is. Valid value is `DataContract`.",enum:["DataContract"]},apiVersion:{type:"string",default:"v3.1.0",description:"Version of the standard used to build data contract. Default value is v3.1.0.",enum:["v3.1.0","v3.0.2","v3.0.1","v3.0.0","v2.2.2","v2.2.1","v2.2.0"]},id:{type:"string",description:"A unique identifier used to reduce the risk of dataset name collisions, such as a UUID."},name:{type:"string",description:"Name of the data contract."},tenant:{type:"string",description:"Indicates the property the data is primarily associated with. Value is case insensitive."},tags:{$ref:"#/$defs/Tags"},status:{type:"string",description:"Current status of the dataset.",examples:["proposed","draft","active","deprecated","retired"]},servers:{type:"array",description:"List of servers where the datasets reside.",items:{$ref:"#/$defs/Server"}},dataProduct:{type:"string",description:"The name of the data product. DEPRECATED since v3.1.0.",deprecated:!0},description:{type:"object",description:"High level description of the dataset.",properties:{usage:{type:"string",description:"Intended usage of the dataset."},purpose:{type:"string",description:"Purpose of the dataset."},limitations:{type:"string",description:"Limitations of the dataset."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"}}},domain:{type:"string",description:"Name of the logical data domain.",examples:["imdb_ds_aggregate","receiver_profile_out","transaction_profile_out"]},schema:{type:"array",description:"A list of elements within the schema to be cataloged.",items:{$ref:"#/$defs/SchemaObject"}},support:{$ref:"#/$defs/Support"},price:{$ref:"#/$defs/Pricing"},team:{oneOf:[{$ref:"#/$defs/Team",description:"Team information object with members array (v3.1.0+)."},{type:"array",description:"DEPRECATED: Array of team members. Use the Team object structure instead. This array format is maintained for backward compatibility with v3.0.2 and earlier versions and will be removed in ODCS 4.0.",deprecated:!0,items:{$ref:"#/$defs/TeamMember"}}]},roles:{type:"array",description:"A list of roles that will provide user access to the dataset.",items:{$ref:"#/$defs/Role"}},slaDefaultElement:{type:"string",description:"DEPRECATED SINCE 3.1. WILL BE REMOVED IN ODCS 4.0. Element (using the element path notation) to do the checks on.",deprecated:!0},slaProperties:{type:"array",description:"A list of key/value pairs for SLA specific properties. There is no limit on the type of properties (more details to come).",items:{$ref:"#/$defs/ServiceLevelAgreementProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"},contractCreatedTs:{type:"string",format:"date-time",description:"Timestamp in UTC of when the data contract was created."}},required:["version","apiVersion","kind","id","status"],additionalProperties:!1,unevaluatedProperties:!1,$defs:{ShorthandReference:{type:"string",description:"Shorthand notation using name fields (table_name.column_name)",pattern:"^[A-Za-z_][A-Za-z0-9_\\-]*(\\.[A-Za-z_][A-Za-z0-9_\\-]*)+$"},FullyQualifiedReference:{type:"string",description:"Fully qualified notation using id fields (section/id/properties/id), optionally prefixed with external file reference",pattern:"^(?:(?:https?:\\/\\/)?[A-Za-z0-9._\\-\\/]+\\.yaml#)?\\/?[A-Za-z_][A-Za-z0-9_]*\\/[^\\s.#/\\\\@!%&^]+(?:\\/[A-Za-z_][A-Za-z0-9_]*\\/[^\\s.#/\\\\@!%&^]+)*$"},StableId:{type:"string",description:"Stable technical identifier for references. Must be unique within its containing array. Per RFC-0026a an id cannot contain '.', '#', '/', '\\', '@', '!', '%', '&' or '^', nor whitespace.",pattern:"^[^\\s.#/\\\\@!%&^]+$"},Server:{type:"object",description:"Data source details of where data is physically stored.",properties:{id:{$ref:"#/$defs/StableId"},server:{type:"string",description:"Identifier of the server."},type:{type:"string",description:"Type of the server.",enum:["api","athena","azure","bigquery","clickhouse","databricks","denodo","dremio","duckdb","glue","cloudsql","db2","hive","impala","informix","kafka","kinesis","local","mysql","oracle","postgresql","postgres","presto","pubsub","redshift","s3","sftp","snowflake","sqlserver","synapse","trino","vertica","zen","custom"]},description:{type:"string",description:"Description of the server."},environment:{type:"string",description:"Environment of the server.",examples:["prod","preprod","dev","uat"]},roles:{type:"array",description:"List of roles that have access to the server.",items:{$ref:"#/$defs/Role"}},customProperties:{$ref:"#/$defs/CustomProperties"}},allOf:[{if:{properties:{type:{const:"api"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ApiServer"}},{if:{properties:{type:{const:"athena"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AthenaServer"}},{if:{properties:{type:{const:"azure"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AzureServer"}},{if:{properties:{type:{const:"bigquery"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/BigQueryServer"}},{if:{properties:{type:{const:"clickhouse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ClickHouseServer"}},{if:{properties:{type:{const:"databricks"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DatabricksServer"}},{if:{properties:{type:{const:"denodo"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DenodoServer"}},{if:{properties:{type:{const:"dremio"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DremioServer"}},{if:{properties:{type:{const:"duckdb"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DuckdbServer"}},{if:{properties:{type:{const:"glue"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GlueServer"}},{if:{properties:{type:{const:"cloudsql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GoogleCloudSqlServer"}},{if:{properties:{type:{const:"db2"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/IBMDB2Server"}},{if:{properties:{type:{const:"hive"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/HiveServer"}},{if:{properties:{type:{const:"impala"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ImpalaServer"}},{if:{properties:{type:{const:"informix"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/InformixServer"}},{if:{properties:{type:{const:"zen"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ZenServer"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/CustomServer"}},{if:{properties:{type:{const:"kafka"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KafkaServer"}},{if:{properties:{type:{const:"kinesis"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KinesisServer"}},{if:{properties:{type:{const:"local"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/LocalServer"}},{if:{properties:{type:{const:"mysql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/MySqlServer"}},{if:{properties:{type:{const:"oracle"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/OracleServer"}},{if:{properties:{type:{const:"postgresql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"postgres"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"presto"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PrestoServer"}},{if:{properties:{type:{const:"pubsub"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PubSubServer"}},{if:{properties:{type:{const:"redshift"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/RedshiftServer"}},{if:{properties:{type:{const:"s3"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/S3Server"}},{if:{properties:{type:{const:"sftp"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SftpServer"}},{if:{properties:{type:{const:"snowflake"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SnowflakeServer"}},{if:{properties:{type:{const:"sqlserver"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SqlserverServer"}},{if:{properties:{type:{const:"synapse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SynapseServer"}},{if:{properties:{type:{const:"trino"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/TrinoServer"}},{if:{properties:{type:{const:"vertica"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/VerticaServer"}}],required:["server","type"],unevaluatedProperties:!1},ServerSource:{ApiServer:{type:"object",title:"ApiServer",properties:{location:{type:"string",format:"uri",description:"The url to the API.",examples:["https://api.example.com/v1"]}},required:["location"]},AthenaServer:{type:"object",title:"AthenaServer",properties:{stagingDir:{type:"string",format:"uri",description:"Amazon Athena automatically stores query results and metadata information for each query that runs in a query result location that you can specify in Amazon S3.",examples:["s3://my_storage_account_name/my_container/path"]},schema:{type:"string",description:"Identify the schema in the data source in which your tables exist."},catalog:{type:"string",description:"Identify the name of the Data Source, also referred to as a Catalog.",default:"awsdatacatalog"},regionName:{type:"string",description:"The region your AWS account uses.",examples:["eu-west-1"]}},required:["stagingDir","schema"]},AzureServer:{type:"object",title:"AzureServer",properties:{location:{type:"string",format:"uri",description:"Fully qualified path to Azure Blob Storage or Azure Data Lake Storage (ADLS), supports globs.",examples:["az://my_storage_account_name.blob.core.windows.net/my_container/path/*.parquet","abfss://my_storage_account_name.dfs.core.windows.net/my_container_name/path/*.parquet"]},format:{type:"string",examples:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",examples:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location","format"]},BigQueryServer:{type:"object",title:"BigQueryServer",properties:{project:{type:"string",description:"The GCP project name."},dataset:{type:"string",description:"The GCP dataset name."}},required:["project","dataset"]},ClickHouseServer:{type:"object",title:"ClickHouseServer",properties:{host:{type:"string",description:"The host of the ClickHouse server."},port:{type:"integer",description:"The port to the ClickHouse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},DatabricksServer:{type:"object",title:"DatabricksServer",properties:{host:{type:"string",description:"The Databricks host",examples:["dbc-abcdefgh-1234.cloud.databricks.com"]},catalog:{type:"string",description:"The name of the Hive or Unity catalog"},schema:{type:"string",description:"The schema name in the catalog"}},required:["catalog","schema"]},DenodoServer:{type:"object",title:"DenodoServer",properties:{host:{type:"string",description:"The host of the Denodo server."},port:{type:"integer",description:"The port of the Denodo server."},database:{type:"string",description:"The name of the database."}},required:["host","port"]},DremioServer:{type:"object",title:"DremioServer",properties:{host:{type:"string",description:"The host of the Dremio server."},port:{type:"integer",description:"The port of the Dremio server."},schema:{type:"string",description:"The name of the schema."}},required:["host","port"]},DuckdbServer:{type:"object",title:"DuckdbServer",properties:{database:{type:"string",description:"Path to duckdb database file."},schema:{type:"string",description:"The name of the schema."}},required:["database"]},GlueServer:{type:"object",title:"GlueServer",properties:{account:{type:"string",description:"The AWS Glue account",examples:["1234-5678-9012"]},database:{type:"string",description:"The AWS Glue database name",examples:["my_database"]},location:{type:"string",format:"uri",description:"The AWS S3 path. Must be in the form of a URL.",examples:["s3://datacontract-example-orders-latest/data/{model}"]},format:{type:"string",description:"The format of the files",examples:["parquet","csv","json","delta"]}},required:["account","database"]},GoogleCloudSqlServer:{type:"object",title:"GoogleCloudSqlServer",properties:{host:{type:"string",description:"The host of the Google Cloud Sql server."},port:{type:"integer",description:"The port of the Google Cloud Sql server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]},IBMDB2Server:{type:"object",title:"IBMDB2Server",properties:{host:{type:"string",description:"The host of the IBM DB2 server."},port:{type:"integer",description:"The port of the IBM DB2 server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database"]},HiveServer:{type:"object",title:"HiveServer",properties:{host:{type:"string",description:"The host to the Hive server. "},port:{type:"integer",description:"The port to the Hive server. Defaults to 10000."},database:{type:"string",description:"The name of the Hive database."}},required:["host","database"]},ImpalaServer:{type:"object",title:"ImpalaServer",properties:{host:{type:"string",description:"The host to the Impala server."},port:{type:"integer",description:"The port to the Impala server. Defaults to 21050."},database:{type:"string",description:"The name of the Impala database."}},required:["host","database"]},InformixServer:{type:"object",title:"InformixServer",properties:{host:{type:"string",description:"The host to the Informix server. "},port:{type:"integer",description:"The port to the Informix server. Defaults to 9088."},database:{type:"string",description:"The name of the database."}},required:["host","database"]},ZenServer:{type:"object",title:"ZenServer",properties:{host:{type:"string",description:"Hostname or IP address of the Zen server."},port:{type:"integer",description:"Zen server SQL connections port. Defaults to 1583."},database:{type:"string",description:"Database name to connect to on the Zen server."}},required:["host","database"]},CustomServer:{type:"object",title:"CustomServer",properties:{account:{type:"string",description:"Account used by the server."},catalog:{type:"string",description:"Name of the catalog."},database:{type:"string",description:"Name of the database."},dataset:{type:"string",description:"Name of the dataset."},delimiter:{type:"string",description:"Delimiter."},endpointUrl:{type:"string",description:"Server endpoint.",format:"uri"},format:{type:"string",description:"File format."},host:{type:"string",description:"Host name or IP address."},location:{type:"string",description:"A URL to a location.",format:"uri"},path:{type:"string",description:"Relative or absolute path to the data file(s)."},port:{type:"integer",description:"Port to the server. No default value is assumed for custom servers."},project:{type:"string",description:"Project name."},region:{type:"string",description:"Cloud region."},regionName:{type:"string",description:"Region name."},schema:{type:"string",description:"Name of the schema."},serviceName:{type:"string",description:"Name of the service."},stagingDir:{type:"string",description:"Staging directory."},warehouse:{type:"string",description:"Name of the cluster or warehouse."},stream:{type:"string",description:"Name of the data stream."}}},KafkaServer:{type:"object",title:"KafkaServer",description:"Kafka Server",properties:{host:{type:"string",description:"The bootstrap server of the kafka cluster."},format:{type:"string",description:"The format of the messages.",examples:["json","avro","protobuf","xml"],default:"json"}},required:["host"]},KinesisServer:{type:"object",title:"KinesisDataStreamsServer",description:"Kinesis Data Streams Server",properties:{region:{type:"string",description:"AWS region.",examples:["eu-west-1"]},format:{type:"string",description:"The format of the record",examples:["json","avro","protobuf"]}}},LocalServer:{type:"object",title:"LocalServer",properties:{path:{type:"string",description:"The relative or absolute path to the data file(s).",examples:["./folder/data.parquet","./folder/*.parquet"]},format:{type:"string",description:"The format of the file(s)",examples:["json","parquet","delta","csv"]}},required:["path","format"]},MySqlServer:{type:"object",title:"MySqlServer",properties:{host:{type:"string",description:"The host of the MySql server."},port:{type:"integer",description:"The port of the MySql server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},OracleServer:{type:"object",title:"OracleServer",properties:{host:{type:"string",description:"The host to the oracle server",examples:["localhost"]},port:{type:"integer",description:"The port to the oracle server.",examples:[1523]},serviceName:{type:"string",description:"The name of the service.",examples:["service"]}},required:["host","port","serviceName"]},PostgresServer:{type:"object",title:"PostgresServer",properties:{host:{type:"string",description:"The host to the Postgres server"},port:{type:"integer",description:"The port to the Postgres server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema in the database."}},required:["host","port","database","schema"]},PrestoServer:{type:"object",title:"PrestoServer",properties:{host:{type:"string",description:"The host to the Presto server",examples:["localhost:8080"]},catalog:{type:"string",description:"The name of the catalog.",examples:["postgres"]},schema:{type:"string",description:"The name of the schema.",examples:["public"]}},required:["host"]},PubSubServer:{type:"object",title:"PubSubServer",properties:{project:{type:"string",description:"The GCP project name."}},required:["project"]},RedshiftServer:{type:"object",title:"RedshiftServer",properties:{host:{type:"string",description:"An optional string describing the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},region:{type:"string",description:"AWS region of Redshift server.",examples:["us-east-1"]},account:{type:"string",description:"The account used by the server."}},required:["database","schema"]},S3Server:{type:"object",title:"S3Server",properties:{location:{type:"string",format:"uri",description:"S3 URL, starting with `s3://`",examples:["s3://datacontract-example-orders-latest/data/{model}/*.json"]},endpointUrl:{type:"string",format:"uri",description:"The server endpoint for S3-compatible servers.",examples:["https://minio.example.com"]},format:{type:"string",examples:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",examples:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SftpServer:{type:"object",title:"SftpServer",properties:{location:{type:"string",format:"uri",pattern:"^sftp://.*",description:"SFTP URL, starting with `sftp://`",examples:["sftp://123.123.12.123/{model}/*.json"]},format:{type:"string",examples:["parquet","delta","json","csv"],description:"File format."},delimiter:{type:"string",examples:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SnowflakeServer:{type:"object",title:"SnowflakeServer",properties:{host:{type:"string",description:"The host to the Snowflake server"},port:{type:"integer",description:"The port to the Snowflake server."},account:{type:"string",description:"The Snowflake account used by the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},warehouse:{type:"string",description:"The name of the cluster of resources that is a Snowflake virtual warehouse."}},required:["account","database","schema"]},SqlserverServer:{type:"object",title:"SqlserverServer",properties:{host:{type:"string",description:"The host to the database server",examples:["localhost"]},port:{type:"integer",description:"The port to the database server.",default:1433,examples:[1433]},database:{type:"string",description:"The name of the database.",examples:["database"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["dbo"]}},required:["host","database","schema"]},SynapseServer:{type:"object",title:"SynapseServer",properties:{host:{type:"string",description:"The host of the Synapse server."},port:{type:"integer",description:"The port of the Synapse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},TrinoServer:{type:"object",title:"TrinoServer",properties:{host:{type:"string",description:"The Trino host URL.",examples:["localhost"]},port:{type:"integer",description:"The Trino port."},catalog:{type:"string",description:"The name of the catalog.",examples:["hive"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["my_schema"]}},required:["host","port","catalog","schema"]},VerticaServer:{type:"object",title:"VerticaServer",properties:{host:{type:"string",description:"The host of the Vertica server."},port:{type:"integer",description:"The port of the Vertica server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]}},SchemaElement:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},name:{type:"string",description:"Name of the element."},physicalType:{type:"string",description:"The physical element data type in the data source.",examples:["table","view","topic","file"]},description:{type:"string",description:"Description of the element."},businessName:{type:"string",description:"The business name of the element."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{$ref:"#/$defs/Tags"},customProperties:{$ref:"#/$defs/CustomProperties"}}},SchemaObject:{type:"object",properties:{logicalType:{type:"string",description:"The logical element data type.",enum:["object"]},physicalName:{type:"string",description:"Physical name.",examples:["table_1_2_0"]},dataGranularityDescription:{type:"string",description:"Granular level of the data in the object.",examples:["Aggregation by country"]},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}},relationships:{type:"array",description:"A list of relationships to other properties. Each relationship must have 'from', 'to' and optionally 'type' field.",items:{$ref:"#/$defs/RelationshipSchemaLevel"}},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"}],required:["name"],unevaluatedProperties:!1},SchemaBaseProperty:{type:"object",properties:{primaryKey:{type:"boolean",description:"Boolean value specifying whether the element is primary or not. Default is false."},primaryKeyPosition:{type:"integer",default:-1,description:"If element is a primary key, the position of the primary key element. Starts from 1. Example of `account_id, name` being primary key columns, `account_id` has primaryKeyPosition 1 and `name` primaryKeyPosition 2. Default to -1."},logicalType:{type:"string",description:"The logical element data type.",enum:["string","date","timestamp","time","number","integer","object","array","boolean"]},logicalTypeOptions:{type:"object",description:"Additional optional metadata to describe the logical type."},physicalType:{type:"string",description:"The physical element data type in the data source. For example, VARCHAR(2), DOUBLE, INT."},physicalName:{type:"string",description:"Physical name.",examples:["col_str_a"]},required:{type:"boolean",default:!1,description:"Indicates if the element may contain Null values; possible values are true and false. Default is false."},unique:{type:"boolean",default:!1,description:"Indicates if the element contains unique values; possible values are true and false. Default is false."},partitioned:{type:"boolean",default:!1,description:"Indicates if the element is partitioned; possible values are true and false."},partitionKeyPosition:{type:"integer",default:-1,description:"If element is used for partitioning, the position of the partition element. Starts from 1. Example of `country, year` being partition columns, `country` has partitionKeyPosition 1 and `year` partitionKeyPosition 2. Default to -1."},classification:{type:"string",description:"Can be anything, like confidential, restricted, and public to more advanced categorization. Some companies like PayPal, use data classification indicating the class of data in the element; expected values are 1, 2, 3, 4, or 5.",examples:["confidential","restricted","public"]},encryptedName:{type:"string",description:"The element name within the dataset that contains the encrypted element value. For example, unencrypted element `email_address` might have an encryptedName of `email_address_encrypt`."},transformSourceObjects:{type:"array",description:"List of objects in the data source used in the transformation.",items:{type:"string"}},transformLogic:{type:"string",description:"Logic used in the element transformation."},transformDescription:{type:"string",description:"Describes the transform logic in very simple terms."},examples:{type:"array",description:"List of sample element values.",items:{$ref:"#/$defs/AnyType"}},criticalDataElement:{type:"boolean",default:!1,description:"True or false indicator; If element is considered a critical data element (CDE) then true else false."},relationships:{type:"array",description:"A list of relationships to other properties. When defined at property level, the 'from' field is implicit and should not be specified.",items:{$ref:"#/$defs/RelationshipPropertyLevel"}},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"},{if:{properties:{logicalType:{const:"string"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{minLength:{type:"integer",minimum:0,description:"Minimum length of the string."},maxLength:{type:"integer",minimum:0,description:"Maximum length of the string."},pattern:{type:"string",description:"Regular expression pattern to define valid value. Follows regular expression syntax from ECMA-262 (https://262.ecma-international.org/5.1/#sec-15.10.1)."},format:{type:"string",examples:["password","byte","binary","email","uuid","uri","hostname","ipv4","ipv6"],description:"Provides extra context about what format the string follows."}}}}}},{if:{properties:{logicalType:{const:"date"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{format:{type:"string",examples:["yyyy-MM-dd","yyyy-MM-dd HH:mm:ss","HH:mm:ss"],description:"Format of the date. Follows the format as prescribed by [JDK DateTimeFormatter](https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html). For example, format 'yyyy-MM-dd'."},exclusiveMaximum:{type:"string",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},maximum:{type:"string",description:"All date values are less than or equal to this value (values <= maximum)."},exclusiveMinimum:{type:"string",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},minimum:{type:"string",description:"All date values are greater than or equal to this value (values >= minimum)."}}}}}},{if:{anyOf:[{properties:{logicalType:{const:"timestamp"}}},{properties:{logicalType:{const:"time"}}}]},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{format:{type:"string",examples:["yyyy-MM-dd","yyyy-MM-dd HH:mm:ss","HH:mm:ss"],description:"Format of the date. Follows the format as prescribed by [JDK DateTimeFormatter](https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html). For example, format 'yyyy-MM-dd'."},exclusiveMaximum:{type:"string",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},maximum:{type:"string",description:"All date values are less than or equal to this value (values <= maximum)."},exclusiveMinimum:{type:"string",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},minimum:{type:"string",description:"All date values are greater than or equal to this value (values >= minimum)."},timezone:{type:"boolean",description:"Whether the timestamp defines the timezone or not. If true, timezone information is included in the timestamp."},defaultTimezone:{type:"string",description:"The default timezone of the timestamp. If timezone is not defined, the default timezone UTC is used.",default:"Etc/UTC"}}}}}},{if:{anyOf:[{properties:{logicalType:{const:"integer"}}}]},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"number",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"number",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use and whether it is signed or unsigned (follows the Rust integer types).",enum:["i8","i16","i32","i64","i128","u8","u16","u32","u64","u128"]}}}}}},{if:{anyOf:[{properties:{logicalType:{const:"number"}}}]},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"number",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"number",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use (follows the Rust float types).",enum:["f32","f64"]}}}}}},{if:{properties:{logicalType:{const:"object"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{maxProperties:{type:"integer",minimum:0,description:"Maximum number of properties."},minProperties:{type:"integer",minimum:0,default:0,description:"Minimum number of properties."},required:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0,description:"Property names that are required to exist in the object."}}},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}}}},{if:{properties:{logicalType:{const:"array"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{maxItems:{type:"integer",minimum:0,description:"Maximum number of items."},minItems:{type:"integer",minimum:0,default:0,description:"Minimum number of items"},uniqueItems:{type:"boolean",default:!1,description:"If set to true, all items in the array are unique."}}},items:{$ref:"#/$defs/SchemaItemProperty",description:"List of items in an array (only applicable when `logicalType: array`)."}}}}],unevaluatedProperties:!1},SchemaProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",required:["name"],unevaluatedProperties:!1},SchemaItemProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",properties:{properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}},unevaluatedProperties:!1},Tags:{type:"array",description:"A list of tags that may be assigned to the elements (object or property); the tags keyword may appear at any level. Tags may be used to better categorize an element. For example, `finance`, `sensitive`, `employee_record`.",examples:["finance","sensitive","employee_record"],items:{type:"string"}},DataQuality:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},businessImpact:{type:"string",description:"Consequences of the rule failure.",examples:["operational","regulatory"]},customProperties:{type:"array",description:"Additional properties required for rule execution.",items:{$ref:"#/$defs/CustomProperty"}},description:{type:"string",description:"Describe the quality check to be completed."},dimension:{type:"string",description:"The key performance indicator (KPI) or dimension for data quality.",enum:["accuracy","completeness","conformity","consistency","coverage","timeliness","uniqueness"]},method:{type:"string",examples:["reconciliation"]},name:{type:"string",description:"Name of the data quality check."},schedule:{type:"string",description:"Rule execution schedule details.",examples:["0 20 * * *"]},scheduler:{type:"string",description:"The name or type of scheduler used to start the data quality check.",examples:["cron"]},severity:{type:"string",description:"The severance of the quality rule.",examples:["info","warning","error"]},tags:{$ref:"#/$defs/Tags"},type:{type:"string",description:"The type of quality check. 'text' is human-readable text that describes the quality of the data. 'library' is a set of maintained predefined quality attributes such as row count or unique. 'sql' is an individual SQL query that returns a value that can be compared. 'custom' is quality attributes that are vendor-specific, such as Soda or Great Expectations.",enum:["text","library","sql","custom"],default:"library"},unit:{type:"string",description:"Unit the rule is using, popular values are `rows` or `percent`, but any value is allowed.",examples:["rows","percent"]}},allOf:[{if:{anyOf:[{properties:{type:{const:"library"}},required:["type"]},{properties:{metric:{type:"string"}},required:["metric"]}]},then:{$ref:"#/$defs/DataQualityLibrary"}},{if:{properties:{type:{const:"sql"}},required:["type"]},then:{$ref:"#/$defs/DataQualitySql"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/DataQualityCustom"}}],unevaluatedProperties:!1},DataQualityChecks:{type:"array",description:"Data quality rules with all the relevant information for rule setup and execution.",items:{$ref:"#/$defs/DataQuality"}},DataQualityOperators:{type:"object",description:"Common comparison operators for data quality checks.",oneOf:[{properties:{mustBe:{description:"Must be equal to the value to be valid. When using numbers, it is equivalent to '='."}},required:["mustBe"]},{properties:{mustNotBe:{description:"Must not be equal to the value to be valid. When using numbers, it is equivalent to '!='."}},required:["mustNotBe"]},{properties:{mustBeGreaterThan:{type:"number",description:"Must be greater than the value to be valid. It is equivalent to '>'."}},required:["mustBeGreaterThan"]},{properties:{mustBeGreaterOrEqualTo:{type:"number",description:"Must be greater than or equal to the value to be valid. It is equivalent to '>='."}},required:["mustBeGreaterOrEqualTo"]},{properties:{mustBeLessThan:{type:"number",description:"Must be less than the value to be valid. It is equivalent to '<'."}},required:["mustBeLessThan"]},{properties:{mustBeLessOrEqualTo:{type:"number",description:"Must be less than or equal to the value to be valid. It is equivalent to '<='."}},required:["mustBeLessOrEqualTo"]},{properties:{mustBeBetween:{type:"array",description:"Must be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}}},required:["mustBeBetween"]},{properties:{mustNotBeBetween:{type:"array",description:"Must not be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}}},required:["mustNotBeBetween"]}]},DataQualityLibrary:{type:"object",allOf:[{$ref:"#/$defs/DataQualityOperators"}],properties:{metric:{type:"string",description:"Define a data quality check based on the predefined metrics as per ODCS.",enum:["nullValues","missingValues","invalidValues","duplicateValues","rowCount"]},rule:{type:"string",deprecated:!0,description:"Use metric instead"},arguments:{type:"object",description:"Additional arguments for the metric, if needed."}},required:["metric"]},DataQualitySql:{type:"object",allOf:[{$ref:"#/$defs/DataQualityOperators"}],properties:{query:{type:"string",description:"Query string that adheres to the dialect of the provided server.",examples:["SELECT COUNT(*) FROM ${table} WHERE ${column} IS NOT NULL"]}},required:["query"]},DataQualityCustom:{type:"object",properties:{engine:{type:"string",description:"Name of the engine which executes the data quality checks.",examples:["soda","great-expectations","monte-carlo","dbt"]},implementation:{oneOf:[{type:"string"},{type:"object"}]}},required:["engine","implementation"]},AuthoritativeDefinitions:{type:"array",description:"List of links to sources that provide more details on the dataset; examples would be a link to an external definition, a training video, a git repo, data catalog, or another tool. Authoritative definitions follow the same structure in the standard.",items:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},url:{type:"string",description:"URL to the authority."},type:{type:"string",description:"Type of definition for authority: v2.3 adds standard values: `businessDefinition`, `transformationImplementation`, `videoTutorial`, `tutorial`, and `implementation`.",examples:["businessDefinition","transformationImplementation","videoTutorial","tutorial","implementation"]},description:{type:"string",description:"Description of the authoritative definition for humans."}},required:["url","type"],additionalProperties:!1}},Support:{type:"array",description:"Top level for support channels.",items:{$ref:"#/$defs/SupportItem"}},SupportItem:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},channel:{type:"string",description:"Channel name or identifier."},url:{type:"string",description:"Access URL using normal [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax) (https, mailto, etc.)."},description:{type:"string",description:"Description of the channel, free text."},tool:{type:"string",description:"Name of the tool, value can be `email`, `slack`, `teams`, `discord`, `ticket`, `googlechat`, or `other`.",examples:["email","slack","teams","discord","ticket","googlechat","other"]},scope:{type:"string",description:"Scope can be: `interactive`, `announcements`, `issues`, `notifications`.",examples:["interactive","announcements","issues","notifications"]},invitationUrl:{type:"string",description:"Some tools uses invitation URL for requesting or subscribing. Follows the [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax)."},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["channel"],additionalProperties:!1},Pricing:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},priceAmount:{type:"number",description:"Subscription price per unit of measure in `priceUnit`."},priceCurrency:{type:"string",description:"Currency of the subscription price in `price.priceAmount`."},priceUnit:{type:"string",description:"The unit of measure for calculating cost. Examples megabyte, gigabyte."}},additionalProperties:!1},TeamMember:{type:"object",description:"Team member information.",additionalProperties:!1,properties:{id:{$ref:"#/$defs/StableId"},username:{type:"string",description:"The user's username or email."},name:{type:"string",description:"The user's name."},description:{type:"string",description:"The user's description."},role:{type:"string",description:"The user's job role; Examples might be owner, data steward. There is no limit on the role."},dateIn:{type:"string",format:"date",description:"The date when the user joined the team."},dateOut:{type:"string",format:"date",description:"The date when the user ceased to be part of the team."},replacedByUsername:{type:"string",description:"The username of the user who replaced the previous user."},tags:{$ref:"#/$defs/Tags"},customProperties:{type:"array",description:"Custom properties block.",items:{$ref:"#/$defs/CustomProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"}},required:["username"]},Team:{type:"object",description:"Team information.",additionalProperties:!1,properties:{id:{$ref:"#/$defs/StableId"},name:{type:"string",description:"Team name."},description:{type:"string",description:"Team description."},members:{type:"array",description:"List of members.",items:{$ref:"#/$defs/TeamMember"}},tags:{$ref:"#/$defs/Tags"},customProperties:{type:"array",description:"Custom properties block.",items:{$ref:"#/$defs/CustomProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"}}},Role:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},role:{type:"string",description:"Name of the IAM role that provides access to the dataset."},description:{type:"string",description:"Description of the IAM role and its permissions."},access:{type:"string",description:"The type of access provided by the IAM role."},firstLevelApprovers:{type:"string",description:"The name(s) of the first-level approver(s) of the role."},secondLevelApprovers:{type:"string",description:"The name(s) of the second-level approver(s) of the role."},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["role"],additionalProperties:!1},ServiceLevelAgreementProperty:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},property:{type:"string",description:"Specific property in SLA, check the periodic table. May requires units (more details to come)."},value:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}],description:"Agreement value. The label will change based on the property itself."},valueExt:{$ref:"#/$defs/AnyNonCollectionType",description:"Extended agreement value. The label will change based on the property itself."},unit:{type:"string",description:"**d**, day, days for days; **y**, yr, years for years, etc. Units use the ISO standard."},element:{type:"string",description:"Element(s) to check on. Multiple elements should be extremely rare and, if so, separated by commas."},driver:{type:"string",description:"Describes the importance of the SLA from the list of: `regulatory`, `analytics`, or `operational`.",examples:["regulatory","analytics","operational"]},description:{type:"string",description:"Description of the SLA for humans.",examples:["99.9% of the time, data is available by 6 AM UTC"]},scheduler:{type:"string",description:"Name of the scheduler, can be cron or any tool your organization support.",examples:["cron"]},schedule:{type:"string",description:"Configuration information for the scheduling tool, for cron a possible value is 0 20 * * *.",examples:["0 20 * * *"]}},required:["property","value"],additionalProperties:!1},CustomProperties:{type:"array",description:"A list of key/value pairs for custom properties.",items:{$ref:"#/$defs/CustomProperty"}},CustomProperty:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},property:{type:"string",description:"The name of the key. Names should be in camel case–the same as if they were permanent properties in the contract."},value:{$ref:"#/$defs/AnyType",description:"The value of the key."},description:{type:"string",description:"Description of the custom property."}},required:["property","value"],additionalProperties:!1},AnyType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"},{type:"array"},{type:"object"}]},AnyNonCollectionType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}]},RelationshipBase:{type:"object",description:"Base definition for relationships between properties, typically for foreign key constraints.",properties:{type:{type:"string",description:"The type of relationship. Defaults to 'foreignKey'.",default:"foreignKey",enum:["foreignKey"]},from:{oneOf:[{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}],description:"Source property reference using fully qualified or shorthand notation."},{type:"array",description:"Array of source properties for composite keys.",items:{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}]},minItems:1}],description:"Source property or properties."},to:{oneOf:[{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}],description:"Target property reference using fully qualified or shorthand notation."},{type:"array",description:"Array of target properties for composite keys.",items:{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}]},minItems:1}],description:"Target property or properties to reference."},customProperties:{$ref:"#/$defs/CustomProperties"}}},RelationshipSchemaLevel:{type:"object",description:"Relationship definition at schema level, requiring both 'from' and 'to' fields with matching types.",allOf:[{$ref:"#/$defs/RelationshipBase"},{required:["from","to"]},{oneOf:[{description:"Single-column relationship - both fields must be strings",properties:{from:{type:"string"},to:{type:"string"}}},{description:"Composite key relationship - both fields must be arrays with matching lengths",properties:{from:{type:"array",items:{type:"string"},minItems:1},to:{type:"array",items:{type:"string"},minItems:1}}}]}],unevaluatedProperties:!1},RelationshipPropertyLevel:{type:"object",description:"Relationship definition at property level, where 'from' is implicitly the current property.",allOf:[{$ref:"#/$defs/RelationshipBase"},{type:"object",required:["to"]},{not:{required:["from"]},description:"The 'from' field must not be specified at property level as it is implicitly derived from the property context"}],unevaluatedProperties:!1},Relationship:{description:"Compatibility wrapper for relationship definitions.",oneOf:[{$ref:"#/$defs/RelationshipSchemaLevel"},{$ref:"#/$defs/RelationshipPropertyLevel"}]}}};var rse={$schema:"https://json-schema.org/draft/2019-09/schema",title:"Open Data Contract Standard (ODCS)",description:"An open data contract specification to establish agreement between data producers and consumers.",type:"object",properties:{version:{type:"string",description:"Current version of the data contract."},kind:{type:"string",default:"DataContract",description:"The kind of file this is. Valid value is `DataContract`.",enum:["DataContract"]},apiVersion:{type:"string",default:"v3.2.0",description:"Version of the standard used to build data contract. Default value is v3.2.0.",enum:["v3.2.0","v3.1.0","v3.0.2","v3.0.1","v3.0.0","v2.2.2","v2.2.1","v2.2.0"]},id:{type:"string",description:"A unique identifier used to reduce the risk of dataset name collisions, such as a UUID."},name:{type:"string",description:"Name of the data contract."},tenant:{type:"string",description:"Indicates the property the data is primarily associated with. Value is case insensitive."},tags:{$ref:"#/$defs/Tags"},status:{type:"string",description:"Current status of the dataset.",examples:["proposed","draft","active","deprecated","retired"]},servers:{type:"array",description:"List of servers where the datasets reside.",items:{$ref:"#/$defs/Server"}},dataProduct:{type:"string",description:"The name of the data product. DEPRECATED since v3.1.0.",deprecated:!0},description:{type:"object",description:"High level description of the dataset.",properties:{usage:{type:"string",description:"Intended usage of the dataset."},purpose:{type:"string",description:"Purpose of the dataset."},limitations:{type:"string",description:"Limitations of the dataset."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"}}},domain:{type:"string",description:"Name of the logical data domain.",examples:["imdb_ds_aggregate","receiver_profile_out","transaction_profile_out"]},context:{$ref:"#/$defs/Context"},schema:{type:"array",description:"A list of elements within the schema to be cataloged.",items:{$ref:"#/$defs/SchemaObject"}},support:{$ref:"#/$defs/Support"},price:{$ref:"#/$defs/Pricing"},team:{oneOf:[{$ref:"#/$defs/Team",description:"Team information object with members array (v3.1.0+)."},{type:"array",description:"DEPRECATED: Array of team members. Use the Team object structure instead. This array format is maintained for backward compatibility with v3.0.2 and earlier versions and will be removed in ODCS 4.0.",deprecated:!0,items:{$ref:"#/$defs/TeamMember"}}]},roles:{type:"array",description:"A list of roles that will provide user access to the dataset.",items:{$ref:"#/$defs/Role"}},slaDefaultElement:{type:"string",description:"DEPRECATED SINCE 3.1. WILL BE REMOVED IN ODCS 4.0. Element (using the element path notation) to do the checks on.",deprecated:!0},slaProperties:{type:"array",description:"A list of key/value pairs for SLA specific properties. There is no limit on the type of properties (more details to come).",items:{$ref:"#/$defs/ServiceLevelAgreementProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},customProperties:{$ref:"#/$defs/CustomProperties"},contractCreatedTs:{type:"string",format:"date-time",description:"Timestamp in UTC of when the data contract was created."}},required:["version","apiVersion","kind","id"],additionalProperties:!1,unevaluatedProperties:!1,$defs:{Context:{description:"AI and semantic context block (RFC-0038). Structured guidance for AI agents, LLMs, BI tools, and semantic layer platforms. Optional and additive.",oneOf:[{type:"string",description:"Shorthand: equivalent to providing instructions only."},{type:"object",properties:{instructions:{type:"string",description:"Natural language guidance for AI agents and tools on how to use this entity. Equivalent to a system prompt scoped to this level."},verifiedStatements:{type:"array",description:"Canonical questions (entries without `answer`) and verified Q&A pairs (entries with `answer`).",items:{type:"object",properties:{id:{type:"string",description:"Stable identifier for the entry."},question:{type:"string",description:"The canonical question."},answer:{type:"string",description:"The expected response or result description."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{type:"array",items:{type:"string"}},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["question"],additionalProperties:!1}},constraints:{type:"array",description:"Negative guidance: what AI agents must NOT do with this entity.",items:{type:"object",properties:{id:{type:"string",description:"Stable identifier for the constraint."},constraint:{type:"string",description:"The constraint text (negative guidance for AI agents)."},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{type:"array",items:{type:"string"}},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["constraint"],additionalProperties:!1}}},additionalProperties:!1}]},ShorthandReference:{type:"string",description:"Shorthand notation using name fields (table_name.column_name)",pattern:"^[A-Za-z_][A-Za-z0-9_\\-]*(\\.[A-Za-z_][A-Za-z0-9_\\-]*)+$"},FullyQualifiedReference:{type:"string",description:"Fully qualified notation using id fields (section/id/properties/id), optionally prefixed with external file reference",pattern:"^(?:(?:https?:\\/\\/)?[A-Za-z0-9._\\-\\/]+\\.ya?ml#)?\\/?[A-Za-z_][A-Za-z0-9_]*\\/[^\\s.#/\\\\@!%&^]+(?:\\/[A-Za-z_][A-Za-z0-9_]*\\/[^\\s.#/\\\\@!%&^]+)*$"},StableId:{type:"string",description:"Stable technical identifier for references. Must be unique within its containing array. Per RFC-0026a an id cannot contain '.', '#', '/', '\\', '@', '!', '%', '&' or '^', nor whitespace.",pattern:"^[^\\s.#/\\\\@!%&^]+$"},Port:{type:["integer","string"],description:"A network port: an integer, or a string, e.g. to hold a variable reference such as ${DB_PORT} resolved at runtime (RFC 0050)."},Server:{type:"object",description:"Data source details of where data is physically stored.",properties:{id:{$ref:"#/$defs/StableId"},server:{type:"string",description:"Identifier of the server."},type:{type:"string",description:"Type of the server.",enum:["api","athena","azure","bigquery","btrieve","clickhouse","databricks","denodo","dremio","duckdb","exasol","fastobjects","glue","hana","cloudsql","db2","hive","iceberg","impala","informix","ingres","kafka","kinesis","local","mysql","oracle","poet","postgresql","postgres","presto","pubsub","redshift","s3","sftp","snowflake","sqlserver","synapse","teradata","trino","vectorwise","versant","vertica","zen","custom"]},description:{type:"string",description:"Description of the server."},environment:{type:"string",description:"Environment of the server.",examples:["prod","preprod","dev","uat"]},roles:{type:"array",description:"List of roles that have access to the server.",items:{$ref:"#/$defs/Role"}},customProperties:{$ref:"#/$defs/CustomProperties"}},allOf:[{if:{properties:{type:{const:"api"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ApiServer"}},{if:{properties:{type:{const:"athena"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AthenaServer"}},{if:{properties:{type:{const:"azure"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/AzureServer"}},{if:{properties:{type:{const:"bigquery"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/BigQueryServer"}},{if:{properties:{type:{const:"btrieve"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ZenServer"}},{if:{properties:{type:{const:"clickhouse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ClickHouseServer"}},{if:{properties:{type:{const:"databricks"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DatabricksServer"}},{if:{properties:{type:{const:"denodo"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DenodoServer"}},{if:{properties:{type:{const:"dremio"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DremioServer"}},{if:{properties:{type:{const:"duckdb"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/DuckdbServer"}},{if:{properties:{type:{const:"exasol"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ExasolServer"}},{if:{properties:{type:{const:"fastobjects"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PoetServer"}},{if:{properties:{type:{const:"glue"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GlueServer"}},{if:{properties:{type:{const:"cloudsql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/GoogleCloudSqlServer"}},{if:{properties:{type:{const:"db2"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/IBMDB2Server"}},{if:{properties:{type:{const:"hive"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/HiveServer"}},{if:{properties:{type:{const:"impala"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ImpalaServer"}},{if:{properties:{type:{const:"informix"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/InformixServer"}},{if:{properties:{type:{const:"ingres"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/IngresServer"}},{if:{properties:{type:{const:"zen"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/ZenServer"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/CustomServer"}},{if:{properties:{type:{const:"kafka"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KafkaServer"}},{if:{properties:{type:{const:"kinesis"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/KinesisServer"}},{if:{properties:{type:{const:"local"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/LocalServer"}},{if:{properties:{type:{const:"mysql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/MySqlServer"}},{if:{properties:{type:{const:"oracle"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/OracleServer"}},{if:{properties:{type:{const:"poet"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PoetServer"}},{if:{properties:{type:{const:"hana"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/HanaServer"}},{if:{properties:{type:{const:"iceberg"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/IcebergServer"}},{if:{properties:{type:{const:"postgresql"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"postgres"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PostgresServer"}},{if:{properties:{type:{const:"presto"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PrestoServer"}},{if:{properties:{type:{const:"pubsub"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/PubSubServer"}},{if:{properties:{type:{const:"redshift"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/RedshiftServer"}},{if:{properties:{type:{const:"s3"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/S3Server"}},{if:{properties:{type:{const:"sftp"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SftpServer"}},{if:{properties:{type:{const:"snowflake"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SnowflakeServer"}},{if:{properties:{type:{const:"sqlserver"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SqlserverServer"}},{if:{properties:{type:{const:"synapse"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/SynapseServer"}},{if:{properties:{type:{const:"teradata"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/TeradataServer"}},{if:{properties:{type:{const:"trino"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/TrinoServer"}},{if:{properties:{type:{const:"vectorwise"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/VectorwiseServer"}},{if:{properties:{type:{const:"versant"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/VersantServer"}},{if:{properties:{type:{const:"vertica"}},required:["type"]},then:{$ref:"#/$defs/ServerSource/VerticaServer"}}],required:["server","type"],unevaluatedProperties:!1},ServerSource:{ApiServer:{type:"object",title:"AthenaServer",properties:{location:{type:"string",format:"uri",description:"The url to the API.",examples:["https://api.example.com/v1"]}},required:["location"]},AthenaServer:{type:"object",title:"AthenaServer",properties:{stagingDir:{type:"string",format:"uri",description:"Amazon Athena automatically stores query results and metadata information for each query that runs in a query result location that you can specify in Amazon S3.",examples:["s3://my_storage_account_name/my_container/path"]},schema:{type:"string",description:"Identify the schema in the data source in which your tables exist."},catalog:{type:"string",description:"Identify the name of the Data Source, also referred to as a Catalog.",default:"awsdatacatalog"},regionName:{type:"string",description:"The region your AWS account uses.",examples:["eu-west-1"]},workgroup:{type:"string",description:"The Athena workgroup to use. Workgroups can enforce query result location and other client-side settings via the 'Override client-side settings' option.",examples:["primary"]}},required:["schema"]},AzureServer:{type:"object",title:"AzureServer",properties:{location:{type:"string",format:"uri",description:"Fully qualified path to Azure Blob Storage or Azure Data Lake Storage (ADLS), supports globs.",examples:["az://my_storage_account_name.blob.core.windows.net/my_container/path/*.parquet","abfss://my_storage_account_name.dfs.core.windows.net/my_container_name/path/*.parquet"]},format:{type:"string",examples:["parquet","delta","json","csv"],description:"File format."},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]},delimiter:{type:"string",examples:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location","format"]},BigQueryServer:{type:"object",title:"BigQueryServer",properties:{project:{type:"string",description:"The GCP project name."},dataset:{type:"string",description:"The GCP dataset name."}},required:["project","dataset"]},ClickHouseServer:{type:"object",title:"ClickHouseServer",properties:{host:{type:"string",description:"The host of the ClickHouse server."},port:{$ref:"#/$defs/Port",description:"The port to the ClickHouse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},DatabricksServer:{type:"object",title:"DatabricksServer",properties:{host:{type:"string",description:"The Databricks host",examples:["dbc-abcdefgh-1234.cloud.databricks.com"]},catalog:{type:"string",description:"The name of the Hive or Unity catalog"},schema:{type:"string",description:"The schema name in the catalog"}},required:["catalog","schema"]},DenodoServer:{type:"object",title:"DenodoServer",properties:{host:{type:"string",description:"The host of the Denodo server."},port:{$ref:"#/$defs/Port",description:"The port of the Denodo server."},database:{type:"string",description:"The name of the database."}},required:["host","port"]},DremioServer:{type:"object",title:"DremioServer",properties:{host:{type:"string",description:"The host of the Dremio server."},port:{$ref:"#/$defs/Port",description:"The port of the Dremio server."},schema:{type:"string",description:"The name of the schema."}},required:["host","port"]},DuckdbServer:{type:"object",title:"DuckdbServer",properties:{database:{type:"string",description:"Path to duckdb database file."},schema:{type:"string",description:"The name of the schema."}},required:["database"]},ExasolServer:{type:"object",title:"ExasolServer",properties:{host:{type:"string",description:"Host of the Exasol server. May be a cluster connection range.",examples:["exasol.acme.com","n11..14.acme.com"]},port:{$ref:"#/$defs/Port",description:"Port of the Exasol server.",default:8563,examples:[8563]},schema:{type:"string",description:"Name of the schema."}},required:["host"]},GlueServer:{type:"object",title:"GlueServer",properties:{account:{type:"string",description:"The AWS Glue account",examples:["1234-5678-9012"]},database:{type:"string",description:"The AWS Glue database name",examples:["my_database"]},location:{type:"string",format:"uri",description:"The AWS S3 path. Must be in the form of a URL.",examples:["s3://datacontract-example-orders-latest/data/{model}"]},format:{type:"string",description:"The format of the files",examples:["parquet","csv","json","delta"]},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]}},required:["account","database"]},GoogleCloudSqlServer:{type:"object",title:"GoogleCloudSqlServer",properties:{host:{type:"string",description:"The host of the Google Cloud Sql server."},port:{$ref:"#/$defs/Port",description:"The port of the Google Cloud Sql server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]},IBMDB2Server:{type:"object",title:"IBMDB2Server",properties:{host:{type:"string",description:"The host of the IBM DB2 server."},port:{$ref:"#/$defs/Port",description:"The port of the IBM DB2 server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database"]},HiveServer:{type:"object",title:"HiveServer",properties:{host:{type:"string",description:"The host to the Hive server. "},port:{$ref:"#/$defs/Port",description:"The port to the Hive server. Defaults to 10000."},database:{type:"string",description:"The name of the Hive database."}},required:["host","database"]},ImpalaServer:{type:"object",title:"ImpalaServer",properties:{host:{type:"string",description:"The host to the Impala server."},port:{$ref:"#/$defs/Port",description:"The port to the Impala server. Defaults to 21050."},database:{type:"string",description:"The name of the Impala database."}},required:["host","database"]},InformixServer:{type:"object",title:"InformixServer",properties:{host:{type:"string",description:"The host to the Informix server. "},port:{$ref:"#/$defs/Port",description:"The port to the Informix server. Defaults to 9088."},database:{type:"string",description:"The name of the database."}},required:["host","database"]},IngresServer:{type:"object",title:"IngresServer",properties:{database:{type:"string",description:"Database name to connect to on the Ingres instance.",examples:["sales"]},host:{type:"string",description:"Hostname or IP address of the Ingres server.",examples:["ingres.acme.com"]},port:{$ref:"#/$defs/Port",description:"Connection port for the Ingres Data Access Server (DAS) / SQL connections.",default:21064,examples:[21064]}},required:["database","host"]},ZenServer:{type:"object",title:"ZenServer",properties:{host:{type:"string",description:"Hostname or IP address of the Zen server."},port:{$ref:"#/$defs/Port",description:"Zen server SQL connections port. Defaults to 1583."},database:{type:"string",description:"Database name to connect to on the Zen server."}},required:["host","database"]},CustomServer:{type:"object",title:"CustomServer",properties:{account:{type:"string",description:"Account used by the server."},catalog:{type:"string",description:"Name of the catalog."},database:{type:"string",description:"Name of the database."},dataset:{type:"string",description:"Name of the dataset."},delimiter:{type:"string",description:"Delimiter."},endpointUrl:{type:"string",description:"Server endpoint.",format:"uri"},format:{type:"string",description:"File format."},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]},host:{type:"string",description:"Host name or IP address."},location:{type:"string",description:"A URL to a location.",format:"uri"},path:{type:"string",description:"Relative or absolute path to the data file(s)."},port:{$ref:"#/$defs/Port",description:"Port to the server. No default value is assumed for custom servers."},project:{type:"string",description:"Project name."},region:{type:"string",description:"Cloud region."},regionName:{type:"string",description:"Region name."},schema:{type:"string",description:"Name of the schema."},serviceName:{type:"string",description:"Name of the service."},stagingDir:{type:"string",description:"Staging directory."},warehouse:{type:"string",description:"Name of the cluster or warehouse."},stream:{type:"string",description:"Name of the data stream."}}},KafkaServer:{type:"object",title:"KafkaServer",description:"Kafka Server",properties:{host:{type:"string",description:"The bootstrap server of the kafka cluster."},format:{type:"string",description:"The format of the messages.",examples:["json","avro","protobuf","xml"],default:"json"},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]}},required:["host"]},KinesisServer:{type:"object",title:"KinesisDataStreamsServer",description:"Kinesis Data Streams Server",properties:{region:{type:"string",description:"AWS region.",examples:["eu-west-1"]},format:{type:"string",description:"The format of the record",examples:["json","avro","protobuf"]},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]}}},LocalServer:{type:"object",title:"LocalServer",properties:{path:{type:"string",description:"The relative or absolute path to the data file(s).",examples:["./folder/data.parquet","./folder/*.parquet"]},format:{type:"string",description:"The format of the file(s)",examples:["json","parquet","delta","csv"]},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]}},required:["path","format"]},MySqlServer:{type:"object",title:"MySqlServer",properties:{host:{type:"string",description:"The host of the MySql server."},port:{$ref:"#/$defs/Port",description:"The port of the MySql server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},OracleServer:{type:"object",title:"OracleServer",properties:{host:{type:"string",description:"The host to the oracle server",examples:["localhost"]},port:{$ref:"#/$defs/Port",description:"The port to the oracle server.",examples:[1523]},serviceName:{type:"string",description:"The name of the service.",examples:["service"]}},required:["host","port","serviceName"]},PoetServer:{type:"object",title:"PoetServer",properties:{database:{type:"string",description:"Database name to connect to on the FastObjects instance.",examples:["parts_catalog"]},host:{type:"string",description:"Hostname or IP address of the FastObjects server. The literal LOCAL selects the in-process embedded engine.",default:"LOCAL",examples:["LOCAL","fastobjects02.acme.com"]},port:{$ref:"#/$defs/Port",description:"Connection port for FastObjects connections.",default:6001,examples:[6001]}},required:["database"]},PostgresServer:{type:"object",title:"PostgresServer",properties:{host:{type:"string",description:"The host to the Postgres server"},port:{$ref:"#/$defs/Port",description:"The port to the Postgres server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema in the database."}},required:["host","port","database","schema"]},HanaServer:{type:"object",title:"HanaServer",properties:{host:{type:"string",description:"Host of the HANA server."},port:{$ref:"#/$defs/Port",description:"Port of the HANA server."},database:{type:"string",description:"Name of the database (tenant)."},schema:{type:"string",description:"Name of the schema."}},required:["host"]},IcebergServer:{type:"object",title:"IcebergServer",properties:{catalog:{type:"string",description:"Catalog name as registered in the query engine or catalog service.",examples:["my_catalog"]},catalogUrl:{type:"string",format:"uri",description:"URL of the Iceberg compatible REST catalog service (Polaris, S3 Tables, Nessie, Unity Catalog, Glue, etc.)",examples:["https://my-catalog-service.com"]},namespace:{type:"string",description:"Dot-separated namespace/schema path within the catalog (e.g. db.schema or just db)."},warehouse:{type:"string",description:"Logical catalog or base location for the catalog to use.",examples:["s3://my-bucket/warehouse/sales/","production","development"]}},required:["catalog","catalogUrl"]},PrestoServer:{type:"object",title:"PrestoServer",properties:{host:{type:"string",description:"The host to the Presto server",examples:["localhost:8080"]},catalog:{type:"string",description:"The name of the catalog.",examples:["postgres"]},schema:{type:"string",description:"The name of the schema.",examples:["public"]}},required:["host"]},PubSubServer:{type:"object",title:"PubSubServer",properties:{project:{type:"string",description:"The GCP project name."}},required:["project"]},RedshiftServer:{type:"object",title:"RedshiftServer",properties:{host:{type:"string",description:"An optional string describing the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},region:{type:"string",description:"AWS region of Redshift server.",examples:["us-east-1"]},account:{type:"string",description:"The account used by the server."}},required:["database","schema"]},S3Server:{type:"object",title:"S3Server",properties:{location:{type:"string",format:"uri",description:"S3 URL, starting with `s3://`",examples:["s3://datacontract-example-orders-latest/data/{model}/*.json"]},endpointUrl:{type:"string",format:"uri",description:"The server endpoint for S3-compatible servers.",examples:["https://minio.example.com"]},format:{type:"string",examples:["parquet","delta","json","csv"],description:"File format."},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]},delimiter:{type:"string",examples:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SftpServer:{type:"object",title:"SftpServer",properties:{location:{type:"string",format:"uri",pattern:"^sftp://.*",description:"SFTP URL, starting with `sftp://`",examples:["sftp://123.123.12.123/{model}/*.json"]},format:{type:"string",examples:["parquet","delta","json","csv"],description:"File format."},encoding:{type:"string",description:"The expected character encoding for data payloads exposed through this server, for example UTF-8, ISO-8859-1, ASCII or UTF-16.",examples:["UTF-8","ISO-8859-1","ASCII","UTF-16"]},delimiter:{type:"string",examples:["new_line","array"],description:"Only for format = json. How multiple json documents are delimited within one file"}},required:["location"]},SnowflakeServer:{type:"object",title:"SnowflakeServer",properties:{host:{type:"string",description:"The host to the Snowflake server"},port:{$ref:"#/$defs/Port",description:"The port to the Snowflake server."},account:{type:"string",description:"The Snowflake account used by the server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."},warehouse:{type:"string",description:"The name of the cluster of resources that is a Snowflake virtual warehouse."}},required:["account","database","schema"]},SqlserverServer:{type:"object",title:"SqlserverServer",properties:{host:{type:"string",description:"The host to the database server",examples:["localhost"]},port:{$ref:"#/$defs/Port",description:"The port to the database server.",default:1433,examples:[1433]},database:{type:"string",description:"The name of the database.",examples:["database"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["dbo"]}},required:["host","database","schema"]},SynapseServer:{type:"object",title:"SynapseServer",properties:{host:{type:"string",description:"The host of the Synapse server."},port:{$ref:"#/$defs/Port",description:"The port of the Synapse server."},database:{type:"string",description:"The name of the database."}},required:["host","port","database"]},TeradataServer:{type:"object",title:"TeradataServer",properties:{host:{type:"string",description:"Host of the Teradata server.",examples:["teradata.acme.com"]},port:{$ref:"#/$defs/Port",description:"Port of the Teradata server.",default:1025,examples:[1025]},database:{type:"string",description:"Name of the database."}},required:["host"]},TrinoServer:{type:"object",title:"TrinoServer",properties:{host:{type:"string",description:"The Trino host URL.",examples:["localhost"]},port:{$ref:"#/$defs/Port",description:"The Trino port."},catalog:{type:"string",description:"The name of the catalog.",examples:["hive"]},schema:{type:"string",description:"The name of the schema in the database.",examples:["my_schema"]}},required:["host","port","catalog","schema"]},VectorwiseServer:{type:"object",title:"VectorwiseServer",properties:{database:{type:"string",description:"Database name to connect to on the Analytics Engine server.",examples:["warehouse"]},host:{type:"string",description:"Hostname or IP address of the Analytics Engine server.",examples:["analytics.acme.com"]},port:{$ref:"#/$defs/Port",description:"Connection port for the Data Access Server (DAS) / SQL connections.",default:21064,examples:[21064]}},required:["database","host"]},VersantServer:{type:"object",title:"VersantServer",properties:{database:{type:"string",description:"Database name to connect to on the NoSQL Database instance.",examples:["policies"]},host:{type:"string",description:"Hostname or IP address of the NoSQL Database server.",default:"localhost",examples:["nosql.acme.com"]},port:{$ref:"#/$defs/Port",description:"Connection port for Actian NoSQL Database connections.",default:5019,examples:[5019]}},required:["database"]},VerticaServer:{type:"object",title:"VerticaServer",properties:{host:{type:"string",description:"The host of the Vertica server."},port:{$ref:"#/$defs/Port",description:"The port of the Vertica server."},database:{type:"string",description:"The name of the database."},schema:{type:"string",description:"The name of the schema."}},required:["host","port","database","schema"]}},SchemaElement:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},name:{type:"string",description:"Name of the element."},physicalType:{type:"string",description:"The physical element data type in the data source.",examples:["table","view","topic","file"]},description:{type:"string",description:"Description of the element."},businessName:{type:"string",description:"The business name of the element."},deprecated:{type:"boolean",description:"Indicates this element is deprecated and should not be used in new implementations. Defaults to false.",default:!1},synonyms:{$ref:"#/$defs/Synonyms"},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{$ref:"#/$defs/Tags"},customProperties:{$ref:"#/$defs/CustomProperties"}}},SchemaObject:{type:"object",properties:{logicalType:{type:"string",description:"The logical element data type.",enum:["object"]},physicalName:{type:"string",description:"Physical name.",examples:["table_1_2_0"]},dataGranularityDescription:{type:"string",description:"Granular level of the data in the object.",examples:["Aggregation by country"]},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}},relationships:{type:"array",description:"A list of relationships to other properties. Each relationship must have 'from', 'to' and optionally 'type' field.",items:{$ref:"#/$defs/RelationshipSchemaLevel"}},quality:{$ref:"#/$defs/DataQualityChecks"},context:{$ref:"#/$defs/Context"}},allOf:[{$ref:"#/$defs/SchemaElement"}],required:["name"],unevaluatedProperties:!1},SchemaBaseProperty:{type:"object",properties:{primaryKey:{type:"boolean",description:"Boolean value specifying whether the element is primary or not. Default is false."},primaryKeyPosition:{type:"integer",default:-1,description:"If element is a primary key, the position of the primary key element. Starts from 1. Example of `account_id, name` being primary key columns, `account_id` has primaryKeyPosition 1 and `name` primaryKeyPosition 2. Default to -1."},logicalType:{type:"string",description:"The logical element data type.",enum:["string","date","timestamp","time","number","integer","object","array","boolean","map","vector"]},logicalTypeOptions:{type:"object",description:"Additional optional metadata to describe the logical type."},physicalType:{type:"string",description:"The physical element data type in the data source. For example, VARCHAR(2), DOUBLE, INT."},physicalName:{type:"string",description:"Physical name.",examples:["col_str_a"]},required:{type:"boolean",default:!1,description:"Indicates if the element may contain Null values; possible values are true and false. Default is false."},unique:{type:"boolean",default:!1,description:"Indicates if the element contains unique values; possible values are true and false. Default is false."},semanticType:{type:"string",enum:["column","measure","dimension"],default:"column",description:"The semantic role the property plays in the data model. `column` (the default) is a physical column in the underlying data store; `measure` is an aggregated value (e.g., `SUM(revenue)`) whose aggregation expression is held in `transformLogic`; `dimension` is a categorical attribute used for grouping and filtering. See RFC 0034."},partitioned:{type:"boolean",default:!1,description:"Indicates if the element is partitioned; possible values are true and false."},partitionKeyPosition:{type:"integer",default:-1,description:"If element is used for partitioning, the position of the partition element. Starts from 1. Example of `country, year` being partition columns, `country` has partitionKeyPosition 1 and `year` partitionKeyPosition 2. Default to -1."},classification:{type:"string",description:"Can be anything, like confidential, restricted, and public to more advanced categorization. Some companies like PayPal, use data classification indicating the class of data in the element; expected values are 1, 2, 3, 4, or 5.",examples:["confidential","restricted","public"]},encryptedName:{type:"string",description:"The element name within the dataset that contains the encrypted element value. For example, unencrypted element `email_address` might have an encryptedName of `email_address_encrypt`."},transformSourceObjects:{type:"array",description:"List of objects in the data source used in the transformation.",items:{type:"string"}},transformLogic:{type:"string",description:"Logic used in the element transformation."},transformDescription:{type:"string",description:"Describes the transform logic in very simple terms."},examples:{type:"array",description:"List of sample element values.",items:{$ref:"#/$defs/AnyType"}},enum:{type:"array",description:"Enumeration of allowed values for this property. Each entry is an object with at least a `value`. See RFC 0033.",minItems:1,uniqueItems:!0,items:{$ref:"#/$defs/EnumValue"}},criticalDataElement:{type:"boolean",default:!1,description:"True or false indicator; If element is considered a critical data element (CDE) then true else false."},relationships:{type:"array",description:"A list of relationships to other properties. When defined at property level, the 'from' field is implicit and should not be specified.",items:{$ref:"#/$defs/RelationshipPropertyLevel"}},quality:{$ref:"#/$defs/DataQualityChecks"}},allOf:[{$ref:"#/$defs/SchemaElement"},{if:{properties:{logicalType:{const:"string"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{minLength:{type:"integer",minimum:0,description:"Minimum length of the string."},maxLength:{type:"integer",minimum:0,description:"Maximum length of the string."},pattern:{type:"string",description:"Regular expression pattern to define valid value. Follows regular expression syntax from ECMA-262 (https://262.ecma-international.org/5.1/#sec-15.10.1)."},format:{type:"string",examples:["password","byte","binary","email","uuid","uri","hostname","ipv4","ipv6"],description:"Provides extra context about what format the string follows."}}}}}},{if:{properties:{logicalType:{const:"date"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{format:{type:"string",examples:["yyyy-MM-dd","yyyy-MM-dd HH:mm:ss","HH:mm:ss"],description:"Format of the date. Follows the format as prescribed by [JDK DateTimeFormatter](https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html). For example, format 'yyyy-MM-dd'."},exclusiveMaximum:{type:"string",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},maximum:{type:"string",description:"All date values are less than or equal to this value (values <= maximum)."},exclusiveMinimum:{type:"string",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},minimum:{type:"string",description:"All date values are greater than or equal to this value (values >= minimum)."}}}}}},{if:{anyOf:[{properties:{logicalType:{const:"timestamp"}}},{properties:{logicalType:{const:"time"}}}]},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{format:{type:"string",examples:["yyyy-MM-dd","yyyy-MM-dd HH:mm:ss","HH:mm:ss"],description:"Format of the date. Follows the format as prescribed by [JDK DateTimeFormatter](https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html). For example, format 'yyyy-MM-dd'."},exclusiveMaximum:{type:"string",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},maximum:{type:"string",description:"All date values are less than or equal to this value (values <= maximum)."},exclusiveMinimum:{type:"string",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},minimum:{type:"string",description:"All date values are greater than or equal to this value (values >= minimum)."},timezone:{type:"boolean",description:"Whether the timestamp defines the timezone or not. If true, timezone information is included in the timestamp."},defaultTimezone:{type:"string",description:"The default timezone of the timestamp. If timezone is not defined, the default timezone UTC is used.",default:"Etc/UTC"}}}}}},{if:{anyOf:[{properties:{logicalType:{const:"integer"}}}]},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"number",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"number",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use and whether it is signed or unsigned (follows the Rust integer types).",enum:["i8","i16","i32","i64","i128","u8","u16","u32","u64","u128"]}}}}}},{if:{anyOf:[{properties:{logicalType:{const:"number"}}}]},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{multipleOf:{type:"number",exclusiveMinimum:0,description:"Values must be multiples of this number. For example, multiple of 5 has valid values 0, 5, 10, -5."},maximum:{type:"number",description:"All values are less than or equal to this value (values <= maximum)."},exclusiveMaximum:{type:"number",description:"All values must be strictly less than this value (values < exclusiveMaximum)."},minimum:{type:"number",description:"All values are greater than or equal to this value (values >= minimum)."},exclusiveMinimum:{type:"number",description:"All values must be strictly greater than this value (values > exclusiveMinimum)."},format:{type:"string",default:"i32",description:"Format of the value in terms of how many bits of space it can use (follows the Rust float types).",enum:["f32","f64"]}}}}}},{if:{properties:{logicalType:{const:"object"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{maxProperties:{type:"integer",minimum:0,description:"Maximum number of properties."},minProperties:{type:"integer",minimum:0,default:0,description:"Minimum number of properties."},required:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0,description:"Property names that are required to exist in the object."}}},properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}}}},{if:{properties:{logicalType:{const:"array"}}},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{maxItems:{type:"integer",minimum:0,description:"Maximum number of items."},minItems:{type:"integer",minimum:0,default:0,description:"Minimum number of items"},uniqueItems:{type:"boolean",default:!1,description:"If set to true, all items in the array are unique."}}},items:{$ref:"#/$defs/SchemaItemProperty",description:"List of items in an array (only applicable when `logicalType: array`)."}}}},{if:{properties:{logicalType:{const:"map"}},required:["logicalType"]},then:{properties:{map:{type:"object",description:"Key/value definition for a map (only applicable when `logicalType: map`). See RFC 0030.",additionalProperties:!1,properties:{key:{$ref:"#/$defs/SchemaItemProperty",description:"Definition of the map's key."},value:{$ref:"#/$defs/SchemaItemProperty",description:"Definition of the map's value."}},required:["key","value"]}},required:["map"]}},{if:{properties:{logicalType:{const:"vector"}},required:["logicalType"]},then:{properties:{logicalTypeOptions:{type:"object",additionalProperties:!1,properties:{dimensions:{type:"integer",minimum:1,description:"The fixed length of the vector. Positive integer (only applicable when `logicalType: vector`). See RFC 0042.",examples:[384,768,1024,1536,3072]},elementType:{type:"string",enum:["bfloat16","binary","float16","float32","float64","int8","uint8"],default:"float32",description:"Numeric type of each vector element. `binary` means each element is one bit (binary-quantized vectors)."},distanceMetric:{type:"string",enum:["cosine","dotProduct","euclidean","hamming","manhattan"],description:"Intended similarity metric. Advisory — the physical index may differ."},embeddingModel:{type:"string",description:"Identifier of the model used to produce the vectors.",examples:["openai/text-embedding-3-small","cohere/embed-english-v3.0"]},embeddingModelVersion:{type:"string",description:"Version or revision of the embedding model, when the model identifier does not already carry one."},normalized:{type:"boolean",default:!1,description:"True if vectors are L2-normalized before storage, which makes cosine and dotProduct equivalent."}},required:["dimensions"]}}}}],unevaluatedProperties:!1},SchemaProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",required:["name"],unevaluatedProperties:!1},SchemaItemProperty:{type:"object",$ref:"#/$defs/SchemaBaseProperty",properties:{properties:{type:"array",description:"A list of properties for the object.",items:{$ref:"#/$defs/SchemaProperty"}}},unevaluatedProperties:!1},Tags:{type:"array",description:"A list of tags that may be assigned to the elements (object or property); the tags keyword may appear at any level. Tags may be used to better categorize an element. For example, `finance`, `sensitive`, `employee_record`.",examples:["finance","sensitive","employee_record"],items:{type:"string"}},DataQuality:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},businessImpact:{type:"string",description:"Consequences of the rule failure.",examples:["operational","regulatory"]},customProperties:{type:"array",description:"Additional properties required for rule execution.",items:{$ref:"#/$defs/CustomProperty"}},description:{type:"string",description:"Describe the quality check to be completed."},dimension:{type:"string",description:"The key performance indicator (KPI) or dimension for data quality.",enum:["accuracy","completeness","conformity","consistency","coverage","timeliness","uniqueness"]},method:{type:"string",examples:["reconciliation"]},name:{type:"string",description:"Name of the data quality check."},schedule:{type:"string",description:"Rule execution schedule details.",examples:["0 20 * * *"]},scheduler:{type:"string",description:"The name or type of scheduler used to start the data quality check.",examples:["cron"]},severity:{type:"string",description:"The severance of the quality rule.",examples:["info","warning","error"]},tags:{$ref:"#/$defs/Tags"},type:{type:"string",description:"The type of quality check. 'text' is human-readable text that describes the quality of the data. 'library' is a set of maintained predefined quality attributes such as row count or unique. 'sql' is an individual SQL query that returns a value that can be compared. 'custom' is quality attributes that are vendor-specific, such as Soda or Great Expectations.",enum:["text","library","sql","custom"],default:"library"},unit:{type:"string",description:"Unit the rule is using, popular values are `rows` or `percent`, but any value is allowed.",examples:["rows","percent"]}},allOf:[{if:{anyOf:[{properties:{type:{const:"library"}},required:["type"]},{properties:{metric:{type:"string"}},required:["metric"]}]},then:{$ref:"#/$defs/DataQualityLibrary"}},{if:{properties:{type:{const:"sql"}},required:["type"]},then:{$ref:"#/$defs/DataQualitySql"}},{if:{properties:{type:{const:"custom"}},required:["type"]},then:{$ref:"#/$defs/DataQualityCustom"}}],unevaluatedProperties:!1},DataQualityChecks:{type:"array",description:"Data quality rules with all the relevant information for rule setup and execution.",items:{$ref:"#/$defs/DataQuality"}},DataQualityOperators:{type:"object",description:"Common comparison operators for data quality checks.",oneOf:[{properties:{mustBe:{description:"Must be equal to the value to be valid. When using numbers, it is equivalent to '='."}},required:["mustBe"]},{properties:{mustNotBe:{description:"Must not be equal to the value to be valid. When using numbers, it is equivalent to '!='."}},required:["mustNotBe"]},{properties:{mustBeGreaterThan:{type:"number",description:"Must be greater than the value to be valid. It is equivalent to '>'."}},required:["mustBeGreaterThan"]},{properties:{mustBeGreaterOrEqualTo:{type:"number",description:"Must be greater than or equal to the value to be valid. It is equivalent to '>='."}},required:["mustBeGreaterOrEqualTo"]},{properties:{mustBeLessThan:{type:"number",description:"Must be less than the value to be valid. It is equivalent to '<'."}},required:["mustBeLessThan"]},{properties:{mustBeLessOrEqualTo:{type:"number",description:"Must be less than or equal to the value to be valid. It is equivalent to '<='."}},required:["mustBeLessOrEqualTo"]},{properties:{mustBeBetween:{type:"array",description:"Must be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}}},required:["mustBeBetween"]},{properties:{mustNotBeBetween:{type:"array",description:"Must not be between the two numbers to be valid. Smallest number first in the array.",minItems:2,maxItems:2,uniqueItems:!0,items:{type:"number"}}},required:["mustNotBeBetween"]}]},DataQualityLibrary:{type:"object",allOf:[{$ref:"#/$defs/DataQualityOperators"}],properties:{metric:{type:"string",description:"Define a data quality check based on the predefined metrics as per ODCS.",enum:["nullValues","missingValues","invalidValues","duplicateValues","rowCount"]},rule:{type:"string",deprecated:!0,description:"Use metric instead"},arguments:{type:"object",description:"Additional arguments for the metric, if needed."}},required:["metric"]},DataQualitySql:{type:"object",allOf:[{$ref:"#/$defs/DataQualityOperators"}],properties:{query:{type:"string",description:"Query string that adheres to the dialect of the provided server.",examples:["SELECT COUNT(*) FROM ${table} WHERE ${column} IS NOT NULL"]}},required:["query"]},DataQualityCustom:{type:"object",properties:{engine:{type:"string",description:"Name of the engine which executes the data quality checks.",examples:["soda","great-expectations","monte-carlo","dbt"]},implementation:{oneOf:[{type:"string"},{type:"object"}]}},required:["engine","implementation"]},AuthoritativeDefinitions:{type:"array",description:"List of links to sources that provide more details on the dataset; examples would be a link to an external definition, a training video, a git repo, data catalog, or another tool. Authoritative definitions follow the same structure in the standard.",items:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},url:{type:"string",description:"URL to the authority."},type:{type:"string",description:"Type of definition for authority. See the recommended values in the documentation.",examples:["businessDefinition","canonicalUrl","glossary","implementation","ontology","taxonomy","transformationImplementation","tutorial","videoTutorial"]},description:{type:"string",description:"Description of the authoritative definition for humans."}},required:["url","type"],additionalProperties:!1}},Support:{type:"array",description:"Top level for support channels.",items:{$ref:"#/$defs/SupportItem"}},SupportItem:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},channel:{type:"string",description:"Channel name or identifier."},url:{type:"string",description:"Access URL using normal [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax) (https, mailto, etc.)."},description:{type:"string",description:"Description of the channel, free text."},tool:{type:"string",description:"Name of the tool, value can be `email`, `slack`, `teams`, `discord`, `ticket`, `googlechat`, or `other`.",examples:["email","slack","teams","discord","ticket","googlechat","other"]},scope:{type:"string",description:"Scope can be: `interactive`, `announcements`, `issues`, `notifications`.",examples:["interactive","announcements","issues","notifications"]},invitationUrl:{type:"string",description:"Some tools uses invitation URL for requesting or subscribing. Follows the [URL scheme](https://en.wikipedia.org/wiki/URL#Syntax)."},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["channel"],additionalProperties:!1},Pricing:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},priceAmount:{type:"number",description:"Subscription price per unit of measure in `priceUnit`."},priceCurrency:{type:"string",description:"Currency of the subscription price in `price.priceAmount`."},priceUnit:{type:"string",description:"The unit of measure for calculating cost. Examples megabyte, gigabyte."}},additionalProperties:!1},TeamMember:{type:"object",description:"Team member information.",additionalProperties:!1,properties:{id:{$ref:"#/$defs/StableId"},username:{type:"string",description:"The user's username or email."},name:{type:"string",description:"The user's name."},description:{type:"string",description:"The user's description."},role:{type:"string",description:"The user's job role; Examples might be owner, data steward. There is no limit on the role."},dateIn:{type:"string",format:"date",description:"The date when the user joined the team."},dateOut:{type:"string",format:"date",description:"The date when the user ceased to be part of the team."},replacedByUsername:{type:"string",description:"The username of the user who replaced the previous user."},tags:{$ref:"#/$defs/Tags"},customProperties:{type:"array",description:"Custom properties block.",items:{$ref:"#/$defs/CustomProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"}},required:["username"]},Team:{type:"object",description:"Team information.",additionalProperties:!1,properties:{id:{$ref:"#/$defs/StableId"},name:{type:"string",description:"Team name."},description:{type:"string",description:"Team description."},members:{type:"array",description:"List of members.",items:{$ref:"#/$defs/TeamMember"}},tags:{$ref:"#/$defs/Tags"},customProperties:{type:"array",description:"Custom properties block.",items:{$ref:"#/$defs/CustomProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"}}},Role:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},role:{type:"string",description:"Name of the IAM role that provides access to the dataset."},description:{type:"string",description:"Description of the IAM role and its permissions."},access:{type:"string",description:"The type of access provided by the IAM role."},firstLevelApprovers:{type:"string",description:"The name(s) of the first-level approver(s) of the role."},secondLevelApprovers:{type:"string",description:"The name(s) of the second-level approver(s) of the role."},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["role"],additionalProperties:!1},ServiceLevelAgreementProperty:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},property:{type:"string",description:"Specific property in SLA, check the periodic table. May requires units (more details to come)."},value:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}],description:"Agreement value. The label will change based on the property itself."},valueExt:{$ref:"#/$defs/AnyNonCollectionType",description:"Extended agreement value. The label will change based on the property itself."},unit:{type:"string",description:"**d**, day, days for days; **y**, yr, years for years, etc. Units use the ISO standard."},element:{type:"string",description:"Element(s) to check on. Multiple elements should be extremely rare and, if so, separated by commas."},driver:{type:"string",description:"Describes the importance of the SLA from the list of: `regulatory`, `analytics`, or `operational`.",examples:["regulatory","analytics","operational"]},description:{type:"string",description:"Description of the SLA for humans.",examples:["99.9% of the time, data is available by 6 AM UTC"]},scheduler:{type:"string",description:"Name of the scheduler, can be cron or any tool your organization support.",examples:["cron"]},schedule:{type:"string",description:"Configuration information for the scheduling tool, for cron a possible value is 0 20 * * *.",examples:["0 20 * * *"]},customProperties:{$ref:"#/$defs/CustomProperties"},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"}},required:["property","value"],additionalProperties:!1},CustomProperties:{type:"array",description:"A list of key/value pairs for custom properties.",items:{$ref:"#/$defs/CustomProperty"}},EnumValue:{type:"object",description:"An allowed value within a property's enumeration. See RFC 0033.",properties:{value:{$ref:"#/$defs/AnyNonCollectionType",description:"The allowed value. Required."},label:{type:"string",description:"Human-readable label for the value, suitable for UI display."},id:{$ref:"#/$defs/StableId"},description:{type:"string",description:"Optional description of what this enum value represents."},customProperties:{type:"array",description:"Custom properties attached to this enum value (e.g., translations).",items:{$ref:"#/$defs/CustomProperty"}},authoritativeDefinitions:{$ref:"#/$defs/AuthoritativeDefinitions"},tags:{$ref:"#/$defs/Tags"}},required:["value"],additionalProperties:!1},Synonyms:{type:"array",description:"A list of alternative names for the object. See RFC 0041.",items:{$ref:"#/$defs/Synonym"}},Synonym:{type:"object",description:"An alternative name for a named object, helping catalogs, AI/LLM tools, and natural language interfaces resolve business vocabulary to the underlying object. See RFC 0041.",properties:{id:{$ref:"#/$defs/StableId"},synonym:{type:"string",description:"The synonymous term."},description:{type:"string",description:"Short human-readable note about when or why this synonym is used."},locale:{type:"string",description:"BCP 47 language tag (e.g., `en-US`, `fr-FR`) when the synonym is language-specific."},source:{type:"string",description:"Origin of the synonym (e.g., `glossary`, `finance-team`, `legacy-system`)."},status:{type:"string",description:"Lifecycle status of the synonym (e.g., `active`, `deprecated`)."},customProperties:{$ref:"#/$defs/CustomProperties"}},required:["synonym"],additionalProperties:!1},CustomProperty:{type:"object",properties:{id:{$ref:"#/$defs/StableId"},property:{type:"string",description:"The name of the key. Names should be in camel case–the same as if they were permanent properties in the contract."},value:{$ref:"#/$defs/AnyType",description:"The value of the key."},description:{type:"string",description:"Description of the custom property."},vendor:{type:"string",description:"Identifies the vendor, provider, or external system associated with this custom property. SHOULD be a stable, lowercase identifier matching ^[a-z0-9][a-z0-9-]*$ (e.g. confluent, zeenea, atlan, soda). Tools MUST preserve unknown vendor values.",examples:["confluent","zeenea","atlan","soda"]}},required:["property","value"],additionalProperties:!1},AnyType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"},{type:"array"},{type:"object"}]},AnyNonCollectionType:{anyOf:[{type:"string"},{type:"number"},{type:"integer"},{type:"boolean"},{type:"null"}]},RelationshipBase:{type:"object",description:"Base definition for relationships between properties, typically for foreign key constraints.",properties:{id:{type:"string",description:"Optional stable identifier for this relationship, unique within its containing relationships array. SHOULD remain stable across contract versions. Cannot contain: . # / \\ @ ! % & ^"},type:{type:"string",description:"The type of relationship. Defaults to 'foreignKey'.",default:"foreignKey",enum:["foreignKey"]},from:{oneOf:[{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}],description:"Source property reference using fully qualified or shorthand notation."},{type:"array",description:"Array of source properties for composite keys.",items:{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}]},minItems:1}],description:"Source property or properties."},to:{oneOf:[{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}],description:"Target property reference using fully qualified or shorthand notation."},{type:"array",description:"Array of target properties for composite keys.",items:{anyOf:[{$ref:"#/$defs/ShorthandReference"},{$ref:"#/$defs/FullyQualifiedReference"}]},minItems:1}],description:"Target property or properties to reference."},customProperties:{$ref:"#/$defs/CustomProperties"}}},RelationshipSchemaLevel:{type:"object",description:"Relationship definition at schema level, requiring both 'from' and 'to' fields with matching types.",allOf:[{$ref:"#/$defs/RelationshipBase"},{required:["from","to"]},{oneOf:[{description:"Single-column relationship - both fields must be strings",properties:{from:{type:"string"},to:{type:"string"}}},{description:"Composite key relationship - both fields must be arrays with matching lengths",properties:{from:{type:"array",items:{type:"string"},minItems:1},to:{type:"array",items:{type:"string"},minItems:1}}}]}],unevaluatedProperties:!1},RelationshipPropertyLevel:{type:"object",description:"Relationship definition at property level, where 'from' is implicitly the current property.",allOf:[{$ref:"#/$defs/RelationshipBase"},{type:"object",required:["to"]},{not:{required:["from"]},description:"The 'from' field must not be specified at property level as it is implicitly derived from the property context"}],unevaluatedProperties:!1},Relationship:{description:"Compatibility wrapper for relationship definitions.",oneOf:[{$ref:"#/$defs/RelationshipSchemaLevel"},{$ref:"#/$defs/RelationshipPropertyLevel"}]}}};var ise="umf.odcs",H3e=Xie,lse=(e,t)=>t==="json"?Jt(e):Wa(e),sse={"v3.0.0":Zie,"v3.0.1":ese,"v3.0.2":tse,"v3.1.0":nse,"v3.2.0":rse},ose=new Map;function z3e(e){let t=e,n=[{code:"ODCS_CONTEXT",path:"",severity:"warning",message:"Contract shape checks do not enforce data quality/SLA rules, resolve references, map physical types or prove exact-number constraints beyond JS precision; edits regenerate layout while retaining original source"}],r=(a,l,c,u="warning")=>n.push({code:a,path:l,message:c,severity:u});if(Object.keys(t).some((a)=>!["profile","root","originalSource","originalFormat"].includes(a)))r("ODCS_REPRESENTATION","","Unknown representation fields remain in UMF");function i(a,l){let c=a.kind==="null"?["kind"]:a.kind==="array"?["kind","items"]:a.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(a).some((u)=>!c.includes(u)))r("ODCS_REPRESENTATION",l,"Unknown tagged-tree fields remain in UMF");if(a.kind==="object")for(let[u,p]of Object.entries(a.members))i(p,l+"/"+$e(u));if(a.kind==="array")a.items.forEach((u,p)=>i(u,l+"/"+p))}if(i(t.root,""),t.root.kind!=="object")return r("ODCS_STRUCTURE","","Expected ODCS contract object","error"),n;try{lse(t.originalSource,t.originalFormat)}catch(a){return r("ODCS_ARCHIVE","/originalSource",String(a),"error"),n}let s=t.root.members.apiVersion;if(s?.kind!=="string"||!Object.hasOwn(sse,s.value))return r("ODCS_VERSION","/apiVersion","Missing or unknown ODCS version preserved without interpretation"),n;let o=ose.get(s.value);if(!o){let a=new ase.default({allErrors:!0,strict:!1,validateFormats:!1,ownProperties:!0});zp(a),o=a.compile(sse[s.value]),ose.set(s.value,o)}if(!o(JSON.parse(Be(t.root))))for(let a of(o.errors??[]).slice(0,100))r("ODCS_NATIVE_SCHEMA",a.instancePath,a.message??"Native contract shape mismatch");if((o.errors?.length??0)>100)r("ODCS_DIAGNOSTICS_TRUNCATED","","More than 100 native schema diagnostics; first 100 retained");return n}function W3e(){return new nt().register(H3e,z3e)}function cse(e){return We(e,W3e())}function Q3e(e){let t=cse(e);if(!t.valid)throw new U("ODCS_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="contract")?.elements.find((r)=>r.id==="contract")?.extensions[ise];if(!n||e.vocabularies[ise]?.version!=="0.1.0")throw new U("ODCS_PAYLOAD","Expected pinned ODCS payload");return Ae(n)}function use(e,t){let n=Q3e(e);if(t!==void 0&&!["json","yaml"].includes(t))throw new U("ODCS_FORMAT","Unsupported native format");if(cse(e).diagnostics.some((r)=>r.code==="ODCS_REPRESENTATION"))throw new U("ODCS_EXPORT","Unknown representation fields cannot be discarded");if((t??n.originalFormat)===n.originalFormat&&Be(lse(n.originalSource,n.originalFormat))===Be(n.root))return n.originalSource;return Be(n.root)+` +`}var t6e=Rr(fae(),1);var{create:Q8e,defineProperty:ZS,defineProperties:Y8e,getOwnPropertyDescriptor:X8e,getOwnPropertyDescriptors:Z8e,getOwnPropertyNames:eVe,getOwnPropertySymbols:mae,getPrototypeOf:tVe}=Object,Eae=Object.prototype.hasOwnProperty,nVe=Object.prototype.propertyIsEnumerable,eh=(e,t)=>(t=Symbol[e])?t:Symbol.for("Symbol."+e),rVe=(e)=>{throw TypeError(e)},yae=(e,t,n)=>(t in e)?ZS(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ls=(e,t)=>{for(var n in t||(t={}))Eae.call(t,n)&&yae(e,n,t[n]);if(mae)for(var n of mae(t))nVe.call(t,n)&&yae(e,n,t[n]);return e},eE=(e,t)=>Y8e(e,Z8e(t)),un=(e,t)=>()=>{try{return t||e((t={exports:{}}).exports,t),t.exports}catch(n){throw t=0,n}},iVe=(e,t)=>{for(var n in t)ZS(e,n,{get:t[n],enumerable:!0})},sVe=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of eVe(t))!Eae.call(e,i)&&i!==n&&ZS(e,i,{get:()=>t[i],enumerable:!(r=X8e(t,i))||r.enumerable});return e},tE=(e,t,n)=>(n=e!=null?Q8e(tVe(e)):{},sVe(t||!e||!e.__esModule?ZS(n,"default",{value:e,enumerable:!0}):n,e)),Ms=function(e,t){this[0]=e,this[1]=t},wp=(e,t,n)=>{var r=(a,l,c,u)=>{try{var p=n[a](l),d=(l=p.value)instanceof Ms,f=p.done;Promise.resolve(d?l[0]:l).then((m)=>d?r(a==="return"?a:"next",l[1]?{done:m.done,value:m.value}:m,c,u):c({value:m,done:f})).catch((m)=>r("throw",m,c,u))}catch(m){u(m)}},i=(a,l,c,u)=>o[a]=(p)=>(l=new Promise((d,f,m)=>(m=()=>r(a,p,d,f),s?s.then(m):m())),u=()=>s===c&&(s=0),s=c=l.then(u,u),l),s,o={};return n=n.apply(e,t),o[eh("asyncIterator")]=()=>o,i("next"),i("throw"),i("return"),o},wf=(e)=>{var t=e[eh("asyncIterator")],n=!1,r,i={};return t==null?(t=e[eh("iterator")](),r=(s)=>i[s]=(o)=>t[s](o)):(t=t.call(e),r=(s)=>i[s]=(o)=>{if(n){if(n=!1,s==="throw")throw o;return o}return n=!0,{done:!1,value:new Ms(new Promise((a)=>{var l=t[s](o);l instanceof Object||rVe("Object expected"),a(l)}),1)}}),i[eh("iterator")]=()=>i,r("next"),"throw"in t?r("throw"):i.throw=(s)=>{throw s},"return"in t&&r("return"),i},sa=(e,t,n)=>(t=e[eh("asyncIterator")])?t.call(e):(e=e[eh("iterator")](),t={},n=(r,i)=>(i=e[r])&&(t[r]=(s)=>new Promise((o,a,l)=>(s=i.call(e,s),l=s.done,Promise.resolve(s.value).then((c)=>o({value:c,done:l}),a)))),n("next"),n("return"),t),oVe=un((e)=>{e.byteLength=l,e.toByteArray=u,e.fromByteArray=f;var t=[],n=[],r=typeof Uint8Array<"u"?Uint8Array:Array,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(s=0,o=i.length;s0)throw Error("Invalid string. Length must be a multiple of 4");var h=m.indexOf("=");h===-1&&(h=y);var b=h===y?0:4-h%4;return[h,b]}function l(m){var y=a(m),h=y[0],b=y[1];return(h+b)*3/4-b}function c(m,y,h){return(y+h)*3/4-h}function u(m){var y,h=a(m),b=h[0],g=h[1],x=new r(c(m,b,g)),v=0,D=g>0?b-4:b,T;for(T=0;T>16&255,x[v++]=y>>8&255,x[v++]=y&255;return g===2&&(y=n[m.charCodeAt(T)]<<2|n[m.charCodeAt(T+1)]>>4,x[v++]=y&255),g===1&&(y=n[m.charCodeAt(T)]<<10|n[m.charCodeAt(T+1)]<<4|n[m.charCodeAt(T+2)]>>2,x[v++]=y>>8&255,x[v++]=y&255),x}function p(m){return t[m>>18&63]+t[m>>12&63]+t[m>>6&63]+t[m&63]}function d(m,y,h){for(var b,g=[],x=y;xD?D:v+x));return b===1?(y=m[h-1],g.push(t[y>>2]+t[y<<4&63]+"==")):b===2&&(y=(m[h-2]<<8)+m[h-1],g.push(t[y>>10]+t[y>>4&63]+t[y<<2&63]+"=")),g.join("")}}),aVe=un((e)=>{e.read=function(t,n,r,i,s){var o,a,l=s*8-i-1,c=(1<>1,p=-7,d=r?s-1:0,f=r?-1:1,m=t[n+d];for(d+=f,o=m&(1<<-p)-1,m>>=-p,p+=l;p>0;o=o*256+t[n+d],d+=f,p-=8);for(a=o&(1<<-p)-1,o>>=-p,p+=i;p>0;a=a*256+t[n+d],d+=f,p-=8);if(o===0)o=1-u;else{if(o===c)return a?NaN:(m?-1:1)*(1/0);a=a+Math.pow(2,i),o=o-u}return(m?-1:1)*a*Math.pow(2,o-i)},e.write=function(t,n,r,i,s,o){var a,l,c,u=o*8-s-1,p=(1<>1,f=s===23?Math.pow(2,-24)-Math.pow(2,-77):0,m=i?0:o-1,y=i?1:-1,h=n<0||n===0&&1/n<0?1:0;for(n=Math.abs(n),isNaN(n)||n===1/0?(l=isNaN(n)?1:0,a=p):(a=Math.floor(Math.log(n)/Math.LN2),n*(c=Math.pow(2,-a))<1&&(a--,c*=2),a+d>=1?n+=f/c:n+=f*Math.pow(2,1-d),n*c>=2&&(a++,c/=2),a+d>=p?(l=0,a=p):a+d>=1?(l=(n*c-1)*Math.pow(2,s),a=a+d):(l=n*Math.pow(2,d-1)*Math.pow(2,s),a=0));s>=8;t[r+m]=l&255,m+=y,l/=256,s-=8);for(a=a<0;t[r+m]=a&255,m+=y,a/=256,u-=8);t[r+m-y]|=h*128}}),Uc=un((e)=>{var t=oVe(),n=aVe(),r=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;e.Buffer=a,e.SlowBuffer=g,e.INSPECT_MAX_BYTES=50;var i=2147483647;e.kMaxLength=i,a.TYPED_ARRAY_SUPPORT=s(),!a.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function s(){try{let _=new Uint8Array(1),S={foo:function(){return 42}};return Object.setPrototypeOf(S,Uint8Array.prototype),Object.setPrototypeOf(_,S),_.foo()===42}catch(_){return!1}}Object.defineProperty(a.prototype,"parent",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.buffer}}),Object.defineProperty(a.prototype,"offset",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.byteOffset}});function o(_){if(_>i)throw RangeError('The value "'+_+'" is invalid for option "size"');let S=new Uint8Array(_);return Object.setPrototypeOf(S,a.prototype),S}function a(_,S,k){if(typeof _=="number"){if(typeof S=="string")throw TypeError('The "string" argument must be of type string. Received type number');return p(_)}return l(_,S,k)}a.poolSize=8192;function l(_,S,k){if(typeof _=="string")return d(_,S);if(ArrayBuffer.isView(_))return m(_);if(_==null)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof _);if(ye(_,ArrayBuffer)||_&&ye(_.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(ye(_,SharedArrayBuffer)||_&&ye(_.buffer,SharedArrayBuffer)))return y(_,S,k);if(typeof _=="number")throw TypeError('The "value" argument must not be of type number. Received type number');let E=_.valueOf&&_.valueOf();if(E!=null&&E!==_)return a.from(E,S,k);let A=h(_);if(A)return A;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof _[Symbol.toPrimitive]=="function")return a.from(_[Symbol.toPrimitive]("string"),S,k);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof _)}a.from=function(_,S,k){return l(_,S,k)},Object.setPrototypeOf(a.prototype,Uint8Array.prototype),Object.setPrototypeOf(a,Uint8Array);function c(_){if(typeof _!="number")throw TypeError('"size" argument must be of type number');if(_<0)throw RangeError('The value "'+_+'" is invalid for option "size"')}function u(_,S,k){return c(_),_<=0?o(_):S!==void 0?typeof k=="string"?o(_).fill(S,k):o(_).fill(S):o(_)}a.alloc=function(_,S,k){return u(_,S,k)};function p(_){return c(_),o(_<0?0:b(_)|0)}a.allocUnsafe=function(_){return p(_)},a.allocUnsafeSlow=function(_){return p(_)};function d(_,S){if((typeof S!="string"||S==="")&&(S="utf8"),!a.isEncoding(S))throw TypeError("Unknown encoding: "+S);let k=x(_,S)|0,E=o(k),A=E.write(_,S);return A!==k&&(E=E.slice(0,A)),E}function f(_){let S=_.length<0?0:b(_.length)|0,k=o(S);for(let E=0;E=i)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+i.toString(16)+" bytes");return _|0}function g(_){return+_!=_&&(_=0),a.alloc(+_)}a.isBuffer=function(_){return _!=null&&_._isBuffer===!0&&_!==a.prototype},a.compare=function(_,S){if(ye(_,Uint8Array)&&(_=a.from(_,_.offset,_.byteLength)),ye(S,Uint8Array)&&(S=a.from(S,S.offset,S.byteLength)),!a.isBuffer(_)||!a.isBuffer(S))throw TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(_===S)return 0;let k=_.length,E=S.length;for(let A=0,Q=Math.min(k,E);AE.length?(a.isBuffer(Q)||(Q=a.from(Q)),Q.copy(E,A)):Uint8Array.prototype.set.call(E,Q,A);else if(a.isBuffer(Q))Q.copy(E,A);else throw TypeError('"list" argument must be an Array of Buffers');A+=Q.length}return E};function x(_,S){if(a.isBuffer(_))return _.length;if(ArrayBuffer.isView(_)||ye(_,ArrayBuffer))return _.byteLength;if(typeof _!="string")throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof _);let k=_.length,E=arguments.length>2&&arguments[2]===!0;if(!E&&k===0)return 0;let A=!1;for(;;)switch(S){case"ascii":case"latin1":case"binary":return k;case"utf8":case"utf-8":return j(_).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return k*2;case"hex":return k>>>1;case"base64":return fe(_).length;default:if(A)return E?-1:j(_).length;S=(""+S).toLowerCase(),A=!0}}a.byteLength=x;function v(_,S,k){let E=!1;if((S===void 0||S<0)&&(S=0),S>this.length||((k===void 0||k>this.length)&&(k=this.length),k<=0)||(k>>>=0,S>>>=0,k<=S))return"";for(_||(_="utf8");;)switch(_){case"hex":return je(this,S,k);case"utf8":case"utf-8":return me(this,S,k);case"ascii":return pe(this,S,k);case"latin1":case"binary":return de(this,S,k);case"base64":return Y(this,S,k);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return be(this,S,k);default:if(E)throw TypeError("Unknown encoding: "+_);_=(_+"").toLowerCase(),E=!0}}a.prototype._isBuffer=!0;function D(_,S,k){let E=_[S];_[S]=_[k],_[k]=E}a.prototype.swap16=function(){let _=this.length;if(_%2!==0)throw RangeError("Buffer size must be a multiple of 16-bits");for(let S=0;S<_;S+=2)D(this,S,S+1);return this},a.prototype.swap32=function(){let _=this.length;if(_%4!==0)throw RangeError("Buffer size must be a multiple of 32-bits");for(let S=0;S<_;S+=4)D(this,S,S+3),D(this,S+1,S+2);return this},a.prototype.swap64=function(){let _=this.length;if(_%8!==0)throw RangeError("Buffer size must be a multiple of 64-bits");for(let S=0;S<_;S+=8)D(this,S,S+7),D(this,S+1,S+6),D(this,S+2,S+5),D(this,S+3,S+4);return this},a.prototype.toString=function(){let _=this.length;return _===0?"":arguments.length===0?me(this,0,_):v.apply(this,arguments)},a.prototype.toLocaleString=a.prototype.toString,a.prototype.equals=function(_){if(!a.isBuffer(_))throw TypeError("Argument must be a Buffer");return this===_?!0:a.compare(this,_)===0},a.prototype.inspect=function(){let _="",S=e.INSPECT_MAX_BYTES;return _=this.toString("hex",0,S).replace(/(.{2})/g,"$1 ").trim(),this.length>S&&(_+=" ... "),""},r&&(a.prototype[r]=a.prototype.inspect),a.prototype.compare=function(_,S,k,E,A){if(ye(_,Uint8Array)&&(_=a.from(_,_.offset,_.byteLength)),!a.isBuffer(_))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof _);if(S===void 0&&(S=0),k===void 0&&(k=_?_.length:0),E===void 0&&(E=0),A===void 0&&(A=this.length),S<0||k>_.length||E<0||A>this.length)throw RangeError("out of range index");if(E>=A&&S>=k)return 0;if(E>=A)return-1;if(S>=k)return 1;if(S>>>=0,k>>>=0,E>>>=0,A>>>=0,this===_)return 0;let Q=A-E,le=k-S,Je=Math.min(Q,le),Et=this.slice(E,A),ut=_.slice(S,k);for(let wt=0;wt2147483647?k=2147483647:k<-2147483648&&(k=-2147483648),k=+k,Pe(k)&&(k=A?0:_.length-1),k<0&&(k=_.length+k),k>=_.length){if(A)return-1;k=_.length-1}else if(k<0)if(A)k=0;else return-1;if(typeof S=="string"&&(S=a.from(S,E)),a.isBuffer(S))return S.length===0?-1:N(_,S,k,E,A);if(typeof S=="number")return S=S&255,typeof Uint8Array.prototype.indexOf=="function"?A?Uint8Array.prototype.indexOf.call(_,S,k):Uint8Array.prototype.lastIndexOf.call(_,S,k):N(_,[S],k,E,A);throw TypeError("val must be string, number or Buffer")}function N(_,S,k,E,A){let Q=1,le=_.length,Je=S.length;if(E!==void 0&&(E=String(E).toLowerCase(),E==="ucs2"||E==="ucs-2"||E==="utf16le"||E==="utf-16le")){if(_.length<2||S.length<2)return-1;Q=2,le/=2,Je/=2,k/=2}function Et(wt,At){return Q===1?wt[At]:wt.readUInt16BE(At*Q)}let ut;if(A){let wt=-1;for(ut=k;utle&&(k=le-Je),ut=k;ut>=0;ut--){let wt=!0;for(let At=0;AtA&&(E=A)):E=A;let Q=S.length;E>Q/2&&(E=Q/2);let le;for(le=0;le>>0,isFinite(k)?(k=k>>>0,E===void 0&&(E="utf8")):(E=k,k=void 0);else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");let A=this.length-S;if((k===void 0||k>A)&&(k=A),_.length>0&&(k<0||S<0)||S>this.length)throw RangeError("Attempt to write outside buffer bounds");E||(E="utf8");let Q=!1;for(;;)switch(E){case"hex":return O(this,_,S,k);case"utf8":case"utf-8":return C(this,_,S,k);case"ascii":case"latin1":case"binary":return X(this,_,S,k);case"base64":return te(this,_,S,k);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return L(this,_,S,k);default:if(Q)throw TypeError("Unknown encoding: "+E);E=(""+E).toLowerCase(),Q=!0}},a.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function Y(_,S,k){return S===0&&k===_.length?t.fromByteArray(_):t.fromByteArray(_.slice(S,k))}function me(_,S,k){k=Math.min(_.length,k);let E=[],A=S;for(;A239?4:Q>223?3:Q>191?2:1;if(A+Je<=k){let Et,ut,wt,At;switch(Je){case 1:Q<128&&(le=Q);break;case 2:Et=_[A+1],(Et&192)===128&&(At=(Q&31)<<6|Et&63,At>127&&(le=At));break;case 3:Et=_[A+1],ut=_[A+2],(Et&192)===128&&(ut&192)===128&&(At=(Q&15)<<12|(Et&63)<<6|ut&63,At>2047&&(At<55296||At>57343)&&(le=At));break;case 4:Et=_[A+1],ut=_[A+2],wt=_[A+3],(Et&192)===128&&(ut&192)===128&&(wt&192)===128&&(At=(Q&15)<<18|(Et&63)<<12|(ut&63)<<6|wt&63,At>65535&&At<1114112&&(le=At))}}le===null?(le=65533,Je=1):le>65535&&(le-=65536,E.push(le>>>10&1023|55296),le=56320|le&1023),E.push(le),A+=Je}return Z(E)}var I=4096;function Z(_){let S=_.length;if(S<=I)return String.fromCharCode.apply(String,_);let k="",E=0;for(;EE)&&(k=E);let A="";for(let Q=S;Qk&&(_=k),S<0?(S+=k,S<0&&(S=0)):S>k&&(S=k),S<_&&(S=_);let E=this.subarray(_,S);return Object.setPrototypeOf(E,a.prototype),E};function Ie(_,S,k){if(_%1!==0||_<0)throw RangeError("offset is not uint");if(_+S>k)throw RangeError("Trying to access beyond buffer length")}a.prototype.readUintLE=a.prototype.readUIntLE=function(_,S,k){_=_>>>0,S=S>>>0,k||Ie(_,S,this.length);let E=this[_],A=1,Q=0;for(;++Q>>0,S=S>>>0,k||Ie(_,S,this.length);let E=this[_+--S],A=1;for(;S>0&&(A*=256);)E+=this[_+--S]*A;return E},a.prototype.readUint8=a.prototype.readUInt8=function(_,S){return _=_>>>0,S||Ie(_,1,this.length),this[_]},a.prototype.readUint16LE=a.prototype.readUInt16LE=function(_,S){return _=_>>>0,S||Ie(_,2,this.length),this[_]|this[_+1]<<8},a.prototype.readUint16BE=a.prototype.readUInt16BE=function(_,S){return _=_>>>0,S||Ie(_,2,this.length),this[_]<<8|this[_+1]},a.prototype.readUint32LE=a.prototype.readUInt32LE=function(_,S){return _=_>>>0,S||Ie(_,4,this.length),(this[_]|this[_+1]<<8|this[_+2]<<16)+this[_+3]*16777216},a.prototype.readUint32BE=a.prototype.readUInt32BE=function(_,S){return _=_>>>0,S||Ie(_,4,this.length),this[_]*16777216+(this[_+1]<<16|this[_+2]<<8|this[_+3])},a.prototype.readBigUInt64LE=Ce(function(_){_=_>>>0,Re(_,"offset");let S=this[_],k=this[_+7];(S===void 0||k===void 0)&&Oe(_,this.length-8);let E=S+this[++_]*256+this[++_]*65536+this[++_]*16777216,A=this[++_]+this[++_]*256+this[++_]*65536+k*16777216;return BigInt(E)+(BigInt(A)<>>0,Re(_,"offset");let S=this[_],k=this[_+7];(S===void 0||k===void 0)&&Oe(_,this.length-8);let E=S*16777216+this[++_]*65536+this[++_]*256+this[++_],A=this[++_]*16777216+this[++_]*65536+this[++_]*256+k;return(BigInt(E)<>>0,S=S>>>0,k||Ie(_,S,this.length);let E=this[_],A=1,Q=0;for(;++Q=A&&(E-=Math.pow(2,8*S)),E},a.prototype.readIntBE=function(_,S,k){_=_>>>0,S=S>>>0,k||Ie(_,S,this.length);let E=S,A=1,Q=this[_+--E];for(;E>0&&(A*=256);)Q+=this[_+--E]*A;return A*=128,Q>=A&&(Q-=Math.pow(2,8*S)),Q},a.prototype.readInt8=function(_,S){return _=_>>>0,S||Ie(_,1,this.length),this[_]&128?(255-this[_]+1)*-1:this[_]},a.prototype.readInt16LE=function(_,S){_=_>>>0,S||Ie(_,2,this.length);let k=this[_]|this[_+1]<<8;return k&32768?k|4294901760:k},a.prototype.readInt16BE=function(_,S){_=_>>>0,S||Ie(_,2,this.length);let k=this[_+1]|this[_]<<8;return k&32768?k|4294901760:k},a.prototype.readInt32LE=function(_,S){return _=_>>>0,S||Ie(_,4,this.length),this[_]|this[_+1]<<8|this[_+2]<<16|this[_+3]<<24},a.prototype.readInt32BE=function(_,S){return _=_>>>0,S||Ie(_,4,this.length),this[_]<<24|this[_+1]<<16|this[_+2]<<8|this[_+3]},a.prototype.readBigInt64LE=Ce(function(_){_=_>>>0,Re(_,"offset");let S=this[_],k=this[_+7];(S===void 0||k===void 0)&&Oe(_,this.length-8);let E=this[_+4]+this[_+5]*256+this[_+6]*65536+(k<<24);return(BigInt(E)<>>0,Re(_,"offset");let S=this[_],k=this[_+7];(S===void 0||k===void 0)&&Oe(_,this.length-8);let E=(S<<24)+this[++_]*65536+this[++_]*256+this[++_];return(BigInt(E)<>>0,S||Ie(_,4,this.length),n.read(this,_,!0,23,4)},a.prototype.readFloatBE=function(_,S){return _=_>>>0,S||Ie(_,4,this.length),n.read(this,_,!1,23,4)},a.prototype.readDoubleLE=function(_,S){return _=_>>>0,S||Ie(_,8,this.length),n.read(this,_,!0,52,8)},a.prototype.readDoubleBE=function(_,S){return _=_>>>0,S||Ie(_,8,this.length),n.read(this,_,!1,52,8)};function J(_,S,k,E,A,Q){if(!a.isBuffer(_))throw TypeError('"buffer" argument must be a Buffer instance');if(S>A||S_.length)throw RangeError("Index out of range")}a.prototype.writeUintLE=a.prototype.writeUIntLE=function(_,S,k,E){if(_=+_,S=S>>>0,k=k>>>0,!E){let le=Math.pow(2,8*k)-1;J(this,_,S,k,le,0)}let A=1,Q=0;for(this[S]=_&255;++Q>>0,k=k>>>0,!E){let le=Math.pow(2,8*k)-1;J(this,_,S,k,le,0)}let A=k-1,Q=1;for(this[S+A]=_&255;--A>=0&&(Q*=256);)this[S+A]=_/Q&255;return S+k},a.prototype.writeUint8=a.prototype.writeUInt8=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,1,255,0),this[S]=_&255,S+1},a.prototype.writeUint16LE=a.prototype.writeUInt16LE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,2,65535,0),this[S]=_&255,this[S+1]=_>>>8,S+2},a.prototype.writeUint16BE=a.prototype.writeUInt16BE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,2,65535,0),this[S]=_>>>8,this[S+1]=_&255,S+2},a.prototype.writeUint32LE=a.prototype.writeUInt32LE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,4,4294967295,0),this[S+3]=_>>>24,this[S+2]=_>>>16,this[S+1]=_>>>8,this[S]=_&255,S+4},a.prototype.writeUint32BE=a.prototype.writeUInt32BE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,4,4294967295,0),this[S]=_>>>24,this[S+1]=_>>>16,this[S+2]=_>>>8,this[S+3]=_&255,S+4};function _e(_,S,k,E,A){Ne(S,E,A,_,k,7);let Q=Number(S&BigInt(4294967295));_[k++]=Q,Q=Q>>8,_[k++]=Q,Q=Q>>8,_[k++]=Q,Q=Q>>8,_[k++]=Q;let le=Number(S>>BigInt(32)&BigInt(4294967295));return _[k++]=le,le=le>>8,_[k++]=le,le=le>>8,_[k++]=le,le=le>>8,_[k++]=le,k}function ue(_,S,k,E,A){Ne(S,E,A,_,k,7);let Q=Number(S&BigInt(4294967295));_[k+7]=Q,Q=Q>>8,_[k+6]=Q,Q=Q>>8,_[k+5]=Q,Q=Q>>8,_[k+4]=Q;let le=Number(S>>BigInt(32)&BigInt(4294967295));return _[k+3]=le,le=le>>8,_[k+2]=le,le=le>>8,_[k+1]=le,le=le>>8,_[k]=le,k+8}a.prototype.writeBigUInt64LE=Ce(function(_,S=0){return _e(this,_,S,BigInt(0),BigInt("0xffffffffffffffff"))}),a.prototype.writeBigUInt64BE=Ce(function(_,S=0){return ue(this,_,S,BigInt(0),BigInt("0xffffffffffffffff"))}),a.prototype.writeIntLE=function(_,S,k,E){if(_=+_,S=S>>>0,!E){let Je=Math.pow(2,8*k-1);J(this,_,S,k,Je-1,-Je)}let A=0,Q=1,le=0;for(this[S]=_&255;++A>0)-le&255;return S+k},a.prototype.writeIntBE=function(_,S,k,E){if(_=+_,S=S>>>0,!E){let Je=Math.pow(2,8*k-1);J(this,_,S,k,Je-1,-Je)}let A=k-1,Q=1,le=0;for(this[S+A]=_&255;--A>=0&&(Q*=256);)_<0&&le===0&&this[S+A+1]!==0&&(le=1),this[S+A]=(_/Q>>0)-le&255;return S+k},a.prototype.writeInt8=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,1,127,-128),_<0&&(_=255+_+1),this[S]=_&255,S+1},a.prototype.writeInt16LE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,2,32767,-32768),this[S]=_&255,this[S+1]=_>>>8,S+2},a.prototype.writeInt16BE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,2,32767,-32768),this[S]=_>>>8,this[S+1]=_&255,S+2},a.prototype.writeInt32LE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,4,2147483647,-2147483648),this[S]=_&255,this[S+1]=_>>>8,this[S+2]=_>>>16,this[S+3]=_>>>24,S+4},a.prototype.writeInt32BE=function(_,S,k){return _=+_,S=S>>>0,k||J(this,_,S,4,2147483647,-2147483648),_<0&&(_=4294967295+_+1),this[S]=_>>>24,this[S+1]=_>>>16,this[S+2]=_>>>8,this[S+3]=_&255,S+4},a.prototype.writeBigInt64LE=Ce(function(_,S=0){return _e(this,_,S,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),a.prototype.writeBigInt64BE=Ce(function(_,S=0){return ue(this,_,S,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function ce(_,S,k,E,A,Q){if(k+E>_.length)throw RangeError("Index out of range");if(k<0)throw RangeError("Index out of range")}function Le(_,S,k,E,A){return S=+S,k=k>>>0,A||ce(_,S,k,4,340282346638528860000000000000000000000,-340282346638528860000000000000000000000),n.write(_,S,k,E,23,4),k+4}a.prototype.writeFloatLE=function(_,S,k){return Le(this,_,S,!0,k)},a.prototype.writeFloatBE=function(_,S,k){return Le(this,_,S,!1,k)};function Ke(_,S,k,E,A){return S=+S,k=k>>>0,A||ce(_,S,k,8,179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000,-179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000),n.write(_,S,k,E,52,8),k+8}a.prototype.writeDoubleLE=function(_,S,k){return Ke(this,_,S,!0,k)},a.prototype.writeDoubleBE=function(_,S,k){return Ke(this,_,S,!1,k)},a.prototype.copy=function(_,S,k,E){if(!a.isBuffer(_))throw TypeError("argument should be a Buffer");if(k||(k=0),!E&&E!==0&&(E=this.length),S>=_.length&&(S=_.length),S||(S=0),E>0&&E=this.length)throw RangeError("Index out of range");if(E<0)throw RangeError("sourceEnd out of bounds");E>this.length&&(E=this.length),_.length-S>>0,k=k===void 0?this.length:k>>>0,_||(_=0);let A;if(typeof _=="number")for(A=S;A4294967296?A=se(String(k)):typeof k=="bigint"&&(A=String(k),(k>BigInt(2)**BigInt(32)||k<-(BigInt(2)**BigInt(32)))&&(A=se(A)),A+="n"),E+=` It must be ${S}. Received ${A}`,E},RangeError);function se(_){let S="",k=_.length,E=_[0]==="-"?1:0;for(;k>=E+4;k-=3)S=`_${_.slice(k-3,k)}${S}`;return`${_.slice(0,k)}${S}`}function he(_,S,k){Re(S,"offset"),(_[S]===void 0||_[S+k]===void 0)&&Oe(S,_.length-(k+1))}function Ne(_,S,k,E,A,Q){if(_>k||_3?S===0||S===BigInt(0)?Je=`>= 0${le} and < 2${le} ** ${(Q+1)*8}${le}`:Je=`>= -(2${le} ** ${(Q+1)*8-1}${le}) and < 2 ** ${(Q+1)*8-1}${le}`:Je=`>= ${S}${le} and <= ${k}${le}`,new ct.ERR_OUT_OF_RANGE("value",Je,_)}he(E,A,Q)}function Re(_,S){if(typeof _!="number")throw new ct.ERR_INVALID_ARG_TYPE(S,"number",_)}function Oe(_,S,k){throw Math.floor(_)!==_?(Re(_,k),new ct.ERR_OUT_OF_RANGE(k||"offset","an integer",_)):S<0?new ct.ERR_BUFFER_OUT_OF_BOUNDS:new ct.ERR_OUT_OF_RANGE(k||"offset",`>= ${k?1:0} and <= ${S}`,_)}var G=/[^+/0-9A-Za-z-_]/g;function V(_){if(_=_.split("=")[0],_=_.trim().replace(G,""),_.length<2)return"";for(;_.length%4!==0;)_=_+"=";return _}function j(_,S){S=S||1/0;let k,E=_.length,A=null,Q=[];for(let le=0;le55295&&k<57344){if(!A){if(k>56319){(S-=3)>-1&&Q.push(239,191,189);continue}else if(le+1===E){(S-=3)>-1&&Q.push(239,191,189);continue}A=k;continue}if(k<56320){(S-=3)>-1&&Q.push(239,191,189),A=k;continue}k=(A-55296<<10|k-56320)+65536}else A&&(S-=3)>-1&&Q.push(239,191,189);if(A=null,k<128){if((S-=1)<0)break;Q.push(k)}else if(k<2048){if((S-=2)<0)break;Q.push(k>>6|192,k&63|128)}else if(k<65536){if((S-=3)<0)break;Q.push(k>>12|224,k>>6&63|128,k&63|128)}else if(k<1114112){if((S-=4)<0)break;Q.push(k>>18|240,k>>12&63|128,k>>6&63|128,k&63|128)}else throw Error("Invalid code point")}return Q}function H(_){let S=[];for(let k=0;k<_.length;++k)S.push(_.charCodeAt(k)&255);return S}function ge(_,S){let k,E,A,Q=[];for(let le=0;le<_.length&&!((S-=2)<0);++le)k=_.charCodeAt(le),E=k>>8,A=k%256,Q.push(A),Q.push(E);return Q}function fe(_){return t.toByteArray(V(_))}function W(_,S,k,E){let A;for(A=0;A=S.length||A>=_.length);++A)S[A+k]=_[A];return A}function ye(_,S){return _ instanceof S||_!=null&&_.constructor!=null&&_.constructor.name!=null&&_.constructor.name===S.name}function Pe(_){return _!==_}var Se=function(){let _="0123456789abcdef",S=Array(256);for(let k=0;k<16;++k){let E=k*16;for(let A=0;A<16;++A)S[E+A]=_[k]+_[A]}return S}();function Ce(_){return typeof BigInt>"u"?Bt:_}function Bt(){throw Error("BigInt not supported")}}),or=un((e,t)=>{var n=class extends Error{constructor(r){if(!Array.isArray(r))throw TypeError(`Expected input to be an Array, got ${typeof r}`);let i="";for(let s=0;s{t.exports={format(n,...r){return n.replace(/%([sdifj])/g,function(...[i,s]){let o=r.shift();return s==="f"?o.toFixed(6):s==="j"?JSON.stringify(o):s==="s"&&typeof o=="object"?`${o.constructor!==Object?o.constructor.name:""} {}`.trim():o.toString()})},inspect(n){switch(typeof n){case"string":if(n.includes("'"))if(n.includes('"')){if(!n.includes("`")&&!n.includes("${"))return`\`${n}\``}else return`"${n}"`;return`'${n}'`;case"number":return isNaN(n)?"NaN":Object.is(n,-0)?String(n):n;case"bigint":return`${String(n)}n`;case"boolean":case"undefined":return String(n);case"object":return"{}"}}}}),ss=un((e,t)=>{var{format:n,inspect:r}=kae(),{AggregateError:i}=or(),s=globalThis.AggregateError||i,o=Symbol("kIsNodeError"),a=["string","function","number","object","Function","Object","boolean","bigint","symbol"],l=/^([A-Z][a-z0-9]*)+$/,c="__node_internal_",u={};function p(g,x){if(!g)throw new u.ERR_INTERNAL_ASSERTION(x)}function d(g){let x="",v=g.length,D=g[0]==="-"?1:0;for(;v>=D+4;v-=3)x=`_${g.slice(v-3,v)}${x}`;return`${g.slice(0,v)}${x}`}function f(g,x,v){if(typeof x=="function")return p(x.length<=v.length,`Code: ${g}; The provided arguments length (${v.length}) does not match the required ones (${x.length}).`),x(...v);let D=(x.match(/%[dfijoOs]/g)||[]).length;return p(D===v.length,`Code: ${g}; The provided arguments length (${v.length}) does not match the required ones (${D}).`),v.length===0?x:n(x,...v)}function m(g,x,v){v||(v=Error);class D extends v{constructor(...T){super(f(g,x,T))}toString(){return`${this.name} [${g}]: ${this.message}`}}Object.defineProperties(D.prototype,{name:{value:v.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${g}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),D.prototype.code=g,D.prototype[o]=!0,u[g]=D}function y(g){let x=c+g.name;return Object.defineProperty(g,"name",{value:x}),g}function h(g,x){if(g&&x&&g!==x){if(Array.isArray(x.errors))return x.errors.push(g),x;let v=new s([x,g],x.message);return v.code=x.code,v}return g||x}var b=class extends Error{constructor(g="The operation was aborted",x=void 0){if(x!==void 0&&typeof x!="object")throw new u.ERR_INVALID_ARG_TYPE("options","Object",x);super(g,x),this.code="ABORT_ERR",this.name="AbortError"}};m("ERR_ASSERTION","%s",Error),m("ERR_INVALID_ARG_TYPE",(g,x,v)=>{p(typeof g=="string","'name' must be a string"),Array.isArray(x)||(x=[x]);let D="The ";g.endsWith(" argument")?D+=`${g} `:D+=`"${g}" ${g.includes(".")?"property":"argument"} `,D+="must be ";let T=[],N=[],O=[];for(let X of x)p(typeof X=="string","All expected entries have to be of type string"),a.includes(X)?T.push(X.toLowerCase()):l.test(X)?N.push(X):(p(X!=="object",'The value "object" should be written as "Object"'),O.push(X));if(N.length>0){let X=T.indexOf("object");X!==-1&&(T.splice(T,X,1),N.push("Object"))}if(T.length>0){switch(T.length){case 1:D+=`of type ${T[0]}`;break;case 2:D+=`one of type ${T[0]} or ${T[1]}`;break;default:{let X=T.pop();D+=`one of type ${T.join(", ")}, or ${X}`}}(N.length>0||O.length>0)&&(D+=" or ")}if(N.length>0){switch(N.length){case 1:D+=`an instance of ${N[0]}`;break;case 2:D+=`an instance of ${N[0]} or ${N[1]}`;break;default:{let X=N.pop();D+=`an instance of ${N.join(", ")}, or ${X}`}}O.length>0&&(D+=" or ")}switch(O.length){case 0:break;case 1:O[0].toLowerCase()!==O[0]&&(D+="an "),D+=`${O[0]}`;break;case 2:D+=`one of ${O[0]} or ${O[1]}`;break;default:{let X=O.pop();D+=`one of ${O.join(", ")}, or ${X}`}}if(v==null)D+=`. Received ${v}`;else if(typeof v=="function"&&v.name)D+=`. Received function ${v.name}`;else if(typeof v=="object"){var C;if((C=v.constructor)!==null&&C!==void 0&&C.name)D+=`. Received an instance of ${v.constructor.name}`;else{let X=r(v,{depth:-1});D+=`. Received ${X}`}}else{let X=r(v,{colors:!1});X.length>25&&(X=`${X.slice(0,25)}...`),D+=`. Received type ${typeof v} (${X})`}return D},TypeError),m("ERR_INVALID_ARG_VALUE",(g,x,v="is invalid")=>{let D=r(x);return D.length>128&&(D=D.slice(0,128)+"..."),`The ${g.includes(".")?"property":"argument"} '${g}' ${v}. Received ${D}`},TypeError),m("ERR_INVALID_RETURN_VALUE",(g,x,v)=>{var D;let T=v!=null&&(D=v.constructor)!==null&&D!==void 0&&D.name?`instance of ${v.constructor.name}`:`type ${typeof v}`;return`Expected ${g} to be returned from the "${x}" function but got ${T}.`},TypeError),m("ERR_MISSING_ARGS",(...g)=>{p(g.length>0,"At least one arg needs to be specified");let x,v=g.length;switch(g=(Array.isArray(g)?g:[g]).map((D)=>`"${D}"`).join(" or "),v){case 1:x+=`The ${g[0]} argument`;break;case 2:x+=`The ${g[0]} and ${g[1]} arguments`;break;default:{let D=g.pop();x+=`The ${g.join(", ")}, and ${D} arguments`}break}return`${x} must be specified`},TypeError),m("ERR_OUT_OF_RANGE",(g,x,v)=>{p(x,'Missing "range" argument');let D;if(Number.isInteger(v)&&Math.abs(v)>4294967296)D=d(String(v));else if(typeof v=="bigint"){D=String(v);let T=BigInt(2)**BigInt(32);(v>T||v<-T)&&(D=d(D)),D+="n"}else D=r(v);return`The value of "${g}" is out of range. It must be ${x}. Received ${D}`},RangeError),m("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error),m("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error),m("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error),m("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error),m("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error),m("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),m("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error),m("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error),m("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error),m("ERR_STREAM_WRITE_AFTER_END","write after end",Error),m("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError),t.exports={AbortError:b,aggregateTwoErrors:y(h),hideStackFrames:y,codes:u}}),c_=un((e,t)=>{var{AbortController:n,AbortSignal:r}=typeof self<"u"?self:typeof window<"u"?window:void 0;t.exports=n,t.exports.AbortSignal=r,t.exports.default=n}),nE=un((e,t)=>{var n=typeof Reflect=="object"?Reflect:null,r=n&&typeof n.apply=="function"?n.apply:function(T,N,O){return Function.prototype.apply.call(T,N,O)},i;n&&typeof n.ownKeys=="function"?i=n.ownKeys:Object.getOwnPropertySymbols?i=function(T){return Object.getOwnPropertyNames(T).concat(Object.getOwnPropertySymbols(T))}:i=function(T){return Object.getOwnPropertyNames(T)};function s(T){console&&console.warn&&console.warn(T)}var o=Number.isNaN||function(T){return T!==T};function a(){a.init.call(this)}t.exports=a,t.exports.once=x,a.EventEmitter=a,a.prototype._events=void 0,a.prototype._eventsCount=0,a.prototype._maxListeners=void 0;var l=10;function c(T){if(typeof T!="function")throw TypeError('The "listener" argument must be of type Function. Received type '+typeof T)}Object.defineProperty(a,"defaultMaxListeners",{enumerable:!0,get:function(){return l},set:function(T){if(typeof T!="number"||T<0||o(T))throw RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+T+".");l=T}}),a.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},a.prototype.setMaxListeners=function(T){if(typeof T!="number"||T<0||o(T))throw RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+T+".");return this._maxListeners=T,this};function u(T){return T._maxListeners===void 0?a.defaultMaxListeners:T._maxListeners}a.prototype.getMaxListeners=function(){return u(this)},a.prototype.emit=function(T){for(var N=[],O=1;O0&&(te=N[0]),te instanceof Error)throw te;var L=Error("Unhandled error."+(te?" ("+te.message+")":""));throw L.context=te,L}var Y=X[T];if(Y===void 0)return!1;if(typeof Y=="function")r(Y,this,N);else for(var me=Y.length,I=h(Y,me),O=0;O0&&L.length>X&&!L.warned){L.warned=!0;var Y=Error("Possible EventEmitter memory leak detected. "+L.length+" "+String(N)+" listeners added. Use emitter.setMaxListeners() to increase limit");Y.name="MaxListenersExceededWarning",Y.emitter=T,Y.type=N,Y.count=L.length,s(Y)}return T}a.prototype.addListener=function(T,N){return p(this,T,N,!1)},a.prototype.on=a.prototype.addListener,a.prototype.prependListener=function(T,N){return p(this,T,N,!0)};function d(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function f(T,N,O){var C={fired:!1,wrapFn:void 0,target:T,type:N,listener:O},X=d.bind(C);return X.listener=O,C.wrapFn=X,X}a.prototype.once=function(T,N){return c(N),this.on(T,f(this,T,N)),this},a.prototype.prependOnceListener=function(T,N){return c(N),this.prependListener(T,f(this,T,N)),this},a.prototype.removeListener=function(T,N){var O,C,X,te,L;if(c(N),C=this._events,C===void 0)return this;if(O=C[T],O===void 0)return this;if(O===N||O.listener===N)--this._eventsCount===0?this._events=Object.create(null):(delete C[T],C.removeListener&&this.emit("removeListener",T,O.listener||N));else if(typeof O!="function"){for(X=-1,te=O.length-1;te>=0;te--)if(O[te]===N||O[te].listener===N){L=O[te].listener,X=te;break}if(X<0)return this;X===0?O.shift():b(O,X),O.length===1&&(C[T]=O[0]),C.removeListener!==void 0&&this.emit("removeListener",T,L||N)}return this},a.prototype.off=a.prototype.removeListener,a.prototype.removeAllListeners=function(T){var N,O,C;if(O=this._events,O===void 0)return this;if(O.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):O[T]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete O[T]),this;if(arguments.length===0){var X=Object.keys(O),te;for(C=0;C=0;C--)this.removeListener(T,N[C]);return this};function m(T,N,O){var C=T._events;if(C===void 0)return[];var X=C[N];return X===void 0?[]:typeof X=="function"?O?[X.listener||X]:[X]:O?g(X):h(X,X.length)}a.prototype.listeners=function(T){return m(this,T,!0)},a.prototype.rawListeners=function(T){return m(this,T,!1)},a.listenerCount=function(T,N){return typeof T.listenerCount=="function"?T.listenerCount(N):y.call(T,N)},a.prototype.listenerCount=y;function y(T){var N=this._events;if(N!==void 0){var O=N[T];if(typeof O=="function")return 1;if(O!==void 0)return O.length}return 0}a.prototype.eventNames=function(){return this._eventsCount>0?i(this._events):[]};function h(T,N){for(var O=Array(N),C=0;C{var n=Uc(),{format:r,inspect:i}=kae(),{codes:{ERR_INVALID_ARG_TYPE:s}}=ss(),{kResistStopPropagation:o,AggregateError:a,SymbolDispose:l}=or(),c=globalThis.AbortSignal||c_().AbortSignal,u=globalThis.AbortController||c_().AbortController,p=Object.getPrototypeOf(async function(){}).constructor,d=globalThis.Blob||n.Blob,f=typeof d<"u"?function(h){return h instanceof d}:function(h){return!1},m=(h,b)=>{if(h!==void 0&&(h===null||typeof h!="object"||!("aborted"in h)))throw new s(b,"AbortSignal",h)},y=(h,b)=>{if(typeof h!="function")throw new s(b,"Function",h)};t.exports={AggregateError:a,kEmptyObject:Object.freeze({}),once(h){let b=!1;return function(...g){b||(b=!0,h.apply(this,g))}},createDeferredPromise:function(){let h,b;return{promise:new Promise((g,x)=>{h=g,b=x}),resolve:h,reject:b}},promisify(h){return new Promise((b,g)=>{h((x,...v)=>x?g(x):b(...v))})},debuglog(){return function(){}},format:r,inspect:i,types:{isAsyncFunction(h){return h instanceof p},isArrayBufferView(h){return ArrayBuffer.isView(h)}},isBlob:f,deprecate(h,b){return h},addAbortListener:nE().addAbortListener||function(h,b){if(h===void 0)throw new s("signal","AbortSignal",h);m(h,"signal"),y(b,"listener");let g;return h.aborted?queueMicrotask(()=>b()):(h.addEventListener("abort",b,{__proto__:null,once:!0,[o]:!0}),g=()=>{h.removeEventListener("abort",b)}),{__proto__:null,[l](){var x;(x=g)===null||x===void 0||x()}}},AbortSignalAny:c.any||function(h){if(h.length===1)return h[0];let b=new u,g=()=>b.abort();return h.forEach((x)=>{m(x,"signals"),x.addEventListener("abort",g,{once:!0})}),b.signal.addEventListener("abort",()=>{h.forEach((x)=>x.removeEventListener("abort",g))},{once:!0}),b.signal}},t.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")}),u_=un((e,t)=>{var{ArrayIsArray:n,ArrayPrototypeIncludes:r,ArrayPrototypeJoin:i,ArrayPrototypeMap:s,NumberIsInteger:o,NumberIsNaN:a,NumberMAX_SAFE_INTEGER:l,NumberMIN_SAFE_INTEGER:c,NumberParseInt:u,ObjectPrototypeHasOwnProperty:p,RegExpPrototypeExec:d,String:f,StringPrototypeToUpperCase:m,StringPrototypeTrim:y}=or(),{hideStackFrames:h,codes:{ERR_SOCKET_BAD_PORT:b,ERR_INVALID_ARG_TYPE:g,ERR_INVALID_ARG_VALUE:x,ERR_OUT_OF_RANGE:v,ERR_UNKNOWN_SIGNAL:D}}=ss(),{normalizeEncoding:T}=qs(),{isAsyncFunction:N,isArrayBufferView:O}=qs().types,C={};function X(W){return W===(W|0)}function te(W){return W===W>>>0}var L=/^[0-7]+$/,Y="must be a 32-bit unsigned integer or an octal string";function me(W,ye,Pe){if(typeof W>"u"&&(W=Pe),typeof W=="string"){if(d(L,W)===null)throw new x(ye,W,Y);W=u(W,8)}return pe(W,ye),W}var I=h((W,ye,Pe=c,Se=l)=>{if(typeof W!="number")throw new g(ye,"number",W);if(!o(W))throw new v(ye,"an integer",W);if(WSe)throw new v(ye,`>= ${Pe} && <= ${Se}`,W)}),Z=h((W,ye,Pe=-2147483648,Se=2147483647)=>{if(typeof W!="number")throw new g(ye,"number",W);if(!o(W))throw new v(ye,"an integer",W);if(WSe)throw new v(ye,`>= ${Pe} && <= ${Se}`,W)}),pe=h((W,ye,Pe=!1)=>{if(typeof W!="number")throw new g(ye,"number",W);if(!o(W))throw new v(ye,"an integer",W);let Se=Pe?1:0,Ce=4294967295;if(WCe)throw new v(ye,`>= ${Se} && <= ${Ce}`,W)});function de(W,ye){if(typeof W!="string")throw new g(ye,"string",W)}function je(W,ye,Pe=void 0,Se){if(typeof W!="number")throw new g(ye,"number",W);if(Pe!=null&&WSe||(Pe!=null||Se!=null)&&a(W))throw new v(ye,`${Pe!=null?`>= ${Pe}`:""}${Pe!=null&&Se!=null?" && ":""}${Se!=null?`<= ${Se}`:""}`,W)}var be=h((W,ye,Pe)=>{if(!r(Pe,W)){let Se="must be one of: "+i(s(Pe,(Ce)=>typeof Ce=="string"?`'${Ce}'`:f(Ce)),", ");throw new x(ye,W,Se)}});function Ie(W,ye){if(typeof W!="boolean")throw new g(ye,"boolean",W)}function J(W,ye,Pe){return W==null||!p(W,ye)?Pe:W[ye]}var _e=h((W,ye,Pe=null)=>{let Se=J(Pe,"allowArray",!1),Ce=J(Pe,"allowFunction",!1);if(!J(Pe,"nullable",!1)&&W===null||!Se&&n(W)||typeof W!="object"&&(!Ce||typeof W!="function"))throw new g(ye,"Object",W)}),ue=h((W,ye)=>{if(W!=null&&typeof W!="object"&&typeof W!="function")throw new g(ye,"a dictionary",W)}),ce=h((W,ye,Pe=0)=>{if(!n(W))throw new g(ye,"Array",W);if(W.length{if(!O(W))throw new g(ye,["Buffer","TypedArray","DataView"],W)});function he(W,ye){let Pe=T(ye),Se=W.length;if(Pe==="hex"&&Se%2!==0)throw new x("encoding",ye,`is invalid for data of length ${Se}`)}function Ne(W,ye="Port",Pe=!0){if(typeof W!="number"&&typeof W!="string"||typeof W=="string"&&y(W).length===0||+W!==+W>>>0||W>65535||W===0&&!Pe)throw new b(ye,W,Pe);return W|0}var Re=h((W,ye)=>{if(W!==void 0&&(W===null||typeof W!="object"||!("aborted"in W)))throw new g(ye,"AbortSignal",W)}),Oe=h((W,ye)=>{if(typeof W!="function")throw new g(ye,"Function",W)}),G=h((W,ye)=>{if(typeof W!="function"||N(W))throw new g(ye,"Function",W)}),V=h((W,ye)=>{if(W!==void 0)throw new g(ye,"undefined",W)});function j(W,ye,Pe){if(!r(Pe,W))throw new g(ye,`('${i(Pe,"|")}')`,W)}var H=/^(?:<[^>]*>)(?:\s*;\s*[^;"\s]+(?:=(")?[^;"\s]*\1)?)*$/;function ge(W,ye){if(typeof W>"u"||!d(H,W))throw new x(ye,W,'must be an array or string of format "; rel=preload; as=style"')}function fe(W){if(typeof W=="string")return ge(W,"hints"),W;if(n(W)){let ye=W.length,Pe="";if(ye===0)return Pe;for(let Se=0;Se; rel=preload; as=style"')}t.exports={isInt32:X,isUint32:te,parseFileMode:me,validateArray:ce,validateStringArray:Le,validateBooleanArray:Ke,validateAbortSignalArray:ct,validateBoolean:Ie,validateBuffer:se,validateDictionary:ue,validateEncoding:he,validateFunction:Oe,validateInt32:Z,validateInteger:I,validateNumber:je,validateObject:_e,validateOneOf:be,validatePlainFunction:G,validatePort:Ne,validateSignalName:lt,validateString:de,validateUint32:pe,validateUndefined:V,validateUnion:j,validateAbortSignal:Re,validateLinkHeaderValue:fe}}),Tf=un((e,t)=>{var n=t.exports={},r,i;function s(){throw Error("setTimeout has not been defined")}function o(){throw Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?r=setTimeout:r=s}catch(b){r=s}try{typeof clearTimeout=="function"?i=clearTimeout:i=o}catch(b){i=o}})();function a(b){if(r===setTimeout)return setTimeout(b,0);if((r===s||!r)&&setTimeout)return r=setTimeout,setTimeout(b,0);try{return r(b,0)}catch(g){try{return r.call(null,b,0)}catch(x){return r.call(this,b,0)}}}function l(b){if(i===clearTimeout)return clearTimeout(b);if((i===o||!i)&&clearTimeout)return i=clearTimeout,clearTimeout(b);try{return i(b)}catch(g){try{return i.call(null,b)}catch(x){return i.call(this,b)}}}var c=[],u=!1,p,d=-1;function f(){!u||!p||(u=!1,p.length?c=p.concat(c):d=-1,c.length&&m())}function m(){if(!u){var b=a(f);u=!0;for(var g=c.length;g;){for(p=c,c=[];++d1)for(var x=1;x{var{SymbolAsyncIterator:n,SymbolIterator:r,SymbolFor:i}=or(),s=i("nodejs.stream.destroyed"),o=i("nodejs.stream.errored"),a=i("nodejs.stream.readable"),l=i("nodejs.stream.writable"),c=i("nodejs.stream.disturbed"),u=i("nodejs.webstream.isClosedPromise"),p=i("nodejs.webstream.controllerErrorFunction");function d(J,_e=!1){var ue;return!!(J&&typeof J.pipe=="function"&&typeof J.on=="function"&&(!_e||typeof J.pause=="function"&&typeof J.resume=="function")&&(!J._writableState||((ue=J._readableState)===null||ue===void 0?void 0:ue.readable)!==!1)&&(!J._writableState||J._readableState))}function f(J){var _e;return!!(J&&typeof J.write=="function"&&typeof J.on=="function"&&(!J._readableState||((_e=J._writableState)===null||_e===void 0?void 0:_e.writable)!==!1))}function m(J){return!!(J&&typeof J.pipe=="function"&&J._readableState&&typeof J.on=="function"&&typeof J.write=="function")}function y(J){return J&&(J._readableState||J._writableState||typeof J.write=="function"&&typeof J.on=="function"||typeof J.pipe=="function"&&typeof J.on=="function")}function h(J){return!!(J&&!y(J)&&typeof J.pipeThrough=="function"&&typeof J.getReader=="function"&&typeof J.cancel=="function")}function b(J){return!!(J&&!y(J)&&typeof J.getWriter=="function"&&typeof J.abort=="function")}function g(J){return!!(J&&!y(J)&&typeof J.readable=="object"&&typeof J.writable=="object")}function x(J){return h(J)||b(J)||g(J)}function v(J,_e){return J==null?!1:_e===!0?typeof J[n]=="function":_e===!1?typeof J[r]=="function":typeof J[n]=="function"||typeof J[r]=="function"}function D(J){if(!y(J))return null;let{_writableState:_e,_readableState:ue}=J,ce=_e||ue;return!!(J.destroyed||J[s]||ce!=null&&ce.destroyed)}function T(J){if(!f(J))return null;if(J.writableEnded===!0)return!0;let _e=J._writableState;return _e!=null&&_e.errored?!1:typeof(_e==null?void 0:_e.ended)!="boolean"?null:_e.ended}function N(J,_e){if(!f(J))return null;if(J.writableFinished===!0)return!0;let ue=J._writableState;return ue!=null&&ue.errored?!1:typeof(ue==null?void 0:ue.finished)!="boolean"?null:!!(ue.finished||_e===!1&&ue.ended===!0&&ue.length===0)}function O(J){if(!d(J))return null;if(J.readableEnded===!0)return!0;let _e=J._readableState;return!_e||_e.errored?!1:typeof(_e==null?void 0:_e.ended)!="boolean"?null:_e.ended}function C(J,_e){if(!d(J))return null;let ue=J._readableState;return ue!=null&&ue.errored?!1:typeof(ue==null?void 0:ue.endEmitted)!="boolean"?null:!!(ue.endEmitted||_e===!1&&ue.ended===!0&&ue.length===0)}function X(J){return J&&J[a]!=null?J[a]:typeof(J==null?void 0:J.readable)!="boolean"?null:D(J)?!1:d(J)&&J.readable&&!C(J)}function te(J){return J&&J[l]!=null?J[l]:typeof(J==null?void 0:J.writable)!="boolean"?null:D(J)?!1:f(J)&&J.writable&&!T(J)}function L(J,_e){return y(J)?D(J)?!0:!((_e==null?void 0:_e.readable)!==!1&&X(J)||(_e==null?void 0:_e.writable)!==!1&&te(J)):null}function Y(J){var _e,ue;return y(J)?J.writableErrored?J.writableErrored:(_e=(ue=J._writableState)===null||ue===void 0?void 0:ue.errored)!==null&&_e!==void 0?_e:null:null}function me(J){var _e,ue;return y(J)?J.readableErrored?J.readableErrored:(_e=(ue=J._readableState)===null||ue===void 0?void 0:ue.errored)!==null&&_e!==void 0?_e:null:null}function I(J){if(!y(J))return null;if(typeof J.closed=="boolean")return J.closed;let{_writableState:_e,_readableState:ue}=J;return typeof(_e==null?void 0:_e.closed)=="boolean"||typeof(ue==null?void 0:ue.closed)=="boolean"?(_e==null?void 0:_e.closed)||(ue==null?void 0:ue.closed):typeof J._closed=="boolean"&&Z(J)?J._closed:null}function Z(J){return typeof J._closed=="boolean"&&typeof J._defaultKeepAlive=="boolean"&&typeof J._removedConnection=="boolean"&&typeof J._removedContLen=="boolean"}function pe(J){return typeof J._sent100=="boolean"&&Z(J)}function de(J){var _e;return typeof J._consuming=="boolean"&&typeof J._dumped=="boolean"&&((_e=J.req)===null||_e===void 0?void 0:_e.upgradeOrConnect)===void 0}function je(J){if(!y(J))return null;let{_writableState:_e,_readableState:ue}=J,ce=_e||ue;return!ce&&pe(J)||!!(ce&&ce.autoDestroy&&ce.emitClose&&ce.closed===!1)}function be(J){var _e;return!!(J&&((_e=J[c])!==null&&_e!==void 0?_e:J.readableDidRead||J.readableAborted))}function Ie(J){var _e,ue,ce,Le,Ke,ct,lt,se,he,Ne;return!!(J&&((_e=(ue=(ce=(Le=(Ke=(ct=J[o])!==null&&ct!==void 0?ct:J.readableErrored)!==null&&Ke!==void 0?Ke:J.writableErrored)!==null&&Le!==void 0?Le:(lt=J._readableState)===null||lt===void 0?void 0:lt.errorEmitted)!==null&&ce!==void 0?ce:(se=J._writableState)===null||se===void 0?void 0:se.errorEmitted)!==null&&ue!==void 0?ue:(he=J._readableState)===null||he===void 0?void 0:he.errored)!==null&&_e!==void 0?_e:!((Ne=J._writableState)===null||Ne===void 0)&&Ne.errored))}t.exports={isDestroyed:D,kIsDestroyed:s,isDisturbed:be,kIsDisturbed:c,isErrored:Ie,kIsErrored:o,isReadable:X,kIsReadable:a,kIsClosedPromise:u,kControllerErrorFunction:p,kIsWritable:l,isClosed:I,isDuplexNodeStream:m,isFinished:L,isIterable:v,isReadableNodeStream:d,isReadableStream:h,isReadableEnded:O,isReadableFinished:C,isReadableErrored:me,isNodeStream:y,isWebStream:x,isWritable:te,isWritableNodeStream:f,isWritableStream:b,isWritableEnded:T,isWritableFinished:N,isWritableErrored:Y,isServerRequest:de,isServerResponse:pe,willEmitClose:je,isTransformStream:g}}),Dp=un((e,t)=>{var n=Tf(),{AbortError:r,codes:i}=ss(),{ERR_INVALID_ARG_TYPE:s,ERR_STREAM_PREMATURE_CLOSE:o}=i,{kEmptyObject:a,once:l}=qs(),{validateAbortSignal:c,validateFunction:u,validateObject:p,validateBoolean:d}=u_(),{Promise:f,PromisePrototypeThen:m,SymbolDispose:y}=or(),{isClosed:h,isReadable:b,isReadableNodeStream:g,isReadableStream:x,isReadableFinished:v,isReadableErrored:D,isWritable:T,isWritableNodeStream:N,isWritableStream:O,isWritableFinished:C,isWritableErrored:X,isNodeStream:te,willEmitClose:L,kIsClosedPromise:Y}=Bc(),me;function I(be){return be.setHeader&&typeof be.abort=="function"}var Z=()=>{};function pe(be,Ie,J){var _e,ue;if(arguments.length===2?(J=Ie,Ie=a):Ie==null?Ie=a:p(Ie,"options"),u(J,"callback"),c(Ie.signal,"options.signal"),J=l(J),x(be)||O(be))return de(be,Ie,J);if(!te(be))throw new s("stream",["ReadableStream","WritableStream","Stream"],be);let ce=(_e=Ie.readable)!==null&&_e!==void 0?_e:g(be),Le=(ue=Ie.writable)!==null&&ue!==void 0?ue:N(be),{_writableState:Ke,_readableState:ct}=be,lt=()=>{be.writable||Ne()},se=L(be)&&g(be)===ce&&N(be)===Le,he=C(be,!1),Ne=()=>{he=!0,be.destroyed&&(se=!1),!(se&&(!be.readable||ce))&&(!ce||Re)&&J.call(be)},Re=v(be,!1),Oe=()=>{Re=!0,be.destroyed&&(se=!1),!(se&&(!be.writable||Le))&&(!Le||he)&&J.call(be)},G=(W)=>{J.call(be,W)},V=h(be),j=()=>{V=!0;let W=X(be)||D(be);if(W&&typeof W!="boolean")return J.call(be,W);if(ce&&!Re&&g(be,!0)&&!v(be,!1))return J.call(be,new o);if(Le&&!he&&!C(be,!1))return J.call(be,new o);J.call(be)},H=()=>{V=!0;let W=X(be)||D(be);if(W&&typeof W!="boolean")return J.call(be,W);J.call(be)},ge=()=>{be.req.on("finish",Ne)};I(be)?(be.on("complete",Ne),se||be.on("abort",j),be.req?ge():be.on("request",ge)):Le&&!Ke&&(be.on("end",lt),be.on("close",lt)),!se&&typeof be.aborted=="boolean"&&be.on("aborted",j),be.on("end",Oe),be.on("finish",Ne),Ie.error!==!1&&be.on("error",G),be.on("close",j),V?n.nextTick(j):Ke!=null&&Ke.errorEmitted||ct!=null&&ct.errorEmitted?se||n.nextTick(H):(!ce&&(!se||b(be))&&(he||T(be)===!1)||!Le&&(!se||T(be))&&(Re||b(be)===!1)||ct&&be.req&&be.aborted)&&n.nextTick(H);let fe=()=>{J=Z,be.removeListener("aborted",j),be.removeListener("complete",Ne),be.removeListener("abort",j),be.removeListener("request",ge),be.req&&be.req.removeListener("finish",Ne),be.removeListener("end",lt),be.removeListener("close",lt),be.removeListener("finish",Ne),be.removeListener("end",Oe),be.removeListener("error",G),be.removeListener("close",j)};if(Ie.signal&&!V){let W=()=>{let ye=J;fe(),ye.call(be,new r(void 0,{cause:Ie.signal.reason}))};if(Ie.signal.aborted)n.nextTick(W);else{me=me||qs().addAbortListener;let ye=me(Ie.signal,W),Pe=J;J=l((...Se)=>{ye[y](),Pe.apply(be,Se)})}}return fe}function de(be,Ie,J){let _e=!1,ue=Z;if(Ie.signal)if(ue=()=>{_e=!0,J.call(be,new r(void 0,{cause:Ie.signal.reason}))},Ie.signal.aborted)n.nextTick(ue);else{me=me||qs().addAbortListener;let Le=me(Ie.signal,ue),Ke=J;J=l((...ct)=>{Le[y](),Ke.apply(be,ct)})}let ce=(...Le)=>{_e||n.nextTick(()=>J.apply(be,Le))};return m(be[Y].promise,ce,ce),Z}function je(be,Ie){var J;let _e=!1;return Ie===null&&(Ie=a),(J=Ie)!==null&&J!==void 0&&J.cleanup&&(d(Ie.cleanup,"cleanup"),_e=Ie.cleanup),new f((ue,ce)=>{let Le=pe(be,Ie,(Ke)=>{_e&&Le(),Ke?ce(Ke):ue()})})}t.exports=pe,t.exports.finished=je}),nh=un((e,t)=>{var n=Tf(),{aggregateTwoErrors:r,codes:{ERR_MULTIPLE_CALLBACK:i},AbortError:s}=ss(),{Symbol:o}=or(),{kIsDestroyed:a,isDestroyed:l,isFinished:c,isServerRequest:u}=Bc(),p=o("kDestroy"),d=o("kConstruct");function f(L,Y,me){L&&(L.stack,Y&&!Y.errored&&(Y.errored=L),me&&!me.errored&&(me.errored=L))}function m(L,Y){let me=this._readableState,I=this._writableState,Z=I||me;return I!=null&&I.destroyed||me!=null&&me.destroyed?(typeof Y=="function"&&Y(),this):(f(L,I,me),I&&(I.destroyed=!0),me&&(me.destroyed=!0),Z.constructed?y(this,L,Y):this.once(p,function(pe){y(this,r(pe,L),Y)}),this)}function y(L,Y,me){let I=!1;function Z(pe){if(I)return;I=!0;let{_readableState:de,_writableState:je}=L;f(pe,je,de),je&&(je.closed=!0),de&&(de.closed=!0),typeof me=="function"&&me(pe),pe?n.nextTick(h,L,pe):n.nextTick(b,L)}try{L._destroy(Y||null,Z)}catch(pe){Z(pe)}}function h(L,Y){g(L,Y),b(L)}function b(L){let{_readableState:Y,_writableState:me}=L;me&&(me.closeEmitted=!0),Y&&(Y.closeEmitted=!0),(me!=null&&me.emitClose||Y!=null&&Y.emitClose)&&L.emit("close")}function g(L,Y){let{_readableState:me,_writableState:I}=L;I!=null&&I.errorEmitted||me!=null&&me.errorEmitted||(I&&(I.errorEmitted=!0),me&&(me.errorEmitted=!0),L.emit("error",Y))}function x(){let L=this._readableState,Y=this._writableState;L&&(L.constructed=!0,L.closed=!1,L.closeEmitted=!1,L.destroyed=!1,L.errored=null,L.errorEmitted=!1,L.reading=!1,L.ended=L.readable===!1,L.endEmitted=L.readable===!1),Y&&(Y.constructed=!0,Y.destroyed=!1,Y.closed=!1,Y.closeEmitted=!1,Y.errored=null,Y.errorEmitted=!1,Y.finalCalled=!1,Y.prefinished=!1,Y.ended=Y.writable===!1,Y.ending=Y.writable===!1,Y.finished=Y.writable===!1)}function v(L,Y,me){let{_readableState:I,_writableState:Z}=L;if(Z!=null&&Z.destroyed||I!=null&&I.destroyed)return this;I!=null&&I.autoDestroy||Z!=null&&Z.autoDestroy?L.destroy(Y):Y&&(Y.stack,Z&&!Z.errored&&(Z.errored=Y),I&&!I.errored&&(I.errored=Y),me?n.nextTick(g,L,Y):g(L,Y))}function D(L,Y){if(typeof L._construct!="function")return;let{_readableState:me,_writableState:I}=L;me&&(me.constructed=!1),I&&(I.constructed=!1),L.once(d,Y),!(L.listenerCount(d)>1)&&n.nextTick(T,L)}function T(L){let Y=!1;function me(I){if(Y){v(L,I!=null?I:new i);return}Y=!0;let{_readableState:Z,_writableState:pe}=L,de=pe||Z;Z&&(Z.constructed=!0),pe&&(pe.constructed=!0),de.destroyed?L.emit(p,I):I?v(L,I,!0):n.nextTick(N,L)}try{L._construct((I)=>{n.nextTick(me,I)})}catch(I){n.nextTick(me,I)}}function N(L){L.emit(d)}function O(L){return(L==null?void 0:L.setHeader)&&typeof L.abort=="function"}function C(L){L.emit("close")}function X(L,Y){L.emit("error",Y),n.nextTick(C,L)}function te(L,Y){!L||l(L)||(!Y&&!c(L)&&(Y=new s),u(L)?(L.socket=null,L.destroy(Y)):O(L)?L.abort():O(L.req)?L.req.abort():typeof L.destroy=="function"?L.destroy(Y):typeof L.close=="function"?L.close():Y?n.nextTick(X,L,Y):n.nextTick(C,L),L.destroyed||(L[a]=!0))}t.exports={construct:D,destroyer:te,destroy:m,undestroy:x,errorOrDestroy:v}}),cC=un((e,t)=>{var{ArrayIsArray:n,ObjectSetPrototypeOf:r}=or(),{EventEmitter:i}=nE();function s(a){i.call(this,a)}r(s.prototype,i.prototype),r(s,i),s.prototype.pipe=function(a,l){let c=this;function u(b){a.writable&&a.write(b)===!1&&c.pause&&c.pause()}c.on("data",u);function p(){c.readable&&c.resume&&c.resume()}a.on("drain",p),!a._isStdio&&(!l||l.end!==!1)&&(c.on("end",f),c.on("close",m));let d=!1;function f(){d||(d=!0,a.end())}function m(){d||(d=!0,typeof a.destroy=="function"&&a.destroy())}function y(b){h(),i.listenerCount(this,"error")===0&&this.emit("error",b)}o(c,"error",y),o(a,"error",y);function h(){c.removeListener("data",u),a.removeListener("drain",p),c.removeListener("end",f),c.removeListener("close",m),c.removeListener("error",y),a.removeListener("error",y),c.removeListener("end",h),c.removeListener("close",h),a.removeListener("close",h)}return c.on("end",h),c.on("close",h),a.on("close",h),a.emit("pipe",c),a};function o(a,l,c){if(typeof a.prependListener=="function")return a.prependListener(l,c);!a._events||!a._events[l]?a.on(l,c):n(a._events[l])?a._events[l].unshift(c):a._events[l]=[c,a._events[l]]}t.exports={Stream:s,prependListener:o}}),rE=un((e,t)=>{var{SymbolDispose:n}=or(),{AbortError:r,codes:i}=ss(),{isNodeStream:s,isWebStream:o,kControllerErrorFunction:a}=Bc(),l=Dp(),{ERR_INVALID_ARG_TYPE:c}=i,u,p=(d,f)=>{if(typeof d!="object"||!("aborted"in d))throw new c(f,"AbortSignal",d)};t.exports.addAbortSignal=function(d,f){if(p(d,"signal"),!s(f)&&!o(f))throw new c("stream",["ReadableStream","WritableStream","Stream"],f);return t.exports.addAbortSignalNoValidate(d,f)},t.exports.addAbortSignalNoValidate=function(d,f){if(typeof d!="object"||!("aborted"in d))return f;let m=s(f)?()=>{f.destroy(new r(void 0,{cause:d.reason}))}:()=>{f[a](new r(void 0,{cause:d.reason}))};if(d.aborted)m();else{u=u||qs().addAbortListener;let y=u(d,m);l(f,y[n])}return f}}),lVe=un((e,t)=>{var{StringPrototypeSlice:n,SymbolIterator:r,TypedArrayPrototypeSet:i,Uint8Array:s}=or(),{Buffer:o}=Uc(),{inspect:a}=qs();t.exports=class{constructor(){this.head=null,this.tail=null,this.length=0}push(l){let c={data:l,next:null};this.length>0?this.tail.next=c:this.head=c,this.tail=c,++this.length}unshift(l){let c={data:l,next:this.head};this.length===0&&(this.tail=c),this.head=c,++this.length}shift(){if(this.length===0)return;let l=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,l}clear(){this.head=this.tail=null,this.length=0}join(l){if(this.length===0)return"";let c=this.head,u=""+c.data;for(;(c=c.next)!==null;)u+=l+c.data;return u}concat(l){if(this.length===0)return o.alloc(0);let c=o.allocUnsafe(l>>>0),u=this.head,p=0;for(;u;)i(c,u.data,p),p+=u.data.length,u=u.next;return c}consume(l,c){let u=this.head.data;if(ld.length)c+=d,l-=d.length;else{l===d.length?(c+=d,++p,u.next?this.head=u.next:this.head=this.tail=null):(c+=n(d,0,l),this.head=u,u.data=n(d,l));break}++p}while((u=u.next)!==null);return this.length-=p,c}_getBuffer(l){let c=o.allocUnsafe(l),u=l,p=this.head,d=0;do{let f=p.data;if(l>f.length)i(c,f,u-l),l-=f.length;else{l===f.length?(i(c,f,u-l),++d,p.next?this.head=p.next:this.head=this.tail=null):(i(c,new s(f.buffer,f.byteOffset,l),u-l),this.head=p,p.data=f.slice(l));break}++d}while((p=p.next)!==null);return this.length-=d,c}[Symbol.for("nodejs.util.inspect.custom")](l,c){return a(this,eE(Ls({},c),{depth:0,customInspect:!1}))}}}),iE=un((e,t)=>{var{MathFloor:n,NumberIsInteger:r}=or(),{validateInteger:i}=u_(),{ERR_INVALID_ARG_VALUE:s}=ss().codes,o=16384,a=16;function l(d,f,m){return d.highWaterMark!=null?d.highWaterMark:f?d[m]:null}function c(d){return d?a:o}function u(d,f){i(f,"value",0),d?a=f:o=f}function p(d,f,m,y){let h=l(f,y,m);if(h!=null){if(!r(h)||h<0){let b=y?`options.${m}`:"options.highWaterMark";throw new s(b,h)}return n(h)}return c(d.objectMode)}t.exports={getHighWaterMark:p,getDefaultHighWaterMark:c,setDefaultHighWaterMark:u}}),cVe=un((e,t)=>{var n=Uc(),r=n.Buffer;function i(o,a){for(var l in o)a[l]=o[l]}r.from&&r.alloc&&r.allocUnsafe&&r.allocUnsafeSlow?t.exports=n:(i(n,e),e.Buffer=s);function s(o,a,l){return r(o,a,l)}s.prototype=Object.create(r.prototype),i(r,s),s.from=function(o,a,l){if(typeof o=="number")throw TypeError("Argument must not be a number");return r(o,a,l)},s.alloc=function(o,a,l){if(typeof o!="number")throw TypeError("Argument must be a number");var c=r(o);return a!==void 0?typeof l=="string"?c.fill(a,l):c.fill(a):c.fill(0),c},s.allocUnsafe=function(o){if(typeof o!="number")throw TypeError("Argument must be a number");return r(o)},s.allocUnsafeSlow=function(o){if(typeof o!="number")throw TypeError("Argument must be a number");return n.SlowBuffer(o)}}),uVe=un((e)=>{var t=cVe().Buffer,n=t.isEncoding||function(g){switch(g=""+g,g&&g.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function r(g){if(!g)return"utf8";for(var x;;)switch(g){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return g;default:if(x)return;g=(""+g).toLowerCase(),x=!0}}function i(g){var x=r(g);if(typeof x!="string"&&(t.isEncoding===n||!n(g)))throw Error("Unknown encoding: "+g);return x||g}e.StringDecoder=s;function s(g){this.encoding=i(g);var x;switch(this.encoding){case"utf16le":this.text=d,this.end=f,x=4;break;case"utf8":this.fillLast=c,x=4;break;case"base64":this.text=m,this.end=y,x=3;break;default:this.write=h,this.end=b;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=t.allocUnsafe(x)}s.prototype.write=function(g){if(g.length===0)return"";var x,v;if(this.lastNeed){if(x=this.fillLast(g),x===void 0)return"";v=this.lastNeed,this.lastNeed=0}else v=0;return v>5===6?2:g>>4===14?3:g>>3===30?4:g>>6===2?-1:-2}function a(g,x,v){var D=x.length-1;if(D=0?(T>0&&(g.lastNeed=T-1),T):--D=0?(T>0&&(g.lastNeed=T-2),T):--D=0?(T>0&&(T===2?T=0:g.lastNeed=T-3),T):0))}function l(g,x,v){if((x[0]&192)!==128)return g.lastNeed=0,"�";if(g.lastNeed>1&&x.length>1){if((x[1]&192)!==128)return g.lastNeed=1,"�";if(g.lastNeed>2&&x.length>2&&(x[2]&192)!==128)return g.lastNeed=2,"�"}}function c(g){var x=this.lastTotal-this.lastNeed,v=l(this,g,x);if(v!==void 0)return v;if(this.lastNeed<=g.length)return g.copy(this.lastChar,x,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);g.copy(this.lastChar,x,0,g.length),this.lastNeed-=g.length}function u(g,x){var v=a(this,g,x);if(!this.lastNeed)return g.toString("utf8",x);this.lastTotal=v;var D=g.length-(v-this.lastNeed);return g.copy(this.lastChar,0,D),g.toString("utf8",x,D)}function p(g){var x=g&&g.length?this.write(g):"";return this.lastNeed?x+"�":x}function d(g,x){if((g.length-x)%2===0){var v=g.toString("utf16le",x);if(v){var D=v.charCodeAt(v.length-1);if(D>=55296&&D<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=g[g.length-2],this.lastChar[1]=g[g.length-1],v.slice(0,-1)}return v}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=g[g.length-1],g.toString("utf16le",x,g.length-1)}function f(g){var x=g&&g.length?this.write(g):"";if(this.lastNeed){var v=this.lastTotal-this.lastNeed;return x+this.lastChar.toString("utf16le",0,v)}return x}function m(g,x){var v=(g.length-x)%3;return v===0?g.toString("base64",x):(this.lastNeed=3-v,this.lastTotal=3,v===1?this.lastChar[0]=g[g.length-1]:(this.lastChar[0]=g[g.length-2],this.lastChar[1]=g[g.length-1]),g.toString("base64",x,g.length-v))}function y(g){var x=g&&g.length?this.write(g):"";return this.lastNeed?x+this.lastChar.toString("base64",0,3-this.lastNeed):x}function h(g){return g.toString(this.encoding)}function b(g){return g&&g.length?this.write(g):""}}),Nae=un((e,t)=>{var n=Tf(),{PromisePrototypeThen:r,SymbolAsyncIterator:i,SymbolIterator:s}=or(),{Buffer:o}=Uc(),{ERR_INVALID_ARG_TYPE:a,ERR_STREAM_NULL_VALUES:l}=ss().codes;function c(u,p,d){let f;if(typeof p=="string"||p instanceof o)return new u(eE(Ls({objectMode:!0},d),{read(){this.push(p),this.push(null)}}));let m;if(p&&p[i])m=!0,f=p[i]();else if(p&&p[s])m=!1,f=p[s]();else throw new a("iterable",["Iterable"],p);let y=new u(Ls({objectMode:!0,highWaterMark:1},d)),h=!1;y._read=function(){h||(h=!0,g())},y._destroy=function(x,v){r(b(x),()=>n.nextTick(v,x),(D)=>n.nextTick(v,D||x))};async function b(x){let v=x!=null,D=typeof f.throw=="function";if(v&&D){let{value:T,done:N}=await f.throw(x);if(await T,N)return}if(typeof f.return=="function"){let{value:T}=await f.return();await T}}async function g(){for(;;){try{let{value:x,done:v}=m?await f.next():f.next();if(v)y.push(null);else{let D=x&&typeof x.then=="function"?await x:x;if(D===null)throw h=!1,new l;if(y.push(D))continue;h=!1}}catch(x){y.destroy(x)}break}}return y}t.exports=c}),sE=un((e,t)=>{var n=Tf(),{ArrayPrototypeIndexOf:r,NumberIsInteger:i,NumberIsNaN:s,NumberParseInt:o,ObjectDefineProperties:a,ObjectKeys:l,ObjectSetPrototypeOf:c,Promise:u,SafeSet:p,SymbolAsyncDispose:d,SymbolAsyncIterator:f,Symbol:m}=or();t.exports=Se,Se.ReadableState=Pe;var{EventEmitter:y}=nE(),{Stream:h,prependListener:b}=cC(),{Buffer:g}=Uc(),{addAbortSignal:x}=rE(),v=Dp(),D=qs().debuglog("stream",(R)=>{D=R}),T=lVe(),N=nh(),{getHighWaterMark:O,getDefaultHighWaterMark:C}=iE(),{aggregateTwoErrors:X,codes:{ERR_INVALID_ARG_TYPE:te,ERR_METHOD_NOT_IMPLEMENTED:L,ERR_OUT_OF_RANGE:Y,ERR_STREAM_PUSH_AFTER_EOF:me,ERR_STREAM_UNSHIFT_AFTER_END_EVENT:I},AbortError:Z}=ss(),{validateObject:pe}=u_(),de=m("kPaused"),{StringDecoder:je}=uVe(),be=Nae();c(Se.prototype,h.prototype),c(Se,h);var Ie=()=>{},{errorOrDestroy:J}=N,_e=1,ue=2,ce=4,Le=8,Ke=16,ct=32,lt=64,se=128,he=256,Ne=512,Re=1024,Oe=2048,G=4096,V=8192,j=16384,H=32768,ge=65536,fe=131072,W=262144;function ye(R){return{enumerable:!1,get(){return(this.state&R)!==0},set(K){K?this.state|=R:this.state&=~R}}}a(Pe.prototype,{objectMode:ye(_e),ended:ye(ue),endEmitted:ye(ce),reading:ye(Le),constructed:ye(Ke),sync:ye(ct),needReadable:ye(lt),emittedReadable:ye(se),readableListening:ye(he),resumeScheduled:ye(Ne),errorEmitted:ye(Re),emitClose:ye(Oe),autoDestroy:ye(G),destroyed:ye(V),closed:ye(j),closeEmitted:ye(H),multiAwaitDrain:ye(ge),readingMore:ye(fe),dataEmitted:ye(W)});function Pe(R,K,Fe){typeof Fe!="boolean"&&(Fe=K instanceof qc()),this.state=Oe|G|Ke|ct,R&&R.objectMode&&(this.state|=_e),Fe&&R&&R.readableObjectMode&&(this.state|=_e),this.highWaterMark=R?O(this,R,"readableHighWaterMark",Fe):C(!1),this.buffer=new T,this.length=0,this.pipes=[],this.flowing=null,this[de]=null,R&&R.emitClose===!1&&(this.state&=~Oe),R&&R.autoDestroy===!1&&(this.state&=~G),this.errored=null,this.defaultEncoding=R&&R.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.decoder=null,this.encoding=null,R&&R.encoding&&(this.decoder=new je(R.encoding),this.encoding=R.encoding)}function Se(R){if(!(this instanceof Se))return new Se(R);let K=this instanceof qc();this._readableState=new Pe(R,this,K),R&&(typeof R.read=="function"&&(this._read=R.read),typeof R.destroy=="function"&&(this._destroy=R.destroy),typeof R.construct=="function"&&(this._construct=R.construct),R.signal&&!K&&x(R.signal,this)),h.call(this,R),N.construct(this,()=>{this._readableState.needReadable&&le(this,this._readableState)})}Se.prototype.destroy=N.destroy,Se.prototype._undestroy=N.undestroy,Se.prototype._destroy=function(R,K){K(R)},Se.prototype[y.captureRejectionSymbol]=function(R){this.destroy(R)},Se.prototype[d]=function(){let R;return this.destroyed||(R=this.readableEnded?null:new Z,this.destroy(R)),new u((K,Fe)=>v(this,(Ge)=>Ge&&Ge!==R?Fe(Ge):K(null)))},Se.prototype.push=function(R,K){return Ce(this,R,K,!1)},Se.prototype.unshift=function(R,K){return Ce(this,R,K,!0)};function Ce(R,K,Fe,Ge){D("readableAddChunk",K);let tt=R._readableState,Ar;if((tt.state&_e)===0&&(typeof K=="string"?(Fe=Fe||tt.defaultEncoding,tt.encoding!==Fe&&(Ge&&tt.encoding?K=g.from(K,Fe).toString(tt.encoding):(K=g.from(K,Fe),Fe=""))):K instanceof g?Fe="":h._isUint8Array(K)?(K=h._uint8ArrayToBuffer(K),Fe=""):K!=null&&(Ar=new te("chunk",["string","Buffer","Uint8Array"],K))),Ar)J(R,Ar);else if(K===null)tt.state&=~Le,E(R,tt);else if((tt.state&_e)!==0||K&&K.length>0)if(Ge)if((tt.state&ce)!==0)J(R,new I);else{if(tt.destroyed||tt.errored)return!1;Bt(R,tt,K,!0)}else if(tt.ended)J(R,new me);else{if(tt.destroyed||tt.errored)return!1;tt.state&=~Le,tt.decoder&&!Fe?(K=tt.decoder.write(K),tt.objectMode||K.length!==0?Bt(R,tt,K,!1):le(R,tt)):Bt(R,tt,K,!1)}else Ge||(tt.state&=~Le,le(R,tt));return!tt.ended&&(tt.length0?((K.state&ge)!==0?K.awaitDrainWriters.clear():K.awaitDrainWriters=null,K.dataEmitted=!0,R.emit("data",Fe)):(K.length+=K.objectMode?1:Fe.length,Ge?K.buffer.unshift(Fe):K.buffer.push(Fe),(K.state<)!==0&&A(R)),le(R,K)}Se.prototype.isPaused=function(){let R=this._readableState;return R[de]===!0||R.flowing===!1},Se.prototype.setEncoding=function(R){let K=new je(R);this._readableState.decoder=K,this._readableState.encoding=this._readableState.decoder.encoding;let Fe=this._readableState.buffer,Ge="";for(let tt of Fe)Ge+=K.write(tt);return Fe.clear(),Ge!==""&&Fe.push(Ge),this._readableState.length=Ge.length,this};var _=1073741824;function S(R){if(R>_)throw new Y("size","<= 1GiB",R);return R--,R|=R>>>1,R|=R>>>2,R|=R>>>4,R|=R>>>8,R|=R>>>16,R++,R}function k(R,K){return R<=0||K.length===0&&K.ended?0:(K.state&_e)!==0?1:s(R)?K.flowing&&K.length?K.buffer.first().length:K.length:R<=K.length?R:K.ended?K.length:0}Se.prototype.read=function(R){D("read",R),R===void 0?R=NaN:i(R)||(R=o(R,10));let K=this._readableState,Fe=R;if(R>K.highWaterMark&&(K.highWaterMark=S(R)),R!==0&&(K.state&=~se),R===0&&K.needReadable&&((K.highWaterMark!==0?K.length>=K.highWaterMark:K.length>0)||K.ended))return D("read: emitReadable",K.length,K.ended),K.length===0&&K.ended?Bs(this):A(this),null;if(R=k(R,K),R===0&&K.ended)return K.length===0&&Bs(this),null;let Ge=(K.state<)!==0;if(D("need readable",Ge),(K.length===0||K.length-R0?tt=qa(R,K):tt=null,tt===null?(K.needReadable=K.length<=K.highWaterMark,R=0):(K.length-=R,K.multiAwaitDrain?K.awaitDrainWriters.clear():K.awaitDrainWriters=null),K.length===0&&(K.ended||(K.needReadable=!0),Fe!==R&&K.ended&&Bs(this)),tt!==null&&!K.errorEmitted&&!K.closeEmitted&&(K.dataEmitted=!0,this.emit("data",tt)),tt};function E(R,K){if(D("onEofChunk"),!K.ended){if(K.decoder){let Fe=K.decoder.end();Fe&&Fe.length&&(K.buffer.push(Fe),K.length+=K.objectMode?1:Fe.length)}K.ended=!0,K.sync?A(R):(K.needReadable=!1,K.emittedReadable=!0,Q(R))}}function A(R){let K=R._readableState;D("emitReadable",K.needReadable,K.emittedReadable),K.needReadable=!1,K.emittedReadable||(D("emitReadable",K.flowing),K.emittedReadable=!0,n.nextTick(Q,R))}function Q(R){let K=R._readableState;D("emitReadable_",K.destroyed,K.length,K.ended),!K.destroyed&&!K.errored&&(K.length||K.ended)&&(R.emit("readable"),K.emittedReadable=!1),K.needReadable=!K.flowing&&!K.ended&&K.length<=K.highWaterMark,Rn(R)}function le(R,K){!K.readingMore&&K.constructed&&(K.readingMore=!0,n.nextTick(Je,R,K))}function Je(R,K){for(;!K.reading&&!K.ended&&(K.length1&&Ge.pipes.includes(R)&&(D("false write response, pause",Ge.awaitDrainWriters.size),Ge.awaitDrainWriters.add(R)),Fe.pause()),wn||(wn=Et(Fe,R),R.on("drain",wn))}Fe.on("data",__);function __(Al){D("ondata");let po=R.write(Al);D("dest.write",po),po===!1&&v_()}function uh(Al){if(D("onerror",Al),Np(),R.removeListener("error",uh),R.listenerCount("error")===0){let po=R._writableState||R._readableState;po&&!po.errorEmitted?J(R,Al):R.emit("error",Al)}}b(R,"error",uh);function zc(){R.removeListener("finish",ph),Np()}R.once("close",zc);function ph(){D("onfinish"),R.removeListener("close",zc),Np()}R.once("finish",ph);function Np(){D("unpipe"),Fe.unpipe(R)}return R.emit("pipe",Fe),R.writableNeedDrain===!0?v_():Ge.flowing||(D("pipe resume"),Fe.resume()),R};function Et(R,K){return function(){let Fe=R._readableState;Fe.awaitDrainWriters===K?(D("pipeOnDrain",1),Fe.awaitDrainWriters=null):Fe.multiAwaitDrain&&(D("pipeOnDrain",Fe.awaitDrainWriters.size),Fe.awaitDrainWriters.delete(K)),(!Fe.awaitDrainWriters||Fe.awaitDrainWriters.size===0)&&R.listenerCount("data")&&R.resume()}}Se.prototype.unpipe=function(R){let K=this._readableState,Fe={hasUnpiped:!1};if(K.pipes.length===0)return this;if(!R){let tt=K.pipes;K.pipes=[],this.pause();for(let Ar=0;Ar0,Ge.flowing!==!1&&this.resume()):R==="readable"&&!Ge.endEmitted&&!Ge.readableListening&&(Ge.readableListening=Ge.needReadable=!0,Ge.flowing=!1,Ge.emittedReadable=!1,D("on readable",Ge.length,Ge.reading),Ge.length?A(this):Ge.reading||n.nextTick(wt,this)),Fe},Se.prototype.addListener=Se.prototype.on,Se.prototype.removeListener=function(R,K){let Fe=h.prototype.removeListener.call(this,R,K);return R==="readable"&&n.nextTick(ut,this),Fe},Se.prototype.off=Se.prototype.removeListener,Se.prototype.removeAllListeners=function(R){let K=h.prototype.removeAllListeners.apply(this,arguments);return(R==="readable"||R===void 0)&&n.nextTick(ut,this),K};function ut(R){let K=R._readableState;K.readableListening=R.listenerCount("readable")>0,K.resumeScheduled&&K[de]===!1?K.flowing=!0:R.listenerCount("data")>0?R.resume():K.readableListening||(K.flowing=null)}function wt(R){D("readable nexttick read 0"),R.read(0)}Se.prototype.resume=function(){let R=this._readableState;return R.flowing||(D("resume"),R.flowing=!R.readableListening,At(this,R)),R[de]=!1,this};function At(R,K){K.resumeScheduled||(K.resumeScheduled=!0,n.nextTick(Ln,R,K))}function Ln(R,K){D("resume",K.reading),K.reading||R.read(0),K.resumeScheduled=!1,R.emit("resume"),Rn(R),K.flowing&&!K.reading&&R.read(0)}Se.prototype.pause=function(){return D("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(D("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState[de]=!0,this};function Rn(R){let K=R._readableState;for(D("flow",K.flowing);K.flowing&&R.read()!==null;);}Se.prototype.wrap=function(R){let K=!1;R.on("data",(Ge)=>{!this.push(Ge)&&R.pause&&(K=!0,R.pause())}),R.on("end",()=>{this.push(null)}),R.on("error",(Ge)=>{J(this,Ge)}),R.on("close",()=>{this.destroy()}),R.on("destroy",()=>{this.destroy()}),this._read=()=>{K&&R.resume&&(K=!1,R.resume())};let Fe=l(R);for(let Ge=1;Ge{tt=Bi?X(tt,Bi):null,Fe(),Fe=Ie});try{for(;;){let Bi=R.destroyed?null:R.read();if(Bi!==null)yield Bi;else{if(tt)throw tt;if(tt===null)return;yield new Ms(new u(Ge))}}}catch(Bi){throw tt=X(tt,Bi),tt}finally{(tt||(K==null?void 0:K.destroyOnReturn)!==!1)&&(tt===void 0||R._readableState.autoDestroy)?N.destroyer(R,null):(R.off("readable",Ge),Ar())}})}a(Se.prototype,{readable:{__proto__:null,get(){let R=this._readableState;return!!R&&R.readable!==!1&&!R.destroyed&&!R.errorEmitted&&!R.endEmitted},set(R){this._readableState&&(this._readableState.readable=!!R)}},readableDidRead:{__proto__:null,enumerable:!1,get:function(){return this._readableState.dataEmitted}},readableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._readableState.readable!==!1&&(this._readableState.destroyed||this._readableState.errored)&&!this._readableState.endEmitted)}},readableHighWaterMark:{__proto__:null,enumerable:!1,get:function(){return this._readableState.highWaterMark}},readableBuffer:{__proto__:null,enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}},readableFlowing:{__proto__:null,enumerable:!1,get:function(){return this._readableState.flowing},set:function(R){this._readableState&&(this._readableState.flowing=R)}},readableLength:{__proto__:null,enumerable:!1,get(){return this._readableState.length}},readableObjectMode:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.objectMode:!1}},readableEncoding:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.encoding:null}},errored:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.errored:null}},closed:{__proto__:null,get(){return this._readableState?this._readableState.closed:!1}},destroyed:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.destroyed:!1},set(R){this._readableState&&(this._readableState.destroyed=R)}},readableEnded:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.endEmitted:!1}}}),a(Pe.prototype,{pipesCount:{__proto__:null,get(){return this.pipes.length}},paused:{__proto__:null,get(){return this[de]!==!1},set(R){this[de]=!!R}}}),Se._fromList=qa;function qa(R,K){if(K.length===0)return null;let Fe;return K.objectMode?Fe=K.buffer.shift():!R||R>=K.length?(K.decoder?Fe=K.buffer.join(""):K.buffer.length===1?Fe=K.buffer.first():Fe=K.buffer.concat(K.length),K.buffer.clear()):Fe=K.buffer.consume(R,K.decoder),Fe}function Bs(R){let K=R._readableState;D("endReadable",K.endEmitted),K.endEmitted||(K.ended=!0,n.nextTick(ls,K,R))}function ls(R,K){if(D("endReadableNT",R.endEmitted,R.length),!R.errored&&!R.closeEmitted&&!R.endEmitted&&R.length===0){if(R.endEmitted=!0,K.emit("end"),K.writable&&K.allowHalfOpen===!1)n.nextTick(ah,K);else if(R.autoDestroy){let Fe=K._writableState;(!Fe||Fe.autoDestroy&&(Fe.finished||Fe.writable===!1))&&K.destroy()}}}function ah(R){R.writable&&!R.writableEnded&&!R.destroyed&&R.end()}Se.from=function(R,K){return be(Se,R,K)};var Hc;function lh(){return Hc===void 0&&(Hc={}),Hc}Se.fromWeb=function(R,K){return lh().newStreamReadableFromReadableStream(R,K)},Se.toWeb=function(R,K){return lh().newReadableStreamFromStreamReadable(R,K)},Se.wrap=function(R,K){var Fe,Ge;return new Se(eE(Ls({objectMode:(Fe=(Ge=R.readableObjectMode)!==null&&Ge!==void 0?Ge:R.objectMode)!==null&&Fe!==void 0?Fe:!0},K),{destroy(tt,Ar){N.destroyer(R,tt),Ar(tt)}})).wrap(R)}}),uC=un((e,t)=>{var n=Tf(),{ArrayPrototypeSlice:r,Error:i,FunctionPrototypeSymbolHasInstance:s,ObjectDefineProperty:o,ObjectDefineProperties:a,ObjectSetPrototypeOf:l,StringPrototypeToLowerCase:c,Symbol:u,SymbolHasInstance:p}=or();t.exports=pe,pe.WritableState=I;var{EventEmitter:d}=nE(),f=cC().Stream,{Buffer:m}=Uc(),y=nh(),{addAbortSignal:h}=rE(),{getHighWaterMark:b,getDefaultHighWaterMark:g}=iE(),{ERR_INVALID_ARG_TYPE:x,ERR_METHOD_NOT_IMPLEMENTED:v,ERR_MULTIPLE_CALLBACK:D,ERR_STREAM_CANNOT_PIPE:T,ERR_STREAM_DESTROYED:N,ERR_STREAM_ALREADY_FINISHED:O,ERR_STREAM_NULL_VALUES:C,ERR_STREAM_WRITE_AFTER_END:X,ERR_UNKNOWN_ENCODING:te}=ss().codes,{errorOrDestroy:L}=y;l(pe.prototype,f.prototype),l(pe,f);function Y(){}var me=u("kOnFinished");function I(G,V,j){typeof j!="boolean"&&(j=V instanceof qc()),this.objectMode=!!(G&&G.objectMode),j&&(this.objectMode=this.objectMode||!!(G&&G.writableObjectMode)),this.highWaterMark=G?b(this,G,"writableHighWaterMark",j):g(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;let H=!!(G&&G.decodeStrings===!1);this.decodeStrings=!H,this.defaultEncoding=G&&G.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=J.bind(void 0,V),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,Z(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!G||G.emitClose!==!1,this.autoDestroy=!G||G.autoDestroy!==!1,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[me]=[]}function Z(G){G.buffered=[],G.bufferedIndex=0,G.allBuffers=!0,G.allNoop=!0}I.prototype.getBuffer=function(){return r(this.buffered,this.bufferedIndex)},o(I.prototype,"bufferedRequestCount",{__proto__:null,get(){return this.buffered.length-this.bufferedIndex}});function pe(G){let V=this instanceof qc();if(!V&&!s(pe,this))return new pe(G);this._writableState=new I(G,this,V),G&&(typeof G.write=="function"&&(this._write=G.write),typeof G.writev=="function"&&(this._writev=G.writev),typeof G.destroy=="function"&&(this._destroy=G.destroy),typeof G.final=="function"&&(this._final=G.final),typeof G.construct=="function"&&(this._construct=G.construct),G.signal&&h(G.signal,this)),f.call(this,G),y.construct(this,()=>{let j=this._writableState;j.writing||Le(this,j),se(this,j)})}o(pe,p,{__proto__:null,value:function(G){return s(this,G)?!0:this!==pe?!1:G&&G._writableState instanceof I}}),pe.prototype.pipe=function(){L(this,new T)};function de(G,V,j,H){let ge=G._writableState;if(typeof j=="function")H=j,j=ge.defaultEncoding;else{if(!j)j=ge.defaultEncoding;else if(j!=="buffer"&&!m.isEncoding(j))throw new te(j);typeof H!="function"&&(H=Y)}if(V===null)throw new C;if(!ge.objectMode)if(typeof V=="string")ge.decodeStrings!==!1&&(V=m.from(V,j),j="buffer");else if(V instanceof m)j="buffer";else if(f._isUint8Array(V))V=f._uint8ArrayToBuffer(V),j="buffer";else throw new x("chunk",["string","Buffer","Uint8Array"],V);let fe;return ge.ending?fe=new X:ge.destroyed&&(fe=new N("write")),fe?(n.nextTick(H,fe),L(G,fe,!0),fe):(ge.pendingcb++,je(G,ge,V,j,H))}pe.prototype.write=function(G,V,j){return de(this,G,V,j)===!0},pe.prototype.cork=function(){this._writableState.corked++},pe.prototype.uncork=function(){let G=this._writableState;G.corked&&(G.corked--,G.writing||Le(this,G))},pe.prototype.setDefaultEncoding=function(G){if(typeof G=="string"&&(G=c(G)),!m.isEncoding(G))throw new te(G);return this._writableState.defaultEncoding=G,this};function je(G,V,j,H,ge){let fe=V.objectMode?1:j.length;V.length+=fe;let W=V.lengthj.bufferedIndex&&Le(G,j),H?j.afterWriteTickInfo!==null&&j.afterWriteTickInfo.cb===ge?j.afterWriteTickInfo.count++:(j.afterWriteTickInfo={count:1,cb:ge,stream:G,state:j},n.nextTick(_e,j.afterWriteTickInfo)):ue(G,j,1,ge))}function _e({stream:G,state:V,count:j,cb:H}){return V.afterWriteTickInfo=null,ue(G,V,j,H)}function ue(G,V,j,H){for(!V.ending&&!G.destroyed&&V.length===0&&V.needDrain&&(V.needDrain=!1,G.emit("drain"));j-- >0;)V.pendingcb--,H();V.destroyed&&ce(V),se(G,V)}function ce(G){if(G.writing)return;for(let ge=G.bufferedIndex;ge1&&G._writev){V.pendingcb-=fe-1;let ye=V.allNoop?Y:(Se)=>{for(let Ce=W;Ce256?(j.splice(0,W),V.bufferedIndex=0):V.bufferedIndex=W}V.bufferProcessing=!1}pe.prototype._write=function(G,V,j){if(this._writev)this._writev([{chunk:G,encoding:V}],j);else throw new v("_write()")},pe.prototype._writev=null,pe.prototype.end=function(G,V,j){let H=this._writableState;typeof G=="function"?(j=G,G=null,V=null):typeof V=="function"&&(j=V,V=null);let ge;if(G!=null){let fe=de(this,G,V);fe instanceof i&&(ge=fe)}return H.corked&&(H.corked=1,this.uncork()),ge||(!H.errored&&!H.ending?(H.ending=!0,se(this,H,!0),H.ended=!0):H.finished?ge=new O("end"):H.destroyed&&(ge=new N("end"))),typeof j=="function"&&(ge||H.finished?n.nextTick(j,ge):H[me].push(j)),this};function Ke(G){return G.ending&&!G.destroyed&&G.constructed&&G.length===0&&!G.errored&&G.buffered.length===0&&!G.finished&&!G.writing&&!G.errorEmitted&&!G.closeEmitted}function ct(G,V){let j=!1;function H(ge){if(j){L(G,ge!=null?ge:D());return}if(j=!0,V.pendingcb--,ge){let fe=V[me].splice(0);for(let W=0;W{Ke(ge)?he(H,ge):ge.pendingcb--},G,V)):Ke(V)&&(V.pendingcb++,he(G,V))))}function he(G,V){V.pendingcb--,V.finished=!0;let j=V[me].splice(0);for(let H=0;H{var n=Tf(),r=Uc(),{isReadable:i,isWritable:s,isIterable:o,isNodeStream:a,isReadableNodeStream:l,isWritableNodeStream:c,isDuplexNodeStream:u,isReadableStream:p,isWritableStream:d}=Bc(),f=Dp(),{AbortError:m,codes:{ERR_INVALID_ARG_TYPE:y,ERR_INVALID_RETURN_VALUE:h}}=ss(),{destroyer:b}=nh(),g=qc(),x=sE(),v=uC(),{createDeferredPromise:D}=qs(),T=Nae(),N=globalThis.Blob||r.Blob,O=typeof N<"u"?function(me){return me instanceof N}:function(me){return!1},C=globalThis.AbortController||c_().AbortController,{FunctionPrototypeCall:X}=or(),te=class extends g{constructor(me){super(me),(me==null?void 0:me.readable)===!1&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),(me==null?void 0:me.writable)===!1&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)}};t.exports=function me(I,Z){if(u(I))return I;if(l(I))return Y({readable:I});if(c(I))return Y({writable:I});if(a(I))return Y({writable:!1,readable:!1});if(p(I))return Y({readable:x.fromWeb(I)});if(d(I))return Y({writable:v.fromWeb(I)});if(typeof I=="function"){let{value:de,write:je,final:be,destroy:Ie}=L(I);if(o(de))return T(te,de,{objectMode:!0,write:je,final:be,destroy:Ie});let J=de==null?void 0:de.then;if(typeof J=="function"){let _e,ue=X(J,de,(ce)=>{if(ce!=null)throw new h("nully","body",ce)},(ce)=>{b(_e,ce)});return _e=new te({objectMode:!0,readable:!1,write:je,final(ce){be(async()=>{try{await ue,n.nextTick(ce,null)}catch(Le){n.nextTick(ce,Le)}})},destroy:Ie})}throw new h("Iterable, AsyncIterable or AsyncFunction",Z,de)}if(O(I))return me(I.arrayBuffer());if(o(I))return T(te,I,{objectMode:!0,writable:!1});if(p(I==null?void 0:I.readable)&&d(I==null?void 0:I.writable))return te.fromWeb(I);if(typeof(I==null?void 0:I.writable)=="object"||typeof(I==null?void 0:I.readable)=="object"){let de=I!=null&&I.readable?l(I==null?void 0:I.readable)?I==null?void 0:I.readable:me(I.readable):void 0,je=I!=null&&I.writable?c(I==null?void 0:I.writable)?I==null?void 0:I.writable:me(I.writable):void 0;return Y({readable:de,writable:je})}let pe=I==null?void 0:I.then;if(typeof pe=="function"){let de;return X(pe,I,(je)=>{je!=null&&de.push(je),de.push(null)},(je)=>{b(de,je)}),de=new te({objectMode:!0,writable:!1,read(){}})}throw new y(Z,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],I)};function L(me){let{promise:I,resolve:Z}=D(),pe=new C,de=pe.signal;return{value:me(function(){return wp(this,null,function*(){for(;;){let je=I;I=null;let{chunk:be,done:Ie,cb:J}=yield new Ms(je);if(n.nextTick(J),Ie)return;if(de.aborted)throw new m(void 0,{cause:de.reason});({promise:I,resolve:Z}=D()),yield be}})}(),{signal:de}),write(je,be,Ie){let J=Z;Z=null,J({chunk:je,done:!1,cb:Ie})},final(je){let be=Z;Z=null,be({done:!0,cb:je})},destroy(je,be){pe.abort(),be(je)}}}function Y(me){let I=me.readable&&typeof me.readable.read!="function"?x.wrap(me.readable):me.readable,Z=me.writable,pe=!!i(I),de=!!s(Z),je,be,Ie,J,_e;function ue(ce){let Le=J;J=null,Le?Le(ce):ce&&_e.destroy(ce)}return _e=new te({readableObjectMode:!!(I!=null&&I.readableObjectMode),writableObjectMode:!!(Z!=null&&Z.writableObjectMode),readable:pe,writable:de}),de&&(f(Z,(ce)=>{de=!1,ce&&b(I,ce),ue(ce)}),_e._write=function(ce,Le,Ke){Z.write(ce,Le)?Ke():je=Ke},_e._final=function(ce){Z.end(),be=ce},Z.on("drain",function(){if(je){let ce=je;je=null,ce()}}),Z.on("finish",function(){if(be){let ce=be;be=null,ce()}})),pe&&(f(I,(ce)=>{pe=!1,ce&&b(I,ce),ue(ce)}),I.on("readable",function(){if(Ie){let ce=Ie;Ie=null,ce()}}),I.on("end",function(){_e.push(null)}),_e._read=function(){for(;;){let ce=I.read();if(ce===null){Ie=_e._read;return}if(!_e.push(ce))return}}),_e._destroy=function(ce,Le){!ce&&J!==null&&(ce=new m),Ie=null,je=null,be=null,J===null?Le(ce):(J=Le,b(Z,ce),b(I,ce))},_e}}),qc=un((e,t)=>{var{ObjectDefineProperties:n,ObjectGetOwnPropertyDescriptor:r,ObjectKeys:i,ObjectSetPrototypeOf:s}=or();t.exports=l;var o=sE(),a=uC();s(l.prototype,o.prototype),s(l,o);{let d=i(a.prototype);for(let f=0;f{var{ObjectSetPrototypeOf:n,Symbol:r}=or();t.exports=l;var{ERR_METHOD_NOT_IMPLEMENTED:i}=ss().codes,s=qc(),{getHighWaterMark:o}=iE();n(l.prototype,s.prototype),n(l,s);var a=r("kCallback");function l(p){if(!(this instanceof l))return new l(p);let d=p?o(this,p,"readableHighWaterMark",!0):null;d===0&&(p=eE(Ls({},p),{highWaterMark:null,readableHighWaterMark:d,writableHighWaterMark:p.writableHighWaterMark||0})),s.call(this,p),this._readableState.sync=!1,this[a]=null,p&&(typeof p.transform=="function"&&(this._transform=p.transform),typeof p.flush=="function"&&(this._flush=p.flush)),this.on("prefinish",u)}function c(p){typeof this._flush=="function"&&!this.destroyed?this._flush((d,f)=>{if(d){p?p(d):this.destroy(d);return}f!=null&&this.push(f),this.push(null),p&&p()}):(this.push(null),p&&p())}function u(){this._final!==c&&c.call(this)}l.prototype._final=c,l.prototype._transform=function(p,d,f){throw new i("_transform()")},l.prototype._write=function(p,d,f){let m=this._readableState,y=this._writableState,h=m.length;this._transform(p,d,(b,g)=>{if(b){f(b);return}g!=null&&this.push(g),y.ended||h===m.length||m.length{var{ObjectSetPrototypeOf:n}=or();t.exports=i;var r=Oae();n(i.prototype,r.prototype),n(i,r);function i(s){if(!(this instanceof i))return new i(s);r.call(this,s)}i.prototype._transform=function(s,o,a){a(null,s)}}),pC=un((e,t)=>{var n=Tf(),{ArrayIsArray:r,Promise:i,SymbolAsyncIterator:s,SymbolDispose:o}=or(),a=Dp(),{once:l}=qs(),c=nh(),u=qc(),{aggregateTwoErrors:p,codes:{ERR_INVALID_ARG_TYPE:d,ERR_INVALID_RETURN_VALUE:f,ERR_MISSING_ARGS:m,ERR_STREAM_DESTROYED:y,ERR_STREAM_PREMATURE_CLOSE:h},AbortError:b}=ss(),{validateFunction:g,validateAbortSignal:x}=u_(),{isIterable:v,isReadable:D,isReadableNodeStream:T,isNodeStream:N,isTransformStream:O,isWebStream:C,isReadableStream:X,isReadableFinished:te}=Bc(),L=globalThis.AbortController||c_().AbortController,Y,me,I;function Z(ce,Le,Ke){let ct=!1;ce.on("close",()=>{ct=!0});let lt=a(ce,{readable:Le,writable:Ke},(se)=>{ct=!se});return{destroy:(se)=>{ct||(ct=!0,c.destroyer(ce,se||new y("pipe")))},cleanup:lt}}function pe(ce){return g(ce[ce.length-1],"streams[stream.length - 1]"),ce.pop()}function de(ce){if(v(ce))return ce;if(T(ce))return je(ce);throw new d("val",["Readable","Iterable","AsyncIterable"],ce)}function je(ce){return wp(this,null,function*(){me||(me=sE()),yield*wf(me.prototype[s].call(ce))})}async function be(ce,Le,Ke,{end:ct}){let lt,se=null,he=(H)=>{if(H&&(lt=H),se){let ge=se;se=null,ge()}},Ne=()=>new i((H,ge)=>{lt?ge(lt):se=()=>{lt?ge(lt):H()}});Le.on("drain",he);let Re=a(Le,{readable:!1},he);try{Le.writableNeedDrain&&await Ne();try{for(var Oe=sa(ce),G,V,j;G=!(V=await Oe.next()).done;G=!1){let H=V.value;Le.write(H)||await Ne()}}catch(H){j=[H]}finally{try{G&&(V=Oe.return)&&await V.call(Oe)}finally{if(j)throw j[0]}}ct&&(Le.end(),await Ne()),Ke()}catch(H){Ke(lt!==H?p(lt,H):H)}finally{Re(),Le.off("drain",he)}}async function Ie(ce,Le,Ke,{end:ct}){O(Le)&&(Le=Le.writable);let lt=Le.getWriter();try{try{for(var se=sa(ce),he,Ne,Re;he=!(Ne=await se.next()).done;he=!1){let Oe=Ne.value;await lt.ready,lt.write(Oe).catch(()=>{})}}catch(Oe){Re=[Oe]}finally{try{he&&(Ne=se.return)&&await Ne.call(se)}finally{if(Re)throw Re[0]}}await lt.ready,ct&&await lt.close(),Ke()}catch(Oe){try{await lt.abort(Oe),Ke(Oe)}catch(G){Ke(G)}}}function J(...ce){return _e(ce,l(pe(ce)))}function _e(ce,Le,Ke){if(ce.length===1&&r(ce[0])&&(ce=ce[0]),ce.length<2)throw new m("streams");let ct=new L,lt=ct.signal,se=Ke==null?void 0:Ke.signal,he=[];x(se,"options.signal");function Ne(){ge(new b)}I=I||qs().addAbortListener;let Re;se&&(Re=I(se,Ne));let Oe,G,V=[],j=0;function H(Se){ge(Se,--j===0)}function ge(Se,Ce){var Bt;if(Se&&(!Oe||Oe.code==="ERR_STREAM_PREMATURE_CLOSE")&&(Oe=Se),!(!Oe&&!Ce)){for(;V.length;)V.shift()(Oe);(Bt=Re)===null||Bt===void 0||Bt[o](),ct.abort(),Ce&&(Oe||he.forEach((_)=>_()),n.nextTick(Le,Oe,G))}}let fe;for(let Se=0;Se0,S=Bt||(Ke==null?void 0:Ke.end)!==!1,k=Se===ce.length-1;if(N(Ce)){let E=function(A){A&&A.name!=="AbortError"&&A.code!=="ERR_STREAM_PREMATURE_CLOSE"&&H(A)};var W=E;if(S){let{destroy:A,cleanup:Q}=Z(Ce,Bt,_);V.push(A),D(Ce)&&k&&he.push(Q)}Ce.on("error",E),D(Ce)&&k&&he.push(()=>{Ce.removeListener("error",E)})}if(Se===0)if(typeof Ce=="function"){if(fe=Ce({signal:lt}),!v(fe))throw new f("Iterable, AsyncIterable or Stream","source",fe)}else v(Ce)||T(Ce)||O(Ce)?fe=Ce:fe=u.from(Ce);else if(typeof Ce=="function"){if(O(fe)){var ye;fe=de((ye=fe)===null||ye===void 0?void 0:ye.readable)}else fe=de(fe);if(fe=Ce(fe,{signal:lt}),Bt){if(!v(fe,!0))throw new f("AsyncIterable",`transform[${Se-1}]`,fe)}else{var Pe;Y||(Y=Pae());let E=new Y({objectMode:!0}),A=(Pe=fe)===null||Pe===void 0?void 0:Pe.then;if(typeof A=="function")j++,A.call(fe,(Je)=>{G=Je,Je!=null&&E.write(Je),S&&E.end(),n.nextTick(H)},(Je)=>{E.destroy(Je),n.nextTick(H,Je)});else if(v(fe,!0))j++,be(fe,E,H,{end:S});else if(X(fe)||O(fe)){let Je=fe.readable||fe;j++,be(Je,E,H,{end:S})}else throw new f("AsyncIterable or Promise","destination",fe);fe=E;let{destroy:Q,cleanup:le}=Z(fe,!1,!0);V.push(Q),k&&he.push(le)}}else if(N(Ce)){if(T(fe)){j+=2;let E=ue(fe,Ce,H,{end:S});D(Ce)&&k&&he.push(E)}else if(O(fe)||X(fe)){let E=fe.readable||fe;j++,be(E,Ce,H,{end:S})}else if(v(fe))j++,be(fe,Ce,H,{end:S});else throw new d("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],fe);fe=Ce}else if(C(Ce)){if(T(fe))j++,Ie(de(fe),Ce,H,{end:S});else if(X(fe)||v(fe))j++,Ie(fe,Ce,H,{end:S});else if(O(fe))j++,Ie(fe.readable,Ce,H,{end:S});else throw new d("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],fe);fe=Ce}else fe=u.from(Ce)}return(lt!=null&<.aborted||se!=null&&se.aborted)&&n.nextTick(Ne),fe}function ue(ce,Le,Ke,{end:ct}){let lt=!1;if(Le.on("close",()=>{lt||Ke(new h)}),ce.pipe(Le,{end:!1}),ct){let he=function(){lt=!0,Le.end()};var se=he;te(ce)?n.nextTick(he):ce.once("end",he)}else Ke();return a(ce,{readable:!0,writable:!1},(he)=>{let Ne=ce._readableState;he&&he.code==="ERR_STREAM_PREMATURE_CLOSE"&&Ne&&Ne.ended&&!Ne.errored&&!Ne.errorEmitted?ce.once("end",Ke).once("error",Ke):Ke(he)}),a(Le,{readable:!1,writable:!0},Ke)}t.exports={pipelineImpl:_e,pipeline:J}}),$ae=un((e,t)=>{var{pipeline:n}=pC(),r=qc(),{destroyer:i}=nh(),{isNodeStream:s,isReadable:o,isWritable:a,isWebStream:l,isTransformStream:c,isWritableStream:u,isReadableStream:p}=Bc(),{AbortError:d,codes:{ERR_INVALID_ARG_VALUE:f,ERR_MISSING_ARGS:m}}=ss(),y=Dp();t.exports=function(...h){if(h.length===0)throw new m("streams");if(h.length===1)return r.from(h[0]);let b=[...h];if(typeof h[0]=="function"&&(h[0]=r.from(h[0])),typeof h[h.length-1]=="function"){let L=h.length-1;h[L]=r.from(h[L])}for(let L=0;L0&&!(a(h[L])||u(h[L])||c(h[L])))throw new f(`streams[${L}]`,b[L],"must be writable")}let g,x,v,D,T;function N(L){let Y=D;D=null,Y?Y(L):L?T.destroy(L):!te&&!X&&T.destroy()}let O=h[0],C=n(h,N),X=!!(a(O)||u(O)||c(O)),te=!!(o(C)||p(C)||c(C));if(T=new r({writableObjectMode:!!(O!=null&&O.writableObjectMode),readableObjectMode:!!(C!=null&&C.readableObjectMode),writable:X,readable:te}),X){if(s(O))T._write=function(Y,me,I){O.write(Y,me)?I():g=I},T._final=function(Y){O.end(),x=Y},O.on("drain",function(){if(g){let Y=g;g=null,Y()}});else if(l(O)){let Y=(c(O)?O.writable:O).getWriter();T._write=async function(me,I,Z){try{await Y.ready,Y.write(me).catch(()=>{}),Z()}catch(pe){Z(pe)}},T._final=async function(me){try{await Y.ready,Y.close().catch(()=>{}),x=me}catch(I){me(I)}}}let L=c(C)?C.readable:C;y(L,()=>{if(x){let Y=x;x=null,Y()}})}if(te){if(s(C))C.on("readable",function(){if(v){let L=v;v=null,L()}}),C.on("end",function(){T.push(null)}),T._read=function(){for(;;){let L=C.read();if(L===null){v=T._read;return}if(!T.push(L))return}};else if(l(C)){let L=(c(C)?C.readable:C).getReader();T._read=async function(){for(;;)try{let{value:Y,done:me}=await L.read();if(!T.push(Y))return;if(me){T.push(null);return}}catch(Y){return}}}}return T._destroy=function(L,Y){!L&&D!==null&&(L=new d),v=null,g=null,x=null,D===null?Y(L):(D=Y,s(C)&&i(C,L))},T}}),dVe=un((e,t)=>{var n=globalThis.AbortController||c_().AbortController,{codes:{ERR_INVALID_ARG_VALUE:r,ERR_INVALID_ARG_TYPE:i,ERR_MISSING_ARGS:s,ERR_OUT_OF_RANGE:o},AbortError:a}=ss(),{validateAbortSignal:l,validateInteger:c,validateObject:u}=u_(),p=or().Symbol("kWeak"),d=or().Symbol("kResistStopPropagation"),{finished:f}=Dp(),m=$ae(),{addAbortSignalNoValidate:y}=rE(),{isWritable:h,isNodeStream:b}=Bc(),{deprecate:g}=qs(),{ArrayPrototypePush:x,Boolean:v,MathFloor:D,Number:T,NumberIsNaN:N,Promise:O,PromiseReject:C,PromiseResolve:X,PromisePrototypeThen:te,Symbol:L}=or(),Y=L("kEmpty"),me=L("kEof");function I(se,he){if(he!=null&&u(he,"options"),(he==null?void 0:he.signal)!=null&&l(he.signal,"options.signal"),b(se)&&!h(se))throw new r("stream",se,"must be writable");let Ne=m(this,se);return he!=null&&he.signal&&y(he.signal,Ne),Ne}function Z(se,he){if(typeof se!="function")throw new i("fn",["Function","AsyncFunction"],se);he!=null&&u(he,"options"),(he==null?void 0:he.signal)!=null&&l(he.signal,"options.signal");let Ne=1;(he==null?void 0:he.concurrency)!=null&&(Ne=D(he.concurrency));let Re=Ne-1;return(he==null?void 0:he.highWaterMark)!=null&&(Re=D(he.highWaterMark)),c(Ne,"options.concurrency",1),c(Re,"options.highWaterMark",0),Re+=Ne,function(){return wp(this,null,function*(){let Oe=qs().AbortSignalAny([he==null?void 0:he.signal].filter(v)),G=this,V=[],j={signal:Oe},H,ge,fe=!1,W=0;function ye(){fe=!0,Pe()}function Pe(){W-=1,Se()}function Se(){ge&&!fe&&W=Re||W>=Ne)&&await new O((A)=>{ge=A})}}catch(E){k=[E]}finally{try{_&&(S=Bt.return)&&await S.call(Bt)}finally{if(k)throw k[0]}}V.push(me)}catch(E){let A=C(E);te(A,Pe,ye),V.push(A)}finally{fe=!0,H&&(H(),H=null)}}Ce();try{for(;;){for(;V.length>0;){let Bt=yield new Ms(V[0]);if(Bt===me)return;if(Oe.aborted)throw new a;Bt!==Y&&(yield Bt),V.shift(),Se()}yield new Ms(new O((Bt)=>{H=Bt}))}}finally{fe=!0,ge&&(ge(),ge=null)}})}.call(this)}function pe(se=void 0){return se!=null&&u(se,"options"),(se==null?void 0:se.signal)!=null&&l(se.signal,"options.signal"),function(){return wp(this,null,function*(){let he=0;try{for(var Ne=sa(this),Re,Oe,G;Re=!(Oe=yield new Ms(Ne.next())).done;Re=!1){let j=Oe.value;var V;if(se!=null&&(V=se.signal)!==null&&V!==void 0&&V.aborted)throw new a({cause:se.signal.reason});yield[he++,j]}}catch(j){G=[j]}finally{try{Re&&(Oe=Ne.return)&&(yield new Ms(Oe.call(Ne)))}finally{if(G)throw G[0]}}})}.call(this)}async function de(se,he=void 0){try{for(var Ne=sa(J.call(this,se,he)),Re,Oe,G;Re=!(Oe=await Ne.next()).done;Re=!1){let V=Oe.value;return!0}}catch(V){G=[V]}finally{try{Re&&(Oe=Ne.return)&&await Oe.call(Ne)}finally{if(G)throw G[0]}}return!1}async function je(se,he=void 0){if(typeof se!="function")throw new i("fn",["Function","AsyncFunction"],se);return!await de.call(this,async(...Ne)=>!await se(...Ne),he)}async function be(se,he){try{for(var Ne=sa(J.call(this,se,he)),Re,Oe,G;Re=!(Oe=await Ne.next()).done;Re=!1)return Oe.value}catch(V){G=[V]}finally{try{Re&&(Oe=Ne.return)&&await Oe.call(Ne)}finally{if(G)throw G[0]}}}async function Ie(se,he){if(typeof se!="function")throw new i("fn",["Function","AsyncFunction"],se);async function Ne(j,H){return await se(j,H),Y}try{for(var Re=sa(Z.call(this,Ne,he)),Oe,G,V;Oe=!(G=await Re.next()).done;Oe=!1){let j=G.value}}catch(j){V=[j]}finally{try{Oe&&(G=Re.return)&&await G.call(Re)}finally{if(V)throw V[0]}}}function J(se,he){if(typeof se!="function")throw new i("fn",["Function","AsyncFunction"],se);async function Ne(Re,Oe){return await se(Re,Oe)?Re:Y}return Z.call(this,Ne,he)}var _e=class extends s{constructor(){super("reduce"),this.message="Reduce of an empty stream requires an initial value"}};async function ue(se,he,Ne){var Re;if(typeof se!="function")throw new i("reducer",["Function","AsyncFunction"],se);Ne!=null&&u(Ne,"options"),(Ne==null?void 0:Ne.signal)!=null&&l(Ne.signal,"options.signal");let Oe=arguments.length>1;if(Ne!=null&&(Re=Ne.signal)!==null&&Re!==void 0&&Re.aborted){let Pe=new a(void 0,{cause:Ne.signal.reason});throw this.once("error",()=>{}),await f(this.destroy(Pe)),Pe}let G=new n,V=G.signal;if(Ne!=null&&Ne.signal){let Pe={once:!0,[p]:this,[d]:!0};Ne.signal.addEventListener("abort",()=>G.abort(),Pe)}let j=!1;try{try{for(var H=sa(this),ge,fe,W;ge=!(fe=await H.next()).done;ge=!1){let Pe=fe.value;var ye;if(j=!0,Ne!=null&&(ye=Ne.signal)!==null&&ye!==void 0&&ye.aborted)throw new a;Oe?he=await se(he,Pe,{signal:V}):(he=Pe,Oe=!0)}}catch(Pe){W=[Pe]}finally{try{ge&&(fe=H.return)&&await fe.call(H)}finally{if(W)throw W[0]}}if(!j&&!Oe)throw new _e}finally{G.abort()}return he}async function ce(se){se!=null&&u(se,"options"),(se==null?void 0:se.signal)!=null&&l(se.signal,"options.signal");let he=[];try{for(var Ne=sa(this),Re,Oe,G;Re=!(Oe=await Ne.next()).done;Re=!1){let j=Oe.value;var V;if(se!=null&&(V=se.signal)!==null&&V!==void 0&&V.aborted)throw new a(void 0,{cause:se.signal.reason});x(he,j)}}catch(j){G=[j]}finally{try{Re&&(Oe=Ne.return)&&await Oe.call(Ne)}finally{if(G)throw G[0]}}return he}function Le(se,he){let Ne=Z.call(this,se,he);return function(){return wp(this,null,function*(){try{for(var Re=sa(Ne),Oe,G,V;Oe=!(G=yield new Ms(Re.next())).done;Oe=!1){let j=G.value;yield*wf(j)}}catch(j){V=[j]}finally{try{Oe&&(G=Re.return)&&(yield new Ms(G.call(Re)))}finally{if(V)throw V[0]}}})}.call(this)}function Ke(se){if(se=T(se),N(se))return 0;if(se<0)throw new o("number",">= 0",se);return se}function ct(se,he=void 0){return he!=null&&u(he,"options"),(he==null?void 0:he.signal)!=null&&l(he.signal,"options.signal"),se=Ke(se),function(){return wp(this,null,function*(){var Ne;if(he!=null&&(Ne=he.signal)!==null&&Ne!==void 0&&Ne.aborted)throw new a;try{for(var Re=sa(this),Oe,G,V;Oe=!(G=yield new Ms(Re.next())).done;Oe=!1){let H=G.value;var j;if(he!=null&&(j=he.signal)!==null&&j!==void 0&&j.aborted)throw new a;se--<=0&&(yield H)}}catch(H){V=[H]}finally{try{Oe&&(G=Re.return)&&(yield new Ms(G.call(Re)))}finally{if(V)throw V[0]}}})}.call(this)}function lt(se,he=void 0){return he!=null&&u(he,"options"),(he==null?void 0:he.signal)!=null&&l(he.signal,"options.signal"),se=Ke(se),function(){return wp(this,null,function*(){var Ne;if(he!=null&&(Ne=he.signal)!==null&&Ne!==void 0&&Ne.aborted)throw new a;try{for(var Re=sa(this),Oe,G,V;Oe=!(G=yield new Ms(Re.next())).done;Oe=!1){let H=G.value;var j;if(he!=null&&(j=he.signal)!==null&&j!==void 0&&j.aborted)throw new a;if(se-- >0&&(yield H),se<=0)return}}catch(H){V=[H]}finally{try{Oe&&(G=Re.return)&&(yield new Ms(G.call(Re)))}finally{if(V)throw V[0]}}})}.call(this)}t.exports.streamReturningOperators={asIndexedPairs:g(pe,"readable.asIndexedPairs will be removed in a future version."),drop:ct,filter:J,flatMap:Le,map:Z,take:lt,compose:I},t.exports.promiseReturningOperators={every:je,forEach:Ie,reduce:ue,toArray:ce,some:de,find:be}}),Iae=un((e,t)=>{var{ArrayPrototypePop:n,Promise:r}=or(),{isIterable:i,isNodeStream:s,isWebStream:o}=Bc(),{pipelineImpl:a}=pC(),{finished:l}=Dp();Aae();function c(...u){return new r((p,d)=>{let f,m,y=u[u.length-1];if(y&&typeof y=="object"&&!s(y)&&!i(y)&&!o(y)){let h=n(u);f=h.signal,m=h.end}a(u,(h,b)=>{h?d(h):p(b)},{signal:f,end:m})})}t.exports={finished:l,pipeline:c}}),Aae=un((e,t)=>{var{Buffer:n}=Uc(),{ObjectDefineProperty:r,ObjectKeys:i,ReflectApply:s}=or(),{promisify:{custom:o}}=qs(),{streamReturningOperators:a,promiseReturningOperators:l}=dVe(),{codes:{ERR_ILLEGAL_CONSTRUCTOR:c}}=ss(),u=$ae(),{setDefaultHighWaterMark:p,getDefaultHighWaterMark:d}=iE(),{pipeline:f}=pC(),{destroyer:m}=nh(),y=Dp(),h=Iae(),b=Bc(),g=t.exports=cC().Stream;g.isDestroyed=b.isDestroyed,g.isDisturbed=b.isDisturbed,g.isErrored=b.isErrored,g.isReadable=b.isReadable,g.isWritable=b.isWritable,g.Readable=sE();for(let v of i(a)){let D=function(...N){if(new.target)throw c();return g.Readable.from(s(T,this,N))},T=a[v];r(D,"name",{__proto__:null,value:T.name}),r(D,"length",{__proto__:null,value:T.length}),r(g.Readable.prototype,v,{__proto__:null,value:D,enumerable:!1,configurable:!0,writable:!0})}for(let v of i(l)){let D=function(...N){if(new.target)throw c();return s(T,this,N)},T=l[v];r(D,"name",{__proto__:null,value:T.name}),r(D,"length",{__proto__:null,value:T.length}),r(g.Readable.prototype,v,{__proto__:null,value:D,enumerable:!1,configurable:!0,writable:!0})}g.Writable=uC(),g.Duplex=qc(),g.Transform=Oae(),g.PassThrough=Pae(),g.pipeline=f;var{addAbortSignal:x}=rE();g.addAbortSignal=x,g.finished=y,g.destroy=m,g.compose=u,g.setDefaultHighWaterMark=p,g.getDefaultHighWaterMark=d,r(g,"promises",{__proto__:null,configurable:!0,enumerable:!0,get(){return h}}),r(f,o,{__proto__:null,enumerable:!0,get(){return h.pipeline}}),r(y,o,{__proto__:null,enumerable:!0,get(){return h.finished}}),g.Stream=g,g._isUint8Array=function(v){return v instanceof Uint8Array},g._uint8ArrayToBuffer=function(v){return n.from(v.buffer,v.byteOffset,v.byteLength)}}),dC=un((e,t)=>{var n=Aae(),r=Iae(),i=n.Readable.destroy;t.exports=n.Readable,t.exports._uint8ArrayToBuffer=n._uint8ArrayToBuffer,t.exports._isUint8Array=n._isUint8Array,t.exports.isDisturbed=n.isDisturbed,t.exports.isErrored=n.isErrored,t.exports.isReadable=n.isReadable,t.exports.Readable=n.Readable,t.exports.Writable=n.Writable,t.exports.Duplex=n.Duplex,t.exports.Transform=n.Transform,t.exports.PassThrough=n.PassThrough,t.exports.addAbortSignal=n.addAbortSignal,t.exports.finished=n.finished,t.exports.destroy=n.destroy,t.exports.destroy=i,t.exports.pipeline=n.pipeline,t.exports.compose=n.compose,Object.defineProperty(n,"promises",{configurable:!0,enumerable:!0,get(){return r}}),t.exports.Stream=n.Stream,t.exports.default=t.exports}),fVe=tE(Uc()),xf="http://www.w3.org/1999/02/22-rdf-syntax-ns#",Qy="http://www.w3.org/2001/XMLSchema#",HS="http://www.w3.org/2000/10/swap/",br={xsd:{decimal:`${Qy}decimal`,boolean:`${Qy}boolean`,dateTime:`${Qy}dateTime`,double:`${Qy}double`,integer:`${Qy}integer`,string:`${Qy}string`},rdf:{type:`${xf}type`,nil:`${xf}nil`,first:`${xf}first`,rest:`${xf}rest`,langString:`${xf}langString`,dirLangString:`${xf}dirLangString`,reifies:`${xf}reifies`},owl:{sameAs:"http://www.w3.org/2002/07/owl#sameAs"},r:{forSome:`${HS}reify#forSome`,forAll:`${HS}reify#forAll`},log:{implies:`${HS}log#implies`,isImpliedBy:`${HS}log#isImpliedBy`}},{xsd:zS}=br,WS=32,QS=9,hae=10,YS=13,mVe=35,yVe=/\\u([a-fA-F0-9]{4})|\\U([a-fA-F0-9]{8})|\\([^])/g,gae={"\\":"\\","'":"'",'"':'"',n:` +`,r:"\r",t:"\t",f:"\f",b:"\b"},hVe={_:"_","~":"~",".":".","-":"-","!":"!",$:"$","&":"&","'":"'","(":"(",")":")","*":"*","+":"+",",":",",";":";","=":"=","/":"/","?":"?","#":"#","@":"@","%":"%"},gVe=/[\x00-\x20<>\\"\{\}\|\^\`]/;function bae(e){return e<=1114111&&(e<55296||e>57343)}var bVe={_iri:!0,_unescapedIri:!0,_simpleQuotedString:!0,_langcode:!0,_blank:!0,_commentLine:!0,_whitespace:!0},vVe=/$0^/,_Ve=class{constructor(e){if(this._iri=/^<((?:[^ <>{}\\]|\\[uU])+)>[ \t]*/,this._unescapedIri=/^<([^\x00-\x20<>\\"\{\}\|\^\`]*)>[ \t]*/,this._simpleQuotedString=/^"([^"\\\r\n]*)"(?=[^"])/,this._simpleApostropheString=/^'([^'\\\r\n]*)'(?=[^'])/,this._langcode=/^@([a-z]+(?:-[a-z0-9]+)*)(?=[^a-z0-9])/i,this._prefix=/^((?:[A-Za-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)?:(?=[#\s<])/,this._prefixed=/^((?:[A-Za-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)?:((?:(?:[0-:A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~])(?:(?:[\.\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~])*(?:[\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~]))?)?)(?:[ \t]+|(?=\.?[,;!\^\s#()\[\]\{\}"'<>]))/,this._variable=/^\?(?:(?:[A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:[\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)(?=[.,;!\^\s#()\[\]\{\}"'<>])/,this._blank=/^_:((?:[0-9A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)(?:[ \t]+|(?=\.?[,;:!\^\s#()\[\]\{\}"'<>]))/,this._number=/^[\-+]?(?:(\d+\.\d*|\.?\d+)[eE][\-+]?|\d*(\.)?)\d+(?=\.?[,;:!\^\s#()\[\]\{\}"'<>])/,this._boolean=/^(?:true|false)(?=[.,;!\^\s#()\[\]\{\}"'<>])/,this._atKeyword=/^@[a-z]+(?=[\s#<:])/i,this._keyword=/^(?:PREFIX|BASE|VERSION|GRAPH)(?=[\s#<])/i,this._n3Verb=/^(?:has|is|of)(?=[\s#()\[\]\{\}"'<>?_+\-0-9])/,this._n3Id=/^id(?=[\s#<])/,this._shortPredicates=/^a(?=[\s#()\[\]\{\}"'<>])/,this._commentLine=/^[ \t]*#([^\n\r]*)(?:\r\n|\n|\r)([ \t]*)/,this._whitespace=/^[ \t]+/,e=e||{},this._isImpliedBy=e.isImpliedBy,this._lineMode=!!e.lineMode){this._n3Mode=!1;for(let t in this)!(t in bVe)&&this[t]instanceof RegExp&&(this[t]=vVe)}else this._n3Mode=e.n3!==!1;this.comments=!!e.comments,this._literalClosingPos=0}_tokenizeToEnd(e,t){let n=this._input,r=this._linePosition+n.length;for(;;){for(;;){let x=n.charCodeAt(0),v=0;if(x===WS||x===QS){let D=n.charCodeAt(1);v=D===WS||D===QS?this._whitespace.exec(n)[0].length:1,x=n.charCodeAt(v)}if(x===mVe){let D=this._commentLine.exec(n);if(D){let T=D[0].length;if(!t&&T===n.length&&n.charCodeAt(T-1)===YS)return this._linePosition=r-n.length,this._input=n;this.comments&&i(D[1],this._line,v),n=n.slice(T),r=n.length+D[2].length,this._line++}else{if(n=n.slice(v),!t)return this._linePosition=r-n.length,this._input=n;this.comments&&i(n.slice(1),this._line,0),n="";break}}else if(x===hae||x===YS){if(!t&&x===YS&&v+1===n.length)return this._linePosition=r-n.length,this._input=n;v+=x===YS&&n.charCodeAt(v+1)===hae?2:1;let D=0,T=n.charCodeAt(v);if(T===WS||T===QS){let N=n.charCodeAt(v+1);D=N===WS||N===QS?this._whitespace.exec(n.slice(v))[0].length:1}n=n.slice(v+D),r=n.length+D,this._line++}else{v!==0&&(n=n.slice(v));break}}if(n.length===0)return t&&(n=null,s("eof","","",this._line,0)),this._linePosition=r,this._input=n;let a=this._line,l=n[0],c="",u="",p="",d=null,f=0,m=0,y=0,h=!1;switch(l){case"^":if(n.length<3)break;if(n[1]==="^"){if(this._previousMarker="^^",n=n.slice(2),n[0]!=="<"){h=!0;break}}else{this._n3Mode&&(f=1,c="^");break}case"<":if(d=this._unescapedIri.exec(n))c="IRI",u=d[1],m=d[1].length+2;else if(d=this._iri.exec(n)){if(u=this._unescape(d[1],gae),u===null||gVe.test(u))return o(this);c="IRI",m=d[1].length+2}else n.length>2&&n[1]==="<"&&n[2]==="("?(c="<<(",f=3):!this._lineMode&&n.length>(t?1:2)&&n[1]==="<"?(c="<<",f=2):this._n3Mode&&n.length>1&&n[1]==="="?(f=2,this._isImpliedBy?(c="abbreviation",u="<"):(c="inverse",u=">")):this._n3Mode&&n.length>1&&n[1]==="-"&&(c="inversePredicate",f=2);break;case">":n.length>1&&n[1]===">"&&(c=">>",f=2);break;case"_":((d=this._blank.exec(n))||t&&(d=this._blank.exec(`${n} `)))&&(c="blank",p="_",u=d[1],m=d[1].length+2);break;case'"':if(d=this._simpleQuotedString.exec(n))u=d[1];else if({value:u,matchLength:f,finalLineLength:y}=this._parseLiteral(n),u===null)return o(this);(d!==null||f!==0)&&(c="literal",this._literalClosingPos=0);break;case"'":if(!this._lineMode){if(d=this._simpleApostropheString.exec(n))u=d[1];else if({value:u,matchLength:f,finalLineLength:y}=this._parseLiteral(n),u===null)return o(this);(d!==null||f!==0)&&(c="literal",this._literalClosingPos=0)}break;case"?":this._n3Mode&&(d=this._variable.exec(n))&&(c="var",u=d[0]);break;case"@":this._previousMarker==="literal"&&(d=this._langcode.exec(n))&&d[1]!=="version"?!t&&n[d[0].length]==="-"&&n[d[0].length+1]!=="-"?d=null:(c="langcode",u=d[1]):(d=this._atKeyword.exec(n))&&(c=d[0]);break;case".":if(n.length===1?t:n[1]<"0"||n[1]>"9"){c=".",f=1;break}case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":case"+":case"-":if(n[1]==="-"){this._previousMarker==="langcode"&&(n.startsWith("--ltr")?(c="dircode",u="ltr",f=5):n.startsWith("--rtl")&&(c="dircode",u="rtl",f=5));break}(d=this._number.exec(n)||t&&(d=this._number.exec(`${n} `)))&&(c="literal",u=d[0],p=typeof d[1]=="string"?zS.double:typeof d[2]=="string"?zS.decimal:zS.integer);break;case"B":case"b":case"p":case"P":case"G":case"g":case"V":case"v":(d=this._keyword.exec(n))?c=d[0].toUpperCase():h=!0;break;case"f":case"t":this._boolean.test(n)?(c="literal",u=l==="t"?"true":"false",p=zS.boolean,f=u.length):h=!0;break;case"a":this._shortPredicates.test(n)?(c="abbreviation",u="a",f=1):h=!0;break;case"h":case"o":this._n3Mode&&(d=this._matchN3Verb(n,t))?c=d[0]:h=!0;break;case"i":this._n3Mode&&this._n3Id.test(n)?(c="id",f=2):this._n3Mode&&(d=this._matchN3Verb(n,t))?c=d[0]:h=!0;break;case"=":this._n3Mode&&n.length>1&&(c="abbreviation",n[1]!==">"?(f=1,u="="):(f=2,u=">"));break;case"!":if(!this._n3Mode)break;case")":if(!t&&(n.length===1||n.length===2&&n[1]===">"))break;if(n.length>2&&n[1]===">"&&n[2]===">"){c=")>>",f=3;break}case",":case";":case"[":case"]":case"(":case"}":case"~":this._lineMode||(f=1,c=l);break;case"{":!this._lineMode&&n.length>=2&&(n[1]==="|"?(c="{|",f=2):(c=l,f=1));break;case"|":n.length>=2&&n[1]==="}"&&(c="|}",f=2);break;default:h=!0}if(h&&((this._previousMarker==="@prefix"||this._previousMarker==="PREFIX")&&(d=this._prefix.exec(n))?(c="prefix",u=d[1]||""):((d=this._prefixed.exec(n))||t&&(d=this._prefixed.exec(`${n} `)))&&(c="prefixed",p=d[1]||"",u=this._unescape(d[2],hVe),m=p.length+d[2].length+1)),this._previousMarker==="^^")switch(c){case"prefixed":c="type";break;case"IRI":c="typeIRI";break;default:c=""}if(!c)return t||!/^'''|^"""/.test(n)&&/\n|\r/.test(n)?o(this):(this._linePosition=r-n.length,this._input=n);let b=f||d[0].length,g;y?(g={type:c,value:u,prefix:p,line:a,start:r-n.length,end:y,endLine:this._line},e(null,g)):g=s(c,u,p,a,m||b),this.previousToken=g,this._previousMarker=c,n=n.slice(b),y&&(r=n.length+y)}function i(a,l,c){let u=r-n.length+c;e(null,{type:"comment",value:a,prefix:"",line:l,start:u,end:u+a.length+1})}function s(a,l,c,u,p){let d=n?r-n.length:r,f=d+p,m={type:a,value:l,prefix:c,line:u,start:d,end:f};return e(null,m),m}function o(a){e(a._syntaxError(/^\S*/.exec(n)[0]))}}_matchN3Verb(e,t){let n=this._n3Verb.exec(e);if(!n)return null;let r=e[n[0].length];return r!=="-"&&r!=="_"&&(r<"0"||r>"9")?n:this._prefixed.exec(e)||this._prefixed.exec(`${e} `)||!t&&this._prefix.exec(`${e}: `)?null:n}_unescape(e,t){if(e.indexOf("\\")<0)return e;let n=!1,r=e.replace(yVe,(i,s,o,a)=>{if(typeof s=="string"){let l=Number.parseInt(s,16);return bae(l)?String.fromCharCode(l):(n=!0,"")}if(typeof o=="string"){let l=Number.parseInt(o,16);return bae(l)?l<=65535?String.fromCharCode(Number.parseInt(o,16)):String.fromCharCode(55296+((l-=65536)>>10),56320+(l&1023)):(n=!0,"")}return a in t?t[a]:(n=!0,"")});return n?null:r}_parseLiteral(e){if(e.length>=3){let t=e[0],n=e[1]===t&&e[2]===t?3:1,r=t;n===3&&(r=t==='"'?'"""':"'''");let i=Math.max(this._literalClosingPos,n);for(;(i=e.indexOf(r,i))>0;){let s=0;for(;e[i-s-1]==="\\";)s++;if(s%2===0){let o=e.substring(n,i),a=o.split(/\r\n|\r|\n/),l=a.length-1,c=i+n;if(n===1&&l!==0||n===3&&this._lineMode)break;this._line+=l;let u=l===0?0:a[a.length-1].length+n;return{value:this._unescape(o,gae),matchLength:c,finalLineLength:u}}i++}this._literalClosingPos=e.length-n+1}return{value:"",matchLength:0,finalLineLength:0}}_syntaxError(e){this._input=null;let t=Error(`Unexpected "${e}" on line ${this._line}.`);return t.context={token:void 0,line:this._line,previousToken:this.previousToken},t}_readStartingBom(e){return e.startsWith("\uFEFF")?(this._linePosition=1,e.slice(1)):e}tokenize(e,t){let n=this._tokenization={};if(this._line=1,this._linePosition=0,this._previousMarker=void 0,this.previousToken=void 0,this._literalClosingPos=0,this._input=void 0,typeof e=="string")if(this._input=this._readStartingBom(e),typeof t=="function")queueMicrotask(()=>{this._tokenization===n&&this._tokenizeToEnd(t,!0)});else{let r=[],i;if(this._tokenizeToEnd((s,o)=>s?i=s:r.push(o),!0),i)throw i;return r}else this._pendingBuffer=null,typeof e.setEncoding=="function"&&e.setEncoding("utf8"),e.on("data",(r)=>{this._tokenization===n&&this._input!==null&&r.length!==0&&(this._pendingBuffer&&(r=fVe.Buffer.concat([this._pendingBuffer,r]),this._pendingBuffer=null),r[r.length-1]&128?this._pendingBuffer=r:(typeof this._input>"u"?this._input=this._readStartingBom(typeof r=="string"?r:r.toString()):this._input+=r,this._tokenizeToEnd(t,!1)))}),e.on("end",()=>{this._tokenization===n&&typeof this._input=="string"&&this._tokenizeToEnd(t,!0)}),e.on("error",(r)=>{this._tokenization===n&&t(r)})}};var{rdf:vae,xsd:xp}=br,rh,xVe=0,aC={namedNode:Fae,blankNode:Cae,variable:Lae,literal:Mae,defaultGraph:SVe,quad:lC,triple:lC,fromTerm:l_,fromQuad:qae},os=aC,Vc=class e{constructor(t){this.id=t}get value(){return this.id}equals(t){return t instanceof e?this.id===t.id:!!t&&this.termType===t.termType&&this.value===t.value}hashCode(){return 0}toJSON(){return{termType:this.termType,value:this.value}}},Rae=class extends Vc{constructor(e){super(e)}get termType(){return"NamedNode"}},o_=class e extends Vc{constructor(t){super(t)}get termType(){return"Literal"}get value(){return this.id.substring(1,this.id.lastIndexOf('"'))}get language(){let t=this.id,n=t.lastIndexOf('"')+1,r=t.lastIndexOf("--");return nn?t.substr(0,r):t).substr(n).toLowerCase():""}get direction(){let t=this.id,n=t.lastIndexOf('"'),r=t.lastIndexOf("--");return r>n&&r+20?vae.dirLangString:vae.langString}equals(t){return t instanceof e?this.id===t.id:!!t&&!!t.datatype&&this.termType===t.termType&&this.value===t.value&&this.language===t.language&&(this.direction===t.direction||this.direction===""&&!t.direction)&&this.datatype.value===t.datatype.value}toJSON(){return{termType:this.termType,value:this.value,language:this.language,direction:this.direction,datatype:{termType:"NamedNode",value:this.datatypeString}}}},wVe=class extends Vc{constructor(e){super(`_:${e}`)}get termType(){return"BlankNode"}get value(){return this.id.substr(2)}},DVe=class extends Vc{constructor(e){super(`?${e}`)}get termType(){return"Variable"}get value(){return this.id.substr(1)}},TVe=class extends Vc{constructor(){return super(""),rh||this}get termType(){return"DefaultGraph"}equals(e){return this===e||!!e&&this.termType===e.termType}};rh=new TVe;function a_(e,t,n){if(t=t||aC,!e)return t.defaultGraph();switch(e[0]){case"?":return t.variable(e.substr(1));case"_":return t.blankNode(e.substr(2));case'"':if(t===aC)return new o_(e);if(e[e.length-1]==='"')return t.literal(e.substr(1,e.length-2));let r=e.lastIndexOf('"',e.length-1),i;if(e[r+1]==="@"){i=e.substr(r+2);let s=i.lastIndexOf("--");s>0&&s0?"INF":"-INF")):e instanceof Date&&!Number.isNaN(e.getTime())&&(n=xp.dateTime,e=e.toISOString())),n===""||n===xp.string?new o_(`"${e}"`):new o_(`"${e}"^^${n}`)}function Lae(e){return new DVe(e)}function SVe(){return rh}function lC(e,t,n,r){return new jae(e,t,n,r)}function l_(e){if(e instanceof Vc)return e;switch(e.termType){case"NamedNode":return Fae(e.value);case"BlankNode":return Cae(e.value);case"Variable":return Lae(e.value);case"DefaultGraph":return rh;case"Literal":return Mae(e.value,e.language||e.datatype);case"Quad":return qae(e);default:throw Error(`Unexpected termType: ${e.termType}`)}}function qae(e){if(e instanceof jae)return e;if(e.termType!=="Quad")throw Error(`Unexpected termType: ${e.termType}`);return lC(l_(e.subject),l_(e.predicate),l_(e.object),l_(e.graph))}var _ae=0,p_=class e{constructor(t){this._contextStack=[],this._graph=null,t=t||{},this._setBase(t.baseIRI),t.factory&&Uae(this,t.factory);let n=typeof t.format=="string"?t.format.match(/\w*$/)[0].toLowerCase():"",r=/turtle/.test(n),i=/trig/.test(n),s=/triple/.test(n),o=/quad/.test(n),a=this._n3Mode=/n3/.test(n),l=s||o;this._emitCurrent=this._emit,a&&(this._createQuad=this._createQuadInDirection,this._emit=this._emitInDirection,this._emitCurrent=this._emitCurrentInDirection),(this._supportsNamedGraphs=!(r||a))||(this._readPredicateOrNamedGraph=this._readPredicate),this._supportsQuads=!(r||i||s||a),this._isImpliedBy=t.isImpliedBy,this._implicitEmptyPrefix=!!t.implicitEmptyPrefix,this._emptyFormulaAsTrue=!!t.emptyFormulaAsTrue,l&&(this._resolveRelativeIRI=(c)=>null),this._blankNodePrefix=typeof t.blankNodePrefix!="string"?"":t.blankNodePrefix.replace(/^(?!_:)/,"_:"),this._lexer=t.lexer||new _Ve({lineMode:l,n3:a,isImpliedBy:this._isImpliedBy}),this._explicitQuantifiers=!!t.explicitQuantifiers,this._parseUnsupportedVersions=!!t.parseUnsupportedVersions,this._version=t.version}static _resetBlankNodePrefix(){_ae=0}_setBase(t){if(!t)this._base="",this._basePath="";else{let n=t.indexOf("#");n>=0&&(t=t.substr(0,n)),this._base=t,this._basePath=t.indexOf("/")<0?t:t.replace(/[^\/?]*(?:\?.*)?$/,""),t=t.match(/^(?:([a-z][a-z0-9+.-]*:))?(?:\/\/[^\/]*)?/i),this._baseRoot=t[0],this._baseScheme=t[1]}}_saveContext(t,n,r,i,s){if(!this._n3Mode){this._contextStack.push({type:t,subject:r,predicate:i,object:s,graph:n});return}let o={type:t,subject:r,predicate:i,object:s,graph:n,inverse:this._inversePredicate,expectOf:this._expectOf,blankPrefix:this._prefixes._,quantified:this._quantified,emptyFormula:this._emptyFormula};t==="formula"&&(o.prefixes=this._prefixes,o.base=[this._base,this._basePath,this._baseRoot,this._baseScheme],this._prefixes=Object.create(this._prefixes)),this._contextStack.push(o),this._inversePredicate=!1,this._expectOf=!1,this._prefixes._=this._graph?`${this._graph.value}.`:".",this._quantified=Object.create(this._quantified),t==="formula"&&(this._subject=null,this._emptyFormula=!0)}_restoreContext(t,n){let r=this._contextStack.pop();if(!r||r.type!==t)return this._error(`Unexpected ${n.type}`,n);this._subject=r.subject,this._predicate=r.predicate,this._object=r.object,this._graph=r.graph,this._n3Mode&&(this._inversePredicate=r.inverse,this._expectOf=r.expectOf,t==="formula"?(this._prefixes=r.prefixes,[this._base,this._basePath,this._baseRoot,this._baseScheme]=r.base):this._prefixes._=r.blankPrefix,this._quantified=r.quantified,this._emptyFormula=r.emptyFormula)}_readBeforeTopContext(t){return this._version&&!this._isValidVersion(this._version)?this._error(`Detected unsupported version as media type parameter: "${this._version}"`,t):this._readInTopContext(t)}_readInTopContext(t){switch(t.type){case"eof":return this._graph!==null?this._error("Unclosed graph",t):(delete this._prefixes._,this._callback(null,null,this._prefixes));case"PREFIX":this._sparqlStyle=!0;case"@prefix":return this._readPrefix;case"BASE":this._sparqlStyle=!0;case"@base":return this._readBaseIRI;case"VERSION":this._sparqlStyle=!0;case"@version":return this._readVersion;case"{":if(this._supportsNamedGraphs)return this._graph="",this._subject=null,this._readSubject;case"GRAPH":if(this._supportsNamedGraphs)return this._readNamedGraphLabel;default:return this._readSubject(t)}}_readInFormulaContext(t){switch(t.type){case"PREFIX":this._sparqlStyle=!0;case"@prefix":return this._readPrefix;case"BASE":this._sparqlStyle=!0;case"@base":return this._readBaseIRI;default:return this._readSubject(t)}}_getStatementReader(){let t=this._contextStack[this._contextStack.length-1];return t&&t.type==="formula"?this._readInFormulaContext:this._readInTopContext}_readEntity(t,n){let r;switch(t.type){case"IRI":case"typeIRI":let i=this._resolveIRI(t.value);if(i===null)return this._error("Invalid IRI",t);r=this._factory.namedNode(i);break;case"type":case"prefixed":let s=this._prefixes[t.prefix];if(s===void 0)return this._error(`Undefined prefix "${t.prefix}:"`,t);r=this._factory.namedNode(s+t.value);break;case"blank":r=this._factory.blankNode(this._prefixes[t.prefix]+t.value);break;case"var":r=this._factory.variable(t.value.substr(1));break;default:return this._error(`Expected entity but got ${t.type}`,t)}return!n&&this._n3Mode&&r.id in this._quantified&&(r=this._quantified[r.id]),r}_readList(t,n,r,i){let s=this._contextStack;return(s.length&&s[s.length-1]).type==="<<"?this._error("Unexpected list in reified triple",t):(this._saveContext("list",this._graph,n,r,i),this._subject=null,this._readListItem)}_readSubject(t){switch(this._predicate=null,t.type!=="}"&&(this._emptyFormula=!1),t.type){case"[":return this._saveContext("blank",this._graph,this._subject=this._factory.blankNode(),null,null),this._readBlankNodeHead;case"(":return this._readList(t,this.RDF_NIL,null,null);case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._graph=this._factory.blankNode(),null,null),this._readInFormulaContext):this._error("Unexpected graph",t);case"}":return this._readPunctuation(t);case"@forSome":return this._n3Mode?(this._subject=null,this._predicate=this.N3_FORSOME,this._quantifier="blankNode",this._readQuantifierList):this._error('Unexpected "@forSome"',t);case"@forAll":return this._n3Mode?(this._subject=null,this._predicate=this.N3_FORALL,this._quantifier="variable",this._readQuantifierList):this._error('Unexpected "@forAll"',t);case"literal":return this._n3Mode?t.prefix.length===0?(this._literalValue=t.value,this._completeSubjectLiteral):(this._subject=this._factory.literal(t.value,this._factory.namedNode(t.prefix)),this._getPathReader(this._readPredicateOrNamedGraph)):this._error("Unexpected literal",t);case"<<(":return this._n3Mode?(this._saveContext("<<(",this._graph,null,null,null),this._graph=null,this._readSubject):this._error("Disallowed triple term as subject",t);case"<<":return this._saveContext("<<",this._graph,null,null,null),this._graph=null,this._readSubject;default:if((this._subject=this._readEntity(t))===void 0)return;if(this._n3Mode)return this._getPathReader(this._readPredicateOrNamedGraph)}return this._readPredicateOrNamedGraph}_readPredicate(t){let n=t.type,r=!1;switch(n){case"inverse":this._inversePredicate=!0;case"abbreviation":this._predicate=this.ABBREVIATIONS[t.value];break;case"has":return this._readPredicateAfterVerb;case"is":return this._inversePredicate=!0,this._expectOf=!0,this._readPredicateAfterVerb;case"inversePredicate":return this._inversePredicate=!0,this._readPredicateAfterVerb;case".":case"]":case"}":case"|}":return this._predicate===null&&!this._n3Mode?this._error(`Unexpected ${n}`,t):(this._subject=null,n==="]"?this._readBlankNodeTail(t):this._readPunctuation(t));case";":return this._predicate!==null?this._readPredicate:this._error("Expected predicate but got ;",t);case"literal":if(!this._n3Mode)return this._error("Unexpected literal",t);if(t.prefix.length===0)return this._literalValue=t.value,this._completePredicateLiteral;this._predicate=this._factory.literal(t.value,this._factory.namedNode(t.prefix)),r=!0;break;case"(":return this._n3Mode?this._readList(t,this._subject,this.RDF_NIL,null):this._error(`Expected entity but got ${n}`,t);case"[":return this._n3Mode?(this._saveContext("blank",this._graph,this._subject,this._subject=this._factory.blankNode(),null),this._readBlankNodeHead):this._error("Disallowed blank node as predicate",t);case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._subject,this._graph=this._factory.blankNode(),null),this._readSubject):this._readEntity(t);case"blank":if(!this._n3Mode)return this._error("Disallowed blank node as predicate",t);default:if((this._predicate=this._readEntity(t))===void 0)return;r=this._n3Mode}return this._validAnnotation=!0,r?this._getPathReader(this._readObject,"predicate"):this._readObject}_readPredicateAfterVerb(t){return t.type==="has"||t.type==="is"||t.type==="of"||t.type==="inversePredicate"?this._error(`Expected expression but got ${t.type}`,t):this._readPredicate(t)}_readObject(t){if(this._expectOf)return t.type!=="of"?this._error(`Expected of but got ${t.type}`,t):(this._expectOf=!1,this._readObject);switch(t.type){case"literal":if(t.prefix.length===0)return this._literalValue=t.value,this._readDataTypeOrLang;if(this._object=this._factory.literal(t.value,this._factory.namedNode(t.prefix)),this._n3Mode)return this._getPathReader(this._getContextEndReader());break;case"[":return this._saveContext("blank",this._graph,this._subject,this._predicate,this._subject=this._factory.blankNode()),this._readBlankNodeHead;case"(":return this._readList(t,this._subject,this._predicate,this.RDF_NIL);case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._subject,this._predicate,this._graph=this._factory.blankNode()),this._readInFormulaContext):this._error("Unexpected graph",t);case"<<(":return this._saveContext("<<(",this._graph,this._subject,this._predicate,null),this._graph=null,this._readSubject;case"<<":return this._saveContext("<<",this._graph,this._subject,this._predicate,null),this._graph=null,this._readSubject;default:if((this._object=this._readEntity(t))===void 0)return;if(this._n3Mode)return this._getPathReader(this._getContextEndReader())}return this._getContextEndReader()}_readPredicateOrNamedGraph(t){return t.type==="{"?this._readGraph(t):this._readPredicate(t)}_readGraph(t){return t.type!=="{"?this._error(`Expected graph but got ${t.type}`,t):(this._graph=this._subject,this._subject=null,this._readSubject)}_readBlankNodeHead(t){if(t.type==="]")return this._subject=null,this._readBlankNodeTail(t);{let n=this._contextStack;return(n.length>1&&n[n.length-2]).type==="<<"?this._error("Unexpected compound blank node expression in reified triple",t):t.type==="id"?this._readIriPropertyListId:(this._predicate=null,this._readPredicate(t))}}_readIriPropertyListId(t){let n=this._readEntity(t);if(n===void 0)return;if(n.termType!=="NamedNode")return this._error(`Expected IRI after id but got ${t.type}`,t);let r=this._subject;this._subject=n;let i=this._contextStack[this._contextStack.length-1];return i.subject===r&&(i.subject=n),i.predicate===r&&(i.predicate=n),i.object===r&&(i.object=n),this._predicate=null,this._readIriPropertyListPredicate}_readIriPropertyListPredicate(t){return t.type===";"||t.type==="]"||t.type==="."||t.type==="}"?this._error(`Expected predicate but got ${t.type}`,t):this._readPredicate(t)}_readBlankNodeTail(t){if(t.type!=="]")return this._readBlankNodePunctuation(t);this._subject!==null&&this._emitCurrent(this._subject,this._predicate,this._object,this._graph);let n=this._predicate===null;return this._restoreContext("blank",t),this._object!==null?this._getContextEndReader():this._predicate!==null?this._getPathReader(this._readObject,"predicate"):n?this._readPredicateOrNamedGraph:this._readPredicateAfterBlank}_readPredicateAfterBlank(t){switch(t.type){case".":case"}":return this._subject=null,this._readPunctuation(t);default:return this._readPredicate(t)}}_readListItem(t){let n=null,r=null,i=this._readListItem,s=this._subject,o=this._contextStack,a=o[o.length-1];switch(t.type){case"[":this._saveContext("blank",this._graph,r=this._factory.blankNode(),this.RDF_FIRST,this._subject=n=this._factory.blankNode()),i=this._readBlankNodeHead;break;case"(":this._saveContext("list",this._graph,r=this._factory.blankNode(),this.RDF_FIRST,this.RDF_NIL),this._subject=null;break;case")":if(this._restoreContext("list",t),o.length!==0&&o[o.length-1].type==="list"){if(this._n3Mode)return s!==null&&this._emit(s,this.RDF_REST,this.RDF_NIL,this._graph),this._saveContext("item",this._graph,this._subject,this._predicate,this._object),this._subject=this._object,this._predicate=null,this._getPathReader(this._readListItem);this._emit(this._subject,this._predicate,this._object,this._graph)}if(this._predicate===null){if(i=this._n3Mode?this._getPathReader(this._readPredicate):this._readPredicate,this._subject===this.RDF_NIL)return i}else if(this._object===null){if(i=this._getPathReader(this._readObject,"predicate"),this._predicate===this.RDF_NIL)return i}else if(i=this._getContextEndReader(),this._n3Mode&&(i=this._getPathReader(i)),this._object===this.RDF_NIL)return i;r=this.RDF_NIL;break;case"literal":t.prefix.length===0?(this._literalValue=t.value,i=this._readListItemDataTypeOrLang):(n=this._factory.literal(t.value,this._factory.namedNode(t.prefix)),i=this._getContextEndReader());break;case"{":return this._n3Mode?(r=this._factory.blankNode(),n=this._factory.blankNode(),s===null?a.predicate===null?a.subject=r:a.object=r:this._emit(s,this.RDF_REST,r,this._graph),this._emit(r,this.RDF_FIRST,n,this._graph),this._saveContext("formula",this._graph,r,this.RDF_FIRST,this._graph=n),this._subject=null,this._readInFormulaContext):this._error("Unexpected graph",t);case"<<(":this._saveContext("<<(",this._graph,null,null,null),this._graph=null,i=this._readSubject;break;case"<<":this._saveContext("<<",this._graph,null,null,null),this._graph=null,i=this._readSubject;break;default:if((n=this._readEntity(t))===void 0)return}if(r===null&&(this._subject=r=this._factory.blankNode()),(t.type==="<<"||t.type==="<<(")&&(o[o.length-1].subject=this._subject),s===null?a.predicate===null?a.subject=r:a.object===null?a.predicate=r:a.object=r:this._emit(s,this.RDF_REST,r,this._graph),n!==null){if(this._n3Mode&&(t.type==="IRI"||t.type==="prefixed"||t.type==="var"||t.type==="blank"||t.type==="literal"))return this._saveContext("item",this._graph,r,this.RDF_FIRST,n),this._subject=n,this._predicate=null,this._getPathReader(this._readListItem);this._emit(r,this.RDF_FIRST,n,this._graph)}return i}_readDataTypeOrLang(t){return this._completeObjectLiteral(t,!1)}_readListItemDataTypeOrLang(t){return this._completeObjectLiteral(t,!0)}_completeLiteral(t,n){let r,i=!1;switch(t.type){case"type":case"typeIRI":let s=this._readEntity(t);if(s===void 0)return;if(s.value===br.rdf.langString||s.value===br.rdf.dirLangString)return this._error("Detected illegal (directional) languaged-tagged string with explicit datatype",t);r=this._factory.literal(this._literalValue,s),t=null;break;case"langcode":if(t.value.split("-").some((o)=>o.length>8))return this._error("Detected language tag with subtag longer than 8 characters",t);r=this._factory.literal(this._literalValue,t.value),this._literalLanguage=t.value,t=null,this._literalComponent=n,i=!0;break;default:r=this._factory.literal(this._literalValue)}return{token:t,literal:r,readCb:i}}_readDirCode(t){let n=this._literalComponent,r=this._literalListItem;if(t.type==="dircode"){let i=this._factory.literal(this._literalValue,{language:this._literalLanguage,direction:t.value});n==="subject"?this._subject=i:n==="predicate"?this._predicate=i:this._object=i,this._literalLanguage=void 0,t=null}if(n==="subject"||n==="predicate"){let i=n==="subject"?this._readPredicateOrNamedGraph:this._readObject;return this._getPathEndReader(t,i,n)||i.call(this,t)}return this._completeObjectLiteralPost(t,r)}_completeTermLiteral(t,n){let r=this._completeLiteral(t,n);if(!r)return;let i;if(n==="subject"?(this._subject=r.literal,i=this._readPredicateOrNamedGraph):(this._predicate=r.literal,this._validAnnotation=!0,i=this._readObject),r.readCb)return this._literalListItem=!1,this._readDirCode;return this._getPathEndReader(r.token,i,n)||i.call(this,r.token)}_completeSubjectLiteral(t){return this._completeTermLiteral(t,"subject")}_completePredicateLiteral(t){return this._completeTermLiteral(t,"predicate")}_completeObjectLiteral(t,n){let r=this._completeLiteral(t,"object");if(r)return this._object=r.literal,r.readCb?(this._literalListItem=n,this._readDirCode):this._completeObjectLiteralPost(r.token,n)}_completeObjectLiteralPost(t,n){return this._n3Mode&&(t===null||t.type==="!"||t.type==="^")?n?(this._saveContext("item",this._graph,this._subject,this.RDF_FIRST,this._object),this._subject=this._object,this._predicate=null,this._getPathEndReader(t,this._readListItem)):this._getPathEndReader(t,this._getContextEndReader()):(n&&this._emit(this._subject,this.RDF_FIRST,this._object,this._graph),t===null?this._getContextEndReader():(this._readCallback=this._getContextEndReader(),this._readCallback(t)))}_readFormulaTail(t){if(t.type!=="}")return this._readPunctuation(t);this._subject!==null&&this._emitCurrent(this._subject,this._predicate,this._object,this._graph);let n=this._graph,r=this._emptyFormula;return this._restoreContext("formula",t),r&&this._emptyFormulaAsTrue&&(this._subject===n?this._subject=this.N3_TRUE:this._predicate===n?this._predicate=this.N3_TRUE:this._object=this.N3_TRUE),this._object!==null?this._getPathReader(this._getContextEndReader(),"object"):this._predicate!==null?this._getPathReader(this._readObject,"predicate"):this._getPathReader(this._readPredicate,"subject")}_readPunctuation(t){let n,r=this._graph,i=!1,s=this._subject,o=this._inversePredicate;switch(t.type){case"}":if(this._graph===null)return this._error("Unexpected graph closing",t);if(this._n3Mode)return this._readFormulaTail(t);this._graph=null;case".":this._subject=null,this._tripleTerm=null,n=this._getStatementReader(),o&&(this._inversePredicate=!1);break;case";":o&&(this._inversePredicate=!1),n=this._readPredicate;break;case",":n=this._readObject;break;case"~":s!==null&&(this._tripleTerm=null),n=this._readReifierInAnnotation,i=!0;break;case"{|":s!==null&&(this._tripleTerm=null),this._subject=this._readTripleTerm(),this._inversePredicate=!1,this._validAnnotation=!1,i=!0,n=this._readPredicate;break;case"|}":if(!this._annotation)return this._error("Unexpected annotation syntax closing",t);if(!this._validAnnotation)return this._error("Annotation block can not be empty",t);this._subject=null,this._annotation=!1,this._inversePredicate=!1,n=this._getContextEndReader();break;default:if(this._supportsQuads&&this._graph===null&&(r=this._readEntity(t))!==void 0){n=this._readQuadPunctuation;break}return this._error(`Expected punctuation to follow "${this._object.id}"`,t)}if(s!==null&&(!i||i&&!this._annotation)){let a=this._predicate,l=this._object;this._emit(s,a,l,r,o)}return i&&(this._annotation=!0),n}_readBlankNodePunctuation(t){let n,r=!1;switch(t.type){case";":r=this._inversePredicate,n=this._readPredicate;break;case",":n=this._readObject;break;case"~":case"{|":case"|}":return this._readPunctuation(t);default:return this._error(`Expected punctuation to follow "${this._object.id}"`,t)}return this._subject===null?this._error("Expected ] to follow annotation",t):(this._emitCurrent(this._subject,this._predicate,this._object,this._graph),r&&(this._inversePredicate=!1),n)}_readQuadPunctuation(t){return t.type!=="."?this._error("Expected dot to follow quad",t):this._readInTopContext}_readPrefix(t){return t.type!=="prefix"?this._error("Expected prefix to follow @prefix",t):(this._prefix=t.value,this._readPrefixIRI)}_readPrefixIRI(t){if(t.type!=="IRI")return this._error(`Expected IRI to follow prefix "${this._prefix}:"`,t);let n=this._readEntity(t);return this._prefixes[this._prefix]=n.value,this._prefixCallback(this._prefix,n),this._readDeclarationPunctuation}_readBaseIRI(t){let n=t.type==="IRI"&&this._resolveIRI(t.value);return n?(this._setBase(n),this._readDeclarationPunctuation):this._error("Expected valid IRI to follow base declaration",t)}_isValidVersion(t){return this._parseUnsupportedVersions||e.SUPPORTED_VERSIONS.includes(t)}_readVersion(t){return t.type!=="literal"?this._error("Expected literal to follow version declaration",t):t.end-t.start!==t.value.length+2?this._error("Version declarations must use single quotes",t):(this._versionCallback(t.value),this._isValidVersion(t.value)?this._readDeclarationPunctuation:this._error(`Detected unsupported version: "${t.value}"`,t))}_readNamedGraphLabel(t){switch(t.type){case"IRI":case"blank":case"prefixed":return this._readSubject(t),this._readGraph;case"[":return this._readNamedGraphBlankLabel;default:return this._error("Invalid graph label",t)}}_readNamedGraphBlankLabel(t){return t.type!=="]"?this._error("Invalid graph label",t):(this._subject=this._factory.blankNode(),this._readGraph)}_readDeclarationPunctuation(t){return this._sparqlStyle?(this._sparqlStyle=!1,this._getStatementReader().call(this,t)):t.type!=="."?this._error("Expected declaration to end with a dot",t):this._getStatementReader()}_readQuantifierList(t){let n;switch(t.type){case"IRI":case"prefixed":if((n=this._readEntity(t,!0))!==void 0)break;default:return this._error(`Unexpected ${t.type}`,t)}return this._explicitQuantifiers?(this._subject===null?this._emit(this._graph||this.DEFAULTGRAPH,this._predicate,this._subject=this._factory.blankNode(),this.QUANTIFIERS_GRAPH):this._emit(this._subject,this.RDF_REST,this._subject=this._factory.blankNode(),this.QUANTIFIERS_GRAPH),this._emit(this._subject,this.RDF_FIRST,n,this.QUANTIFIERS_GRAPH)):this._quantified[n.id]=this._factory[this._quantifier](this._factory.blankNode().value),this._readQuantifierPunctuation}_readQuantifierPunctuation(t){return t.type===","?this._readQuantifierList:(this._explicitQuantifiers&&(this._emit(this._subject,this.RDF_REST,this.RDF_NIL,this.QUANTIFIERS_GRAPH),this._subject=null),this._readCallback=this._getContextEndReader(),this._readCallback(t))}_getPathReader(t,n){return this._afterPath=t,this._pathPosition=n||(this._predicate===null?"subject":"object"),this._readPath}_getPathEndReader(t,n,r){if(t!==null&&t.type!=="!"&&t.type!=="^")return null;let i=this._getPathReader(n,r);return t===null?i:i.call(this,t)}_readPath(t){switch(t.type){case"!":return this._readForwardPath;case"^":return this._readBackwardPath;default:let n=this._afterPath,r=this._contextStack,i=r.length&&r[r.length-1];if(i&&i.type==="item"){let s=this._subject;this._restoreContext("item",t),this._emit(this._subject,this.RDF_FIRST,s,this._graph)}return this._afterPath=null,this._pathPosition=null,n.call(this,t)}}_readForwardPath(t){let n,r,i=this._factory.blankNode();if((r=this._readEntity(t))!==void 0)return this._pathPosition==="subject"?(n=this._subject,this._subject=i):this._pathPosition==="predicate"?(n=this._predicate,this._predicate=i):(n=this._object,this._object=i),this._emit(n,r,i,this._graph),this._readPath}_readBackwardPath(t){let n=this._factory.blankNode(),r,i;if((r=this._readEntity(t))!==void 0)return this._pathPosition==="subject"?(i=this._subject,this._subject=n):this._pathPosition==="predicate"?(i=this._predicate,this._predicate=n):(i=this._object,this._object=n),this._emit(n,r,i,this._graph),this._readPath}_readTripleTermTail(t){if(t.type!==")>>")return this._error(`Expected )>> but got ${t.type}`,t);let n=this._createQuad(this._subject,this._predicate,this._object,this._graph,this._inversePredicate);this._restoreContext("<<(",t);let r=this._contextStack,i=r.length&&r[r.length-1];return i&&i.type==="list"?(this._emit(this._subject,this.RDF_FIRST,n,this._graph),this._getContextEndReader()):this._subject===null?(this._subject=n,this._readPredicate):(this._object=n,this._getContextEndReader())}_readReifiedTripleTailOrReifier(t){return t.type==="~"?this._readReifier:this._readReifiedTripleTail(t)}_readReifiedTripleTail(t){if(t.type!==">>")return this._error(`Expected >> but got ${t.type}`,t);this._tripleTerm=null;let n=this._readTripleTerm();this._restoreContext("<<",t);let r=this._contextStack,i=r.length&&r[r.length-1];return i&&i.type==="list"?(this._emit(this._subject,this.RDF_FIRST,n,this._graph),this._getContextEndReader()):this._subject===null?(this._subject=n,this._readPredicateOrReifierTripleEnd):(this._object=n,this._getContextEndReader())}_readPredicateOrReifierTripleEnd(t){return t.type==="."?(this._subject=null,this._readPunctuation(t)):this._readPredicate(t)}_readReifier(t){return this._reifier=this._readEntity(t),this._readReifiedTripleTail}_readReifierInAnnotation(t){return t.type==="IRI"||t.type==="typeIRI"||t.type==="type"||t.type==="prefixed"||t.type==="blank"||t.type==="var"?(this._reifier=this._readEntity(t),this._readAnnotationBlockOrPunctuation):(this._readTripleTerm(),this._subject=null,this._getContextEndReader().call(this,t))}_readAnnotationBlockOrPunctuation(t){if(t.type==="{|")return this._readPunctuation(t);switch(this._readTripleTerm(),this._annotation=!1,this._tripleTerm=null,t.type){case";":return this._inversePredicate=!1,this._readPredicate;case",":return this._readObject;default:return this._subject=null,this._getContextEndReader().call(this,t)}}_readTripleTerm(){let t=this._contextStack,n=t.length&&t[t.length-1],r=n?n.graph:void 0,i=this._reifier||this._factory.blankNode();return this._reifier=null,this._tripleTerm=this._tripleTerm||this._createQuad(this._subject,this._predicate,this._object,null,this._inversePredicate),this._emit(i,this.RDF_REIFIES,this._tripleTerm,r||this._graph||this.DEFAULTGRAPH),i}_getContextEndReader(){let t=this._contextStack;if(!t.length)return this._readPunctuation;switch(t[t.length-1].type){case"blank":return this._readBlankNodeTail;case"list":return this._readListItem;case"formula":return this._readFormulaTail;case"<<(":return this._readTripleTermTail;case"<<":return this._readReifiedTripleTailOrReifier}}_createQuad(t,n,r,i){return this._factory.quad(t,n,r,i||this.DEFAULTGRAPH)}_createQuadInDirection(t,n,r,i,s){return s?this._factory.quad(r,n,t,i||this.DEFAULTGRAPH):this._factory.quad(t,n,r,i||this.DEFAULTGRAPH)}_emitInDirection(t,n,r,i,s){this._callback(null,this._createQuad(t,n,r,i,s))}_emitCurrentInDirection(t,n,r,i){this._callback(null,this._createQuad(t,n,r,i,this._inversePredicate))}_emit(t,n,r,i){this._callback(null,this._factory.quad(t,n,r,i||this.DEFAULTGRAPH))}_error(t,n){let r=` on line ${n.line}.`;t.length+r.length>200&&(t=`${t.slice(0,199-r.length)}…`);let i=Error(`${t}${r}`);i.context={token:n,line:n.line,previousToken:this._lexer.previousToken},this._callback(i),this._callback=r_}_resolveIRI(t){return/^[a-z][a-z0-9+.-]*:/i.test(t)?t:this._resolveRelativeIRI(t)}_resolveRelativeIRI(t){if(!t.length)return this._base;switch(t[0]){case"#":return this._base+t;case"?":return this._base.replace(/(?:\?.*)?$/,t);case"/":return(t[1]==="/"?this._baseScheme:this._baseRoot)+this._removeDotSegments(t);default:return/^[^/:]*:/.test(t)?null:this._removeDotSegments(this._basePath+t)}}_removeDotSegments(t){if(!/(^|\/)\.\.?($|[/#?])/.test(t))return t;let n=t.length,r="",i=-1,s=-1,o=0,a="/";for(;i=s&&(r=r.substr(0,o)),a!=="/")return`${r}/${t.substr(i+1)}`;o=i+1}}}a=t[++i]}return r+t.substring(o)}parse(t,n,r,i){let s,o,a,l;if(n&&(n.onQuad||n.onPrefix||n.onComment||n.onVersion)?(s=n.onQuad,o=n.onPrefix,a=n.onComment,l=n.onVersion):(s=n,o=r,l=i),this._readCallback=this._readBeforeTopContext,this._sparqlStyle=!1,this._prefixes=Object.create(null),this._prefixes._=this._blankNodePrefix?this._blankNodePrefix.substr(2):`b${_ae++}_`,this._n3Mode&&this._implicitEmptyPrefix&&this._base&&(this._prefixes[""]=this._resolveIRI("#")),this._prefixCallback=o||r_,this._versionCallback=l||r_,this._inversePredicate=!1,this._expectOf=!1,this._quantified=Object.create(null),this._emptyFormula=!1,!s){let u=[],p;if(this._callback=(d,f)=>{d?p=d:f&&u.push(f)},this._lexer.tokenize(t).every((d)=>this._readCallback=this._readCallback(d)),p)throw p;return u}let c=(u,p)=>{u!==null?(this._callback(u),this._callback=r_):this._readCallback&&(this._readCallback=this._readCallback(p))};a&&(this._lexer.comments=!0,c=(u,p)=>{u!==null?(this._callback(u),this._callback=r_):this._readCallback&&(p.type==="comment"?a(p.value):this._readCallback=this._readCallback(p))}),this._callback=s,this._lexer.tokenize(t,c)}};function r_(){}function Uae(e,t){e._factory=t,e.DEFAULTGRAPH=t.defaultGraph(),e.RDF_FIRST=t.namedNode(br.rdf.first),e.RDF_REST=t.namedNode(br.rdf.rest),e.RDF_NIL=t.namedNode(br.rdf.nil),e.RDF_REIFIES=t.namedNode(br.rdf.reifies),e.N3_FORALL=t.namedNode(br.r.forAll),e.N3_FORSOME=t.namedNode(br.r.forSome),e.N3_TRUE=t.literal("true",t.namedNode(br.xsd.boolean)),e.ABBREVIATIONS={a:t.namedNode(br.rdf.type),"=":t.namedNode(br.owl.sameAs),">":t.namedNode(br.log.implies),"<":t.namedNode(br.log.isImpliedBy)},e.QUANTIFIERS_GRAPH=t.namedNode("urn:n3:quantifiers")}p_.SUPPORTED_VERSIONS=["1.2","1.2-basic","1.1"];Uae(p_.prototype,os);var EVe={};iVe(EVe,{inDefaultGraph:()=>IVe,isBlankNode:()=>NVe,isDefaultGraph:()=>Df,isLiteral:()=>OVe,isNamedNode:()=>kVe,isQuad:()=>$Ve,isVariable:()=>PVe,prefix:()=>AVe,prefixes:()=>Bae});function kVe(e){return!!e&&e.termType==="NamedNode"}function NVe(e){return!!e&&e.termType==="BlankNode"}function OVe(e){return!!e&&e.termType==="Literal"}function PVe(e){return!!e&&e.termType==="Variable"}function $Ve(e){return!!e&&e.termType==="Quad"}function Df(e){return!!e&&e.termType==="DefaultGraph"}function IVe(e){return Df(e.graph)}function AVe(e,t){return Bae({"":e.value||e},t)("")}function Bae(e,t){let n=Object.create(null);for(let i in e)r(i,e[i]);t=t||os;function r(i,s){if(typeof s=="string"){let o=Object.create(null);n[i]=(a)=>o[a]||(o[a]=t.namedNode(s+a))}else if(!(i in n))throw Error(`Unknown prefix: ${i}`);return n[i]}return r}function XS(e){return e.replace(/[\]\/\(\)\*\+\?\.\\\$]/g,"\\$&")}var RVe=/^:?[^:?#]*(?:[?#]|$)|^file:|^[^:]*:\/*[^?#]+?\/(?:\.\.?(?:\/|$)|\/)/i,jVe=/^(?:(?:[^/?#]{3,}|\.?[^/?#.]\.?)(?:\/[^/?#]{3,}|\.?[^/?#.]\.?)*\/?)?(?:[?#]|$)/,xae="./",FVe="../",sC="?",wae="#",CVe=class e{constructor(t){this.base=t,this._baseLength=0,this._baseMatcher=null,this._pathReplacements=Array(t.length+1)}static supports(t){return!RVe.test(t)}_getBaseMatcher(){if(this._baseMatcher)return this._baseMatcher;if(!e.supports(this.base))return this._baseMatcher=/.^/;let t=/^[^:]*:\/*/.exec(this.base)[0],n=["^",XS(t)],r=[],i=[],s=/[^/?#]*([/?#])/y,o,a=0,l=0,c=s.lastIndex=t.length;for(;!a&&!l&&(o=s.exec(this.base));)o[1]===wae?l=s.lastIndex-1:(n.push(XS(o[0]),"(?:"),r.push(")?"),o[1]!==sC?i.push(c=s.lastIndex):(a=c=s.lastIndex,l=this.base.indexOf(wae,a),this._pathReplacements[a]=sC));for(let u=0;u0?l:this.base.length,n.push(XS(this.base.substring(c,this._baseLength)),a?"(?:#|$)":"(?:[?#]|$)"),this._baseMatcher=new RegExp([...n,...r].join(""))}toRelative(t){let n=this._getBaseMatcher().exec(t);if(!n)return t;let r=n[0].length;if(r===this._baseLength&&r===t.length)return"";let i=this._pathReplacements[r];if(i){let s=t.substring(r);return i!==sC&&!jVe.test(s)?t:i===xae&&/^[^?#]/.test(s)?s:i+s}return t.substring(r-1)}},i_=os.defaultGraph(),{rdf:MVe,xsd:Yy}=br,Dae=/["\\\t\n\r\b\f\u0000-\u0019\ud800-\udbff]/,Tae=/["\\\t\n\r\b\f\u0000-\u0019]|[\ud800-\udbff][\udc00-\udfff]/g,LVe={"\\":"\\\\",'"':"\\\"","\t":"\\t","\n":"\\n","\r":"\\r","\b":"\\b","\f":"\\f"},s_=class extends Vc{equals(e){return e===this}},d_=class{constructor(e,t){if(this._prefixRegex=/$0^/,this._hasPrefixes=!1,e&&typeof e.write!="function"&&(t=e,e=null),t=t||{},this._lists=t.lists,e)this._outputStream=e,this._endStream=t.end===void 0?!0:!!t.end;else{let n="";this._outputStream={write(r,i,s){n+=r,s&&s()},end:(r)=>{r&&r(null,n)}},this._endStream=!0}this._subject=null,/triple|quad/i.test(t.format)?(this._lineMode=!0,this._writeQuad=this._writeQuadLine):(this._lineMode=!1,this._graph=i_,this._prefixIRIs=Object.create(null),t.baseIRI&&(this._baseIri=new CVe(t.baseIRI),t.writeBase&&this._write(`@base <${t.baseIRI}>. `)),t.prefixes&&this.addPrefixes(t.prefixes))}get _inDefaultGraph(){return i_.equals(this._graph)}_write(e,t){this._outputStream.write(e,"utf8",t)}_writeQuad(e,t,n,r,i){try{r!==this._graph&&(!r.equals(this._graph)||r.termType!==this._graph.termType)&&(this._write((this._subject===null?"":this._inDefaultGraph?`. `:` } `)+(i_.equals(r)?"":`${this._encodeIriOrBlank(r)} { `)),this._graph=r,this._subject=null),e===this._subject||e.equals(this._subject)?t===this._predicate||t.equals(this._predicate)?this._write(`, ${this._encodeObject(n)}`,i):this._write(`; ${this._encodePredicate(this._predicate=t)} ${this._encodeObject(n)}`,i):this._write(`${(this._subject===null?"":`. -`)+this._encodeSubject(this._subject=e)} ${this._encodePredicate(this._predicate=t)} ${this._encodeObject(n)}`,i)}catch(s){i&&i(s)}}_writeQuadLine(e,t,n,r,i){delete this._prefixMatch,this._write(this.quadToString(e,t,n,r),i)}quadToString(e,t,n,r){return`${this._encodeSubject(e)} ${this._encodeIriOrBlank(t)} ${this._encodeObject(n)}${r&&!xf(r)?` ${this._encodeIriOrBlank(r)} . +`)+this._encodeSubject(this._subject=e)} ${this._encodePredicate(this._predicate=t)} ${this._encodeObject(n)}`,i)}catch(s){i&&i(s)}}_writeQuadLine(e,t,n,r,i){delete this._prefixMatch,this._write(this.quadToString(e,t,n,r),i)}quadToString(e,t,n,r){return`${this._encodeSubject(e)} ${this._encodeIriOrBlank(t)} ${this._encodeObject(n)}${r&&!Df(r)?` ${this._encodeIriOrBlank(r)} . `:` . -`}`}quadsToString(e){let t="";for(let n of e)t+=this.quadToString(n.subject,n.predicate,n.object,n.graph);return t}_encodeSubject(e){return e.termType==="Quad"?this._encodeQuad(e):this._encodeIriOrBlank(e)}_encodeIriOrBlank(e){if(e.termType!=="NamedNode")return this._lists&&e.value in this._lists&&(e=this.list(this._lists[e.value])),e.termType==="Variable"?`?${e.value}`:("id"in e)?e.id:`_:${e.value}`;let t=e.value;this._baseIri&&(t=this._baseIri.toRelative(t)),Dae.test(t)&&(t=t.replace(Tae,Sae));let n=this._hasPrefixes?this._prefixRegex.exec(t):null;return n?n[1]?this._prefixIRIs[n[1]]+n[2]:t:`<${t}>`}_encodeLiteral(e){let t=e.value;Dae.test(t)&&(t=t.replace(Tae,Sae));let n=e.language;if(n){let r=e.direction,i=r?`--${r}`:"";return`"${t}"@${n}${i}`}if(this._lineMode){if(e.datatype.value===Wy.string)return`"${t}"`}else switch(e.datatype.value){case Wy.string:return`"${t}"`;case Wy.boolean:if(t==="true"||t==="false")return t;break;case Wy.integer:if(/^[+-]?\d+$/.test(t))return t;break;case Wy.decimal:if(/^[+-]?\d*\.\d+$/.test(t))return t;break;case Wy.double:if(/^[+-]?(?:\d+\.\d*|\.?\d+)[eE][+-]?\d+$/.test(t))return t;break}return`"${t}"^^${this._encodeIriOrBlank(e.datatype)}`}_encodePredicate(e){return e.value===CVe.type?"a":this._encodeIriOrBlank(e)}_encodeObject(e){switch(e.termType){case"Quad":return this._encodeQuad(e);case"Literal":return this._encodeLiteral(e);default:return this._encodeIriOrBlank(e)}}_encodeQuad({subject:e,predicate:t,object:n,graph:r}){return`<<(${this._encodeSubject(e)} ${this._encodePredicate(t)} ${this._encodeObject(n)}${xf(r)?"":` ${this._encodeIriOrBlank(r)}`})>>`}_blockedWrite(){throw Error("Cannot write because the writer has been closed.")}addQuad(e,t,n,r,i){n===void 0?this._writeQuad(e.subject,e.predicate,e.object,e.graph,t):typeof r=="function"?this._writeQuad(e,t,n,i_,r):this._writeQuad(e,t,n,r||i_,i)}addQuads(e){for(let t=0;t`}_encodeLiteral(e){let t=e.value;Dae.test(t)&&(t=t.replace(Tae,Sae));let n=e.language;if(n){let r=e.direction,i=r?`--${r}`:"";return`"${t}"@${n}${i}`}if(this._lineMode){if(e.datatype.value===Yy.string)return`"${t}"`}else switch(e.datatype.value){case Yy.string:return`"${t}"`;case Yy.boolean:if(t==="true"||t==="false")return t;break;case Yy.integer:if(/^[+-]?\d+$/.test(t))return t;break;case Yy.decimal:if(/^[+-]?\d*\.\d+$/.test(t))return t;break;case Yy.double:if(/^[+-]?(?:\d+\.\d*|\.?\d+)[eE][+-]?\d+$/.test(t))return t;break}return`"${t}"^^${this._encodeIriOrBlank(e.datatype)}`}_encodePredicate(e){return e.value===MVe.type?"a":this._encodeIriOrBlank(e)}_encodeObject(e){switch(e.termType){case"Quad":return this._encodeQuad(e);case"Literal":return this._encodeLiteral(e);default:return this._encodeIriOrBlank(e)}}_encodeQuad({subject:e,predicate:t,object:n,graph:r}){return`<<(${this._encodeSubject(e)} ${this._encodePredicate(t)} ${this._encodeObject(n)}${Df(r)?"":` ${this._encodeIriOrBlank(r)}`})>>`}_blockedWrite(){throw Error("Cannot write because the writer has been closed.")}addQuad(e,t,n,r,i){n===void 0?this._writeQuad(e.subject,e.predicate,e.object,e.graph,t):typeof r=="function"?this._writeQuad(e,t,n,i_,r):this._writeQuad(e,t,n,r||i_,i)}addQuads(e){for(let t=0;t. @@ -4352,7 +4352,7 @@ Enum bindings allow enums to be bound to any object, including complex nested ob ]`)}}list(e){let t=e&&e.length||0,n=Array(t);for(let r=0;r{t=null,e(n,r)});if(this._endStream)try{return this._outputStream.end(t)}catch(n){}t&&t()}};function Sae(e){let t=MVe[e];return t===void 0&&(e.length===1?(t=e.charCodeAt(0).toString(16),t="\\u0000".substr(0,6-t.length)+t):(t=((e.charCodeAt(0)-55296)*1024+e.charCodeAt(1)+9216).toString(16),t="\\U00000000".substr(0,10-t.length)+t)),t}var Vae=tE(dC()),oC=Symbol("iter"),sr=Symbol("size");function LVe(e,t,n,r){let i=e&&e[t],s=i&&i[n];return!!s&&r in s}function Zy(e,t,n=4){let r=e[sr]||0;for(let i in t)i in e?n!==0&&(e[i]=Zy(e[i],t[i],n-1)):(r++,e[i]=n===0?null:Zy(Object.create(null),t[i],n-1));return n<=2&&(e[sr]=r),e}function Kae(e,t,n=4){let r=!1,i=0;n<=2&&t[sr]{r in n||(n[r]=!0,t(this._termFromId(this._entities[r],this._factory)))}}add(t){return this.addQuad(t),this}addQuad(t,n,r,i){n||(i=t.graph,r=t.object,n=t.predicate,t=t.subject),i=i?this._termToNewNumericId(i):1;let s=this._graphs[i];return s||(s=this._graphs[i]={subjects:{[sr]:0},predicates:{[sr]:0},objects:{[sr]:0}},Object.freeze(s)),t=this._termToNewNumericId(t),n=this._termToNewNumericId(n),r=this._termToNewNumericId(r),this._addToIndex(s.subjects,t,n,r)?(this._addToIndex(s.predicates,n,r,t),this._addToIndex(s.objects,r,t,n),this._size=null,!0):!1}addQuads(t){for(let n=0;n{this.addQuad(n)}),t}removeQuad(t,n,r,i){n||({subject:t,predicate:n,object:r,graph:i}=t),i=i?this._termToNumericId(i):1;let s=this._graphs,o,a,l;return!(t=t&&this._termToNumericId(t))||!(n=n&&this._termToNumericId(n))||!(r=r&&this._termToNumericId(r))||!(o=s[i])||!(a=o.subjects[t])||!(l=a[n])||!(r in l)?!1:(this._removeFromIndex(o.subjects,t,n,r),this._removeFromIndex(o.predicates,n,r,t),this._removeFromIndex(o.objects,r,t,n),this._size!==null&&this._size--,o.subjects[sr]===0&&delete s[i],!0)}removeQuads(t){for(let n=0;n{this.removeQuad(n)}),t}removeMatches(t,n,r,i){let s=new Vae.Readable({objectMode:!0}),o=this.readQuads(t,n,r,i);return s._read=(a)=>{for(;--a>=0;){let{done:l,value:c}=o.next();if(l){s.push(null);return}s.push(c)}},this.remove(s)}deleteGraph(t){return this.removeMatches(null,null,null,t)}getQuads(t,n,r,i){return[...this.readQuads(t,n,r,i)]}*readQuads(t,n,r,i){let s=this._getGraphs(i),o,a,l,c;if(!(t&&!(a=this._termToNumericId(t))||n&&!(l=this._termToNumericId(n))||r&&!(c=this._termToNumericId(r))))for(let u in s)(o=s[u])&&(a?c?yield*_f(this._findInIndex(o.objects,c,a,l,"object","subject","predicate",u)):yield*_f(this._findInIndex(o.subjects,a,l,null,"subject","predicate","object",u)):l?yield*_f(this._findInIndex(o.predicates,l,c,null,"predicate","object","subject",u)):c?yield*_f(this._findInIndex(o.objects,c,null,null,"object","subject","predicate",u)):yield*_f(this._findInIndex(o.subjects,null,null,null,"subject","predicate","object",u)))}match(t,n,r,i){return new Qy(this,t,n,r,i,{entityIndex:this._entityIndex})}countQuads(t,n,r,i){let s=this._getGraphs(i),o=0,a,l,c,u;if(t&&!(l=this._termToNumericId(t))||n&&!(c=this._termToNumericId(n))||r&&!(u=this._termToNumericId(r)))return 0;for(let p in s)(a=s[p])&&(t?r?o+=this._countInIndex(a.objects,u,l,c):o+=this._countInIndex(a.subjects,l,c,u):n?o+=this._countInIndex(a.predicates,c,u,l):o+=this._countInIndex(a.objects,u,l,c));return o}forEach(t,n,r,i,s){this.some((o)=>(t(o,this),!1),n,r,i,s)}every(t,n,r,i,s){return!this.some((o)=>!t(o,this),n,r,i,s)}some(t,n,r,i,s){for(let o of this.readQuads(n,r,i,s))if(t(o,this))return!0;return!1}getSubjects(t,n,r){let i=[];return this.forSubjects((s)=>{i.push(s)},t,n,r),i}forSubjects(t,n,r,i){let s=this._getGraphs(i),o,a,l;if(t=this._uniqueEntities(t),!(n&&!(a=this._termToNumericId(n))||r&&!(l=this._termToNumericId(r))))for(i in s)(o=s[i])&&(a?l?this._loopBy2Keys(o.predicates,a,l,t):this._loopByKey1(o.subjects,a,t):l?this._loopByKey0(o.objects,l,t):this._loop(o.subjects,t))}getPredicates(t,n,r){let i=[];return this.forPredicates((s)=>{i.push(s)},t,n,r),i}forPredicates(t,n,r,i){let s=this._getGraphs(i),o,a,l;if(t=this._uniqueEntities(t),!(n&&!(a=this._termToNumericId(n))||r&&!(l=this._termToNumericId(r))))for(i in s)(o=s[i])&&(a?l?this._loopBy2Keys(o.objects,l,a,t):this._loopByKey0(o.subjects,a,t):l?this._loopByKey1(o.predicates,l,t):this._loop(o.predicates,t))}getObjects(t,n,r){let i=[];return this.forObjects((s)=>{i.push(s)},t,n,r),i}forObjects(t,n,r,i){let s=this._getGraphs(i),o,a,l;if(t=this._uniqueEntities(t),!(n&&!(a=this._termToNumericId(n))||r&&!(l=this._termToNumericId(r))))for(i in s)(o=s[i])&&(a?l?this._loopBy2Keys(o.subjects,a,l,t):this._loopByKey0Deep(o.subjects,a,t):l?this._loopByKey0(o.predicates,l,t):this._loop(o.objects,t))}getGraphs(t,n,r){let i=[];return this.forGraphs((s)=>{i.push(s)},t,n,r),i}forGraphs(t,n,r,i){for(let s in this._graphs)this.some((o)=>(t(o.graph),!0),n,r,i,this._termFromId(this._entities[s]))}createBlankNode(t){return this._entityIndex.createBlankNode(t)}extractLists({remove:t=!1,ignoreErrors:n=!1}={}){let r=Object.create(null),i=n?()=>!0:(a,l)=>{throw Error(`${a.value} ${l}`)},s=this.getQuads(null,br.rdf.rest,br.rdf.nil,null),o=t?[...s]:[];return s.forEach((a)=>{let l=[],c=!1,u,p,{graph:d,subject:f}=a;for(;f&&!c;){let m=this.getQuads(null,null,f,null),y=this.getQuads(f,null,null,null),h,b=null,g=null,x=null;for(let v=0;vthis.has(c));let n=this._graphs,r=t._graphs,i,s,o,a,l;for(let c in r){if(!(i=n[c]))return!1;i=i.subjects;for(let u in s=r[c].subjects){if(!(o=i[u]))return!1;for(let p in a=s[u]){if(!(l=o[p]))return!1;for(let d in a[p])if(!(d in l))return!1}}}return!0}deleteMatches(t,n,r,i){for(let s of this.match(t,n,r,i))this.removeQuad(s);return this}difference(t){if(t&&t instanceof Qy&&(t=t.filtered),t===this)return new e({entityIndex:this._entityIndex});if(t instanceof e&&t._entityIndex===this._entityIndex){let n=new e({entityIndex:this._entityIndex}),r=Jae(this._graphs,t._graphs);return r&&(n._graphs=r,n._size=null),n}return this.filter((n)=>!t.has(n))}equals(t){return t instanceof Qy&&(t=t.filtered),t===this||this.size===t.size&&this.contains(t)}filter(t){let n=new e({entityIndex:this._entityIndex});for(let r of this)t(r,this)&&n.add(r);return n}intersection(t){if(t instanceof Qy&&(t=t.filtered),t===this){let n=new e({entityIndex:this._entityIndex});return n._graphs=Zy(Object.create(null),this._graphs),n._size=this._size,n}else if(t instanceof e&&this._entityIndex===t._entityIndex){let n=new e({entityIndex:this._entityIndex}),r=Kae(t._graphs,this._graphs);return r&&(n._graphs=r,n._size=null),n}return this.filter((n)=>t.has(n))}map(t){let n=new e({entityIndex:this._entityIndex});for(let r of this)n.add(t(r,this));return n}reduce(t,n){let r=this.readQuads(),i=n===void 0?r.next().value:n;for(let s of r)i=t(i,s,this);return i}toArray(){return this.getQuads()}toCanonical(){throw Error("not implemented")}toStream(){return this.match()}toString(){return new d_().quadsToString(this)}union(t){let n=new e({entityIndex:this._entityIndex});return n._graphs=Zy(Object.create(null),this._graphs),n._size=this._size,n.addAll(t),n}[Symbol.iterator](){return this.readQuads()}};function Pl(e,t,n=0){let r=t[n];if(r&&!(r in e))return!1;let i=!1,s=0;for(let o in r?{[r]:e[r]}:e){let a=n===2?null:Pl(e[o],t,n+1);a!==!1&&(i=i||Object.create(null),i[o]=a,s++)}return i&&(i[sr]=s),i}var Qy=class e extends Vae.Readable{constructor(t,n,r,i,s,o){super({objectMode:!0}),Object.assign(this,{n3Store:t,subject:n,predicate:r,object:i,graph:s,options:o})}get filtered(){if(!this._filtered){let{n3Store:t,graph:n,object:r,predicate:i,subject:s}=this,o=this._filtered=new UVe({factory:t._factory,entityIndex:this.options.entityIndex}),a,l,c;if(s&&!(a=o._termToNumericId(s))||i&&!(l=o._termToNumericId(i))||r&&!(c=o._termToNumericId(r)))return o;let u=t._getGraphs(n);for(let p in u){let d,f,m,y;(y=u[p])&&(!a&&l?(f=Pl(y.predicates,[l,c,a]))&&(d=Pl(y.subjects,[a,l,c]),m=Pl(y.objects,[c,a,l])):c?(m=Pl(y.objects,[c,a,l]))&&(d=Pl(y.subjects,[a,l,c]),f=Pl(y.predicates,[l,c,a])):(d=Pl(y.subjects,[a,l,c]))&&(f=Pl(y.predicates,[l,c,a]),m=Pl(y.objects,[c,a,l])),d&&(o._graphs[p]={subjects:d,predicates:f,objects:m}))}o._size=null}return this._filtered}get size(){return this.filtered.size}_read(t){t>0&&!this[oC]&&(this[oC]=this[Symbol.iterator]());let n=this[oC];for(;--t>=0;){let{done:r,value:i}=n.next();if(r){this.push(null);return}this.push(i)}}addAll(t){return this.filtered.addAll(t)}contains(t){return this.filtered.contains(t)}deleteMatches(t,n,r,i){return this.filtered.deleteMatches(t,n,r,i)}difference(t){return this.filtered.difference(t)}equals(t){return this.filtered.equals(t)}every(t,n,r,i,s){return this.filtered.every(t,n,r,i,s)}filter(t){return this.filtered.filter(t)}forEach(t,n,r,i,s){return this.filtered.forEach(t,n,r,i,s)}import(t){return this.filtered.import(t)}intersection(t){return this.filtered.intersection(t)}map(t){return this.filtered.map(t)}some(t,n,r,i,s){return this.filtered.some(t,n,r,i,s)}toCanonical(){return this.filtered.toCanonical()}toStream(){return this._filtered?this._filtered.toStream():this.n3Store.match(this.subject,this.predicate,this.object,this.graph)}union(t){return this._filtered?this._filtered.union(t):this.n3Store.match(this.subject,this.predicate,this.object,this.graph).addAll(t)}toArray(){return this._filtered?this._filtered.toArray():this.n3Store.getQuads(this.subject,this.predicate,this.object,this.graph)}reduce(t,n){return this.filtered.reduce(t,n)}toString(){return new d_().quadsToString(this)}add(t){return this.filtered.add(t)}delete(t){return this.filtered.delete(t)}has(t){return this.filtered.has(t)}match(t,n,r,i){return new e(this.filtered,t,n,r,i,this.options)}[Symbol.iterator](){return this._filtered?this._filtered[Symbol.iterator]():this.n3Store.readQuads(this.subject,this.predicate,this.object,this.graph)}};var BVe=tE(dC()),ABt=class extends BVe.Transform{constructor(e){super({decodeStrings:!0,readableObjectMode:!0});let t=new p_(e),n,r,i={onQuad:(s,o)=>{s&&this.emit("error",s)||o&&this.push(o)},onPrefix:(s,o)=>{this.emit("prefix",s,o)}};e&&e.comments&&(i.onComment=(s)=>{this.emit("comment",s)}),t.parse({on:(s,o)=>{switch(s){case"data":n=o;break;case"end":r=o;break}}},i),this._transform=(s,o,a)=>{n(s),a()},this._flush=(s)=>{r(),s()}}import(e){return e.on("error",(t)=>{this.emit("error",t)}),typeof e.pipe=="function"?e.pipe(this):(e.on("data",(t)=>{this.write(t)}),e.on("end",()=>{this.end()})),this}},VVe=tE(dC()),KVe=16384,JVe=20,RBt=class extends VVe.Transform{constructor(e){super({encoding:"utf8",writableObjectMode:!0}),this._buffer="",this._flushTimer=null,this._flushDelay=e&&e.flushDelay!==void 0?e.flushDelay:JVe;let t=this._writer=new d_({write:(i,s,o)=>{this._buffer+=i,this._buffer.length>=KVe?this._pushBuffer():this._flushTimer===null&&this._armFlushTimer(),o&&o()},end:(i)=>{this._pushBuffer(),this.push(null),i&&i()}},e),n=null,r=(i)=>{let s=n;n=null,i&&this._pushBuffer(),s(i)};this._transform=(i,s,o)=>{n=o,t.addQuad(i,r)},this._flush=(i)=>{t.end(i)}}_pushBuffer(){this._clearFlushTimer(),this._buffer!==""&&(this.push(this._buffer),this._buffer="")}_armFlushTimer(){this._flushTimer=setTimeout(()=>{this._flushTimer=null,this._pushBuffer()},this._flushDelay),this._flushTimer.unref&&this._flushTimer.unref()}_clearFlushTimer(){this._flushTimer!==null&&(clearTimeout(this._flushTimer),this._flushTimer=null)}_destroy(e,t){this._clearFlushTimer(),super._destroy(e,t)}import(e){return e.on("data",(t)=>{this.write(t)}),e.on("end",()=>{this.end()}),e.on("error",(t)=>{this._pushBuffer(),this.emit("error",t)}),e.on("prefix",(t,n)=>{this._writer.addPrefix(t,n)}),this}};/*! Bundled license information: +`),this._subject=null),this._write=this._blockedWrite;let t=e&&((n,r)=>{t=null,e(n,r)});if(this._endStream)try{return this._outputStream.end(t)}catch(n){}t&&t()}};function Sae(e){let t=LVe[e];return t===void 0&&(e.length===1?(t=e.charCodeAt(0).toString(16),t="\\u0000".substr(0,6-t.length)+t):(t=((e.charCodeAt(0)-55296)*1024+e.charCodeAt(1)+9216).toString(16),t="\\U00000000".substr(0,10-t.length)+t)),t}var Vae=tE(dC()),oC=Symbol("iter"),sr=Symbol("size");function qVe(e,t,n,r){let i=e&&e[t],s=i&&i[n];return!!s&&r in s}function th(e,t,n=4){let r=e[sr]||0;for(let i in t)i in e?n!==0&&(e[i]=th(e[i],t[i],n-1)):(r++,e[i]=n===0?null:th(Object.create(null),t[i],n-1));return n<=2&&(e[sr]=r),e}function Kae(e,t,n=4){let r=!1,i=0;n<=2&&t[sr]{r in n||(n[r]=!0,t(this._termFromId(this._entities[r],this._factory)))}}add(t){return this.addQuad(t),this}addQuad(t,n,r,i){n||(i=t.graph,r=t.object,n=t.predicate,t=t.subject),i=i?this._termToNewNumericId(i):1;let s=this._graphs[i];return s||(s=this._graphs[i]={subjects:{[sr]:0},predicates:{[sr]:0},objects:{[sr]:0}},Object.freeze(s)),t=this._termToNewNumericId(t),n=this._termToNewNumericId(n),r=this._termToNewNumericId(r),this._addToIndex(s.subjects,t,n,r)?(this._addToIndex(s.predicates,n,r,t),this._addToIndex(s.objects,r,t,n),this._size=null,!0):!1}addQuads(t){for(let n=0;n{this.addQuad(n)}),t}removeQuad(t,n,r,i){n||({subject:t,predicate:n,object:r,graph:i}=t),i=i?this._termToNumericId(i):1;let s=this._graphs,o,a,l;return!(t=t&&this._termToNumericId(t))||!(n=n&&this._termToNumericId(n))||!(r=r&&this._termToNumericId(r))||!(o=s[i])||!(a=o.subjects[t])||!(l=a[n])||!(r in l)?!1:(this._removeFromIndex(o.subjects,t,n,r),this._removeFromIndex(o.predicates,n,r,t),this._removeFromIndex(o.objects,r,t,n),this._size!==null&&this._size--,o.subjects[sr]===0&&delete s[i],!0)}removeQuads(t){for(let n=0;n{this.removeQuad(n)}),t}removeMatches(t,n,r,i){let s=new Vae.Readable({objectMode:!0}),o=this.readQuads(t,n,r,i);return s._read=(a)=>{for(;--a>=0;){let{done:l,value:c}=o.next();if(l){s.push(null);return}s.push(c)}},this.remove(s)}deleteGraph(t){return this.removeMatches(null,null,null,t)}getQuads(t,n,r,i){return[...this.readQuads(t,n,r,i)]}*readQuads(t,n,r,i){let s=this._getGraphs(i),o,a,l,c;if(!(t&&!(a=this._termToNumericId(t))||n&&!(l=this._termToNumericId(n))||r&&!(c=this._termToNumericId(r))))for(let u in s)(o=s[u])&&(a?c?yield*wf(this._findInIndex(o.objects,c,a,l,"object","subject","predicate",u)):yield*wf(this._findInIndex(o.subjects,a,l,null,"subject","predicate","object",u)):l?yield*wf(this._findInIndex(o.predicates,l,c,null,"predicate","object","subject",u)):c?yield*wf(this._findInIndex(o.objects,c,null,null,"object","subject","predicate",u)):yield*wf(this._findInIndex(o.subjects,null,null,null,"subject","predicate","object",u)))}match(t,n,r,i){return new Xy(this,t,n,r,i,{entityIndex:this._entityIndex})}countQuads(t,n,r,i){let s=this._getGraphs(i),o=0,a,l,c,u;if(t&&!(l=this._termToNumericId(t))||n&&!(c=this._termToNumericId(n))||r&&!(u=this._termToNumericId(r)))return 0;for(let p in s)(a=s[p])&&(t?r?o+=this._countInIndex(a.objects,u,l,c):o+=this._countInIndex(a.subjects,l,c,u):n?o+=this._countInIndex(a.predicates,c,u,l):o+=this._countInIndex(a.objects,u,l,c));return o}forEach(t,n,r,i,s){this.some((o)=>(t(o,this),!1),n,r,i,s)}every(t,n,r,i,s){return!this.some((o)=>!t(o,this),n,r,i,s)}some(t,n,r,i,s){for(let o of this.readQuads(n,r,i,s))if(t(o,this))return!0;return!1}getSubjects(t,n,r){let i=[];return this.forSubjects((s)=>{i.push(s)},t,n,r),i}forSubjects(t,n,r,i){let s=this._getGraphs(i),o,a,l;if(t=this._uniqueEntities(t),!(n&&!(a=this._termToNumericId(n))||r&&!(l=this._termToNumericId(r))))for(i in s)(o=s[i])&&(a?l?this._loopBy2Keys(o.predicates,a,l,t):this._loopByKey1(o.subjects,a,t):l?this._loopByKey0(o.objects,l,t):this._loop(o.subjects,t))}getPredicates(t,n,r){let i=[];return this.forPredicates((s)=>{i.push(s)},t,n,r),i}forPredicates(t,n,r,i){let s=this._getGraphs(i),o,a,l;if(t=this._uniqueEntities(t),!(n&&!(a=this._termToNumericId(n))||r&&!(l=this._termToNumericId(r))))for(i in s)(o=s[i])&&(a?l?this._loopBy2Keys(o.objects,l,a,t):this._loopByKey0(o.subjects,a,t):l?this._loopByKey1(o.predicates,l,t):this._loop(o.predicates,t))}getObjects(t,n,r){let i=[];return this.forObjects((s)=>{i.push(s)},t,n,r),i}forObjects(t,n,r,i){let s=this._getGraphs(i),o,a,l;if(t=this._uniqueEntities(t),!(n&&!(a=this._termToNumericId(n))||r&&!(l=this._termToNumericId(r))))for(i in s)(o=s[i])&&(a?l?this._loopBy2Keys(o.subjects,a,l,t):this._loopByKey0Deep(o.subjects,a,t):l?this._loopByKey0(o.predicates,l,t):this._loop(o.objects,t))}getGraphs(t,n,r){let i=[];return this.forGraphs((s)=>{i.push(s)},t,n,r),i}forGraphs(t,n,r,i){for(let s in this._graphs)this.some((o)=>(t(o.graph),!0),n,r,i,this._termFromId(this._entities[s]))}createBlankNode(t){return this._entityIndex.createBlankNode(t)}extractLists({remove:t=!1,ignoreErrors:n=!1}={}){let r=Object.create(null),i=n?()=>!0:(a,l)=>{throw Error(`${a.value} ${l}`)},s=this.getQuads(null,br.rdf.rest,br.rdf.nil,null),o=t?[...s]:[];return s.forEach((a)=>{let l=[],c=!1,u,p,{graph:d,subject:f}=a;for(;f&&!c;){let m=this.getQuads(null,null,f,null),y=this.getQuads(f,null,null,null),h,b=null,g=null,x=null;for(let v=0;vthis.has(c));let n=this._graphs,r=t._graphs,i,s,o,a,l;for(let c in r){if(!(i=n[c]))return!1;i=i.subjects;for(let u in s=r[c].subjects){if(!(o=i[u]))return!1;for(let p in a=s[u]){if(!(l=o[p]))return!1;for(let d in a[p])if(!(d in l))return!1}}}return!0}deleteMatches(t,n,r,i){for(let s of this.match(t,n,r,i))this.removeQuad(s);return this}difference(t){if(t&&t instanceof Xy&&(t=t.filtered),t===this)return new e({entityIndex:this._entityIndex});if(t instanceof e&&t._entityIndex===this._entityIndex){let n=new e({entityIndex:this._entityIndex}),r=Jae(this._graphs,t._graphs);return r&&(n._graphs=r,n._size=null),n}return this.filter((n)=>!t.has(n))}equals(t){return t instanceof Xy&&(t=t.filtered),t===this||this.size===t.size&&this.contains(t)}filter(t){let n=new e({entityIndex:this._entityIndex});for(let r of this)t(r,this)&&n.add(r);return n}intersection(t){if(t instanceof Xy&&(t=t.filtered),t===this){let n=new e({entityIndex:this._entityIndex});return n._graphs=th(Object.create(null),this._graphs),n._size=this._size,n}else if(t instanceof e&&this._entityIndex===t._entityIndex){let n=new e({entityIndex:this._entityIndex}),r=Kae(t._graphs,this._graphs);return r&&(n._graphs=r,n._size=null),n}return this.filter((n)=>t.has(n))}map(t){let n=new e({entityIndex:this._entityIndex});for(let r of this)n.add(t(r,this));return n}reduce(t,n){let r=this.readQuads(),i=n===void 0?r.next().value:n;for(let s of r)i=t(i,s,this);return i}toArray(){return this.getQuads()}toCanonical(){throw Error("not implemented")}toStream(){return this.match()}toString(){return new d_().quadsToString(this)}union(t){let n=new e({entityIndex:this._entityIndex});return n._graphs=th(Object.create(null),this._graphs),n._size=this._size,n.addAll(t),n}[Symbol.iterator](){return this.readQuads()}};function Pl(e,t,n=0){let r=t[n];if(r&&!(r in e))return!1;let i=!1,s=0;for(let o in r?{[r]:e[r]}:e){let a=n===2?null:Pl(e[o],t,n+1);a!==!1&&(i=i||Object.create(null),i[o]=a,s++)}return i&&(i[sr]=s),i}var Xy=class e extends Vae.Readable{constructor(t,n,r,i,s,o){super({objectMode:!0}),Object.assign(this,{n3Store:t,subject:n,predicate:r,object:i,graph:s,options:o})}get filtered(){if(!this._filtered){let{n3Store:t,graph:n,object:r,predicate:i,subject:s}=this,o=this._filtered=new BVe({factory:t._factory,entityIndex:this.options.entityIndex}),a,l,c;if(s&&!(a=o._termToNumericId(s))||i&&!(l=o._termToNumericId(i))||r&&!(c=o._termToNumericId(r)))return o;let u=t._getGraphs(n);for(let p in u){let d,f,m,y;(y=u[p])&&(!a&&l?(f=Pl(y.predicates,[l,c,a]))&&(d=Pl(y.subjects,[a,l,c]),m=Pl(y.objects,[c,a,l])):c?(m=Pl(y.objects,[c,a,l]))&&(d=Pl(y.subjects,[a,l,c]),f=Pl(y.predicates,[l,c,a])):(d=Pl(y.subjects,[a,l,c]))&&(f=Pl(y.predicates,[l,c,a]),m=Pl(y.objects,[c,a,l])),d&&(o._graphs[p]={subjects:d,predicates:f,objects:m}))}o._size=null}return this._filtered}get size(){return this.filtered.size}_read(t){t>0&&!this[oC]&&(this[oC]=this[Symbol.iterator]());let n=this[oC];for(;--t>=0;){let{done:r,value:i}=n.next();if(r){this.push(null);return}this.push(i)}}addAll(t){return this.filtered.addAll(t)}contains(t){return this.filtered.contains(t)}deleteMatches(t,n,r,i){return this.filtered.deleteMatches(t,n,r,i)}difference(t){return this.filtered.difference(t)}equals(t){return this.filtered.equals(t)}every(t,n,r,i,s){return this.filtered.every(t,n,r,i,s)}filter(t){return this.filtered.filter(t)}forEach(t,n,r,i,s){return this.filtered.forEach(t,n,r,i,s)}import(t){return this.filtered.import(t)}intersection(t){return this.filtered.intersection(t)}map(t){return this.filtered.map(t)}some(t,n,r,i,s){return this.filtered.some(t,n,r,i,s)}toCanonical(){return this.filtered.toCanonical()}toStream(){return this._filtered?this._filtered.toStream():this.n3Store.match(this.subject,this.predicate,this.object,this.graph)}union(t){return this._filtered?this._filtered.union(t):this.n3Store.match(this.subject,this.predicate,this.object,this.graph).addAll(t)}toArray(){return this._filtered?this._filtered.toArray():this.n3Store.getQuads(this.subject,this.predicate,this.object,this.graph)}reduce(t,n){return this.filtered.reduce(t,n)}toString(){return new d_().quadsToString(this)}add(t){return this.filtered.add(t)}delete(t){return this.filtered.delete(t)}has(t){return this.filtered.has(t)}match(t,n,r,i){return new e(this.filtered,t,n,r,i,this.options)}[Symbol.iterator](){return this._filtered?this._filtered[Symbol.iterator]():this.n3Store.readQuads(this.subject,this.predicate,this.object,this.graph)}};var VVe=tE(dC()),jBt=class extends VVe.Transform{constructor(e){super({decodeStrings:!0,readableObjectMode:!0});let t=new p_(e),n,r,i={onQuad:(s,o)=>{s&&this.emit("error",s)||o&&this.push(o)},onPrefix:(s,o)=>{this.emit("prefix",s,o)}};e&&e.comments&&(i.onComment=(s)=>{this.emit("comment",s)}),t.parse({on:(s,o)=>{switch(s){case"data":n=o;break;case"end":r=o;break}}},i),this._transform=(s,o,a)=>{n(s),a()},this._flush=(s)=>{r(),s()}}import(e){return e.on("error",(t)=>{this.emit("error",t)}),typeof e.pipe=="function"?e.pipe(this):(e.on("data",(t)=>{this.write(t)}),e.on("end",()=>{this.end()})),this}},KVe=tE(dC()),JVe=16384,GVe=20,FBt=class extends KVe.Transform{constructor(e){super({encoding:"utf8",writableObjectMode:!0}),this._buffer="",this._flushTimer=null,this._flushDelay=e&&e.flushDelay!==void 0?e.flushDelay:GVe;let t=this._writer=new d_({write:(i,s,o)=>{this._buffer+=i,this._buffer.length>=JVe?this._pushBuffer():this._flushTimer===null&&this._armFlushTimer(),o&&o()},end:(i)=>{this._pushBuffer(),this.push(null),i&&i()}},e),n=null,r=(i)=>{let s=n;n=null,i&&this._pushBuffer(),s(i)};this._transform=(i,s,o)=>{n=o,t.addQuad(i,r)},this._flush=(i)=>{t.end(i)}}_pushBuffer(){this._clearFlushTimer(),this._buffer!==""&&(this.push(this._buffer),this._buffer="")}_armFlushTimer(){this._flushTimer=setTimeout(()=>{this._flushTimer=null,this._pushBuffer()},this._flushDelay),this._flushTimer.unref&&this._flushTimer.unref()}_clearFlushTimer(){this._flushTimer!==null&&(clearTimeout(this._flushTimer),this._flushTimer=null)}_destroy(e,t){this._clearFlushTimer(),super._destroy(e,t)}import(e){return e.on("data",(t)=>{this.write(t)}),e.on("end",()=>{this.end()}),e.on("error",(t)=>{this._pushBuffer(),this.emit("error",t)}),e.on("prefix",(t,n)=>{this._writer.addPrefix(t,n)}),this}};/*! Bundled license information: ieee754/index.js: (*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh *) @@ -4367,8 +4367,8 @@ buffer/index.js: safe-buffer/index.js: (*! safe-buffer. MIT License. Feross Aboukhadijeh *) -*/var Gae={id:"umf.rdf",version:"0.1.0",coreVersion:"0.1.0",description:"RDF 1.1 N-Quads/Turtle/TriG source and editable dataset terms with local blank-node scope",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:rdf:0.1.0",type:"object",properties:{profile:{enum:["rdf11-nquads","rdf11-turtle","rdf11-trig"]},baseIRI:{type:"string",minLength:1,maxLength:4096},namedGraphs:{type:"array",maxItems:1e4,items:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0}]}},blankNodeScope:{type:"string",minLength:1},quads:{type:"array",maxItems:1e4,items:{type:"object",properties:{subject:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0}]},predicate:{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},object:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"literal"},value:{type:"string"},datatype:{type:"string"},language:{type:"string",pattern:"^[a-z]+(?:-[a-z0-9]+)*$"}},required:["kind","value","datatype"],additionalProperties:!0}]},graph:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"default"}},required:["kind"],additionalProperties:!0}]}},required:["subject","predicate","object","graph"],additionalProperties:!0}},originalSource:{type:"string",maxLength:4000000}},required:["profile","blankNodeScope","quads","originalSource"],additionalProperties:!0,allOf:[{if:{properties:{profile:{enum:["rdf11-turtle","rdf11-trig"]}}},then:{properties:{baseIRI:{}},required:["baseIRI"]}},{if:{properties:{profile:{const:"rdf11-trig"}}},then:{properties:{namedGraphs:{}},required:["namedGraphs"]}}]},semantics:"CONTRACT-025; ordered quad occurrences preserve syntax-level information, dataset meaning has set semantics; blank labels are scoped, no entailment",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"RDF",version:"RDF 1.1 N-Quads/Turtle/TriG; N3.js 2.7.12",subset:"N-Quads/Turtle/TriG RDF 1.1 terms, explicit Turtle/TriG base, named/default graphs with empty graph inventory, lexical literals and local blank nodes, collision-guarded IRI rename and explicit disjoint-input dataset merge; no other syntaxes, RDF 1.2, entailment or canonicalization"},evidence:["tests/rdf/merge.test.ts","fixtures/rdf/merge/oracle-results.json","fixtures/rdf/merge/browser-results.json","tests/rdf/rdf.test.ts","fixtures/rdf/nquads/oracle-results.json","fixtures/rdf/nquads/browser-results.json","tests/rdf/rename.test.ts","fixtures/rdf/rename/oracle-results.json","fixtures/rdf/rename/browser-results.json","tests/rdf/trig.test.ts","fixtures/rdf/trig/oracle-results.json","fixtures/rdf/trig/browser-results.json","tests/rdf/turtle.test.ts","fixtures/rdf/turtle/oracle-results.json","fixtures/rdf/turtle/browser-results.json"]}};var Kc="umf.rdf",HVe=Gae,zVe="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString";function f_(e){if(e.termType==="NamedNode")return{kind:"iri",value:e.value};if(e.termType==="BlankNode")return{kind:"blank",value:e.value};if(e.termType==="DefaultGraph")return{kind:"default"};if(e.termType==="Literal"&&!e.direction)return{kind:"literal",value:e.value,datatype:e.datatype.value,...e.language?{language:e.language.toLowerCase()}:{}};throw new U("RDF_PROFILE","Term is outside the RDF 1.1 profile")}function nh(e,t="N-Quads",n,r){if(typeof e!=="string"||e.length>4000000)throw new U("RDF_LIMIT","Expected at most 4,000,000 source characters");if(/[\uD800-\uDFFF]/u.test(e))throw new U("RDF_UNICODE","Unpaired UTF-16 surrogates cannot represent Unicode scalar values");let i=0,s=t!=="N-Quads"?{...ss,blankNode:(a)=>ss.blankNode(a===void 0?"g_"+i++:"e_"+Array.from(a).map((l)=>l.codePointAt(0).toString(16).padStart(6,"0")).join(""))}:ss,o;try{let a=new p_({format:t,blankNodePrefix:"",factory:s,baseIRI:n});if(t==="TriG"){let l=a._readGraph;if(typeof l!=="function")throw new U("RDF_PARSER","Pinned graph-reader hook is unavailable");let c=new Set;a._readGraph=function(u){let p=l.call(this,u);if(u.type==="{"&&this._graph&&typeof this._graph==="object"){let d=f_(this._graph);if(d.kind!=="iri"&&d.kind!=="blank")throw new U("RDF_GRAPH","Expected graph name");let f=JSON.stringify(d);if(!c.has(f)){if(c.add(f),r?.push(d),c.size>1e4)throw new U("RDF_LIMIT","At most 10,000 named graphs")}}return p}}o=a.parse(e,void 0,void 0,()=>{throw new U("RDF_PROFILE","RDF version directives are outside the RDF 1.1 syntax profile")})}catch(a){throw new U("RDF_SYNTAX",String(a))}if(o.length>1e4)throw new U("RDF_LIMIT","At most 10,000 quad occurrences");return o.map((a)=>({subject:f_(a.subject),predicate:f_(a.predicate),object:f_(a.object),graph:f_(a.graph)}))}function oE(e){switch(e.kind){case"iri":return ss.namedNode(e.value);case"blank":return ss.blankNode(e.value);case"default":return ss.defaultGraph();case"literal":if(e.language&&e.datatype!==zVe)throw new U("RDF_LITERAL","Language literal requires rdf:langString");return ss.literal(e.value,e.language??ss.namedNode(e.datatype))}}function m_(e){return new d_({format:"N-Quads"}).quadsToString(e.map((t)=>ss.quad(oE(t.subject),oE(t.predicate),oE(t.object),oE(t.graph))))}var $l=(e)=>JSON.stringify(e.map((t)=>[t.subject,t.predicate,t.object,t.graph].map((n)=>n.kind==="default"?[n.kind]:n.kind==="literal"?[n.kind,n.value,n.datatype,n.language??""]:[n.kind,n.value])));function WVe(e){let t=e,n=[{code:"RDF_CONTEXT",path:"",severity:"warning",message:"RDF 1.1 N-Quads/Turtle/TriG only. Turtle/TriG expands prefixes/base and allocates deterministic local anonymous labels. Blank labels have document-local scope; dataset meaning ignores duplicate occurrences and order. No entailment, datatype value normalization, isomorphism/canonicalization or RDF 1.2 support is asserted. Original bytes remain archived; edited export regenerates syntax."}],r=(i,s,o)=>{if(Object.keys(i).some((a)=>!s.includes(a)))n.push({code:"RDF_REPRESENTATION",path:o,severity:"warning",message:"Unknown encoding fields are retained and block native export"})};r(t,["profile","blankNodeScope","quads","originalSource","namedGraphs",...t.profile!=="rdf11-nquads"?["baseIRI"]:[]],""),t.namedGraphs?.forEach((i,s)=>r(i,["kind","value"],"/namedGraphs/"+s)),t.quads.forEach((i,s)=>{r(i,["subject","predicate","object","graph"],"/quads/"+s);for(let[o,a]of Object.entries(i)){if(!["subject","predicate","object","graph"].includes(o))continue;r(a,a.kind==="default"?["kind"]:a.kind==="literal"?["kind","value","datatype","language"]:["kind","value"],"/quads/"+s+"/"+o)}});try{if(t.profile!=="rdf11-nquads")YVe(t.baseIRI);if(t.profile==="rdf11-turtle"){if(mC(t).length)throw Error("Turtle cannot represent named graphs")}nh(t.originalSource,t.profile==="rdf11-trig"?"TriG":t.profile==="rdf11-turtle"?"Turtle":"N-Quads",t.baseIRI);for(let o of t.namedGraphs??[]){let a={subject:o,predicate:{kind:"iri",value:"urn:umf:graph-probe"},object:o,graph:{kind:"default"}};if($l(nh(m_([a])))!==$l([a]))throw Error("Graph name changes when encoded")}let i=m_(t.quads),s=nh(i);if($l(s)!==$l(t.quads)&&!n.some((o)=>o.code==="RDF_REPRESENTATION"))throw Error("Terms change when encoded as N-Quads")}catch(i){n.push({code:"RDF_TERMS",path:"",severity:"error",message:String(i)})}return n}function QVe(){return new nt().register(HVe,WVe)}function Dp(e){return We(e,QVe())}function Hae(e){let t=Dp(e);if(!t.valid)throw new U("RDF_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="dataset")?.elements.find((r)=>r.id==="dataset")?.extensions[Kc];if(!n||e.vocabularies[Kc]?.version!=="0.1.0")throw new U("RDF_PAYLOAD","Expected pinned RDF dataset payload");return Ae(n)}function fC(e,t={}){if(t.preserveSource!==void 0&&typeof t.preserveSource!=="boolean")throw new U("RDF_OPTIONS","Expected boolean preserveSource");let n=Hae(e);if(Dp(e).diagnostics.some((r)=>r.code==="RDF_REPRESENTATION"))throw new U("RDF_EXPORT","Unknown encoding fields cannot be discarded");if(mC(n).some((r)=>!n.quads.some((i)=>i.graph.kind===r.kind&&("value"in i.graph)&&i.graph.value===r.value)))throw new U("RDF_GRAPH_LOSS","N-Quads cannot represent empty named graphs");return t.preserveSource!==!1&&n.profile==="rdf11-nquads"&&$l(nh(n.originalSource))===$l(n.quads)?n.originalSource:m_(n.quads)}function YVe(e){if(typeof e!=="string"||!e.length||e.length>4096)throw new U("RDF_BASE","Explicit absolute base IRI required");let t={subject:{kind:"iri",value:e},predicate:{kind:"iri",value:"urn:umf:base-probe"},object:{kind:"iri",value:e},graph:{kind:"default"}};if($l(nh(m_([t])))!==$l([t]))throw new U("RDF_BASE","Base IRI spelling changes on serialization")}function rh(e){let t=Hae(e);if(Dp(e).diagnostics.some((n)=>n.code==="RDF_REPRESENTATION"))throw new U("RDF_EXPORT","Unknown encoding fields cannot be discarded");if(mC(t).length)throw new U("RDF_GRAPH_LOSS","Turtle export cannot silently discard named graphs");return t.profile==="rdf11-turtle"&&$l(nh(t.originalSource,"Turtle",t.baseIRI))===$l(t.quads)?t.originalSource:m_(t.quads)}function mC(e){let t=new Map;for(let n of[...e.namedGraphs??[],...e.quads.map((r)=>r.graph)])if(n.kind!=="default")t.set(JSON.stringify([n.kind,n.value]),n);return[...t.values()]}var t6e=Ar(LF(),1);var zae={id:"umf.jsonld",version:"0.1.0",coreVersion:"0.1.0",description:"JSON-LD source and supplied context preservation with explicit expansion, flattening, compaction and framing proposals",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:jsonld:0.1.0",type:"object",properties:{profile:{const:"jsonld-source"},processingMode:{enum:["json-ld-1.0","json-ld-1.1"]},baseIRI:{type:"string",minLength:1,maxLength:4096},root:{$ref:"#/$defs/node"},originalSource:{type:"string",maxLength:4000000},contexts:{type:"array",maxItems:100,items:{type:"object",properties:{url:{type:"string",minLength:1},documentUrl:{type:"string",minLength:1},root:{$ref:"#/$defs/node"},originalSource:{type:"string",maxLength:4000000}},required:["url","documentUrl","root","originalSource"],additionalProperties:!0}},expandContext:{$ref:"#/$defs/node"}},required:["profile","processingMode","baseIRI","root","originalSource","contexts"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-026; exact source and context values remain authoritative; JSON-LD processing proposals are qualified transformations, not an RDF or ontology equivalence proof",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"JSON-LD",version:"1.0/1.1; jsonld.js 9.0.0 + UMF processing patch",subset:"JSON source and explicit context bundle; exact-number expansion with recorded loss events or rejection; flattening and standalone compaction with recorded corpus discrepancies; framing selected views with retained sources, strict flag validation and recorded compatibility blocks; RDF-to-JSON-LD projection with lexical/native type policies; qualified JSON-LD-to-RDF proposals with explicitly recorded strict/binary64 numeric policies with explicit quantization and finite-overflow blocks; optional generalized dataset projection through umf.generalized-rdf; malformed terms omitted with explicit loss events; compound-literal direction conversion with graph/list round-trip evidence; no network"},evidence:["tests/generalized-rdf/dataset.test.ts","fixtures/generalized-rdf/oracle-results.json","fixtures/generalized-rdf/browser-results.json","fixtures/jsonld/to-rdf/numeric-oracle-results.json","tests/jsonld/to-rdf.test.ts","fixtures/jsonld/to-rdf/oracle-results.json","fixtures/jsonld/to-rdf/rdf-oracle-results.json","fixtures/jsonld/to-rdf/browser-results.json","tests/jsonld/from-rdf.test.ts","fixtures/jsonld/from-rdf/oracle-results.json","fixtures/jsonld/from-rdf/browser-results.json","tests/jsonld/framing.test.ts","fixtures/jsonld/framing/oracle-results.json","fixtures/jsonld/framing/browser-results.json","tests/jsonld/compaction.test.ts","fixtures/jsonld/compaction/oracle-results.json","fixtures/jsonld/compaction/browser-results.json","tests/jsonld/flatten.test.ts","fixtures/jsonld/flatten/oracle-results.json","fixtures/jsonld/flatten/browser-results.json","tests/jsonld/numeric.test.ts","fixtures/jsonld/numeric/oracle-results.json","tests/jsonld/nest.test.ts","fixtures/jsonld/nest/results.json","fixtures/jsonld/patch-results.json","tests/jsonld/legacy.test.ts","fixtures/jsonld/legacy/results.json","tests/jsonld/jsonld.test.ts","fixtures/jsonld/expansion/oracle-results.json","fixtures/jsonld/expansion/browser-results.json"]}};var Wae="umf.jsonld",n6e=zae;function yC(e){try{new URL(e)}catch{throw new U("JSONLD_IRI","Expected absolute document/base URL")}}function r6e(e){let t=e,n=[{code:"JSONLD_CONTEXT",path:"",severity:"warning",message:"Source representation only; semantic expansion is a separate asynchronous proposal. Original source, unknown native values and exact numeric tokens remain archived. No RDF conversion, ontology validation or retrieval is asserted."}],r=(s,o,a)=>{if(Object.keys(s).some((l)=>!o.includes(l)))n.push({code:"JSONLD_REPRESENTATION",path:a,severity:"warning",message:"Unknown representation fields are retained and block native export/expansion"})},i=(s,o)=>{if(r(s,s.kind==="null"?["kind"]:s.kind==="object"?["kind","members"]:s.kind==="array"?["kind","items"]:["kind","value"],o),s.kind==="array")s.items.forEach((a,l)=>i(a,o+"/"+l));if(s.kind==="object")for(let[a,l]of Object.entries(s.members))i(l,o+"/"+Pe(a))};if(r(t,["profile","processingMode","baseIRI","root","originalSource","contexts","expandContext"],""),i(t.root,"/root"),t.expandContext)i(t.expandContext,"/expandContext");try{yC(t.baseIRI),Jt(t.originalSource);let s=new Set;t.contexts.forEach((o,a)=>{if(r(o,["url","documentUrl","root","originalSource"],"/contexts/"+a),i(o.root,"/contexts/"+a+"/root"),yC(o.url),yC(o.documentUrl),s.has(o.url))throw Error("Duplicate supplied context URL: "+o.url);s.add(o.url),Jt(o.originalSource)})}catch(s){n.push({code:"JSONLD_SOURCE",path:"",severity:"error",message:String(s)})}return n}function i6e(){return new nt().register(n6e,r6e)}function Xae(e){return We(e,i6e())}function s6e(e){let t=Xae(e);if(!t.valid)throw new U("JSONLD_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="jsonld")?.elements.find((r)=>r.id==="document")?.extensions[Wae];if(!n||e.vocabularies[Wae]?.version!=="0.1.0")throw new U("JSONLD_PAYLOAD","Expected pinned JSON-LD payload");return Ae(n)}function Zae(e){let t=s6e(e);if(Xae(e).diagnostics.some((n)=>n.code==="JSONLD_REPRESENTATION"))throw new U("JSONLD_EXPORT","Unknown representation fields cannot be discarded");return Be(Jt(t.originalSource))===Be(t.root)?t.originalSource:Be(t.root)+` -`}function Qae(e){let[t,n="0"]=e.toLowerCase().split("e"),r=t.startsWith("-"),i=t.replace("-","").split("."),s=(i[0]+(i[1]??"")).replace(/^0+/,""),o=BigInt(n)-BigInt((i[1]??"").length);while(s.endsWith("0"))s=s.slice(0,-1),o++;return s?[r,s,o.toString()]:[r,"0","0"]}var aE=new WeakMap;class o6e extends Number{constructor(e){super(0);Object.defineProperty(this,Symbol.for("umf.jsonld.exact-number"),{value:!0}),aE.set(this,e),Object.freeze(this)}valueOf(){throw new U("JSONLD_NUMBER_OPERATION","Exact expansion number cannot be coerced for arithmetic")}toString(){return aE.get(this)}[Symbol.for("umf.jsonld.number-equals")](e){let t=typeof e==="number"&&Number.isFinite(e)?Object.is(e,-0)?"-0":JSON.stringify(e):e&&typeof e==="object"?aE.get(e):void 0;return t!==void 0&&JSON.stringify(Qae(this.toString()))===JSON.stringify(Qae(t))}toJSON(){return{$umfExactNumber:aE.get(this)}}}var ele={id:"umf.owl",version:"0.1.0",coreVersion:"0.1.0",description:"OWL 2 RDF graph preservation and local ontology metadata views",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:owl:0.1.0",type:"object",properties:{profile:{enum:["rdf11-nquads","rdf11-turtle","rdf11-trig"]},baseIRI:{type:"string",minLength:1,maxLength:4096},namedGraphs:{type:"array",maxItems:1e4,items:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0}]}},blankNodeScope:{type:"string",minLength:1},quads:{type:"array",maxItems:1e4,items:{type:"object",properties:{subject:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0}]},predicate:{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},object:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"literal"},value:{type:"string"},datatype:{type:"string"},language:{type:"string",pattern:"^[a-z]+(?:-[a-z0-9]+)*$"}},required:["kind","value","datatype"],additionalProperties:!0}]},graph:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"default"}},required:["kind"],additionalProperties:!0}]}},required:["subject","predicate","object","graph"],additionalProperties:!0}},originalSource:{type:"string",maxLength:4000000},owlVersion:{const:"2"}},required:["profile","blankNodeScope","quads","originalSource","owlVersion"],additionalProperties:!0,allOf:[{if:{properties:{profile:{enum:["rdf11-turtle","rdf11-trig"]}}},then:{properties:{baseIRI:{}},required:["baseIRI"]}},{if:{properties:{profile:{const:"rdf11-trig"}}},then:{properties:{namedGraphs:{}},required:["namedGraphs"]}}]},semantics:"CONTRACT-029; RDF graph fidelity only; OWL axiom validation and reasoning unimplemented",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"OWL",version:"OWL 2 Second Edition 2012-12-11",subset:"Turtle RDF graph preservation; explicit headers/declarations, local expressions, axiom annotations, negative/n-ary assertions and chain/key/disjoint-union lists. No complete structural OWL mapping, validity, profile, import execution or entailment claim"},evidence:["tests/owl/annotations.test.ts","fixtures/owl/annotations-oracle.json","fixtures/owl/annotation-case-oracle.json","fixtures/owl/annotation-case-browser.json","tests/owl/expressions.test.ts","fixtures/owl/expression-oracle.json","tests/owl/roundtrip.test.ts","fixtures/owl/oracle-results.json","fixtures/owl/browser-results.json","tests/owl/axioms.test.ts","fixtures/owl/special-oracle.json","fixtures/owl/special-browser.json","tests/owl/declarations.test.ts","fixtures/owl/declarations-oracle.json","fixtures/owl/declarations-browser.json","tests/owl/list-axioms.test.ts","fixtures/owl/list-axioms-oracle.json","fixtures/owl/list-axioms-browser.json"]}};var tle="umf.owl",u6e=ele;function nle(e){let t=Ae(e);return delete t.owlVersion,{umf:"0.1.0",id:"owl:graph",vocabularies:{[Kc]:{version:"0.1.0"}},modules:[{id:"dataset",namespace:"",elements:[{id:"dataset",extensions:{[Kc]:t}}]}]}}function p6e(e){return[...Dp(nle(e)).diagnostics,{code:"OWL_SCOPE",path:"",severity:"warning",message:"OWL 2 RDF graph preservation only. Axiom validation, profiles, import resolution, consistency and entailment are not implemented."}]}function d6e(){return new nt().register(u6e,p6e)}function f6e(e){return We(e,d6e())}function m6e(e){let t=f6e(e);if(!t.valid)throw new U("OWL_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((i)=>i.id==="dataset")?.elements.find((i)=>i.id==="dataset")?.extensions[tle];if(!n||e.vocabularies[tle]?.version!=="0.1.0")throw new U("OWL_PAYLOAD","Expected pinned ontology graph");let r=nle(n);return rh(r),r}function rle(e){return rh(m6e(e))}var ile={id:"umf.shacl",version:"0.1.0",coreVersion:"0.1.0",description:"SHACL 1.0 shapes graphs with source-preserving RDF representation and explicit property-path interpretation",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:shacl:0.1.0",type:"object",properties:{profile:{enum:["rdf11-nquads","rdf11-turtle","rdf11-trig"]},baseIRI:{type:"string",minLength:1,maxLength:4096},namedGraphs:{type:"array",maxItems:1e4,items:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0}]}},blankNodeScope:{type:"string",minLength:1},quads:{type:"array",maxItems:1e4,items:{type:"object",properties:{subject:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0}]},predicate:{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},object:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"literal"},value:{type:"string"},datatype:{type:"string"},language:{type:"string",pattern:"^[a-z]+(?:-[a-z0-9]+)*$"}},required:["kind","value","datatype"],additionalProperties:!0}]},graph:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"default"}},required:["kind"],additionalProperties:!0}]}},required:["subject","predicate","object","graph"],additionalProperties:!0}},originalSource:{type:"string",maxLength:4000000},shaclVersion:{const:"1.0"}},required:["profile","blankNodeScope","quads","originalSource","shaclVersion"],additionalProperties:!0,allOf:[{if:{properties:{profile:{enum:["rdf11-turtle","rdf11-trig"]}}},then:{properties:{baseIRI:{}},required:["baseIRI"]}},{if:{properties:{profile:{const:"rdf11-trig"}}},then:{properties:{namedGraphs:{}},required:["namedGraphs"]}}]},semantics:"CONTRACT-028; SHACL 2017 Recommendation, source graph preservation, property paths and Core target selection; verified constraint conformance remains unimplemented; engine proposal available",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"SHACL",version:"W3C Recommendation 2017-07-20",subset:"RDF 1.1 Turtle shapes graph; all seven property-path forms and Core target selection; no constraint conformance, SPARQL execution, imports, entailment or SHACL 1.2 claim"},evidence:["tests/shacl/paths.test.ts","fixtures/shacl/oracle-results.json","fixtures/shacl/browser-results.json","fixtures/shacl/corpus-results.json","fixtures/shacl/corpus-oracle-results.json","fixtures/shacl/target-oracle-results.json","fixtures/shacl/target-browser-results.json","fixtures/shacl/validation-results.json","fixtures/shacl/report-comparison.json","fixtures/shacl/validation-browser-results.json","fixtures/shacl/exact-numeric-results.json","fixtures/shacl/exact-numeric-oracle.json","fixtures/shacl/exact-numeric-browser-results.json","fixtures/shacl/float-results.json","fixtures/shacl/float-oracle.json","fixtures/shacl/float-browser-results.json","tests/shacl/metadata.test.ts","fixtures/shacl/metadata.json","fixtures/shacl/metadata-browser-results.json","tests/shacl/lists.test.ts","fixtures/shacl/list-gap.json","fixtures/shacl/string-results.json","fixtures/shacl/string-oracle.json","fixtures/shacl/string-browser-results.json"]}};var sle="umf.shacl",h6e=ile;function ole(e){let t=Ae(e);return delete t.shaclVersion,{umf:"0.1.0",id:"shacl:graph",vocabularies:{[Kc]:{version:"0.1.0"}},modules:[{id:"dataset",namespace:"",elements:[{id:"dataset",extensions:{[Kc]:t}}]}]}}function g6e(e){return[...Dp(ole(e)).diagnostics,{code:"SHACL_SCOPE",path:"",severity:"warning",message:"SHACL 1.0 graph preservation, property paths and Core target selection only. Constraint validation, imports, general entailment and SHACL 1.2 are not implemented."}]}function b6e(){return new nt().register(h6e,g6e)}function v6e(e){return We(e,b6e())}function _6e(e){let t=v6e(e);if(!t.valid)throw new U("SHACL_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((i)=>i.id==="dataset")?.elements.find((i)=>i.id==="dataset")?.extensions[sle];if(!n||e.vocabularies[sle]?.version!=="0.1.0")throw new U("SHACL_PAYLOAD","Expected pinned shapes graph");let r=ole(n);return rh(r),r}function ale(e){return rh(_6e(e))}var lle={id:"umf.dbt.manifest",version:"0.1.0",coreVersion:"0.1.0",description:"Exact dbt manifest JSON with pinned v12 shape inspection",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:dbt:manifest:0.1.0",type:"object",properties:{profile:{const:"dbt-manifest-json"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-022; native warnings never justify source loss; shape checks do not prove compilation or graph validity",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"dbt manifest",version:"v12 grammar; dbt Core 1.10.0 fixture",subset:"Exact artifact preservation, copied edits and schema-shape diagnostics; no graph or execution validity"},evidence:["tests/dbt/manifest.test.ts","fixtures/dbt/oracle-results.json","fixtures/dbt/browser-results.json"]}};var cle={$schema:"https://json-schema.org/draft/2020-12/schema",type:"object",title:"WritableManifest",properties:{metadata:{type:"object",title:"ManifestMetadata",description:"Metadata about the manifest",properties:{dbt_schema_version:{type:"string"},dbt_version:{type:"string",default:"1.11.6"},generated_at:{type:"string"},invocation_id:{anyOf:[{type:"string"},{type:"null"}]},invocation_started_at:{anyOf:[{type:"string"},{type:"null"}]},env:{type:"object",additionalProperties:{type:"string"},propertyNames:{type:"string"}},project_name:{description:"Name of the root project",anyOf:[{type:"string"},{type:"null"}],default:null},project_id:{description:"A unique identifier for the project, hashed from the project name",anyOf:[{type:"string"},{type:"null"}],default:null},user_id:{description:"A unique identifier for the user",anyOf:[{type:"string",format:"uuid"},{type:"null"}],default:null},send_anonymous_usage_stats:{description:"Whether dbt is configured to send anonymous usage statistics",anyOf:[{type:"boolean"},{type:"null"}],default:null},adapter_type:{description:"The type name of the adapter",anyOf:[{type:"string"},{type:"null"}],default:null},quoting:{description:"The quoting configuration for the project",anyOf:[{type:"object",title:"Quoting",properties:{database:{anyOf:[{type:"boolean"},{type:"null"}],default:null},schema:{anyOf:[{type:"boolean"},{type:"null"}],default:null},identifier:{anyOf:[{type:"boolean"},{type:"null"}],default:null},column:{anyOf:[{type:"boolean"},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},run_started_at:{description:"The timestamp when the run started",anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},nodes:{type:"object",description:"The nodes defined in the dbt project and its dependencies",additionalProperties:{anyOf:[{type:"object",title:"Seed",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"seed"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"SeedConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"seed"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},delimiter:{type:"string",default:","},quote_columns:{anyOf:[{type:"boolean"},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},root_path:{anyOf:[{type:"string"},{type:"null"}],default:null},depends_on:{type:"object",title:"MacroDependsOn",properties:{macros:{type:"array",items:{type:"string"}}},additionalProperties:!1},defer_relation:{anyOf:[{type:"object",title:"DeferRelation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},alias:{type:"string"},relation_name:{anyOf:[{type:"string"},{type:"null"}]},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},name:{type:"string"},description:{type:"string"},compiled_code:{anyOf:[{type:"string"},{type:"null"}]},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{anyOf:[{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},{type:"null"}]}},additionalProperties:!1,required:["database","schema","alias","relation_name","resource_type","name","description","compiled_code","meta","tags","config"]},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"Analysis",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"analysis"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"SingularTest",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"test"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"TestConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:"dbt_test__audit"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"test"},severity:{type:"string",default:"ERROR",pattern:"^([Ww][Aa][Rr][Nn]|[Ee][Rr][Rr][Oo][Rr])$"},store_failures:{anyOf:[{type:"boolean"},{type:"null"}],default:null},store_failures_as:{anyOf:[{type:"string"},{type:"null"}],default:null},where:{anyOf:[{type:"string"},{type:"null"}],default:null},limit:{anyOf:[{type:"integer"},{type:"null"}],default:null},fail_calc:{type:"string",default:"count(*)"},warn_if:{type:"string",default:"!= 0"},error_if:{type:"string",default:"!= 0"}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"HookNode",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"operation"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"Model",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"model"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"ModelConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},access:{enum:["private","protected","public"],default:"protected"},freshness:{anyOf:[{type:"object",title:"ModelFreshness",properties:{build_after:{type:"object",title:"ModelBuildAfter",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null},updates_on:{enum:["all","any"],default:"any"}},additionalProperties:!0}},additionalProperties:!0,required:["build_after"]},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},access:{enum:["private","protected","public"],default:"protected"},constraints:{type:"array",items:{type:"object",title:"ModelLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}},columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null},latest_version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null},deprecation_date:{anyOf:[{type:"string"},{type:"null"}],default:null},defer_relation:{anyOf:[{type:"object",title:"DeferRelation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},alias:{type:"string"},relation_name:{anyOf:[{type:"string"},{type:"null"}]},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},name:{type:"string"},description:{type:"string"},compiled_code:{anyOf:[{type:"string"},{type:"null"}]},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{anyOf:[{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},{type:"null"}]}},additionalProperties:!1,required:["database","schema","alias","relation_name","resource_type","name","description","compiled_code","meta","tags","config"]},{type:"null"}],default:null},primary_key:{type:"array",items:{type:"string"}},time_spine:{anyOf:[{type:"object",title:"TimeSpine",properties:{standard_granularity_column:{type:"string"},custom_granularities:{type:"array",items:{type:"object",title:"CustomGranularity",properties:{name:{type:"string"},column_name:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}}},additionalProperties:!1,required:["standard_granularity_column"]},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"SqlOperation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"sql_operation"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"GenericTest",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"test"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"TestConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:"dbt_test__audit"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"test"},severity:{type:"string",default:"ERROR",pattern:"^([Ww][Aa][Rr][Nn]|[Ee][Rr][Rr][Oo][Rr])$"},store_failures:{anyOf:[{type:"boolean"},{type:"null"}],default:null},store_failures_as:{anyOf:[{type:"string"},{type:"null"}],default:null},where:{anyOf:[{type:"string"},{type:"null"}],default:null},limit:{anyOf:[{type:"integer"},{type:"null"}],default:null},fail_calc:{type:"string",default:"count(*)"},warn_if:{type:"string",default:"!= 0"},error_if:{type:"string",default:"!= 0"}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},column_name:{anyOf:[{type:"string"},{type:"null"}],default:null},file_key_name:{anyOf:[{type:"string"},{type:"null"}],default:null},attached_node:{anyOf:[{type:"string"},{type:"null"}],default:null},test_metadata:{type:"object",title:"TestMetadata",properties:{name:{type:"string",default:"test"},kwargs:{type:"object",propertyNames:{type:"string"}},namespace:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"Snapshot",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"snapshot"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"SnapshotConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"snapshot"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},target_schema:{anyOf:[{type:"string"},{type:"null"}],default:null},target_database:{anyOf:[{type:"string"},{type:"null"}],default:null},updated_at:{anyOf:[{type:"string"},{type:"null"}],default:null},check_cols:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},snapshot_meta_column_names:{type:"object",title:"SnapshotMetaColumnNames",properties:{dbt_valid_to:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_valid_from:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_scd_id:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_updated_at:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_is_deleted:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},dbt_valid_to_current:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},defer_relation:{anyOf:[{type:"object",title:"DeferRelation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},alias:{type:"string"},relation_name:{anyOf:[{type:"string"},{type:"null"}]},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},name:{type:"string"},description:{type:"string"},compiled_code:{anyOf:[{type:"string"},{type:"null"}]},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{anyOf:[{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},{type:"null"}]}},additionalProperties:!1,required:["database","schema","alias","relation_name","resource_type","name","description","compiled_code","meta","tags","config"]},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum","config"]},{type:"object",title:"Function",properties:{returns:{type:"object",title:"FunctionReturns",properties:{data_type:{type:"string"},description:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["data_type"]},database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"function"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"FunctionConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"function"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},type:{enum:["scalar","aggregate","table"],default:"scalar"},volatility:{anyOf:[{enum:["deterministic","stable","non-deterministic"]},{type:"null"}],default:null},runtime_version:{anyOf:[{type:"string"},{type:"null"}],default:null},entry_point:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},arguments:{type:"array",items:{type:"object",title:"FunctionArgument",properties:{name:{type:"string"},data_type:{type:"string"},description:{anyOf:[{type:"string"},{type:"null"}],default:null},default_value:{anyOf:[{},{type:"null"}],default:null}},additionalProperties:!1,required:["name","data_type"]}}},additionalProperties:!1,required:["returns","database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum","config"]}]},propertyNames:{type:"string"}},sources:{type:"object",description:"The sources defined in the dbt project and its dependencies",additionalProperties:{type:"object",title:"SourceDefinition",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"source"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},source_name:{type:"string"},source_description:{type:"string"},loader:{type:"string"},identifier:{type:"string"},quoting:{type:"object",title:"Quoting",properties:{database:{anyOf:[{type:"boolean"},{type:"null"}],default:null},schema:{anyOf:[{type:"boolean"},{type:"null"}],default:null},identifier:{anyOf:[{type:"boolean"},{type:"null"}],default:null},column:{anyOf:[{type:"boolean"},{type:"null"}],default:null}},additionalProperties:!1},loaded_at_field:{anyOf:[{type:"string"},{type:"null"}],default:null},loaded_at_query:{anyOf:[{type:"string"},{type:"null"}],default:null},freshness:{anyOf:[{type:"object",title:"FreshnessThreshold",properties:{warn_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},error_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},filter:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},external:{anyOf:[{type:"object",title:"ExternalTable",properties:{_extra:{type:"object",propertyNames:{type:"string"}},location:{anyOf:[{type:"string"},{type:"null"}],default:null},file_format:{anyOf:[{type:"string"},{type:"null"}],default:null},row_format:{anyOf:[{type:"string"},{type:"null"}],default:null},tbl_properties:{anyOf:[{type:"string"},{type:"null"}],default:null},partitions:{anyOf:[{type:"array",items:{type:"string"}},{type:"array",items:{type:"object",title:"ExternalPartition",properties:{_extra:{type:"object",propertyNames:{type:"string"}},name:{type:"string",default:""},description:{type:"string",default:""},data_type:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0}},{type:"null"}],default:null}},additionalProperties:!0},{type:"null"}],default:null},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},source_meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{type:"object",title:"SourceConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},event_time:{default:null},freshness:{anyOf:[{type:"object",title:"FreshnessThreshold",properties:{warn_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},error_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},filter:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},loaded_at_field:{anyOf:[{type:"string"},{type:"null"}],default:null},loaded_at_query:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},created_at:{type:"number"},unrendered_database:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_schema:{anyOf:[{type:"string"},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","source_name","source_description","loader","identifier"]},propertyNames:{type:"string"}},macros:{type:"object",description:"The macros defined in the dbt project and its dependencies",additionalProperties:{type:"object",title:"Macro",properties:{name:{type:"string"},resource_type:{const:"macro"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},macro_sql:{type:"string"},depends_on:{type:"object",title:"MacroDependsOn",properties:{macros:{type:"array",items:{type:"string"}}},additionalProperties:!1},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},arguments:{type:"array",items:{type:"object",title:"MacroArgument",properties:{name:{type:"string"},type:{anyOf:[{type:"string"},{type:"null"}],default:null},description:{type:"string",default:""}},additionalProperties:!1,required:["name"]}},created_at:{type:"number"},supported_languages:{anyOf:[{type:"array",items:{enum:["python","sql"]}},{type:"null"}],default:null}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","macro_sql"]},propertyNames:{type:"string"}},docs:{type:"object",description:"The docs defined in the dbt project and its dependencies",additionalProperties:{type:"object",title:"Documentation",properties:{name:{type:"string"},resource_type:{const:"doc"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},block_contents:{type:"string"}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","block_contents"]},propertyNames:{type:"string"}},exposures:{type:"object",description:"The exposures defined in the dbt project and its dependencies",additionalProperties:{type:"object",title:"Exposure",properties:{name:{type:"string"},resource_type:{const:"exposure"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},type:{enum:["dashboard","notebook","analysis","ml","application"]},owner:{type:"object",title:"Owner",properties:{_extra:{type:"object",propertyNames:{type:"string"}},email:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},name:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},description:{type:"string",default:""},label:{anyOf:[{type:"string"},{type:"null"}],default:null},maturity:{anyOf:[{enum:["low","medium","high"]},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{type:"object",title:"ExposureConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},tags:{type:"array",items:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},url:{anyOf:[{type:"string"},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},created_at:{type:"number"}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","type","owner"]},propertyNames:{type:"string"}},metrics:{type:"object",description:"The metrics defined in the dbt project and its dependencies",additionalProperties:{type:"object",title:"Metric",properties:{name:{type:"string"},resource_type:{const:"metric"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},description:{type:"string"},label:{type:"string"},type:{enum:["simple","ratio","cumulative","derived","conversion"]},type_params:{type:"object",title:"MetricTypeParams",properties:{measure:{anyOf:[{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null},input_measures:{type:"array",items:{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},numerator:{anyOf:[{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null},denominator:{anyOf:[{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},grain_to_date:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},metrics:{anyOf:[{type:"array",items:{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},{type:"null"}],default:null},conversion_type_params:{anyOf:[{type:"object",title:"ConversionTypeParams",properties:{base_measure:{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},conversion_measure:{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},entity:{type:"string"},calculation:{enum:["conversions","conversion_rate"],default:"conversion_rate"},window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},constant_properties:{anyOf:[{type:"array",items:{type:"object",title:"ConstantPropertyInput",properties:{base_property:{type:"string"},conversion_property:{type:"string"}},additionalProperties:!1,required:["base_property","conversion_property"]}},{type:"null"}],default:null}},additionalProperties:!1,required:["base_measure","conversion_measure","entity"]},{type:"null"}],default:null},cumulative_type_params:{anyOf:[{type:"object",title:"CumulativeTypeParams",properties:{window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},grain_to_date:{anyOf:[{type:"string"},{type:"null"}],default:null},period_agg:{enum:["first","last","average"],default:"first"},metric:{anyOf:[{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},metric_aggregation_params:{anyOf:[{type:"object",title:"MetricAggregationParams",properties:{semantic_model:{type:"string"},agg:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},agg_params:{anyOf:[{type:"object",title:"MeasureAggregationParameters",properties:{percentile:{anyOf:[{type:"number"},{type:"null"}],default:null},use_discrete_percentile:{type:"boolean",default:!1},use_approximate_percentile:{type:"boolean",default:!1}},additionalProperties:!1},{type:"null"}],default:null},agg_time_dimension:{anyOf:[{type:"string"},{type:"null"}],default:null},non_additive_dimension:{anyOf:[{type:"object",title:"NonAdditiveDimension",properties:{name:{type:"string"},window_choice:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},window_groupings:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["name","window_choice","window_groupings"]},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["semantic_model","agg"]},{type:"null"}],default:null}},additionalProperties:!1},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},time_granularity:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{type:"object",title:"MetricConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},group:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},created_at:{type:"number"},group:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","description","label","type","type_params"]},propertyNames:{type:"string"}},groups:{type:"object",description:"The groups defined in the dbt project",additionalProperties:{type:"object",title:"Group",properties:{name:{type:"string"},resource_type:{const:"group"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},owner:{type:"object",title:"Owner",properties:{_extra:{type:"object",propertyNames:{type:"string"}},email:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},name:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},description:{anyOf:[{type:"string"},{type:"null"}],default:null},config:{type:"object",title:"GroupConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","owner"]},propertyNames:{type:"string"}},selectors:{type:"object",description:"The selectors defined in selectors.yml",propertyNames:{type:"string"}},disabled:{description:"A mapping of the disabled nodes in the target",anyOf:[{type:"object",additionalProperties:{type:"array",items:{anyOf:[{type:"object",title:"Seed",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"seed"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"SeedConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"seed"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},delimiter:{type:"string",default:","},quote_columns:{anyOf:[{type:"boolean"},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},root_path:{anyOf:[{type:"string"},{type:"null"}],default:null},depends_on:{type:"object",title:"MacroDependsOn",properties:{macros:{type:"array",items:{type:"string"}}},additionalProperties:!1},defer_relation:{anyOf:[{type:"object",title:"DeferRelation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},alias:{type:"string"},relation_name:{anyOf:[{type:"string"},{type:"null"}]},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},name:{type:"string"},description:{type:"string"},compiled_code:{anyOf:[{type:"string"},{type:"null"}]},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{anyOf:[{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},{type:"null"}]}},additionalProperties:!1,required:["database","schema","alias","relation_name","resource_type","name","description","compiled_code","meta","tags","config"]},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"Analysis",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"analysis"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"SingularTest",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"test"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"TestConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:"dbt_test__audit"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"test"},severity:{type:"string",default:"ERROR",pattern:"^([Ww][Aa][Rr][Nn]|[Ee][Rr][Rr][Oo][Rr])$"},store_failures:{anyOf:[{type:"boolean"},{type:"null"}],default:null},store_failures_as:{anyOf:[{type:"string"},{type:"null"}],default:null},where:{anyOf:[{type:"string"},{type:"null"}],default:null},limit:{anyOf:[{type:"integer"},{type:"null"}],default:null},fail_calc:{type:"string",default:"count(*)"},warn_if:{type:"string",default:"!= 0"},error_if:{type:"string",default:"!= 0"}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"HookNode",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"operation"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"Model",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"model"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"ModelConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},access:{enum:["private","protected","public"],default:"protected"},freshness:{anyOf:[{type:"object",title:"ModelFreshness",properties:{build_after:{type:"object",title:"ModelBuildAfter",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null},updates_on:{enum:["all","any"],default:"any"}},additionalProperties:!0}},additionalProperties:!0,required:["build_after"]},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},access:{enum:["private","protected","public"],default:"protected"},constraints:{type:"array",items:{type:"object",title:"ModelLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}},columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null},latest_version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null},deprecation_date:{anyOf:[{type:"string"},{type:"null"}],default:null},defer_relation:{anyOf:[{type:"object",title:"DeferRelation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},alias:{type:"string"},relation_name:{anyOf:[{type:"string"},{type:"null"}]},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},name:{type:"string"},description:{type:"string"},compiled_code:{anyOf:[{type:"string"},{type:"null"}]},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{anyOf:[{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},{type:"null"}]}},additionalProperties:!1,required:["database","schema","alias","relation_name","resource_type","name","description","compiled_code","meta","tags","config"]},{type:"null"}],default:null},primary_key:{type:"array",items:{type:"string"}},time_spine:{anyOf:[{type:"object",title:"TimeSpine",properties:{standard_granularity_column:{type:"string"},custom_granularities:{type:"array",items:{type:"object",title:"CustomGranularity",properties:{name:{type:"string"},column_name:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}}},additionalProperties:!1,required:["standard_granularity_column"]},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"SqlOperation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"sql_operation"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"GenericTest",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"test"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"TestConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:"dbt_test__audit"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"test"},severity:{type:"string",default:"ERROR",pattern:"^([Ww][Aa][Rr][Nn]|[Ee][Rr][Rr][Oo][Rr])$"},store_failures:{anyOf:[{type:"boolean"},{type:"null"}],default:null},store_failures_as:{anyOf:[{type:"string"},{type:"null"}],default:null},where:{anyOf:[{type:"string"},{type:"null"}],default:null},limit:{anyOf:[{type:"integer"},{type:"null"}],default:null},fail_calc:{type:"string",default:"count(*)"},warn_if:{type:"string",default:"!= 0"},error_if:{type:"string",default:"!= 0"}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},column_name:{anyOf:[{type:"string"},{type:"null"}],default:null},file_key_name:{anyOf:[{type:"string"},{type:"null"}],default:null},attached_node:{anyOf:[{type:"string"},{type:"null"}],default:null},test_metadata:{type:"object",title:"TestMetadata",properties:{name:{type:"string",default:"test"},kwargs:{type:"object",propertyNames:{type:"string"}},namespace:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"Snapshot",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"snapshot"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"SnapshotConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"snapshot"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},target_schema:{anyOf:[{type:"string"},{type:"null"}],default:null},target_database:{anyOf:[{type:"string"},{type:"null"}],default:null},updated_at:{anyOf:[{type:"string"},{type:"null"}],default:null},check_cols:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},snapshot_meta_column_names:{type:"object",title:"SnapshotMetaColumnNames",properties:{dbt_valid_to:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_valid_from:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_scd_id:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_updated_at:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_is_deleted:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},dbt_valid_to_current:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},defer_relation:{anyOf:[{type:"object",title:"DeferRelation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},alias:{type:"string"},relation_name:{anyOf:[{type:"string"},{type:"null"}]},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},name:{type:"string"},description:{type:"string"},compiled_code:{anyOf:[{type:"string"},{type:"null"}]},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{anyOf:[{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},{type:"null"}]}},additionalProperties:!1,required:["database","schema","alias","relation_name","resource_type","name","description","compiled_code","meta","tags","config"]},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum","config"]},{type:"object",title:"Function",properties:{returns:{type:"object",title:"FunctionReturns",properties:{data_type:{type:"string"},description:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["data_type"]},database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"function"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"FunctionConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"function"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},type:{enum:["scalar","aggregate","table"],default:"scalar"},volatility:{anyOf:[{enum:["deterministic","stable","non-deterministic"]},{type:"null"}],default:null},runtime_version:{anyOf:[{type:"string"},{type:"null"}],default:null},entry_point:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},arguments:{type:"array",items:{type:"object",title:"FunctionArgument",properties:{name:{type:"string"},data_type:{type:"string"},description:{anyOf:[{type:"string"},{type:"null"}],default:null},default_value:{anyOf:[{},{type:"null"}],default:null}},additionalProperties:!1,required:["name","data_type"]}}},additionalProperties:!1,required:["returns","database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum","config"]},{type:"object",title:"SourceDefinition",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"source"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},source_name:{type:"string"},source_description:{type:"string"},loader:{type:"string"},identifier:{type:"string"},quoting:{type:"object",title:"Quoting",properties:{database:{anyOf:[{type:"boolean"},{type:"null"}],default:null},schema:{anyOf:[{type:"boolean"},{type:"null"}],default:null},identifier:{anyOf:[{type:"boolean"},{type:"null"}],default:null},column:{anyOf:[{type:"boolean"},{type:"null"}],default:null}},additionalProperties:!1},loaded_at_field:{anyOf:[{type:"string"},{type:"null"}],default:null},loaded_at_query:{anyOf:[{type:"string"},{type:"null"}],default:null},freshness:{anyOf:[{type:"object",title:"FreshnessThreshold",properties:{warn_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},error_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},filter:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},external:{anyOf:[{type:"object",title:"ExternalTable",properties:{_extra:{type:"object",propertyNames:{type:"string"}},location:{anyOf:[{type:"string"},{type:"null"}],default:null},file_format:{anyOf:[{type:"string"},{type:"null"}],default:null},row_format:{anyOf:[{type:"string"},{type:"null"}],default:null},tbl_properties:{anyOf:[{type:"string"},{type:"null"}],default:null},partitions:{anyOf:[{type:"array",items:{type:"string"}},{type:"array",items:{type:"object",title:"ExternalPartition",properties:{_extra:{type:"object",propertyNames:{type:"string"}},name:{type:"string",default:""},description:{type:"string",default:""},data_type:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0}},{type:"null"}],default:null}},additionalProperties:!0},{type:"null"}],default:null},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},source_meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{type:"object",title:"SourceConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},event_time:{default:null},freshness:{anyOf:[{type:"object",title:"FreshnessThreshold",properties:{warn_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},error_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},filter:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},loaded_at_field:{anyOf:[{type:"string"},{type:"null"}],default:null},loaded_at_query:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},created_at:{type:"number"},unrendered_database:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_schema:{anyOf:[{type:"string"},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","source_name","source_description","loader","identifier"]},{type:"object",title:"Exposure",properties:{name:{type:"string"},resource_type:{const:"exposure"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},type:{enum:["dashboard","notebook","analysis","ml","application"]},owner:{type:"object",title:"Owner",properties:{_extra:{type:"object",propertyNames:{type:"string"}},email:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},name:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},description:{type:"string",default:""},label:{anyOf:[{type:"string"},{type:"null"}],default:null},maturity:{anyOf:[{enum:["low","medium","high"]},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{type:"object",title:"ExposureConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},tags:{type:"array",items:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},url:{anyOf:[{type:"string"},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},created_at:{type:"number"}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","type","owner"]},{type:"object",title:"Metric",properties:{name:{type:"string"},resource_type:{const:"metric"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},description:{type:"string"},label:{type:"string"},type:{enum:["simple","ratio","cumulative","derived","conversion"]},type_params:{type:"object",title:"MetricTypeParams",properties:{measure:{anyOf:[{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null},input_measures:{type:"array",items:{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},numerator:{anyOf:[{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null},denominator:{anyOf:[{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},grain_to_date:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},metrics:{anyOf:[{type:"array",items:{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},{type:"null"}],default:null},conversion_type_params:{anyOf:[{type:"object",title:"ConversionTypeParams",properties:{base_measure:{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},conversion_measure:{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},entity:{type:"string"},calculation:{enum:["conversions","conversion_rate"],default:"conversion_rate"},window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},constant_properties:{anyOf:[{type:"array",items:{type:"object",title:"ConstantPropertyInput",properties:{base_property:{type:"string"},conversion_property:{type:"string"}},additionalProperties:!1,required:["base_property","conversion_property"]}},{type:"null"}],default:null}},additionalProperties:!1,required:["base_measure","conversion_measure","entity"]},{type:"null"}],default:null},cumulative_type_params:{anyOf:[{type:"object",title:"CumulativeTypeParams",properties:{window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},grain_to_date:{anyOf:[{type:"string"},{type:"null"}],default:null},period_agg:{enum:["first","last","average"],default:"first"},metric:{anyOf:[{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},metric_aggregation_params:{anyOf:[{type:"object",title:"MetricAggregationParams",properties:{semantic_model:{type:"string"},agg:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},agg_params:{anyOf:[{type:"object",title:"MeasureAggregationParameters",properties:{percentile:{anyOf:[{type:"number"},{type:"null"}],default:null},use_discrete_percentile:{type:"boolean",default:!1},use_approximate_percentile:{type:"boolean",default:!1}},additionalProperties:!1},{type:"null"}],default:null},agg_time_dimension:{anyOf:[{type:"string"},{type:"null"}],default:null},non_additive_dimension:{anyOf:[{type:"object",title:"NonAdditiveDimension",properties:{name:{type:"string"},window_choice:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},window_groupings:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["name","window_choice","window_groupings"]},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["semantic_model","agg"]},{type:"null"}],default:null}},additionalProperties:!1},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},time_granularity:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{type:"object",title:"MetricConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},group:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},created_at:{type:"number"},group:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","description","label","type","type_params"]},{type:"object",title:"SavedQuery",properties:{name:{type:"string"},resource_type:{const:"saved_query"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},query_params:{type:"object",title:"QueryParams",properties:{metrics:{type:"array",items:{type:"string"}},group_by:{type:"array",items:{type:"string"}},where:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}]},order_by:{type:"array",items:{type:"string"}},limit:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["metrics","group_by","where"]},exports:{type:"array",items:{type:"object",title:"Export",properties:{name:{type:"string"},config:{type:"object",title:"ExportConfig",properties:{export_as:{enum:["table","view"]},schema_name:{anyOf:[{type:"string"},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["export_as"]},unrendered_config:{type:"object",additionalProperties:{type:"string"},propertyNames:{type:"string"}}},additionalProperties:!1,required:["name","config"]}},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},config:{type:"object",title:"SavedQueryConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},group:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},export_as:{anyOf:[{enum:["table","view"]},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},cache:{type:"object",title:"SavedQueryCache",properties:{enabled:{type:"boolean",default:!1}},additionalProperties:!1}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},created_at:{type:"number"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","query_params","exports"]},{type:"object",title:"SemanticModel",properties:{name:{type:"string"},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},model:{type:"string"},node_relation:{anyOf:[{type:"object",title:"NodeRelation",properties:{alias:{type:"string"},schema_name:{type:"string"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:""}},additionalProperties:!1,required:["alias","schema_name"]},{type:"null"}]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},defaults:{anyOf:[{type:"object",title:"Defaults",properties:{agg_time_dimension:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},entities:{type:"array",items:{type:"object",title:"Entity",properties:{name:{type:"string"},type:{enum:["foreign","natural","primary","unique"]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},role:{anyOf:[{type:"string"},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},config:{anyOf:[{type:"object",title:"SemanticLayerElementConfig",properties:{meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["name","type"]}},measures:{type:"array",items:{type:"object",title:"Measure",properties:{name:{type:"string"},agg:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},create_metric:{type:"boolean",default:!1},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},agg_params:{anyOf:[{type:"object",title:"MeasureAggregationParameters",properties:{percentile:{anyOf:[{type:"number"},{type:"null"}],default:null},use_discrete_percentile:{type:"boolean",default:!1},use_approximate_percentile:{type:"boolean",default:!1}},additionalProperties:!1},{type:"null"}],default:null},non_additive_dimension:{anyOf:[{type:"object",title:"NonAdditiveDimension",properties:{name:{type:"string"},window_choice:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},window_groupings:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["name","window_choice","window_groupings"]},{type:"null"}],default:null},agg_time_dimension:{anyOf:[{type:"string"},{type:"null"}],default:null},config:{anyOf:[{type:"object",title:"SemanticLayerElementConfig",properties:{meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["name","agg"]}},dimensions:{type:"array",items:{type:"object",title:"Dimension",properties:{name:{type:"string"},type:{enum:["categorical","time"]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},is_partition:{type:"boolean",default:!1},type_params:{anyOf:[{type:"object",title:"DimensionTypeParams",properties:{time_granularity:{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},validity_params:{anyOf:[{type:"object",title:"DimensionValidityParams",properties:{is_start:{type:"boolean",default:!1},is_end:{type:"boolean",default:!1}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["time_granularity"]},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},config:{anyOf:[{type:"object",title:"SemanticLayerElementConfig",properties:{meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["name","type"]}},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},created_at:{type:"number"},config:{type:"object",title:"SemanticModelConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},group:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},primary_entity:{anyOf:[{type:"string"},{type:"null"}],default:null},group:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","model","node_relation"]},{type:"object",title:"UnitTestDefinition",properties:{model:{type:"string"},given:{type:"array",items:{type:"object",title:"UnitTestInputFixture",properties:{input:{type:"string"},rows:{anyOf:[{type:"string"},{type:"array",items:{type:"object",propertyNames:{type:"string"}}},{type:"null"}],default:null},format:{enum:["csv","dict","sql"],default:"dict"},fixture:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["input"]}},expect:{type:"object",title:"UnitTestOutputFixture",properties:{rows:{anyOf:[{type:"string"},{type:"array",items:{type:"object",propertyNames:{type:"string"}}},{type:"null"}],default:null},format:{enum:["csv","dict","sql"],default:"dict"},fixture:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},name:{type:"string"},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},description:{type:"string",default:""},overrides:{anyOf:[{type:"object",title:"UnitTestOverrides",properties:{macros:{type:"object",propertyNames:{type:"string"}},vars:{type:"object",propertyNames:{type:"string"}},env_vars:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},config:{type:"object",title:"UnitTestConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},tags:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}}]},meta:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0}},additionalProperties:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},created_at:{type:"number"},versions:{anyOf:[{type:"object",title:"UnitTestNodeVersions",properties:{include:{anyOf:[{type:"array",items:{anyOf:[{type:"string"},{type:"number"}]}},{type:"null"}],default:null},exclude:{anyOf:[{type:"array",items:{anyOf:[{type:"string"},{type:"number"}]}},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["model","given","expect","name","resource_type","package_name","path","original_file_path","unique_id","fqn"]}]}},propertyNames:{type:"string"}},{type:"null"}]},parent_map:{description:"A mapping from child nodes to their dependencies",anyOf:[{type:"object",additionalProperties:{type:"array",items:{type:"string"}},propertyNames:{type:"string"}},{type:"null"}]},child_map:{description:"A mapping from parent nodes to their dependents",anyOf:[{type:"object",additionalProperties:{type:"array",items:{type:"string"}},propertyNames:{type:"string"}},{type:"null"}]},group_map:{description:"A mapping from group names to their nodes",anyOf:[{type:"object",additionalProperties:{type:"array",items:{type:"string"}},propertyNames:{type:"string"}},{type:"null"}]},saved_queries:{type:"object",description:"The saved queries defined in the dbt project",additionalProperties:{type:"object",title:"SavedQuery",properties:{name:{type:"string"},resource_type:{const:"saved_query"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},query_params:{type:"object",title:"QueryParams",properties:{metrics:{type:"array",items:{type:"string"}},group_by:{type:"array",items:{type:"string"}},where:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}]},order_by:{type:"array",items:{type:"string"}},limit:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["metrics","group_by","where"]},exports:{type:"array",items:{type:"object",title:"Export",properties:{name:{type:"string"},config:{type:"object",title:"ExportConfig",properties:{export_as:{enum:["table","view"]},schema_name:{anyOf:[{type:"string"},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["export_as"]},unrendered_config:{type:"object",additionalProperties:{type:"string"},propertyNames:{type:"string"}}},additionalProperties:!1,required:["name","config"]}},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},config:{type:"object",title:"SavedQueryConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},group:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},export_as:{anyOf:[{enum:["table","view"]},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},cache:{type:"object",title:"SavedQueryCache",properties:{enabled:{type:"boolean",default:!1}},additionalProperties:!1}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},created_at:{type:"number"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","query_params","exports"]},propertyNames:{type:"string"}},semantic_models:{type:"object",description:"The semantic models defined in the dbt project",additionalProperties:{type:"object",title:"SemanticModel",properties:{name:{type:"string"},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},model:{type:"string"},node_relation:{anyOf:[{type:"object",title:"NodeRelation",properties:{alias:{type:"string"},schema_name:{type:"string"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:""}},additionalProperties:!1,required:["alias","schema_name"]},{type:"null"}]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},defaults:{anyOf:[{type:"object",title:"Defaults",properties:{agg_time_dimension:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},entities:{type:"array",items:{type:"object",title:"Entity",properties:{name:{type:"string"},type:{enum:["foreign","natural","primary","unique"]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},role:{anyOf:[{type:"string"},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},config:{anyOf:[{type:"object",title:"SemanticLayerElementConfig",properties:{meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["name","type"]}},measures:{type:"array",items:{type:"object",title:"Measure",properties:{name:{type:"string"},agg:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},create_metric:{type:"boolean",default:!1},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},agg_params:{anyOf:[{type:"object",title:"MeasureAggregationParameters",properties:{percentile:{anyOf:[{type:"number"},{type:"null"}],default:null},use_discrete_percentile:{type:"boolean",default:!1},use_approximate_percentile:{type:"boolean",default:!1}},additionalProperties:!1},{type:"null"}],default:null},non_additive_dimension:{anyOf:[{type:"object",title:"NonAdditiveDimension",properties:{name:{type:"string"},window_choice:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},window_groupings:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["name","window_choice","window_groupings"]},{type:"null"}],default:null},agg_time_dimension:{anyOf:[{type:"string"},{type:"null"}],default:null},config:{anyOf:[{type:"object",title:"SemanticLayerElementConfig",properties:{meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["name","agg"]}},dimensions:{type:"array",items:{type:"object",title:"Dimension",properties:{name:{type:"string"},type:{enum:["categorical","time"]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},is_partition:{type:"boolean",default:!1},type_params:{anyOf:[{type:"object",title:"DimensionTypeParams",properties:{time_granularity:{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},validity_params:{anyOf:[{type:"object",title:"DimensionValidityParams",properties:{is_start:{type:"boolean",default:!1},is_end:{type:"boolean",default:!1}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["time_granularity"]},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},config:{anyOf:[{type:"object",title:"SemanticLayerElementConfig",properties:{meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["name","type"]}},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},created_at:{type:"number"},config:{type:"object",title:"SemanticModelConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},group:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},primary_entity:{anyOf:[{type:"string"},{type:"null"}],default:null},group:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","model","node_relation"]},propertyNames:{type:"string"}},unit_tests:{type:"object",description:"The unit tests defined in the project",additionalProperties:{type:"object",title:"UnitTestDefinition",properties:{model:{type:"string"},given:{type:"array",items:{type:"object",title:"UnitTestInputFixture",properties:{input:{type:"string"},rows:{anyOf:[{type:"string"},{type:"array",items:{type:"object",propertyNames:{type:"string"}}},{type:"null"}],default:null},format:{enum:["csv","dict","sql"],default:"dict"},fixture:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["input"]}},expect:{type:"object",title:"UnitTestOutputFixture",properties:{rows:{anyOf:[{type:"string"},{type:"array",items:{type:"object",propertyNames:{type:"string"}}},{type:"null"}],default:null},format:{enum:["csv","dict","sql"],default:"dict"},fixture:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},name:{type:"string"},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},description:{type:"string",default:""},overrides:{anyOf:[{type:"object",title:"UnitTestOverrides",properties:{macros:{type:"object",propertyNames:{type:"string"}},vars:{type:"object",propertyNames:{type:"string"}},env_vars:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},config:{type:"object",title:"UnitTestConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},tags:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}}]},meta:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0}},additionalProperties:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},created_at:{type:"number"},versions:{anyOf:[{type:"object",title:"UnitTestNodeVersions",properties:{include:{anyOf:[{type:"array",items:{anyOf:[{type:"string"},{type:"number"}]}},{type:"null"}],default:null},exclude:{anyOf:[{type:"array",items:{anyOf:[{type:"string"},{type:"number"}]}},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["model","given","expect","name","resource_type","package_name","path","original_file_path","unique_id","fqn"]},propertyNames:{type:"string"}},functions:{type:"object",description:"The functions defined in the dbt project",additionalProperties:{type:"object",title:"Function",properties:{returns:{type:"object",title:"FunctionReturns",properties:{data_type:{type:"string"},description:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["data_type"]},database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"function"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"FunctionConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"function"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},type:{enum:["scalar","aggregate","table"],default:"scalar"},volatility:{anyOf:[{enum:["deterministic","stable","non-deterministic"]},{type:"null"}],default:null},runtime_version:{anyOf:[{type:"string"},{type:"null"}],default:null},entry_point:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},arguments:{type:"array",items:{type:"object",title:"FunctionArgument",properties:{name:{type:"string"},data_type:{type:"string"},description:{anyOf:[{type:"string"},{type:"null"}],default:null},default_value:{anyOf:[{},{type:"null"}],default:null}},additionalProperties:!1,required:["name","data_type"]}}},additionalProperties:!1,required:["returns","database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum","config"]},propertyNames:{type:"string"}}},additionalProperties:!1,required:["metadata","nodes","sources","macros","docs","exposures","metrics","groups","selectors","disabled","parent_map","child_map","group_map","saved_queries","semantic_models","unit_tests"],$id:"https://schemas.getdbt.com/dbt/manifest/v12.json"};var ule="umf.dbt.manifest",D6e=lle,lE;function T6e(e){let t=e,n=[{code:"DBT_MANIFEST_CONTEXT",path:"",severity:"warning",message:"Native schema shapes do not establish graph/SQL/Jinja validity, format constraints or exact-number constraints beyond JS precision"}],r=(a,l,c,u="warning")=>n.push({code:a,path:l,message:c,severity:u});if(Object.keys(t).some((a)=>!["profile","root"].includes(a)))r("DBT_MANIFEST_REPRESENTATION","","Unknown representation fields remain in UMF");function i(a,l){let c=a.kind==="null"?["kind"]:a.kind==="array"?["kind","items"]:a.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(a).some((u)=>!c.includes(u)))r("DBT_MANIFEST_REPRESENTATION",l,"Unknown tagged-tree fields remain in UMF");if(a.kind==="object")for(let[u,p]of Object.entries(a.members))i(p,l+"/"+Pe(u));if(a.kind==="array")a.items.forEach((u,p)=>i(u,l+"/"+p))}i(t.root,"");let s=t.root.kind==="object"?t.root.members.metadata:void 0,o=s?.kind==="object"?s.members.dbt_schema_version:void 0;if(o?.kind!=="string")return r("DBT_MANIFEST_STRUCTURE","/metadata/dbt_schema_version","Expected manifest object with metadata object and schema version string","error"),n;if(o.value!=="https://schemas.getdbt.com/dbt/manifest/v12.json")return r("DBT_MANIFEST_VERSION","/metadata/dbt_schema_version","Unknown artifact version preserved without interpretation"),n;if(lE??=mt(!1).compile(cle),!lE(JSON.parse(Be(t.root))))for(let a of(lE.errors??[]).slice(0,100))r("DBT_MANIFEST_NATIVE_SCHEMA",a.instancePath,a.message??"Native grammar mismatch");if((lE.errors?.length??0)>100)r("DBT_MANIFEST_DIAGNOSTICS_TRUNCATED","","More than 100 native schema diagnostics; first 100 retained");return n}function S6e(){return new nt().register(D6e,T6e)}function ple(e){return We(e,S6e())}function E6e(e){let t=ple(e);if(!t.valid)throw new U("DBT_MANIFEST_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="manifest")?.elements.find((r)=>r.id==="manifest")?.extensions[ule];if(!n||e.vocabularies[ule]?.version!=="0.1.0")throw new U("DBT_MANIFEST_PAYLOAD","Expected pinned dbt manifest payload");return Ae(n)}function dle(e){let t=E6e(e);if(ple(e).diagnostics.some((n)=>n.code==="DBT_MANIFEST_REPRESENTATION"))throw new U("DBT_MANIFEST_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var fle={id:"umf.arrow",version:"0.1.0",coreVersion:"0.1.0",description:"Arrow integration schema JSON with exact unknown content and ordered metadata",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:arrow:0.1.0",type:"object",properties:{profile:{const:"arrow-integration-schema"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-016. Exact schema JSON preservation is separate from native IPC and record-batch validity. Unknown types/properties and duplicate metadata remain authoritative in source.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Apache Arrow integration schema JSON",version:"Grammar profile 0.1.0; native feasibility evidence JS 21.2.0 / PyArrow 21.0.0",subset:"Schema JSON only, exact metadata/type parameter retention and candidate edits. Guarded schema-only IPC export via an explicit pinned backend; no arbitrary IPC import or array/data support claimed."},evidence:["tests/arrow/schema.test.ts","tests/arrow/ipc.test.ts","fixtures/arrow/capability-results.json","fixtures/arrow/public-ipc-oracle-results.json","fixtures/arrow/upstream/schema-results.json"]}};var hC={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:arrow:integration-schema:0.1.0",description:"Schema portion of Arrow integration JSON, including future type names and unknown properties retained without interpretation. Buffer/data validity and native IPC representability are separate.",type:"object",properties:{fields:{type:"array",items:{$ref:"#/$defs/field"}},metadata:{type:"array",items:{type:"object",properties:{key:{type:"string"},value:{type:"string"}},required:["key","value"],additionalProperties:!0}}},required:["fields"],additionalProperties:!0,$defs:{field:{type:"object",properties:{name:{type:"string"},nullable:{type:"boolean"},type:{$ref:"#/$defs/type"},children:{type:"array",items:{$ref:"#/$defs/field"}},metadata:{type:"array",items:{type:"object",properties:{key:{type:"string"},value:{type:"string"}},required:["key","value"],additionalProperties:!0}},dictionary:{type:"object",properties:{id:{type:"integer"},indexType:{type:"object",properties:{name:{const:"int"},bitWidth:{enum:[8,16,32,64]},isSigned:{type:"boolean"}},required:["name","bitWidth","isSigned"],additionalProperties:!0},isOrdered:{type:"boolean"}},required:["id"],additionalProperties:!0}},required:["name","nullable","type"],additionalProperties:!0},type:{anyOf:[{type:"object",properties:{name:{const:"null"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"NONE"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"bool"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"binary"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"largebinary"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"binaryview"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"utf8"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"largeutf8"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"utf8view"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"list"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"largelist"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"listview"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"largelistview"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"struct"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"struct_"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"runendencoded"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"int"},bitWidth:{enum:[8,16,32,64]},isSigned:{type:"boolean"}},required:["name","bitWidth","isSigned"],additionalProperties:!0},{type:"object",properties:{name:{const:"floatingpoint"},precision:{enum:["HALF","SINGLE","DOUBLE"]}},required:["name","precision"],additionalProperties:!0},{type:"object",properties:{name:{const:"decimal"},bitWidth:{enum:[32,64,128,256]},precision:{type:"integer",minimum:1,maximum:76},scale:{type:"integer",minimum:-2147483648,maximum:2147483647}},required:["name","precision","scale"],additionalProperties:!0},{type:"object",properties:{name:{const:"date"},unit:{enum:["DAY","MILLISECOND"]}},required:["name","unit"],additionalProperties:!0},{type:"object",properties:{name:{const:"time"},unit:{enum:["SECOND","MILLISECOND","MICROSECOND","NANOSECOND"]},bitWidth:{enum:[32,64]}},required:["name","unit","bitWidth"],additionalProperties:!0},{type:"object",properties:{name:{const:"timestamp"},unit:{enum:["SECOND","MILLISECOND","MICROSECOND","NANOSECOND"]},timezone:{type:["string","null"]}},required:["name","unit"],additionalProperties:!0},{type:"object",properties:{name:{const:"duration"},unit:{enum:["SECOND","MILLISECOND","MICROSECOND","NANOSECOND"]}},required:["name","unit"],additionalProperties:!0},{type:"object",properties:{name:{const:"interval"},unit:{enum:["YEAR_MONTH","DAY_TIME","MONTH_DAY_NANO"]}},required:["name","unit"],additionalProperties:!0},{type:"object",properties:{name:{const:"fixedsizebinary"},byteWidth:{type:"integer",minimum:0,maximum:2147483647}},required:["name","byteWidth"],additionalProperties:!0},{type:"object",properties:{name:{const:"fixedsizelist"},listSize:{type:"integer",minimum:0,maximum:2147483647}},required:["name","listSize"],additionalProperties:!0},{type:"object",properties:{name:{const:"map"},keysSorted:{type:"boolean"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"union"},mode:{enum:["DENSE","SPARSE"]},typeIds:{type:"array",items:{type:"integer",minimum:0,maximum:127},uniqueItems:!0}},required:["name","mode","typeIds"],additionalProperties:!0},{type:"object",properties:{name:{type:"string",not:{enum:["null","NONE","bool","binary","largebinary","binaryview","utf8","largeutf8","utf8view","list","largelist","listview","largelistview","struct","struct_","runendencoded","int","floatingpoint","decimal","date","time","timestamp","duration","interval","fixedsizebinary","fixedsizelist","map","union"]}}},required:["name"],additionalProperties:!0}]}}};var mle="umf.arrow",O6e=fle,P6e=new Map(hC.$defs.type.anyOf.filter((e)=>e.properties.name.const).map((e)=>[e.properties.name.const,e])),gC;function yle(e){let t=/^(-?)([0-9]+)(?:\.([0-9]+))?(?:[eE]([+-]?[0-9]+))?$/.exec(e);if(!t)return;let n=(t[2]+(t[3]??"")).replace(/^0+/,"");if(!n)return 0n;let r=BigInt((t[3]??"").length)-BigInt(t[4]??"0");if(r>0n){if(r>=BigInt(n.length)||!/^[0]+$/.test(n.slice(-Number(r))))return;n=n.slice(0,-Number(r))}else{if(BigInt(n.length)-r>19n)return;n+="0".repeat(Number(-r))}if(n.length>19)return;return BigInt(t[1]+n)}function $6e(e){let t=e,n=[{code:"ARROW_NATIVE_UNVERIFIED",path:"",severity:"warning",message:"Schema JSON preservation does not establish IPC, dictionary-data, extension-type or record-batch validity"}],r=(u,p,d,f="warning")=>n.push({code:u,path:p,message:d,severity:f});if(Object.keys(t).some((u)=>!["profile","root"].includes(u)))r("ARROW_REPRESENTATION","","Unknown representation fields must stay in UMF");function i(u,p){let d=u.kind==="null"?["kind"]:u.kind==="object"?["kind","members"]:u.kind==="array"?["kind","items"]:["kind","value"];if(Object.keys(u).some((f)=>!d.includes(f)))r("ARROW_REPRESENTATION",p,"Unknown tagged-tree fields must stay in UMF");if(u.kind==="object")for(let[f,m]of Object.entries(u.members))i(m,p+"/"+Pe(f));if(u.kind==="array")u.items.forEach((f,m)=>i(f,p+"/"+m))}i(t.root,"/root");let s=JSON.parse(Be(t.root));if(gC??=mt(!1).compile(hC),!gC(s)){for(let u of gC.errors??[])r("ARROW_STRUCTURE",u.instancePath,u.message??"Invalid schema JSON","error");return n}function o(u,p,d){for(let f of Object.keys(u))if(!p.includes(f))r("ARROW_UNKNOWN",d+"/"+Pe(f),"Native content retained without interpretation")}function a(u,p){let d=new Set;u.forEach((f,m)=>{if(o(f,["key","value"],p+"/"+m),d.has(f.key))r("ARROW_DUPLICATE_METADATA",p+"/"+m,"Ordered duplicate metadata retained; native Map conversion may collapse it");d.add(f.key)})}function l(u){let p=t.root;for(let d of wr(u))p=Dr(p,d);if(p.kind!=="number"||yle(p.value)===void 0)r("ARROW_INTEGER",u,"Known integer parameter must be exact, not a rounded host value","error")}function c(u,p){o(u,["name","nullable","type","children","metadata","dictionary"],p),a(u.metadata??[],p+"/metadata");let d=P6e.get(u.type.name);if(!d)r("ARROW_UNKNOWN_TYPE",p+"/type","Future or unrecognized Arrow type retained");else o(u.type,Object.keys(d.properties),p+"/type");if(d){for(let[m,y]of Object.entries(d.properties))if(Object.hasOwn(u.type,m)&&(y.type==="integer"||typeof y.enum?.[0]==="number"))l(p+"/type/"+Pe(m))}if(u.type.name==="union")u.type.typeIds.forEach((m,y)=>l(p+"/type/typeIds/"+y));let f=u.children??[];if(["list","largelist","listview","largelistview","fixedsizelist","map"].includes(u.type.name)&&f.length!==1)r("ARROW_CHILDREN",p+"/children","This native type requires one child field","error");if(u.type.name==="runendencoded"&&f.length!==2)r("ARROW_CHILDREN",p+"/children","Run-end encoding requires run-ends and values children","error");if(d&&!["list","largelist","listview","largelistview","fixedsizelist","map","struct","struct_","union","runendencoded"].includes(u.type.name)&&f.length)r("ARROW_CHILDREN",p+"/children","Primitive type cannot have child fields","error");if(u.type.name==="map"&&(f[0]?.nullable!==!1||!["struct","struct_"].includes(f[0]?.type?.name)||f[0]?.children?.length!==2||f[0]?.children?.[0]?.nullable!==!1))r("ARROW_MAP",p+"/children","Map requires non-null entries struct with two children and non-null key","error");if(u.type.name==="runendencoded"&&(f[0]?.nullable!==!1||f[0]?.type?.name!=="int"||f[0]?.type?.isSigned!==!0||![16,32,64].includes(f[0]?.type?.bitWidth)))r("ARROW_RUN_ENDS",p+"/children/0","Run ends must be non-null signed int16/int32/int64","error");if(u.type.name==="union"&&u.type.typeIds.length!==f.length)r("ARROW_UNION",p+"/type/typeIds","Union type IDs must correspond to children","error");if(u.type.name==="time"&&u.type.bitWidth!==(["SECOND","MILLISECOND"].includes(u.type.unit)?32:64))r("ARROW_TIME",p+"/type","Time unit and bit width disagree","error");if(u.type.name==="decimal"&&u.type.precision>{32:9,64:18,128:38,256:76}[u.type.bitWidth??128])r("ARROW_DECIMAL",p+"/type","Decimal precision exceeds its bit width","error");if(u.dictionary){let m=t.root;for(let h of wr(p+"/dictionary/id"))m=Dr(m,h);let y=m.kind==="number"?yle(m.value):void 0;if(y===void 0||y<-9223372036854775808n||y>9223372036854775807n)r("ARROW_DICTIONARY_ID",p+"/dictionary/id","Dictionary IDs must be exact signed 64-bit integers","error");if(o(u.dictionary,["id","indexType","isOrdered"],p+"/dictionary"),u.dictionary.indexType)l(p+"/dictionary/indexType/bitWidth"),o(u.dictionary.indexType,["name","bitWidth","isSigned"],p+"/dictionary/indexType")}f.forEach((m,y)=>c(m,p+"/children/"+y))}return o(s,["fields","metadata"],""),a(s.metadata??[],"/metadata"),s.fields.forEach((u,p)=>c(u,"/fields/"+p)),n}function I6e(){return new nt().register(O6e,$6e)}function hle(e){return We(e,I6e())}function A6e(e){let t=hle(e);if(!t.valid)throw new U("ARROW_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[mle];if(!n||e.vocabularies[mle]?.version!=="0.1.0")throw new U("ARROW_PAYLOAD","Expected Arrow schema payload");return Ae(n)}function gle(e){let t=A6e(e);if(hle(e).diagnostics.some((n)=>n.code==="ARROW_REPRESENTATION"))throw new U("ARROW_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var R6e={exportJsonSchemaBundle:NB,exportAvroBundle:O8,exportGraphqlBundle:Q6,exportOpenapiBundle:N4,exportDeltaTable:L4,exportDeltaLog:B4,exportIcebergTable:Y4,exportDbtSemanticManifest:r9,exportDbtArtifact:d9,exportTypeSpecSources:nne,exportSmithySources:lne,exportArrowIpcCapture:pne,exportParquetCapture:Ov,exportGeneralizedRdfDataset:Ine,exportSqlServerCatalog:Mne,exportPostgresqlCatalogCapture:Jne,exportJsonSchema:kB,exportAvroSchema:N8,exportGraphqlSchema:TO,exportProtobufDescriptorSet:fF,exportSparkSchema:Nie,exportDeltaSchema:F4,exportIcebergSchema:H4,exportOpenapiDocument:k4,exportTableSpec:Rie,exportLinkmlDocument:Yie,exportOdcsDocument:use,exportJsonLdDocument:Zae,exportRdfNQuads:fC,exportOwlTurtle:rle,exportShaclTurtle:ale,exportDbtManifest:dle,exportSmithyJson:ane,exportArrowSchema:gle},j6e={"umf.delta.table":["exportDeltaTable","delta-table.json"],"umf.delta.log":["exportDeltaLog","delta-log.json"],"umf.iceberg.table":["exportIcebergTable","iceberg-table.json"],"umf.dbt.semantic":["exportDbtSemanticManifest","semantic-manifest.json"],"umf.dbt.artifact":["exportDbtArtifact","dbt-artifact.json"],"umf.typespec":["exportTypeSpecSources","typespec-sources.json"],"umf.arrow.ipc":["exportArrowIpcCapture","schema.arrow"],"umf.parquet":["exportParquetCapture","schema.parquet"],"umf.generalized-rdf":["exportGeneralizedRdfDataset","rdf-dataset.json"],"umf.sqlserver":["exportSqlServerCatalog","sqlserver-catalog.json"],"umf.postgresql.catalog":["exportPostgresqlCatalogCapture","postgresql-catalog.json"],"umf.json-schema":["exportJsonSchemaBundle","json-schema-bundle.json"],"umf.avro":["exportAvroBundle","avro-bundle.json"],"umf.graphql":["exportGraphqlBundle","graphql-bundle.json"],"umf.protobuf":["exportProtobufDescriptorSet","schema.pb"],"umf.spark":["exportSparkSchema","schema.spark.json"],"umf.delta":["exportDeltaSchema","schema.delta.json"],"umf.iceberg":["exportIcebergSchema","schema.iceberg.json"],"umf.openapi":["exportOpenapiBundle","openapi-bundle.json"],"umf.tablespec":["exportTableSpec","table.native.txt"],"umf.linkml":["exportLinkmlDocument","schema.linkml.json"],"umf.odcs":["exportOdcsDocument","contract.json"],"umf.jsonld":["exportJsonLdDocument","schema.jsonld"],"umf.rdf":["exportRdfNQuads","schema.nq"],"umf.owl":["exportOwlTurtle","schema.owl.ttl"],"umf.shacl":["exportShaclTurtle","schema.shacl.ttl"],"umf.dbt.manifest":["exportDbtManifest","manifest.json"],"umf.smithy":["exportSmithyJson","model.smithy.json"],"umf.arrow":["exportArrowSchema","schema.arrow.json"]};function ble(e){if(!e.document)return[];let t=[];for(let n of Object.keys(e.document.vocabularies)){let r=j6e[n];if(!r)continue;let i=R6e[r[0]];if(typeof i!=="function")continue;try{t.push({name:r[1],content:(()=>{let s=["umf.linkml","umf.odcs"].includes(n)?i(e.document,"json"):i(e.document);return typeof s==="string"||s instanceof Uint8Array?s:JSON.stringify(s,null,2)})()})}catch(s){t.push({name:r[1]+".export-error.txt",content:"Native recovery blocked: "+String(s instanceof Error?s.message:s)})}}return t}var vle={postgresql:"PostgreSQL DDL",sqlserver:"SQL Server DDL",delta:"Spark / Delta DDL","json-schema":"JSON Schema 2020-12",avro:"Avro schema",graphql:"GraphQL SDL",protobuf:"Protobuf proto3",openapi:"OpenAPI 3.1 schema components",spark:"Spark / Delta schema JSON"};function _le(e,t,n,r="yaml"){let i=["Schema-only scalar profile v1. Keys, relationships, constraints, defaults, descriptions and extension content are retained in the source companion, not enforced by generated output.","Integers use signed 64-bit carriers; floats use double. Decimal and timestamp values use text to avoid inventing precision or timezone semantics. No data conversion is performed. Core absent-allowed maps to target nullable/optional; native absence and null are not equivalent."],s=[];if(t.native?.columns){let y=t.native;s.push({name:y.table_name,fields:y.columns.map((h)=>{if(typeof h.nullable!=="boolean")throw Error(`${h.name}: explicit boolean nullable is required`);return{name:h.name,type:{VARCHAR:"string",TEXT:"string",CHAR:"string",BOOLEAN:"boolean",INTEGER:"integer",DECIMAL:"decimal",FLOAT:"float",DATE:"date",DATETIME:"timestamp",TIMESTAMP:"timestamp"}[h.data_type]??"unsupported",nullable:h.nullable}})})}else if(t.document){let y=t.document;for(let h of y.modules)for(let b of h.elements){if(b.kind!=="record")continue;s.push({name:String(b.name??b.id),fields:(Array.isArray(b.members)?b.members:[]).map((g)=>{let x=y.modules.find((v)=>v.id===g.module)?.elements.find((v)=>v.id===g.element);if(!x||x.kind!=="field"||x.cardinality!=="one"||!["required","absent-allowed"].includes(String(x.nullability)))throw Error(`${b.id}: unresolved, non-scalar or contextual member ${g.element}`);return{name:String(x.name??x.id),type:x.scalarType==="binary"?"bytes":String(x.scalarType),nullable:x.nullability==="absent-allowed"}})})}}if(!s.length)throw Error("This source has no scalar table or record schema.");let o=new Set;for(let y of s){if(!y.name||o.has(y.name)||!y.fields.length)throw Error("Unique, nonempty table names and fields are required.");o.add(y.name);let h=new Set;for(let b of y.fields){if(h.has(b.name)||!b.name||!["string","integer","float","decimal","boolean","date","timestamp","bytes"].includes(b.type))throw Error(`${y.name}.${b.name}: unsupported type or duplicate field`);h.add(b.name)}}let a=(y)=>{if(!/^[A-Za-z_][A-Za-z0-9_]*$/.test(y)||y.startsWith("__"))throw Error(`Target identifier is not supported: ${y}`);return y},l=(y)=>n==="sqlserver"?"["+y.replace(/]/g,"]]")+"]":'"'+y.replace(/"/g,'""')+'"',c=(y,h)=>h[y.type]??"string",u=(y)=>{let h=c(y,{integer:"string",float:"number",boolean:"boolean",bytes:"string"});return{type:y.nullable?[h,"null"]:h}},p=Object.fromEntries(s.map((y)=>[y.name,{type:"object",properties:Object.fromEntries(y.fields.map((h)=>[h.name,u(h)])),required:y.fields.filter((h)=>!h.nullable).map((h)=>h.name),additionalProperties:!1}])),d="json",f;if(["postgresql","sqlserver","delta"].includes(n)){d="sql";let y=n==="postgresql"?{string:"text",integer:"bigint",float:"double precision",boolean:"boolean",date:"date",bytes:"bytea",decimal:"text",timestamp:"text"}:n==="sqlserver"?{string:"nvarchar(max)",integer:"bigint",float:"float(53)",boolean:"bit",date:"date",bytes:"varbinary(max)",decimal:"nvarchar(max)",timestamp:"nvarchar(max)"}:{string:"STRING",integer:"BIGINT",float:"DOUBLE",boolean:"BOOLEAN",date:"DATE",bytes:"BINARY",decimal:"STRING",timestamp:"STRING"},h=n==="delta"?(b)=>"`"+b.replace(/`/g,"``")+"`":l;f=`-- UMF scalar export v1; read the companion report before use. +*/var Gae={id:"umf.rdf",version:"0.1.0",coreVersion:"0.1.0",description:"RDF 1.1 N-Quads/Turtle/TriG source and editable dataset terms with local blank-node scope",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:rdf:0.1.0",type:"object",properties:{profile:{enum:["rdf11-nquads","rdf11-turtle","rdf11-trig"]},baseIRI:{type:"string",minLength:1,maxLength:4096},namedGraphs:{type:"array",maxItems:1e4,items:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0}]}},blankNodeScope:{type:"string",minLength:1},quads:{type:"array",maxItems:1e4,items:{type:"object",properties:{subject:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0}]},predicate:{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},object:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"literal"},value:{type:"string"},datatype:{type:"string"},language:{type:"string",pattern:"^[a-z]+(?:-[a-z0-9]+)*$"}},required:["kind","value","datatype"],additionalProperties:!0}]},graph:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"default"}},required:["kind"],additionalProperties:!0}]}},required:["subject","predicate","object","graph"],additionalProperties:!0}},originalSource:{type:"string",maxLength:4000000}},required:["profile","blankNodeScope","quads","originalSource"],additionalProperties:!0,allOf:[{if:{properties:{profile:{enum:["rdf11-turtle","rdf11-trig"]}}},then:{properties:{baseIRI:{}},required:["baseIRI"]}},{if:{properties:{profile:{const:"rdf11-trig"}}},then:{properties:{namedGraphs:{}},required:["namedGraphs"]}}]},semantics:"CONTRACT-025; ordered quad occurrences preserve syntax-level information, dataset meaning has set semantics; blank labels are scoped, no entailment",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"RDF",version:"RDF 1.1 N-Quads/Turtle/TriG; N3.js 2.7.12",subset:"N-Quads/Turtle/TriG RDF 1.1 terms, explicit Turtle/TriG base, named/default graphs with empty graph inventory, lexical literals and local blank nodes, collision-guarded IRI rename and explicit disjoint-input dataset merge; no other syntaxes, RDF 1.2, entailment or canonicalization"},evidence:["tests/rdf/merge.test.ts","fixtures/rdf/merge/oracle-results.json","fixtures/rdf/merge/browser-results.json","tests/rdf/rdf.test.ts","fixtures/rdf/nquads/oracle-results.json","fixtures/rdf/nquads/browser-results.json","tests/rdf/rename.test.ts","fixtures/rdf/rename/oracle-results.json","fixtures/rdf/rename/browser-results.json","tests/rdf/trig.test.ts","fixtures/rdf/trig/oracle-results.json","fixtures/rdf/trig/browser-results.json","tests/rdf/turtle.test.ts","fixtures/rdf/turtle/oracle-results.json","fixtures/rdf/turtle/browser-results.json"]}};var Kc="umf.rdf",zVe=Gae,WVe="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString";function f_(e){if(e.termType==="NamedNode")return{kind:"iri",value:e.value};if(e.termType==="BlankNode")return{kind:"blank",value:e.value};if(e.termType==="DefaultGraph")return{kind:"default"};if(e.termType==="Literal"&&!e.direction)return{kind:"literal",value:e.value,datatype:e.datatype.value,...e.language?{language:e.language.toLowerCase()}:{}};throw new U("RDF_PROFILE","Term is outside the RDF 1.1 profile")}function ih(e,t="N-Quads",n,r){if(typeof e!=="string"||e.length>4000000)throw new U("RDF_LIMIT","Expected at most 4,000,000 source characters");if(/[\uD800-\uDFFF]/u.test(e))throw new U("RDF_UNICODE","Unpaired UTF-16 surrogates cannot represent Unicode scalar values");let i=0,s=t!=="N-Quads"?{...os,blankNode:(a)=>os.blankNode(a===void 0?"g_"+i++:"e_"+Array.from(a).map((l)=>l.codePointAt(0).toString(16).padStart(6,"0")).join(""))}:os,o;try{let a=new p_({format:t,blankNodePrefix:"",factory:s,baseIRI:n});if(t==="TriG"){let l=a._readGraph;if(typeof l!=="function")throw new U("RDF_PARSER","Pinned graph-reader hook is unavailable");let c=new Set;a._readGraph=function(u){let p=l.call(this,u);if(u.type==="{"&&this._graph&&typeof this._graph==="object"){let d=f_(this._graph);if(d.kind!=="iri"&&d.kind!=="blank")throw new U("RDF_GRAPH","Expected graph name");let f=JSON.stringify(d);if(!c.has(f)){if(c.add(f),r?.push(d),c.size>1e4)throw new U("RDF_LIMIT","At most 10,000 named graphs")}}return p}}o=a.parse(e,void 0,void 0,()=>{throw new U("RDF_PROFILE","RDF version directives are outside the RDF 1.1 syntax profile")})}catch(a){throw new U("RDF_SYNTAX",String(a))}if(o.length>1e4)throw new U("RDF_LIMIT","At most 10,000 quad occurrences");return o.map((a)=>({subject:f_(a.subject),predicate:f_(a.predicate),object:f_(a.object),graph:f_(a.graph)}))}function oE(e){switch(e.kind){case"iri":return os.namedNode(e.value);case"blank":return os.blankNode(e.value);case"default":return os.defaultGraph();case"literal":if(e.language&&e.datatype!==WVe)throw new U("RDF_LITERAL","Language literal requires rdf:langString");return os.literal(e.value,e.language??os.namedNode(e.datatype))}}function m_(e){return new d_({format:"N-Quads"}).quadsToString(e.map((t)=>os.quad(oE(t.subject),oE(t.predicate),oE(t.object),oE(t.graph))))}var $l=(e)=>JSON.stringify(e.map((t)=>[t.subject,t.predicate,t.object,t.graph].map((n)=>n.kind==="default"?[n.kind]:n.kind==="literal"?[n.kind,n.value,n.datatype,n.language??""]:[n.kind,n.value])));function QVe(e){let t=e,n=[{code:"RDF_CONTEXT",path:"",severity:"warning",message:"RDF 1.1 N-Quads/Turtle/TriG only. Turtle/TriG expands prefixes/base and allocates deterministic local anonymous labels. Blank labels have document-local scope; dataset meaning ignores duplicate occurrences and order. No entailment, datatype value normalization, isomorphism/canonicalization or RDF 1.2 support is asserted. Original bytes remain archived; edited export regenerates syntax."}],r=(i,s,o)=>{if(Object.keys(i).some((a)=>!s.includes(a)))n.push({code:"RDF_REPRESENTATION",path:o,severity:"warning",message:"Unknown encoding fields are retained and block native export"})};r(t,["profile","blankNodeScope","quads","originalSource","namedGraphs",...t.profile!=="rdf11-nquads"?["baseIRI"]:[]],""),t.namedGraphs?.forEach((i,s)=>r(i,["kind","value"],"/namedGraphs/"+s)),t.quads.forEach((i,s)=>{r(i,["subject","predicate","object","graph"],"/quads/"+s);for(let[o,a]of Object.entries(i)){if(!["subject","predicate","object","graph"].includes(o))continue;r(a,a.kind==="default"?["kind"]:a.kind==="literal"?["kind","value","datatype","language"]:["kind","value"],"/quads/"+s+"/"+o)}});try{if(t.profile!=="rdf11-nquads")XVe(t.baseIRI);if(t.profile==="rdf11-turtle"){if(mC(t).length)throw Error("Turtle cannot represent named graphs")}ih(t.originalSource,t.profile==="rdf11-trig"?"TriG":t.profile==="rdf11-turtle"?"Turtle":"N-Quads",t.baseIRI);for(let o of t.namedGraphs??[]){let a={subject:o,predicate:{kind:"iri",value:"urn:umf:graph-probe"},object:o,graph:{kind:"default"}};if($l(ih(m_([a])))!==$l([a]))throw Error("Graph name changes when encoded")}let i=m_(t.quads),s=ih(i);if($l(s)!==$l(t.quads)&&!n.some((o)=>o.code==="RDF_REPRESENTATION"))throw Error("Terms change when encoded as N-Quads")}catch(i){n.push({code:"RDF_TERMS",path:"",severity:"error",message:String(i)})}return n}function YVe(){return new nt().register(zVe,QVe)}function Tp(e){return We(e,YVe())}function Hae(e){let t=Tp(e);if(!t.valid)throw new U("RDF_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="dataset")?.elements.find((r)=>r.id==="dataset")?.extensions[Kc];if(!n||e.vocabularies[Kc]?.version!=="0.1.0")throw new U("RDF_PAYLOAD","Expected pinned RDF dataset payload");return Ae(n)}function fC(e,t={}){if(t.preserveSource!==void 0&&typeof t.preserveSource!=="boolean")throw new U("RDF_OPTIONS","Expected boolean preserveSource");let n=Hae(e);if(Tp(e).diagnostics.some((r)=>r.code==="RDF_REPRESENTATION"))throw new U("RDF_EXPORT","Unknown encoding fields cannot be discarded");if(mC(n).some((r)=>!n.quads.some((i)=>i.graph.kind===r.kind&&("value"in i.graph)&&i.graph.value===r.value)))throw new U("RDF_GRAPH_LOSS","N-Quads cannot represent empty named graphs");return t.preserveSource!==!1&&n.profile==="rdf11-nquads"&&$l(ih(n.originalSource))===$l(n.quads)?n.originalSource:m_(n.quads)}function XVe(e){if(typeof e!=="string"||!e.length||e.length>4096)throw new U("RDF_BASE","Explicit absolute base IRI required");let t={subject:{kind:"iri",value:e},predicate:{kind:"iri",value:"urn:umf:base-probe"},object:{kind:"iri",value:e},graph:{kind:"default"}};if($l(ih(m_([t])))!==$l([t]))throw new U("RDF_BASE","Base IRI spelling changes on serialization")}function sh(e){let t=Hae(e);if(Tp(e).diagnostics.some((n)=>n.code==="RDF_REPRESENTATION"))throw new U("RDF_EXPORT","Unknown encoding fields cannot be discarded");if(mC(t).length)throw new U("RDF_GRAPH_LOSS","Turtle export cannot silently discard named graphs");return t.profile==="rdf11-turtle"&&$l(ih(t.originalSource,"Turtle",t.baseIRI))===$l(t.quads)?t.originalSource:m_(t.quads)}function mC(e){let t=new Map;for(let n of[...e.namedGraphs??[],...e.quads.map((r)=>r.graph)])if(n.kind!=="default")t.set(JSON.stringify([n.kind,n.value]),n);return[...t.values()]}var n6e=Rr(LF(),1);var zae={id:"umf.jsonld",version:"0.1.0",coreVersion:"0.1.0",description:"JSON-LD source and supplied context preservation with explicit expansion, flattening, compaction and framing proposals",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:jsonld:0.1.0",type:"object",properties:{profile:{const:"jsonld-source"},processingMode:{enum:["json-ld-1.0","json-ld-1.1"]},baseIRI:{type:"string",minLength:1,maxLength:4096},root:{$ref:"#/$defs/node"},originalSource:{type:"string",maxLength:4000000},contexts:{type:"array",maxItems:100,items:{type:"object",properties:{url:{type:"string",minLength:1},documentUrl:{type:"string",minLength:1},root:{$ref:"#/$defs/node"},originalSource:{type:"string",maxLength:4000000}},required:["url","documentUrl","root","originalSource"],additionalProperties:!0}},expandContext:{$ref:"#/$defs/node"}},required:["profile","processingMode","baseIRI","root","originalSource","contexts"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-026; exact source and context values remain authoritative; JSON-LD processing proposals are qualified transformations, not an RDF or ontology equivalence proof",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"JSON-LD",version:"1.0/1.1; jsonld.js 9.0.0 + UMF processing patch",subset:"JSON source and explicit context bundle; exact-number expansion with recorded loss events or rejection; flattening and standalone compaction with recorded corpus discrepancies; framing selected views with retained sources, strict flag validation and recorded compatibility blocks; RDF-to-JSON-LD projection with lexical/native type policies; qualified JSON-LD-to-RDF proposals with explicitly recorded strict/binary64 numeric policies with explicit quantization and finite-overflow blocks; optional generalized dataset projection through umf.generalized-rdf; malformed terms omitted with explicit loss events; compound-literal direction conversion with graph/list round-trip evidence; no network"},evidence:["tests/generalized-rdf/dataset.test.ts","fixtures/generalized-rdf/oracle-results.json","fixtures/generalized-rdf/browser-results.json","fixtures/jsonld/to-rdf/numeric-oracle-results.json","tests/jsonld/to-rdf.test.ts","fixtures/jsonld/to-rdf/oracle-results.json","fixtures/jsonld/to-rdf/rdf-oracle-results.json","fixtures/jsonld/to-rdf/browser-results.json","tests/jsonld/from-rdf.test.ts","fixtures/jsonld/from-rdf/oracle-results.json","fixtures/jsonld/from-rdf/browser-results.json","tests/jsonld/framing.test.ts","fixtures/jsonld/framing/oracle-results.json","fixtures/jsonld/framing/browser-results.json","tests/jsonld/compaction.test.ts","fixtures/jsonld/compaction/oracle-results.json","fixtures/jsonld/compaction/browser-results.json","tests/jsonld/flatten.test.ts","fixtures/jsonld/flatten/oracle-results.json","fixtures/jsonld/flatten/browser-results.json","tests/jsonld/numeric.test.ts","fixtures/jsonld/numeric/oracle-results.json","tests/jsonld/nest.test.ts","fixtures/jsonld/nest/results.json","fixtures/jsonld/patch-results.json","tests/jsonld/legacy.test.ts","fixtures/jsonld/legacy/results.json","tests/jsonld/jsonld.test.ts","fixtures/jsonld/expansion/oracle-results.json","fixtures/jsonld/expansion/browser-results.json"]}};var Wae="umf.jsonld",r6e=zae;function yC(e){try{new URL(e)}catch{throw new U("JSONLD_IRI","Expected absolute document/base URL")}}function i6e(e){let t=e,n=[{code:"JSONLD_CONTEXT",path:"",severity:"warning",message:"Source representation only; semantic expansion is a separate asynchronous proposal. Original source, unknown native values and exact numeric tokens remain archived. No RDF conversion, ontology validation or retrieval is asserted."}],r=(s,o,a)=>{if(Object.keys(s).some((l)=>!o.includes(l)))n.push({code:"JSONLD_REPRESENTATION",path:a,severity:"warning",message:"Unknown representation fields are retained and block native export/expansion"})},i=(s,o)=>{if(r(s,s.kind==="null"?["kind"]:s.kind==="object"?["kind","members"]:s.kind==="array"?["kind","items"]:["kind","value"],o),s.kind==="array")s.items.forEach((a,l)=>i(a,o+"/"+l));if(s.kind==="object")for(let[a,l]of Object.entries(s.members))i(l,o+"/"+$e(a))};if(r(t,["profile","processingMode","baseIRI","root","originalSource","contexts","expandContext"],""),i(t.root,"/root"),t.expandContext)i(t.expandContext,"/expandContext");try{yC(t.baseIRI),Jt(t.originalSource);let s=new Set;t.contexts.forEach((o,a)=>{if(r(o,["url","documentUrl","root","originalSource"],"/contexts/"+a),i(o.root,"/contexts/"+a+"/root"),yC(o.url),yC(o.documentUrl),s.has(o.url))throw Error("Duplicate supplied context URL: "+o.url);s.add(o.url),Jt(o.originalSource)})}catch(s){n.push({code:"JSONLD_SOURCE",path:"",severity:"error",message:String(s)})}return n}function s6e(){return new nt().register(r6e,i6e)}function Xae(e){return We(e,s6e())}function o6e(e){let t=Xae(e);if(!t.valid)throw new U("JSONLD_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="jsonld")?.elements.find((r)=>r.id==="document")?.extensions[Wae];if(!n||e.vocabularies[Wae]?.version!=="0.1.0")throw new U("JSONLD_PAYLOAD","Expected pinned JSON-LD payload");return Ae(n)}function Zae(e){let t=o6e(e);if(Xae(e).diagnostics.some((n)=>n.code==="JSONLD_REPRESENTATION"))throw new U("JSONLD_EXPORT","Unknown representation fields cannot be discarded");return Be(Jt(t.originalSource))===Be(t.root)?t.originalSource:Be(t.root)+` +`}function Qae(e){let[t,n="0"]=e.toLowerCase().split("e"),r=t.startsWith("-"),i=t.replace("-","").split("."),s=(i[0]+(i[1]??"")).replace(/^0+/,""),o=BigInt(n)-BigInt((i[1]??"").length);while(s.endsWith("0"))s=s.slice(0,-1),o++;return s?[r,s,o.toString()]:[r,"0","0"]}var aE=new WeakMap;class a6e extends Number{constructor(e){super(0);Object.defineProperty(this,Symbol.for("umf.jsonld.exact-number"),{value:!0}),aE.set(this,e),Object.freeze(this)}valueOf(){throw new U("JSONLD_NUMBER_OPERATION","Exact expansion number cannot be coerced for arithmetic")}toString(){return aE.get(this)}[Symbol.for("umf.jsonld.number-equals")](e){let t=typeof e==="number"&&Number.isFinite(e)?Object.is(e,-0)?"-0":JSON.stringify(e):e&&typeof e==="object"?aE.get(e):void 0;return t!==void 0&&JSON.stringify(Qae(this.toString()))===JSON.stringify(Qae(t))}toJSON(){return{$umfExactNumber:aE.get(this)}}}var ele={id:"umf.owl",version:"0.1.0",coreVersion:"0.1.0",description:"OWL 2 RDF graph preservation and local ontology metadata views",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:owl:0.1.0",type:"object",properties:{profile:{enum:["rdf11-nquads","rdf11-turtle","rdf11-trig"]},baseIRI:{type:"string",minLength:1,maxLength:4096},namedGraphs:{type:"array",maxItems:1e4,items:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0}]}},blankNodeScope:{type:"string",minLength:1},quads:{type:"array",maxItems:1e4,items:{type:"object",properties:{subject:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0}]},predicate:{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},object:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"literal"},value:{type:"string"},datatype:{type:"string"},language:{type:"string",pattern:"^[a-z]+(?:-[a-z0-9]+)*$"}},required:["kind","value","datatype"],additionalProperties:!0}]},graph:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"default"}},required:["kind"],additionalProperties:!0}]}},required:["subject","predicate","object","graph"],additionalProperties:!0}},originalSource:{type:"string",maxLength:4000000},owlVersion:{const:"2"}},required:["profile","blankNodeScope","quads","originalSource","owlVersion"],additionalProperties:!0,allOf:[{if:{properties:{profile:{enum:["rdf11-turtle","rdf11-trig"]}}},then:{properties:{baseIRI:{}},required:["baseIRI"]}},{if:{properties:{profile:{const:"rdf11-trig"}}},then:{properties:{namedGraphs:{}},required:["namedGraphs"]}}]},semantics:"CONTRACT-029; RDF graph fidelity only; OWL axiom validation and reasoning unimplemented",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"OWL",version:"OWL 2 Second Edition 2012-12-11",subset:"Turtle RDF graph preservation; explicit headers/declarations, local expressions, axiom annotations, negative/n-ary assertions and chain/key/disjoint-union lists. No complete structural OWL mapping, validity, profile, import execution or entailment claim"},evidence:["tests/owl/annotations.test.ts","fixtures/owl/annotations-oracle.json","fixtures/owl/annotation-case-oracle.json","fixtures/owl/annotation-case-browser.json","tests/owl/expressions.test.ts","fixtures/owl/expression-oracle.json","tests/owl/roundtrip.test.ts","fixtures/owl/oracle-results.json","fixtures/owl/browser-results.json","tests/owl/axioms.test.ts","fixtures/owl/special-oracle.json","fixtures/owl/special-browser.json","tests/owl/declarations.test.ts","fixtures/owl/declarations-oracle.json","fixtures/owl/declarations-browser.json","tests/owl/list-axioms.test.ts","fixtures/owl/list-axioms-oracle.json","fixtures/owl/list-axioms-browser.json"]}};var tle="umf.owl",p6e=ele;function nle(e){let t=Ae(e);return delete t.owlVersion,{umf:"0.1.0",id:"owl:graph",vocabularies:{[Kc]:{version:"0.1.0"}},modules:[{id:"dataset",namespace:"",elements:[{id:"dataset",extensions:{[Kc]:t}}]}]}}function d6e(e){return[...Tp(nle(e)).diagnostics,{code:"OWL_SCOPE",path:"",severity:"warning",message:"OWL 2 RDF graph preservation only. Axiom validation, profiles, import resolution, consistency and entailment are not implemented."}]}function f6e(){return new nt().register(p6e,d6e)}function m6e(e){return We(e,f6e())}function y6e(e){let t=m6e(e);if(!t.valid)throw new U("OWL_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((i)=>i.id==="dataset")?.elements.find((i)=>i.id==="dataset")?.extensions[tle];if(!n||e.vocabularies[tle]?.version!=="0.1.0")throw new U("OWL_PAYLOAD","Expected pinned ontology graph");let r=nle(n);return sh(r),r}function rle(e){return sh(y6e(e))}var ile={id:"umf.shacl",version:"0.1.0",coreVersion:"0.1.0",description:"SHACL 1.0 shapes graphs with source-preserving RDF representation and explicit property-path interpretation",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:shacl:0.1.0",type:"object",properties:{profile:{enum:["rdf11-nquads","rdf11-turtle","rdf11-trig"]},baseIRI:{type:"string",minLength:1,maxLength:4096},namedGraphs:{type:"array",maxItems:1e4,items:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0}]}},blankNodeScope:{type:"string",minLength:1},quads:{type:"array",maxItems:1e4,items:{type:"object",properties:{subject:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0}]},predicate:{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},object:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"literal"},value:{type:"string"},datatype:{type:"string"},language:{type:"string",pattern:"^[a-z]+(?:-[a-z0-9]+)*$"}},required:["kind","value","datatype"],additionalProperties:!0}]},graph:{oneOf:[{type:"object",properties:{kind:{const:"iri"},value:{type:"string"}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"blank"},value:{type:"string",minLength:1}},required:["kind","value"],additionalProperties:!0},{type:"object",properties:{kind:{const:"default"}},required:["kind"],additionalProperties:!0}]}},required:["subject","predicate","object","graph"],additionalProperties:!0}},originalSource:{type:"string",maxLength:4000000},shaclVersion:{const:"1.0"}},required:["profile","blankNodeScope","quads","originalSource","shaclVersion"],additionalProperties:!0,allOf:[{if:{properties:{profile:{enum:["rdf11-turtle","rdf11-trig"]}}},then:{properties:{baseIRI:{}},required:["baseIRI"]}},{if:{properties:{profile:{const:"rdf11-trig"}}},then:{properties:{namedGraphs:{}},required:["namedGraphs"]}}]},semantics:"CONTRACT-028; SHACL 2017 Recommendation, source graph preservation, property paths and Core target selection; verified constraint conformance remains unimplemented; engine proposal available",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"SHACL",version:"W3C Recommendation 2017-07-20",subset:"RDF 1.1 Turtle shapes graph; all seven property-path forms and Core target selection; no constraint conformance, SPARQL execution, imports, entailment or SHACL 1.2 claim"},evidence:["tests/shacl/paths.test.ts","fixtures/shacl/oracle-results.json","fixtures/shacl/browser-results.json","fixtures/shacl/corpus-results.json","fixtures/shacl/corpus-oracle-results.json","fixtures/shacl/target-oracle-results.json","fixtures/shacl/target-browser-results.json","fixtures/shacl/validation-results.json","fixtures/shacl/report-comparison.json","fixtures/shacl/validation-browser-results.json","fixtures/shacl/exact-numeric-results.json","fixtures/shacl/exact-numeric-oracle.json","fixtures/shacl/exact-numeric-browser-results.json","fixtures/shacl/float-results.json","fixtures/shacl/float-oracle.json","fixtures/shacl/float-browser-results.json","tests/shacl/metadata.test.ts","fixtures/shacl/metadata.json","fixtures/shacl/metadata-browser-results.json","tests/shacl/lists.test.ts","fixtures/shacl/list-gap.json","fixtures/shacl/string-results.json","fixtures/shacl/string-oracle.json","fixtures/shacl/string-browser-results.json"]}};var sle="umf.shacl",g6e=ile;function ole(e){let t=Ae(e);return delete t.shaclVersion,{umf:"0.1.0",id:"shacl:graph",vocabularies:{[Kc]:{version:"0.1.0"}},modules:[{id:"dataset",namespace:"",elements:[{id:"dataset",extensions:{[Kc]:t}}]}]}}function b6e(e){return[...Tp(ole(e)).diagnostics,{code:"SHACL_SCOPE",path:"",severity:"warning",message:"SHACL 1.0 graph preservation, property paths and Core target selection only. Constraint validation, imports, general entailment and SHACL 1.2 are not implemented."}]}function v6e(){return new nt().register(g6e,b6e)}function _6e(e){return We(e,v6e())}function x6e(e){let t=_6e(e);if(!t.valid)throw new U("SHACL_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((i)=>i.id==="dataset")?.elements.find((i)=>i.id==="dataset")?.extensions[sle];if(!n||e.vocabularies[sle]?.version!=="0.1.0")throw new U("SHACL_PAYLOAD","Expected pinned shapes graph");let r=ole(n);return sh(r),r}function ale(e){return sh(x6e(e))}var lle={id:"umf.dbt.manifest",version:"0.1.0",coreVersion:"0.1.0",description:"Exact dbt manifest JSON with pinned v12 shape inspection",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:dbt:manifest:0.1.0",type:"object",properties:{profile:{const:"dbt-manifest-json"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-022; native warnings never justify source loss; shape checks do not prove compilation or graph validity",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"dbt manifest",version:"v12 grammar; dbt Core 1.10.0 fixture",subset:"Exact artifact preservation, copied edits and schema-shape diagnostics; no graph or execution validity"},evidence:["tests/dbt/manifest.test.ts","fixtures/dbt/oracle-results.json","fixtures/dbt/browser-results.json"]}};var cle={$schema:"https://json-schema.org/draft/2020-12/schema",type:"object",title:"WritableManifest",properties:{metadata:{type:"object",title:"ManifestMetadata",description:"Metadata about the manifest",properties:{dbt_schema_version:{type:"string"},dbt_version:{type:"string",default:"1.11.6"},generated_at:{type:"string"},invocation_id:{anyOf:[{type:"string"},{type:"null"}]},invocation_started_at:{anyOf:[{type:"string"},{type:"null"}]},env:{type:"object",additionalProperties:{type:"string"},propertyNames:{type:"string"}},project_name:{description:"Name of the root project",anyOf:[{type:"string"},{type:"null"}],default:null},project_id:{description:"A unique identifier for the project, hashed from the project name",anyOf:[{type:"string"},{type:"null"}],default:null},user_id:{description:"A unique identifier for the user",anyOf:[{type:"string",format:"uuid"},{type:"null"}],default:null},send_anonymous_usage_stats:{description:"Whether dbt is configured to send anonymous usage statistics",anyOf:[{type:"boolean"},{type:"null"}],default:null},adapter_type:{description:"The type name of the adapter",anyOf:[{type:"string"},{type:"null"}],default:null},quoting:{description:"The quoting configuration for the project",anyOf:[{type:"object",title:"Quoting",properties:{database:{anyOf:[{type:"boolean"},{type:"null"}],default:null},schema:{anyOf:[{type:"boolean"},{type:"null"}],default:null},identifier:{anyOf:[{type:"boolean"},{type:"null"}],default:null},column:{anyOf:[{type:"boolean"},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},run_started_at:{description:"The timestamp when the run started",anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},nodes:{type:"object",description:"The nodes defined in the dbt project and its dependencies",additionalProperties:{anyOf:[{type:"object",title:"Seed",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"seed"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"SeedConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"seed"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},delimiter:{type:"string",default:","},quote_columns:{anyOf:[{type:"boolean"},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},root_path:{anyOf:[{type:"string"},{type:"null"}],default:null},depends_on:{type:"object",title:"MacroDependsOn",properties:{macros:{type:"array",items:{type:"string"}}},additionalProperties:!1},defer_relation:{anyOf:[{type:"object",title:"DeferRelation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},alias:{type:"string"},relation_name:{anyOf:[{type:"string"},{type:"null"}]},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},name:{type:"string"},description:{type:"string"},compiled_code:{anyOf:[{type:"string"},{type:"null"}]},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{anyOf:[{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},{type:"null"}]}},additionalProperties:!1,required:["database","schema","alias","relation_name","resource_type","name","description","compiled_code","meta","tags","config"]},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"Analysis",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"analysis"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"SingularTest",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"test"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"TestConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:"dbt_test__audit"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"test"},severity:{type:"string",default:"ERROR",pattern:"^([Ww][Aa][Rr][Nn]|[Ee][Rr][Rr][Oo][Rr])$"},store_failures:{anyOf:[{type:"boolean"},{type:"null"}],default:null},store_failures_as:{anyOf:[{type:"string"},{type:"null"}],default:null},where:{anyOf:[{type:"string"},{type:"null"}],default:null},limit:{anyOf:[{type:"integer"},{type:"null"}],default:null},fail_calc:{type:"string",default:"count(*)"},warn_if:{type:"string",default:"!= 0"},error_if:{type:"string",default:"!= 0"}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"HookNode",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"operation"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"Model",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"model"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"ModelConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},access:{enum:["private","protected","public"],default:"protected"},freshness:{anyOf:[{type:"object",title:"ModelFreshness",properties:{build_after:{type:"object",title:"ModelBuildAfter",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null},updates_on:{enum:["all","any"],default:"any"}},additionalProperties:!0}},additionalProperties:!0,required:["build_after"]},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},access:{enum:["private","protected","public"],default:"protected"},constraints:{type:"array",items:{type:"object",title:"ModelLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}},columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null},latest_version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null},deprecation_date:{anyOf:[{type:"string"},{type:"null"}],default:null},defer_relation:{anyOf:[{type:"object",title:"DeferRelation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},alias:{type:"string"},relation_name:{anyOf:[{type:"string"},{type:"null"}]},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},name:{type:"string"},description:{type:"string"},compiled_code:{anyOf:[{type:"string"},{type:"null"}]},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{anyOf:[{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},{type:"null"}]}},additionalProperties:!1,required:["database","schema","alias","relation_name","resource_type","name","description","compiled_code","meta","tags","config"]},{type:"null"}],default:null},primary_key:{type:"array",items:{type:"string"}},time_spine:{anyOf:[{type:"object",title:"TimeSpine",properties:{standard_granularity_column:{type:"string"},custom_granularities:{type:"array",items:{type:"object",title:"CustomGranularity",properties:{name:{type:"string"},column_name:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}}},additionalProperties:!1,required:["standard_granularity_column"]},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"SqlOperation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"sql_operation"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"GenericTest",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"test"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"TestConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:"dbt_test__audit"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"test"},severity:{type:"string",default:"ERROR",pattern:"^([Ww][Aa][Rr][Nn]|[Ee][Rr][Rr][Oo][Rr])$"},store_failures:{anyOf:[{type:"boolean"},{type:"null"}],default:null},store_failures_as:{anyOf:[{type:"string"},{type:"null"}],default:null},where:{anyOf:[{type:"string"},{type:"null"}],default:null},limit:{anyOf:[{type:"integer"},{type:"null"}],default:null},fail_calc:{type:"string",default:"count(*)"},warn_if:{type:"string",default:"!= 0"},error_if:{type:"string",default:"!= 0"}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},column_name:{anyOf:[{type:"string"},{type:"null"}],default:null},file_key_name:{anyOf:[{type:"string"},{type:"null"}],default:null},attached_node:{anyOf:[{type:"string"},{type:"null"}],default:null},test_metadata:{type:"object",title:"TestMetadata",properties:{name:{type:"string",default:"test"},kwargs:{type:"object",propertyNames:{type:"string"}},namespace:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"Snapshot",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"snapshot"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"SnapshotConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"snapshot"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},target_schema:{anyOf:[{type:"string"},{type:"null"}],default:null},target_database:{anyOf:[{type:"string"},{type:"null"}],default:null},updated_at:{anyOf:[{type:"string"},{type:"null"}],default:null},check_cols:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},snapshot_meta_column_names:{type:"object",title:"SnapshotMetaColumnNames",properties:{dbt_valid_to:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_valid_from:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_scd_id:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_updated_at:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_is_deleted:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},dbt_valid_to_current:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},defer_relation:{anyOf:[{type:"object",title:"DeferRelation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},alias:{type:"string"},relation_name:{anyOf:[{type:"string"},{type:"null"}]},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},name:{type:"string"},description:{type:"string"},compiled_code:{anyOf:[{type:"string"},{type:"null"}]},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{anyOf:[{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},{type:"null"}]}},additionalProperties:!1,required:["database","schema","alias","relation_name","resource_type","name","description","compiled_code","meta","tags","config"]},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum","config"]},{type:"object",title:"Function",properties:{returns:{type:"object",title:"FunctionReturns",properties:{data_type:{type:"string"},description:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["data_type"]},database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"function"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"FunctionConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"function"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},type:{enum:["scalar","aggregate","table"],default:"scalar"},volatility:{anyOf:[{enum:["deterministic","stable","non-deterministic"]},{type:"null"}],default:null},runtime_version:{anyOf:[{type:"string"},{type:"null"}],default:null},entry_point:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},arguments:{type:"array",items:{type:"object",title:"FunctionArgument",properties:{name:{type:"string"},data_type:{type:"string"},description:{anyOf:[{type:"string"},{type:"null"}],default:null},default_value:{anyOf:[{},{type:"null"}],default:null}},additionalProperties:!1,required:["name","data_type"]}}},additionalProperties:!1,required:["returns","database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum","config"]}]},propertyNames:{type:"string"}},sources:{type:"object",description:"The sources defined in the dbt project and its dependencies",additionalProperties:{type:"object",title:"SourceDefinition",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"source"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},source_name:{type:"string"},source_description:{type:"string"},loader:{type:"string"},identifier:{type:"string"},quoting:{type:"object",title:"Quoting",properties:{database:{anyOf:[{type:"boolean"},{type:"null"}],default:null},schema:{anyOf:[{type:"boolean"},{type:"null"}],default:null},identifier:{anyOf:[{type:"boolean"},{type:"null"}],default:null},column:{anyOf:[{type:"boolean"},{type:"null"}],default:null}},additionalProperties:!1},loaded_at_field:{anyOf:[{type:"string"},{type:"null"}],default:null},loaded_at_query:{anyOf:[{type:"string"},{type:"null"}],default:null},freshness:{anyOf:[{type:"object",title:"FreshnessThreshold",properties:{warn_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},error_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},filter:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},external:{anyOf:[{type:"object",title:"ExternalTable",properties:{_extra:{type:"object",propertyNames:{type:"string"}},location:{anyOf:[{type:"string"},{type:"null"}],default:null},file_format:{anyOf:[{type:"string"},{type:"null"}],default:null},row_format:{anyOf:[{type:"string"},{type:"null"}],default:null},tbl_properties:{anyOf:[{type:"string"},{type:"null"}],default:null},partitions:{anyOf:[{type:"array",items:{type:"string"}},{type:"array",items:{type:"object",title:"ExternalPartition",properties:{_extra:{type:"object",propertyNames:{type:"string"}},name:{type:"string",default:""},description:{type:"string",default:""},data_type:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0}},{type:"null"}],default:null}},additionalProperties:!0},{type:"null"}],default:null},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},source_meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{type:"object",title:"SourceConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},event_time:{default:null},freshness:{anyOf:[{type:"object",title:"FreshnessThreshold",properties:{warn_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},error_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},filter:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},loaded_at_field:{anyOf:[{type:"string"},{type:"null"}],default:null},loaded_at_query:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},created_at:{type:"number"},unrendered_database:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_schema:{anyOf:[{type:"string"},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","source_name","source_description","loader","identifier"]},propertyNames:{type:"string"}},macros:{type:"object",description:"The macros defined in the dbt project and its dependencies",additionalProperties:{type:"object",title:"Macro",properties:{name:{type:"string"},resource_type:{const:"macro"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},macro_sql:{type:"string"},depends_on:{type:"object",title:"MacroDependsOn",properties:{macros:{type:"array",items:{type:"string"}}},additionalProperties:!1},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},arguments:{type:"array",items:{type:"object",title:"MacroArgument",properties:{name:{type:"string"},type:{anyOf:[{type:"string"},{type:"null"}],default:null},description:{type:"string",default:""}},additionalProperties:!1,required:["name"]}},created_at:{type:"number"},supported_languages:{anyOf:[{type:"array",items:{enum:["python","sql"]}},{type:"null"}],default:null}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","macro_sql"]},propertyNames:{type:"string"}},docs:{type:"object",description:"The docs defined in the dbt project and its dependencies",additionalProperties:{type:"object",title:"Documentation",properties:{name:{type:"string"},resource_type:{const:"doc"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},block_contents:{type:"string"}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","block_contents"]},propertyNames:{type:"string"}},exposures:{type:"object",description:"The exposures defined in the dbt project and its dependencies",additionalProperties:{type:"object",title:"Exposure",properties:{name:{type:"string"},resource_type:{const:"exposure"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},type:{enum:["dashboard","notebook","analysis","ml","application"]},owner:{type:"object",title:"Owner",properties:{_extra:{type:"object",propertyNames:{type:"string"}},email:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},name:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},description:{type:"string",default:""},label:{anyOf:[{type:"string"},{type:"null"}],default:null},maturity:{anyOf:[{enum:["low","medium","high"]},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{type:"object",title:"ExposureConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},tags:{type:"array",items:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},url:{anyOf:[{type:"string"},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},created_at:{type:"number"}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","type","owner"]},propertyNames:{type:"string"}},metrics:{type:"object",description:"The metrics defined in the dbt project and its dependencies",additionalProperties:{type:"object",title:"Metric",properties:{name:{type:"string"},resource_type:{const:"metric"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},description:{type:"string"},label:{type:"string"},type:{enum:["simple","ratio","cumulative","derived","conversion"]},type_params:{type:"object",title:"MetricTypeParams",properties:{measure:{anyOf:[{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null},input_measures:{type:"array",items:{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},numerator:{anyOf:[{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null},denominator:{anyOf:[{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},grain_to_date:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},metrics:{anyOf:[{type:"array",items:{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},{type:"null"}],default:null},conversion_type_params:{anyOf:[{type:"object",title:"ConversionTypeParams",properties:{base_measure:{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},conversion_measure:{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},entity:{type:"string"},calculation:{enum:["conversions","conversion_rate"],default:"conversion_rate"},window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},constant_properties:{anyOf:[{type:"array",items:{type:"object",title:"ConstantPropertyInput",properties:{base_property:{type:"string"},conversion_property:{type:"string"}},additionalProperties:!1,required:["base_property","conversion_property"]}},{type:"null"}],default:null}},additionalProperties:!1,required:["base_measure","conversion_measure","entity"]},{type:"null"}],default:null},cumulative_type_params:{anyOf:[{type:"object",title:"CumulativeTypeParams",properties:{window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},grain_to_date:{anyOf:[{type:"string"},{type:"null"}],default:null},period_agg:{enum:["first","last","average"],default:"first"},metric:{anyOf:[{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},metric_aggregation_params:{anyOf:[{type:"object",title:"MetricAggregationParams",properties:{semantic_model:{type:"string"},agg:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},agg_params:{anyOf:[{type:"object",title:"MeasureAggregationParameters",properties:{percentile:{anyOf:[{type:"number"},{type:"null"}],default:null},use_discrete_percentile:{type:"boolean",default:!1},use_approximate_percentile:{type:"boolean",default:!1}},additionalProperties:!1},{type:"null"}],default:null},agg_time_dimension:{anyOf:[{type:"string"},{type:"null"}],default:null},non_additive_dimension:{anyOf:[{type:"object",title:"NonAdditiveDimension",properties:{name:{type:"string"},window_choice:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},window_groupings:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["name","window_choice","window_groupings"]},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["semantic_model","agg"]},{type:"null"}],default:null}},additionalProperties:!1},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},time_granularity:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{type:"object",title:"MetricConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},group:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},created_at:{type:"number"},group:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","description","label","type","type_params"]},propertyNames:{type:"string"}},groups:{type:"object",description:"The groups defined in the dbt project",additionalProperties:{type:"object",title:"Group",properties:{name:{type:"string"},resource_type:{const:"group"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},owner:{type:"object",title:"Owner",properties:{_extra:{type:"object",propertyNames:{type:"string"}},email:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},name:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},description:{anyOf:[{type:"string"},{type:"null"}],default:null},config:{type:"object",title:"GroupConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","owner"]},propertyNames:{type:"string"}},selectors:{type:"object",description:"The selectors defined in selectors.yml",propertyNames:{type:"string"}},disabled:{description:"A mapping of the disabled nodes in the target",anyOf:[{type:"object",additionalProperties:{type:"array",items:{anyOf:[{type:"object",title:"Seed",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"seed"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"SeedConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"seed"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},delimiter:{type:"string",default:","},quote_columns:{anyOf:[{type:"boolean"},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},root_path:{anyOf:[{type:"string"},{type:"null"}],default:null},depends_on:{type:"object",title:"MacroDependsOn",properties:{macros:{type:"array",items:{type:"string"}}},additionalProperties:!1},defer_relation:{anyOf:[{type:"object",title:"DeferRelation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},alias:{type:"string"},relation_name:{anyOf:[{type:"string"},{type:"null"}]},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},name:{type:"string"},description:{type:"string"},compiled_code:{anyOf:[{type:"string"},{type:"null"}]},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{anyOf:[{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},{type:"null"}]}},additionalProperties:!1,required:["database","schema","alias","relation_name","resource_type","name","description","compiled_code","meta","tags","config"]},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"Analysis",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"analysis"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"SingularTest",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"test"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"TestConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:"dbt_test__audit"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"test"},severity:{type:"string",default:"ERROR",pattern:"^([Ww][Aa][Rr][Nn]|[Ee][Rr][Rr][Oo][Rr])$"},store_failures:{anyOf:[{type:"boolean"},{type:"null"}],default:null},store_failures_as:{anyOf:[{type:"string"},{type:"null"}],default:null},where:{anyOf:[{type:"string"},{type:"null"}],default:null},limit:{anyOf:[{type:"integer"},{type:"null"}],default:null},fail_calc:{type:"string",default:"count(*)"},warn_if:{type:"string",default:"!= 0"},error_if:{type:"string",default:"!= 0"}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"HookNode",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"operation"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"Model",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"model"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"ModelConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},access:{enum:["private","protected","public"],default:"protected"},freshness:{anyOf:[{type:"object",title:"ModelFreshness",properties:{build_after:{type:"object",title:"ModelBuildAfter",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null},updates_on:{enum:["all","any"],default:"any"}},additionalProperties:!0}},additionalProperties:!0,required:["build_after"]},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},access:{enum:["private","protected","public"],default:"protected"},constraints:{type:"array",items:{type:"object",title:"ModelLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}},columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null},latest_version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null},deprecation_date:{anyOf:[{type:"string"},{type:"null"}],default:null},defer_relation:{anyOf:[{type:"object",title:"DeferRelation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},alias:{type:"string"},relation_name:{anyOf:[{type:"string"},{type:"null"}]},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},name:{type:"string"},description:{type:"string"},compiled_code:{anyOf:[{type:"string"},{type:"null"}]},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{anyOf:[{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},{type:"null"}]}},additionalProperties:!1,required:["database","schema","alias","relation_name","resource_type","name","description","compiled_code","meta","tags","config"]},{type:"null"}],default:null},primary_key:{type:"array",items:{type:"string"}},time_spine:{anyOf:[{type:"object",title:"TimeSpine",properties:{standard_granularity_column:{type:"string"},custom_granularities:{type:"array",items:{type:"object",title:"CustomGranularity",properties:{name:{type:"string"},column_name:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}}},additionalProperties:!1,required:["standard_granularity_column"]},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"SqlOperation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"sql_operation"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"GenericTest",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"test"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"TestConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:"dbt_test__audit"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"test"},severity:{type:"string",default:"ERROR",pattern:"^([Ww][Aa][Rr][Nn]|[Ee][Rr][Rr][Oo][Rr])$"},store_failures:{anyOf:[{type:"boolean"},{type:"null"}],default:null},store_failures_as:{anyOf:[{type:"string"},{type:"null"}],default:null},where:{anyOf:[{type:"string"},{type:"null"}],default:null},limit:{anyOf:[{type:"integer"},{type:"null"}],default:null},fail_calc:{type:"string",default:"count(*)"},warn_if:{type:"string",default:"!= 0"},error_if:{type:"string",default:"!= 0"}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},column_name:{anyOf:[{type:"string"},{type:"null"}],default:null},file_key_name:{anyOf:[{type:"string"},{type:"null"}],default:null},attached_node:{anyOf:[{type:"string"},{type:"null"}],default:null},test_metadata:{type:"object",title:"TestMetadata",properties:{name:{type:"string",default:"test"},kwargs:{type:"object",propertyNames:{type:"string"}},namespace:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum"]},{type:"object",title:"Snapshot",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"snapshot"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"SnapshotConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"snapshot"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},target_schema:{anyOf:[{type:"string"},{type:"null"}],default:null},target_database:{anyOf:[{type:"string"},{type:"null"}],default:null},updated_at:{anyOf:[{type:"string"},{type:"null"}],default:null},check_cols:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},snapshot_meta_column_names:{type:"object",title:"SnapshotMetaColumnNames",properties:{dbt_valid_to:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_valid_from:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_scd_id:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_updated_at:{anyOf:[{type:"string"},{type:"null"}],default:null},dbt_is_deleted:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},dbt_valid_to_current:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},defer_relation:{anyOf:[{type:"object",title:"DeferRelation",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},alias:{type:"string"},relation_name:{anyOf:[{type:"string"},{type:"null"}]},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},name:{type:"string"},description:{type:"string"},compiled_code:{anyOf:[{type:"string"},{type:"null"}]},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{anyOf:[{type:"object",title:"NodeConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"view"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null}},additionalProperties:!0},{type:"null"}]}},additionalProperties:!1,required:["database","schema","alias","relation_name","resource_type","name","description","compiled_code","meta","tags","config"]},{type:"null"}],default:null}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum","config"]},{type:"object",title:"Function",properties:{returns:{type:"object",title:"FunctionReturns",properties:{data_type:{type:"string"},description:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["data_type"]},database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"function"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"FunctionConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"function"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},type:{enum:["scalar","aggregate","table"],default:"scalar"},volatility:{anyOf:[{enum:["deterministic","stable","non-deterministic"]},{type:"null"}],default:null},runtime_version:{anyOf:[{type:"string"},{type:"null"}],default:null},entry_point:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},arguments:{type:"array",items:{type:"object",title:"FunctionArgument",properties:{name:{type:"string"},data_type:{type:"string"},description:{anyOf:[{type:"string"},{type:"null"}],default:null},default_value:{anyOf:[{},{type:"null"}],default:null}},additionalProperties:!1,required:["name","data_type"]}}},additionalProperties:!1,required:["returns","database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum","config"]},{type:"object",title:"SourceDefinition",properties:{database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"source"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},source_name:{type:"string"},source_description:{type:"string"},loader:{type:"string"},identifier:{type:"string"},quoting:{type:"object",title:"Quoting",properties:{database:{anyOf:[{type:"boolean"},{type:"null"}],default:null},schema:{anyOf:[{type:"boolean"},{type:"null"}],default:null},identifier:{anyOf:[{type:"boolean"},{type:"null"}],default:null},column:{anyOf:[{type:"boolean"},{type:"null"}],default:null}},additionalProperties:!1},loaded_at_field:{anyOf:[{type:"string"},{type:"null"}],default:null},loaded_at_query:{anyOf:[{type:"string"},{type:"null"}],default:null},freshness:{anyOf:[{type:"object",title:"FreshnessThreshold",properties:{warn_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},error_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},filter:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},external:{anyOf:[{type:"object",title:"ExternalTable",properties:{_extra:{type:"object",propertyNames:{type:"string"}},location:{anyOf:[{type:"string"},{type:"null"}],default:null},file_format:{anyOf:[{type:"string"},{type:"null"}],default:null},row_format:{anyOf:[{type:"string"},{type:"null"}],default:null},tbl_properties:{anyOf:[{type:"string"},{type:"null"}],default:null},partitions:{anyOf:[{type:"array",items:{type:"string"}},{type:"array",items:{type:"object",title:"ExternalPartition",properties:{_extra:{type:"object",propertyNames:{type:"string"}},name:{type:"string",default:""},description:{type:"string",default:""},data_type:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0}},{type:"null"}],default:null}},additionalProperties:!0},{type:"null"}],default:null},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},source_meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{type:"object",title:"SourceConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},event_time:{default:null},freshness:{anyOf:[{type:"object",title:"FreshnessThreshold",properties:{warn_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},error_after:{anyOf:[{type:"object",title:"Time",properties:{count:{anyOf:[{type:"integer"},{type:"null"}],default:null},period:{anyOf:[{enum:["minute","hour","day"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},filter:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}]},loaded_at_field:{anyOf:[{type:"string"},{type:"null"}],default:null},loaded_at_query:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},created_at:{type:"number"},unrendered_database:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_schema:{anyOf:[{type:"string"},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","source_name","source_description","loader","identifier"]},{type:"object",title:"Exposure",properties:{name:{type:"string"},resource_type:{const:"exposure"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},type:{enum:["dashboard","notebook","analysis","ml","application"]},owner:{type:"object",title:"Owner",properties:{_extra:{type:"object",propertyNames:{type:"string"}},email:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},name:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},description:{type:"string",default:""},label:{anyOf:[{type:"string"},{type:"null"}],default:null},maturity:{anyOf:[{enum:["low","medium","high"]},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{type:"object",title:"ExposureConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},tags:{type:"array",items:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},url:{anyOf:[{type:"string"},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},created_at:{type:"number"}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","type","owner"]},{type:"object",title:"Metric",properties:{name:{type:"string"},resource_type:{const:"metric"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},description:{type:"string"},label:{type:"string"},type:{enum:["simple","ratio","cumulative","derived","conversion"]},type_params:{type:"object",title:"MetricTypeParams",properties:{measure:{anyOf:[{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null},input_measures:{type:"array",items:{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},numerator:{anyOf:[{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null},denominator:{anyOf:[{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},grain_to_date:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},metrics:{anyOf:[{type:"array",items:{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},{type:"null"}],default:null},conversion_type_params:{anyOf:[{type:"object",title:"ConversionTypeParams",properties:{base_measure:{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},conversion_measure:{type:"object",title:"MetricInputMeasure",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},join_to_timespine:{type:"boolean",default:!1},fill_nulls_with:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},entity:{type:"string"},calculation:{enum:["conversions","conversion_rate"],default:"conversion_rate"},window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},constant_properties:{anyOf:[{type:"array",items:{type:"object",title:"ConstantPropertyInput",properties:{base_property:{type:"string"},conversion_property:{type:"string"}},additionalProperties:!1,required:["base_property","conversion_property"]}},{type:"null"}],default:null}},additionalProperties:!1,required:["base_measure","conversion_measure","entity"]},{type:"null"}],default:null},cumulative_type_params:{anyOf:[{type:"object",title:"CumulativeTypeParams",properties:{window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},grain_to_date:{anyOf:[{type:"string"},{type:"null"}],default:null},period_agg:{enum:["first","last","average"],default:"first"},metric:{anyOf:[{type:"object",title:"MetricInput",properties:{name:{type:"string"},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},offset_window:{anyOf:[{type:"object",title:"MetricTimeWindow",properties:{count:{type:"integer"},granularity:{type:"string"}},additionalProperties:!1,required:["count","granularity"]},{type:"null"}],default:null},offset_to_grain:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},metric_aggregation_params:{anyOf:[{type:"object",title:"MetricAggregationParams",properties:{semantic_model:{type:"string"},agg:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},agg_params:{anyOf:[{type:"object",title:"MeasureAggregationParameters",properties:{percentile:{anyOf:[{type:"number"},{type:"null"}],default:null},use_discrete_percentile:{type:"boolean",default:!1},use_approximate_percentile:{type:"boolean",default:!1}},additionalProperties:!1},{type:"null"}],default:null},agg_time_dimension:{anyOf:[{type:"string"},{type:"null"}],default:null},non_additive_dimension:{anyOf:[{type:"object",title:"NonAdditiveDimension",properties:{name:{type:"string"},window_choice:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},window_groupings:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["name","window_choice","window_groupings"]},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["semantic_model","agg"]},{type:"null"}],default:null}},additionalProperties:!1},filter:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}],default:null},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},time_granularity:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}},config:{type:"object",title:"MetricConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},group:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},created_at:{type:"number"},group:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","description","label","type","type_params"]},{type:"object",title:"SavedQuery",properties:{name:{type:"string"},resource_type:{const:"saved_query"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},query_params:{type:"object",title:"QueryParams",properties:{metrics:{type:"array",items:{type:"string"}},group_by:{type:"array",items:{type:"string"}},where:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}]},order_by:{type:"array",items:{type:"string"}},limit:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["metrics","group_by","where"]},exports:{type:"array",items:{type:"object",title:"Export",properties:{name:{type:"string"},config:{type:"object",title:"ExportConfig",properties:{export_as:{enum:["table","view"]},schema_name:{anyOf:[{type:"string"},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["export_as"]},unrendered_config:{type:"object",additionalProperties:{type:"string"},propertyNames:{type:"string"}}},additionalProperties:!1,required:["name","config"]}},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},config:{type:"object",title:"SavedQueryConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},group:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},export_as:{anyOf:[{enum:["table","view"]},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},cache:{type:"object",title:"SavedQueryCache",properties:{enabled:{type:"boolean",default:!1}},additionalProperties:!1}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},created_at:{type:"number"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","query_params","exports"]},{type:"object",title:"SemanticModel",properties:{name:{type:"string"},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},model:{type:"string"},node_relation:{anyOf:[{type:"object",title:"NodeRelation",properties:{alias:{type:"string"},schema_name:{type:"string"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:""}},additionalProperties:!1,required:["alias","schema_name"]},{type:"null"}]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},defaults:{anyOf:[{type:"object",title:"Defaults",properties:{agg_time_dimension:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},entities:{type:"array",items:{type:"object",title:"Entity",properties:{name:{type:"string"},type:{enum:["foreign","natural","primary","unique"]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},role:{anyOf:[{type:"string"},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},config:{anyOf:[{type:"object",title:"SemanticLayerElementConfig",properties:{meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["name","type"]}},measures:{type:"array",items:{type:"object",title:"Measure",properties:{name:{type:"string"},agg:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},create_metric:{type:"boolean",default:!1},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},agg_params:{anyOf:[{type:"object",title:"MeasureAggregationParameters",properties:{percentile:{anyOf:[{type:"number"},{type:"null"}],default:null},use_discrete_percentile:{type:"boolean",default:!1},use_approximate_percentile:{type:"boolean",default:!1}},additionalProperties:!1},{type:"null"}],default:null},non_additive_dimension:{anyOf:[{type:"object",title:"NonAdditiveDimension",properties:{name:{type:"string"},window_choice:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},window_groupings:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["name","window_choice","window_groupings"]},{type:"null"}],default:null},agg_time_dimension:{anyOf:[{type:"string"},{type:"null"}],default:null},config:{anyOf:[{type:"object",title:"SemanticLayerElementConfig",properties:{meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["name","agg"]}},dimensions:{type:"array",items:{type:"object",title:"Dimension",properties:{name:{type:"string"},type:{enum:["categorical","time"]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},is_partition:{type:"boolean",default:!1},type_params:{anyOf:[{type:"object",title:"DimensionTypeParams",properties:{time_granularity:{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},validity_params:{anyOf:[{type:"object",title:"DimensionValidityParams",properties:{is_start:{type:"boolean",default:!1},is_end:{type:"boolean",default:!1}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["time_granularity"]},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},config:{anyOf:[{type:"object",title:"SemanticLayerElementConfig",properties:{meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["name","type"]}},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},created_at:{type:"number"},config:{type:"object",title:"SemanticModelConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},group:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},primary_entity:{anyOf:[{type:"string"},{type:"null"}],default:null},group:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","model","node_relation"]},{type:"object",title:"UnitTestDefinition",properties:{model:{type:"string"},given:{type:"array",items:{type:"object",title:"UnitTestInputFixture",properties:{input:{type:"string"},rows:{anyOf:[{type:"string"},{type:"array",items:{type:"object",propertyNames:{type:"string"}}},{type:"null"}],default:null},format:{enum:["csv","dict","sql"],default:"dict"},fixture:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["input"]}},expect:{type:"object",title:"UnitTestOutputFixture",properties:{rows:{anyOf:[{type:"string"},{type:"array",items:{type:"object",propertyNames:{type:"string"}}},{type:"null"}],default:null},format:{enum:["csv","dict","sql"],default:"dict"},fixture:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},name:{type:"string"},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},description:{type:"string",default:""},overrides:{anyOf:[{type:"object",title:"UnitTestOverrides",properties:{macros:{type:"object",propertyNames:{type:"string"}},vars:{type:"object",propertyNames:{type:"string"}},env_vars:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},config:{type:"object",title:"UnitTestConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},tags:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}}]},meta:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0}},additionalProperties:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},created_at:{type:"number"},versions:{anyOf:[{type:"object",title:"UnitTestNodeVersions",properties:{include:{anyOf:[{type:"array",items:{anyOf:[{type:"string"},{type:"number"}]}},{type:"null"}],default:null},exclude:{anyOf:[{type:"array",items:{anyOf:[{type:"string"},{type:"number"}]}},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["model","given","expect","name","resource_type","package_name","path","original_file_path","unique_id","fqn"]}]}},propertyNames:{type:"string"}},{type:"null"}]},parent_map:{description:"A mapping from child nodes to their dependencies",anyOf:[{type:"object",additionalProperties:{type:"array",items:{type:"string"}},propertyNames:{type:"string"}},{type:"null"}]},child_map:{description:"A mapping from parent nodes to their dependents",anyOf:[{type:"object",additionalProperties:{type:"array",items:{type:"string"}},propertyNames:{type:"string"}},{type:"null"}]},group_map:{description:"A mapping from group names to their nodes",anyOf:[{type:"object",additionalProperties:{type:"array",items:{type:"string"}},propertyNames:{type:"string"}},{type:"null"}]},saved_queries:{type:"object",description:"The saved queries defined in the dbt project",additionalProperties:{type:"object",title:"SavedQuery",properties:{name:{type:"string"},resource_type:{const:"saved_query"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},query_params:{type:"object",title:"QueryParams",properties:{metrics:{type:"array",items:{type:"string"}},group_by:{type:"array",items:{type:"string"}},where:{anyOf:[{type:"object",title:"WhereFilterIntersection",properties:{where_filters:{type:"array",items:{type:"object",title:"WhereFilter",properties:{where_sql_template:{type:"string"}},additionalProperties:!1,required:["where_sql_template"]}}},additionalProperties:!1,required:["where_filters"]},{type:"null"}]},order_by:{type:"array",items:{type:"string"}},limit:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["metrics","group_by","where"]},exports:{type:"array",items:{type:"object",title:"Export",properties:{name:{type:"string"},config:{type:"object",title:"ExportConfig",properties:{export_as:{enum:["table","view"]},schema_name:{anyOf:[{type:"string"},{type:"null"}],default:null},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["export_as"]},unrendered_config:{type:"object",additionalProperties:{type:"string"},propertyNames:{type:"string"}}},additionalProperties:!1,required:["name","config"]}},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},config:{type:"object",title:"SavedQueryConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},group:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}},export_as:{anyOf:[{enum:["table","view"]},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},cache:{type:"object",title:"SavedQueryCache",properties:{enabled:{type:"boolean",default:!1}},additionalProperties:!1}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},created_at:{type:"number"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","query_params","exports"]},propertyNames:{type:"string"}},semantic_models:{type:"object",description:"The semantic models defined in the dbt project",additionalProperties:{type:"object",title:"SemanticModel",properties:{name:{type:"string"},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},model:{type:"string"},node_relation:{anyOf:[{type:"object",title:"NodeRelation",properties:{alias:{type:"string"},schema_name:{type:"string"},database:{anyOf:[{type:"string"},{type:"null"}],default:null},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:""}},additionalProperties:!1,required:["alias","schema_name"]},{type:"null"}]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},defaults:{anyOf:[{type:"object",title:"Defaults",properties:{agg_time_dimension:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},entities:{type:"array",items:{type:"object",title:"Entity",properties:{name:{type:"string"},type:{enum:["foreign","natural","primary","unique"]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},role:{anyOf:[{type:"string"},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},config:{anyOf:[{type:"object",title:"SemanticLayerElementConfig",properties:{meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["name","type"]}},measures:{type:"array",items:{type:"object",title:"Measure",properties:{name:{type:"string"},agg:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},create_metric:{type:"boolean",default:!1},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},agg_params:{anyOf:[{type:"object",title:"MeasureAggregationParameters",properties:{percentile:{anyOf:[{type:"number"},{type:"null"}],default:null},use_discrete_percentile:{type:"boolean",default:!1},use_approximate_percentile:{type:"boolean",default:!1}},additionalProperties:!1},{type:"null"}],default:null},non_additive_dimension:{anyOf:[{type:"object",title:"NonAdditiveDimension",properties:{name:{type:"string"},window_choice:{enum:["sum","min","max","count_distinct","sum_boolean","average","percentile","median","count"]},window_groupings:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["name","window_choice","window_groupings"]},{type:"null"}],default:null},agg_time_dimension:{anyOf:[{type:"string"},{type:"null"}],default:null},config:{anyOf:[{type:"object",title:"SemanticLayerElementConfig",properties:{meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["name","agg"]}},dimensions:{type:"array",items:{type:"object",title:"Dimension",properties:{name:{type:"string"},type:{enum:["categorical","time"]},description:{anyOf:[{type:"string"},{type:"null"}],default:null},label:{anyOf:[{type:"string"},{type:"null"}],default:null},is_partition:{type:"boolean",default:!1},type_params:{anyOf:[{type:"object",title:"DimensionTypeParams",properties:{time_granularity:{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},validity_params:{anyOf:[{type:"object",title:"DimensionValidityParams",properties:{is_start:{type:"boolean",default:!1},is_end:{type:"boolean",default:!1}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["time_granularity"]},{type:"null"}],default:null},expr:{anyOf:[{type:"string"},{type:"null"}],default:null},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},config:{anyOf:[{type:"object",title:"SemanticLayerElementConfig",properties:{meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null}},additionalProperties:!1,required:["name","type"]}},metadata:{anyOf:[{type:"object",title:"SourceFileMetadata",properties:{repo_file_path:{type:"string"},file_slice:{type:"object",title:"FileSlice",properties:{filename:{type:"string"},content:{type:"string"},start_line_number:{type:"integer"},end_line_number:{type:"integer"}},additionalProperties:!1,required:["filename","content","start_line_number","end_line_number"]}},additionalProperties:!1,required:["repo_file_path","file_slice"]},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},created_at:{type:"number"},config:{type:"object",title:"SemanticModelConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},group:{anyOf:[{type:"string"},{type:"null"}],default:null},meta:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!0},unrendered_config:{type:"object",propertyNames:{type:"string"}},primary_entity:{anyOf:[{type:"string"},{type:"null"}],default:null},group:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["name","resource_type","package_name","path","original_file_path","unique_id","fqn","model","node_relation"]},propertyNames:{type:"string"}},unit_tests:{type:"object",description:"The unit tests defined in the project",additionalProperties:{type:"object",title:"UnitTestDefinition",properties:{model:{type:"string"},given:{type:"array",items:{type:"object",title:"UnitTestInputFixture",properties:{input:{type:"string"},rows:{anyOf:[{type:"string"},{type:"array",items:{type:"object",propertyNames:{type:"string"}}},{type:"null"}],default:null},format:{enum:["csv","dict","sql"],default:"dict"},fixture:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["input"]}},expect:{type:"object",title:"UnitTestOutputFixture",properties:{rows:{anyOf:[{type:"string"},{type:"array",items:{type:"object",propertyNames:{type:"string"}}},{type:"null"}],default:null},format:{enum:["csv","dict","sql"],default:"dict"},fixture:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},name:{type:"string"},resource_type:{enum:["model","analysis","test","snapshot","operation","seed","rpc","sql_operation","doc","source","macro","exposure","metric","group","saved_query","semantic_model","unit_test","fixture","function"]},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},description:{type:"string",default:""},overrides:{anyOf:[{type:"object",title:"UnitTestOverrides",properties:{macros:{type:"object",propertyNames:{type:"string"}},vars:{type:"object",propertyNames:{type:"string"}},env_vars:{type:"object",propertyNames:{type:"string"}}},additionalProperties:!1},{type:"null"}],default:null},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},config:{type:"object",title:"UnitTestConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},tags:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}}]},meta:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0}},additionalProperties:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},created_at:{type:"number"},versions:{anyOf:[{type:"object",title:"UnitTestNodeVersions",properties:{include:{anyOf:[{type:"array",items:{anyOf:[{type:"string"},{type:"number"}]}},{type:"null"}],default:null},exclude:{anyOf:[{type:"array",items:{anyOf:[{type:"string"},{type:"number"}]}},{type:"null"}],default:null}},additionalProperties:!1},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["model","given","expect","name","resource_type","package_name","path","original_file_path","unique_id","fqn"]},propertyNames:{type:"string"}},functions:{type:"object",description:"The functions defined in the dbt project",additionalProperties:{type:"object",title:"Function",properties:{returns:{type:"object",title:"FunctionReturns",properties:{data_type:{type:"string"},description:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1,required:["data_type"]},database:{anyOf:[{type:"string"},{type:"null"}]},schema:{type:"string"},name:{type:"string"},resource_type:{const:"function"},package_name:{type:"string"},path:{type:"string"},original_file_path:{type:"string"},unique_id:{type:"string"},fqn:{type:"array",items:{type:"string"}},alias:{type:"string"},checksum:{type:"object",title:"FileHash",properties:{name:{type:"string"},checksum:{type:"string"}},additionalProperties:!1,required:["name","checksum"]},config:{type:"object",title:"FunctionConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},enabled:{type:"boolean",default:!0},alias:{anyOf:[{type:"string"},{type:"null"}],default:null},schema:{anyOf:[{type:"string"},{type:"null"}],default:null},database:{anyOf:[{type:"string"},{type:"null"}],default:null},tags:{anyOf:[{type:"array",items:{type:"string"}},{type:"string"}]},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},materialized:{type:"string",default:"function"},incremental_strategy:{anyOf:[{type:"string"},{type:"null"}],default:null},batch_size:{default:null},lookback:{default:1},begin:{default:null},persist_docs:{type:"object",propertyNames:{type:"string"}},"post-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},"pre-hook":{type:"array",items:{type:"object",title:"Hook",properties:{sql:{type:"string"},transaction:{type:"boolean",default:!0},index:{anyOf:[{type:"integer"},{type:"null"}],default:null}},additionalProperties:!1,required:["sql"]}},quoting:{type:"object",propertyNames:{type:"string"}},column_types:{type:"object",propertyNames:{type:"string"}},full_refresh:{anyOf:[{type:"boolean"},{type:"null"}],default:null},unique_key:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}},{type:"null"}],default:null},on_schema_change:{anyOf:[{type:"string"},{type:"null"}],default:"ignore"},on_configuration_change:{enum:["apply","continue","fail"]},grants:{type:"object",propertyNames:{type:"string"}},packages:{type:"array",items:{type:"string"}},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},contract:{type:"object",title:"ContractConfig",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0}},additionalProperties:!1},event_time:{default:null},concurrent_batches:{default:null},type:{enum:["scalar","aggregate","table"],default:"scalar"},volatility:{anyOf:[{enum:["deterministic","stable","non-deterministic"]},{type:"null"}],default:null},runtime_version:{anyOf:[{type:"string"},{type:"null"}],default:null},entry_point:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},description:{type:"string",default:""},columns:{type:"object",additionalProperties:{type:"object",title:"ColumnInfo",properties:{name:{type:"string"},description:{type:"string",default:""},meta:{type:"object",propertyNames:{type:"string"}},data_type:{anyOf:[{type:"string"},{type:"null"}],default:null},constraints:{type:"array",items:{type:"object",title:"ColumnLevelConstraint",properties:{type:{enum:["check","not_null","unique","primary_key","foreign_key","custom"]},name:{anyOf:[{type:"string"},{type:"null"}],default:null},expression:{anyOf:[{type:"string"},{type:"null"}],default:null},warn_unenforced:{type:"boolean",default:!0},warn_unsupported:{type:"boolean",default:!0},to:{anyOf:[{type:"string"},{type:"null"}],default:null},to_columns:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type"]}},quote:{anyOf:[{type:"boolean"},{type:"null"}],default:null},config:{type:"object",title:"ColumnConfig",properties:{_extra:{type:"object",propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},tags:{type:"array",items:{type:"string"}}},additionalProperties:!0},tags:{type:"array",items:{type:"string"}},_extra:{type:"object",propertyNames:{type:"string"}},granularity:{anyOf:[{enum:["nanosecond","microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"]},{type:"null"}],default:null},doc_blocks:{type:"array",items:{type:"string"}}},additionalProperties:!0,required:["name"]},propertyNames:{type:"string"}},meta:{type:"object",propertyNames:{type:"string"}},group:{anyOf:[{type:"string"},{type:"null"}],default:null},docs:{type:"object",title:"Docs",properties:{show:{type:"boolean",default:!0},node_color:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},patch_path:{anyOf:[{type:"string"},{type:"null"}],default:null},build_path:{anyOf:[{type:"string"},{type:"null"}],default:null},unrendered_config:{type:"object",propertyNames:{type:"string"}},created_at:{type:"number"},config_call_dict:{type:"object",propertyNames:{type:"string"}},unrendered_config_call_dict:{type:"object",propertyNames:{type:"string"}},relation_name:{anyOf:[{type:"string"},{type:"null"}],default:null},raw_code:{type:"string",default:""},doc_blocks:{type:"array",items:{type:"string"}},language:{type:"string",default:"sql"},refs:{type:"array",items:{type:"object",title:"RefArgs",properties:{name:{type:"string"},package:{anyOf:[{type:"string"},{type:"null"}],default:null},version:{anyOf:[{type:"string"},{type:"number"},{type:"null"}],default:null}},additionalProperties:!1,required:["name"]}},sources:{type:"array",items:{type:"array",items:{type:"string"}}},metrics:{type:"array",items:{type:"array",items:{type:"string"}}},functions:{type:"array",items:{type:"array",items:{type:"string"}}},depends_on:{type:"object",title:"DependsOn",properties:{macros:{type:"array",items:{type:"string"}},nodes:{type:"array",items:{type:"string"}}},additionalProperties:!1},compiled_path:{anyOf:[{type:"string"},{type:"null"}],default:null},compiled:{type:"boolean",default:!1},compiled_code:{anyOf:[{type:"string"},{type:"null"}],default:null},extra_ctes_injected:{type:"boolean",default:!1},extra_ctes:{type:"array",items:{type:"object",title:"InjectedCTE",properties:{id:{type:"string"},sql:{type:"string"}},additionalProperties:!1,required:["id","sql"]}},_pre_injected_sql:{anyOf:[{type:"string"},{type:"null"}],default:null},contract:{type:"object",title:"Contract",properties:{enforced:{type:"boolean",default:!1},alias_types:{type:"boolean",default:!0},checksum:{anyOf:[{type:"string"},{type:"null"}],default:null}},additionalProperties:!1},arguments:{type:"array",items:{type:"object",title:"FunctionArgument",properties:{name:{type:"string"},data_type:{type:"string"},description:{anyOf:[{type:"string"},{type:"null"}],default:null},default_value:{anyOf:[{},{type:"null"}],default:null}},additionalProperties:!1,required:["name","data_type"]}}},additionalProperties:!1,required:["returns","database","schema","name","resource_type","package_name","path","original_file_path","unique_id","fqn","alias","checksum","config"]},propertyNames:{type:"string"}}},additionalProperties:!1,required:["metadata","nodes","sources","macros","docs","exposures","metrics","groups","selectors","disabled","parent_map","child_map","group_map","saved_queries","semantic_models","unit_tests"],$id:"https://schemas.getdbt.com/dbt/manifest/v12.json"};var ule="umf.dbt.manifest",T6e=lle,lE;function S6e(e){let t=e,n=[{code:"DBT_MANIFEST_CONTEXT",path:"",severity:"warning",message:"Native schema shapes do not establish graph/SQL/Jinja validity, format constraints or exact-number constraints beyond JS precision"}],r=(a,l,c,u="warning")=>n.push({code:a,path:l,message:c,severity:u});if(Object.keys(t).some((a)=>!["profile","root"].includes(a)))r("DBT_MANIFEST_REPRESENTATION","","Unknown representation fields remain in UMF");function i(a,l){let c=a.kind==="null"?["kind"]:a.kind==="array"?["kind","items"]:a.kind==="object"?["kind","members"]:["kind","value"];if(Object.keys(a).some((u)=>!c.includes(u)))r("DBT_MANIFEST_REPRESENTATION",l,"Unknown tagged-tree fields remain in UMF");if(a.kind==="object")for(let[u,p]of Object.entries(a.members))i(p,l+"/"+$e(u));if(a.kind==="array")a.items.forEach((u,p)=>i(u,l+"/"+p))}i(t.root,"");let s=t.root.kind==="object"?t.root.members.metadata:void 0,o=s?.kind==="object"?s.members.dbt_schema_version:void 0;if(o?.kind!=="string")return r("DBT_MANIFEST_STRUCTURE","/metadata/dbt_schema_version","Expected manifest object with metadata object and schema version string","error"),n;if(o.value!=="https://schemas.getdbt.com/dbt/manifest/v12.json")return r("DBT_MANIFEST_VERSION","/metadata/dbt_schema_version","Unknown artifact version preserved without interpretation"),n;if(lE??=mt(!1).compile(cle),!lE(JSON.parse(Be(t.root))))for(let a of(lE.errors??[]).slice(0,100))r("DBT_MANIFEST_NATIVE_SCHEMA",a.instancePath,a.message??"Native grammar mismatch");if((lE.errors?.length??0)>100)r("DBT_MANIFEST_DIAGNOSTICS_TRUNCATED","","More than 100 native schema diagnostics; first 100 retained");return n}function E6e(){return new nt().register(T6e,S6e)}function ple(e){return We(e,E6e())}function k6e(e){let t=ple(e);if(!t.valid)throw new U("DBT_MANIFEST_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="manifest")?.elements.find((r)=>r.id==="manifest")?.extensions[ule];if(!n||e.vocabularies[ule]?.version!=="0.1.0")throw new U("DBT_MANIFEST_PAYLOAD","Expected pinned dbt manifest payload");return Ae(n)}function dle(e){let t=k6e(e);if(ple(e).diagnostics.some((n)=>n.code==="DBT_MANIFEST_REPRESENTATION"))throw new U("DBT_MANIFEST_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var fle={id:"umf.arrow",version:"0.1.0",coreVersion:"0.1.0",description:"Arrow integration schema JSON with exact unknown content and ordered metadata",schema:{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:arrow:0.1.0",type:"object",properties:{profile:{const:"arrow-integration-schema"},root:{$ref:"#/$defs/node"}},required:["profile","root"],additionalProperties:!0,$defs:{node:{oneOf:[{type:"object",required:["kind"],properties:{kind:{const:"null"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"boolean"},value:{type:"boolean"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"string"},value:{type:"string"}}},{type:"object",required:["kind","value"],properties:{kind:{const:"number"},value:{type:"string",pattern:"^-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?$"}}},{type:"object",required:["kind","items"],properties:{kind:{const:"array"},items:{type:"array",items:{$ref:"#/$defs/node"}}}},{type:"object",required:["kind","members"],properties:{kind:{const:"object"},members:{type:"object",additionalProperties:{$ref:"#/$defs/node"}}}}]}}},semantics:"CONTRACT-016. Exact schema JSON preservation is separate from native IPC and record-batch validity. Unknown types/properties and duplicate metadata remain authoritative in source.",scopes:["element"],capabilities:{validation:"semantic",directions:["import","export"],native:{system:"Apache Arrow integration schema JSON",version:"Grammar profile 0.1.0; native feasibility evidence JS 21.2.0 / PyArrow 21.0.0",subset:"Schema JSON only, exact metadata/type parameter retention and candidate edits. Guarded schema-only IPC export via an explicit pinned backend; no arbitrary IPC import or array/data support claimed."},evidence:["tests/arrow/schema.test.ts","tests/arrow/ipc.test.ts","fixtures/arrow/capability-results.json","fixtures/arrow/public-ipc-oracle-results.json","fixtures/arrow/upstream/schema-results.json"]}};var hC={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:arrow:integration-schema:0.1.0",description:"Schema portion of Arrow integration JSON, including future type names and unknown properties retained without interpretation. Buffer/data validity and native IPC representability are separate.",type:"object",properties:{fields:{type:"array",items:{$ref:"#/$defs/field"}},metadata:{type:"array",items:{type:"object",properties:{key:{type:"string"},value:{type:"string"}},required:["key","value"],additionalProperties:!0}}},required:["fields"],additionalProperties:!0,$defs:{field:{type:"object",properties:{name:{type:"string"},nullable:{type:"boolean"},type:{$ref:"#/$defs/type"},children:{type:"array",items:{$ref:"#/$defs/field"}},metadata:{type:"array",items:{type:"object",properties:{key:{type:"string"},value:{type:"string"}},required:["key","value"],additionalProperties:!0}},dictionary:{type:"object",properties:{id:{type:"integer"},indexType:{type:"object",properties:{name:{const:"int"},bitWidth:{enum:[8,16,32,64]},isSigned:{type:"boolean"}},required:["name","bitWidth","isSigned"],additionalProperties:!0},isOrdered:{type:"boolean"}},required:["id"],additionalProperties:!0}},required:["name","nullable","type"],additionalProperties:!0},type:{anyOf:[{type:"object",properties:{name:{const:"null"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"NONE"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"bool"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"binary"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"largebinary"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"binaryview"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"utf8"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"largeutf8"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"utf8view"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"list"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"largelist"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"listview"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"largelistview"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"struct"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"struct_"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"runendencoded"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"int"},bitWidth:{enum:[8,16,32,64]},isSigned:{type:"boolean"}},required:["name","bitWidth","isSigned"],additionalProperties:!0},{type:"object",properties:{name:{const:"floatingpoint"},precision:{enum:["HALF","SINGLE","DOUBLE"]}},required:["name","precision"],additionalProperties:!0},{type:"object",properties:{name:{const:"decimal"},bitWidth:{enum:[32,64,128,256]},precision:{type:"integer",minimum:1,maximum:76},scale:{type:"integer",minimum:-2147483648,maximum:2147483647}},required:["name","precision","scale"],additionalProperties:!0},{type:"object",properties:{name:{const:"date"},unit:{enum:["DAY","MILLISECOND"]}},required:["name","unit"],additionalProperties:!0},{type:"object",properties:{name:{const:"time"},unit:{enum:["SECOND","MILLISECOND","MICROSECOND","NANOSECOND"]},bitWidth:{enum:[32,64]}},required:["name","unit","bitWidth"],additionalProperties:!0},{type:"object",properties:{name:{const:"timestamp"},unit:{enum:["SECOND","MILLISECOND","MICROSECOND","NANOSECOND"]},timezone:{type:["string","null"]}},required:["name","unit"],additionalProperties:!0},{type:"object",properties:{name:{const:"duration"},unit:{enum:["SECOND","MILLISECOND","MICROSECOND","NANOSECOND"]}},required:["name","unit"],additionalProperties:!0},{type:"object",properties:{name:{const:"interval"},unit:{enum:["YEAR_MONTH","DAY_TIME","MONTH_DAY_NANO"]}},required:["name","unit"],additionalProperties:!0},{type:"object",properties:{name:{const:"fixedsizebinary"},byteWidth:{type:"integer",minimum:0,maximum:2147483647}},required:["name","byteWidth"],additionalProperties:!0},{type:"object",properties:{name:{const:"fixedsizelist"},listSize:{type:"integer",minimum:0,maximum:2147483647}},required:["name","listSize"],additionalProperties:!0},{type:"object",properties:{name:{const:"map"},keysSorted:{type:"boolean"}},required:["name"],additionalProperties:!0},{type:"object",properties:{name:{const:"union"},mode:{enum:["DENSE","SPARSE"]},typeIds:{type:"array",items:{type:"integer",minimum:0,maximum:127},uniqueItems:!0}},required:["name","mode","typeIds"],additionalProperties:!0},{type:"object",properties:{name:{type:"string",not:{enum:["null","NONE","bool","binary","largebinary","binaryview","utf8","largeutf8","utf8view","list","largelist","listview","largelistview","struct","struct_","runendencoded","int","floatingpoint","decimal","date","time","timestamp","duration","interval","fixedsizebinary","fixedsizelist","map","union"]}}},required:["name"],additionalProperties:!0}]}}};var mle="umf.arrow",P6e=fle,$6e=new Map(hC.$defs.type.anyOf.filter((e)=>e.properties.name.const).map((e)=>[e.properties.name.const,e])),gC;function yle(e){let t=/^(-?)([0-9]+)(?:\.([0-9]+))?(?:[eE]([+-]?[0-9]+))?$/.exec(e);if(!t)return;let n=(t[2]+(t[3]??"")).replace(/^0+/,"");if(!n)return 0n;let r=BigInt((t[3]??"").length)-BigInt(t[4]??"0");if(r>0n){if(r>=BigInt(n.length)||!/^[0]+$/.test(n.slice(-Number(r))))return;n=n.slice(0,-Number(r))}else{if(BigInt(n.length)-r>19n)return;n+="0".repeat(Number(-r))}if(n.length>19)return;return BigInt(t[1]+n)}function I6e(e){let t=e,n=[{code:"ARROW_NATIVE_UNVERIFIED",path:"",severity:"warning",message:"Schema JSON preservation does not establish IPC, dictionary-data, extension-type or record-batch validity"}],r=(u,p,d,f="warning")=>n.push({code:u,path:p,message:d,severity:f});if(Object.keys(t).some((u)=>!["profile","root"].includes(u)))r("ARROW_REPRESENTATION","","Unknown representation fields must stay in UMF");function i(u,p){let d=u.kind==="null"?["kind"]:u.kind==="object"?["kind","members"]:u.kind==="array"?["kind","items"]:["kind","value"];if(Object.keys(u).some((f)=>!d.includes(f)))r("ARROW_REPRESENTATION",p,"Unknown tagged-tree fields must stay in UMF");if(u.kind==="object")for(let[f,m]of Object.entries(u.members))i(m,p+"/"+$e(f));if(u.kind==="array")u.items.forEach((f,m)=>i(f,p+"/"+m))}i(t.root,"/root");let s=JSON.parse(Be(t.root));if(gC??=mt(!1).compile(hC),!gC(s)){for(let u of gC.errors??[])r("ARROW_STRUCTURE",u.instancePath,u.message??"Invalid schema JSON","error");return n}function o(u,p,d){for(let f of Object.keys(u))if(!p.includes(f))r("ARROW_UNKNOWN",d+"/"+$e(f),"Native content retained without interpretation")}function a(u,p){let d=new Set;u.forEach((f,m)=>{if(o(f,["key","value"],p+"/"+m),d.has(f.key))r("ARROW_DUPLICATE_METADATA",p+"/"+m,"Ordered duplicate metadata retained; native Map conversion may collapse it");d.add(f.key)})}function l(u){let p=t.root;for(let d of Dr(u))p=Tr(p,d);if(p.kind!=="number"||yle(p.value)===void 0)r("ARROW_INTEGER",u,"Known integer parameter must be exact, not a rounded host value","error")}function c(u,p){o(u,["name","nullable","type","children","metadata","dictionary"],p),a(u.metadata??[],p+"/metadata");let d=$6e.get(u.type.name);if(!d)r("ARROW_UNKNOWN_TYPE",p+"/type","Future or unrecognized Arrow type retained");else o(u.type,Object.keys(d.properties),p+"/type");if(d){for(let[m,y]of Object.entries(d.properties))if(Object.hasOwn(u.type,m)&&(y.type==="integer"||typeof y.enum?.[0]==="number"))l(p+"/type/"+$e(m))}if(u.type.name==="union")u.type.typeIds.forEach((m,y)=>l(p+"/type/typeIds/"+y));let f=u.children??[];if(["list","largelist","listview","largelistview","fixedsizelist","map"].includes(u.type.name)&&f.length!==1)r("ARROW_CHILDREN",p+"/children","This native type requires one child field","error");if(u.type.name==="runendencoded"&&f.length!==2)r("ARROW_CHILDREN",p+"/children","Run-end encoding requires run-ends and values children","error");if(d&&!["list","largelist","listview","largelistview","fixedsizelist","map","struct","struct_","union","runendencoded"].includes(u.type.name)&&f.length)r("ARROW_CHILDREN",p+"/children","Primitive type cannot have child fields","error");if(u.type.name==="map"&&(f[0]?.nullable!==!1||!["struct","struct_"].includes(f[0]?.type?.name)||f[0]?.children?.length!==2||f[0]?.children?.[0]?.nullable!==!1))r("ARROW_MAP",p+"/children","Map requires non-null entries struct with two children and non-null key","error");if(u.type.name==="runendencoded"&&(f[0]?.nullable!==!1||f[0]?.type?.name!=="int"||f[0]?.type?.isSigned!==!0||![16,32,64].includes(f[0]?.type?.bitWidth)))r("ARROW_RUN_ENDS",p+"/children/0","Run ends must be non-null signed int16/int32/int64","error");if(u.type.name==="union"&&u.type.typeIds.length!==f.length)r("ARROW_UNION",p+"/type/typeIds","Union type IDs must correspond to children","error");if(u.type.name==="time"&&u.type.bitWidth!==(["SECOND","MILLISECOND"].includes(u.type.unit)?32:64))r("ARROW_TIME",p+"/type","Time unit and bit width disagree","error");if(u.type.name==="decimal"&&u.type.precision>{32:9,64:18,128:38,256:76}[u.type.bitWidth??128])r("ARROW_DECIMAL",p+"/type","Decimal precision exceeds its bit width","error");if(u.dictionary){let m=t.root;for(let h of Dr(p+"/dictionary/id"))m=Tr(m,h);let y=m.kind==="number"?yle(m.value):void 0;if(y===void 0||y<-9223372036854775808n||y>9223372036854775807n)r("ARROW_DICTIONARY_ID",p+"/dictionary/id","Dictionary IDs must be exact signed 64-bit integers","error");if(o(u.dictionary,["id","indexType","isOrdered"],p+"/dictionary"),u.dictionary.indexType)l(p+"/dictionary/indexType/bitWidth"),o(u.dictionary.indexType,["name","bitWidth","isSigned"],p+"/dictionary/indexType")}f.forEach((m,y)=>c(m,p+"/children/"+y))}return o(s,["fields","metadata"],""),a(s.metadata??[],"/metadata"),s.fields.forEach((u,p)=>c(u,"/fields/"+p)),n}function A6e(){return new nt().register(P6e,I6e)}function hle(e){return We(e,A6e())}function R6e(e){let t=hle(e);if(!t.valid)throw new U("ARROW_DOCUMENT",JSON.stringify(t.diagnostics));let n=e.modules.find((r)=>r.id==="schema")?.elements.find((r)=>r.id==="schema")?.extensions[mle];if(!n||e.vocabularies[mle]?.version!=="0.1.0")throw new U("ARROW_PAYLOAD","Expected Arrow schema payload");return Ae(n)}function gle(e){let t=R6e(e);if(hle(e).diagnostics.some((n)=>n.code==="ARROW_REPRESENTATION"))throw new U("ARROW_EXPORT","Unknown representation fields cannot be discarded");return Be(t.root)}var j6e={exportJsonSchemaBundle:NB,exportAvroBundle:O8,exportGraphqlBundle:Q6,exportOpenapiBundle:N4,exportDeltaTable:L4,exportDeltaLog:B4,exportIcebergTable:Y4,exportDbtSemanticManifest:r9,exportDbtArtifact:d9,exportTypeSpecSources:nne,exportSmithySources:lne,exportArrowIpcCapture:pne,exportParquetCapture:Ov,exportGeneralizedRdfDataset:Ine,exportSqlServerCatalog:Mne,exportPostgresqlCatalogCapture:Jne,exportJsonSchema:kB,exportAvroSchema:N8,exportGraphqlSchema:TO,exportProtobufDescriptorSet:fF,exportSparkSchema:Nie,exportDeltaSchema:F4,exportIcebergSchema:H4,exportOpenapiDocument:k4,exportTableSpec:Rie,exportLinkmlDocument:Yie,exportOdcsDocument:use,exportJsonLdDocument:Zae,exportRdfNQuads:fC,exportOwlTurtle:rle,exportShaclTurtle:ale,exportDbtManifest:dle,exportSmithyJson:ane,exportArrowSchema:gle},F6e={"umf.delta.table":["exportDeltaTable","delta-table.json"],"umf.delta.log":["exportDeltaLog","delta-log.json"],"umf.iceberg.table":["exportIcebergTable","iceberg-table.json"],"umf.dbt.semantic":["exportDbtSemanticManifest","semantic-manifest.json"],"umf.dbt.artifact":["exportDbtArtifact","dbt-artifact.json"],"umf.typespec":["exportTypeSpecSources","typespec-sources.json"],"umf.arrow.ipc":["exportArrowIpcCapture","schema.arrow"],"umf.parquet":["exportParquetCapture","schema.parquet"],"umf.generalized-rdf":["exportGeneralizedRdfDataset","rdf-dataset.json"],"umf.sqlserver":["exportSqlServerCatalog","sqlserver-catalog.json"],"umf.postgresql.catalog":["exportPostgresqlCatalogCapture","postgresql-catalog.json"],"umf.json-schema":["exportJsonSchemaBundle","json-schema-bundle.json"],"umf.avro":["exportAvroBundle","avro-bundle.json"],"umf.graphql":["exportGraphqlBundle","graphql-bundle.json"],"umf.protobuf":["exportProtobufDescriptorSet","schema.pb"],"umf.spark":["exportSparkSchema","schema.spark.json"],"umf.delta":["exportDeltaSchema","schema.delta.json"],"umf.iceberg":["exportIcebergSchema","schema.iceberg.json"],"umf.openapi":["exportOpenapiBundle","openapi-bundle.json"],"umf.tablespec":["exportTableSpec","table.native.txt"],"umf.linkml":["exportLinkmlDocument","schema.linkml.json"],"umf.odcs":["exportOdcsDocument","contract.json"],"umf.jsonld":["exportJsonLdDocument","schema.jsonld"],"umf.rdf":["exportRdfNQuads","schema.nq"],"umf.owl":["exportOwlTurtle","schema.owl.ttl"],"umf.shacl":["exportShaclTurtle","schema.shacl.ttl"],"umf.dbt.manifest":["exportDbtManifest","manifest.json"],"umf.smithy":["exportSmithyJson","model.smithy.json"],"umf.arrow":["exportArrowSchema","schema.arrow.json"]};function ble(e){if(!e.document)return[];let t=[];for(let n of Object.keys(e.document.vocabularies)){let r=F6e[n];if(!r)continue;let i=j6e[r[0]];if(typeof i!=="function")continue;try{t.push({name:r[1],content:(()=>{let s=["umf.linkml","umf.odcs"].includes(n)?i(e.document,"json"):i(e.document);return typeof s==="string"||s instanceof Uint8Array?s:JSON.stringify(s,null,2)})()})}catch(s){t.push({name:r[1]+".export-error.txt",content:"Native recovery blocked: "+String(s instanceof Error?s.message:s)})}}return t}var vle={postgresql:"PostgreSQL DDL",sqlserver:"SQL Server DDL",delta:"Spark / Delta DDL","json-schema":"JSON Schema 2020-12",avro:"Avro schema",graphql:"GraphQL SDL",protobuf:"Protobuf proto3",openapi:"OpenAPI 3.1 schema components",spark:"Spark / Delta schema JSON"};function _le(e,t,n,r="yaml"){let i=["Schema-only scalar profile v1. Keys, relationships, constraints, defaults, descriptions and extension content are retained in the source companion, not enforced by generated output.","Integers use signed 64-bit carriers; floats use double. Decimal and timestamp values use text to avoid inventing precision or timezone semantics. No data conversion is performed. Core absent-allowed maps to target nullable/optional; native absence and null are not equivalent."],s=[];if(t.native?.columns){let y=t.native;s.push({name:y.table_name,fields:y.columns.map((h)=>{if(typeof h.nullable!=="boolean")throw Error(`${h.name}: explicit boolean nullable is required`);return{name:h.name,type:{VARCHAR:"string",TEXT:"string",CHAR:"string",BOOLEAN:"boolean",INTEGER:"integer",DECIMAL:"decimal",FLOAT:"float",DATE:"date",DATETIME:"timestamp",TIMESTAMP:"timestamp"}[h.data_type]??"unsupported",nullable:h.nullable}})})}else if(t.document){let y=t.document;for(let h of y.modules)for(let b of h.elements){if(b.kind!=="record")continue;s.push({name:String(b.name??b.id),fields:(Array.isArray(b.members)?b.members:[]).map((g)=>{let x=y.modules.find((v)=>v.id===g.module)?.elements.find((v)=>v.id===g.element);if(!x||x.kind!=="field"||x.cardinality!=="one"||!["required","absent-allowed"].includes(String(x.nullability)))throw Error(`${b.id}: unresolved, non-scalar or contextual member ${g.element}`);return{name:String(x.name??x.id),type:x.scalarType==="binary"?"bytes":String(x.scalarType),nullable:x.nullability==="absent-allowed"}})})}}if(!s.length)throw Error("This source has no scalar table or record schema.");let o=new Set;for(let y of s){if(!y.name||o.has(y.name)||!y.fields.length)throw Error("Unique, nonempty table names and fields are required.");o.add(y.name);let h=new Set;for(let b of y.fields){if(h.has(b.name)||!b.name||!["string","integer","float","decimal","boolean","date","timestamp","bytes"].includes(b.type))throw Error(`${y.name}.${b.name}: unsupported type or duplicate field`);h.add(b.name)}}let a=(y)=>{if(!/^[A-Za-z_][A-Za-z0-9_]*$/.test(y)||y.startsWith("__"))throw Error(`Target identifier is not supported: ${y}`);return y},l=(y)=>n==="sqlserver"?"["+y.replace(/]/g,"]]")+"]":'"'+y.replace(/"/g,'""')+'"',c=(y,h)=>h[y.type]??"string",u=(y)=>{let h=c(y,{integer:"string",float:"number",boolean:"boolean",bytes:"string"});return{type:y.nullable?[h,"null"]:h}},p=Object.fromEntries(s.map((y)=>[y.name,{type:"object",properties:Object.fromEntries(y.fields.map((h)=>[h.name,u(h)])),required:y.fields.filter((h)=>!h.nullable).map((h)=>h.name),additionalProperties:!1}])),d="json",f;if(["postgresql","sqlserver","delta"].includes(n)){d="sql";let y=n==="postgresql"?{string:"text",integer:"bigint",float:"double precision",boolean:"boolean",date:"date",bytes:"bytea",decimal:"text",timestamp:"text"}:n==="sqlserver"?{string:"nvarchar(max)",integer:"bigint",float:"float(53)",boolean:"bit",date:"date",bytes:"varbinary(max)",decimal:"nvarchar(max)",timestamp:"nvarchar(max)"}:{string:"STRING",integer:"BIGINT",float:"DOUBLE",boolean:"BOOLEAN",date:"DATE",bytes:"BINARY",decimal:"STRING",timestamp:"STRING"},h=n==="delta"?(b)=>"`"+b.replace(/`/g,"``")+"`":l;f=`-- UMF scalar export v1; read the companion report before use. `+s.map((b)=>`CREATE TABLE ${h(b.name)} ( ${b.fields.map((g)=>` ${h(g.name)} ${c(g,y)}${g.nullable?"":" NOT NULL"}`).join(`, `)} @@ -4388,10 +4388,10 @@ ${y.fields.map((h,b)=>` optional ${c(h,{integer:"int64",float:"double",boolean: `)} }`).join(` -`),i.push("Field numbers follow source member order; freeze them before evolving deployed messages. Presence does not enforce requiredness or distinguish explicit null.");if(["json-schema","openapi"].includes(n))i.push("Integers are decimal strings; date, timestamp, decimal and byte text formats are not constrained.");if(n==="avro")i.push("Output is an Avro union of records. Date, timestamp and decimal use unconstrained strings.");if(n==="spark")i.push("Output is a table-name map of StructTypes; select a value for a single Spark schema.");if(["json-schema","openapi"].includes(n))d=r;let m=typeof f==="string"?f:M1(f,d==="yaml"?"yaml":"json");return{filename:`schema.${d}`,content:m,report:{profile:"umf-browser-scalar-export-1",target:n,issues:i,source:{path:e.path,format:e.format,text:e.text},files:[{name:`schema.${d}`,content:m}]}}}var cE=[];function xle(){cE.forEach((e)=>URL.revokeObjectURL(e)),cE=[]}function wle(e,t,n){let r=document.createElement("details");r.className="detail-block";let i=document.createElement("summary");i.textContent="Download as…",r.append(i);let s=document.createElement("p");s.textContent="Generate scalar schemas for the whole source. Review mappings and limits before downloading. The companion bundle retains the original source.",r.append(s);let o=ble(n);if(o.length){let d=document.createElement("p");d.textContent="Native recovery uses the retained adapter payload. Download the source companion too: dependencies and unrelated metadata may be required.",r.append(d),o.push({name:"source-companion."+t.format,content:t.text})}for(let d of o){let f=document.createElement("a");f.textContent="Recover native "+d.name,f.download=d.name;let m=typeof d.content==="string"?d.content:new Uint8Array(d.content).buffer;f.href=URL.createObjectURL(new Blob([m],{type:"application/octet-stream"})),cE.push(f.href),f.className="button secondary",r.append(f)}let a=document.createElement("select");a.setAttribute("aria-label","Download target");for(let[d,f]of Object.entries(vle)){let m=document.createElement("option");m.value=d,m.textContent=f,a.append(m)}r.append(a);let l=document.createElement("select");l.setAttribute("aria-label","Schema serialization");for(let d of["yaml","json"]){let f=document.createElement("option");f.value=d,f.textContent=d.toUpperCase(),l.append(f)}r.append(l);let c=document.createElement("div");r.append(c);let u=()=>{c.replaceChildren();try{let d=_le(t,n,a.value,l.value),f=document.createElement("ul");d.report.issues.forEach((x)=>{let v=document.createElement("li");v.textContent=x,f.append(v)});let m=document.createElement("pre");m.textContent=["avro","spark"].includes(a.value)?go(d.content,{intAsBigInt:!0}).toString({collectionStyle:"block",lineWidth:0}):d.content;let y=document.createElement("label"),h=document.createElement("input");h.type="checkbox",y.append(h,document.createTextNode(" I reviewed the mappings and limitations."));let b=document.createElement("p"),g=(x,v)=>{let D=document.createElement("a");return D.textContent="Download "+x,D.download=x,D.href=URL.createObjectURL(new Blob([v],{type:"text/plain"})),cE.push(D.href),D.className="button secondary",D};if(b.append(g(d.filename,d.content),document.createTextNode(" "),g("schema-export-bundle.json",JSON.stringify(d.report,null,2))),b.hidden=!0,h.onchange=()=>b.hidden=!h.checked,["avro","spark"].includes(a.value)){let x=document.createElement("p");x.textContent="YAML preview · native download uses JSON.",c.append(x)}c.append(f,m,y,b)}catch(d){let f=document.createElement("p");f.className="callout",f.textContent="Export unavailable: "+String(d instanceof Error?d.message:d),c.append(f)}},p=()=>{l.hidden=!["json-schema","openapi"].includes(a.value),u()};a.onchange=p,l.onchange=p,p(),e.append(r)}bo();function Dle(){let e={type:"string",minLength:1};return{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:dataset-source:1.0.0",type:"object",required:["kind","data_kind"],properties:{kind:{enum:["synthetic","external"]},data_kind:{enum:["fabricated","observed","deidentified","unknown"]},description:{type:"string"},generator:{type:"object",required:["id","version"],properties:{id:e,version:{type:"string",pattern:"^[0-9]+\\.[0-9]+\\.[0-9]+$"}},additionalProperties:!0},reference:e,format:e,revision:e,checksum:{type:"object",required:["algorithm","value"],properties:{algorithm:{const:"sha256"},value:{type:"string",pattern:"^[a-f0-9]{64}$"}},additionalProperties:!0},license:{type:"object",properties:{id:e,reference:e,redistribution:{enum:["allowed","restricted","unknown"]},attribution:{type:"string"},notices:{type:"array",items:{type:"string"}}},additionalProperties:!0},provenance:{type:"object",properties:{publisher:e,retrieved_at:e,source_ids:{type:"array",items:e},transformations:{type:"array",items:e}},additionalProperties:!0}},allOf:[{if:{properties:{kind:{const:"external"}}},then:{properties:{reference:{},format:{}},required:["reference","format"]}},{if:{properties:{kind:{const:"synthetic"}}},then:{properties:{generator:{}},required:["generator"]}}],additionalProperties:!0}}function Tle(){let e={type:"string",minLength:1},t={type:"string",pattern:"^[0-9]+\\.[0-9]+\\.[0-9]+$"};return{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:domain-pack:1.0.0",type:"object",required:["id","version","domain_types"],anyOf:[{properties:{generator:{}},required:["generator"]},{properties:{sources:{}},required:["sources"]}],properties:{id:e,version:t,description:{type:"string"},generator:{type:"object",required:["id","version"],properties:{id:e,version:t},additionalProperties:!0},domain_types:{type:"object",minProperties:1,propertyNames:{type:"string",pattern:"^[A-Za-z_][A-Za-z0-9_]*$"},additionalProperties:{type:"object",properties:{description:{type:"string"},sample_generation:{type:"object",required:["method"],properties:{method:{type:"string",pattern:"^generate_[A-Za-z0-9_]+$"}},additionalProperties:!0},detection:{type:"object"}},additionalProperties:!0}},scale_presets:{type:"object",additionalProperties:{type:"object",required:["roots","children"],properties:{roots:{type:"object",additionalProperties:{type:"integer",minimum:0}},children:{type:"object",additionalProperties:{type:"object",required:["parent","per_parent"],properties:{parent:e,per_parent:{type:"number",minimum:0},distribution:{enum:["uniform","skewed"]}},additionalProperties:!0}}},additionalProperties:!0}},sources:{type:"object",minProperties:1,additionalProperties:Dle()},source_bindings:{type:"array",items:{type:"object",required:["schema_id","source_id","role"],properties:{schema_id:e,source_id:e,role:{enum:["rows","reference","terminology"]}},additionalProperties:!0}},schemas:{type:"array",items:{type:"object",required:["id","format","reference"],properties:{id:e,format:e,reference:e},additionalProperties:!0}}},additionalProperties:!0}}var F6e=mt().compile(Tle());function C6e(e){let t;try{t=Ae(e)}catch(a){return{valid:!1,complete:!1,diagnostics:[String(a)]}}let n=[];if(!F6e(Ae(t)))return{valid:!1,complete:!1,diagnostics:["Invalid canonical domain-pack metadata"]};let r=t.schemas??[],i=r.map((a)=>a.id),s=t.sources??{};if(new Set(i).size!==i.length)n.push("Duplicate schema identity");for(let a of t.source_bindings??[])if(!i.includes(a.schema_id)||!Object.hasOwn(s,a.source_id))n.push("Unresolved source binding");let o=t.execution_profile;if(Object.hasOwn(t,"execution_profile")){if(!o||typeof o!=="object"||Array.isArray(o))return{valid:!1,complete:!1,diagnostics:["Malformed execution profile"]};let a=["version","targets","mode","scales","identity_columns","include_sources","qualification"];if(typeof o!=="object"||Array.isArray(o)||Object.keys(o).some((l)=>!a.includes(l)))n.push("Unsupported execution profile fields");if(o.version!=="1.0.0")n.push("Unsupported execution profile version");if(!["fixed","scenario-replay"].includes(o.mode))n.push("Unsupported execution profile mode");if(typeof o.qualification!=="string"||!o.qualification)n.push("Missing execution qualification");if(!o.targets||typeof o.targets!=="object"||Array.isArray(o.targets)||!Object.keys(o.targets).length)n.push("Missing schema targets");else for(let[l,c]of Object.entries(o.targets)){if(!["tabular","graph"].includes(l)||!Array.isArray(c)||!c.length||new Set(c).size!==c.length){n.push("Unsupported schema target");continue}for(let u of c){let p=r.find((d)=>d.id===u);if(!p||p.format!==(l==="tabular"?"tablespec":"umf"))n.push("Target schema format or identity mismatch")}}if(!Array.isArray(o.include_sources)||new Set(o.include_sources).size!==o.include_sources.length||o.include_sources.some((l)=>!Object.hasOwn(s,l)))n.push("Unresolved source inclusion");if(o.mode==="scenario-replay"){if(!o.scales||typeof o.scales!=="object"||Array.isArray(o.scales)||!Object.keys(o.scales).length||Object.values(o.scales).some((c)=>!Number.isSafeInteger(c)||Number(c)<1||Number(c)>1e4))n.push("Invalid scenario component scales");let l=o.targets?.tabular??[];if(!o.identity_columns||typeof o.identity_columns!=="object"||Array.isArray(o.identity_columns)||Object.keys(o.identity_columns).length!==l.length||l.some((c)=>!Array.isArray(o.identity_columns[c])||!o.identity_columns[c].length||new Set(o.identity_columns[c]).size!==o.identity_columns[c].length||o.identity_columns[c].some((u)=>typeof u!=="string"||!u)))n.push("Invalid identity column mapping")}}return{valid:n.length===0,complete:n.length===0&&Boolean(o),diagnostics:n}}function Sle(e){try{return C6e(e)}catch{return{valid:!1,complete:!1,diagnostics:["Malformed execution profile"]}}}var Jc=(e,t)=>JSON.stringify([e,t]);function y_(e){let t=e.format==="json"?Jt(e.text):Wa(e.text),n=bC(t);if(!n||typeof n!=="object"||Array.isArray(n))throw Error("Expected a schema or pack object.");if(typeof n.umf!=="string"){if(n.table_name&&Array.isArray(n.columns)){let o=Aie(e.text,{id:e.id,format:e.format}),a=DS(o);return{native:n,label:`TableSpec ${n.version??"version not declared"}`,definitions:n.columns.map((l,c)=>({key:Jc("native",l.name),module:n.table_name,id:l.name,title:l.name,value:l,pointer:`/columns/${c}`})),valid:a.valid,complete:!1,diagnostics:a.diagnostics.map((l)=>`${l.code}: ${l.message}`).join(` -`)}}if(n.domain_types&&typeof n.id==="string"){let o=Sle(ms(Be(t),"json"));return{native:n,label:`Domain pack ${n.version??"version not declared"}`,definitions:Object.entries(n.domain_types).map(([a,l])=>({key:Jc("native",a),module:n.id,id:a,title:a,value:l,pointer:"/domain_types/"+a.replace(/~/g,"~0").replace(/\//g,"~1")})),valid:o.valid,complete:o.complete,diagnostics:o.diagnostics.join(` +`),i.push("Field numbers follow source member order; freeze them before evolving deployed messages. Presence does not enforce requiredness or distinguish explicit null.");if(["json-schema","openapi"].includes(n))i.push("Integers are decimal strings; date, timestamp, decimal and byte text formats are not constrained.");if(n==="avro")i.push("Output is an Avro union of records. Date, timestamp and decimal use unconstrained strings.");if(n==="spark")i.push("Output is a table-name map of StructTypes; select a value for a single Spark schema.");if(["json-schema","openapi"].includes(n))d=r;let m=typeof f==="string"?f:M1(f,d==="yaml"?"yaml":"json");return{filename:`schema.${d}`,content:m,report:{profile:"umf-browser-scalar-export-1",target:n,issues:i,source:{path:e.path,format:e.format,text:e.text},files:[{name:`schema.${d}`,content:m}]}}}var cE=[];function xle(){cE.forEach((e)=>URL.revokeObjectURL(e)),cE=[]}function wle(e,t,n){let r=document.createElement("details");r.className="detail-block";let i=document.createElement("summary");i.textContent="Download as…",r.append(i);let s=document.createElement("p");s.textContent="Generate scalar schemas for the whole source. Review mappings and limits before downloading. The companion bundle retains the original source.",r.append(s);let o=ble(n);if(o.length){let d=document.createElement("p");d.textContent="Native recovery uses the retained adapter payload. Download the source companion too: dependencies and unrelated metadata may be required.",r.append(d),o.push({name:"source-companion."+t.format,content:t.text})}for(let d of o){let f=document.createElement("a");f.textContent="Recover native "+d.name,f.download=d.name;let m=typeof d.content==="string"?d.content:new Uint8Array(d.content).buffer;f.href=URL.createObjectURL(new Blob([m],{type:"application/octet-stream"})),cE.push(f.href),f.className="button secondary",r.append(f)}let a=document.createElement("select");a.setAttribute("aria-label","Download target");for(let[d,f]of Object.entries(vle)){let m=document.createElement("option");m.value=d,m.textContent=f,a.append(m)}r.append(a);let l=document.createElement("select");l.setAttribute("aria-label","Schema serialization");for(let d of["yaml","json"]){let f=document.createElement("option");f.value=d,f.textContent=d.toUpperCase(),l.append(f)}r.append(l);let c=document.createElement("div");r.append(c);let u=()=>{c.replaceChildren();try{let d=_le(t,n,a.value,l.value),f=document.createElement("ul");d.report.issues.forEach((x)=>{let v=document.createElement("li");v.textContent=x,f.append(v)});let m=document.createElement("pre");m.textContent=["avro","spark"].includes(a.value)?go(d.content,{intAsBigInt:!0}).toString({collectionStyle:"block",lineWidth:0}):d.content;let y=document.createElement("label"),h=document.createElement("input");h.type="checkbox",y.append(h,document.createTextNode(" I reviewed the mappings and limitations."));let b=document.createElement("p"),g=(x,v)=>{let D=document.createElement("a");return D.textContent="Download "+x,D.download=x,D.href=URL.createObjectURL(new Blob([v],{type:"text/plain"})),cE.push(D.href),D.className="button secondary",D};if(b.append(g(d.filename,d.content),document.createTextNode(" "),g("schema-export-bundle.json",JSON.stringify(d.report,null,2))),b.hidden=!0,h.onchange=()=>b.hidden=!h.checked,["avro","spark"].includes(a.value)){let x=document.createElement("p");x.textContent="YAML preview · native download uses JSON.",c.append(x)}c.append(f,m,y,b)}catch(d){let f=document.createElement("p");f.className="callout",f.textContent="Export unavailable: "+String(d instanceof Error?d.message:d),c.append(f)}},p=()=>{l.hidden=!["json-schema","openapi"].includes(a.value),u()};a.onchange=p,l.onchange=p,p(),e.append(r)}bo();function Dle(){let e={type:"string",minLength:1};return{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:dataset-source:1.0.0",type:"object",required:["kind","data_kind"],properties:{kind:{enum:["synthetic","external"]},data_kind:{enum:["fabricated","observed","deidentified","unknown"]},description:{type:"string"},generator:{type:"object",required:["id","version"],properties:{id:e,version:{type:"string",pattern:"^[0-9]+\\.[0-9]+\\.[0-9]+$"}},additionalProperties:!0},reference:e,format:e,revision:e,checksum:{type:"object",required:["algorithm","value"],properties:{algorithm:{const:"sha256"},value:{type:"string",pattern:"^[a-f0-9]{64}$"}},additionalProperties:!0},license:{type:"object",properties:{id:e,reference:e,redistribution:{enum:["allowed","restricted","unknown"]},attribution:{type:"string"},notices:{type:"array",items:{type:"string"}}},additionalProperties:!0},provenance:{type:"object",properties:{publisher:e,retrieved_at:e,source_ids:{type:"array",items:e},transformations:{type:"array",items:e}},additionalProperties:!0}},allOf:[{if:{properties:{kind:{const:"external"}}},then:{properties:{reference:{},format:{}},required:["reference","format"]}},{if:{properties:{kind:{const:"synthetic"}}},then:{properties:{generator:{}},required:["generator"]}}],additionalProperties:!0}}function Tle(){let e={type:"string",minLength:1},t={type:"string",pattern:"^[0-9]+\\.[0-9]+\\.[0-9]+$"};return{$schema:"https://json-schema.org/draft/2020-12/schema",$id:"urn:umf:domain-pack:1.0.0",type:"object",required:["id","version","domain_types"],anyOf:[{properties:{generator:{}},required:["generator"]},{properties:{sources:{}},required:["sources"]}],properties:{id:e,version:t,description:{type:"string"},family:{type:"object",required:["id","version","label"],properties:{id:e,version:t,label:e},additionalProperties:!0},composition:{type:"object",required:["version","components"],properties:{version:{const:"1.0.0"},components:{type:"array",minItems:1,maxItems:32,items:{type:"object",required:["id","version","label","checksum"],properties:{id:{type:"string",pattern:"^[a-z][a-z0-9-]*$"},version:t,label:e,checksum:{type:"object",required:["algorithm","value"],properties:{algorithm:{const:"sha256"},value:{type:"string",pattern:"^[a-f0-9]{64}$"}},additionalProperties:!0}},additionalProperties:!0}}},additionalProperties:!0},generator:{type:"object",required:["id","version"],properties:{id:e,version:t},additionalProperties:!0},domain_types:{type:"object",minProperties:1,propertyNames:{type:"string",pattern:"^[A-Za-z_][A-Za-z0-9_]*$"},additionalProperties:{type:"object",properties:{description:{type:"string"},sample_generation:{type:"object",required:["method"],properties:{method:{type:"string",pattern:"^generate_[A-Za-z0-9_]+$"}},additionalProperties:!0},detection:{type:"object"}},additionalProperties:!0}},scale_presets:{type:"object",additionalProperties:{type:"object",required:["roots","children"],properties:{roots:{type:"object",additionalProperties:{type:"integer",minimum:0}},children:{type:"object",additionalProperties:{type:"object",required:["parent","per_parent"],properties:{parent:e,per_parent:{type:"number",minimum:0},distribution:{enum:["uniform","skewed"]}},additionalProperties:!0}}},additionalProperties:!0}},sources:{type:"object",minProperties:1,additionalProperties:Dle()},source_bindings:{type:"array",items:{type:"object",required:["schema_id","source_id","role"],properties:{schema_id:e,source_id:e,role:{enum:["rows","reference","terminology"]}},additionalProperties:!0}},schemas:{type:"array",items:{type:"object",required:["id","format","reference"],properties:{id:e,format:e,reference:e},additionalProperties:!0}}},additionalProperties:!0}}var C6e=mt().compile(Tle());function M6e(e){let t;try{t=Ae(e)}catch(a){return{valid:!1,complete:!1,diagnostics:[String(a)]}}let n=[];if(!C6e(Ae(t)))return{valid:!1,complete:!1,diagnostics:["Invalid canonical domain-pack metadata"]};let r=t.schemas??[],i=r.map((a)=>a.id),s=t.sources??{};if(new Set(i).size!==i.length)n.push("Duplicate schema identity");for(let a of t.source_bindings??[])if(!i.includes(a.schema_id)||!Object.hasOwn(s,a.source_id))n.push("Unresolved source binding");if(t.composition){let a=t.composition.components,l=a.map((c)=>c.id+"@"+c.version);if(new Set(l).size!==l.length||new Set(a.map((c)=>c.id)).size!==a.length)n.push("Duplicate component identity");if(a.some((c)=>c.id===t.id))n.push("Self composition is not supported")}let o=t.execution_profile;if(Object.hasOwn(t,"execution_profile")){if(!o||typeof o!=="object"||Array.isArray(o))return{valid:!1,complete:!1,diagnostics:["Malformed execution profile"]};let a=["version","targets","mode","scales","identity_columns","include_sources","qualification"];if(typeof o!=="object"||Array.isArray(o)||Object.keys(o).some((l)=>!a.includes(l)))n.push("Unsupported execution profile fields");if(o.version!=="1.0.0")n.push("Unsupported execution profile version");if(!["fixed","scenario-replay"].includes(o.mode))n.push("Unsupported execution profile mode");if(typeof o.qualification!=="string"||!o.qualification)n.push("Missing execution qualification");if(!o.targets||typeof o.targets!=="object"||Array.isArray(o.targets)||!Object.keys(o.targets).length)n.push("Missing schema targets");else for(let[l,c]of Object.entries(o.targets)){if(!["tabular","graph"].includes(l)||!Array.isArray(c)||!c.length||new Set(c).size!==c.length){n.push("Unsupported schema target");continue}for(let u of c){let p=r.find((d)=>d.id===u);if(!p||p.format!==(l==="tabular"?"tablespec":"umf"))n.push("Target schema format or identity mismatch")}}if(!Array.isArray(o.include_sources)||new Set(o.include_sources).size!==o.include_sources.length||o.include_sources.some((l)=>!Object.hasOwn(s,l)))n.push("Unresolved source inclusion");if(o.mode==="scenario-replay"){if(!o.scales||typeof o.scales!=="object"||Array.isArray(o.scales)||!Object.keys(o.scales).length||Object.values(o.scales).some((c)=>!Number.isSafeInteger(c)||Number(c)<1||Number(c)>1e4))n.push("Invalid scenario component scales");let l=o.targets?.tabular??[];if(!o.identity_columns||typeof o.identity_columns!=="object"||Array.isArray(o.identity_columns)||Object.keys(o.identity_columns).length!==l.length||l.some((c)=>!Array.isArray(o.identity_columns[c])||!o.identity_columns[c].length||new Set(o.identity_columns[c]).size!==o.identity_columns[c].length||o.identity_columns[c].some((u)=>typeof u!=="string"||!u)))n.push("Invalid identity column mapping")}}return{valid:n.length===0,complete:n.length===0&&Boolean(o),diagnostics:n}}function Sle(e){try{return M6e(e)}catch{return{valid:!1,complete:!1,diagnostics:["Malformed execution profile"]}}}var Jc=(e,t)=>JSON.stringify([e,t]);function y_(e){let t=e.format==="json"?Jt(e.text):Wa(e.text),n=bC(t);if(!n||typeof n!=="object"||Array.isArray(n))throw Error("Expected a schema or pack object.");if(typeof n.umf!=="string"){if(n.table_name&&Array.isArray(n.columns)){let o=Aie(e.text,{id:e.id,format:e.format}),a=DS(o);return{native:n,label:`TableSpec ${n.version??"version not declared"}`,definitions:n.columns.map((l,c)=>({key:Jc("native",l.name),module:n.table_name,id:l.name,title:l.name,value:l,pointer:`/columns/${c}`})),valid:a.valid,complete:!1,diagnostics:a.diagnostics.map((l)=>`${l.code}: ${l.message}`).join(` +`)}}if(n.domain_types&&typeof n.id==="string"){let o=Sle(ys(Be(t),"json"));return{native:n,label:`Domain pack ${n.version??"version not declared"}`,definitions:Object.entries(n.domain_types).map(([a,l])=>({key:Jc("native",a),module:n.id,id:a,title:a,value:l,pointer:"/domain_types/"+a.replace(/~/g,"~0").replace(/\//g,"~1")})),valid:o.valid,complete:o.complete,diagnostics:o.diagnostics.join(` `)||"Canonical metadata and declared execution profile validated. Generators, source data and graph storage never execute in this explorer."}}if(n.$schema||n.$defs||n.definitions||e.schemaFormat==="json-schema")return{native:n,label:"JSON Schema · source inspection",definitions:[],valid:!1,complete:!1,diagnostics:"Schema keywords are displayed as declared. Instance validation and reference evaluation are not performed."};throw Error("Unsupported schema shape. Supply a UMF document, domain-pack manifest, TableSpec table, or JSON Schema.")}let r=hB(e.text,e.format),i=We(r),s=r.modules.flatMap((o,a)=>o.elements.map((l,c)=>({key:Jc(o.id,l.id),module:o.id,id:l.id,title:String(l.title??l.name??l.id),value:l,pointer:`/modules/${a}/elements/${c}`})));return{document:r,definitions:s,valid:i.valid,complete:i.complete,diagnostics:i.diagnostics.map((o)=>`${o.severity.toUpperCase()} ${o.code} ${o.path}: ${o.message}`).join(` `)}}function uE(e,t){return`${e.title} ${e.path} ${e.pack??""} -${e.text}`.toLowerCase().includes(t.toLowerCase())}function bC(e){switch(e.kind){case"number":return{numberToken:e.value};case"string":case"boolean":return e.value;case"null":return null;case"array":return e.items.map(bC);case"object":return Object.fromEntries(Object.entries(e.members).map(([t,n])=>[t,bC(n)]))}}function vC(e){let t=e.definitions.filter((i)=>i.value.kind==="record"),n=e.definitions.filter((i)=>i.value.kind==="field"),r=(e.document?.modules??[]).flatMap((i)=>(Array.isArray(i.relationships)?i.relationships:[]).map((s)=>({key:JSON.stringify(["relationship",i.id,s.id]),module:i.id,value:s})));return{records:t,fields:n,edges:r}}var Tt=(e,t,n)=>{let r=document.createElement(e);if(t!==void 0)r.textContent=t;if(n)r.className=n;return r},Il=(e)=>e.replace(/_/g," ").replace(/^./,(t)=>t.toUpperCase()),Tp=(e)=>e?`${e.min}..${e.max}`:"Not declared",os=(e)=>Jc(e.module,e.element);function Ele(e,t,n,r,i){let s=vC(t),o=i.get("definition"),a=s.edges.find((I)=>I.key===i.get("relationship")),l=t.definitions.find((I)=>I.key===o),c=(I)=>"#"+new URLSearchParams({schema:n.id,...I}),u=(I,Z,pe="ref-link")=>{let de=Tt("a",I,pe);return de.href=c(Z),de},p=(I)=>{let Z=t.definitions.find((pe)=>pe.key===os(I));return Z?u(Il(Z.title),{definition:Z.key}):Tt("span",`${I.module} / ${I.element} · unresolved`,"unresolved")},d=(I)=>{let Z=Tt("section",void 0,"detail-block");return Z.append(Tt("h3",I)),e.append(Z),Z},f=(I,Z,pe)=>{let de=Tt("details",void 0,"raw-content");de.append(Tt("summary",Z),Tt("pre",Ul(pe,{aliasDuplicateObjects:!1,lineWidth:0}))),I.append(de)},m=(I,Z)=>s.edges.filter((pe)=>(pe.value[Z]??[]).some((de)=>os(de)===I.key)),y=Tt("nav",void 0,"definition-list");y.setAttribute("aria-label","Ontology views"),y.append(u("Model overview",{}));for(let I of s.records)y.append(u(Il(I.title),{definition:I.key}));e.append(y);let h=Tt("div",void 0,"stats");for(let I of[`${s.records.length} records`,`${s.fields.length} properties`,`${s.edges.length} relationships`])h.append(Tt("span",I,"tag"));e.append(h),e.append(Tt("p","UMF record and relationship model · arrows represent declared schema relationships.","ontology-caption"));let b=l?.value.kind==="record"?l:void 0;if(a){let I=d("Relationship: "+Il(String(a.value.name??a.value.id)));I.dataset.relationship=a.key;for(let Z of["source","target"]){let pe=Tt("p",Z==="source"?"Source: ":"Target: ");for(let de of a.value[Z]??[])pe.append(p(de),document.createTextNode(de.key?` · key ${de.key} `:" "));I.append(pe)}if(I.append(Tt("p",`Source participation ${Tp(a.value.sourceMultiplicity)} · Target participation ${Tp(a.value.targetMultiplicity)} · ${a.value.directed===!0?"Directed":a.value.directed===!1?"Undirected":"Direction not declared"}`)),a.value.targetLifecycle)I.append(Tt("p","Target lifecycle: "+a.value.targetLifecycle));f(I,"Original relationship",a.value)}else if(l){let I=d(Il(l.title));if(I.dataset.record=l.key,I.append(Tt("p",`${l.module} / ${l.id}`,"schema-id")),l.value.description)I.append(Tt("p",String(l.value.description)));if(b){let Z=r.find((_e)=>_e.id===`pack:${n.pack}@${n.packVersion}`),pe=Z?JSON.parse(Z.text).execution_profile?.targets:void 0,de=pe?.graph?.includes("ontology")&&r.find((_e)=>_e.id===`schema:${n.pack}@${n.packVersion}:${b.id}`&&pe.tabular?.includes(b.id));if(de){let _e=Tt("a","View corresponding table","ref-link");_e.href="#"+new URLSearchParams({schema:de.id}),I.append(_e)}let je=Tt("div",void 0,"table-wrap"),be=Tt("table",void 0,"details-table"),Ie=Tt("tr");for(let _e of["Property","Type / shape","Availability","Identity"])Ie.append(Tt("th",_e));be.append(Ie);let J=new Set((b.value.keys??[]).flatMap((_e)=>(_e.fields??[]).map(os)));for(let _e of b.value.members??[]){let ue=_e.field??_e,ce=t.definitions.find((ct)=>ct.key===os(ue)),Le=Tt("tr"),Ke=Tt("td");Ke.append(p(ue)),Le.append(Ke,Tt("td",ce?`${ce.value.scalarType??ce.value.kind??"Not declared"} / ${ce.value.cardinality??"Not declared"}`:"Unresolved"),Tt("td",String(ce?.value.nullability??"Not declared")),Tt("td",J.has(os(ue))?"Key member":"—")),be.append(Le)}if(je.append(be),I.append(je),b.value.keys)f(I,"Identity and keys",b.value.keys);for(let[_e,ue]of[["source","Outgoing relationships"],["target","Incoming relationships"]]){let ce=d(ue),Le=m(b,_e);if(!Le.length)ce.append(Tt("p","None declared."));for(let Ke of Le){let ct=Tt("p");ct.append(u(Il(String(Ke.value.name??Ke.value.id)),{relationship:Ke.key}));let lt=_e==="source"?"target":"source";ct.append(document.createTextNode(" · "));for(let se of Ke.value[lt]??[])ct.append(p(se),document.createTextNode(" "));ct.append(document.createTextNode(` · ${Tp(Ke.value.sourceMultiplicity)} → ${Tp(Ke.value.targetMultiplicity)}`)),ce.append(ct)}}}else{if(I.append(Tt("p",`Type: ${l.value.scalarType??l.value.kind??"Not declared"} · Shape: ${l.value.cardinality??"Not declared"} · Availability: ${l.value.nullability??"Not declared"}`)),l.value.facets)f(I,"Declared constraints",l.value.facets);let Z=s.records.filter((de)=>(de.value.members??[]).some((je)=>os(je.field??je)===l.key)),pe=Tt("p","Record: ");for(let de of Z)pe.append(u(Il(de.title),{definition:de.key}));I.append(pe)}f(I,"Constraints and retained metadata",l.value)}let g=d(b?"Relationship neighborhood":"Relationship map"),x=Tt("div",void 0,"definition-list"),v=Tt("select");v.setAttribute("aria-label","Focus record");let D=Tt("option","Full model");D.value="",v.append(D);for(let I of s.records){let Z=Tt("option",Il(I.title));Z.value=I.key,v.append(Z)}let T=i.get("focus")??b?.key??(a?.value.source?.[0]?os(a.value.source[0]):void 0)??s.records[0]?.key??"";v.value=T,x.append(Tt("label","Focus: "),v);let N=Tt("button","Show full model");N.type="button",x.append(N),g.append(x);let O=Tt("div",void 0,"ontology-map");g.append(O);let C=(I)=>{O.replaceChildren();let Z=s.edges.filter((se)=>[...se.value.source??[],...se.value.target??[]].some((he)=>os(he)===I)),pe=new Set([I,...Z.flatMap((se)=>[...se.value.source??[],...se.value.target??[]].map(os))]),de=I?s.records.filter((se)=>pe.has(se.key)):s.records,je=new Map(de.map((se,he)=>[se.key,{x:35+he%3*250,y:35+Math.floor(he/3)*120}])),be="http://www.w3.org/2000/svg",Ie=(se,he={})=>{let ke=document.createElementNS(be,se);for(let[Re,Ne]of Object.entries(he))ke.setAttribute(Re,Ne);return ke},J=Ie("svg",{viewBox:`0 0 780 ${Math.max(180,Math.ceil(de.length/3)*120+30)}`,role:"img","aria-label":I?"Record relationship neighborhood":"Full record relationship map"}),_e=Ie("defs"),ue=Ie("marker",{id:"ontology-arrow",viewBox:"0 0 10 10",refX:"9",refY:"5",markerWidth:"6",markerHeight:"6",orient:"auto"});ue.append(Ie("path",{d:"M 0 0 L 10 5 L 0 10 z",fill:"#526b45"})),_e.append(ue),J.append(_e);let ce=I?Z:s.edges,Le=[];for(let se of ce){if(se.value.source?.length!==1||se.value.target?.length!==1)continue;let he=!1;for(let ke of se.value.source??[])for(let Re of se.value.target??[]){let Ne=je.get(os(ke)),G=je.get(os(Re));if(!Ne||!G)continue;he=!0;let V=Ie("a",{href:c({relationship:se.key,focus:I}),tabindex:"0","aria-label":"Inspect relationship "+String(se.value.name??se.value.id)}),j=Ie("title");j.textContent=`${se.value.name??se.value.id}: ${Tp(se.value.sourceMultiplicity)} → ${Tp(se.value.targetMultiplicity)}`;let H=G.x-Ne.x,ge=G.y-Ne.y,fe=H===0&&ge===0?0:Math.min(H===0?1/0:108/Math.abs(H),ge===0?1/0:35/Math.abs(ge)),W=ge===0&&Math.abs(H)>250?88:0,ye=(Ne.x+G.x)/2+102.5,Oe=(Ne.y+G.y)/2+31+W/2,Se=Ie("path",{d:os(ke)===os(Re)?`M ${Ne.x+160} ${Ne.y} C ${Ne.x+270} ${Ne.y-35} ${Ne.x+270} ${Ne.y+95} ${Ne.x+160} ${Ne.y+60}`:`M ${Ne.x+102.5+H*fe} ${Ne.y+31+ge*fe} Q ${ye} ${(Ne.y+G.y)/2+31+W} ${G.x+102.5-H*fe} ${G.y+31-ge*fe}`,fill:"none",stroke:"#526b45","stroke-width":"3",...se.value.directed===!0?{"marker-end":"url(#ontology-arrow)"}:{}});V.append(j,Se,Ie("circle",{cx:String(ye),cy:String(Oe),r:"11",fill:"#526b45"}));let Ce=Ie("text",{x:String(ye),y:String(Oe+4),"text-anchor":"middle",fill:"white","font-size":"11"});Ce.textContent=String(ce.indexOf(se)+1),V.append(Ce),J.append(V)}if(he)Le.push(se)}for(let se of de){let he=je.get(se.key),ke=Ie("a",{href:c({definition:se.key}),tabindex:"0","aria-label":"Inspect record "+Il(se.title)});ke.append(Ie("rect",{x:String(he.x),y:String(he.y),width:"205",height:"62",rx:"8",fill:se.key===I?"#dce6cc":"#fffdf7",stroke:"#526b45","stroke-width":"2"}));let Re=Ie("text",{x:String(he.x+10),y:String(he.y+25)});Re.textContent=Il(se.title);let Ne=Ie("text",{x:String(he.x+10),y:String(he.y+47),class:"map-count"});Ne.textContent=`${(se.value.members??[]).length} properties`,ke.append(Re,Ne),J.append(ke)}O.append(J);let Ke=ce.filter((se)=>se.value.source?.length!==1||se.value.target?.length!==1);if(Ke.length)O.append(Tt("p",`${Ke.length} relationships have multiple or unspecified endpoints; inspect their full declarations in Relationships. They are not drawn as binary arrows.`));let ct=Tt("div",void 0,"map-relationships");for(let se of Le){let he=Tt("p");he.append(u(`${ce.indexOf(se)+1}. ${se.value.name??se.value.id}`,{relationship:se.key,focus:I}),document.createTextNode(` · ${Tp(se.value.sourceMultiplicity)} → ${Tp(se.value.targetMultiplicity)}`)),ct.append(he)}O.append(ct);let lt=ce.filter((se)=>[...se.value.source??[],...se.value.target??[]].some((he)=>!s.records.some((ke)=>ke.key===os(he))));if(lt.length)O.append(Tt("p",`${lt.length} relationships have endpoints outside the displayed record model; retained in the relationship list.`,"unresolved"))},X=(I)=>{let Z=new URLSearchParams(location.hash.slice(1));Z.set("focus",I),history.replaceState(null,"","#"+Z),v.value=I,C(I)};v.onchange=()=>X(v.value),N.onclick=()=>X(""),C(T);let te=d("Relationships");for(let I of s.edges){let Z=Tt("p");Z.append(u(String(I.value.name??I.value.id),{relationship:I.key})),te.append(Z)}if(!s.edges.length)te.append(Tt("p","None declared."));let L=d("Records and properties");for(let I of s.records){let Z=Tt("details");Z.append(Tt("summary",Il(I.title)),u("Open record",{definition:I.key}));for(let pe of I.value.members??[]){let de=Tt("p");de.append(p(pe.field??pe)),Z.append(de)}L.append(Z)}let Y=t.definitions.filter((I)=>I.value.kind!=="record"&&I.value.kind!=="field");if(Y.length){let I=d("Other definitions");for(let Z of Y)I.append(u(Z.title,{definition:Z.key}))}let me=s.fields.filter((I)=>!s.records.some((Z)=>(Z.value.members??[]).some((pe)=>os(pe.field??pe)===I.key)));if(me.length){let I=d("Properties without declared record membership");for(let Z of me)I.append(u(Z.title,{definition:Z.key}))}f(d("Retained source metadata"),"Original document",t.document)}var Sf=(e)=>document.getElementById(e),Sp=Sf("catalog"),pn=Sf("inspector"),fE=Sf("status"),dE,Jr=[],Nt,pr,xn,xC=Sf("search"),Tf=Sf("category");function $e(e,t,n){let r=document.createElement(e);if(t!==void 0)r.textContent=t;if(n)r.className=n;return r}function oh(e){return Ul(e,{aliasDuplicateObjects:!1,lineWidth:0}).trimEnd()}function vi(e,t,n,r=!1){let i=$e("details",void 0,"raw-content");i.open=r,i.append($e("summary",t),$e("pre",typeof n==="string"?n:oh(n))),e.append(i)}function mE(){let e=Nt;vi(pn,"Schema · YAML",go(e.text,{intAsBigInt:!0}).toString({collectionStyle:"block",lineWidth:0})),vi(pn,"Original schema source",e.text)}function uo(e){let t=$e("section",void 0,"detail-block");return t.append($e("h3",e)),pn.append(t),t}function $le(e,t){location.hash=new URLSearchParams({schema:e.id,...t?{definition:t.key}:{}}).toString()}function yE(e){if(!e||typeof e!=="object")return $e("span",oh(e));let t=e,n=pr?.definitions.find((i)=>i.key===Jc(String(t.module),String(t.element)));if(!n)return $e("span",`${String(t.module)} / ${String(t.element)} · unresolved`,"unresolved");let r=$e("a",n.title,"ref-link");return r.href="#"+new URLSearchParams({schema:Nt.id,definition:n.key}),r}function h_(e,t,n){let r=$e("dl",void 0,"schema-properties");for(let[i,s]of Object.entries(t)){if(n.includes(i))continue;let o=$e("div");o.append($e("dt",i),$e("dd",typeof s==="string"?s:oh(s))),r.append(o)}if(r.children.length)e.append(r)}function M6e(e,t){for(let n of["itemType","valueType"])if(t[n]){let r=$e("p",n+": ");r.append(yE(t[n])),e.append(r)}for(let n of Array.isArray(t.references)?t.references:[]){let r=$e("p",`${String(n.role)}: `);r.append(yE(n)),e.append(r)}}var kle=new Map,Nle=new Map;function ih(e){return Jr.find((t)=>t.id.startsWith("pack:")&&t.pack===e.pack&&t.packVersion===e.packVersion)}function Ile(e){let t=kle.get(e.id);if(!t)t=y_(e),kle.set(e.id,t);return t}function Df(e){return e.replace(/_/g," ").replace(/^./,(t)=>t.toUpperCase())}function L6e(e,t,n=t.title){let r=$e("a",n,"ref-link");return r.href="#"+new URLSearchParams({schema:e.id,definition:t.key}),r}function pE(e,t){let n=$e("button",t?.title??(e.id.startsWith("pack:")?"Overview":e.title),"catalog-item");if(n.setAttribute("type","button"),e===Nt&&(!t?!xn:t.key===xn?.key))n.setAttribute("aria-current","true");return n.append($e("small",t?"Domain type":e.id.startsWith("pack:")?"Pack overview":e.path)),n.onclick=()=>$le(e,t),n}function _C(e,t,n,r=!1){let i=$e("details",void 0,"catalog-group");return i.open=r||(Nle.get(n)??(!n.endsWith(":types")&&!Jr.some((s)=>s.id===n&&s.id.startsWith("pack:")))),i.append($e("summary",t)),i.addEventListener("toggle",()=>Nle.set(n,i.open)),e.append(i),i}function g_(){Sp.replaceChildren();let e=xC.value.trim(),t=(o)=>(Tf.value==="all"||o.category===Tf.value)&&uE(o,e),n=0,r=Jr.filter((o)=>o.id.startsWith("pack:"));if(Tf.value==="all"||Tf.value==="domain"){let o=$e("section",void 0,"catalog-section");o.append($e("h3","Domain packs"));for(let a of r){let l=Jr.filter((m)=>!m.id.startsWith("pack:")&&ih(m)===a),c=uE(a,e),u=l.filter((m)=>c||uE(m,e)),p=Ile(a).definitions.filter((m)=>!e||`${m.title} ${oh(m.value)}`.toLowerCase().includes(e.toLowerCase()));if(!c&&!u.length&&!p.length)continue;let d=Nt&&ih(Nt)===a,f=_C(o,`${Df(a.title)} · ${a.packVersion??"version not declared"}`,a.id,!!d||!!e);f.dataset.pack=a.id,f.append(pE(a)),n++;for(let[m,y]of[["Tables",u.filter((h)=>h.schemaFormat==="tablespec")],["Ontology",u.filter((h)=>h.schemaFormat==="umf")],["Other schemas",u.filter((h)=>h.schemaFormat!=="umf"&&h.schemaFormat!=="tablespec")]])if(y.length){let h=_C(f,m,a.id+":"+m,!!d||!!e);for(let b of y)h.append(pE(b)),n++}if(p.length){let m=_C(f,"Domain types",a.id+":types",Nt===a&&!!xn||!!e);for(let y of p)m.append(pE(a,y)),n++}}if(o.querySelector("details"))Sp.append(o)}for(let[o,a]of[["Examples",(l)=>l.category==="example"],["Local files",(l)=>l.category==="local"],["Other schemas",(l)=>l.category==="domain"&&!ih(l)]]){let l=Jr.filter((u)=>a(u)&&t(u));if(!l.length)continue;let c=$e("section",void 0,"catalog-section");c.append($e("h3",o));for(let u of l)c.append(pE(u)),n++;Sp.append(c)}if(Sf("count").textContent=String(n),!n)Sp.append($e("p",Tf.value==="domain"&&!r.length?"Domain packs have not been added to this catalog yet. Open a local schema to inspect it.":"No matching schemas. Try another search.","catalog-empty"));let i=Sp.querySelector('[aria-current="true"]'),s=matchMedia("(max-width:850px)").matches?Sp:Sp.closest("aside");if(i&&s){let o=i.getBoundingClientRect(),a=s.getBoundingClientRect();if(o.topa.bottom)s.scrollTop+=o.top-a.top-40}}function q6e(){if(!Nt)return;let e=$e("nav",void 0,"breadcrumbs");e.setAttribute("aria-label","Breadcrumb");let t=ih(Nt);function n(i){if(e.children.length)e.append($e("span","›"));e.append(i)}if(t){if(n(sh(t.id,`${Df(t.title)} · ${t.packVersion}`)),Nt===t){if(n($e("span",xn?"Domain types":"Overview")),xn)n($e("span",Df(xn.title)))}else if(n($e("span",Nt.schemaFormat==="umf"?"Ontology":"Tables")),n(sh(Nt.id,Df(Nt.title))),xn)n($e("span",Df(xn.title)))}else if(n($e("span",Nt.category==="example"?"Examples":Nt.category==="local"?"Local files":"Schemas")),n(sh(Nt.id,Df(Nt.title))),xn)n($e("span",Df(xn.title)));let r=e.lastElementChild;if(r)r.setAttribute("aria-current","page");pn.append(e)}function Ole(e){let t=Nt&&ih(Nt),n=t&&Ile(t).definitions.find((r)=>r.id===e);return t&&n?L6e(t,n):$e("span",`${e} · not declared in this pack`,"unresolved")}function U6e(){if(xle(),dE)URL.revokeObjectURL(dE);if(pn.replaceChildren(),!Nt||!pr)return;if(q6e(),wle(pn,Nt,pr),pr.native){B6e();return}let e=pr.document,t=$e("div",void 0,"detail-top"),n=$e("div");n.append($e("span",Nt.category==="domain"?"Domain pack":"Example","tag"),$e("h2",Nt.title),$e("p",e.id,"schema-id")),t.append(n);let r=$e("a","Download source","button secondary");r.href=dE=URL.createObjectURL(new Blob([Nt.text],{type:"text/plain"})),r.download=Nt.path.split("/").pop()??"schema.json",r.onclick=()=>setTimeout(()=>URL.revokeObjectURL(r.href),1000),t.append(r),pn.append(t);let i=$e("div",void 0,"stats");for(let l of[`UMF ${e.umf}`,`${e.modules.length} modules`,`${pr.definitions.length} definitions`])i.append($e("span",l,"tag"));if(pn.append(i),pn.append($e("p",`Source: ${Nt.path}`,"schema-id")),Nt.description)pn.append($e("p",Nt.description));let s=$e("div",`${pr.valid?"Core structure valid":"Core structure invalid"} · ${pr.complete?"All supplied content checked":"Some semantics are not interpreted"}. Inspection does not establish storage or runtime enforcement.`,"callout");if(pn.append(s),pr.diagnostics)vi(pn,"Validation and interpretation messages",pr.diagnostics);if((Nt.schemaFormat==="umf"||String(e.title??"").includes("ontology"))&&vC(pr).records.length){Ele(pn,pr,Nt,Jr,new URLSearchParams(location.hash.slice(1))),mE();return}let o=$e("div",void 0,"definition-list"),a=$e("a","Overview");if(a.href="#"+new URLSearchParams({schema:Nt.id}),!xn)a.setAttribute("aria-current","true");o.append(a);for(let l of pr.definitions){let c=$e("a",l.title);if(c.href="#"+new URLSearchParams({schema:Nt.id,definition:l.key}),c.title=`${l.module} / ${l.id}`,l===xn)c.setAttribute("aria-current","true");o.append(c)}if(pn.append(o),xn){let l=xn.value;if(pn.append($e("h3",xn.title,"definition-heading"),$e("p",`${xn.module} / ${xn.id} · ${xn.pointer}`,"schema-id")),l.description)pn.append($e("p",String(l.description)));if(h_(pn,l,["id","name","title","description","extensions","references","members","keys","itemType","valueType"]),M6e(pn,l),Array.isArray(l.members)){let u=uo("Fields and members"),p=$e("div",void 0,"table-wrap"),d=$e("table",void 0,"details-table"),f=$e("tr");for(let m of["Definition","Type / shape","Availability"])f.append($e("th",m));d.append(f);for(let m of l.members){let y=m.field??m,h=pr.definitions.find((x)=>x.key===Jc(String(y.module),String(y.element))),b=$e("tr"),g=$e("td");if(g.append(yE(y)),h?.value.description)g.append($e("p",String(h.value.description),"field-description"));b.append(g,$e("td",h?`${h.value.scalarType??h.value.kind??"Not declared"} · ${h.value.cardinality??"shape unspecified"}`:"Unresolved"),$e("td",String(h?.value.nullability??"Not declared"))),d.append(b)}p.append(d),u.append(p),vi(u,"Original member declarations",l.members)}if(l.keys)vi(uo("Keys"),"Declared keys",l.keys,!0);let c=e.modules.flatMap((u)=>Array.isArray(u.relationships)?u.relationships:[]).filter((u)=>[...u.source??[],...u.target??[]].some((p)=>Jc(p.module,p.element)===xn.key));if(c.length)Ple(c);if(l.extensions)vi(uo("Extensions · retained payloads"),"Inspect extension content",l.extensions,!0);vi(pn,"Original definition",l)}else{for(let l of e.modules){let c=uo(String(l.title??l.namespace??l.id));if(c.append($e("p",`${l.id} · ${l.elements.length} definitions`,"schema-id")),l.extensions)vi(c,"Module extensions",l.extensions);if(Array.isArray(l.relationships)&&l.relationships.length)Ple(l.relationships)}if(vi(uo("Declared vocabularies"),"Versions and declarations",e.vocabularies,!0),e.extensions)vi(pn,"Document extensions",e.extensions)}mE()}function Ple(e){let t=uo("Relationships");for(let n of e){let r=$e("details");r.append($e("summary",String(n.name??n.id)));for(let i of["source","target"]){let s=$e("p",i+": ");for(let o of n[i]??[])s.append(yE(o),document.createTextNode(" "));r.append(s)}h_(r,n,["source","target"]),t.append(r)}}function sh(e,t){let n=$e("a",t,"ref-link");return n.href="#"+new URLSearchParams({schema:e}),n}function B6e(){let e=pr.native,t=$e("div",void 0,"detail-top");if(t.append($e("h2",Nt.title)),pn.append(t,$e("p",`${pr.label} · ${Nt.path}`,"schema-id")),e.description)pn.append($e("p",String(e.description)));pn.append($e("p",pr.diagnostics||"Source metadata inspection; native execution semantics are not certified.","callout"));let n=$e("div",void 0,"definition-list"),r=sh(Nt.id,"Overview");n.append(r);for(let s of pr.definitions){let o=$e("a",s.title);if(o.href="#"+new URLSearchParams({schema:Nt.id,definition:s.key}),s===xn)o.setAttribute("aria-current","true");n.append(o)}if(pn.append(n),xn){let s=uo(xn.title);if(s.append($e("p",xn.pointer,"schema-id")),xn.value.description)s.append($e("p",String(xn.value.description)));if(h_(s,xn.value,["description","domain_type"]),typeof xn.value.domain_type==="string"){let o=$e("p","Domain type: ");o.append(Ole(xn.value.domain_type)),s.append(o)}vi(s,"Original definition metadata",xn.value,!0),mE();return}if(e.domain_types){h_(pn,e,["domain_types","schemas","description","scale_presets","source_bindings","sources"]);for(let[a,l]of[["scale_presets","Scale presets"],["source_bindings","Source bindings"],["sources","Source declarations"]])if(e[a])vi(pn,l,e[a]);let s=uo("Schemas in this pack");for(let a of e.schemas??[]){let l=Jr.find((u)=>u.pack===e.id&&u.packVersion===Nt.packVersion&&u.path===a.reference),c=$e("p");c.append(l?sh(l.id,String(a.id)):$e("span",`${a.id} · ${a.reference} · not bundled`,"unresolved")),c.append($e("span",` · ${a.format}`,"quiet")),s.append(c)}if(!e.schemas?.length)s.append($e("p","No schema references declared."));let o=uo("Domain types");for(let[a,l]of Object.entries(e.domain_types)){let c=$e("details");c.append($e("summary",a),$e("pre",oh(l))),o.append(c)}}else if(Array.isArray(e.columns)){let s=ih(Nt),o=s?JSON.parse(s.text).execution_profile?.targets:void 0,a=o?.graph?.includes("ontology")&&Jr.find((d)=>d.id===`schema:${Nt.pack}@${Nt.packVersion}:ontology`);if(a&&o.tabular?.includes(e.table_name)){let d=y_(a).definitions.find((f)=>f.id===e.table_name&&f.value.kind==="record");if(d){let f=$e("a","View ontology record","ref-link");f.href="#"+new URLSearchParams({schema:a.id,definition:d.key}),pn.append(f)}}let l=uo("Columns"),c=$e("div",void 0,"table-wrap"),u=$e("table",void 0,"details-table"),p=$e("tr");for(let d of["Column","Native type","Nullable","Domain type"])p.append($e("th",d));u.append(p);for(let d of e.columns){let f=$e("tr"),m=$e("td",d.name);if(d.description)m.append($e("p",d.description,"field-description"));f.append(m,$e("td",d.data_type),$e("td",d.nullable===void 0?"Not declared":String(d.nullable)),(()=>{let y=$e("td");return y.append(d.domain_type?Ole(d.domain_type):$e("span","—")),y})()),u.append(f)}if(c.append(u),l.append(c),vi(l,"All column metadata",e.columns),e.primary_key)vi(uo("Primary key"),"Declared columns",e.primary_key,!0);if(e.relationships){let d=uo("Native relationships");for(let f of e.relationships.foreign_keys??[]){let m=Jr.find((h)=>h.pack===Nt.pack&&h.packVersion===Nt.packVersion&&h.title===f.references_table),y=$e("p",`${f.column} → `);y.append(m?sh(m.id,`${f.references_table}.${f.references_column}`):$e("span",`${f.references_table}.${f.references_column} · not bundled`,"unresolved")),d.append(y)}vi(d,"Original relationship metadata",e.relationships)}h_(pn,e,["columns","relationships","primary_key","description","table_name"])}else{let s=e.$defs??e.definitions??{},o=uo("Definitions");for(let[a,l]of Object.entries(s)){let c=$e("details");c.append($e("summary",a),$e("pre",oh(l))),o.append(c)}vi(pn,"Schema keywords",e,!0)}mE();let i=$e("a","Download source","button secondary");i.href=dE=URL.createObjectURL(new Blob([Nt.text],{type:"text/plain"})),i.download=Nt.path.split("/").pop()??"schema.json",i.onclick=()=>setTimeout(()=>URL.revokeObjectURL(i.href),1000),pn.append(i)}function Ale(){let e=new URLSearchParams(location.hash.slice(1)),t=e.get("schema"),n=Jr.find((r)=>r.id===t)??Jr.find((r)=>r.aliases?.includes(t??""))??(!t?Jr[0]:void 0);if(n&&t&&n.id!==t)e.set("schema",n.id),history.replaceState(null,"","#"+e);if(!n){Nt=void 0,pr=void 0,pn.replaceChildren($e("p","This schema is not in the catalog. Choose a schema from the catalog.","empty")),g_();return}try{Nt=n,pr=y_(n),xn=pr.definitions.find((r)=>r.key===e.get("definition")),U6e(),g_(),fE.textContent=e.get("definition")&&!xn?"Definition not found; showing the schema overview.":[`${Jr.filter((r)=>r.id.startsWith("pack:")).length} domain pack${Jr.filter((r)=>r.id.startsWith("pack:")).length===1?"":"s"}`,`${Jr.filter((r)=>r.category==="domain"&&!r.id.startsWith("pack:")).length} domain schemas`,`${Jr.filter((r)=>r.category==="example").length} example${Jr.filter((r)=>r.category==="example").length===1?"":"s"}`].join(" · ")}catch(r){pr=void 0,pn.replaceChildren($e("p","This schema could not be opened.","empty"),$e("pre",String(r))),g_(),fE.textContent="Schema inspection refused; original source remains available.",vi(pn,"Original schema source",n.text)}}xC.oninput=g_;Tf.onchange=g_;window.addEventListener("hashchange",Ale);Sf("file").onchange=async(e)=>{let t=e.target,n=t.files?.[0];if(!n)return;try{if(n.size>4000000)throw Error("Schema exceeds the 4 MB local-file limit.");let r={id:`local:${n.name}:${Date.now()}`,title:n.name,category:"local",path:n.name,text:await n.text(),format:/\.ya?ml$/i.test(n.name)?"yaml":"json"};y_(r),Jr.push(r),Tf.value="all",xC.value="",$le(r)}catch(r){fE.textContent=`Could not open local schema: ${String(r)}`}finally{t.value=""}};try{let e=await fetch("schema-catalog.json");if(!e.ok)throw Error(`Catalog unavailable (${e.status})`);Jr=(await e.json()).entries,Ale()}catch(e){fE.textContent=String(e),Sp.append($e("p","Open a local schema to start exploring.","empty"))} +${e.text}`.toLowerCase().includes(t.toLowerCase())}function bC(e){switch(e.kind){case"number":return{numberToken:e.value};case"string":case"boolean":return e.value;case"null":return null;case"array":return e.items.map(bC);case"object":return Object.fromEntries(Object.entries(e.members).map(([t,n])=>[t,bC(n)]))}}function vC(e){let t=e.definitions.filter((i)=>i.value.kind==="record"),n=e.definitions.filter((i)=>i.value.kind==="field"),r=(e.document?.modules??[]).flatMap((i)=>(Array.isArray(i.relationships)?i.relationships:[]).map((s)=>({key:JSON.stringify(["relationship",i.id,s.id]),module:i.id,value:s})));return{records:t,fields:n,edges:r}}var St=(e,t,n)=>{let r=document.createElement(e);if(t!==void 0)r.textContent=t;if(n)r.className=n;return r},Il=(e)=>e.replace(/_/g," ").replace(/^./,(t)=>t.toUpperCase()),Sp=(e)=>e?`${e.min}..${e.max}`:"Not declared",as=(e)=>Jc(e.module,e.element);function Ele(e,t,n,r,i){let s=vC(t),o=i.get("definition"),a=s.edges.find((I)=>I.key===i.get("relationship")),l=t.definitions.find((I)=>I.key===o),c=(I)=>"#"+new URLSearchParams({schema:n.id,...I}),u=(I,Z,pe="ref-link")=>{let de=St("a",I,pe);return de.href=c(Z),de},p=(I)=>{let Z=t.definitions.find((pe)=>pe.key===as(I));return Z?u(Il(Z.title),{definition:Z.key}):St("span",`${I.module} / ${I.element} · unresolved`,"unresolved")},d=(I)=>{let Z=St("section",void 0,"detail-block");return Z.append(St("h3",I)),e.append(Z),Z},f=(I,Z,pe)=>{let de=St("details",void 0,"raw-content");de.append(St("summary",Z),St("pre",Ul(pe,{aliasDuplicateObjects:!1,lineWidth:0}))),I.append(de)},m=(I,Z)=>s.edges.filter((pe)=>(pe.value[Z]??[]).some((de)=>as(de)===I.key)),y=St("nav",void 0,"definition-list");y.setAttribute("aria-label","Ontology views"),y.append(u("Model overview",{}));for(let I of s.records)y.append(u(Il(I.title),{definition:I.key}));e.append(y);let h=St("div",void 0,"stats");for(let I of[`${s.records.length} records`,`${s.fields.length} properties`,`${s.edges.length} relationships`])h.append(St("span",I,"tag"));e.append(h),e.append(St("p","UMF record and relationship model · arrows represent declared schema relationships.","ontology-caption"));let b=l?.value.kind==="record"?l:void 0;if(a){let I=d("Relationship: "+Il(String(a.value.name??a.value.id)));I.dataset.relationship=a.key;for(let Z of["source","target"]){let pe=St("p",Z==="source"?"Source: ":"Target: ");for(let de of a.value[Z]??[])pe.append(p(de),document.createTextNode(de.key?` · key ${de.key} `:" "));I.append(pe)}if(I.append(St("p",`Source participation ${Sp(a.value.sourceMultiplicity)} · Target participation ${Sp(a.value.targetMultiplicity)} · ${a.value.directed===!0?"Directed":a.value.directed===!1?"Undirected":"Direction not declared"}`)),a.value.targetLifecycle)I.append(St("p","Target lifecycle: "+a.value.targetLifecycle));f(I,"Original relationship",a.value)}else if(l){let I=d(Il(l.title));if(I.dataset.record=l.key,I.append(St("p",`${l.module} / ${l.id}`,"schema-id")),l.value.description)I.append(St("p",String(l.value.description)));if(b){let Z=r.find((_e)=>_e.id===`pack:${n.pack}@${n.packVersion}`),pe=Z?JSON.parse(Z.text).execution_profile?.targets:void 0,de=pe?.graph?.includes("ontology")&&r.find((_e)=>_e.id===`schema:${n.pack}@${n.packVersion}:${b.id}`&&pe.tabular?.includes(b.id));if(de){let _e=St("a","View corresponding table","ref-link");_e.href="#"+new URLSearchParams({schema:de.id}),I.append(_e)}let je=St("div",void 0,"table-wrap"),be=St("table",void 0,"details-table"),Ie=St("tr");for(let _e of["Property","Type / shape","Availability","Identity"])Ie.append(St("th",_e));be.append(Ie);let J=new Set((b.value.keys??[]).flatMap((_e)=>(_e.fields??[]).map(as)));for(let _e of b.value.members??[]){let ue=_e.field??_e,ce=t.definitions.find((ct)=>ct.key===as(ue)),Le=St("tr"),Ke=St("td");Ke.append(p(ue)),Le.append(Ke,St("td",ce?`${ce.value.scalarType??ce.value.kind??"Not declared"} / ${ce.value.cardinality??"Not declared"}`:"Unresolved"),St("td",String(ce?.value.nullability??"Not declared")),St("td",J.has(as(ue))?"Key member":"—")),be.append(Le)}if(je.append(be),I.append(je),b.value.keys)f(I,"Identity and keys",b.value.keys);for(let[_e,ue]of[["source","Outgoing relationships"],["target","Incoming relationships"]]){let ce=d(ue),Le=m(b,_e);if(!Le.length)ce.append(St("p","None declared."));for(let Ke of Le){let ct=St("p");ct.append(u(Il(String(Ke.value.name??Ke.value.id)),{relationship:Ke.key}));let lt=_e==="source"?"target":"source";ct.append(document.createTextNode(" · "));for(let se of Ke.value[lt]??[])ct.append(p(se),document.createTextNode(" "));ct.append(document.createTextNode(` · ${Sp(Ke.value.sourceMultiplicity)} → ${Sp(Ke.value.targetMultiplicity)}`)),ce.append(ct)}}}else{if(I.append(St("p",`Type: ${l.value.scalarType??l.value.kind??"Not declared"} · Shape: ${l.value.cardinality??"Not declared"} · Availability: ${l.value.nullability??"Not declared"}`)),l.value.facets)f(I,"Declared constraints",l.value.facets);let Z=s.records.filter((de)=>(de.value.members??[]).some((je)=>as(je.field??je)===l.key)),pe=St("p","Record: ");for(let de of Z)pe.append(u(Il(de.title),{definition:de.key}));I.append(pe)}f(I,"Constraints and retained metadata",l.value)}let g=d(b?"Relationship neighborhood":"Relationship map"),x=St("div",void 0,"definition-list"),v=St("select");v.setAttribute("aria-label","Focus record");let D=St("option","Full model");D.value="",v.append(D);for(let I of s.records){let Z=St("option",Il(I.title));Z.value=I.key,v.append(Z)}let T=i.get("focus")??b?.key??(a?.value.source?.[0]?as(a.value.source[0]):void 0)??s.records[0]?.key??"";v.value=T,x.append(St("label","Focus: "),v);let N=St("button","Show full model");N.type="button",x.append(N),g.append(x);let O=St("div",void 0,"ontology-map");g.append(O);let C=(I)=>{O.replaceChildren();let Z=s.edges.filter((se)=>[...se.value.source??[],...se.value.target??[]].some((he)=>as(he)===I)),pe=new Set([I,...Z.flatMap((se)=>[...se.value.source??[],...se.value.target??[]].map(as))]),de=I?s.records.filter((se)=>pe.has(se.key)):s.records,je=new Map(de.map((se,he)=>[se.key,{x:35+he%3*250,y:35+Math.floor(he/3)*120}])),be="http://www.w3.org/2000/svg",Ie=(se,he={})=>{let Ne=document.createElementNS(be,se);for(let[Re,Oe]of Object.entries(he))Ne.setAttribute(Re,Oe);return Ne},J=Ie("svg",{viewBox:`0 0 780 ${Math.max(180,Math.ceil(de.length/3)*120+30)}`,role:"img","aria-label":I?"Record relationship neighborhood":"Full record relationship map"}),_e=Ie("defs"),ue=Ie("marker",{id:"ontology-arrow",viewBox:"0 0 10 10",refX:"9",refY:"5",markerWidth:"6",markerHeight:"6",orient:"auto"});ue.append(Ie("path",{d:"M 0 0 L 10 5 L 0 10 z",fill:"#526b45"})),_e.append(ue),J.append(_e);let ce=I?Z:s.edges,Le=[];for(let se of ce){if(se.value.source?.length!==1||se.value.target?.length!==1)continue;let he=!1;for(let Ne of se.value.source??[])for(let Re of se.value.target??[]){let Oe=je.get(as(Ne)),G=je.get(as(Re));if(!Oe||!G)continue;he=!0;let V=Ie("a",{href:c({relationship:se.key,focus:I}),tabindex:"0","aria-label":"Inspect relationship "+String(se.value.name??se.value.id)}),j=Ie("title");j.textContent=`${se.value.name??se.value.id}: ${Sp(se.value.sourceMultiplicity)} → ${Sp(se.value.targetMultiplicity)}`;let H=G.x-Oe.x,ge=G.y-Oe.y,fe=H===0&&ge===0?0:Math.min(H===0?1/0:108/Math.abs(H),ge===0?1/0:35/Math.abs(ge)),W=ge===0&&Math.abs(H)>250?88:0,ye=(Oe.x+G.x)/2+102.5,Pe=(Oe.y+G.y)/2+31+W/2,Se=Ie("path",{d:as(Ne)===as(Re)?`M ${Oe.x+160} ${Oe.y} C ${Oe.x+270} ${Oe.y-35} ${Oe.x+270} ${Oe.y+95} ${Oe.x+160} ${Oe.y+60}`:`M ${Oe.x+102.5+H*fe} ${Oe.y+31+ge*fe} Q ${ye} ${(Oe.y+G.y)/2+31+W} ${G.x+102.5-H*fe} ${G.y+31-ge*fe}`,fill:"none",stroke:"#526b45","stroke-width":"3",...se.value.directed===!0?{"marker-end":"url(#ontology-arrow)"}:{}});V.append(j,Se,Ie("circle",{cx:String(ye),cy:String(Pe),r:"11",fill:"#526b45"}));let Ce=Ie("text",{x:String(ye),y:String(Pe+4),"text-anchor":"middle",fill:"white","font-size":"11"});Ce.textContent=String(ce.indexOf(se)+1),V.append(Ce),J.append(V)}if(he)Le.push(se)}for(let se of de){let he=je.get(se.key),Ne=Ie("a",{href:c({definition:se.key}),tabindex:"0","aria-label":"Inspect record "+Il(se.title)});Ne.append(Ie("rect",{x:String(he.x),y:String(he.y),width:"205",height:"62",rx:"8",fill:se.key===I?"#dce6cc":"#fffdf7",stroke:"#526b45","stroke-width":"2"}));let Re=Ie("text",{x:String(he.x+10),y:String(he.y+25)});Re.textContent=Il(se.title);let Oe=Ie("text",{x:String(he.x+10),y:String(he.y+47),class:"map-count"});Oe.textContent=`${(se.value.members??[]).length} properties`,Ne.append(Re,Oe),J.append(Ne)}O.append(J);let Ke=ce.filter((se)=>se.value.source?.length!==1||se.value.target?.length!==1);if(Ke.length)O.append(St("p",`${Ke.length} relationships have multiple or unspecified endpoints; inspect their full declarations in Relationships. They are not drawn as binary arrows.`));let ct=St("div",void 0,"map-relationships");for(let se of Le){let he=St("p");he.append(u(`${ce.indexOf(se)+1}. ${se.value.name??se.value.id}`,{relationship:se.key,focus:I}),document.createTextNode(` · ${Sp(se.value.sourceMultiplicity)} → ${Sp(se.value.targetMultiplicity)}`)),ct.append(he)}O.append(ct);let lt=ce.filter((se)=>[...se.value.source??[],...se.value.target??[]].some((he)=>!s.records.some((Ne)=>Ne.key===as(he))));if(lt.length)O.append(St("p",`${lt.length} relationships have endpoints outside the displayed record model; retained in the relationship list.`,"unresolved"))},X=(I)=>{let Z=new URLSearchParams(location.hash.slice(1));Z.set("focus",I),history.replaceState(null,"","#"+Z),v.value=I,C(I)};v.onchange=()=>X(v.value),N.onclick=()=>X(""),C(T);let te=d("Relationships");for(let I of s.edges){let Z=St("p");Z.append(u(String(I.value.name??I.value.id),{relationship:I.key})),te.append(Z)}if(!s.edges.length)te.append(St("p","None declared."));let L=d("Records and properties");for(let I of s.records){let Z=St("details");Z.append(St("summary",Il(I.title)),u("Open record",{definition:I.key}));for(let pe of I.value.members??[]){let de=St("p");de.append(p(pe.field??pe)),Z.append(de)}L.append(Z)}let Y=t.definitions.filter((I)=>I.value.kind!=="record"&&I.value.kind!=="field");if(Y.length){let I=d("Other definitions");for(let Z of Y)I.append(u(Z.title,{definition:Z.key}))}let me=s.fields.filter((I)=>!s.records.some((Z)=>(Z.value.members??[]).some((pe)=>as(pe.field??pe)===I.key)));if(me.length){let I=d("Properties without declared record membership");for(let Z of me)I.append(u(Z.title,{definition:Z.key}))}f(d("Retained source metadata"),"Original document",t.document)}var kf=(e)=>document.getElementById(e),Ep=kf("catalog"),pn=kf("inspector"),fE=kf("status"),dE,vr=[],yt,pr,xn,xC=kf("search"),Ef=kf("category");function ke(e,t,n){let r=document.createElement(e);if(t!==void 0)r.textContent=t;if(n)r.className=n;return r}function oh(e){return Ul(e,{aliasDuplicateObjects:!1,lineWidth:0}).trimEnd()}function Gr(e,t,n,r=!1){let i=ke("details",void 0,"raw-content");i.open=r,i.append(ke("summary",t),ke("pre",typeof n==="string"?n:oh(n))),e.append(i)}function mE(){let e=yt;Gr(pn,"Schema · YAML",go(e.text,{intAsBigInt:!0}).toString({collectionStyle:"block",lineWidth:0})),Gr(pn,"Original schema source",e.text)}function Ui(e){let t=ke("section",void 0,"detail-block");return t.append(ke("h3",e)),pn.append(t),t}function $le(e,t){location.hash=new URLSearchParams({schema:e.id,...t?{definition:t.key}:{}}).toString()}function yE(e){if(!e||typeof e!=="object")return ke("span",oh(e));let t=e,n=pr?.definitions.find((i)=>i.key===Jc(String(t.module),String(t.element)));if(!n)return ke("span",`${String(t.module)} / ${String(t.element)} · unresolved`,"unresolved");let r=ke("a",n.title,"ref-link");return r.href="#"+new URLSearchParams({schema:yt.id,definition:n.key}),r}function h_(e,t,n){let r=ke("dl",void 0,"schema-properties");for(let[i,s]of Object.entries(t)){if(n.includes(i))continue;let o=ke("div");o.append(ke("dt",i),ke("dd",typeof s==="string"?s:oh(s))),r.append(o)}if(r.children.length)e.append(r)}function L6e(e,t){for(let n of["itemType","valueType"])if(t[n]){let r=ke("p",n+": ");r.append(yE(t[n])),e.append(r)}for(let n of Array.isArray(t.references)?t.references:[]){let r=ke("p",`${String(n.role)}: `);r.append(yE(n)),e.append(r)}}var kle=new Map,Nle=new Map;function kp(e){return vr.find((t)=>t.id.startsWith("pack:")&&t.pack===e.pack&&t.packVersion===e.packVersion)}function Ile(e){let t=kle.get(e.id);if(!t)t=y_(e),kle.set(e.id,t);return t}function Sf(e){return e.replace(/_/g," ").replace(/^./,(t)=>t.toUpperCase())}function q6e(e,t,n=t.title){let r=ke("a",n,"ref-link");return r.href="#"+new URLSearchParams({schema:e.id,definition:t.key}),r}function pE(e,t){let n=ke("button",t?.title??(e.id.startsWith("pack:")?"Overview":e.title),"catalog-item");if(n.setAttribute("type","button"),e===yt&&(!t?!xn:t.key===xn?.key))n.setAttribute("aria-current","true");return n.append(ke("small",t?"Domain type":e.id.startsWith("pack:")?"Pack overview":e.path)),n.onclick=()=>$le(e,t),n}function _C(e,t,n,r=!1){let i=ke("details",void 0,"catalog-group");return i.open=r||(Nle.get(n)??(!n.endsWith(":types")&&!vr.some((s)=>s.id===n&&s.id.startsWith("pack:")))),i.append(ke("summary",t)),i.addEventListener("toggle",()=>Nle.set(n,i.open)),e.append(i),i}function g_(){Ep.replaceChildren();let e=xC.value.trim(),t=(o)=>(Ef.value==="all"||o.category===Ef.value)&&uE(o,e),n=0,r=vr.filter((o)=>o.id.startsWith("pack:"));if(Ef.value==="all"||Ef.value==="domain"){let o=ke("section",void 0,"catalog-section");o.append(ke("h3","Domain packs"));for(let a of r){let l=vr.filter((m)=>!m.id.startsWith("pack:")&&kp(m)===a),c=uE(a,e),u=l.filter((m)=>c||uE(m,e)),p=Ile(a).definitions.filter((m)=>!e||`${m.title} ${oh(m.value)}`.toLowerCase().includes(e.toLowerCase()));if(!c&&!u.length&&!p.length)continue;let d=yt&&kp(yt)===a,f=_C(o,`${Sf(a.title)} · ${a.packVersion??"version not declared"}`,a.id,!!d||!!e);f.dataset.pack=a.id,f.append(pE(a)),n++;for(let[m,y]of[["Tables",u.filter((h)=>h.schemaFormat==="tablespec")],["Ontology",u.filter((h)=>h.schemaFormat==="umf")],["Other schemas",u.filter((h)=>h.schemaFormat!=="umf"&&h.schemaFormat!=="tablespec")]])if(y.length){let h=_C(f,m,a.id+":"+m,!!d||!!e);for(let b of y)h.append(pE(b)),n++}if(p.length){let m=_C(f,"Domain types",a.id+":types",yt===a&&!!xn||!!e);for(let y of p)m.append(pE(a,y)),n++}}if(o.querySelector("details"))Ep.append(o)}for(let[o,a]of[["Examples",(l)=>l.category==="example"],["Local files",(l)=>l.category==="local"],["Other schemas",(l)=>l.category==="domain"&&!kp(l)]]){let l=vr.filter((u)=>a(u)&&t(u));if(!l.length)continue;let c=ke("section",void 0,"catalog-section");c.append(ke("h3",o));for(let u of l)c.append(pE(u)),n++;Ep.append(c)}if(kf("count").textContent=String(n),!n)Ep.append(ke("p",Ef.value==="domain"&&!r.length?"Domain packs have not been added to this catalog yet. Open a local schema to inspect it.":"No matching schemas. Try another search.","catalog-empty"));let i=Ep.querySelector('[aria-current="true"]'),s=matchMedia("(max-width:850px)").matches?Ep:Ep.closest("aside");if(i&&s){let o=i.getBoundingClientRect(),a=s.getBoundingClientRect();if(o.topa.bottom)s.scrollTop+=o.top-a.top-40}}function U6e(){if(!yt)return;let e=ke("nav",void 0,"breadcrumbs");e.setAttribute("aria-label","Breadcrumb");let t=kp(yt);function n(i){if(e.children.length)e.append(ke("span","›"));e.append(i)}if(t){if(n(Gc(t.id,`${Sf(t.title)} · ${t.packVersion}`)),yt===t){if(n(ke("span",xn?"Domain types":"Overview")),xn)n(ke("span",Sf(xn.title)))}else if(n(ke("span",yt.schemaFormat==="umf"?"Ontology":"Tables")),n(Gc(yt.id,Sf(yt.title))),xn)n(ke("span",Sf(xn.title)))}else if(n(ke("span",yt.category==="example"?"Examples":yt.category==="local"?"Local files":"Schemas")),n(Gc(yt.id,Sf(yt.title))),xn)n(ke("span",Sf(xn.title)));let r=e.lastElementChild;if(r)r.setAttribute("aria-current","page");pn.append(e)}function Ole(e){let t=yt&&kp(yt),n=t&&Ile(t).definitions.find((r)=>r.id===e);return t&&n?q6e(t,n):ke("span",`${e} · not declared in this pack`,"unresolved")}function B6e(){if(xle(),dE)URL.revokeObjectURL(dE);if(pn.replaceChildren(),!yt||!pr)return;if(U6e(),wle(pn,yt,pr),pr.native){K6e();return}let e=pr.document,t=ke("div",void 0,"detail-top"),n=ke("div");n.append(ke("span",yt.category==="domain"?"Domain pack":"Example","tag"),ke("h2",yt.title),ke("p",e.id,"schema-id")),t.append(n);let r=ke("a","Download source","button secondary");r.href=dE=URL.createObjectURL(new Blob([yt.text],{type:"text/plain"})),r.download=yt.path.split("/").pop()??"schema.json",r.onclick=()=>setTimeout(()=>URL.revokeObjectURL(r.href),1000),t.append(r),pn.append(t),Ale();let i=ke("div",void 0,"stats");for(let l of[`UMF ${e.umf}`,`${e.modules.length} modules`,`${pr.definitions.length} definitions`])i.append(ke("span",l,"tag"));if(pn.append(i),pn.append(ke("p",`Source: ${yt.path}`,"schema-id")),yt.description)pn.append(ke("p",yt.description));let s=ke("div",`${pr.valid?"Core structure valid":"Core structure invalid"} · ${pr.complete?"All supplied content checked":"Some semantics are not interpreted"}. Inspection does not establish storage or runtime enforcement.`,"callout");if(pn.append(s),pr.diagnostics)Gr(pn,"Validation and interpretation messages",pr.diagnostics);if((yt.schemaFormat==="umf"||String(e.title??"").includes("ontology"))&&vC(pr).records.length){Ele(pn,pr,yt,vr,new URLSearchParams(location.hash.slice(1))),mE();return}let o=ke("div",void 0,"definition-list"),a=ke("a","Overview");if(a.href="#"+new URLSearchParams({schema:yt.id}),!xn)a.setAttribute("aria-current","true");o.append(a);for(let l of pr.definitions){let c=ke("a",l.title);if(c.href="#"+new URLSearchParams({schema:yt.id,definition:l.key}),c.title=`${l.module} / ${l.id}`,l===xn)c.setAttribute("aria-current","true");o.append(c)}if(pn.append(o),xn){let l=xn.value;if(pn.append(ke("h3",xn.title,"definition-heading"),ke("p",`${xn.module} / ${xn.id} · ${xn.pointer}`,"schema-id")),l.description)pn.append(ke("p",String(l.description)));if(h_(pn,l,["id","name","title","description","extensions","references","members","keys","itemType","valueType"]),L6e(pn,l),Array.isArray(l.members)){let u=Ui("Fields and members"),p=ke("div",void 0,"table-wrap"),d=ke("table",void 0,"details-table"),f=ke("tr");for(let m of["Definition","Type / shape","Availability"])f.append(ke("th",m));d.append(f);for(let m of l.members){let y=m.field??m,h=pr.definitions.find((x)=>x.key===Jc(String(y.module),String(y.element))),b=ke("tr"),g=ke("td");if(g.append(yE(y)),h?.value.description)g.append(ke("p",String(h.value.description),"field-description"));b.append(g,ke("td",h?`${h.value.scalarType??h.value.kind??"Not declared"} · ${h.value.cardinality??"shape unspecified"}`:"Unresolved"),ke("td",String(h?.value.nullability??"Not declared"))),d.append(b)}p.append(d),u.append(p),Gr(u,"Original member declarations",l.members)}if(l.keys)Gr(Ui("Keys"),"Declared keys",l.keys,!0);let c=e.modules.flatMap((u)=>Array.isArray(u.relationships)?u.relationships:[]).filter((u)=>[...u.source??[],...u.target??[]].some((p)=>Jc(p.module,p.element)===xn.key));if(c.length)Ple(c);if(l.extensions)Gr(Ui("Extensions · retained payloads"),"Inspect extension content",l.extensions,!0);Gr(pn,"Original definition",l)}else{for(let l of e.modules){let c=Ui(String(l.title??l.namespace??l.id));if(c.append(ke("p",`${l.id} · ${l.elements.length} definitions`,"schema-id")),l.extensions)Gr(c,"Module extensions",l.extensions);if(Array.isArray(l.relationships)&&l.relationships.length)Ple(l.relationships)}if(Gr(Ui("Declared vocabularies"),"Versions and declarations",e.vocabularies,!0),e.extensions)Gr(pn,"Document extensions",e.extensions)}mE()}function Ple(e){let t=Ui("Relationships");for(let n of e){let r=ke("details");r.append(ke("summary",String(n.name??n.id)));for(let i of["source","target"]){let s=ke("p",i+": ");for(let o of n[i]??[])s.append(yE(o),document.createTextNode(" "));r.append(s)}h_(r,n,["source","target"]),t.append(r)}}function Gc(e,t){let n=ke("a",t,"ref-link");return n.href="#"+new URLSearchParams({schema:e}),n}function Ale(){let e=yt&&kp(yt);if(!e)return;let t=JSON.parse(e.text),n=t.family;if(!n)return;let r=vr.find((a)=>a.id===`pack:${n.id}@${n.version}`),i=Ui("Medical family");if(r&&r!==e)i.append(Gc(r.id,"Medical overview"));let s=r?JSON.parse(r.text):void 0,o=[...r?[{id:r.pack,version:r.packVersion,label:"Clinical"}]:[],...s?.composition?.components??[]];for(let a of o){let l=vr.find((u)=>u.id===`pack:${a.id}@${a.version}`),c=ke("p");if(c.append(l?Gc(l.id,a.label):ke("span",a.label+" · unavailable","unresolved")),c.append(ke("span",` · ${a.id} ${a.version}`,"quiet")),l===e)c.append(ke("span"," · current","tag"));i.append(c)}i.append(ke("p","Separate source namespaces and versions; no automatic patient matching or population joins.","quiet"))}function V6e(){let e=yt&&kp(yt);if(!e?.assets?.length)return;let t=JSON.parse(e.text),n=Ui(yt===e?"Sample data and originals":"Sample data"),r=new Set((t.source_bindings??[]).filter((s)=>s.schema_id===yt.title&&s.role==="rows").map((s)=>s.source_id)),i=yt===e?e.assets:e.assets.filter((s)=>r.has(s.id));for(let s of i){let o=ke("p"),a=ke("a",`Download ${s.reference.split("/").pop()}`,"ref-link");a.href=s.url,a.download=s.reference.split("/").pop(),o.append(a,ke("span",` · ${s.format} · ${s.dataKind}`,"quiet")),n.append(o)}if(!i.length)n.append(ke("p","No row source is bound to this schema."));if(yt!==e)n.append(Gc(e.id,"All sample data and originals"));n.append(ke("p","Downloads contain the pinned sample bytes. Source notices and scope are retained in the pack overview.","quiet"))}function K6e(){let e=pr.native,t=ke("div",void 0,"detail-top");if(t.append(ke("h2",yt.title)),pn.append(t,ke("p",`${pr.label} · ${yt.path}`,"schema-id")),Ale(),e.description)pn.append(ke("p",String(e.description)));pn.append(ke("p",pr.diagnostics||"Source metadata inspection; native execution semantics are not certified.","callout"));let n=ke("div",void 0,"definition-list"),r=Gc(yt.id,"Overview");n.append(r);for(let s of pr.definitions){let o=ke("a",s.title);if(o.href="#"+new URLSearchParams({schema:yt.id,definition:s.key}),s===xn)o.setAttribute("aria-current","true");n.append(o)}if(pn.append(n),xn){let s=Ui(xn.title);if(s.append(ke("p",xn.pointer,"schema-id")),xn.value.description)s.append(ke("p",String(xn.value.description)));if(h_(s,xn.value,["description","domain_type"]),typeof xn.value.domain_type==="string"){let o=ke("p","Domain type: ");o.append(Ole(xn.value.domain_type)),s.append(o)}Gr(s,"Original definition metadata",xn.value,!0),mE();return}if(e.domain_types){if(h_(pn,e,["domain_types","schemas","description","scale_presets","source_bindings","sources",...e.family?["family","composition","execution_profile","csv_conventions","fixture_counts","qualification"]:[]]),e.family){let a=Ui("Sample scope");for(let l of["subset","limits"])if(typeof e.qualification?.[l]==="string")a.append(ke("p",e.qualification[l]));if(e.qualification)Gr(a,"Detailed source qualification",e.qualification);Gr(a,"Pack composition and execution metadata",{family:e.family,...e.composition?{composition:e.composition}:{},execution_profile:e.execution_profile,csv_conventions:e.csv_conventions,fixture_counts:e.fixture_counts})}for(let[a,l]of[["scale_presets","Scale presets"],["source_bindings","Source bindings"],["sources","Source declarations"]])if(e[a])Gr(pn,l,e[a]);let s=Ui("Schemas in this pack");for(let a of e.schemas??[]){let l=vr.find((u)=>u.pack===e.id&&u.packVersion===yt.packVersion&&u.path===a.reference),c=ke("p");c.append(l?Gc(l.id,String(a.id)):ke("span",`${a.id} · ${a.reference} · not bundled`,"unresolved")),c.append(ke("span",` · ${a.format}`,"quiet")),s.append(c)}if(!e.schemas?.length)s.append(ke("p","No schema references declared."));let o=Ui("Domain types");for(let[a,l]of Object.entries(e.domain_types)){let c=ke("details");c.append(ke("summary",a),ke("pre",oh(l))),o.append(c)}}else if(Array.isArray(e.columns)){let s=kp(yt),o=s?JSON.parse(s.text).execution_profile?.targets:void 0,a=o?.graph?.includes("ontology")&&vr.find((d)=>d.id===`schema:${yt.pack}@${yt.packVersion}:ontology`);if(a&&o.tabular?.includes(e.table_name)){let d=y_(a).definitions.find((f)=>f.id===e.table_name&&f.value.kind==="record");if(d){let f=ke("a","View ontology record","ref-link");f.href="#"+new URLSearchParams({schema:a.id,definition:d.key}),pn.append(f)}}let l=Ui("Columns"),c=ke("div",void 0,"table-wrap"),u=ke("table",void 0,"details-table"),p=ke("tr");for(let d of["Column","Native type","Nullable","Domain type"])p.append(ke("th",d));u.append(p);for(let d of e.columns){let f=ke("tr"),m=ke("td",d.name);if(d.description)m.append(ke("p",d.description,"field-description"));f.append(m,ke("td",d.data_type),ke("td",d.nullable===void 0?"Not declared":String(d.nullable)),(()=>{let y=ke("td");return y.append(d.domain_type?Ole(d.domain_type):ke("span","—")),y})()),u.append(f)}if(c.append(u),l.append(c),Gr(l,"All column metadata",e.columns),e.primary_key)Gr(Ui("Primary key"),"Declared columns",e.primary_key,!0);if(e.relationships){let d=Ui("Native relationships");for(let f of e.relationships.foreign_keys??[]){let m=vr.find((h)=>h.pack===yt.pack&&h.packVersion===yt.packVersion&&h.title===f.references_table),y=ke("p",`${f.column} → `);y.append(m?Gc(m.id,`${f.references_table}.${f.references_column}`):ke("span",`${f.references_table}.${f.references_column} · not bundled`,"unresolved")),d.append(y)}Gr(d,"Original relationship metadata",e.relationships)}h_(pn,e,["columns","relationships","primary_key","description","table_name"])}else{let s=e.$defs??e.definitions??{},o=Ui("Definitions");for(let[a,l]of Object.entries(s)){let c=ke("details");c.append(ke("summary",a),ke("pre",oh(l))),o.append(c)}Gr(pn,"Schema keywords",e,!0)}V6e(),mE();let i=ke("a","Download source","button secondary");i.href=dE=URL.createObjectURL(new Blob([yt.text],{type:"text/plain"})),i.download=yt.path.split("/").pop()??"schema.json",i.onclick=()=>setTimeout(()=>URL.revokeObjectURL(i.href),1000),pn.append(i)}function Rle(){let e=new URLSearchParams(location.hash.slice(1)),t=e.get("schema"),n=vr.find((r)=>r.id===t)??vr.find((r)=>r.aliases?.includes(t??""))??(!t?vr[0]:void 0);if(n&&t&&n.id!==t)e.set("schema",n.id),history.replaceState(null,"","#"+e);if(!n){yt=void 0,pr=void 0,pn.replaceChildren(ke("p","This schema is not in the catalog. Choose a schema from the catalog.","empty")),g_();return}try{yt=n,pr=y_(n),xn=pr.definitions.find((r)=>r.key===e.get("definition")),B6e(),g_(),fE.textContent=e.get("definition")&&!xn?"Definition not found; showing the schema overview.":[`${vr.filter((r)=>r.id.startsWith("pack:")).length} domain pack${vr.filter((r)=>r.id.startsWith("pack:")).length===1?"":"s"}`,`${vr.filter((r)=>r.category==="domain"&&!r.id.startsWith("pack:")).length} domain schemas`,`${vr.filter((r)=>r.category==="example").length} example${vr.filter((r)=>r.category==="example").length===1?"":"s"}`].join(" · ")}catch(r){pr=void 0,pn.replaceChildren(ke("p","This schema could not be opened.","empty"),ke("pre",String(r))),g_(),fE.textContent="Schema inspection refused; original source remains available.",Gr(pn,"Original schema source",n.text)}}xC.oninput=g_;Ef.onchange=g_;window.addEventListener("hashchange",Rle);kf("file").onchange=async(e)=>{let t=e.target,n=t.files?.[0];if(!n)return;try{if(n.size>4000000)throw Error("Schema exceeds the 4 MB local-file limit.");let r={id:`local:${n.name}:${Date.now()}`,title:n.name,category:"local",path:n.name,text:await n.text(),format:/\.ya?ml$/i.test(n.name)?"yaml":"json"};y_(r),vr.push(r),Ef.value="all",xC.value="",$le(r)}catch(r){fE.textContent=`Could not open local schema: ${String(r)}`}finally{t.value=""}};try{let e=await fetch("schema-catalog.json");if(!e.ok)throw Error(`Catalog unavailable (${e.status})`);vr=(await e.json()).entries,Rle()}catch(e){fE.textContent=String(e),Ep.append(ke("p","Open a local schema to start exploring.","empty"))} diff --git a/docs/helix/05-deploy/microsite/dist/schema-catalog.json b/docs/helix/05-deploy/microsite/dist/schema-catalog.json index 63ace4dac..3fbb983b7 100644 --- a/docs/helix/05-deploy/microsite/dist/schema-catalog.json +++ b/docs/helix/05-deploy/microsite/dist/schema-catalog.json @@ -2304,436 +2304,1443 @@ ] }, { - "id": "pack:medical-carrier@1.0.0", + "id": "pack:medical-carrier@1.1.0", "title": "medical-carrier", "category": "domain", "path": "domain-pack.json", "pack": "medical-carrier", - "packVersion": "1.0.0", - "text": "{\n \"id\": \"medical-carrier\",\n \"version\": \"1.0.0\",\n \"description\": \"Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.\",\n \"domain_types\": {\n \"source_qualified_identity\": {\n \"description\": \"Source namespace and native identity; no inferred patient identity.\"\n },\n \"exact_native_literal\": {\n \"description\": \"Numeric and temporal source spelling retained as text.\"\n }\n },\n \"schemas\": [\n {\n \"id\": \"resources\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/resources.json\"\n },\n {\n \"id\": \"coverage\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/coverage.json\"\n },\n {\n \"id\": \"eligibility\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/eligibility.json\"\n },\n {\n \"id\": \"claims\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/claims.json\"\n },\n {\n \"id\": \"claim_lines\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/claim_lines.json\"\n },\n {\n \"id\": \"adjudications\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/adjudications.json\"\n },\n {\n \"id\": \"payments\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/payments.json\"\n },\n {\n \"id\": \"plans\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/plans.json\"\n },\n {\n \"id\": \"enrollments\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/enrollments.json\"\n },\n {\n \"id\": \"resource_references\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/resource_references.json\"\n },\n {\n \"id\": \"coded_values\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/coded_values.json\"\n },\n {\n \"id\": \"workflow_events\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/workflow_events.json\"\n }\n ],\n \"sources\": {\n \"hl7-claim\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-claim.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"9f5772b885ed9279361b761e5483a929ece57c2e1d32ac2315ce12caef186339\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/claim-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-claimresponse\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-claimresponse.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"460c178f1c9248bbcb0677aa96aef9da5353be7e50f3fc84f144f03be227f3c4\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/claimresponse-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-coverage\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-coverage.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"98fb4fcef07a290efb9e3733714f5e3f29d2943ca4367e7d3e3e59c4339bbf08\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/coverage-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-eligibility-request\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-eligibility-request.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"9e5e4291bec5672542d37151206a3e6433c5c764e91d8c0f927405cd6dd99612\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/coverageeligibilityrequest-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-eligibility-response\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-eligibility-response.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"c24cdf34a5b9609df131dd1968f7873dad451602a55f0b1185b024b14cfa7d4a\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/coverageeligibilityresponse-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-enrollment\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-enrollment.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"8d625da8606e1f1c0d179401b31d45e53888213e1583c8049f95bd36bb909cd2\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/enrollmentrequest-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-eob\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-eob.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"d73617364c6080c39083912e22bb76162e7594611dca360412d7010e74ff68c2\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/explanationofbenefit-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-insuranceplan\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-insuranceplan.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"5dec5d14070a0ba3a3ad9217c305b35948502fc6e1e8ca2217215c25b022fd0e\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/insuranceplan-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-payment\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-payment.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"ed5674fda256ae01788491e66078869cdaef41b52261a31af9d1368bebde5a20\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/paymentreconciliation-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"supplement-claim-authorization-approved\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-claim-authorization-approved.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"526b7a991784f8a6cc35981eab28105195ef682755c5067cc45358f672b4b2ee\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-claim-authorization-denied\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-claim-authorization-denied.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"ad9c085fb8d866d1bf201ba317064cec6de3a076bbe27b126688c487c1baf4dd\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-claim-paid-denied\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-claim-paid-denied.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"d9fe4d6e41c17e28aedb9441267dd33df33f539869fdc056ae0ba302cfb71118\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-coverage-active\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-coverage-active.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"bfe0d1b789d6b5af1ce3d69cdbec59b7a289c57a8e6b3fa7f704c461a5d59ae1\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-coverage-inactive\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-coverage-inactive.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"6bac11dd3d84828012d41bcfe073ea909ee6bb92e45f695ef83b227e8dbdd171\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-eligibility-negative-request\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-eligibility-negative-request.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"26e43d4fd5ebff41ccac60f264c2c68c618efbc04ec2d25814e68d9edf75f9d2\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-eligibility-negative-response\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-eligibility-negative-response.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"facfed979d36ee6ae0cb4f94c718c720fa5227999aa8751bae286c0ef96405f3\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-eligibility-positive-request\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-eligibility-positive-request.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"ac8d756638c079d9fe68d46e211331c575f101edf5ff28bbf1b9605885c57525\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-eligibility-positive-response\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-eligibility-positive-response.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"d8e0e9a8f9025dfac07df8546e81de2e95cd12311bfa24585c6ac131c04f7e9d\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-enrollment-request\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-enrollment-request.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"1bb28887e7ba29630b1726145813675fa9903af02fa5cd462c88ff93762f84dd\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-enrollment-response\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-enrollment-response.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"f0591ee4edbfe089ad1f5c5478b536911ecdb8f17de01d5ae87ae6f0e05d6a2e\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-eob\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-eob.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"e35a4194dab73e92de8a15613139506b7b52882f96284cf2226fe45d70f8da1a\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-patient\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-patient.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"7289f945e6acf2ce66c83e3e8a37ebfa6a6556c599d2d12336cbd51396f66424\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-payer\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-payer.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"4a43f964cbd30343e1280c92e3bb1ed37b7dfb9bf946f6bafd439a51b99a5661\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-payment\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-payment.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"36284c9df3a93a5f86cbe054435730811fa5a62e2cb233be81da0a174db672b6\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-plan\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-plan.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"d9886c0b4ce226972752ab72665824aa60c55a06c7fe6ca2ecf927326756c922\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-response-authorization-approved\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-response-authorization-approved.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"bd267969ba418fc87baf385946c1422f64e913aa7c6a8cc15fa4f16363c8c848\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-response-authorization-denied\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-response-authorization-denied.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"f709ce1bf67e2a05073a4720de39b1ec718a525cf64fbaff8f32716f33033ce5\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-response-paid-denied\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-response-paid-denied.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"c7d4f37c7eec131f9b3474ca7e5ebabb1a8dd0be79bdaed37d9579ce3df3dae5\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"workflow\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/workflow-events.json\",\n \"format\": \"json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"bb3fae1317c8c050a802b70895d362f263d3114cc65af12fbcb639b9063abaae\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"cms_rif\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"https://data.cms.gov/\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"Centers for Medicare & Medicaid Services\"\n }\n },\n \"cms_blue_button\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"https://bluebutton.cms.gov/data/understanding-the-data/\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"Centers for Medicare & Medicaid Services\"\n }\n },\n \"notices\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"format\": \"text\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"7d17b67002331831971ff865c563c1ef265da9fcb77068f90dd979f7b0a69b24\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"csv_resources\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/resources.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"0f4a4537fc78a555ade4a8fe68709458c3b4c0f4a080b99692382dac0ef7f6e9\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\",\n \"workflow\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_coverage\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/coverage.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"5571b3a7a70a61dae1d771dc113c6a0a246e506f8a125de579094f3d87487eda\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\",\n \"workflow\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_eligibility\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/eligibility.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"68d560d188c7fa42ac85b331de51ca04c8dd8c64611d3663cf53f5ad0f18a08a\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\",\n \"workflow\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_claims\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/claims.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"a902b00758a4972f09f53e2e8b26f9997fdd2bea468e20a1cb7c04adebc8c703\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\",\n \"workflow\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_claim_lines\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/claim_lines.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"0bd9b58462d29869bcd8a00225f8b1b77b83c81bed04d5a8a44fe7232e94ce37\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\",\n \"workflow\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_adjudications\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/adjudications.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"fa035e3b2b0dfb201414d04b7dcfdf0a7e39fed806de024b6c0be2ac352fab7f\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\",\n \"workflow\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_payments\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/payments.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"1469a88558a7f262ef85c5fe9b4b6bda7eb7102ea92a992004f35a648ed707ec\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\",\n \"workflow\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_plans\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/plans.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"f27ca990c8476379a6cc992083451b684eb0a1e54957aa1e985bf216b7f64034\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\",\n \"workflow\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_enrollments\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/enrollments.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"5716b79011198e027a81163c62cd97c7c03af0b0b7e27308bd8d12b9c6625eb5\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\",\n \"workflow\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_resource_references\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/resource_references.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"1da6ebc223e723755b8476306fb5e8050aa3d0e384fa7048ecc6c26a7aae0aaf\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\",\n \"workflow\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_coded_values\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/coded_values.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"5eeeeb39af2f52c42959c071208ad18f9f8ba335865b5a3703d2df85677b0b48\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\",\n \"workflow\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_workflow_events\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/workflow_events.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"b27e0b1d336915c55ee950bb82b0cbf6f9cc86799ed6a0babd4ce3d6452f83cb\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\",\n \"workflow\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n }\n },\n \"source_bindings\": [\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"csv_resources\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"csv_coverage\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"csv_eligibility\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"csv_claims\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"csv_claim_lines\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"csv_adjudications\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"csv_payments\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"csv_plans\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"csv_enrollments\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"csv_resource_references\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"csv_coded_values\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"workflow_events\",\n \"source_id\": \"csv_workflow_events\",\n \"role\": \"rows\"\n }\n ],\n \"csv_conventions\": {\n \"encoding\": \"UTF-8\",\n \"null_value\": \"\\\\N\",\n \"header\": true,\n \"quote\": \"\\\"\"\n },\n \"fixture_counts\": {\n \"resources\": 28,\n \"coverage\": 3,\n \"eligibility\": 6,\n \"claims\": 10,\n \"claim_lines\": 20,\n \"adjudications\": 30,\n \"payments\": 4,\n \"plans\": 2,\n \"enrollments\": 3,\n \"resource_references\": 95,\n \"coded_values\": 101,\n \"workflow_events\": 4\n },\n \"qualification\": {\n \"native_format\": \"FHIR R4 4.0.1 selected views plus independent UMF scenario events\",\n \"subset\": \"9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.\",\n \"limits\": \"Illustrative sources are not a validated FHIR Bundle or carrier simulation. Native official examples do not form a coherent history. CMS ingestion and X12 services are not implemented. Reference resolution is namespace-local; no patient matching.\"\n }\n}\n", - "format": "json", - "description": "Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence." - }, - { - "id": "schema:medical-carrier@1.0.0:resources", + "packVersion": "1.1.0", + "text": "{\n \"id\": \"medical-carrier\",\n \"version\": \"1.1.0\",\n \"family\": {\n \"id\": \"medical\",\n \"version\": \"1.1.0\",\n \"label\": \"Carrier: eligibility, claims and payments\"\n },\n \"execution_profile\": {\n \"version\": \"1.0.0\",\n \"targets\": {\n \"tabular\": [\n \"resources\",\n \"coverage\",\n \"eligibility\",\n \"claims\",\n \"claim_lines\",\n \"adjudications\",\n \"payments\",\n \"plans\",\n \"enrollments\",\n \"resource_references\",\n \"coded_values\",\n \"workflow_events\",\n \"cms_beneficiaries\",\n \"cms_inpatient_claims\",\n \"cms_carrier_claims\"\n ],\n \"graph\": [\n \"ontology\"\n ]\n },\n \"mode\": \"fixed\",\n \"include_sources\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\",\n \"workflow\",\n \"cms_beneficiaries\",\n \"cms_inpatient\",\n \"cms_carrier\",\n \"cms_selection\",\n \"notices\",\n \"csv_resources\",\n \"csv_coverage\",\n \"csv_eligibility\",\n \"csv_claims\",\n \"csv_claim_lines\",\n \"csv_adjudications\",\n \"csv_payments\",\n \"csv_plans\",\n \"csv_enrollments\",\n \"csv_resource_references\",\n \"csv_coded_values\",\n \"csv_workflow_events\",\n \"csv_cms_beneficiaries\",\n \"csv_cms_inpatient_claims\",\n \"csv_cms_carrier_claims\"\n ],\n \"qualification\": \"Fixed source-qualified sample rows and schema-only ontology. No data generation, clinical conformance or graph-storage execution claim.\"\n },\n \"description\": \"Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.\",\n \"domain_types\": {\n \"source_qualified_identity\": {\n \"description\": \"Source namespace and native identity; no inferred patient identity.\"\n },\n \"exact_native_literal\": {\n \"description\": \"Numeric and temporal source spelling retained as text.\"\n }\n },\n \"schemas\": [\n {\n \"id\": \"resources\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/resources.json\"\n },\n {\n \"id\": \"coverage\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/coverage.json\"\n },\n {\n \"id\": \"eligibility\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/eligibility.json\"\n },\n {\n \"id\": \"claims\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/claims.json\"\n },\n {\n \"id\": \"claim_lines\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/claim_lines.json\"\n },\n {\n \"id\": \"adjudications\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/adjudications.json\"\n },\n {\n \"id\": \"payments\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/payments.json\"\n },\n {\n \"id\": \"plans\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/plans.json\"\n },\n {\n \"id\": \"enrollments\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/enrollments.json\"\n },\n {\n \"id\": \"resource_references\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/resource_references.json\"\n },\n {\n \"id\": \"coded_values\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/coded_values.json\"\n },\n {\n \"id\": \"workflow_events\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/workflow_events.json\"\n },\n {\n \"id\": \"cms_beneficiaries\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/cms_beneficiaries.json\"\n },\n {\n \"id\": \"cms_inpatient_claims\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/cms_inpatient_claims.json\"\n },\n {\n \"id\": \"cms_carrier_claims\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/cms_carrier_claims.json\"\n },\n {\n \"id\": \"ontology\",\n \"format\": \"umf\",\n \"reference\": \"ontology.json\"\n }\n ],\n \"sources\": {\n \"hl7-claim\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-claim.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"9f5772b885ed9279361b761e5483a929ece57c2e1d32ac2315ce12caef186339\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/claim-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-claimresponse\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-claimresponse.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"460c178f1c9248bbcb0677aa96aef9da5353be7e50f3fc84f144f03be227f3c4\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/claimresponse-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-coverage\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-coverage.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"98fb4fcef07a290efb9e3733714f5e3f29d2943ca4367e7d3e3e59c4339bbf08\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/coverage-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-eligibility-request\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-eligibility-request.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"9e5e4291bec5672542d37151206a3e6433c5c764e91d8c0f927405cd6dd99612\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/coverageeligibilityrequest-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-eligibility-response\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-eligibility-response.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"c24cdf34a5b9609df131dd1968f7873dad451602a55f0b1185b024b14cfa7d4a\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/coverageeligibilityresponse-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-enrollment\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-enrollment.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"8d625da8606e1f1c0d179401b31d45e53888213e1583c8049f95bd36bb909cd2\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/enrollmentrequest-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-eob\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-eob.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"d73617364c6080c39083912e22bb76162e7594611dca360412d7010e74ff68c2\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/explanationofbenefit-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-insuranceplan\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-insuranceplan.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"5dec5d14070a0ba3a3ad9217c305b35948502fc6e1e8ca2217215c25b022fd0e\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/insuranceplan-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"hl7-payment\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/hl7-payment.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"ed5674fda256ae01788491e66078869cdaef41b52261a31af9d1368bebde5a20\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/paymentreconciliation-example.json\",\n \"transformations\": []\n },\n \"revision\": \"4.0.1\"\n },\n \"supplement-claim-authorization-approved\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-claim-authorization-approved.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"526b7a991784f8a6cc35981eab28105195ef682755c5067cc45358f672b4b2ee\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-claim-authorization-denied\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-claim-authorization-denied.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"ad9c085fb8d866d1bf201ba317064cec6de3a076bbe27b126688c487c1baf4dd\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-claim-paid-denied\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-claim-paid-denied.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"d9fe4d6e41c17e28aedb9441267dd33df33f539869fdc056ae0ba302cfb71118\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-coverage-active\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-coverage-active.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"bfe0d1b789d6b5af1ce3d69cdbec59b7a289c57a8e6b3fa7f704c461a5d59ae1\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-coverage-inactive\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-coverage-inactive.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"6bac11dd3d84828012d41bcfe073ea909ee6bb92e45f695ef83b227e8dbdd171\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-eligibility-negative-request\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-eligibility-negative-request.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"26e43d4fd5ebff41ccac60f264c2c68c618efbc04ec2d25814e68d9edf75f9d2\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-eligibility-negative-response\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-eligibility-negative-response.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"facfed979d36ee6ae0cb4f94c718c720fa5227999aa8751bae286c0ef96405f3\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-eligibility-positive-request\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-eligibility-positive-request.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"ac8d756638c079d9fe68d46e211331c575f101edf5ff28bbf1b9605885c57525\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-eligibility-positive-response\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-eligibility-positive-response.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"d8e0e9a8f9025dfac07df8546e81de2e95cd12311bfa24585c6ac131c04f7e9d\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-enrollment-request\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-enrollment-request.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"1bb28887e7ba29630b1726145813675fa9903af02fa5cd462c88ff93762f84dd\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-enrollment-response\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-enrollment-response.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"f0591ee4edbfe089ad1f5c5478b536911ecdb8f17de01d5ae87ae6f0e05d6a2e\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-eob\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-eob.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"e35a4194dab73e92de8a15613139506b7b52882f96284cf2226fe45d70f8da1a\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-patient\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-patient.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"7289f945e6acf2ce66c83e3e8a37ebfa6a6556c599d2d12336cbd51396f66424\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-payer\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-payer.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"4a43f964cbd30343e1280c92e3bb1ed37b7dfb9bf946f6bafd439a51b99a5661\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-payment\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-payment.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"36284c9df3a93a5f86cbe054435730811fa5a62e2cb233be81da0a174db672b6\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-plan\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-plan.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"d9886c0b4ce226972752ab72665824aa60c55a06c7fe6ca2ecf927326756c922\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-response-authorization-approved\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-response-authorization-approved.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"bd267969ba418fc87baf385946c1422f64e913aa7c6a8cc15fa4f16363c8c848\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-response-authorization-denied\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-response-authorization-denied.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"f709ce1bf67e2a05073a4720de39b1ec718a525cf64fbaff8f32716f33033ce5\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"supplement-response-paid-denied\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement-response-paid-denied.json\",\n \"format\": \"fhir-r4-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"c7d4f37c7eec131f9b3474ca7e5ebabb1a8dd0be79bdaed37d9579ce3df3dae5\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-scenario-1.0.0\"\n },\n \"workflow\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/workflow-events.json\",\n \"format\": \"json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"bb3fae1317c8c050a802b70895d362f263d3114cc65af12fbcb639b9063abaae\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"cms_rif\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"https://data.cms.gov/\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"Centers for Medicare & Medicaid Services\"\n }\n },\n \"cms_blue_button\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"https://bluebutton.cms.gov/data/understanding-the-data/\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"Centers for Medicare & Medicaid Services\"\n }\n },\n \"cms_beneficiaries\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/cms-beneficiaries.csv\",\n \"format\": \"csv\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"500f5a2040cb17376c130884bfafa81bcc8d5acb0a44f89aa2af8701cc2d7349\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"CMS\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://www.cms.gov/research-statistics-data-and-systems/downloadable-public-use-files/synpufs/downloads/de1_0_2008_beneficiary_summary_file_sample_1.zip\",\n \"transformations\": [\n \"Exact native header and selected complete record bytes; see cms-selection.json.\"\n ]\n },\n \"revision\": \"DE-SynPUF 1.0 Sample 1; 2008 beneficiary and 2008–2010 claims\"\n },\n \"cms_inpatient\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/cms-inpatient.csv\",\n \"format\": \"csv\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"064973be1b23e48c9df9f4163502282ffc01b1094710cba588beb6d581f6d8b4\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"CMS\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://www.cms.gov/research-statistics-data-and-systems/downloadable-public-use-files/synpufs/downloads/de1_0_2008_to_2010_inpatient_claims_sample_1.zip\",\n \"transformations\": [\n \"Exact native header and selected complete record bytes; see cms-selection.json.\"\n ]\n },\n \"revision\": \"DE-SynPUF 1.0 Sample 1; 2008 beneficiary and 2008–2010 claims\"\n },\n \"cms_carrier\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/cms-carrier.csv\",\n \"format\": \"csv\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"91d44f48211ffe3a0176bcc3fc980672de5db48de1d79783935db703ed0f456d\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"CMS\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://downloads.cms.gov/files/DE1_0_2008_to_2010_Carrier_Claims_Sample_1A.zip\",\n \"transformations\": [\n \"Exact native header and selected complete record bytes; see cms-selection.json.\"\n ]\n },\n \"revision\": \"DE-SynPUF 1.0 Sample 1; 2008 beneficiary and 2008–2010 claims\"\n },\n \"cms_selection\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"sources/cms-selection.json\",\n \"format\": \"json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"ce80cfbfeaa4899356d1877d62bf2404ff53896de7acb69cb64aed94fe5da1c5\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"notices\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"format\": \"text\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"1100d7e599a36762c7159a5fdc0ca81efd19185babaa2a8ec226f970d1e7340c\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"csv_resources\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/resources.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"0f4a4537fc78a555ade4a8fe68709458c3b4c0f4a080b99692382dac0ef7f6e9\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_coverage\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/coverage.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"5571b3a7a70a61dae1d771dc113c6a0a246e506f8a125de579094f3d87487eda\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_eligibility\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/eligibility.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"68d560d188c7fa42ac85b331de51ca04c8dd8c64611d3663cf53f5ad0f18a08a\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_claims\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/claims.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"a902b00758a4972f09f53e2e8b26f9997fdd2bea468e20a1cb7c04adebc8c703\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_claim_lines\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/claim_lines.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"0bd9b58462d29869bcd8a00225f8b1b77b83c81bed04d5a8a44fe7232e94ce37\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_adjudications\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/adjudications.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"fa035e3b2b0dfb201414d04b7dcfdf0a7e39fed806de024b6c0be2ac352fab7f\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_payments\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/payments.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"1469a88558a7f262ef85c5fe9b4b6bda7eb7102ea92a992004f35a648ed707ec\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_plans\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/plans.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"f27ca990c8476379a6cc992083451b684eb0a1e54957aa1e985bf216b7f64034\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_enrollments\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/enrollments.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"5716b79011198e027a81163c62cd97c7c03af0b0b7e27308bd8d12b9c6625eb5\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_resource_references\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/resource_references.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"1da6ebc223e723755b8476306fb5e8050aa3d0e384fa7048ecc6c26a7aae0aaf\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_coded_values\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/coded_values.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"5eeeeb39af2f52c42959c071208ad18f9f8ba335865b5a3703d2df85677b0b48\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"hl7-claim\",\n \"hl7-claimresponse\",\n \"hl7-coverage\",\n \"hl7-eligibility-request\",\n \"hl7-eligibility-response\",\n \"hl7-enrollment\",\n \"hl7-eob\",\n \"hl7-insuranceplan\",\n \"hl7-payment\",\n \"supplement-claim-authorization-approved\",\n \"supplement-claim-authorization-denied\",\n \"supplement-claim-paid-denied\",\n \"supplement-coverage-active\",\n \"supplement-coverage-inactive\",\n \"supplement-eligibility-negative-request\",\n \"supplement-eligibility-negative-response\",\n \"supplement-eligibility-positive-request\",\n \"supplement-eligibility-positive-response\",\n \"supplement-enrollment-request\",\n \"supplement-enrollment-response\",\n \"supplement-eob\",\n \"supplement-patient\",\n \"supplement-payer\",\n \"supplement-payment\",\n \"supplement-plan\",\n \"supplement-response-authorization-approved\",\n \"supplement-response-authorization-denied\",\n \"supplement-response-paid-denied\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_workflow_events\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/workflow_events.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"b27e0b1d336915c55ee950bb82b0cbf6f9cc86799ed6a0babd4ce3d6452f83cb\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"workflow\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_cms_beneficiaries\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/cms_beneficiaries.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"682d408b477eba199e96c853c7982c0157881768a5b8e7be896a75ca1a91e82e\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"cms_beneficiaries\",\n \"cms_selection\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_cms_inpatient_claims\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/cms_inpatient_claims.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"281f8484b788cdfd0c3545740374675c9b69c350f25b64dd0f9aa26ce8ffdfa8\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"cms_inpatient\",\n \"cms_selection\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_cms_carrier_claims\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/cms_carrier_claims.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-carrier-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"a3175dadf541162ed006f3b768cc95c3aad7c06e5ca90bd79b4edebef2138401\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"cms_carrier\",\n \"cms_selection\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n }\n },\n \"source_bindings\": [\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"csv_resources\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"hl7-claim\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"hl7-claimresponse\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"hl7-coverage\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"hl7-eligibility-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"hl7-eligibility-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"hl7-enrollment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"hl7-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"hl7-insuranceplan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"hl7-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-claim-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-claim-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-claim-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-coverage-active\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-coverage-inactive\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-eligibility-negative-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-eligibility-negative-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-eligibility-positive-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-eligibility-positive-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-enrollment-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-enrollment-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-patient\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-payer\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-plan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-response-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-response-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"supplement-response-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"csv_coverage\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"hl7-claim\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"hl7-claimresponse\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"hl7-coverage\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"hl7-eligibility-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"hl7-eligibility-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"hl7-enrollment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"hl7-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"hl7-insuranceplan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"hl7-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-claim-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-claim-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-claim-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-coverage-active\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-coverage-inactive\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-eligibility-negative-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-eligibility-negative-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-eligibility-positive-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-eligibility-positive-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-enrollment-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-enrollment-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-patient\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-payer\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-plan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-response-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-response-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coverage\",\n \"source_id\": \"supplement-response-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"csv_eligibility\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"hl7-claim\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"hl7-claimresponse\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"hl7-coverage\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"hl7-eligibility-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"hl7-eligibility-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"hl7-enrollment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"hl7-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"hl7-insuranceplan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"hl7-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-claim-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-claim-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-claim-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-coverage-active\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-coverage-inactive\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-eligibility-negative-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-eligibility-negative-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-eligibility-positive-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-eligibility-positive-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-enrollment-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-enrollment-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-patient\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-payer\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-plan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-response-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-response-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"eligibility\",\n \"source_id\": \"supplement-response-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"csv_claims\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"hl7-claim\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"hl7-claimresponse\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"hl7-coverage\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"hl7-eligibility-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"hl7-eligibility-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"hl7-enrollment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"hl7-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"hl7-insuranceplan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"hl7-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-claim-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-claim-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-claim-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-coverage-active\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-coverage-inactive\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-eligibility-negative-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-eligibility-negative-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-eligibility-positive-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-eligibility-positive-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-enrollment-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-enrollment-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-patient\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-payer\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-plan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-response-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-response-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claims\",\n \"source_id\": \"supplement-response-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"csv_claim_lines\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"hl7-claim\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"hl7-claimresponse\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"hl7-coverage\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"hl7-eligibility-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"hl7-eligibility-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"hl7-enrollment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"hl7-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"hl7-insuranceplan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"hl7-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-claim-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-claim-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-claim-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-coverage-active\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-coverage-inactive\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-eligibility-negative-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-eligibility-negative-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-eligibility-positive-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-eligibility-positive-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-enrollment-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-enrollment-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-patient\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-payer\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-plan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-response-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-response-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"claim_lines\",\n \"source_id\": \"supplement-response-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"csv_adjudications\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"hl7-claim\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"hl7-claimresponse\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"hl7-coverage\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"hl7-eligibility-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"hl7-eligibility-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"hl7-enrollment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"hl7-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"hl7-insuranceplan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"hl7-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-claim-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-claim-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-claim-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-coverage-active\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-coverage-inactive\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-eligibility-negative-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-eligibility-negative-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-eligibility-positive-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-eligibility-positive-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-enrollment-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-enrollment-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-patient\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-payer\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-plan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-response-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-response-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"adjudications\",\n \"source_id\": \"supplement-response-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"csv_payments\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"hl7-claim\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"hl7-claimresponse\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"hl7-coverage\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"hl7-eligibility-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"hl7-eligibility-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"hl7-enrollment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"hl7-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"hl7-insuranceplan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"hl7-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-claim-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-claim-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-claim-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-coverage-active\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-coverage-inactive\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-eligibility-negative-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-eligibility-negative-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-eligibility-positive-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-eligibility-positive-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-enrollment-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-enrollment-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-patient\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-payer\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-plan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-response-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-response-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"payments\",\n \"source_id\": \"supplement-response-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"csv_plans\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"hl7-claim\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"hl7-claimresponse\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"hl7-coverage\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"hl7-eligibility-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"hl7-eligibility-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"hl7-enrollment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"hl7-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"hl7-insuranceplan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"hl7-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-claim-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-claim-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-claim-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-coverage-active\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-coverage-inactive\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-eligibility-negative-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-eligibility-negative-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-eligibility-positive-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-eligibility-positive-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-enrollment-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-enrollment-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-patient\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-payer\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-plan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-response-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-response-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"plans\",\n \"source_id\": \"supplement-response-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"csv_enrollments\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"hl7-claim\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"hl7-claimresponse\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"hl7-coverage\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"hl7-eligibility-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"hl7-eligibility-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"hl7-enrollment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"hl7-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"hl7-insuranceplan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"hl7-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-claim-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-claim-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-claim-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-coverage-active\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-coverage-inactive\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-eligibility-negative-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-eligibility-negative-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-eligibility-positive-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-eligibility-positive-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-enrollment-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-enrollment-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-patient\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-payer\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-plan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-response-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-response-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"enrollments\",\n \"source_id\": \"supplement-response-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"csv_resource_references\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"hl7-claim\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"hl7-claimresponse\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"hl7-coverage\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"hl7-eligibility-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"hl7-eligibility-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"hl7-enrollment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"hl7-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"hl7-insuranceplan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"hl7-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-claim-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-claim-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-claim-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-coverage-active\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-coverage-inactive\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-eligibility-negative-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-eligibility-negative-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-eligibility-positive-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-eligibility-positive-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-enrollment-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-enrollment-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-patient\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-payer\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-plan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-response-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-response-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"supplement-response-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"csv_coded_values\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"hl7-claim\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"hl7-claimresponse\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"hl7-coverage\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"hl7-eligibility-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"hl7-eligibility-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"hl7-enrollment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"hl7-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"hl7-insuranceplan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"hl7-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-claim-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-claim-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-claim-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-coverage-active\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-coverage-inactive\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-eligibility-negative-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-eligibility-negative-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-eligibility-positive-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-eligibility-positive-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-enrollment-request\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-enrollment-response\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-eob\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-patient\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-payer\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-payment\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-plan\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-response-authorization-approved\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-response-authorization-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"coded_values\",\n \"source_id\": \"supplement-response-paid-denied\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"workflow_events\",\n \"source_id\": \"csv_workflow_events\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"workflow_events\",\n \"source_id\": \"workflow\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"cms_beneficiaries\",\n \"source_id\": \"csv_cms_beneficiaries\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"cms_beneficiaries\",\n \"source_id\": \"cms_beneficiaries\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"cms_beneficiaries\",\n \"source_id\": \"cms_selection\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"cms_inpatient_claims\",\n \"source_id\": \"csv_cms_inpatient_claims\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"cms_inpatient_claims\",\n \"source_id\": \"cms_inpatient\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"cms_inpatient_claims\",\n \"source_id\": \"cms_selection\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"cms_carrier_claims\",\n \"source_id\": \"csv_cms_carrier_claims\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"cms_carrier_claims\",\n \"source_id\": \"cms_carrier\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"cms_carrier_claims\",\n \"source_id\": \"cms_selection\",\n \"role\": \"reference\"\n }\n ],\n \"csv_conventions\": {\n \"encoding\": \"UTF-8\",\n \"null_value\": \"\\\\N\",\n \"header\": true,\n \"quote\": \"\\\"\"\n },\n \"fixture_counts\": {\n \"resources\": 28,\n \"coverage\": 3,\n \"eligibility\": 6,\n \"claims\": 10,\n \"claim_lines\": 20,\n \"adjudications\": 30,\n \"payments\": 4,\n \"plans\": 2,\n \"enrollments\": 3,\n \"resource_references\": 95,\n \"coded_values\": 101,\n \"workflow_events\": 4,\n \"cms_beneficiaries\": 3,\n \"cms_inpatient_claims\": 5,\n \"cms_carrier_claims\": 5\n },\n \"qualification\": {\n \"native_format\": \"FHIR R4 4.0.1 selected views plus independent UMF scenario events\",\n \"subset\": \"9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"limits\": \"Illustrative sources are not a validated FHIR Bundle or carrier simulation. Native official examples do not form a coherent history. CMS coverage is DE-SynPUF Sample 1, 2008 beneficiaries and 2008–2010 claims; ICD-9 remains native. Numeric CPT/Level I HCPCS carrier rows are excluded. These are synthetic public samples, not real beneficiaries. X12 services are not implemented. Reference resolution is namespace-local; no patient matching.\"\n }\n}\n", + "format": "json", + "description": "Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.", + "assets": [ + { + "id": "hl7-claim", + "reference": "sources/hl7-claim.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/hl7-claim.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "9f5772b885ed9279361b761e5483a929ece57c2e1d32ac2315ce12caef186339", + "revision": "4.0.1" + }, + { + "id": "hl7-claimresponse", + "reference": "sources/hl7-claimresponse.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/hl7-claimresponse.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "460c178f1c9248bbcb0677aa96aef9da5353be7e50f3fc84f144f03be227f3c4", + "revision": "4.0.1" + }, + { + "id": "hl7-coverage", + "reference": "sources/hl7-coverage.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/hl7-coverage.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "98fb4fcef07a290efb9e3733714f5e3f29d2943ca4367e7d3e3e59c4339bbf08", + "revision": "4.0.1" + }, + { + "id": "hl7-eligibility-request", + "reference": "sources/hl7-eligibility-request.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/hl7-eligibility-request.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "9e5e4291bec5672542d37151206a3e6433c5c764e91d8c0f927405cd6dd99612", + "revision": "4.0.1" + }, + { + "id": "hl7-eligibility-response", + "reference": "sources/hl7-eligibility-response.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/hl7-eligibility-response.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "c24cdf34a5b9609df131dd1968f7873dad451602a55f0b1185b024b14cfa7d4a", + "revision": "4.0.1" + }, + { + "id": "hl7-enrollment", + "reference": "sources/hl7-enrollment.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/hl7-enrollment.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "8d625da8606e1f1c0d179401b31d45e53888213e1583c8049f95bd36bb909cd2", + "revision": "4.0.1" + }, + { + "id": "hl7-eob", + "reference": "sources/hl7-eob.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/hl7-eob.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "d73617364c6080c39083912e22bb76162e7594611dca360412d7010e74ff68c2", + "revision": "4.0.1" + }, + { + "id": "hl7-insuranceplan", + "reference": "sources/hl7-insuranceplan.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/hl7-insuranceplan.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "5dec5d14070a0ba3a3ad9217c305b35948502fc6e1e8ca2217215c25b022fd0e", + "revision": "4.0.1" + }, + { + "id": "hl7-payment", + "reference": "sources/hl7-payment.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/hl7-payment.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "ed5674fda256ae01788491e66078869cdaef41b52261a31af9d1368bebde5a20", + "revision": "4.0.1" + }, + { + "id": "supplement-claim-authorization-approved", + "reference": "sources/supplement-claim-authorization-approved.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-claim-authorization-approved.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "526b7a991784f8a6cc35981eab28105195ef682755c5067cc45358f672b4b2ee", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-claim-authorization-denied", + "reference": "sources/supplement-claim-authorization-denied.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-claim-authorization-denied.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "ad9c085fb8d866d1bf201ba317064cec6de3a076bbe27b126688c487c1baf4dd", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-claim-paid-denied", + "reference": "sources/supplement-claim-paid-denied.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-claim-paid-denied.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "d9fe4d6e41c17e28aedb9441267dd33df33f539869fdc056ae0ba302cfb71118", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-coverage-active", + "reference": "sources/supplement-coverage-active.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-coverage-active.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "bfe0d1b789d6b5af1ce3d69cdbec59b7a289c57a8e6b3fa7f704c461a5d59ae1", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-coverage-inactive", + "reference": "sources/supplement-coverage-inactive.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-coverage-inactive.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "6bac11dd3d84828012d41bcfe073ea909ee6bb92e45f695ef83b227e8dbdd171", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-eligibility-negative-request", + "reference": "sources/supplement-eligibility-negative-request.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-eligibility-negative-request.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "26e43d4fd5ebff41ccac60f264c2c68c618efbc04ec2d25814e68d9edf75f9d2", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-eligibility-negative-response", + "reference": "sources/supplement-eligibility-negative-response.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-eligibility-negative-response.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "facfed979d36ee6ae0cb4f94c718c720fa5227999aa8751bae286c0ef96405f3", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-eligibility-positive-request", + "reference": "sources/supplement-eligibility-positive-request.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-eligibility-positive-request.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "ac8d756638c079d9fe68d46e211331c575f101edf5ff28bbf1b9605885c57525", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-eligibility-positive-response", + "reference": "sources/supplement-eligibility-positive-response.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-eligibility-positive-response.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "d8e0e9a8f9025dfac07df8546e81de2e95cd12311bfa24585c6ac131c04f7e9d", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-enrollment-request", + "reference": "sources/supplement-enrollment-request.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-enrollment-request.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "1bb28887e7ba29630b1726145813675fa9903af02fa5cd462c88ff93762f84dd", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-enrollment-response", + "reference": "sources/supplement-enrollment-response.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-enrollment-response.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "f0591ee4edbfe089ad1f5c5478b536911ecdb8f17de01d5ae87ae6f0e05d6a2e", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-eob", + "reference": "sources/supplement-eob.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-eob.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "e35a4194dab73e92de8a15613139506b7b52882f96284cf2226fe45d70f8da1a", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-patient", + "reference": "sources/supplement-patient.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-patient.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "7289f945e6acf2ce66c83e3e8a37ebfa6a6556c599d2d12336cbd51396f66424", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-payer", + "reference": "sources/supplement-payer.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-payer.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "4a43f964cbd30343e1280c92e3bb1ed37b7dfb9bf946f6bafd439a51b99a5661", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-payment", + "reference": "sources/supplement-payment.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-payment.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "36284c9df3a93a5f86cbe054435730811fa5a62e2cb233be81da0a174db672b6", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-plan", + "reference": "sources/supplement-plan.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-plan.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "d9886c0b4ce226972752ab72665824aa60c55a06c7fe6ca2ecf927326756c922", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-response-authorization-approved", + "reference": "sources/supplement-response-authorization-approved.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-response-authorization-approved.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "bd267969ba418fc87baf385946c1422f64e913aa7c6a8cc15fa4f16363c8c848", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-response-authorization-denied", + "reference": "sources/supplement-response-authorization-denied.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-response-authorization-denied.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "f709ce1bf67e2a05073a4720de39b1ec718a525cf64fbaff8f32716f33033ce5", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "supplement-response-paid-denied", + "reference": "sources/supplement-response-paid-denied.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/supplement-response-paid-denied.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "c7d4f37c7eec131f9b3474ca7e5ebabb1a8dd0be79bdaed37d9579ce3df3dae5", + "revision": "umf-scenario-1.0.0" + }, + { + "id": "workflow", + "reference": "sources/workflow-events.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/workflow-events.json", + "format": "json", + "dataKind": "fabricated", + "sha256": "bb3fae1317c8c050a802b70895d362f263d3114cc65af12fbcb639b9063abaae" + }, + { + "id": "cms_beneficiaries", + "reference": "sources/cms-beneficiaries.csv", + "url": "pack-assets/medical-carrier%401.1.0/sources/cms-beneficiaries.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "500f5a2040cb17376c130884bfafa81bcc8d5acb0a44f89aa2af8701cc2d7349", + "revision": "DE-SynPUF 1.0 Sample 1; 2008 beneficiary and 2008–2010 claims" + }, + { + "id": "cms_inpatient", + "reference": "sources/cms-inpatient.csv", + "url": "pack-assets/medical-carrier%401.1.0/sources/cms-inpatient.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "064973be1b23e48c9df9f4163502282ffc01b1094710cba588beb6d581f6d8b4", + "revision": "DE-SynPUF 1.0 Sample 1; 2008 beneficiary and 2008–2010 claims" + }, + { + "id": "cms_carrier", + "reference": "sources/cms-carrier.csv", + "url": "pack-assets/medical-carrier%401.1.0/sources/cms-carrier.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "91d44f48211ffe3a0176bcc3fc980672de5db48de1d79783935db703ed0f456d", + "revision": "DE-SynPUF 1.0 Sample 1; 2008 beneficiary and 2008–2010 claims" + }, + { + "id": "cms_selection", + "reference": "sources/cms-selection.json", + "url": "pack-assets/medical-carrier%401.1.0/sources/cms-selection.json", + "format": "json", + "dataKind": "unknown", + "sha256": "ce80cfbfeaa4899356d1877d62bf2404ff53896de7acb69cb64aed94fe5da1c5" + }, + { + "id": "notices", + "reference": "licenses/NOTICE.txt", + "url": "pack-assets/medical-carrier%401.1.0/licenses/NOTICE.txt", + "format": "text", + "dataKind": "unknown", + "sha256": "1100d7e599a36762c7159a5fdc0ca81efd19185babaa2a8ec226f970d1e7340c" + }, + { + "id": "csv_resources", + "reference": "data/resources.csv", + "url": "pack-assets/medical-carrier%401.1.0/data/resources.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "0f4a4537fc78a555ade4a8fe68709458c3b4c0f4a080b99692382dac0ef7f6e9", + "revision": "medical-carrier-1.1.0" + }, + { + "id": "csv_coverage", + "reference": "data/coverage.csv", + "url": "pack-assets/medical-carrier%401.1.0/data/coverage.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "5571b3a7a70a61dae1d771dc113c6a0a246e506f8a125de579094f3d87487eda", + "revision": "medical-carrier-1.1.0" + }, + { + "id": "csv_eligibility", + "reference": "data/eligibility.csv", + "url": "pack-assets/medical-carrier%401.1.0/data/eligibility.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "68d560d188c7fa42ac85b331de51ca04c8dd8c64611d3663cf53f5ad0f18a08a", + "revision": "medical-carrier-1.1.0" + }, + { + "id": "csv_claims", + "reference": "data/claims.csv", + "url": "pack-assets/medical-carrier%401.1.0/data/claims.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "a902b00758a4972f09f53e2e8b26f9997fdd2bea468e20a1cb7c04adebc8c703", + "revision": "medical-carrier-1.1.0" + }, + { + "id": "csv_claim_lines", + "reference": "data/claim_lines.csv", + "url": "pack-assets/medical-carrier%401.1.0/data/claim_lines.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "0bd9b58462d29869bcd8a00225f8b1b77b83c81bed04d5a8a44fe7232e94ce37", + "revision": "medical-carrier-1.1.0" + }, + { + "id": "csv_adjudications", + "reference": "data/adjudications.csv", + "url": "pack-assets/medical-carrier%401.1.0/data/adjudications.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "fa035e3b2b0dfb201414d04b7dcfdf0a7e39fed806de024b6c0be2ac352fab7f", + "revision": "medical-carrier-1.1.0" + }, + { + "id": "csv_payments", + "reference": "data/payments.csv", + "url": "pack-assets/medical-carrier%401.1.0/data/payments.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "1469a88558a7f262ef85c5fe9b4b6bda7eb7102ea92a992004f35a648ed707ec", + "revision": "medical-carrier-1.1.0" + }, + { + "id": "csv_plans", + "reference": "data/plans.csv", + "url": "pack-assets/medical-carrier%401.1.0/data/plans.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "f27ca990c8476379a6cc992083451b684eb0a1e54957aa1e985bf216b7f64034", + "revision": "medical-carrier-1.1.0" + }, + { + "id": "csv_enrollments", + "reference": "data/enrollments.csv", + "url": "pack-assets/medical-carrier%401.1.0/data/enrollments.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "5716b79011198e027a81163c62cd97c7c03af0b0b7e27308bd8d12b9c6625eb5", + "revision": "medical-carrier-1.1.0" + }, + { + "id": "csv_resource_references", + "reference": "data/resource_references.csv", + "url": "pack-assets/medical-carrier%401.1.0/data/resource_references.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "1da6ebc223e723755b8476306fb5e8050aa3d0e384fa7048ecc6c26a7aae0aaf", + "revision": "medical-carrier-1.1.0" + }, + { + "id": "csv_coded_values", + "reference": "data/coded_values.csv", + "url": "pack-assets/medical-carrier%401.1.0/data/coded_values.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "5eeeeb39af2f52c42959c071208ad18f9f8ba335865b5a3703d2df85677b0b48", + "revision": "medical-carrier-1.1.0" + }, + { + "id": "csv_workflow_events", + "reference": "data/workflow_events.csv", + "url": "pack-assets/medical-carrier%401.1.0/data/workflow_events.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "b27e0b1d336915c55ee950bb82b0cbf6f9cc86799ed6a0babd4ce3d6452f83cb", + "revision": "medical-carrier-1.1.0" + }, + { + "id": "csv_cms_beneficiaries", + "reference": "data/cms_beneficiaries.csv", + "url": "pack-assets/medical-carrier%401.1.0/data/cms_beneficiaries.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "682d408b477eba199e96c853c7982c0157881768a5b8e7be896a75ca1a91e82e", + "revision": "medical-carrier-1.1.0" + }, + { + "id": "csv_cms_inpatient_claims", + "reference": "data/cms_inpatient_claims.csv", + "url": "pack-assets/medical-carrier%401.1.0/data/cms_inpatient_claims.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "281f8484b788cdfd0c3545740374675c9b69c350f25b64dd0f9aa26ce8ffdfa8", + "revision": "medical-carrier-1.1.0" + }, + { + "id": "csv_cms_carrier_claims", + "reference": "data/cms_carrier_claims.csv", + "url": "pack-assets/medical-carrier%401.1.0/data/cms_carrier_claims.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "a3175dadf541162ed006f3b768cc95c3aad7c06e5ca90bd79b4edebef2138401", + "revision": "medical-carrier-1.1.0" + } + ], + "aliases": [ + "pack:medical-carrier@1.0.0" + ] + }, + { + "id": "schema:medical-carrier@1.1.0:resources", "title": "resources", "category": "domain", "path": "umf/resources.json", "pack": "medical-carrier", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", - "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"resources\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"source_id\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"source id\"\n },\n {\n \"name\": \"resource_type\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource type\"\n },\n {\n \"name\": \"native_id\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native id\"\n },\n {\n \"name\": \"resource_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"resource json\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ]\n}\n", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"resources\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"source_id\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"source id\"\n },\n {\n \"name\": \"resource_type\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource type\"\n },\n {\n \"name\": \"native_id\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native id\"\n },\n {\n \"name\": \"resource_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"resource json\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ]\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-carrier/umf/resources.json" + "spec/domain-packs/medical-carrier/umf/resources.json", + "schema:medical-carrier@1.0.0:resources" ] }, { - "id": "schema:medical-carrier@1.0.0:coverage", + "id": "schema:medical-carrier@1.1.0:coverage", "title": "coverage", "category": "domain", "path": "umf/coverage.json", "pack": "medical-carrier", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", - "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"coverage\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"status\"\n },\n {\n \"name\": \"beneficiary_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"beneficiary json\"\n },\n {\n \"name\": \"subscriber_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"subscriber json\"\n },\n {\n \"name\": \"payors_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"payors json\"\n },\n {\n \"name\": \"classes_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"classes json\"\n },\n {\n \"name\": \"period_start\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"period start\"\n },\n {\n \"name\": \"period_end\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"period end\"\n },\n {\n \"name\": \"benefits_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"benefits json\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"coverage\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"status\"\n },\n {\n \"name\": \"beneficiary_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"beneficiary json\"\n },\n {\n \"name\": \"subscriber_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"subscriber json\"\n },\n {\n \"name\": \"payors_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"payors json\"\n },\n {\n \"name\": \"classes_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"classes json\"\n },\n {\n \"name\": \"period_start\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"period start\"\n },\n {\n \"name\": \"period_end\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"period end\"\n },\n {\n \"name\": \"benefits_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"benefits json\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-carrier/umf/coverage.json" + "spec/domain-packs/medical-carrier/umf/coverage.json", + "schema:medical-carrier@1.0.0:coverage" ] }, { - "id": "schema:medical-carrier@1.0.0:eligibility", + "id": "schema:medical-carrier@1.1.0:eligibility", "title": "eligibility", "category": "domain", "path": "umf/eligibility.json", "pack": "medical-carrier", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", - "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"eligibility\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"status\"\n },\n {\n \"name\": \"patient_reference\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"patient reference\"\n },\n {\n \"name\": \"direction\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"direction\"\n },\n {\n \"name\": \"purpose_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"purpose json\"\n },\n {\n \"name\": \"created\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"created\"\n },\n {\n \"name\": \"serviced_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"serviced json\"\n },\n {\n \"name\": \"request_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"request json\"\n },\n {\n \"name\": \"outcome\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"outcome\"\n },\n {\n \"name\": \"insurance_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"insurance json\"\n },\n {\n \"name\": \"items_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"items json\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"eligibility\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"status\"\n },\n {\n \"name\": \"patient_reference\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"patient reference\"\n },\n {\n \"name\": \"direction\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"direction\"\n },\n {\n \"name\": \"purpose_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"purpose json\"\n },\n {\n \"name\": \"created\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"created\"\n },\n {\n \"name\": \"serviced_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"serviced json\"\n },\n {\n \"name\": \"request_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"request json\"\n },\n {\n \"name\": \"outcome\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"outcome\"\n },\n {\n \"name\": \"insurance_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"insurance json\"\n },\n {\n \"name\": \"items_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"items json\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-carrier/umf/eligibility.json" + "spec/domain-packs/medical-carrier/umf/eligibility.json", + "schema:medical-carrier@1.0.0:eligibility" ] }, { - "id": "schema:medical-carrier@1.0.0:claims", + "id": "schema:medical-carrier@1.1.0:claims", "title": "claims", "category": "domain", "path": "umf/claims.json", "pack": "medical-carrier", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", - "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"claims\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"status\"\n },\n {\n \"name\": \"patient_reference\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"patient reference\"\n },\n {\n \"name\": \"resource_type\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource type\"\n },\n {\n \"name\": \"use\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"use\"\n },\n {\n \"name\": \"type_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"type json\"\n },\n {\n \"name\": \"created\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"created\"\n },\n {\n \"name\": \"outcome\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"outcome\"\n },\n {\n \"name\": \"request_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"request json\"\n },\n {\n \"name\": \"insurance_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"insurance json\"\n },\n {\n \"name\": \"diagnoses_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"diagnoses json\"\n },\n {\n \"name\": \"procedures_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"procedures json\"\n },\n {\n \"name\": \"related_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"related json\"\n },\n {\n \"name\": \"totals_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"totals json\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"claims\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"status\"\n },\n {\n \"name\": \"patient_reference\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"patient reference\"\n },\n {\n \"name\": \"resource_type\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource type\"\n },\n {\n \"name\": \"use\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"use\"\n },\n {\n \"name\": \"type_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"type json\"\n },\n {\n \"name\": \"created\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"created\"\n },\n {\n \"name\": \"outcome\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"outcome\"\n },\n {\n \"name\": \"request_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"request json\"\n },\n {\n \"name\": \"insurance_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"insurance json\"\n },\n {\n \"name\": \"diagnoses_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"diagnoses json\"\n },\n {\n \"name\": \"procedures_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"procedures json\"\n },\n {\n \"name\": \"related_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"related json\"\n },\n {\n \"name\": \"totals_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"totals json\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-carrier/umf/claims.json" + "spec/domain-packs/medical-carrier/umf/claims.json", + "schema:medical-carrier@1.0.0:claims" ] }, { - "id": "schema:medical-carrier@1.0.0:claim_lines", + "id": "schema:medical-carrier@1.1.0:claim_lines", "title": "claim_lines", "category": "domain", "path": "umf/claim_lines.json", "pack": "medical-carrier", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", - "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"claim_lines\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.\",\n \"columns\": [\n {\n \"name\": \"line_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"line key\"\n },\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"parent_line_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"parent line key\"\n },\n {\n \"name\": \"native_path\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native path\"\n },\n {\n \"name\": \"sequence\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"sequence\"\n },\n {\n \"name\": \"product_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"product json\"\n },\n {\n \"name\": \"modifiers_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"modifiers json\"\n },\n {\n \"name\": \"service_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"service json\"\n },\n {\n \"name\": \"quantity\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"quantity\"\n },\n {\n \"name\": \"unit_price\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"unit price\"\n },\n {\n \"name\": \"net_amount\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"net amount\"\n },\n {\n \"name\": \"net_currency\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"net currency\"\n },\n {\n \"name\": \"line_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"line json\"\n }\n ],\n \"primary_key\": [\n \"line_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n },\n {\n \"column\": \"parent_line_key\",\n \"references_table\": \"claim_lines\",\n \"references_column\": \"line_key\"\n }\n ]\n }\n}\n", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"claim_lines\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"columns\": [\n {\n \"name\": \"line_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"line key\"\n },\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"parent_line_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"parent line key\"\n },\n {\n \"name\": \"native_path\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native path\"\n },\n {\n \"name\": \"sequence\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"sequence\"\n },\n {\n \"name\": \"product_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"product json\"\n },\n {\n \"name\": \"modifiers_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"modifiers json\"\n },\n {\n \"name\": \"service_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"service json\"\n },\n {\n \"name\": \"quantity\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"quantity\"\n },\n {\n \"name\": \"unit_price\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"unit price\"\n },\n {\n \"name\": \"net_amount\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"net amount\"\n },\n {\n \"name\": \"net_currency\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"net currency\"\n },\n {\n \"name\": \"line_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"line json\"\n }\n ],\n \"primary_key\": [\n \"line_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n },\n {\n \"column\": \"parent_line_key\",\n \"references_table\": \"claim_lines\",\n \"references_column\": \"line_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-carrier/umf/claim_lines.json" + "spec/domain-packs/medical-carrier/umf/claim_lines.json", + "schema:medical-carrier@1.0.0:claim_lines" ] }, { - "id": "schema:medical-carrier@1.0.0:adjudications", + "id": "schema:medical-carrier@1.1.0:adjudications", "title": "adjudications", "category": "domain", "path": "umf/adjudications.json", "pack": "medical-carrier", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", - "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"adjudications\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.\",\n \"columns\": [\n {\n \"name\": \"adjudication_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"adjudication key\"\n },\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"line_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"line key\"\n },\n {\n \"name\": \"category_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"category json\"\n },\n {\n \"name\": \"reason_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"reason json\"\n },\n {\n \"name\": \"amount\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"amount\"\n },\n {\n \"name\": \"currency\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"currency\"\n },\n {\n \"name\": \"value\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"value\"\n },\n {\n \"name\": \"native_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"native json\"\n }\n ],\n \"primary_key\": [\n \"adjudication_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n },\n {\n \"column\": \"line_key\",\n \"references_table\": \"claim_lines\",\n \"references_column\": \"line_key\"\n }\n ]\n }\n}\n", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"adjudications\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"columns\": [\n {\n \"name\": \"adjudication_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"adjudication key\"\n },\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"line_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"line key\"\n },\n {\n \"name\": \"category_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"category json\"\n },\n {\n \"name\": \"reason_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"reason json\"\n },\n {\n \"name\": \"amount\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"amount\"\n },\n {\n \"name\": \"currency\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"currency\"\n },\n {\n \"name\": \"value\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"value\"\n },\n {\n \"name\": \"native_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"native json\"\n }\n ],\n \"primary_key\": [\n \"adjudication_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n },\n {\n \"column\": \"line_key\",\n \"references_table\": \"claim_lines\",\n \"references_column\": \"line_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-carrier/umf/adjudications.json" + "spec/domain-packs/medical-carrier/umf/adjudications.json", + "schema:medical-carrier@1.0.0:adjudications" ] }, { - "id": "schema:medical-carrier@1.0.0:payments", + "id": "schema:medical-carrier@1.1.0:payments", "title": "payments", "category": "domain", "path": "umf/payments.json", "pack": "medical-carrier", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", - "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"payments\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.\",\n \"columns\": [\n {\n \"name\": \"payment_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"payment key\"\n },\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"date\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"date\"\n },\n {\n \"name\": \"amount\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"amount\"\n },\n {\n \"name\": \"currency\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"currency\"\n },\n {\n \"name\": \"allocations_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"allocations json\"\n },\n {\n \"name\": \"native_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"native json\"\n }\n ],\n \"primary_key\": [\n \"payment_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"payments\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"columns\": [\n {\n \"name\": \"payment_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"payment key\"\n },\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"date\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"date\"\n },\n {\n \"name\": \"amount\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"amount\"\n },\n {\n \"name\": \"currency\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"currency\"\n },\n {\n \"name\": \"allocations_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"allocations json\"\n },\n {\n \"name\": \"native_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"native json\"\n }\n ],\n \"primary_key\": [\n \"payment_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-carrier/umf/payments.json" + "spec/domain-packs/medical-carrier/umf/payments.json", + "schema:medical-carrier@1.0.0:payments" ] }, { - "id": "schema:medical-carrier@1.0.0:plans", + "id": "schema:medical-carrier@1.1.0:plans", "title": "plans", "category": "domain", "path": "umf/plans.json", "pack": "medical-carrier", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", - "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"plans\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"status\"\n },\n {\n \"name\": \"name\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"name\"\n },\n {\n \"name\": \"period_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"period json\"\n },\n {\n \"name\": \"owner_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"owner json\"\n },\n {\n \"name\": \"coverage_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"coverage json\"\n },\n {\n \"name\": \"plans_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"plans json\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"plans\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"status\"\n },\n {\n \"name\": \"name\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"name\"\n },\n {\n \"name\": \"period_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"period json\"\n },\n {\n \"name\": \"owner_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"owner json\"\n },\n {\n \"name\": \"coverage_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"coverage json\"\n },\n {\n \"name\": \"plans_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"plans json\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-carrier/umf/plans.json" + "spec/domain-packs/medical-carrier/umf/plans.json", + "schema:medical-carrier@1.0.0:plans" ] }, { - "id": "schema:medical-carrier@1.0.0:enrollments", + "id": "schema:medical-carrier@1.1.0:enrollments", "title": "enrollments", "category": "domain", "path": "umf/enrollments.json", "pack": "medical-carrier", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", - "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"enrollments\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"direction\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"direction\"\n },\n {\n \"name\": \"status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"status\"\n },\n {\n \"name\": \"created\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"created\"\n },\n {\n \"name\": \"candidate_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"candidate json\"\n },\n {\n \"name\": \"coverage_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"coverage json\"\n },\n {\n \"name\": \"request_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"request json\"\n },\n {\n \"name\": \"outcome\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"outcome\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"enrollments\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"direction\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"direction\"\n },\n {\n \"name\": \"status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"status\"\n },\n {\n \"name\": \"created\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"created\"\n },\n {\n \"name\": \"candidate_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"candidate json\"\n },\n {\n \"name\": \"coverage_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"coverage json\"\n },\n {\n \"name\": \"request_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"request json\"\n },\n {\n \"name\": \"outcome\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"outcome\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-carrier/umf/enrollments.json" + "spec/domain-packs/medical-carrier/umf/enrollments.json", + "schema:medical-carrier@1.0.0:enrollments" ] }, { - "id": "schema:medical-carrier@1.0.0:resource_references", + "id": "schema:medical-carrier@1.1.0:resource_references", "title": "resource_references", "category": "domain", "path": "umf/resource_references.json", "pack": "medical-carrier", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", - "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"resource_references\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.\",\n \"columns\": [\n {\n \"name\": \"reference_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"reference key\"\n },\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"native_path\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native path\"\n },\n {\n \"name\": \"native_reference\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native reference\"\n },\n {\n \"name\": \"target_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"target key\"\n }\n ],\n \"primary_key\": [\n \"reference_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n },\n {\n \"column\": \"target_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"resource_references\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"columns\": [\n {\n \"name\": \"reference_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"reference key\"\n },\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"native_path\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native path\"\n },\n {\n \"name\": \"native_reference\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native reference\"\n },\n {\n \"name\": \"target_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"target key\"\n }\n ],\n \"primary_key\": [\n \"reference_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n },\n {\n \"column\": \"target_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-carrier/umf/resource_references.json" + "spec/domain-packs/medical-carrier/umf/resource_references.json", + "schema:medical-carrier@1.0.0:resource_references" ] }, { - "id": "schema:medical-carrier@1.0.0:coded_values", + "id": "schema:medical-carrier@1.1.0:coded_values", "title": "coded_values", "category": "domain", "path": "umf/coded_values.json", "pack": "medical-carrier", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", - "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"coded_values\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.\",\n \"columns\": [\n {\n \"name\": \"coding_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"coding key\"\n },\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"native_path\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native path\"\n },\n {\n \"name\": \"system\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"system\"\n },\n {\n \"name\": \"release\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"release\"\n },\n {\n \"name\": \"code\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"code\"\n },\n {\n \"name\": \"display\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"display\"\n },\n {\n \"name\": \"native_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"native json\"\n }\n ],\n \"primary_key\": [\n \"coding_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"coded_values\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"columns\": [\n {\n \"name\": \"coding_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"coding key\"\n },\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"native_path\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native path\"\n },\n {\n \"name\": \"system\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"system\"\n },\n {\n \"name\": \"release\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"release\"\n },\n {\n \"name\": \"code\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"code\"\n },\n {\n \"name\": \"display\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"display\"\n },\n {\n \"name\": \"native_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"native json\"\n }\n ],\n \"primary_key\": [\n \"coding_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-carrier/umf/coded_values.json" + "spec/domain-packs/medical-carrier/umf/coded_values.json", + "schema:medical-carrier@1.0.0:coded_values" ] }, { - "id": "schema:medical-carrier@1.0.0:workflow_events", + "id": "schema:medical-carrier@1.1.0:workflow_events", "title": "workflow_events", "category": "domain", "path": "umf/workflow_events.json", "pack": "medical-carrier", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", - "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"workflow_events\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.\",\n \"columns\": [\n {\n \"name\": \"event_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"event key\"\n },\n {\n \"name\": \"event_type\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"event type\"\n },\n {\n \"name\": \"subject_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"subject key\"\n },\n {\n \"name\": \"claim_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"claim key\"\n },\n {\n \"name\": \"prior_event_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"prior event key\"\n },\n {\n \"name\": \"date\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"date\"\n },\n {\n \"name\": \"status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"status\"\n },\n {\n \"name\": \"amount\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"amount\"\n },\n {\n \"name\": \"currency\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"currency\"\n },\n {\n \"name\": \"details_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"details json\"\n }\n ],\n \"primary_key\": [\n \"event_key\"\n ]\n}\n", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"workflow_events\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"columns\": [\n {\n \"name\": \"event_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"event key\"\n },\n {\n \"name\": \"event_type\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"event type\"\n },\n {\n \"name\": \"subject_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"subject key\"\n },\n {\n \"name\": \"claim_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"claim key\"\n },\n {\n \"name\": \"prior_event_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"prior event key\"\n },\n {\n \"name\": \"date\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"date\"\n },\n {\n \"name\": \"status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"status\"\n },\n {\n \"name\": \"amount\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"amount\"\n },\n {\n \"name\": \"currency\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"currency\"\n },\n {\n \"name\": \"details_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"details json\"\n }\n ],\n \"primary_key\": [\n \"event_key\"\n ]\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-carrier/umf/workflow_events.json" + "spec/domain-packs/medical-carrier/umf/workflow_events.json", + "schema:medical-carrier@1.0.0:workflow_events" ] }, { - "id": "pack:medical-epidemiology@1.0.0", - "title": "medical-epidemiology", + "id": "schema:medical-carrier@1.1.0:cms_beneficiaries", + "title": "cms_beneficiaries", "category": "domain", - "path": "domain-pack.json", - "pack": "medical-epidemiology", - "packVersion": "1.0.0", - "text": "{\n \"id\": \"medical-epidemiology\",\n \"version\": \"1.0.0\",\n \"description\": \"Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.\",\n \"domain_types\": {\n \"source_qualified_identity\": {\n \"description\": \"Source namespace and native identity; no inferred patient identity.\"\n },\n \"exact_native_literal\": {\n \"description\": \"Numeric and temporal source spelling retained as text.\"\n }\n },\n \"schemas\": [\n {\n \"id\": \"measures\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/measures.json\"\n },\n {\n \"id\": \"supplemental_measures\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/supplemental_measures.json\"\n }\n ],\n \"sources\": {\n \"cdc\": {\n \"kind\": \"external\",\n \"data_kind\": \"observed\",\n \"reference\": \"sources/cdc-mortality.json\",\n \"format\": \"json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"8a21a792545b670db71b8a53b86b09d75bc471f9c327c5079e47d2c6a74701e4\"\n },\n \"license\": {\n \"id\": \"USGOV_WORKS\",\n \"reference\": \"https://data.cdc.gov/api/views/bi63-dtpu.json\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"CDC/NCHS\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://data.cdc.gov/resource/bi63-dtpu.json?$limit=12&$order=year,state,cause_name\",\n \"transformations\": []\n },\n \"revision\": \"bi63-dtpu-rowsUpdatedAt-1571926785\"\n },\n \"cdc_metadata\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"sources/cdc-metadata.json\",\n \"format\": \"json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"abd2439f7c8f43d9cc551bf9fcb805fb191f57385d69a2250ef6619a9b5b3592\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"CDC/NCHS\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"supplement\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement.json\",\n \"format\": \"json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"847575df6aacdc8e2aa007267125f8d3729d6946b6ee8eb8380597fc20c7823b\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"wonder\": {\n \"kind\": \"external\",\n \"data_kind\": \"observed\",\n \"reference\": \"https://wonder.cdc.gov/\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"CDC/NCHS\"\n }\n },\n \"notices\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"format\": \"text\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"fd61c614ae31a5b53877fc0f4246c3f444057f58fb1c0df9f6772bf1b2e77978\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"csv_measures\": {\n \"kind\": \"external\",\n \"data_kind\": \"observed\",\n \"reference\": \"data/measures.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-epidemiology-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"be23947804729c7a64bb5b5d0071a20e5bba619d27cfaa5504188482969f71ab\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"cdc\",\n \"cdc_metadata\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_supplemental_measures\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/supplemental_measures.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-epidemiology-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"05cd03ec8cf05416a2cf296b5272b0540bd87ffd0e44cfc6399c1f93524de415\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"supplement\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n }\n },\n \"source_bindings\": [\n {\n \"schema_id\": \"measures\",\n \"source_id\": \"csv_measures\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"measures\",\n \"source_id\": \"cdc\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"measures\",\n \"source_id\": \"cdc_metadata\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"supplemental_measures\",\n \"source_id\": \"csv_supplemental_measures\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"supplemental_measures\",\n \"source_id\": \"supplement\",\n \"role\": \"reference\"\n }\n ],\n \"csv_conventions\": {\n \"encoding\": \"UTF-8\",\n \"null_value\": \"\\\\N\",\n \"header\": true,\n \"quote\": \"\\\"\"\n },\n \"fixture_counts\": {\n \"measures\": 12,\n \"supplemental_measures\": 2\n },\n \"qualification\": {\n \"subset\": \"12 CDC/NCHS leading-causes-of-death aggregate records and two separate fabricated zero/suppression cases.\",\n \"limits\": \"Observed deaths and age-adjusted rates use native international ICD-10 cause groups, not ICD-10-CM billing diagnoses. Source rows omit denominators and uncertainty. No rate recomputation, inference of patients, epidemiological comparability or current-year surveillance is claimed.\"\n }\n}\n", + "path": "umf/cms_beneficiaries.json", + "pack": "medical-carrier", + "packVersion": "1.1.0", + "schemaFormat": "tablespec", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"cms_beneficiaries\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"columns\": [\n {\n \"name\": \"DESYNPUF_ID\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"DESYNPUF ID\"\n },\n {\n \"name\": \"BENE_BIRTH_DT\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"BENE BIRTH DT\"\n },\n {\n \"name\": \"BENE_DEATH_DT\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"BENE DEATH DT\"\n },\n {\n \"name\": \"BENE_SEX_IDENT_CD\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"BENE SEX IDENT CD\"\n },\n {\n \"name\": \"BENE_RACE_CD\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"BENE RACE CD\"\n },\n {\n \"name\": \"BENE_ESRD_IND\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"BENE ESRD IND\"\n },\n {\n \"name\": \"SP_STATE_CODE\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"SP STATE CODE\"\n },\n {\n \"name\": \"BENE_COUNTY_CD\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"BENE COUNTY CD\"\n },\n {\n \"name\": \"BENE_HI_CVRAGE_TOT_MONS\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"BENE HI CVRAGE TOT MONS\"\n },\n {\n \"name\": \"BENE_SMI_CVRAGE_TOT_MONS\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"BENE SMI CVRAGE TOT MONS\"\n },\n {\n \"name\": \"BENE_HMO_CVRAGE_TOT_MONS\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"BENE HMO CVRAGE TOT MONS\"\n },\n {\n \"name\": \"PLAN_CVRG_MOS_NUM\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PLAN CVRG MOS NUM\"\n },\n {\n \"name\": \"SP_ALZHDMTA\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"SP ALZHDMTA\"\n },\n {\n \"name\": \"SP_CHF\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"SP CHF\"\n },\n {\n \"name\": \"SP_CHRNKIDN\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"SP CHRNKIDN\"\n },\n {\n \"name\": \"SP_CNCR\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"SP CNCR\"\n },\n {\n \"name\": \"SP_COPD\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"SP COPD\"\n },\n {\n \"name\": \"SP_DEPRESSN\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"SP DEPRESSN\"\n },\n {\n \"name\": \"SP_DIABETES\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"SP DIABETES\"\n },\n {\n \"name\": \"SP_ISCHMCHT\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"SP ISCHMCHT\"\n },\n {\n \"name\": \"SP_OSTEOPRS\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"SP OSTEOPRS\"\n },\n {\n \"name\": \"SP_RA_OA\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"SP RA OA\"\n },\n {\n \"name\": \"SP_STRKETIA\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"SP STRKETIA\"\n },\n {\n \"name\": \"MEDREIMB_IP\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"MEDREIMB IP\"\n },\n {\n \"name\": \"BENRES_IP\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"BENRES IP\"\n },\n {\n \"name\": \"PPPYMT_IP\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PPPYMT IP\"\n },\n {\n \"name\": \"MEDREIMB_OP\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"MEDREIMB OP\"\n },\n {\n \"name\": \"BENRES_OP\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"BENRES OP\"\n },\n {\n \"name\": \"PPPYMT_OP\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PPPYMT OP\"\n },\n {\n \"name\": \"MEDREIMB_CAR\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"MEDREIMB CAR\"\n },\n {\n \"name\": \"BENRES_CAR\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"BENRES CAR\"\n },\n {\n \"name\": \"PPPYMT_CAR\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PPPYMT CAR\"\n },\n {\n \"name\": \"native_record_number\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native record number\"\n },\n {\n \"name\": \"native_csv_record\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native csv record\"\n }\n ],\n \"primary_key\": [\n \"DESYNPUF_ID\"\n ]\n}\n", "format": "json", - "description": "Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence." + "aliases": [ + "spec/domain-packs/medical-carrier/umf/cms_beneficiaries.json", + "schema:medical-carrier@1.0.0:cms_beneficiaries" + ] + }, + { + "id": "schema:medical-carrier@1.1.0:cms_inpatient_claims", + "title": "cms_inpatient_claims", + "category": "domain", + "path": "umf/cms_inpatient_claims.json", + "pack": "medical-carrier", + "packVersion": "1.1.0", + "schemaFormat": "tablespec", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"cms_inpatient_claims\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"columns\": [\n {\n \"name\": \"DESYNPUF_ID\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"DESYNPUF ID\"\n },\n {\n \"name\": \"CLM_ID\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"CLM ID\"\n },\n {\n \"name\": \"SEGMENT\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"SEGMENT\"\n },\n {\n \"name\": \"CLM_FROM_DT\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"CLM FROM DT\"\n },\n {\n \"name\": \"CLM_THRU_DT\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"CLM THRU DT\"\n },\n {\n \"name\": \"PRVDR_NUM\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PRVDR NUM\"\n },\n {\n \"name\": \"CLM_PMT_AMT\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"CLM PMT AMT\"\n },\n {\n \"name\": \"NCH_PRMRY_PYR_CLM_PD_AMT\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"NCH PRMRY PYR CLM PD AMT\"\n },\n {\n \"name\": \"AT_PHYSN_NPI\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"AT PHYSN NPI\"\n },\n {\n \"name\": \"OP_PHYSN_NPI\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"OP PHYSN NPI\"\n },\n {\n \"name\": \"OT_PHYSN_NPI\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"OT PHYSN NPI\"\n },\n {\n \"name\": \"CLM_ADMSN_DT\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"CLM ADMSN DT\"\n },\n {\n \"name\": \"ADMTNG_ICD9_DGNS_CD\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ADMTNG ICD9 DGNS CD\"\n },\n {\n \"name\": \"CLM_PASS_THRU_PER_DIEM_AMT\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"CLM PASS THRU PER DIEM AMT\"\n },\n {\n \"name\": \"NCH_BENE_IP_DDCTBL_AMT\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"NCH BENE IP DDCTBL AMT\"\n },\n {\n \"name\": \"NCH_BENE_PTA_COINSRNC_LBLTY_AM\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"NCH BENE PTA COINSRNC LBLTY AM\"\n },\n {\n \"name\": \"NCH_BENE_BLOOD_DDCTBL_LBLTY_AM\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"NCH BENE BLOOD DDCTBL LBLTY AM\"\n },\n {\n \"name\": \"CLM_UTLZTN_DAY_CNT\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"CLM UTLZTN DAY CNT\"\n },\n {\n \"name\": \"NCH_BENE_DSCHRG_DT\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"NCH BENE DSCHRG DT\"\n },\n {\n \"name\": \"CLM_DRG_CD\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"CLM DRG CD\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_1\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 1\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_2\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 2\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_3\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 3\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_4\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 4\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_5\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 5\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_6\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 6\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_7\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 7\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_8\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 8\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_9\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 9\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_10\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 10\"\n },\n {\n \"name\": \"ICD9_PRCDR_CD_1\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 PRCDR CD 1\"\n },\n {\n \"name\": \"ICD9_PRCDR_CD_2\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 PRCDR CD 2\"\n },\n {\n \"name\": \"ICD9_PRCDR_CD_3\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 PRCDR CD 3\"\n },\n {\n \"name\": \"ICD9_PRCDR_CD_4\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 PRCDR CD 4\"\n },\n {\n \"name\": \"ICD9_PRCDR_CD_5\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 PRCDR CD 5\"\n },\n {\n \"name\": \"ICD9_PRCDR_CD_6\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 PRCDR CD 6\"\n },\n {\n \"name\": \"HCPCS_CD_1\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 1\"\n },\n {\n \"name\": \"HCPCS_CD_2\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 2\"\n },\n {\n \"name\": \"HCPCS_CD_3\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 3\"\n },\n {\n \"name\": \"HCPCS_CD_4\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 4\"\n },\n {\n \"name\": \"HCPCS_CD_5\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 5\"\n },\n {\n \"name\": \"HCPCS_CD_6\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 6\"\n },\n {\n \"name\": \"HCPCS_CD_7\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 7\"\n },\n {\n \"name\": \"HCPCS_CD_8\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 8\"\n },\n {\n \"name\": \"HCPCS_CD_9\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 9\"\n },\n {\n \"name\": \"HCPCS_CD_10\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 10\"\n },\n {\n \"name\": \"HCPCS_CD_11\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 11\"\n },\n {\n \"name\": \"HCPCS_CD_12\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 12\"\n },\n {\n \"name\": \"HCPCS_CD_13\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 13\"\n },\n {\n \"name\": \"HCPCS_CD_14\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 14\"\n },\n {\n \"name\": \"HCPCS_CD_15\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 15\"\n },\n {\n \"name\": \"HCPCS_CD_16\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 16\"\n },\n {\n \"name\": \"HCPCS_CD_17\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 17\"\n },\n {\n \"name\": \"HCPCS_CD_18\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 18\"\n },\n {\n \"name\": \"HCPCS_CD_19\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 19\"\n },\n {\n \"name\": \"HCPCS_CD_20\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 20\"\n },\n {\n \"name\": \"HCPCS_CD_21\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 21\"\n },\n {\n \"name\": \"HCPCS_CD_22\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 22\"\n },\n {\n \"name\": \"HCPCS_CD_23\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 23\"\n },\n {\n \"name\": \"HCPCS_CD_24\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 24\"\n },\n {\n \"name\": \"HCPCS_CD_25\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 25\"\n },\n {\n \"name\": \"HCPCS_CD_26\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 26\"\n },\n {\n \"name\": \"HCPCS_CD_27\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 27\"\n },\n {\n \"name\": \"HCPCS_CD_28\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 28\"\n },\n {\n \"name\": \"HCPCS_CD_29\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 29\"\n },\n {\n \"name\": \"HCPCS_CD_30\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 30\"\n },\n {\n \"name\": \"HCPCS_CD_31\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 31\"\n },\n {\n \"name\": \"HCPCS_CD_32\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 32\"\n },\n {\n \"name\": \"HCPCS_CD_33\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 33\"\n },\n {\n \"name\": \"HCPCS_CD_34\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 34\"\n },\n {\n \"name\": \"HCPCS_CD_35\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 35\"\n },\n {\n \"name\": \"HCPCS_CD_36\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 36\"\n },\n {\n \"name\": \"HCPCS_CD_37\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 37\"\n },\n {\n \"name\": \"HCPCS_CD_38\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 38\"\n },\n {\n \"name\": \"HCPCS_CD_39\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 39\"\n },\n {\n \"name\": \"HCPCS_CD_40\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 40\"\n },\n {\n \"name\": \"HCPCS_CD_41\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 41\"\n },\n {\n \"name\": \"HCPCS_CD_42\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 42\"\n },\n {\n \"name\": \"HCPCS_CD_43\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 43\"\n },\n {\n \"name\": \"HCPCS_CD_44\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 44\"\n },\n {\n \"name\": \"HCPCS_CD_45\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 45\"\n },\n {\n \"name\": \"native_record_number\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native record number\"\n },\n {\n \"name\": \"native_csv_record\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native csv record\"\n }\n ],\n \"primary_key\": [\n \"CLM_ID\",\n \"SEGMENT\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"DESYNPUF_ID\",\n \"references_table\": \"cms_beneficiaries\",\n \"references_column\": \"DESYNPUF_ID\"\n }\n ]\n }\n}\n", + "format": "json", + "aliases": [ + "spec/domain-packs/medical-carrier/umf/cms_inpatient_claims.json", + "schema:medical-carrier@1.0.0:cms_inpatient_claims" + ] + }, + { + "id": "schema:medical-carrier@1.1.0:cms_carrier_claims", + "title": "cms_carrier_claims", + "category": "domain", + "path": "umf/cms_carrier_claims.json", + "pack": "medical-carrier", + "packVersion": "1.1.0", + "schemaFormat": "tablespec", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"cms_carrier_claims\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"columns\": [\n {\n \"name\": \"DESYNPUF_ID\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"DESYNPUF ID\"\n },\n {\n \"name\": \"CLM_ID\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"CLM ID\"\n },\n {\n \"name\": \"CLM_FROM_DT\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"CLM FROM DT\"\n },\n {\n \"name\": \"CLM_THRU_DT\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"CLM THRU DT\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_1\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 1\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_2\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 2\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_3\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 3\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_4\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 4\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_5\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 5\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_6\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 6\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_7\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 7\"\n },\n {\n \"name\": \"ICD9_DGNS_CD_8\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"ICD9 DGNS CD 8\"\n },\n {\n \"name\": \"PRF_PHYSN_NPI_1\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PRF PHYSN NPI 1\"\n },\n {\n \"name\": \"PRF_PHYSN_NPI_2\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PRF PHYSN NPI 2\"\n },\n {\n \"name\": \"PRF_PHYSN_NPI_3\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PRF PHYSN NPI 3\"\n },\n {\n \"name\": \"PRF_PHYSN_NPI_4\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PRF PHYSN NPI 4\"\n },\n {\n \"name\": \"PRF_PHYSN_NPI_5\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PRF PHYSN NPI 5\"\n },\n {\n \"name\": \"PRF_PHYSN_NPI_6\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PRF PHYSN NPI 6\"\n },\n {\n \"name\": \"PRF_PHYSN_NPI_7\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PRF PHYSN NPI 7\"\n },\n {\n \"name\": \"PRF_PHYSN_NPI_8\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PRF PHYSN NPI 8\"\n },\n {\n \"name\": \"PRF_PHYSN_NPI_9\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PRF PHYSN NPI 9\"\n },\n {\n \"name\": \"PRF_PHYSN_NPI_10\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PRF PHYSN NPI 10\"\n },\n {\n \"name\": \"PRF_PHYSN_NPI_11\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PRF PHYSN NPI 11\"\n },\n {\n \"name\": \"PRF_PHYSN_NPI_12\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PRF PHYSN NPI 12\"\n },\n {\n \"name\": \"PRF_PHYSN_NPI_13\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"PRF PHYSN NPI 13\"\n },\n {\n \"name\": \"TAX_NUM_1\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"TAX NUM 1\"\n },\n {\n \"name\": \"TAX_NUM_2\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"TAX NUM 2\"\n },\n {\n \"name\": \"TAX_NUM_3\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"TAX NUM 3\"\n },\n {\n \"name\": \"TAX_NUM_4\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"TAX NUM 4\"\n },\n {\n \"name\": \"TAX_NUM_5\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"TAX NUM 5\"\n },\n {\n \"name\": \"TAX_NUM_6\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"TAX NUM 6\"\n },\n {\n \"name\": \"TAX_NUM_7\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"TAX NUM 7\"\n },\n {\n \"name\": \"TAX_NUM_8\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"TAX NUM 8\"\n },\n {\n \"name\": \"TAX_NUM_9\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"TAX NUM 9\"\n },\n {\n \"name\": \"TAX_NUM_10\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"TAX NUM 10\"\n },\n {\n \"name\": \"TAX_NUM_11\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"TAX NUM 11\"\n },\n {\n \"name\": \"TAX_NUM_12\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"TAX NUM 12\"\n },\n {\n \"name\": \"TAX_NUM_13\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"TAX NUM 13\"\n },\n {\n \"name\": \"HCPCS_CD_1\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 1\"\n },\n {\n \"name\": \"HCPCS_CD_2\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 2\"\n },\n {\n \"name\": \"HCPCS_CD_3\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 3\"\n },\n {\n \"name\": \"HCPCS_CD_4\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 4\"\n },\n {\n \"name\": \"HCPCS_CD_5\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 5\"\n },\n {\n \"name\": \"HCPCS_CD_6\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 6\"\n },\n {\n \"name\": \"HCPCS_CD_7\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 7\"\n },\n {\n \"name\": \"HCPCS_CD_8\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 8\"\n },\n {\n \"name\": \"HCPCS_CD_9\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 9\"\n },\n {\n \"name\": \"HCPCS_CD_10\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 10\"\n },\n {\n \"name\": \"HCPCS_CD_11\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 11\"\n },\n {\n \"name\": \"HCPCS_CD_12\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 12\"\n },\n {\n \"name\": \"HCPCS_CD_13\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"HCPCS CD 13\"\n },\n {\n \"name\": \"LINE_NCH_PMT_AMT_1\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE NCH PMT AMT 1\"\n },\n {\n \"name\": \"LINE_NCH_PMT_AMT_2\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE NCH PMT AMT 2\"\n },\n {\n \"name\": \"LINE_NCH_PMT_AMT_3\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE NCH PMT AMT 3\"\n },\n {\n \"name\": \"LINE_NCH_PMT_AMT_4\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE NCH PMT AMT 4\"\n },\n {\n \"name\": \"LINE_NCH_PMT_AMT_5\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE NCH PMT AMT 5\"\n },\n {\n \"name\": \"LINE_NCH_PMT_AMT_6\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE NCH PMT AMT 6\"\n },\n {\n \"name\": \"LINE_NCH_PMT_AMT_7\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE NCH PMT AMT 7\"\n },\n {\n \"name\": \"LINE_NCH_PMT_AMT_8\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE NCH PMT AMT 8\"\n },\n {\n \"name\": \"LINE_NCH_PMT_AMT_9\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE NCH PMT AMT 9\"\n },\n {\n \"name\": \"LINE_NCH_PMT_AMT_10\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE NCH PMT AMT 10\"\n },\n {\n \"name\": \"LINE_NCH_PMT_AMT_11\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE NCH PMT AMT 11\"\n },\n {\n \"name\": \"LINE_NCH_PMT_AMT_12\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE NCH PMT AMT 12\"\n },\n {\n \"name\": \"LINE_NCH_PMT_AMT_13\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE NCH PMT AMT 13\"\n },\n {\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_1\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PTB DDCTBL AMT 1\"\n },\n {\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_2\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PTB DDCTBL AMT 2\"\n },\n {\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_3\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PTB DDCTBL AMT 3\"\n },\n {\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_4\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PTB DDCTBL AMT 4\"\n },\n {\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_5\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PTB DDCTBL AMT 5\"\n },\n {\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_6\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PTB DDCTBL AMT 6\"\n },\n {\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_7\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PTB DDCTBL AMT 7\"\n },\n {\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_8\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PTB DDCTBL AMT 8\"\n },\n {\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_9\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PTB DDCTBL AMT 9\"\n },\n {\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_10\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PTB DDCTBL AMT 10\"\n },\n {\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_11\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PTB DDCTBL AMT 11\"\n },\n {\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_12\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PTB DDCTBL AMT 12\"\n },\n {\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_13\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PTB DDCTBL AMT 13\"\n },\n {\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_1\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PRMRY PYR PD AMT 1\"\n },\n {\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_2\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PRMRY PYR PD AMT 2\"\n },\n {\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_3\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PRMRY PYR PD AMT 3\"\n },\n {\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_4\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PRMRY PYR PD AMT 4\"\n },\n {\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_5\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PRMRY PYR PD AMT 5\"\n },\n {\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_6\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PRMRY PYR PD AMT 6\"\n },\n {\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_7\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PRMRY PYR PD AMT 7\"\n },\n {\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_8\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PRMRY PYR PD AMT 8\"\n },\n {\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_9\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PRMRY PYR PD AMT 9\"\n },\n {\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_10\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PRMRY PYR PD AMT 10\"\n },\n {\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_11\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PRMRY PYR PD AMT 11\"\n },\n {\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_12\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PRMRY PYR PD AMT 12\"\n },\n {\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_13\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE BENE PRMRY PYR PD AMT 13\"\n },\n {\n \"name\": \"LINE_COINSRNC_AMT_1\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE COINSRNC AMT 1\"\n },\n {\n \"name\": \"LINE_COINSRNC_AMT_2\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE COINSRNC AMT 2\"\n },\n {\n \"name\": \"LINE_COINSRNC_AMT_3\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE COINSRNC AMT 3\"\n },\n {\n \"name\": \"LINE_COINSRNC_AMT_4\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE COINSRNC AMT 4\"\n },\n {\n \"name\": \"LINE_COINSRNC_AMT_5\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE COINSRNC AMT 5\"\n },\n {\n \"name\": \"LINE_COINSRNC_AMT_6\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE COINSRNC AMT 6\"\n },\n {\n \"name\": \"LINE_COINSRNC_AMT_7\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE COINSRNC AMT 7\"\n },\n {\n \"name\": \"LINE_COINSRNC_AMT_8\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE COINSRNC AMT 8\"\n },\n {\n \"name\": \"LINE_COINSRNC_AMT_9\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE COINSRNC AMT 9\"\n },\n {\n \"name\": \"LINE_COINSRNC_AMT_10\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE COINSRNC AMT 10\"\n },\n {\n \"name\": \"LINE_COINSRNC_AMT_11\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE COINSRNC AMT 11\"\n },\n {\n \"name\": \"LINE_COINSRNC_AMT_12\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE COINSRNC AMT 12\"\n },\n {\n \"name\": \"LINE_COINSRNC_AMT_13\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE COINSRNC AMT 13\"\n },\n {\n \"name\": \"LINE_ALOWD_CHRG_AMT_1\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ALOWD CHRG AMT 1\"\n },\n {\n \"name\": \"LINE_ALOWD_CHRG_AMT_2\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ALOWD CHRG AMT 2\"\n },\n {\n \"name\": \"LINE_ALOWD_CHRG_AMT_3\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ALOWD CHRG AMT 3\"\n },\n {\n \"name\": \"LINE_ALOWD_CHRG_AMT_4\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ALOWD CHRG AMT 4\"\n },\n {\n \"name\": \"LINE_ALOWD_CHRG_AMT_5\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ALOWD CHRG AMT 5\"\n },\n {\n \"name\": \"LINE_ALOWD_CHRG_AMT_6\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ALOWD CHRG AMT 6\"\n },\n {\n \"name\": \"LINE_ALOWD_CHRG_AMT_7\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ALOWD CHRG AMT 7\"\n },\n {\n \"name\": \"LINE_ALOWD_CHRG_AMT_8\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ALOWD CHRG AMT 8\"\n },\n {\n \"name\": \"LINE_ALOWD_CHRG_AMT_9\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ALOWD CHRG AMT 9\"\n },\n {\n \"name\": \"LINE_ALOWD_CHRG_AMT_10\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ALOWD CHRG AMT 10\"\n },\n {\n \"name\": \"LINE_ALOWD_CHRG_AMT_11\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ALOWD CHRG AMT 11\"\n },\n {\n \"name\": \"LINE_ALOWD_CHRG_AMT_12\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ALOWD CHRG AMT 12\"\n },\n {\n \"name\": \"LINE_ALOWD_CHRG_AMT_13\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ALOWD CHRG AMT 13\"\n },\n {\n \"name\": \"LINE_PRCSG_IND_CD_1\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE PRCSG IND CD 1\"\n },\n {\n \"name\": \"LINE_PRCSG_IND_CD_2\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE PRCSG IND CD 2\"\n },\n {\n \"name\": \"LINE_PRCSG_IND_CD_3\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE PRCSG IND CD 3\"\n },\n {\n \"name\": \"LINE_PRCSG_IND_CD_4\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE PRCSG IND CD 4\"\n },\n {\n \"name\": \"LINE_PRCSG_IND_CD_5\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE PRCSG IND CD 5\"\n },\n {\n \"name\": \"LINE_PRCSG_IND_CD_6\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE PRCSG IND CD 6\"\n },\n {\n \"name\": \"LINE_PRCSG_IND_CD_7\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE PRCSG IND CD 7\"\n },\n {\n \"name\": \"LINE_PRCSG_IND_CD_8\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE PRCSG IND CD 8\"\n },\n {\n \"name\": \"LINE_PRCSG_IND_CD_9\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE PRCSG IND CD 9\"\n },\n {\n \"name\": \"LINE_PRCSG_IND_CD_10\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE PRCSG IND CD 10\"\n },\n {\n \"name\": \"LINE_PRCSG_IND_CD_11\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE PRCSG IND CD 11\"\n },\n {\n \"name\": \"LINE_PRCSG_IND_CD_12\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE PRCSG IND CD 12\"\n },\n {\n \"name\": \"LINE_PRCSG_IND_CD_13\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE PRCSG IND CD 13\"\n },\n {\n \"name\": \"LINE_ICD9_DGNS_CD_1\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ICD9 DGNS CD 1\"\n },\n {\n \"name\": \"LINE_ICD9_DGNS_CD_2\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ICD9 DGNS CD 2\"\n },\n {\n \"name\": \"LINE_ICD9_DGNS_CD_3\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ICD9 DGNS CD 3\"\n },\n {\n \"name\": \"LINE_ICD9_DGNS_CD_4\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ICD9 DGNS CD 4\"\n },\n {\n \"name\": \"LINE_ICD9_DGNS_CD_5\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ICD9 DGNS CD 5\"\n },\n {\n \"name\": \"LINE_ICD9_DGNS_CD_6\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ICD9 DGNS CD 6\"\n },\n {\n \"name\": \"LINE_ICD9_DGNS_CD_7\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ICD9 DGNS CD 7\"\n },\n {\n \"name\": \"LINE_ICD9_DGNS_CD_8\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ICD9 DGNS CD 8\"\n },\n {\n \"name\": \"LINE_ICD9_DGNS_CD_9\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ICD9 DGNS CD 9\"\n },\n {\n \"name\": \"LINE_ICD9_DGNS_CD_10\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ICD9 DGNS CD 10\"\n },\n {\n \"name\": \"LINE_ICD9_DGNS_CD_11\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ICD9 DGNS CD 11\"\n },\n {\n \"name\": \"LINE_ICD9_DGNS_CD_12\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ICD9 DGNS CD 12\"\n },\n {\n \"name\": \"LINE_ICD9_DGNS_CD_13\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"LINE ICD9 DGNS CD 13\"\n },\n {\n \"name\": \"native_record_number\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native record number\"\n },\n {\n \"name\": \"native_csv_record\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native csv record\"\n }\n ],\n \"primary_key\": [\n \"CLM_ID\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"DESYNPUF_ID\",\n \"references_table\": \"cms_beneficiaries\",\n \"references_column\": \"DESYNPUF_ID\"\n }\n ]\n }\n}\n", + "format": "json", + "aliases": [ + "spec/domain-packs/medical-carrier/umf/cms_carrier_claims.json", + "schema:medical-carrier@1.0.0:cms_carrier_claims" + ] + }, + { + "id": "schema:medical-carrier@1.1.0:ontology", + "title": "medical-carrier ontology", + "category": "domain", + "path": "ontology.json", + "pack": "medical-carrier", + "packVersion": "1.1.0", + "schemaFormat": "umf", + "text": "{\n \"umf\": \"0.8.0\",\n \"id\": \"urn:umf:domain:medical-carrier\",\n \"title\": \"medical-carrier ontology\",\n \"vocabularies\": {},\n \"modules\": [\n {\n \"id\": \"domain\",\n \"namespace\": \"urn:umf:domain:medical-carrier:\",\n \"elements\": [\n {\n \"id\": \"resources\",\n \"kind\": \"record\",\n \"name\": \"resources\",\n \"title\": \"resources\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resources.source_id\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resources.resource_type\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resources.native_id\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resources.resource_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources.resource_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"resources.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"resources.source_id\",\n \"name\": \"source_id\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"source id\",\n \"extensions\": {}\n },\n {\n \"id\": \"resources.resource_type\",\n \"name\": \"resource_type\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource type\",\n \"extensions\": {}\n },\n {\n \"id\": \"resources.native_id\",\n \"name\": \"native_id\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native id\",\n \"extensions\": {}\n },\n {\n \"id\": \"resources.resource_json\",\n \"name\": \"resource_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource json\",\n \"extensions\": {}\n },\n {\n \"id\": \"coverage\",\n \"kind\": \"record\",\n \"name\": \"coverage\",\n \"title\": \"coverage\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"coverage.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"coverage.status\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"coverage.beneficiary_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"coverage.subscriber_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"coverage.payors_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"coverage.classes_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"coverage.period_start\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"coverage.period_end\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"coverage.benefits_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"coverage.resource_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"coverage.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"coverage.status\",\n \"name\": \"status\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"status\",\n \"extensions\": {}\n },\n {\n \"id\": \"coverage.beneficiary_json\",\n \"name\": \"beneficiary_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"beneficiary json\",\n \"extensions\": {}\n },\n {\n \"id\": \"coverage.subscriber_json\",\n \"name\": \"subscriber_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"subscriber json\",\n \"extensions\": {}\n },\n {\n \"id\": \"coverage.payors_json\",\n \"name\": \"payors_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"payors json\",\n \"extensions\": {}\n },\n {\n \"id\": \"coverage.classes_json\",\n \"name\": \"classes_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"classes json\",\n \"extensions\": {}\n },\n {\n \"id\": \"coverage.period_start\",\n \"name\": \"period_start\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"period start\",\n \"extensions\": {}\n },\n {\n \"id\": \"coverage.period_end\",\n \"name\": \"period_end\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"period end\",\n \"extensions\": {}\n },\n {\n \"id\": \"coverage.benefits_json\",\n \"name\": \"benefits_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"benefits json\",\n \"extensions\": {}\n },\n {\n \"id\": \"eligibility\",\n \"kind\": \"record\",\n \"name\": \"eligibility\",\n \"title\": \"eligibility\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"eligibility.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"eligibility.status\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"eligibility.patient_reference\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"eligibility.direction\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"eligibility.purpose_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"eligibility.created\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"eligibility.serviced_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"eligibility.request_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"eligibility.outcome\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"eligibility.insurance_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"eligibility.items_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"eligibility.resource_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"eligibility.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"eligibility.status\",\n \"name\": \"status\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"status\",\n \"extensions\": {}\n },\n {\n \"id\": \"eligibility.patient_reference\",\n \"name\": \"patient_reference\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"patient reference\",\n \"extensions\": {}\n },\n {\n \"id\": \"eligibility.direction\",\n \"name\": \"direction\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"direction\",\n \"extensions\": {}\n },\n {\n \"id\": \"eligibility.purpose_json\",\n \"name\": \"purpose_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"purpose json\",\n \"extensions\": {}\n },\n {\n \"id\": \"eligibility.created\",\n \"name\": \"created\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"created\",\n \"extensions\": {}\n },\n {\n \"id\": \"eligibility.serviced_json\",\n \"name\": \"serviced_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"serviced json\",\n \"extensions\": {}\n },\n {\n \"id\": \"eligibility.request_json\",\n \"name\": \"request_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"request json\",\n \"extensions\": {}\n },\n {\n \"id\": \"eligibility.outcome\",\n \"name\": \"outcome\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"outcome\",\n \"extensions\": {}\n },\n {\n \"id\": \"eligibility.insurance_json\",\n \"name\": \"insurance_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"insurance json\",\n \"extensions\": {}\n },\n {\n \"id\": \"eligibility.items_json\",\n \"name\": \"items_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"items json\",\n \"extensions\": {}\n },\n {\n \"id\": \"claims\",\n \"kind\": \"record\",\n \"name\": \"claims\",\n \"title\": \"claims\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"claims.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claims.status\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claims.patient_reference\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claims.resource_type\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claims.use\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claims.type_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claims.created\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claims.outcome\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claims.request_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claims.insurance_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claims.diagnoses_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claims.procedures_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claims.related_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claims.totals_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"claims.resource_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"claims.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"claims.status\",\n \"name\": \"status\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"status\",\n \"extensions\": {}\n },\n {\n \"id\": \"claims.patient_reference\",\n \"name\": \"patient_reference\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"patient reference\",\n \"extensions\": {}\n },\n {\n \"id\": \"claims.resource_type\",\n \"name\": \"resource_type\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource type\",\n \"extensions\": {}\n },\n {\n \"id\": \"claims.use\",\n \"name\": \"use\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"use\",\n \"extensions\": {}\n },\n {\n \"id\": \"claims.type_json\",\n \"name\": \"type_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"type json\",\n \"extensions\": {}\n },\n {\n \"id\": \"claims.created\",\n \"name\": \"created\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"created\",\n \"extensions\": {}\n },\n {\n \"id\": \"claims.outcome\",\n \"name\": \"outcome\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"outcome\",\n \"extensions\": {}\n },\n {\n \"id\": \"claims.request_json\",\n \"name\": \"request_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"request json\",\n \"extensions\": {}\n },\n {\n \"id\": \"claims.insurance_json\",\n \"name\": \"insurance_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"insurance json\",\n \"extensions\": {}\n },\n {\n \"id\": \"claims.diagnoses_json\",\n \"name\": \"diagnoses_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"diagnoses json\",\n \"extensions\": {}\n },\n {\n \"id\": \"claims.procedures_json\",\n \"name\": \"procedures_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"procedures json\",\n \"extensions\": {}\n },\n {\n \"id\": \"claims.related_json\",\n \"name\": \"related_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"related json\",\n \"extensions\": {}\n },\n {\n \"id\": \"claims.totals_json\",\n \"name\": \"totals_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"totals json\",\n \"extensions\": {}\n },\n {\n \"id\": \"claim_lines\",\n \"kind\": \"record\",\n \"name\": \"claim_lines\",\n \"title\": \"claim_lines\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines.line_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines.parent_line_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines.native_path\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines.sequence\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines.product_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines.modifiers_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines.service_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines.quantity\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines.unit_price\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines.net_amount\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines.net_currency\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines.line_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines.line_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"claim_lines.line_key\",\n \"name\": \"line_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"line key\",\n \"extensions\": {}\n },\n {\n \"id\": \"claim_lines.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"claim_lines.parent_line_key\",\n \"name\": \"parent_line_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"parent line key\",\n \"extensions\": {}\n },\n {\n \"id\": \"claim_lines.native_path\",\n \"name\": \"native_path\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native path\",\n \"extensions\": {}\n },\n {\n \"id\": \"claim_lines.sequence\",\n \"name\": \"sequence\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"sequence\",\n \"extensions\": {}\n },\n {\n \"id\": \"claim_lines.product_json\",\n \"name\": \"product_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"product json\",\n \"extensions\": {}\n },\n {\n \"id\": \"claim_lines.modifiers_json\",\n \"name\": \"modifiers_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"modifiers json\",\n \"extensions\": {}\n },\n {\n \"id\": \"claim_lines.service_json\",\n \"name\": \"service_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"service json\",\n \"extensions\": {}\n },\n {\n \"id\": \"claim_lines.quantity\",\n \"name\": \"quantity\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"quantity\",\n \"extensions\": {}\n },\n {\n \"id\": \"claim_lines.unit_price\",\n \"name\": \"unit_price\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"unit price\",\n \"extensions\": {}\n },\n {\n \"id\": \"claim_lines.net_amount\",\n \"name\": \"net_amount\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"net amount\",\n \"extensions\": {}\n },\n {\n \"id\": \"claim_lines.net_currency\",\n \"name\": \"net_currency\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"net currency\",\n \"extensions\": {}\n },\n {\n \"id\": \"claim_lines.line_json\",\n \"name\": \"line_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"line json\",\n \"extensions\": {}\n },\n {\n \"id\": \"adjudications\",\n \"kind\": \"record\",\n \"name\": \"adjudications\",\n \"title\": \"adjudications\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"adjudications.adjudication_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"adjudications.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"adjudications.line_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"adjudications.category_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"adjudications.reason_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"adjudications.amount\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"adjudications.currency\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"adjudications.value\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"adjudications.native_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"adjudications.adjudication_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"adjudications.adjudication_key\",\n \"name\": \"adjudication_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"adjudication key\",\n \"extensions\": {}\n },\n {\n \"id\": \"adjudications.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"adjudications.line_key\",\n \"name\": \"line_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"line key\",\n \"extensions\": {}\n },\n {\n \"id\": \"adjudications.category_json\",\n \"name\": \"category_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"category json\",\n \"extensions\": {}\n },\n {\n \"id\": \"adjudications.reason_json\",\n \"name\": \"reason_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"reason json\",\n \"extensions\": {}\n },\n {\n \"id\": \"adjudications.amount\",\n \"name\": \"amount\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"amount\",\n \"extensions\": {}\n },\n {\n \"id\": \"adjudications.currency\",\n \"name\": \"currency\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"currency\",\n \"extensions\": {}\n },\n {\n \"id\": \"adjudications.value\",\n \"name\": \"value\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"value\",\n \"extensions\": {}\n },\n {\n \"id\": \"adjudications.native_json\",\n \"name\": \"native_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native json\",\n \"extensions\": {}\n },\n {\n \"id\": \"payments\",\n \"kind\": \"record\",\n \"name\": \"payments\",\n \"title\": \"payments\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"payments.payment_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"payments.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"payments.date\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"payments.amount\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"payments.currency\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"payments.allocations_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"payments.native_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"payments.payment_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"payments.payment_key\",\n \"name\": \"payment_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"payment key\",\n \"extensions\": {}\n },\n {\n \"id\": \"payments.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"payments.date\",\n \"name\": \"date\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"date\",\n \"extensions\": {}\n },\n {\n \"id\": \"payments.amount\",\n \"name\": \"amount\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"amount\",\n \"extensions\": {}\n },\n {\n \"id\": \"payments.currency\",\n \"name\": \"currency\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"currency\",\n \"extensions\": {}\n },\n {\n \"id\": \"payments.allocations_json\",\n \"name\": \"allocations_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"allocations json\",\n \"extensions\": {}\n },\n {\n \"id\": \"payments.native_json\",\n \"name\": \"native_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native json\",\n \"extensions\": {}\n },\n {\n \"id\": \"plans\",\n \"kind\": \"record\",\n \"name\": \"plans\",\n \"title\": \"plans\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"plans.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"plans.status\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"plans.name\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"plans.period_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"plans.owner_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"plans.coverage_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"plans.plans_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"plans.resource_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"plans.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"plans.status\",\n \"name\": \"status\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"status\",\n \"extensions\": {}\n },\n {\n \"id\": \"plans.name\",\n \"name\": \"name\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"name\",\n \"extensions\": {}\n },\n {\n \"id\": \"plans.period_json\",\n \"name\": \"period_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"period json\",\n \"extensions\": {}\n },\n {\n \"id\": \"plans.owner_json\",\n \"name\": \"owner_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"owner json\",\n \"extensions\": {}\n },\n {\n \"id\": \"plans.coverage_json\",\n \"name\": \"coverage_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"coverage json\",\n \"extensions\": {}\n },\n {\n \"id\": \"plans.plans_json\",\n \"name\": \"plans_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"plans json\",\n \"extensions\": {}\n },\n {\n \"id\": \"enrollments\",\n \"kind\": \"record\",\n \"name\": \"enrollments\",\n \"title\": \"enrollments\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"enrollments.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"enrollments.direction\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"enrollments.status\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"enrollments.created\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"enrollments.candidate_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"enrollments.coverage_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"enrollments.request_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"enrollments.outcome\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"enrollments.resource_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"enrollments.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"enrollments.direction\",\n \"name\": \"direction\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"direction\",\n \"extensions\": {}\n },\n {\n \"id\": \"enrollments.status\",\n \"name\": \"status\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"status\",\n \"extensions\": {}\n },\n {\n \"id\": \"enrollments.created\",\n \"name\": \"created\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"created\",\n \"extensions\": {}\n },\n {\n \"id\": \"enrollments.candidate_json\",\n \"name\": \"candidate_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"candidate json\",\n \"extensions\": {}\n },\n {\n \"id\": \"enrollments.coverage_json\",\n \"name\": \"coverage_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"coverage json\",\n \"extensions\": {}\n },\n {\n \"id\": \"enrollments.request_json\",\n \"name\": \"request_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"request json\",\n \"extensions\": {}\n },\n {\n \"id\": \"enrollments.outcome\",\n \"name\": \"outcome\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"outcome\",\n \"extensions\": {}\n },\n {\n \"id\": \"resource_references\",\n \"kind\": \"record\",\n \"name\": \"resource_references\",\n \"title\": \"resource_references\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"resource_references.reference_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resource_references.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resource_references.native_path\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resource_references.native_reference\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resource_references.target_key\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"resource_references.reference_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"resource_references.reference_key\",\n \"name\": \"reference_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"reference key\",\n \"extensions\": {}\n },\n {\n \"id\": \"resource_references.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"resource_references.native_path\",\n \"name\": \"native_path\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native path\",\n \"extensions\": {}\n },\n {\n \"id\": \"resource_references.native_reference\",\n \"name\": \"native_reference\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native reference\",\n \"extensions\": {}\n },\n {\n \"id\": \"resource_references.target_key\",\n \"name\": \"target_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"target key\",\n \"extensions\": {}\n },\n {\n \"id\": \"coded_values\",\n \"kind\": \"record\",\n \"name\": \"coded_values\",\n \"title\": \"coded_values\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"coded_values.coding_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"coded_values.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"coded_values.native_path\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"coded_values.system\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"coded_values.release\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"coded_values.code\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"coded_values.display\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"coded_values.native_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"coded_values.coding_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"coded_values.coding_key\",\n \"name\": \"coding_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"coding key\",\n \"extensions\": {}\n },\n {\n \"id\": \"coded_values.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"coded_values.native_path\",\n \"name\": \"native_path\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native path\",\n \"extensions\": {}\n },\n {\n \"id\": \"coded_values.system\",\n \"name\": \"system\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"system\",\n \"extensions\": {}\n },\n {\n \"id\": \"coded_values.release\",\n \"name\": \"release\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"release\",\n \"extensions\": {}\n },\n {\n \"id\": \"coded_values.code\",\n \"name\": \"code\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"code\",\n \"extensions\": {}\n },\n {\n \"id\": \"coded_values.display\",\n \"name\": \"display\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"display\",\n \"extensions\": {}\n },\n {\n \"id\": \"coded_values.native_json\",\n \"name\": \"native_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native json\",\n \"extensions\": {}\n },\n {\n \"id\": \"workflow_events\",\n \"kind\": \"record\",\n \"name\": \"workflow_events\",\n \"title\": \"workflow_events\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"workflow_events.event_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"workflow_events.event_type\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"workflow_events.subject_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"workflow_events.claim_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"workflow_events.prior_event_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"workflow_events.date\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"workflow_events.status\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"workflow_events.amount\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"workflow_events.currency\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"workflow_events.details_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"workflow_events.event_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"workflow_events.event_key\",\n \"name\": \"event_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"event key\",\n \"extensions\": {}\n },\n {\n \"id\": \"workflow_events.event_type\",\n \"name\": \"event_type\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"event type\",\n \"extensions\": {}\n },\n {\n \"id\": \"workflow_events.subject_key\",\n \"name\": \"subject_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"subject key\",\n \"extensions\": {}\n },\n {\n \"id\": \"workflow_events.claim_key\",\n \"name\": \"claim_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"claim key\",\n \"extensions\": {}\n },\n {\n \"id\": \"workflow_events.prior_event_key\",\n \"name\": \"prior_event_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"prior event key\",\n \"extensions\": {}\n },\n {\n \"id\": \"workflow_events.date\",\n \"name\": \"date\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"date\",\n \"extensions\": {}\n },\n {\n \"id\": \"workflow_events.status\",\n \"name\": \"status\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"status\",\n \"extensions\": {}\n },\n {\n \"id\": \"workflow_events.amount\",\n \"name\": \"amount\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"amount\",\n \"extensions\": {}\n },\n {\n \"id\": \"workflow_events.currency\",\n \"name\": \"currency\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"currency\",\n \"extensions\": {}\n },\n {\n \"id\": \"workflow_events.details_json\",\n \"name\": \"details_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"details json\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries\",\n \"kind\": \"record\",\n \"name\": \"cms_beneficiaries\",\n \"title\": \"cms_beneficiaries\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.DESYNPUF_ID\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.BENE_BIRTH_DT\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.BENE_DEATH_DT\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.BENE_SEX_IDENT_CD\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.BENE_RACE_CD\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.BENE_ESRD_IND\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.SP_STATE_CODE\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.BENE_COUNTY_CD\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.BENE_HI_CVRAGE_TOT_MONS\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.BENE_SMI_CVRAGE_TOT_MONS\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.BENE_HMO_CVRAGE_TOT_MONS\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.PLAN_CVRG_MOS_NUM\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.SP_ALZHDMTA\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.SP_CHF\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.SP_CHRNKIDN\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.SP_CNCR\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.SP_COPD\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.SP_DEPRESSN\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.SP_DIABETES\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.SP_ISCHMCHT\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.SP_OSTEOPRS\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.SP_RA_OA\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.SP_STRKETIA\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.MEDREIMB_IP\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.BENRES_IP\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.PPPYMT_IP\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.MEDREIMB_OP\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.BENRES_OP\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.PPPYMT_OP\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.MEDREIMB_CAR\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.BENRES_CAR\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.PPPYMT_CAR\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.native_record_number\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.native_csv_record\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries.DESYNPUF_ID\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.DESYNPUF_ID\",\n \"name\": \"DESYNPUF_ID\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"DESYNPUF ID\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.BENE_BIRTH_DT\",\n \"name\": \"BENE_BIRTH_DT\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"BENE BIRTH DT\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.BENE_DEATH_DT\",\n \"name\": \"BENE_DEATH_DT\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"BENE DEATH DT\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.BENE_SEX_IDENT_CD\",\n \"name\": \"BENE_SEX_IDENT_CD\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"BENE SEX IDENT CD\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.BENE_RACE_CD\",\n \"name\": \"BENE_RACE_CD\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"BENE RACE CD\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.BENE_ESRD_IND\",\n \"name\": \"BENE_ESRD_IND\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"BENE ESRD IND\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.SP_STATE_CODE\",\n \"name\": \"SP_STATE_CODE\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"SP STATE CODE\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.BENE_COUNTY_CD\",\n \"name\": \"BENE_COUNTY_CD\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"BENE COUNTY CD\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.BENE_HI_CVRAGE_TOT_MONS\",\n \"name\": \"BENE_HI_CVRAGE_TOT_MONS\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"BENE HI CVRAGE TOT MONS\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.BENE_SMI_CVRAGE_TOT_MONS\",\n \"name\": \"BENE_SMI_CVRAGE_TOT_MONS\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"BENE SMI CVRAGE TOT MONS\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.BENE_HMO_CVRAGE_TOT_MONS\",\n \"name\": \"BENE_HMO_CVRAGE_TOT_MONS\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"BENE HMO CVRAGE TOT MONS\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.PLAN_CVRG_MOS_NUM\",\n \"name\": \"PLAN_CVRG_MOS_NUM\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PLAN CVRG MOS NUM\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.SP_ALZHDMTA\",\n \"name\": \"SP_ALZHDMTA\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"SP ALZHDMTA\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.SP_CHF\",\n \"name\": \"SP_CHF\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"SP CHF\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.SP_CHRNKIDN\",\n \"name\": \"SP_CHRNKIDN\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"SP CHRNKIDN\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.SP_CNCR\",\n \"name\": \"SP_CNCR\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"SP CNCR\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.SP_COPD\",\n \"name\": \"SP_COPD\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"SP COPD\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.SP_DEPRESSN\",\n \"name\": \"SP_DEPRESSN\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"SP DEPRESSN\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.SP_DIABETES\",\n \"name\": \"SP_DIABETES\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"SP DIABETES\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.SP_ISCHMCHT\",\n \"name\": \"SP_ISCHMCHT\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"SP ISCHMCHT\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.SP_OSTEOPRS\",\n \"name\": \"SP_OSTEOPRS\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"SP OSTEOPRS\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.SP_RA_OA\",\n \"name\": \"SP_RA_OA\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"SP RA OA\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.SP_STRKETIA\",\n \"name\": \"SP_STRKETIA\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"SP STRKETIA\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.MEDREIMB_IP\",\n \"name\": \"MEDREIMB_IP\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"MEDREIMB IP\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.BENRES_IP\",\n \"name\": \"BENRES_IP\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"BENRES IP\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.PPPYMT_IP\",\n \"name\": \"PPPYMT_IP\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PPPYMT IP\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.MEDREIMB_OP\",\n \"name\": \"MEDREIMB_OP\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"MEDREIMB OP\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.BENRES_OP\",\n \"name\": \"BENRES_OP\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"BENRES OP\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.PPPYMT_OP\",\n \"name\": \"PPPYMT_OP\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PPPYMT OP\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.MEDREIMB_CAR\",\n \"name\": \"MEDREIMB_CAR\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"MEDREIMB CAR\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.BENRES_CAR\",\n \"name\": \"BENRES_CAR\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"BENRES CAR\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.PPPYMT_CAR\",\n \"name\": \"PPPYMT_CAR\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PPPYMT CAR\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.native_record_number\",\n \"name\": \"native_record_number\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native record number\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_beneficiaries.native_csv_record\",\n \"name\": \"native_csv_record\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native csv record\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims\",\n \"kind\": \"record\",\n \"name\": \"cms_inpatient_claims\",\n \"title\": \"cms_inpatient_claims\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.DESYNPUF_ID\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.CLM_ID\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.SEGMENT\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.CLM_FROM_DT\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.CLM_THRU_DT\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.PRVDR_NUM\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.CLM_PMT_AMT\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.NCH_PRMRY_PYR_CLM_PD_AMT\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.AT_PHYSN_NPI\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.OP_PHYSN_NPI\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.OT_PHYSN_NPI\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.CLM_ADMSN_DT\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ADMTNG_ICD9_DGNS_CD\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.CLM_PASS_THRU_PER_DIEM_AMT\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.NCH_BENE_IP_DDCTBL_AMT\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.NCH_BENE_PTA_COINSRNC_LBLTY_AM\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.NCH_BENE_BLOOD_DDCTBL_LBLTY_AM\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.CLM_UTLZTN_DAY_CNT\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.NCH_BENE_DSCHRG_DT\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.CLM_DRG_CD\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_DGNS_CD_1\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_DGNS_CD_2\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_DGNS_CD_3\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_DGNS_CD_4\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_DGNS_CD_5\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_DGNS_CD_6\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_DGNS_CD_7\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_DGNS_CD_8\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_DGNS_CD_9\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_DGNS_CD_10\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_PRCDR_CD_1\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_PRCDR_CD_2\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_PRCDR_CD_3\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_PRCDR_CD_4\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_PRCDR_CD_5\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.ICD9_PRCDR_CD_6\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_1\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_2\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_3\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_4\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_5\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_6\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_7\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_8\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_9\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_10\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_11\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_12\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_13\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_14\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_15\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_16\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_17\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_18\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_19\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_20\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_21\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_22\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_23\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_24\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_25\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_26\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_27\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_28\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_29\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_30\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_31\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_32\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_33\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_34\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_35\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_36\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_37\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_38\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_39\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_40\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_41\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_42\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_43\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_44\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.HCPCS_CD_45\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.native_record_number\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.native_csv_record\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.CLM_ID\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims.SEGMENT\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.DESYNPUF_ID\",\n \"name\": \"DESYNPUF_ID\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"DESYNPUF ID\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.CLM_ID\",\n \"name\": \"CLM_ID\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"CLM ID\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.SEGMENT\",\n \"name\": \"SEGMENT\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"SEGMENT\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.CLM_FROM_DT\",\n \"name\": \"CLM_FROM_DT\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"CLM FROM DT\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.CLM_THRU_DT\",\n \"name\": \"CLM_THRU_DT\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"CLM THRU DT\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.PRVDR_NUM\",\n \"name\": \"PRVDR_NUM\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PRVDR NUM\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.CLM_PMT_AMT\",\n \"name\": \"CLM_PMT_AMT\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"CLM PMT AMT\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.NCH_PRMRY_PYR_CLM_PD_AMT\",\n \"name\": \"NCH_PRMRY_PYR_CLM_PD_AMT\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"NCH PRMRY PYR CLM PD AMT\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.AT_PHYSN_NPI\",\n \"name\": \"AT_PHYSN_NPI\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"AT PHYSN NPI\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.OP_PHYSN_NPI\",\n \"name\": \"OP_PHYSN_NPI\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"OP PHYSN NPI\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.OT_PHYSN_NPI\",\n \"name\": \"OT_PHYSN_NPI\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"OT PHYSN NPI\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.CLM_ADMSN_DT\",\n \"name\": \"CLM_ADMSN_DT\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"CLM ADMSN DT\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ADMTNG_ICD9_DGNS_CD\",\n \"name\": \"ADMTNG_ICD9_DGNS_CD\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ADMTNG ICD9 DGNS CD\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.CLM_PASS_THRU_PER_DIEM_AMT\",\n \"name\": \"CLM_PASS_THRU_PER_DIEM_AMT\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"CLM PASS THRU PER DIEM AMT\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.NCH_BENE_IP_DDCTBL_AMT\",\n \"name\": \"NCH_BENE_IP_DDCTBL_AMT\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"NCH BENE IP DDCTBL AMT\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.NCH_BENE_PTA_COINSRNC_LBLTY_AM\",\n \"name\": \"NCH_BENE_PTA_COINSRNC_LBLTY_AM\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"NCH BENE PTA COINSRNC LBLTY AM\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.NCH_BENE_BLOOD_DDCTBL_LBLTY_AM\",\n \"name\": \"NCH_BENE_BLOOD_DDCTBL_LBLTY_AM\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"NCH BENE BLOOD DDCTBL LBLTY AM\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.CLM_UTLZTN_DAY_CNT\",\n \"name\": \"CLM_UTLZTN_DAY_CNT\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"CLM UTLZTN DAY CNT\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.NCH_BENE_DSCHRG_DT\",\n \"name\": \"NCH_BENE_DSCHRG_DT\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"NCH BENE DSCHRG DT\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.CLM_DRG_CD\",\n \"name\": \"CLM_DRG_CD\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"CLM DRG CD\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_DGNS_CD_1\",\n \"name\": \"ICD9_DGNS_CD_1\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 1\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_DGNS_CD_2\",\n \"name\": \"ICD9_DGNS_CD_2\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 2\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_DGNS_CD_3\",\n \"name\": \"ICD9_DGNS_CD_3\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 3\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_DGNS_CD_4\",\n \"name\": \"ICD9_DGNS_CD_4\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 4\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_DGNS_CD_5\",\n \"name\": \"ICD9_DGNS_CD_5\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 5\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_DGNS_CD_6\",\n \"name\": \"ICD9_DGNS_CD_6\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 6\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_DGNS_CD_7\",\n \"name\": \"ICD9_DGNS_CD_7\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 7\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_DGNS_CD_8\",\n \"name\": \"ICD9_DGNS_CD_8\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 8\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_DGNS_CD_9\",\n \"name\": \"ICD9_DGNS_CD_9\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 9\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_DGNS_CD_10\",\n \"name\": \"ICD9_DGNS_CD_10\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 10\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_PRCDR_CD_1\",\n \"name\": \"ICD9_PRCDR_CD_1\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 PRCDR CD 1\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_PRCDR_CD_2\",\n \"name\": \"ICD9_PRCDR_CD_2\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 PRCDR CD 2\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_PRCDR_CD_3\",\n \"name\": \"ICD9_PRCDR_CD_3\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 PRCDR CD 3\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_PRCDR_CD_4\",\n \"name\": \"ICD9_PRCDR_CD_4\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 PRCDR CD 4\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_PRCDR_CD_5\",\n \"name\": \"ICD9_PRCDR_CD_5\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 PRCDR CD 5\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.ICD9_PRCDR_CD_6\",\n \"name\": \"ICD9_PRCDR_CD_6\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 PRCDR CD 6\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_1\",\n \"name\": \"HCPCS_CD_1\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 1\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_2\",\n \"name\": \"HCPCS_CD_2\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 2\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_3\",\n \"name\": \"HCPCS_CD_3\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 3\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_4\",\n \"name\": \"HCPCS_CD_4\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 4\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_5\",\n \"name\": \"HCPCS_CD_5\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 5\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_6\",\n \"name\": \"HCPCS_CD_6\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 6\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_7\",\n \"name\": \"HCPCS_CD_7\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 7\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_8\",\n \"name\": \"HCPCS_CD_8\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 8\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_9\",\n \"name\": \"HCPCS_CD_9\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 9\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_10\",\n \"name\": \"HCPCS_CD_10\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 10\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_11\",\n \"name\": \"HCPCS_CD_11\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 11\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_12\",\n \"name\": \"HCPCS_CD_12\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 12\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_13\",\n \"name\": \"HCPCS_CD_13\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 13\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_14\",\n \"name\": \"HCPCS_CD_14\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 14\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_15\",\n \"name\": \"HCPCS_CD_15\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 15\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_16\",\n \"name\": \"HCPCS_CD_16\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 16\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_17\",\n \"name\": \"HCPCS_CD_17\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 17\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_18\",\n \"name\": \"HCPCS_CD_18\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 18\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_19\",\n \"name\": \"HCPCS_CD_19\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 19\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_20\",\n \"name\": \"HCPCS_CD_20\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 20\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_21\",\n \"name\": \"HCPCS_CD_21\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 21\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_22\",\n \"name\": \"HCPCS_CD_22\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 22\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_23\",\n \"name\": \"HCPCS_CD_23\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 23\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_24\",\n \"name\": \"HCPCS_CD_24\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 24\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_25\",\n \"name\": \"HCPCS_CD_25\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 25\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_26\",\n \"name\": \"HCPCS_CD_26\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 26\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_27\",\n \"name\": \"HCPCS_CD_27\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 27\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_28\",\n \"name\": \"HCPCS_CD_28\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 28\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_29\",\n \"name\": \"HCPCS_CD_29\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 29\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_30\",\n \"name\": \"HCPCS_CD_30\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 30\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_31\",\n \"name\": \"HCPCS_CD_31\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 31\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_32\",\n \"name\": \"HCPCS_CD_32\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 32\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_33\",\n \"name\": \"HCPCS_CD_33\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 33\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_34\",\n \"name\": \"HCPCS_CD_34\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 34\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_35\",\n \"name\": \"HCPCS_CD_35\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 35\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_36\",\n \"name\": \"HCPCS_CD_36\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 36\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_37\",\n \"name\": \"HCPCS_CD_37\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 37\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_38\",\n \"name\": \"HCPCS_CD_38\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 38\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_39\",\n \"name\": \"HCPCS_CD_39\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 39\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_40\",\n \"name\": \"HCPCS_CD_40\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 40\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_41\",\n \"name\": \"HCPCS_CD_41\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 41\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_42\",\n \"name\": \"HCPCS_CD_42\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 42\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_43\",\n \"name\": \"HCPCS_CD_43\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 43\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_44\",\n \"name\": \"HCPCS_CD_44\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 44\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.HCPCS_CD_45\",\n \"name\": \"HCPCS_CD_45\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 45\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.native_record_number\",\n \"name\": \"native_record_number\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native record number\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_inpatient_claims.native_csv_record\",\n \"name\": \"native_csv_record\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native csv record\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims\",\n \"kind\": \"record\",\n \"name\": \"cms_carrier_claims\",\n \"title\": \"cms_carrier_claims\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.DESYNPUF_ID\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.CLM_ID\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.CLM_FROM_DT\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.CLM_THRU_DT\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.ICD9_DGNS_CD_1\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.ICD9_DGNS_CD_2\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.ICD9_DGNS_CD_3\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.ICD9_DGNS_CD_4\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.ICD9_DGNS_CD_5\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.ICD9_DGNS_CD_6\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.ICD9_DGNS_CD_7\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.ICD9_DGNS_CD_8\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.PRF_PHYSN_NPI_1\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.PRF_PHYSN_NPI_2\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.PRF_PHYSN_NPI_3\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.PRF_PHYSN_NPI_4\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.PRF_PHYSN_NPI_5\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.PRF_PHYSN_NPI_6\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.PRF_PHYSN_NPI_7\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.PRF_PHYSN_NPI_8\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.PRF_PHYSN_NPI_9\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.PRF_PHYSN_NPI_10\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.PRF_PHYSN_NPI_11\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.PRF_PHYSN_NPI_12\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.PRF_PHYSN_NPI_13\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.TAX_NUM_1\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.TAX_NUM_2\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.TAX_NUM_3\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.TAX_NUM_4\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.TAX_NUM_5\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.TAX_NUM_6\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.TAX_NUM_7\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.TAX_NUM_8\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.TAX_NUM_9\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.TAX_NUM_10\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.TAX_NUM_11\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.TAX_NUM_12\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.TAX_NUM_13\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.HCPCS_CD_1\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.HCPCS_CD_2\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.HCPCS_CD_3\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.HCPCS_CD_4\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.HCPCS_CD_5\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.HCPCS_CD_6\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.HCPCS_CD_7\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.HCPCS_CD_8\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.HCPCS_CD_9\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.HCPCS_CD_10\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.HCPCS_CD_11\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.HCPCS_CD_12\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.HCPCS_CD_13\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_1\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_2\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_3\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_4\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_5\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_6\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_7\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_8\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_9\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_10\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_11\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_12\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_13\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_1\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_2\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_3\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_4\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_5\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_6\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_7\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_8\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_9\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_10\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_11\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_12\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_13\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_1\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_2\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_3\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_4\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_5\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_6\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_7\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_8\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_9\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_10\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_11\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_12\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_13\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_COINSRNC_AMT_1\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_COINSRNC_AMT_2\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_COINSRNC_AMT_3\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_COINSRNC_AMT_4\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_COINSRNC_AMT_5\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_COINSRNC_AMT_6\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_COINSRNC_AMT_7\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_COINSRNC_AMT_8\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_COINSRNC_AMT_9\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_COINSRNC_AMT_10\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_COINSRNC_AMT_11\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_COINSRNC_AMT_12\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_COINSRNC_AMT_13\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_1\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_2\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_3\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_4\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_5\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_6\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_7\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_8\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_9\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_10\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_11\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_12\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_13\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_1\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_2\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_3\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_4\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_5\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_6\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_7\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_8\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_9\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_10\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_11\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_12\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_13\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_1\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_2\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_3\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_4\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_5\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_6\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_7\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_8\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_9\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_10\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_11\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_12\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_13\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.native_record_number\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.native_csv_record\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims.CLM_ID\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.DESYNPUF_ID\",\n \"name\": \"DESYNPUF_ID\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"DESYNPUF ID\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.CLM_ID\",\n \"name\": \"CLM_ID\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"CLM ID\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.CLM_FROM_DT\",\n \"name\": \"CLM_FROM_DT\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"CLM FROM DT\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.CLM_THRU_DT\",\n \"name\": \"CLM_THRU_DT\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"CLM THRU DT\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.ICD9_DGNS_CD_1\",\n \"name\": \"ICD9_DGNS_CD_1\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 1\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.ICD9_DGNS_CD_2\",\n \"name\": \"ICD9_DGNS_CD_2\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 2\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.ICD9_DGNS_CD_3\",\n \"name\": \"ICD9_DGNS_CD_3\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 3\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.ICD9_DGNS_CD_4\",\n \"name\": \"ICD9_DGNS_CD_4\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 4\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.ICD9_DGNS_CD_5\",\n \"name\": \"ICD9_DGNS_CD_5\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 5\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.ICD9_DGNS_CD_6\",\n \"name\": \"ICD9_DGNS_CD_6\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 6\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.ICD9_DGNS_CD_7\",\n \"name\": \"ICD9_DGNS_CD_7\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 7\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.ICD9_DGNS_CD_8\",\n \"name\": \"ICD9_DGNS_CD_8\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"ICD9 DGNS CD 8\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.PRF_PHYSN_NPI_1\",\n \"name\": \"PRF_PHYSN_NPI_1\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PRF PHYSN NPI 1\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.PRF_PHYSN_NPI_2\",\n \"name\": \"PRF_PHYSN_NPI_2\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PRF PHYSN NPI 2\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.PRF_PHYSN_NPI_3\",\n \"name\": \"PRF_PHYSN_NPI_3\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PRF PHYSN NPI 3\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.PRF_PHYSN_NPI_4\",\n \"name\": \"PRF_PHYSN_NPI_4\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PRF PHYSN NPI 4\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.PRF_PHYSN_NPI_5\",\n \"name\": \"PRF_PHYSN_NPI_5\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PRF PHYSN NPI 5\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.PRF_PHYSN_NPI_6\",\n \"name\": \"PRF_PHYSN_NPI_6\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PRF PHYSN NPI 6\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.PRF_PHYSN_NPI_7\",\n \"name\": \"PRF_PHYSN_NPI_7\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PRF PHYSN NPI 7\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.PRF_PHYSN_NPI_8\",\n \"name\": \"PRF_PHYSN_NPI_8\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PRF PHYSN NPI 8\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.PRF_PHYSN_NPI_9\",\n \"name\": \"PRF_PHYSN_NPI_9\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PRF PHYSN NPI 9\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.PRF_PHYSN_NPI_10\",\n \"name\": \"PRF_PHYSN_NPI_10\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PRF PHYSN NPI 10\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.PRF_PHYSN_NPI_11\",\n \"name\": \"PRF_PHYSN_NPI_11\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PRF PHYSN NPI 11\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.PRF_PHYSN_NPI_12\",\n \"name\": \"PRF_PHYSN_NPI_12\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PRF PHYSN NPI 12\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.PRF_PHYSN_NPI_13\",\n \"name\": \"PRF_PHYSN_NPI_13\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"PRF PHYSN NPI 13\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.TAX_NUM_1\",\n \"name\": \"TAX_NUM_1\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"TAX NUM 1\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.TAX_NUM_2\",\n \"name\": \"TAX_NUM_2\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"TAX NUM 2\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.TAX_NUM_3\",\n \"name\": \"TAX_NUM_3\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"TAX NUM 3\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.TAX_NUM_4\",\n \"name\": \"TAX_NUM_4\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"TAX NUM 4\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.TAX_NUM_5\",\n \"name\": \"TAX_NUM_5\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"TAX NUM 5\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.TAX_NUM_6\",\n \"name\": \"TAX_NUM_6\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"TAX NUM 6\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.TAX_NUM_7\",\n \"name\": \"TAX_NUM_7\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"TAX NUM 7\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.TAX_NUM_8\",\n \"name\": \"TAX_NUM_8\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"TAX NUM 8\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.TAX_NUM_9\",\n \"name\": \"TAX_NUM_9\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"TAX NUM 9\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.TAX_NUM_10\",\n \"name\": \"TAX_NUM_10\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"TAX NUM 10\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.TAX_NUM_11\",\n \"name\": \"TAX_NUM_11\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"TAX NUM 11\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.TAX_NUM_12\",\n \"name\": \"TAX_NUM_12\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"TAX NUM 12\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.TAX_NUM_13\",\n \"name\": \"TAX_NUM_13\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"TAX NUM 13\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.HCPCS_CD_1\",\n \"name\": \"HCPCS_CD_1\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 1\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.HCPCS_CD_2\",\n \"name\": \"HCPCS_CD_2\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 2\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.HCPCS_CD_3\",\n \"name\": \"HCPCS_CD_3\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 3\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.HCPCS_CD_4\",\n \"name\": \"HCPCS_CD_4\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 4\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.HCPCS_CD_5\",\n \"name\": \"HCPCS_CD_5\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 5\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.HCPCS_CD_6\",\n \"name\": \"HCPCS_CD_6\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 6\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.HCPCS_CD_7\",\n \"name\": \"HCPCS_CD_7\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 7\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.HCPCS_CD_8\",\n \"name\": \"HCPCS_CD_8\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 8\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.HCPCS_CD_9\",\n \"name\": \"HCPCS_CD_9\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 9\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.HCPCS_CD_10\",\n \"name\": \"HCPCS_CD_10\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 10\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.HCPCS_CD_11\",\n \"name\": \"HCPCS_CD_11\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 11\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.HCPCS_CD_12\",\n \"name\": \"HCPCS_CD_12\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 12\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.HCPCS_CD_13\",\n \"name\": \"HCPCS_CD_13\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"HCPCS CD 13\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_1\",\n \"name\": \"LINE_NCH_PMT_AMT_1\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE NCH PMT AMT 1\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_2\",\n \"name\": \"LINE_NCH_PMT_AMT_2\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE NCH PMT AMT 2\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_3\",\n \"name\": \"LINE_NCH_PMT_AMT_3\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE NCH PMT AMT 3\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_4\",\n \"name\": \"LINE_NCH_PMT_AMT_4\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE NCH PMT AMT 4\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_5\",\n \"name\": \"LINE_NCH_PMT_AMT_5\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE NCH PMT AMT 5\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_6\",\n \"name\": \"LINE_NCH_PMT_AMT_6\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE NCH PMT AMT 6\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_7\",\n \"name\": \"LINE_NCH_PMT_AMT_7\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE NCH PMT AMT 7\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_8\",\n \"name\": \"LINE_NCH_PMT_AMT_8\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE NCH PMT AMT 8\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_9\",\n \"name\": \"LINE_NCH_PMT_AMT_9\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE NCH PMT AMT 9\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_10\",\n \"name\": \"LINE_NCH_PMT_AMT_10\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE NCH PMT AMT 10\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_11\",\n \"name\": \"LINE_NCH_PMT_AMT_11\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE NCH PMT AMT 11\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_12\",\n \"name\": \"LINE_NCH_PMT_AMT_12\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE NCH PMT AMT 12\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_NCH_PMT_AMT_13\",\n \"name\": \"LINE_NCH_PMT_AMT_13\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE NCH PMT AMT 13\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_1\",\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_1\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PTB DDCTBL AMT 1\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_2\",\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_2\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PTB DDCTBL AMT 2\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_3\",\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_3\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PTB DDCTBL AMT 3\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_4\",\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_4\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PTB DDCTBL AMT 4\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_5\",\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_5\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PTB DDCTBL AMT 5\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_6\",\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_6\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PTB DDCTBL AMT 6\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_7\",\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_7\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PTB DDCTBL AMT 7\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_8\",\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_8\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PTB DDCTBL AMT 8\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_9\",\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_9\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PTB DDCTBL AMT 9\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_10\",\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_10\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PTB DDCTBL AMT 10\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_11\",\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_11\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PTB DDCTBL AMT 11\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_12\",\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_12\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PTB DDCTBL AMT 12\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_13\",\n \"name\": \"LINE_BENE_PTB_DDCTBL_AMT_13\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PTB DDCTBL AMT 13\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_1\",\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_1\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PRMRY PYR PD AMT 1\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_2\",\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_2\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PRMRY PYR PD AMT 2\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_3\",\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_3\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PRMRY PYR PD AMT 3\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_4\",\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_4\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PRMRY PYR PD AMT 4\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_5\",\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_5\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PRMRY PYR PD AMT 5\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_6\",\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_6\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PRMRY PYR PD AMT 6\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_7\",\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_7\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PRMRY PYR PD AMT 7\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_8\",\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_8\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PRMRY PYR PD AMT 8\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_9\",\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_9\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PRMRY PYR PD AMT 9\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_10\",\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_10\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PRMRY PYR PD AMT 10\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_11\",\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_11\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PRMRY PYR PD AMT 11\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_12\",\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_12\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PRMRY PYR PD AMT 12\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_13\",\n \"name\": \"LINE_BENE_PRMRY_PYR_PD_AMT_13\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE BENE PRMRY PYR PD AMT 13\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_COINSRNC_AMT_1\",\n \"name\": \"LINE_COINSRNC_AMT_1\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE COINSRNC AMT 1\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_COINSRNC_AMT_2\",\n \"name\": \"LINE_COINSRNC_AMT_2\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE COINSRNC AMT 2\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_COINSRNC_AMT_3\",\n \"name\": \"LINE_COINSRNC_AMT_3\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE COINSRNC AMT 3\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_COINSRNC_AMT_4\",\n \"name\": \"LINE_COINSRNC_AMT_4\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE COINSRNC AMT 4\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_COINSRNC_AMT_5\",\n \"name\": \"LINE_COINSRNC_AMT_5\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE COINSRNC AMT 5\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_COINSRNC_AMT_6\",\n \"name\": \"LINE_COINSRNC_AMT_6\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE COINSRNC AMT 6\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_COINSRNC_AMT_7\",\n \"name\": \"LINE_COINSRNC_AMT_7\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE COINSRNC AMT 7\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_COINSRNC_AMT_8\",\n \"name\": \"LINE_COINSRNC_AMT_8\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE COINSRNC AMT 8\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_COINSRNC_AMT_9\",\n \"name\": \"LINE_COINSRNC_AMT_9\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE COINSRNC AMT 9\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_COINSRNC_AMT_10\",\n \"name\": \"LINE_COINSRNC_AMT_10\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE COINSRNC AMT 10\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_COINSRNC_AMT_11\",\n \"name\": \"LINE_COINSRNC_AMT_11\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE COINSRNC AMT 11\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_COINSRNC_AMT_12\",\n \"name\": \"LINE_COINSRNC_AMT_12\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE COINSRNC AMT 12\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_COINSRNC_AMT_13\",\n \"name\": \"LINE_COINSRNC_AMT_13\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE COINSRNC AMT 13\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_1\",\n \"name\": \"LINE_ALOWD_CHRG_AMT_1\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ALOWD CHRG AMT 1\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_2\",\n \"name\": \"LINE_ALOWD_CHRG_AMT_2\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ALOWD CHRG AMT 2\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_3\",\n \"name\": \"LINE_ALOWD_CHRG_AMT_3\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ALOWD CHRG AMT 3\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_4\",\n \"name\": \"LINE_ALOWD_CHRG_AMT_4\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ALOWD CHRG AMT 4\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_5\",\n \"name\": \"LINE_ALOWD_CHRG_AMT_5\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ALOWD CHRG AMT 5\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_6\",\n \"name\": \"LINE_ALOWD_CHRG_AMT_6\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ALOWD CHRG AMT 6\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_7\",\n \"name\": \"LINE_ALOWD_CHRG_AMT_7\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ALOWD CHRG AMT 7\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_8\",\n \"name\": \"LINE_ALOWD_CHRG_AMT_8\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ALOWD CHRG AMT 8\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_9\",\n \"name\": \"LINE_ALOWD_CHRG_AMT_9\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ALOWD CHRG AMT 9\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_10\",\n \"name\": \"LINE_ALOWD_CHRG_AMT_10\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ALOWD CHRG AMT 10\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_11\",\n \"name\": \"LINE_ALOWD_CHRG_AMT_11\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ALOWD CHRG AMT 11\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_12\",\n \"name\": \"LINE_ALOWD_CHRG_AMT_12\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ALOWD CHRG AMT 12\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ALOWD_CHRG_AMT_13\",\n \"name\": \"LINE_ALOWD_CHRG_AMT_13\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ALOWD CHRG AMT 13\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_1\",\n \"name\": \"LINE_PRCSG_IND_CD_1\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE PRCSG IND CD 1\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_2\",\n \"name\": \"LINE_PRCSG_IND_CD_2\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE PRCSG IND CD 2\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_3\",\n \"name\": \"LINE_PRCSG_IND_CD_3\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE PRCSG IND CD 3\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_4\",\n \"name\": \"LINE_PRCSG_IND_CD_4\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE PRCSG IND CD 4\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_5\",\n \"name\": \"LINE_PRCSG_IND_CD_5\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE PRCSG IND CD 5\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_6\",\n \"name\": \"LINE_PRCSG_IND_CD_6\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE PRCSG IND CD 6\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_7\",\n \"name\": \"LINE_PRCSG_IND_CD_7\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE PRCSG IND CD 7\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_8\",\n \"name\": \"LINE_PRCSG_IND_CD_8\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE PRCSG IND CD 8\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_9\",\n \"name\": \"LINE_PRCSG_IND_CD_9\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE PRCSG IND CD 9\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_10\",\n \"name\": \"LINE_PRCSG_IND_CD_10\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE PRCSG IND CD 10\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_11\",\n \"name\": \"LINE_PRCSG_IND_CD_11\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE PRCSG IND CD 11\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_12\",\n \"name\": \"LINE_PRCSG_IND_CD_12\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE PRCSG IND CD 12\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_PRCSG_IND_CD_13\",\n \"name\": \"LINE_PRCSG_IND_CD_13\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE PRCSG IND CD 13\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_1\",\n \"name\": \"LINE_ICD9_DGNS_CD_1\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ICD9 DGNS CD 1\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_2\",\n \"name\": \"LINE_ICD9_DGNS_CD_2\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ICD9 DGNS CD 2\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_3\",\n \"name\": \"LINE_ICD9_DGNS_CD_3\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ICD9 DGNS CD 3\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_4\",\n \"name\": \"LINE_ICD9_DGNS_CD_4\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ICD9 DGNS CD 4\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_5\",\n \"name\": \"LINE_ICD9_DGNS_CD_5\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ICD9 DGNS CD 5\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_6\",\n \"name\": \"LINE_ICD9_DGNS_CD_6\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ICD9 DGNS CD 6\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_7\",\n \"name\": \"LINE_ICD9_DGNS_CD_7\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ICD9 DGNS CD 7\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_8\",\n \"name\": \"LINE_ICD9_DGNS_CD_8\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ICD9 DGNS CD 8\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_9\",\n \"name\": \"LINE_ICD9_DGNS_CD_9\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ICD9 DGNS CD 9\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_10\",\n \"name\": \"LINE_ICD9_DGNS_CD_10\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ICD9 DGNS CD 10\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_11\",\n \"name\": \"LINE_ICD9_DGNS_CD_11\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ICD9 DGNS CD 11\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_12\",\n \"name\": \"LINE_ICD9_DGNS_CD_12\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ICD9 DGNS CD 12\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.LINE_ICD9_DGNS_CD_13\",\n \"name\": \"LINE_ICD9_DGNS_CD_13\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"LINE ICD9 DGNS CD 13\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.native_record_number\",\n \"name\": \"native_record_number\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native record number\",\n \"extensions\": {}\n },\n {\n \"id\": \"cms_carrier_claims.native_csv_record\",\n \"name\": \"native_csv_record\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native csv record\",\n \"extensions\": {}\n }\n ],\n \"relationships\": [\n {\n \"id\": \"coverage.resource_key\",\n \"name\": \"coverage.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"coverage\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"eligibility.resource_key\",\n \"name\": \"eligibility.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"eligibility\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"claims.resource_key\",\n \"name\": \"claims.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"claims\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"claim_lines.resource_key\",\n \"name\": \"claim_lines.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"claim_lines.parent_line_key\",\n \"name\": \"claim_lines.parent_line_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 0,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"adjudications.resource_key\",\n \"name\": \"adjudications.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"adjudications\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"adjudications.line_key\",\n \"name\": \"adjudications.line_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"adjudications\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"claim_lines\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"payments.resource_key\",\n \"name\": \"payments.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"payments\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"plans.resource_key\",\n \"name\": \"plans.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"plans\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"enrollments.resource_key\",\n \"name\": \"enrollments.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"enrollments\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"resource_references.resource_key\",\n \"name\": \"resource_references.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"resource_references\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"resource_references.target_key\",\n \"name\": \"resource_references.target_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"resource_references\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 0,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"coded_values.resource_key\",\n \"name\": \"coded_values.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"coded_values\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"cms_inpatient_claims.DESYNPUF_ID\",\n \"name\": \"cms_inpatient_claims.DESYNPUF_ID\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"cms_inpatient_claims\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"cms_carrier_claims.DESYNPUF_ID\",\n \"name\": \"cms_carrier_claims.DESYNPUF_ID\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"cms_carrier_claims\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"cms_beneficiaries\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n }\n ]\n }\n ]\n}\n", + "format": "json", + "aliases": [ + "spec/domain-packs/medical-carrier/ontology.json", + "schema:medical-carrier@1.0.0:ontology" + ] }, { - "id": "schema:medical-epidemiology@1.0.0:measures", + "id": "pack:medical-epidemiology@1.1.0", + "title": "medical-epidemiology", + "category": "domain", + "path": "domain-pack.json", + "pack": "medical-epidemiology", + "packVersion": "1.1.0", + "text": "{\n \"id\": \"medical-epidemiology\",\n \"version\": \"1.1.0\",\n \"family\": {\n \"id\": \"medical\",\n \"version\": \"1.1.0\",\n \"label\": \"Epidemiology\"\n },\n \"execution_profile\": {\n \"version\": \"1.0.0\",\n \"targets\": {\n \"tabular\": [\n \"measures\",\n \"supplemental_measures\"\n ],\n \"graph\": [\n \"ontology\"\n ]\n },\n \"mode\": \"fixed\",\n \"include_sources\": [\n \"cdc\",\n \"cdc_metadata\",\n \"supplement\",\n \"notices\",\n \"csv_measures\",\n \"csv_supplemental_measures\"\n ],\n \"qualification\": \"Fixed source-qualified sample rows and schema-only ontology. No data generation, clinical conformance or graph-storage execution claim.\"\n },\n \"description\": \"Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.\",\n \"domain_types\": {\n \"source_qualified_identity\": {\n \"description\": \"Source namespace and native identity; no inferred patient identity.\"\n },\n \"exact_native_literal\": {\n \"description\": \"Numeric and temporal source spelling retained as text.\"\n }\n },\n \"schemas\": [\n {\n \"id\": \"measures\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/measures.json\"\n },\n {\n \"id\": \"supplemental_measures\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/supplemental_measures.json\"\n },\n {\n \"id\": \"ontology\",\n \"format\": \"umf\",\n \"reference\": \"ontology.json\"\n }\n ],\n \"sources\": {\n \"cdc\": {\n \"kind\": \"external\",\n \"data_kind\": \"observed\",\n \"reference\": \"sources/cdc-mortality.json\",\n \"format\": \"json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"8a21a792545b670db71b8a53b86b09d75bc471f9c327c5079e47d2c6a74701e4\"\n },\n \"license\": {\n \"id\": \"USGOV_WORKS\",\n \"reference\": \"https://data.cdc.gov/api/views/bi63-dtpu.json\",\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"CDC/NCHS\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://data.cdc.gov/resource/bi63-dtpu.json?$limit=12&$order=year,state,cause_name\",\n \"transformations\": []\n },\n \"revision\": \"bi63-dtpu-rowsUpdatedAt-1571926785\"\n },\n \"cdc_metadata\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"sources/cdc-metadata.json\",\n \"format\": \"json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"abd2439f7c8f43d9cc551bf9fcb805fb191f57385d69a2250ef6619a9b5b3592\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"CDC/NCHS\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"supplement\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/supplement.json\",\n \"format\": \"json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"847575df6aacdc8e2aa007267125f8d3729d6946b6ee8eb8380597fc20c7823b\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"wonder\": {\n \"kind\": \"external\",\n \"data_kind\": \"observed\",\n \"reference\": \"https://wonder.cdc.gov/\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"CDC/NCHS\"\n }\n },\n \"notices\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"format\": \"text\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"fd61c614ae31a5b53877fc0f4246c3f444057f58fb1c0df9f6772bf1b2e77978\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"csv_measures\": {\n \"kind\": \"external\",\n \"data_kind\": \"observed\",\n \"reference\": \"data/measures.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-epidemiology-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"be23947804729c7a64bb5b5d0071a20e5bba619d27cfaa5504188482969f71ab\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"cdc\",\n \"cdc_metadata\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_supplemental_measures\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/supplemental_measures.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-epidemiology-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"05cd03ec8cf05416a2cf296b5272b0540bd87ffd0e44cfc6399c1f93524de415\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"supplement\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n }\n },\n \"source_bindings\": [\n {\n \"schema_id\": \"measures\",\n \"source_id\": \"csv_measures\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"measures\",\n \"source_id\": \"cdc\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"measures\",\n \"source_id\": \"cdc_metadata\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"supplemental_measures\",\n \"source_id\": \"csv_supplemental_measures\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"supplemental_measures\",\n \"source_id\": \"supplement\",\n \"role\": \"reference\"\n }\n ],\n \"csv_conventions\": {\n \"encoding\": \"UTF-8\",\n \"null_value\": \"\\\\N\",\n \"header\": true,\n \"quote\": \"\\\"\"\n },\n \"fixture_counts\": {\n \"measures\": 12,\n \"supplemental_measures\": 2\n },\n \"qualification\": {\n \"subset\": \"12 CDC/NCHS leading-causes-of-death aggregate records and two separate fabricated zero/suppression cases.\",\n \"limits\": \"Observed deaths and age-adjusted rates use native international ICD-10 cause groups, not ICD-10-CM billing diagnoses. Source rows omit denominators and uncertainty. No rate recomputation, inference of patients, epidemiological comparability or current-year surveillance is claimed.\"\n }\n}\n", + "format": "json", + "description": "Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.", + "assets": [ + { + "id": "cdc", + "reference": "sources/cdc-mortality.json", + "url": "pack-assets/medical-epidemiology%401.1.0/sources/cdc-mortality.json", + "format": "json", + "dataKind": "observed", + "sha256": "8a21a792545b670db71b8a53b86b09d75bc471f9c327c5079e47d2c6a74701e4", + "revision": "bi63-dtpu-rowsUpdatedAt-1571926785" + }, + { + "id": "cdc_metadata", + "reference": "sources/cdc-metadata.json", + "url": "pack-assets/medical-epidemiology%401.1.0/sources/cdc-metadata.json", + "format": "json", + "dataKind": "unknown", + "sha256": "abd2439f7c8f43d9cc551bf9fcb805fb191f57385d69a2250ef6619a9b5b3592" + }, + { + "id": "supplement", + "reference": "sources/supplement.json", + "url": "pack-assets/medical-epidemiology%401.1.0/sources/supplement.json", + "format": "json", + "dataKind": "fabricated", + "sha256": "847575df6aacdc8e2aa007267125f8d3729d6946b6ee8eb8380597fc20c7823b" + }, + { + "id": "notices", + "reference": "licenses/NOTICE.txt", + "url": "pack-assets/medical-epidemiology%401.1.0/licenses/NOTICE.txt", + "format": "text", + "dataKind": "unknown", + "sha256": "fd61c614ae31a5b53877fc0f4246c3f444057f58fb1c0df9f6772bf1b2e77978" + }, + { + "id": "csv_measures", + "reference": "data/measures.csv", + "url": "pack-assets/medical-epidemiology%401.1.0/data/measures.csv", + "format": "csv", + "dataKind": "observed", + "sha256": "be23947804729c7a64bb5b5d0071a20e5bba619d27cfaa5504188482969f71ab", + "revision": "medical-epidemiology-1.1.0" + }, + { + "id": "csv_supplemental_measures", + "reference": "data/supplemental_measures.csv", + "url": "pack-assets/medical-epidemiology%401.1.0/data/supplemental_measures.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "05cd03ec8cf05416a2cf296b5272b0540bd87ffd0e44cfc6399c1f93524de415", + "revision": "medical-epidemiology-1.1.0" + } + ], + "aliases": [ + "pack:medical-epidemiology@1.0.0" + ] + }, + { + "id": "schema:medical-epidemiology@1.1.0:measures", "title": "measures", "category": "domain", "path": "umf/measures.json", "pack": "medical-epidemiology", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"measures\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 12 CDC/NCHS leading-causes-of-death aggregate records and two separate fabricated zero/suppression cases.\",\n \"columns\": [\n {\n \"name\": \"measure_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"measure key\"\n },\n {\n \"name\": \"source_id\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"source id\"\n },\n {\n \"name\": \"year\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"year\"\n },\n {\n \"name\": \"geography\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"geography\"\n },\n {\n \"name\": \"geography_vintage\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"geography vintage\"\n },\n {\n \"name\": \"cause\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"cause\"\n },\n {\n \"name\": \"case_definition\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"case definition\"\n },\n {\n \"name\": \"measure\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"measure\"\n },\n {\n \"name\": \"count\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"count\"\n },\n {\n \"name\": \"count_status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"count status\"\n },\n {\n \"name\": \"adjusted_rate\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"adjusted rate\"\n },\n {\n \"name\": \"rate_status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"rate status\"\n },\n {\n \"name\": \"rate_unit\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"rate unit\"\n },\n {\n \"name\": \"adjustment\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"adjustment\"\n },\n {\n \"name\": \"population_denominator\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"population denominator\"\n },\n {\n \"name\": \"denominator_status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"denominator status\"\n },\n {\n \"name\": \"uncertainty_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"uncertainty json\"\n },\n {\n \"name\": \"native_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"native json\"\n }\n ],\n \"primary_key\": [\n \"measure_key\"\n ]\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-epidemiology/umf/measures.json" + "spec/domain-packs/medical-epidemiology/umf/measures.json", + "schema:medical-epidemiology@1.0.0:measures" ] }, { - "id": "schema:medical-epidemiology@1.0.0:supplemental_measures", + "id": "schema:medical-epidemiology@1.1.0:supplemental_measures", "title": "supplemental_measures", "category": "domain", "path": "umf/supplemental_measures.json", "pack": "medical-epidemiology", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"supplemental_measures\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 12 CDC/NCHS leading-causes-of-death aggregate records and two separate fabricated zero/suppression cases.\",\n \"columns\": [\n {\n \"name\": \"measure_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"measure key\"\n },\n {\n \"name\": \"source_id\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"source id\"\n },\n {\n \"name\": \"year\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"year\"\n },\n {\n \"name\": \"geography\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"geography\"\n },\n {\n \"name\": \"geography_vintage\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"geography vintage\"\n },\n {\n \"name\": \"cause\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"cause\"\n },\n {\n \"name\": \"case_definition\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"case definition\"\n },\n {\n \"name\": \"measure\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"measure\"\n },\n {\n \"name\": \"count\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"count\"\n },\n {\n \"name\": \"count_status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"count status\"\n },\n {\n \"name\": \"adjusted_rate\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"adjusted rate\"\n },\n {\n \"name\": \"rate_status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"rate status\"\n },\n {\n \"name\": \"rate_unit\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"rate unit\"\n },\n {\n \"name\": \"adjustment\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"adjustment\"\n },\n {\n \"name\": \"population_denominator\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"population denominator\"\n },\n {\n \"name\": \"denominator_status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"denominator status\"\n },\n {\n \"name\": \"uncertainty_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"uncertainty json\"\n },\n {\n \"name\": \"native_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"native json\"\n }\n ],\n \"primary_key\": [\n \"measure_key\"\n ]\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-epidemiology/umf/supplemental_measures.json" + "spec/domain-packs/medical-epidemiology/umf/supplemental_measures.json", + "schema:medical-epidemiology@1.0.0:supplemental_measures" ] }, { - "id": "pack:medical-imaging@1.0.0", - "title": "medical-imaging", + "id": "schema:medical-epidemiology@1.1.0:ontology", + "title": "medical-epidemiology ontology", "category": "domain", - "path": "domain-pack.json", - "pack": "medical-imaging", - "packVersion": "1.0.0", - "text": "{\n \"id\": \"medical-imaging\",\n \"version\": \"1.0.0\",\n \"description\": \"Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.\",\n \"domain_types\": {\n \"source_qualified_identity\": {\n \"description\": \"Source namespace and native identity; no inferred patient identity.\"\n },\n \"exact_native_literal\": {\n \"description\": \"Numeric and temporal source spelling retained as text.\"\n }\n },\n \"schemas\": [\n {\n \"id\": \"instances\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/instances.json\"\n },\n {\n \"id\": \"attributes\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/attributes.json\"\n }\n ],\n \"sources\": {\n \"dicom_json\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/synthetic-dicom.json\",\n \"format\": \"dicom-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"e6e9beff8acc1a07d1a059f9f75890d6616e90bde906123b3022436e5419ada4\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-synthetic-1.0.0\"\n },\n \"dicom_binary\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/synthetic.dcm\",\n \"format\": \"dicom-part10\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"54f23548d26d998a92fac698f829f330d19bf8633bab848a5b33da5710e1db1d\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"provenance\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"sources/provenance.json\",\n \"format\": \"json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"41ecb95b1f4c857fc6149d6b0d3c05a0679d241c2b5e8a2cc34cae5a99f0e30c\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"tcia\": {\n \"kind\": \"external\",\n \"data_kind\": \"deidentified\",\n \"reference\": \"https://www.cancerimagingarchive.net/data-usage-policies-and-restrictions/\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"The Cancer Imaging Archive\"\n }\n },\n \"notices\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"format\": \"text\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"5406b7be08334dbd64bcfb0523895a594fd39992a4196ebe5398e3baefd53804\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"csv_instances\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/instances.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-imaging-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"78a44cc081c21c2c7a4efde37309458ec474953ca6df7924933ced31f5bca552\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"dicom_json\",\n \"dicom_binary\",\n \"provenance\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_attributes\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/attributes.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-imaging-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"414edf65a0f5c21865bb296a5e150ddaa7cbb60817bd9a257f94ad4340ca7f8e\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"dicom_json\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n }\n },\n \"source_bindings\": [\n {\n \"schema_id\": \"instances\",\n \"source_id\": \"csv_instances\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"instances\",\n \"source_id\": \"dicom_json\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"instances\",\n \"source_id\": \"dicom_binary\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"instances\",\n \"source_id\": \"provenance\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"attributes\",\n \"source_id\": \"csv_attributes\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"attributes\",\n \"source_id\": \"dicom_json\",\n \"role\": \"reference\"\n }\n ],\n \"csv_conventions\": {\n \"encoding\": \"UTF-8\",\n \"null_value\": \"\\\\N\",\n \"header\": true,\n \"quote\": \"\\\"\"\n },\n \"fixture_counts\": {\n \"instances\": 1,\n \"attributes\": 24\n },\n \"qualification\": {\n \"native_format\": \"DICOM Part 10 Explicit VR Little Endian and DICOM JSON\",\n \"subset\": \"One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence.\",\n \"projection_losses\": [\n \"pydicom DICOM JSON normalizes native DS decimal spellings (1.2500 to 1.25); original spellings remain in the unchanged binary object. File-meta elements and preamble are binary-only, retained in the original.\"\n ],\n \"limits\": \"Native metadata and original binary retention only. No public patient images, pixel decoding, full IOD conformance, DICOMweb or live PACS operations. TCIA remains a collection-specific rights/access candidate; no TCIA bytes are bundled.\"\n }\n}\n", + "path": "ontology.json", + "pack": "medical-epidemiology", + "packVersion": "1.1.0", + "schemaFormat": "umf", + "text": "{\n \"umf\": \"0.8.0\",\n \"id\": \"urn:umf:domain:medical-epidemiology\",\n \"title\": \"medical-epidemiology ontology\",\n \"vocabularies\": {},\n \"modules\": [\n {\n \"id\": \"domain\",\n \"namespace\": \"urn:umf:domain:medical-epidemiology:\",\n \"elements\": [\n {\n \"id\": \"measures\",\n \"kind\": \"record\",\n \"name\": \"measures\",\n \"title\": \"measures\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 12 CDC/NCHS leading-causes-of-death aggregate records and two separate fabricated zero/suppression cases.\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"measures.measure_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.source_id\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.year\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.geography\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.geography_vintage\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.cause\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.case_definition\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.measure\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.count\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.count_status\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.adjusted_rate\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.rate_status\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.rate_unit\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.adjustment\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.population_denominator\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.denominator_status\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.uncertainty_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"measures.native_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"measures.measure_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"measures.measure_key\",\n \"name\": \"measure_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"measure key\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.source_id\",\n \"name\": \"source_id\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"source id\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.year\",\n \"name\": \"year\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"year\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.geography\",\n \"name\": \"geography\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"geography\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.geography_vintage\",\n \"name\": \"geography_vintage\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"geography vintage\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.cause\",\n \"name\": \"cause\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"cause\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.case_definition\",\n \"name\": \"case_definition\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"case definition\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.measure\",\n \"name\": \"measure\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"measure\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.count\",\n \"name\": \"count\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"count\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.count_status\",\n \"name\": \"count_status\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"count status\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.adjusted_rate\",\n \"name\": \"adjusted_rate\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"adjusted rate\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.rate_status\",\n \"name\": \"rate_status\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"rate status\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.rate_unit\",\n \"name\": \"rate_unit\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"rate unit\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.adjustment\",\n \"name\": \"adjustment\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"adjustment\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.population_denominator\",\n \"name\": \"population_denominator\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"population denominator\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.denominator_status\",\n \"name\": \"denominator_status\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"denominator status\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.uncertainty_json\",\n \"name\": \"uncertainty_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"uncertainty json\",\n \"extensions\": {}\n },\n {\n \"id\": \"measures.native_json\",\n \"name\": \"native_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native json\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures\",\n \"kind\": \"record\",\n \"name\": \"supplemental_measures\",\n \"title\": \"supplemental_measures\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 12 CDC/NCHS leading-causes-of-death aggregate records and two separate fabricated zero/suppression cases.\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.measure_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.source_id\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.year\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.geography\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.geography_vintage\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.cause\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.case_definition\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.measure\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.count\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.count_status\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.adjusted_rate\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.rate_status\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.rate_unit\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.adjustment\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.population_denominator\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.denominator_status\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.uncertainty_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.native_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"supplemental_measures.measure_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.measure_key\",\n \"name\": \"measure_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"measure key\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.source_id\",\n \"name\": \"source_id\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"source id\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.year\",\n \"name\": \"year\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"year\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.geography\",\n \"name\": \"geography\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"geography\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.geography_vintage\",\n \"name\": \"geography_vintage\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"geography vintage\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.cause\",\n \"name\": \"cause\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"cause\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.case_definition\",\n \"name\": \"case_definition\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"case definition\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.measure\",\n \"name\": \"measure\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"measure\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.count\",\n \"name\": \"count\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"count\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.count_status\",\n \"name\": \"count_status\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"count status\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.adjusted_rate\",\n \"name\": \"adjusted_rate\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"adjusted rate\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.rate_status\",\n \"name\": \"rate_status\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"rate status\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.rate_unit\",\n \"name\": \"rate_unit\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"rate unit\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.adjustment\",\n \"name\": \"adjustment\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"adjustment\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.population_denominator\",\n \"name\": \"population_denominator\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"population denominator\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.denominator_status\",\n \"name\": \"denominator_status\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"denominator status\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.uncertainty_json\",\n \"name\": \"uncertainty_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"uncertainty json\",\n \"extensions\": {}\n },\n {\n \"id\": \"supplemental_measures.native_json\",\n \"name\": \"native_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native json\",\n \"extensions\": {}\n }\n ],\n \"relationships\": []\n }\n ]\n}\n", "format": "json", - "description": "Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence." + "aliases": [ + "spec/domain-packs/medical-epidemiology/ontology.json", + "schema:medical-epidemiology@1.0.0:ontology" + ] }, { - "id": "schema:medical-imaging@1.0.0:instances", + "id": "pack:medical-imaging@1.1.0", + "title": "medical-imaging", + "category": "domain", + "path": "domain-pack.json", + "pack": "medical-imaging", + "packVersion": "1.1.0", + "text": "{\n \"id\": \"medical-imaging\",\n \"version\": \"1.1.0\",\n \"family\": {\n \"id\": \"medical\",\n \"version\": \"1.1.0\",\n \"label\": \"Imaging: DICOM and PACS metadata\"\n },\n \"execution_profile\": {\n \"version\": \"1.0.0\",\n \"targets\": {\n \"tabular\": [\n \"instances\",\n \"attributes\"\n ],\n \"graph\": [\n \"ontology\"\n ]\n },\n \"mode\": \"fixed\",\n \"include_sources\": [\n \"dicom_json\",\n \"dicom_binary\",\n \"provenance\",\n \"tcia_binary\",\n \"tcia_json\",\n \"tcia_selection\",\n \"notices\",\n \"csv_instances\",\n \"csv_attributes\"\n ],\n \"qualification\": \"Fixed source-qualified sample rows and schema-only ontology. No data generation, clinical conformance or graph-storage execution claim.\"\n },\n \"description\": \"Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.\",\n \"domain_types\": {\n \"source_qualified_identity\": {\n \"description\": \"Source namespace and native identity; no inferred patient identity.\"\n },\n \"exact_native_literal\": {\n \"description\": \"Numeric and temporal source spelling retained as text.\"\n }\n },\n \"schemas\": [\n {\n \"id\": \"instances\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/instances.json\"\n },\n {\n \"id\": \"attributes\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/attributes.json\"\n },\n {\n \"id\": \"ontology\",\n \"format\": \"umf\",\n \"reference\": \"ontology.json\"\n }\n ],\n \"sources\": {\n \"dicom_json\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/synthetic-dicom.json\",\n \"format\": \"dicom-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"e6e9beff8acc1a07d1a059f9f75890d6616e90bde906123b3022436e5419ada4\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"umf-synthetic-1.0.0\"\n },\n \"dicom_binary\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/synthetic.dcm\",\n \"format\": \"dicom-part10\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"54f23548d26d998a92fac698f829f330d19bf8633bab848a5b33da5710e1db1d\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"provenance\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"sources/provenance.json\",\n \"format\": \"json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"41ecb95b1f4c857fc6149d6b0d3c05a0679d241c2b5e8a2cc34cae5a99f0e30c\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"tcia_binary\": {\n \"kind\": \"external\",\n \"data_kind\": \"deidentified\",\n \"reference\": \"sources/tcia-lidc-0001-ct.dcm\",\n \"format\": \"dicom-part10\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"4b5570f8acf2ec6cb086e21cba31d67c1ce13a75897bc759d360d8805d570576\"\n },\n \"license\": {\n \"id\": \"CC-BY-3.0\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"Armato et al. (2015), Data From LIDC-IDRI, doi:10.7937/K9/TCIA.2015.LO9QL9SX\"\n },\n \"provenance\": {\n \"publisher\": \"TCIA\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"2015 DOI; exact API snapshot retrieved 2026-10-08\"\n },\n \"tcia_json\": {\n \"kind\": \"external\",\n \"data_kind\": \"deidentified\",\n \"reference\": \"sources/tcia-lidc-0001-ct.json\",\n \"format\": \"dicom-json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"dce66b9233f07dbe028cad501b7147e8d627b030701fbf3395bfdd4b1072005d\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"TCIA / UMF projection\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n },\n \"revision\": \"2015 DOI; exact API snapshot retrieved 2026-10-08\"\n },\n \"tcia_selection\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"sources/tcia-selection.json\",\n \"format\": \"json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"b374d405939a3c33bd02a13138dbf3c4e963c444a330a9732fc2f18f91945f57\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"notices\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"format\": \"text\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"c810fd8653dd42fc427d84b87c9f786184a8e6df95b8e4430194bfb9904043fb\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"csv_instances\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"data/instances.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-imaging-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"a9de843fb268c76ae8454e246986df1844ae7077df6b0b459529a0db7501d9cd\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"dicom_json\",\n \"dicom_binary\",\n \"provenance\",\n \"tcia_binary\",\n \"tcia_json\",\n \"tcia_selection\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_attributes\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"data/attributes.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-imaging-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"642ad1c908d4abbf35b609e7e100a6192df48c950a2fffc79b63ce1863af9070\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"dicom_json\",\n \"tcia_json\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n }\n },\n \"source_bindings\": [\n {\n \"schema_id\": \"instances\",\n \"source_id\": \"csv_instances\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"instances\",\n \"source_id\": \"dicom_json\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"instances\",\n \"source_id\": \"dicom_binary\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"instances\",\n \"source_id\": \"provenance\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"instances\",\n \"source_id\": \"tcia_binary\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"instances\",\n \"source_id\": \"tcia_json\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"instances\",\n \"source_id\": \"tcia_selection\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"attributes\",\n \"source_id\": \"csv_attributes\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"attributes\",\n \"source_id\": \"dicom_json\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"attributes\",\n \"source_id\": \"tcia_json\",\n \"role\": \"reference\"\n }\n ],\n \"csv_conventions\": {\n \"encoding\": \"UTF-8\",\n \"null_value\": \"\\\\N\",\n \"header\": true,\n \"quote\": \"\\\"\"\n },\n \"fixture_counts\": {\n \"instances\": 2,\n \"attributes\": 113\n },\n \"qualification\": {\n \"native_format\": \"DICOM Part 10 with per-instance transfer syntax and separate DICOM JSON metadata\",\n \"subset\": \"One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence; one unchanged public TCIA LIDC-IDRI CT slice with publisher-deidentified source identity.\",\n \"projection_losses\": [\n \"pydicom DICOM JSON normalizes native DS decimal spellings (1.2500 to 1.25); original spellings remain in the unchanged binary object. File-meta elements and preamble are binary-only, retained in the original.\",\n \"DS/IS values may normalize lexical spelling in pydicom JSON; exact spelling stays in original binary.\",\n \"PixelData becomes an opaque local BulkDataURI; pixel and file-meta bytes stay in the unchanged binary.\"\n ],\n \"limits\": \"Native metadata and original binary retention only. The public CT slice is an incomplete 1/133-series selection, not a full study. Its source DICOM edition is unknown; pydicom 3.0.2 JSON inspection is the tested profile. No independent deidentification certification, pixel decoding, full IOD conformance, DICOMweb or live PACS operations.\"\n }\n}\n", + "format": "json", + "description": "Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.", + "assets": [ + { + "id": "dicom_json", + "reference": "sources/synthetic-dicom.json", + "url": "pack-assets/medical-imaging%401.1.0/sources/synthetic-dicom.json", + "format": "dicom-json", + "dataKind": "fabricated", + "sha256": "e6e9beff8acc1a07d1a059f9f75890d6616e90bde906123b3022436e5419ada4", + "revision": "umf-synthetic-1.0.0" + }, + { + "id": "dicom_binary", + "reference": "sources/synthetic.dcm", + "url": "pack-assets/medical-imaging%401.1.0/sources/synthetic.dcm", + "format": "dicom-part10", + "dataKind": "fabricated", + "sha256": "54f23548d26d998a92fac698f829f330d19bf8633bab848a5b33da5710e1db1d" + }, + { + "id": "provenance", + "reference": "sources/provenance.json", + "url": "pack-assets/medical-imaging%401.1.0/sources/provenance.json", + "format": "json", + "dataKind": "unknown", + "sha256": "41ecb95b1f4c857fc6149d6b0d3c05a0679d241c2b5e8a2cc34cae5a99f0e30c" + }, + { + "id": "tcia_binary", + "reference": "sources/tcia-lidc-0001-ct.dcm", + "url": "pack-assets/medical-imaging%401.1.0/sources/tcia-lidc-0001-ct.dcm", + "format": "dicom-part10", + "dataKind": "deidentified", + "sha256": "4b5570f8acf2ec6cb086e21cba31d67c1ce13a75897bc759d360d8805d570576", + "revision": "2015 DOI; exact API snapshot retrieved 2026-10-08" + }, + { + "id": "tcia_json", + "reference": "sources/tcia-lidc-0001-ct.json", + "url": "pack-assets/medical-imaging%401.1.0/sources/tcia-lidc-0001-ct.json", + "format": "dicom-json", + "dataKind": "deidentified", + "sha256": "dce66b9233f07dbe028cad501b7147e8d627b030701fbf3395bfdd4b1072005d", + "revision": "2015 DOI; exact API snapshot retrieved 2026-10-08" + }, + { + "id": "tcia_selection", + "reference": "sources/tcia-selection.json", + "url": "pack-assets/medical-imaging%401.1.0/sources/tcia-selection.json", + "format": "json", + "dataKind": "unknown", + "sha256": "b374d405939a3c33bd02a13138dbf3c4e963c444a330a9732fc2f18f91945f57" + }, + { + "id": "notices", + "reference": "licenses/NOTICE.txt", + "url": "pack-assets/medical-imaging%401.1.0/licenses/NOTICE.txt", + "format": "text", + "dataKind": "unknown", + "sha256": "c810fd8653dd42fc427d84b87c9f786184a8e6df95b8e4430194bfb9904043fb" + }, + { + "id": "csv_instances", + "reference": "data/instances.csv", + "url": "pack-assets/medical-imaging%401.1.0/data/instances.csv", + "format": "csv", + "dataKind": "unknown", + "sha256": "a9de843fb268c76ae8454e246986df1844ae7077df6b0b459529a0db7501d9cd", + "revision": "medical-imaging-1.1.0" + }, + { + "id": "csv_attributes", + "reference": "data/attributes.csv", + "url": "pack-assets/medical-imaging%401.1.0/data/attributes.csv", + "format": "csv", + "dataKind": "unknown", + "sha256": "642ad1c908d4abbf35b609e7e100a6192df48c950a2fffc79b63ce1863af9070", + "revision": "medical-imaging-1.1.0" + } + ], + "aliases": [ + "pack:medical-imaging@1.0.0" + ] + }, + { + "id": "schema:medical-imaging@1.1.0:instances", "title": "instances", "category": "domain", "path": "umf/instances.json", "pack": "medical-imaging", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", - "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"instances\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence.\",\n \"columns\": [\n {\n \"name\": \"instance_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"instance key\"\n },\n {\n \"name\": \"source_id\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"source id\"\n },\n {\n \"name\": \"study_uid\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"study uid\"\n },\n {\n \"name\": \"series_uid\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"series uid\"\n },\n {\n \"name\": \"sop_instance_uid\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"sop instance uid\"\n },\n {\n \"name\": \"sop_class_uid\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"sop class uid\"\n },\n {\n \"name\": \"modality\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"modality\"\n },\n {\n \"name\": \"metadata_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"metadata json\"\n },\n {\n \"name\": \"binary_reference\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"binary reference\"\n },\n {\n \"name\": \"binary_sha256\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"binary sha256\"\n },\n {\n \"name\": \"transfer_syntax\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"transfer syntax\"\n }\n ],\n \"primary_key\": [\n \"instance_key\"\n ]\n}\n", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"instances\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence; one unchanged public TCIA LIDC-IDRI CT slice with publisher-deidentified source identity.\",\n \"columns\": [\n {\n \"name\": \"instance_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"instance key\"\n },\n {\n \"name\": \"source_id\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"source id\"\n },\n {\n \"name\": \"study_uid\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"study uid\"\n },\n {\n \"name\": \"series_uid\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"series uid\"\n },\n {\n \"name\": \"sop_instance_uid\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"sop instance uid\"\n },\n {\n \"name\": \"sop_class_uid\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"sop class uid\"\n },\n {\n \"name\": \"modality\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"modality\"\n },\n {\n \"name\": \"metadata_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"metadata json\"\n },\n {\n \"name\": \"binary_reference\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"binary reference\"\n },\n {\n \"name\": \"binary_sha256\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"binary sha256\"\n },\n {\n \"name\": \"transfer_syntax\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"transfer syntax\"\n }\n ],\n \"primary_key\": [\n \"instance_key\"\n ]\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-imaging/umf/instances.json" + "spec/domain-packs/medical-imaging/umf/instances.json", + "schema:medical-imaging@1.0.0:instances" ] }, { - "id": "schema:medical-imaging@1.0.0:attributes", + "id": "schema:medical-imaging@1.1.0:attributes", "title": "attributes", "category": "domain", "path": "umf/attributes.json", "pack": "medical-imaging", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", - "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"attributes\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence.\",\n \"columns\": [\n {\n \"name\": \"attribute_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"attribute key\"\n },\n {\n \"name\": \"source_id\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"source id\"\n },\n {\n \"name\": \"native_path\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native path\"\n },\n {\n \"name\": \"tag\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"tag\"\n },\n {\n \"name\": \"vr\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"vr\"\n },\n {\n \"name\": \"value_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"value json\"\n },\n {\n \"name\": \"bulk_data_uri\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"bulk data uri\"\n },\n {\n \"name\": \"inline_binary\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"inline binary\"\n },\n {\n \"name\": \"native_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"native json\"\n }\n ],\n \"primary_key\": [\n \"attribute_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"source_id\",\n \"references_table\": \"instances\",\n \"references_column\": \"source_id\"\n }\n ]\n }\n}\n", + "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"attributes\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence; one unchanged public TCIA LIDC-IDRI CT slice with publisher-deidentified source identity.\",\n \"columns\": [\n {\n \"name\": \"attribute_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"attribute key\"\n },\n {\n \"name\": \"source_id\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"source id\"\n },\n {\n \"name\": \"native_path\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native path\"\n },\n {\n \"name\": \"tag\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"tag\"\n },\n {\n \"name\": \"vr\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"vr\"\n },\n {\n \"name\": \"value_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": true,\n \"description\": \"value json\"\n },\n {\n \"name\": \"bulk_data_uri\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"bulk data uri\"\n },\n {\n \"name\": \"inline_binary\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"inline binary\"\n },\n {\n \"name\": \"native_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"native json\"\n }\n ],\n \"primary_key\": [\n \"attribute_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"source_id\",\n \"references_table\": \"instances\",\n \"references_column\": \"source_id\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-imaging/umf/attributes.json" + "spec/domain-packs/medical-imaging/umf/attributes.json", + "schema:medical-imaging@1.0.0:attributes" ] }, { - "id": "pack:medical-terminology@1.0.0", - "title": "medical-terminology", + "id": "schema:medical-imaging@1.1.0:ontology", + "title": "medical-imaging ontology", "category": "domain", - "path": "domain-pack.json", - "pack": "medical-terminology", - "packVersion": "1.0.0", - "text": "{\n \"id\": \"medical-terminology\",\n \"version\": \"1.0.0\",\n \"description\": \"Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.\",\n \"domain_types\": {\n \"source_qualified_identity\": {\n \"description\": \"Source namespace and native identity; no inferred patient identity.\"\n },\n \"exact_native_literal\": {\n \"description\": \"Numeric and temporal source spelling retained as text.\"\n }\n },\n \"schemas\": [\n {\n \"id\": \"systems\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/systems.json\"\n },\n {\n \"id\": \"concepts\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/concepts.json\"\n }\n ],\n \"sources\": {\n \"icd10cm\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"sources/icd10cm-order-2026-subset.txt\",\n \"format\": \"icd10cm-order-text\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"183f8332624cd37f64240f46b6233b3950892bbe710caec13184fb2afbd2f9b1\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"CDC/NCHS\",\n \"retrieved_at\": \"2026-10-08\",\n \"source_ids\": [\n \"icd10cm_archive\"\n ],\n \"transformations\": [\n \"First 12 complete lines, including non-billable category records; native line bytes unchanged.\"\n ]\n },\n \"revision\": \"FY2026-2025-10-01\"\n },\n \"selection\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"sources/selection.json\",\n \"format\": \"json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"7a328013f33d3fcdfb67adda62a5dd70d174af9179418da8883689258f163c12\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"icd10cm_archive\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"https://ftp.cdc.gov/pub/Health_Statistics/NCHS/Publications/ICD10CM/2026/icd10cm-Code%20Descriptions-2026.zip\",\n \"format\": \"zip\",\n \"revision\": \"FY2026-2025-10-01\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"CDC/NCHS\"\n },\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"a852eb91b3344ae38476e63816976ee1eeb94dcced7151118324f060e8499f88\"\n }\n },\n \"icd10pcs\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"https://www.cms.gov/medicare/coding-billing/icd-10-codes\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"CMS\"\n }\n },\n \"hcpcs2\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"https://www.cms.gov/medicare/coding-billing/healthcare-common-procedure-system/quarterly-update\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"CMS\"\n }\n },\n \"snomed\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"https://www.nlm.nih.gov/healthit/snomedct/us_edition.html\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"NLM / SNOMED International\"\n }\n },\n \"cpt\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"https://www.ama-assn.org/about/cpt-editorial-panel/faq-editorial-panel-cpt-overview\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"American Medical Association\"\n }\n },\n \"notices\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"format\": \"text\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"ad61121d0fb07b2f879541a883454296f688fa6dd9a5a0b26dee97d3943ffb90\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"csv_systems\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"data/systems.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-terminology-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"a5a2fa063a954b57253b9afb34e10605f19e20b565eb037acf9f6483b533f002\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"icd10pcs\",\n \"hcpcs2\",\n \"snomed\",\n \"cpt\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_concepts\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"data/concepts.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-terminology-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"4c9d331a8e2ef23faf1c2eb0f54c7e96b90ffea6c8ee9490e62b33c515daf954\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"icd10cm\",\n \"selection\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n }\n },\n \"source_bindings\": [\n {\n \"schema_id\": \"systems\",\n \"source_id\": \"csv_systems\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"systems\",\n \"source_id\": \"icd10pcs\",\n \"role\": \"terminology\"\n },\n {\n \"schema_id\": \"systems\",\n \"source_id\": \"hcpcs2\",\n \"role\": \"terminology\"\n },\n {\n \"schema_id\": \"systems\",\n \"source_id\": \"snomed\",\n \"role\": \"terminology\"\n },\n {\n \"schema_id\": \"systems\",\n \"source_id\": \"cpt\",\n \"role\": \"terminology\"\n },\n {\n \"schema_id\": \"concepts\",\n \"source_id\": \"csv_concepts\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"concepts\",\n \"source_id\": \"icd10cm\",\n \"role\": \"terminology\"\n },\n {\n \"schema_id\": \"concepts\",\n \"source_id\": \"selection\",\n \"role\": \"terminology\"\n }\n ],\n \"csv_conventions\": {\n \"encoding\": \"UTF-8\",\n \"null_value\": \"\\\\N\",\n \"header\": true,\n \"quote\": \"\\\"\"\n },\n \"fixture_counts\": {\n \"systems\": 6,\n \"concepts\": 12\n },\n \"qualification\": {\n \"subset\": \"12 native ICD-10-CM FY2026 October 2025 order-file records; six separately identified system/access descriptors.\",\n \"limits\": \"Historical subset only, not current or exhaustive codes. SNOMED CT/CPT have no bundled dictionary or mappings. Exact consumer-local release lookup makes no clinical/billing equivalence claim. An unmatched code means not in this subset, never invalid.\"\n }\n}\n", + "path": "ontology.json", + "pack": "medical-imaging", + "packVersion": "1.1.0", + "schemaFormat": "umf", + "text": "{\n \"umf\": \"0.8.0\",\n \"id\": \"urn:umf:domain:medical-imaging\",\n \"title\": \"medical-imaging ontology\",\n \"vocabularies\": {},\n \"modules\": [\n {\n \"id\": \"domain\",\n \"namespace\": \"urn:umf:domain:medical-imaging:\",\n \"elements\": [\n {\n \"id\": \"instances\",\n \"kind\": \"record\",\n \"name\": \"instances\",\n \"title\": \"instances\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence; one unchanged public TCIA LIDC-IDRI CT slice with publisher-deidentified source identity.\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"instances.instance_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"instances.source_id\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"instances.study_uid\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"instances.series_uid\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"instances.sop_instance_uid\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"instances.sop_class_uid\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"instances.modality\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"instances.metadata_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"instances.binary_reference\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"instances.binary_sha256\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"instances.transfer_syntax\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"instances.instance_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"instances.instance_key\",\n \"name\": \"instance_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"instance key\",\n \"extensions\": {}\n },\n {\n \"id\": \"instances.source_id\",\n \"name\": \"source_id\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"source id\",\n \"extensions\": {}\n },\n {\n \"id\": \"instances.study_uid\",\n \"name\": \"study_uid\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"study uid\",\n \"extensions\": {}\n },\n {\n \"id\": \"instances.series_uid\",\n \"name\": \"series_uid\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"series uid\",\n \"extensions\": {}\n },\n {\n \"id\": \"instances.sop_instance_uid\",\n \"name\": \"sop_instance_uid\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"sop instance uid\",\n \"extensions\": {}\n },\n {\n \"id\": \"instances.sop_class_uid\",\n \"name\": \"sop_class_uid\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"sop class uid\",\n \"extensions\": {}\n },\n {\n \"id\": \"instances.modality\",\n \"name\": \"modality\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"modality\",\n \"extensions\": {}\n },\n {\n \"id\": \"instances.metadata_json\",\n \"name\": \"metadata_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"metadata json\",\n \"extensions\": {}\n },\n {\n \"id\": \"instances.binary_reference\",\n \"name\": \"binary_reference\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"binary reference\",\n \"extensions\": {}\n },\n {\n \"id\": \"instances.binary_sha256\",\n \"name\": \"binary_sha256\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"binary sha256\",\n \"extensions\": {}\n },\n {\n \"id\": \"instances.transfer_syntax\",\n \"name\": \"transfer_syntax\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"transfer syntax\",\n \"extensions\": {}\n },\n {\n \"id\": \"attributes\",\n \"kind\": \"record\",\n \"name\": \"attributes\",\n \"title\": \"attributes\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence; one unchanged public TCIA LIDC-IDRI CT slice with publisher-deidentified source identity.\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"attributes.attribute_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"attributes.source_id\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"attributes.native_path\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"attributes.tag\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"attributes.vr\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"attributes.value_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"attributes.bulk_data_uri\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"attributes.inline_binary\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"attributes.native_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"attributes.attribute_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"attributes.attribute_key\",\n \"name\": \"attribute_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"attribute key\",\n \"extensions\": {}\n },\n {\n \"id\": \"attributes.source_id\",\n \"name\": \"source_id\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"source id\",\n \"extensions\": {}\n },\n {\n \"id\": \"attributes.native_path\",\n \"name\": \"native_path\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native path\",\n \"extensions\": {}\n },\n {\n \"id\": \"attributes.tag\",\n \"name\": \"tag\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"tag\",\n \"extensions\": {}\n },\n {\n \"id\": \"attributes.vr\",\n \"name\": \"vr\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"vr\",\n \"extensions\": {}\n },\n {\n \"id\": \"attributes.value_json\",\n \"name\": \"value_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"value json\",\n \"extensions\": {}\n },\n {\n \"id\": \"attributes.bulk_data_uri\",\n \"name\": \"bulk_data_uri\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"bulk data uri\",\n \"extensions\": {}\n },\n {\n \"id\": \"attributes.inline_binary\",\n \"name\": \"inline_binary\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"inline binary\",\n \"extensions\": {}\n },\n {\n \"id\": \"attributes.native_json\",\n \"name\": \"native_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native json\",\n \"extensions\": {}\n }\n ],\n \"relationships\": [\n {\n \"id\": \"attributes.source_id\",\n \"name\": \"attributes.source_id\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"attributes\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"instances\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n }\n ]\n }\n ]\n}\n", "format": "json", - "description": "Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence." + "aliases": [ + "spec/domain-packs/medical-imaging/ontology.json", + "schema:medical-imaging@1.0.0:ontology" + ] }, { - "id": "schema:medical-terminology@1.0.0:systems", + "id": "pack:medical-terminology@1.1.0", + "title": "medical-terminology", + "category": "domain", + "path": "domain-pack.json", + "pack": "medical-terminology", + "packVersion": "1.1.0", + "text": "{\n \"id\": \"medical-terminology\",\n \"version\": \"1.1.0\",\n \"family\": {\n \"id\": \"medical\",\n \"version\": \"1.1.0\",\n \"label\": \"Terminology\"\n },\n \"execution_profile\": {\n \"version\": \"1.0.0\",\n \"targets\": {\n \"tabular\": [\n \"systems\",\n \"concepts\"\n ],\n \"graph\": [\n \"ontology\"\n ]\n },\n \"mode\": \"fixed\",\n \"include_sources\": [\n \"icd10cm\",\n \"selection\",\n \"notices\",\n \"csv_systems\",\n \"csv_concepts\"\n ],\n \"qualification\": \"Fixed source-qualified sample rows and schema-only ontology. No data generation, clinical conformance or graph-storage execution claim.\"\n },\n \"description\": \"Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.\",\n \"domain_types\": {\n \"source_qualified_identity\": {\n \"description\": \"Source namespace and native identity; no inferred patient identity.\"\n },\n \"exact_native_literal\": {\n \"description\": \"Numeric and temporal source spelling retained as text.\"\n }\n },\n \"schemas\": [\n {\n \"id\": \"systems\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/systems.json\"\n },\n {\n \"id\": \"concepts\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/concepts.json\"\n },\n {\n \"id\": \"ontology\",\n \"format\": \"umf\",\n \"reference\": \"ontology.json\"\n }\n ],\n \"sources\": {\n \"icd10cm\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"sources/icd10cm-order-2026-subset.txt\",\n \"format\": \"icd10cm-order-text\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"183f8332624cd37f64240f46b6233b3950892bbe710caec13184fb2afbd2f9b1\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"CDC/NCHS\",\n \"retrieved_at\": \"2026-10-08\",\n \"source_ids\": [\n \"icd10cm_archive\"\n ],\n \"transformations\": [\n \"First 12 complete lines, including non-billable category records; native line bytes unchanged.\"\n ]\n },\n \"revision\": \"FY2026-2025-10-01\"\n },\n \"selection\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"sources/selection.json\",\n \"format\": \"json\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"7a328013f33d3fcdfb67adda62a5dd70d174af9179418da8883689258f163c12\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"icd10cm_archive\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"https://ftp.cdc.gov/pub/Health_Statistics/NCHS/Publications/ICD10CM/2026/icd10cm-Code%20Descriptions-2026.zip\",\n \"format\": \"zip\",\n \"revision\": \"FY2026-2025-10-01\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"CDC/NCHS\"\n },\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"a852eb91b3344ae38476e63816976ee1eeb94dcced7151118324f060e8499f88\"\n }\n },\n \"icd10pcs\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"https://www.cms.gov/medicare/coding-billing/icd-10-codes\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"CMS\"\n }\n },\n \"hcpcs2\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"https://www.cms.gov/medicare/coding-billing/healthcare-common-procedure-system/quarterly-update\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"CMS\"\n }\n },\n \"snomed\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"https://www.nlm.nih.gov/healthit/snomedct/us_edition.html\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"NLM / SNOMED International\"\n }\n },\n \"cpt\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"https://www.ama-assn.org/about/cpt-editorial-panel/faq-editorial-panel-cpt-overview\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"American Medical Association\"\n }\n },\n \"notices\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"format\": \"text\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"ad61121d0fb07b2f879541a883454296f688fa6dd9a5a0b26dee97d3943ffb90\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"retrieved_at\": \"2026-10-08\",\n \"transformations\": []\n }\n },\n \"csv_systems\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"data/systems.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-terminology-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"a5a2fa063a954b57253b9afb34e10605f19e20b565eb037acf9f6483b533f002\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"icd10pcs\",\n \"hcpcs2\",\n \"snomed\",\n \"cpt\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n },\n \"csv_concepts\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"data/concepts.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-terminology-1.1.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"4c9d331a8e2ef23faf1c2eb0f54c7e96b90ffea6c8ee9490e62b33c515daf954\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"icd10cm\",\n \"selection\"\n ],\n \"transformations\": [\n \"Deterministic selected-column projection; original native sources retained separately.\"\n ]\n }\n }\n },\n \"source_bindings\": [\n {\n \"schema_id\": \"systems\",\n \"source_id\": \"csv_systems\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"systems\",\n \"source_id\": \"icd10pcs\",\n \"role\": \"terminology\"\n },\n {\n \"schema_id\": \"systems\",\n \"source_id\": \"hcpcs2\",\n \"role\": \"terminology\"\n },\n {\n \"schema_id\": \"systems\",\n \"source_id\": \"snomed\",\n \"role\": \"terminology\"\n },\n {\n \"schema_id\": \"systems\",\n \"source_id\": \"cpt\",\n \"role\": \"terminology\"\n },\n {\n \"schema_id\": \"concepts\",\n \"source_id\": \"csv_concepts\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"concepts\",\n \"source_id\": \"icd10cm\",\n \"role\": \"terminology\"\n },\n {\n \"schema_id\": \"concepts\",\n \"source_id\": \"selection\",\n \"role\": \"terminology\"\n }\n ],\n \"csv_conventions\": {\n \"encoding\": \"UTF-8\",\n \"null_value\": \"\\\\N\",\n \"header\": true,\n \"quote\": \"\\\"\"\n },\n \"fixture_counts\": {\n \"systems\": 6,\n \"concepts\": 12\n },\n \"qualification\": {\n \"subset\": \"12 native ICD-10-CM FY2026 October 2025 order-file records; six separately identified system/access descriptors.\",\n \"limits\": \"Historical subset only, not current or exhaustive codes. SNOMED CT/CPT have no bundled dictionary or mappings. Exact consumer-local release lookup makes no clinical/billing equivalence claim. An unmatched code means not in this subset, never invalid.\"\n }\n}\n", + "format": "json", + "description": "Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.", + "assets": [ + { + "id": "icd10cm", + "reference": "sources/icd10cm-order-2026-subset.txt", + "url": "pack-assets/medical-terminology%401.1.0/sources/icd10cm-order-2026-subset.txt", + "format": "icd10cm-order-text", + "dataKind": "unknown", + "sha256": "183f8332624cd37f64240f46b6233b3950892bbe710caec13184fb2afbd2f9b1", + "revision": "FY2026-2025-10-01" + }, + { + "id": "selection", + "reference": "sources/selection.json", + "url": "pack-assets/medical-terminology%401.1.0/sources/selection.json", + "format": "json", + "dataKind": "unknown", + "sha256": "7a328013f33d3fcdfb67adda62a5dd70d174af9179418da8883689258f163c12" + }, + { + "id": "notices", + "reference": "licenses/NOTICE.txt", + "url": "pack-assets/medical-terminology%401.1.0/licenses/NOTICE.txt", + "format": "text", + "dataKind": "unknown", + "sha256": "ad61121d0fb07b2f879541a883454296f688fa6dd9a5a0b26dee97d3943ffb90" + }, + { + "id": "csv_systems", + "reference": "data/systems.csv", + "url": "pack-assets/medical-terminology%401.1.0/data/systems.csv", + "format": "csv", + "dataKind": "unknown", + "sha256": "a5a2fa063a954b57253b9afb34e10605f19e20b565eb037acf9f6483b533f002", + "revision": "medical-terminology-1.1.0" + }, + { + "id": "csv_concepts", + "reference": "data/concepts.csv", + "url": "pack-assets/medical-terminology%401.1.0/data/concepts.csv", + "format": "csv", + "dataKind": "unknown", + "sha256": "4c9d331a8e2ef23faf1c2eb0f54c7e96b90ffea6c8ee9490e62b33c515daf954", + "revision": "medical-terminology-1.1.0" + } + ], + "aliases": [ + "pack:medical-terminology@1.0.0" + ] + }, + { + "id": "schema:medical-terminology@1.1.0:systems", "title": "systems", "category": "domain", "path": "umf/systems.json", "pack": "medical-terminology", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"systems\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 12 native ICD-10-CM FY2026 October 2025 order-file records; six separately identified system/access descriptors.\",\n \"columns\": [\n {\n \"name\": \"system_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"system key\"\n },\n {\n \"name\": \"system\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"system\"\n },\n {\n \"name\": \"release\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"release\"\n },\n {\n \"name\": \"availability\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"availability\"\n },\n {\n \"name\": \"description\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"description\"\n }\n ],\n \"primary_key\": [\n \"system_key\"\n ]\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-terminology/umf/systems.json" + "spec/domain-packs/medical-terminology/umf/systems.json", + "schema:medical-terminology@1.0.0:systems" ] }, { - "id": "schema:medical-terminology@1.0.0:concepts", + "id": "schema:medical-terminology@1.1.0:concepts", "title": "concepts", "category": "domain", "path": "umf/concepts.json", "pack": "medical-terminology", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"concepts\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 12 native ICD-10-CM FY2026 October 2025 order-file records; six separately identified system/access descriptors.\",\n \"columns\": [\n {\n \"name\": \"concept_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"concept key\"\n },\n {\n \"name\": \"system\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"system\"\n },\n {\n \"name\": \"release\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"release\"\n },\n {\n \"name\": \"code\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"code\"\n },\n {\n \"name\": \"billable\",\n \"data_type\": \"BOOLEAN\",\n \"nullable\": false,\n \"description\": \"billable\"\n },\n {\n \"name\": \"short_display\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"short display\"\n },\n {\n \"name\": \"display\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"display\"\n },\n {\n \"name\": \"effective_start\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"effective start\"\n },\n {\n \"name\": \"effective_end\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"effective end\"\n },\n {\n \"name\": \"native_line\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native line\"\n }\n ],\n \"primary_key\": [\n \"concept_key\"\n ]\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical-terminology/umf/concepts.json" + "spec/domain-packs/medical-terminology/umf/concepts.json", + "schema:medical-terminology@1.0.0:concepts" ] }, { - "id": "pack:medical@1.0.0", - "title": "medical", + "id": "schema:medical-terminology@1.1.0:ontology", + "title": "medical-terminology ontology", "category": "domain", - "path": "domain-pack.json", - "pack": "medical", - "packVersion": "1.0.0", - "text": "{\n \"id\": \"medical\",\n \"version\": \"1.0.0\",\n \"description\": \"Official HL7 FHIR R4 example corpus and loss-preserving tabular projections. External rows only; no synthetic fallback or clinical simulation claim.\",\n \"domain_types\": {\n \"fhir_resource_key\": {\n \"description\": \"ResourceType/native-id, scoped to the pinned HL7 R4 corpus\"\n },\n \"fhir_temporal_literal\": {\n \"description\": \"Original FHIR temporal spelling, including partial dates and timezone offsets\"\n },\n \"exact_decimal_text\": {\n \"description\": \"Source decimal spelling retained without binary-number coercion\"\n }\n },\n \"schemas\": [\n {\n \"id\": \"resources\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/resources.json\"\n },\n {\n \"id\": \"organizations\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/organizations.json\"\n },\n {\n \"id\": \"patients\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/patients.json\"\n },\n {\n \"id\": \"practitioners\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/practitioners.json\"\n },\n {\n \"id\": \"encounters\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/encounters.json\"\n },\n {\n \"id\": \"observations\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/observations.json\"\n },\n {\n \"id\": \"medications\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/medications.json\"\n },\n {\n \"id\": \"resource_references\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/resource_references.json\"\n },\n {\n \"id\": \"ontology\",\n \"format\": \"umf\",\n \"reference\": \"ontology.json\"\n }\n ],\n \"sources\": {\n \"patient-example\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/patient-example.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"7cc6b3817264c22e722b6bc10e494d3441341032f8294db7ccec796ca7a0cf81\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/patient-example.json\",\n \"transformations\": []\n }\n },\n \"patient-example-f001-pieter\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/patient-example-f001-pieter.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"707159ab47ef675765a89e07833f0146c980ef554aaffed08603b5e762a37838\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/patient-example-f001-pieter.json\",\n \"transformations\": []\n }\n },\n \"practitioner-example\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/practitioner-example.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"f7bdedca23fe131d62bbf7efae8c4dca6c691fe1ab78aa55e81b5fea43a88655\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/practitioner-example.json\",\n \"transformations\": []\n }\n },\n \"practitioner-example-f005-al\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/practitioner-example-f005-al.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"bea688cbf38ce0e07928cde2b9e4621087d2d2eb4c29b91fe01eaa864713edab\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/practitioner-example-f005-al.json\",\n \"transformations\": []\n }\n },\n \"organization-example-gastro\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/organization-example-gastro.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"8116a0f1283be32e20e5b2496467b83b32b1c79b759217c5a1937c11c7e5e2bd\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/organization-example-gastro.json\",\n \"transformations\": []\n }\n },\n \"organization-example-f001-burgers\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/organization-example-f001-burgers.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"cec6465ce1513077fc1accfa2abcd049ecd10e7dc37e73e9140bccf17b35da54\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/organization-example-f001-burgers.json\",\n \"transformations\": []\n }\n },\n \"organization-example-f002-burgers-card\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/organization-example-f002-burgers-card.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"cefea0ad3875422e835f69df47c52575552e6b4f2051e737575fea5f1e29186e\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/organization-example-f002-burgers-card.json\",\n \"transformations\": []\n }\n },\n \"encounter-example\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/encounter-example.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"6ef7c93b28fa76d3f1f1dcd3e795a8e35c70b5f86ad4659b75f7fc3d93ff0bb5\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/encounter-example.json\",\n \"transformations\": []\n }\n },\n \"observation-example-f001-glucose\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-f001-glucose.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"ce9f8dab3efbdfaa8a734e6c738956656cd444a91b823dcf4458eb833edf4a3f\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-f001-glucose.json\",\n \"transformations\": []\n }\n },\n \"observation-example-f002-excess\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-f002-excess.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"9cd95be31d43a6192d29c18b5452a16c512350f2d96d846d4caddcf4156c331a\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-f002-excess.json\",\n \"transformations\": []\n }\n },\n \"observation-example-f003-co2\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-f003-co2.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"e6c700b420ef67bb56ac6093d1131304369d5dd886785da7b68af8a54ee67140\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-f003-co2.json\",\n \"transformations\": []\n }\n },\n \"observation-example-f004-erythrocyte\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-f004-erythrocyte.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"4c9308712bc8d3b40e47686387ad0f31c02a75c0667d49e9e44b019caf9e4799\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-f004-erythrocyte.json\",\n \"transformations\": []\n }\n },\n \"observation-example-f005-hemoglobin\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-f005-hemoglobin.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"626d6cefa749e4fff6bcc6edf85d51606aa2f25db75f8268e0e734faaf8e904a\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-f005-hemoglobin.json\",\n \"transformations\": []\n }\n },\n \"observation-example-body-height\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-body-height.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"03fc509c667179aa31a781d0d3a5f278cf459a95ba8a20811376e8b80995a824\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-body-height.json\",\n \"transformations\": []\n }\n },\n \"observation-example-heart-rate\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-heart-rate.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"d87f95a9cd9b8595b875ae22c38ad73f6d93f1d60d6ee3daf05d9708de1194d3\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-heart-rate.json\",\n \"transformations\": []\n }\n },\n \"observation-example-respiratory-rate\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-respiratory-rate.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"34e17df17d4510fe8424c5e1ac9431766838747171718cab8226cfcd5a9920d9\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-respiratory-rate.json\",\n \"transformations\": []\n }\n },\n \"medicationexample1\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/medicationexample1.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"7e4840d907254db22a6aa9bce22f1c962a94a7d21cb658ac00f491af8cb37e31\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/medicationexample1.json\",\n \"transformations\": []\n }\n },\n \"csv_resources\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/resources.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"b52e08436fa98b7e0a78a69777196d70c86ff560b78ecaf127961dc3e851d58c\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"csv_organizations\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/organizations.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"ad25193bf1d73737fbfa22c80cbf92bd4905ec0e8f5185b30822e44e1aa12c4f\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"csv_patients\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/patients.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"f9850c74b803c9a9cbb61b9beb463697da73172c05d934bdec0057a10099fac8\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"csv_practitioners\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/practitioners.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"5230332e9ffda03877dd98207471cee08105d422eda9317d19fa22b9fb7d05ab\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"csv_encounters\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/encounters.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"4b84065bff25911d3f8b40610f652dc24c06ec3563de0adb7200680ca93f556d\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"csv_observations\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/observations.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"de68ab0b1dd3d8ee8568fd12e84caac5afe955927ae0c2a650793e0e75c4dc16\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"csv_medications\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/medications.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"5ba6bb3af8d3d7d8b65052fb071fda4e485805dd89d13bde995129db97d4a9d9\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"csv_resource_references\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/resource_references.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"d859681af3e620581795b805a1c0cd4ea1a5042d81613d9826eda4492fa90306\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"notices\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"format\": \"text\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"52b89f1d6f81600eb5b6ee87d1fe054a7b2de072f7762789f72d104e0cbd35b2\"\n },\n \"license\": {\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\"\n }\n },\n \"cms_blue_button\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"https://bluebutton.cms.gov/api-documentation/explore-the-api/\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference only; redistribution is not cleared and no source bytes are bundled.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"Centers for Medicare & Medicaid Services\"\n }\n },\n \"cms_synpuf\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"https://www.cms.gov/data-research/statistics-trends-and-reports/medicare-claims-synthetic-public-use-files\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference only; redistribution is not cleared and no source bytes are bundled.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"Centers for Medicare & Medicaid Services\"\n }\n },\n \"loinc_short_notice\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"licenses/LOINC_short_license.txt\",\n \"format\": \"text\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"cc1aad47fa2c13f4206daeb92dde51a95dca0850029b76bfabdfc997bd6c4985\"\n },\n \"license\": {\n \"id\": \"LicenseRef-LOINC\",\n \"reference\": \"https://loinc.org/license\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"Regenstrief Institute, Inc. and the LOINC Committee; required Section 10 notice\"\n },\n \"provenance\": {\n \"publisher\": \"Regenstrief Institute, Inc.\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://loinc.org/license\",\n \"transformations\": [\n \"Required short notice reproduced without changing its text.\"\n ]\n }\n }\n },\n \"source_bindings\": [\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"csv_resources\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"patient-example\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"patient-example-f001-pieter\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"practitioner-example\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"practitioner-example-f005-al\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"organization-example-gastro\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"organization-example-f001-burgers\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"organization-example-f002-burgers-card\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"encounter-example\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-f001-glucose\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-f002-excess\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-f003-co2\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-f004-erythrocyte\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-f005-hemoglobin\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-body-height\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-heart-rate\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-respiratory-rate\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"medicationexample1\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"organizations\",\n \"source_id\": \"csv_organizations\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"patients\",\n \"source_id\": \"csv_patients\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"practitioners\",\n \"source_id\": \"csv_practitioners\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"encounters\",\n \"source_id\": \"csv_encounters\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"observations\",\n \"source_id\": \"csv_observations\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"medications\",\n \"source_id\": \"csv_medications\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"csv_resource_references\",\n \"role\": \"rows\"\n }\n ],\n \"csv_conventions\": {\n \"encoding\": \"UTF-8\",\n \"null_value\": \"\\\\N\",\n \"header\": true,\n \"quote\": \"\\\"\"\n },\n \"fixture_counts\": {\n \"resources\": 17,\n \"organizations\": 3,\n \"patients\": 2,\n \"practitioners\": 2,\n \"encounters\": 1,\n \"observations\": 8,\n \"medications\": 1,\n \"resource_references\": 17\n },\n \"qualification\": {\n \"native_format\": \"FHIR R4 4.0.1\",\n \"subset\": \"17 selected resources; scalar observation quantities; locally resolved resource references\",\n \"clinical_representativeness\": \"not established\",\n \"source_bundle_validity\": \"not claimed; the corpus is not packaged or validated as a FHIR Bundle\"\n },\n \"execution_profile\": {\n \"version\": \"1.0.0\",\n \"targets\": {\n \"tabular\": [\n \"resources\",\n \"organizations\",\n \"patients\",\n \"practitioners\",\n \"encounters\",\n \"observations\",\n \"medications\",\n \"resource_references\"\n ],\n \"graph\": [\n \"ontology\"\n ]\n },\n \"mode\": \"fixed\",\n \"include_sources\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\",\n \"csv_resources\",\n \"csv_organizations\",\n \"csv_patients\",\n \"csv_practitioners\",\n \"csv_encounters\",\n \"csv_observations\",\n \"csv_medications\",\n \"csv_resource_references\",\n \"notices\",\n \"loinc_short_notice\"\n ],\n \"qualification\": \"Delivered tabular behavior unchanged. Graph schema candidate only; no graph storage acceptance.\"\n }\n}\n", + "path": "ontology.json", + "pack": "medical-terminology", + "packVersion": "1.1.0", + "schemaFormat": "umf", + "text": "{\n \"umf\": \"0.8.0\",\n \"id\": \"urn:umf:domain:medical-terminology\",\n \"title\": \"medical-terminology ontology\",\n \"vocabularies\": {},\n \"modules\": [\n {\n \"id\": \"domain\",\n \"namespace\": \"urn:umf:domain:medical-terminology:\",\n \"elements\": [\n {\n \"id\": \"systems\",\n \"kind\": \"record\",\n \"name\": \"systems\",\n \"title\": \"systems\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 12 native ICD-10-CM FY2026 October 2025 order-file records; six separately identified system/access descriptors.\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"systems.system_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"systems.system\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"systems.release\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"systems.availability\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"systems.description\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"systems.system_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"systems.system_key\",\n \"name\": \"system_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"system key\",\n \"extensions\": {}\n },\n {\n \"id\": \"systems.system\",\n \"name\": \"system\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"system\",\n \"extensions\": {}\n },\n {\n \"id\": \"systems.release\",\n \"name\": \"release\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"release\",\n \"extensions\": {}\n },\n {\n \"id\": \"systems.availability\",\n \"name\": \"availability\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"availability\",\n \"extensions\": {}\n },\n {\n \"id\": \"systems.description\",\n \"name\": \"description\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"description\",\n \"extensions\": {}\n },\n {\n \"id\": \"concepts\",\n \"kind\": \"record\",\n \"name\": \"concepts\",\n \"title\": \"concepts\",\n \"description\": \"Source-qualified selected view. Full original meaning remains in pinned sources. 12 native ICD-10-CM FY2026 October 2025 order-file records; six separately identified system/access descriptors.\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"concepts.concept_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"concepts.system\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"concepts.release\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"concepts.code\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"concepts.billable\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"concepts.short_display\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"concepts.display\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"concepts.effective_start\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"concepts.effective_end\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"concepts.native_line\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"concepts.concept_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"concepts.concept_key\",\n \"name\": \"concept_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"concept key\",\n \"extensions\": {}\n },\n {\n \"id\": \"concepts.system\",\n \"name\": \"system\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"system\",\n \"extensions\": {}\n },\n {\n \"id\": \"concepts.release\",\n \"name\": \"release\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"release\",\n \"extensions\": {}\n },\n {\n \"id\": \"concepts.code\",\n \"name\": \"code\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"code\",\n \"extensions\": {}\n },\n {\n \"id\": \"concepts.billable\",\n \"name\": \"billable\",\n \"kind\": \"field\",\n \"scalarType\": \"boolean\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"billable\",\n \"extensions\": {}\n },\n {\n \"id\": \"concepts.short_display\",\n \"name\": \"short_display\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"short display\",\n \"extensions\": {}\n },\n {\n \"id\": \"concepts.display\",\n \"name\": \"display\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"display\",\n \"extensions\": {}\n },\n {\n \"id\": \"concepts.effective_start\",\n \"name\": \"effective_start\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"effective start\",\n \"extensions\": {}\n },\n {\n \"id\": \"concepts.effective_end\",\n \"name\": \"effective_end\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"effective end\",\n \"extensions\": {}\n },\n {\n \"id\": \"concepts.native_line\",\n \"name\": \"native_line\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native line\",\n \"extensions\": {}\n }\n ],\n \"relationships\": []\n }\n ]\n}\n", "format": "json", - "description": "Official HL7 FHIR R4 example corpus and loss-preserving tabular projections. External rows only; no synthetic fallback or clinical simulation claim." + "aliases": [ + "spec/domain-packs/medical-terminology/ontology.json", + "schema:medical-terminology@1.0.0:ontology" + ] }, { - "id": "schema:medical@1.0.0:resources", + "id": "pack:medical@1.1.0", + "title": "medical", + "category": "domain", + "path": "domain-pack.json", + "pack": "medical", + "packVersion": "1.1.0", + "text": "{\n \"id\": \"medical\",\n \"version\": \"1.1.0\",\n \"description\": \"Official HL7 FHIR R4 example corpus and loss-preserving tabular projections. External rows only; no synthetic fallback or clinical simulation claim.\",\n \"domain_types\": {\n \"fhir_resource_key\": {\n \"description\": \"ResourceType/native-id, scoped to the pinned HL7 R4 corpus\"\n },\n \"fhir_temporal_literal\": {\n \"description\": \"Original FHIR temporal spelling, including partial dates and timezone offsets\"\n },\n \"exact_decimal_text\": {\n \"description\": \"Source decimal spelling retained without binary-number coercion\"\n }\n },\n \"schemas\": [\n {\n \"id\": \"resources\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/resources.json\"\n },\n {\n \"id\": \"organizations\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/organizations.json\"\n },\n {\n \"id\": \"patients\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/patients.json\"\n },\n {\n \"id\": \"practitioners\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/practitioners.json\"\n },\n {\n \"id\": \"encounters\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/encounters.json\"\n },\n {\n \"id\": \"observations\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/observations.json\"\n },\n {\n \"id\": \"medications\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/medications.json\"\n },\n {\n \"id\": \"resource_references\",\n \"format\": \"tablespec\",\n \"reference\": \"umf/resource_references.json\"\n },\n {\n \"id\": \"ontology\",\n \"format\": \"umf\",\n \"reference\": \"ontology.json\"\n }\n ],\n \"sources\": {\n \"patient-example\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/patient-example.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"7cc6b3817264c22e722b6bc10e494d3441341032f8294db7ccec796ca7a0cf81\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/patient-example.json\",\n \"transformations\": []\n }\n },\n \"patient-example-f001-pieter\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/patient-example-f001-pieter.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"707159ab47ef675765a89e07833f0146c980ef554aaffed08603b5e762a37838\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/patient-example-f001-pieter.json\",\n \"transformations\": []\n }\n },\n \"practitioner-example\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/practitioner-example.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"f7bdedca23fe131d62bbf7efae8c4dca6c691fe1ab78aa55e81b5fea43a88655\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/practitioner-example.json\",\n \"transformations\": []\n }\n },\n \"practitioner-example-f005-al\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/practitioner-example-f005-al.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"bea688cbf38ce0e07928cde2b9e4621087d2d2eb4c29b91fe01eaa864713edab\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/practitioner-example-f005-al.json\",\n \"transformations\": []\n }\n },\n \"organization-example-gastro\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/organization-example-gastro.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"8116a0f1283be32e20e5b2496467b83b32b1c79b759217c5a1937c11c7e5e2bd\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/organization-example-gastro.json\",\n \"transformations\": []\n }\n },\n \"organization-example-f001-burgers\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/organization-example-f001-burgers.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"cec6465ce1513077fc1accfa2abcd049ecd10e7dc37e73e9140bccf17b35da54\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/organization-example-f001-burgers.json\",\n \"transformations\": []\n }\n },\n \"organization-example-f002-burgers-card\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/organization-example-f002-burgers-card.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"cefea0ad3875422e835f69df47c52575552e6b4f2051e737575fea5f1e29186e\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/organization-example-f002-burgers-card.json\",\n \"transformations\": []\n }\n },\n \"encounter-example\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/encounter-example.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"6ef7c93b28fa76d3f1f1dcd3e795a8e35c70b5f86ad4659b75f7fc3d93ff0bb5\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/encounter-example.json\",\n \"transformations\": []\n }\n },\n \"observation-example-f001-glucose\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-f001-glucose.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"ce9f8dab3efbdfaa8a734e6c738956656cd444a91b823dcf4458eb833edf4a3f\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-f001-glucose.json\",\n \"transformations\": []\n }\n },\n \"observation-example-f002-excess\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-f002-excess.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"9cd95be31d43a6192d29c18b5452a16c512350f2d96d846d4caddcf4156c331a\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-f002-excess.json\",\n \"transformations\": []\n }\n },\n \"observation-example-f003-co2\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-f003-co2.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"e6c700b420ef67bb56ac6093d1131304369d5dd886785da7b68af8a54ee67140\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-f003-co2.json\",\n \"transformations\": []\n }\n },\n \"observation-example-f004-erythrocyte\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-f004-erythrocyte.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"4c9308712bc8d3b40e47686387ad0f31c02a75c0667d49e9e44b019caf9e4799\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-f004-erythrocyte.json\",\n \"transformations\": []\n }\n },\n \"observation-example-f005-hemoglobin\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-f005-hemoglobin.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"626d6cefa749e4fff6bcc6edf85d51606aa2f25db75f8268e0e734faaf8e904a\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-f005-hemoglobin.json\",\n \"transformations\": []\n }\n },\n \"observation-example-body-height\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-body-height.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"03fc509c667179aa31a781d0d3a5f278cf459a95ba8a20811376e8b80995a824\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-body-height.json\",\n \"transformations\": []\n }\n },\n \"observation-example-heart-rate\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-heart-rate.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"d87f95a9cd9b8595b875ae22c38ad73f6d93f1d60d6ee3daf05d9708de1194d3\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-heart-rate.json\",\n \"transformations\": []\n }\n },\n \"observation-example-respiratory-rate\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/observation-example-respiratory-rate.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"34e17df17d4510fe8424c5e1ac9431766838747171718cab8226cfcd5a9920d9\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/observation-example-respiratory-rate.json\",\n \"transformations\": []\n }\n },\n \"medicationexample1\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"sources/medicationexample1.json\",\n \"format\": \"fhir-r4-json\",\n \"revision\": \"4.0.1\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"7e4840d907254db22a6aa9bce22f1c962a94a7d21cb658ac00f491af8cb37e31\"\n },\n \"license\": {\n \"id\": \"CC0-1.0\",\n \"reference\": \"https://hl7.org/fhir/R4/license.html\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"HL7 International, FHIR R4 4.0.1 official example; third-party LOINC/UCUM notices in licenses/NOTICE.txt\",\n \"notices\": [\n \"Illustrative example, not clinical advice or a validated longitudinal simulation.\",\n \"HL7 and FHIR are registered trademarks of Health Level Seven International; use does not constitute endorsement.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"HL7 International\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://hl7.org/fhir/R4/medicationexample1.json\",\n \"transformations\": []\n }\n },\n \"csv_resources\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/resources.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"b52e08436fa98b7e0a78a69777196d70c86ff560b78ecaf127961dc3e851d58c\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"csv_organizations\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/organizations.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"ad25193bf1d73737fbfa22c80cbf92bd4905ec0e8f5185b30822e44e1aa12c4f\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"csv_patients\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/patients.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"f9850c74b803c9a9cbb61b9beb463697da73172c05d934bdec0057a10099fac8\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"csv_practitioners\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/practitioners.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"5230332e9ffda03877dd98207471cee08105d422eda9317d19fa22b9fb7d05ab\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"csv_encounters\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/encounters.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"4b84065bff25911d3f8b40610f652dc24c06ec3563de0adb7200680ca93f556d\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"csv_observations\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/observations.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"de68ab0b1dd3d8ee8568fd12e84caac5afe955927ae0c2a650793e0e75c4dc16\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"csv_medications\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/medications.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"5ba6bb3af8d3d7d8b65052fb071fda4e485805dd89d13bde995129db97d4a9d9\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"csv_resource_references\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"data/resource_references.csv\",\n \"format\": \"csv\",\n \"revision\": \"medical-1.0.0\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"d859681af3e620581795b805a1c0cd4ea1a5042d81613d9826eda4492fa90306\"\n },\n \"license\": {\n \"redistribution\": \"allowed\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"notices\": [\n \"Derivative tabular projection; original HL7 resources remain unmodified.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"UMF project\",\n \"source_ids\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\"\n ],\n \"transformations\": [\n \"Explicit selected-column projection; complete original resource bytes in resources.resource_json. Decimal and partial date/time values retained as strings. Unresolved references recorded without fabricating targets.\"\n ]\n }\n },\n \"notices\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"licenses/NOTICE.txt\",\n \"format\": \"text\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"52b89f1d6f81600eb5b6ee87d1fe054a7b2de072f7762789f72d104e0cbd35b2\"\n },\n \"license\": {\n \"redistribution\": \"allowed\"\n },\n \"provenance\": {\n \"publisher\": \"UMF project\"\n }\n },\n \"cms_blue_button\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"https://bluebutton.cms.gov/api-documentation/explore-the-api/\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference only; redistribution is not cleared and no source bytes are bundled.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"Centers for Medicare & Medicaid Services\"\n }\n },\n \"cms_synpuf\": {\n \"kind\": \"external\",\n \"data_kind\": \"fabricated\",\n \"reference\": \"https://www.cms.gov/data-research/statistics-trends-and-reports/medicare-claims-synthetic-public-use-files\",\n \"format\": \"publisher-page\",\n \"license\": {\n \"redistribution\": \"unknown\",\n \"notices\": [\n \"Reference only; redistribution is not cleared and no source bytes are bundled.\"\n ]\n },\n \"provenance\": {\n \"publisher\": \"Centers for Medicare & Medicaid Services\"\n }\n },\n \"loinc_short_notice\": {\n \"kind\": \"external\",\n \"data_kind\": \"unknown\",\n \"reference\": \"licenses/LOINC_short_license.txt\",\n \"format\": \"text\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"cc1aad47fa2c13f4206daeb92dde51a95dca0850029b76bfabdfc997bd6c4985\"\n },\n \"license\": {\n \"id\": \"LicenseRef-LOINC\",\n \"reference\": \"https://loinc.org/license\",\n \"redistribution\": \"allowed\",\n \"attribution\": \"Regenstrief Institute, Inc. and the LOINC Committee; required Section 10 notice\"\n },\n \"provenance\": {\n \"publisher\": \"Regenstrief Institute, Inc.\",\n \"retrieved_at\": \"2026-10-08\",\n \"upstream_url\": \"https://loinc.org/license\",\n \"transformations\": [\n \"Required short notice reproduced without changing its text.\"\n ]\n }\n }\n },\n \"source_bindings\": [\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"csv_resources\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"patient-example\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"patient-example-f001-pieter\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"practitioner-example\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"practitioner-example-f005-al\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"organization-example-gastro\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"organization-example-f001-burgers\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"organization-example-f002-burgers-card\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"encounter-example\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-f001-glucose\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-f002-excess\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-f003-co2\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-f004-erythrocyte\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-f005-hemoglobin\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-body-height\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-heart-rate\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"observation-example-respiratory-rate\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"resources\",\n \"source_id\": \"medicationexample1\",\n \"role\": \"reference\"\n },\n {\n \"schema_id\": \"organizations\",\n \"source_id\": \"csv_organizations\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"patients\",\n \"source_id\": \"csv_patients\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"practitioners\",\n \"source_id\": \"csv_practitioners\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"encounters\",\n \"source_id\": \"csv_encounters\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"observations\",\n \"source_id\": \"csv_observations\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"medications\",\n \"source_id\": \"csv_medications\",\n \"role\": \"rows\"\n },\n {\n \"schema_id\": \"resource_references\",\n \"source_id\": \"csv_resource_references\",\n \"role\": \"rows\"\n }\n ],\n \"csv_conventions\": {\n \"encoding\": \"UTF-8\",\n \"null_value\": \"\\\\N\",\n \"header\": true,\n \"quote\": \"\\\"\"\n },\n \"fixture_counts\": {\n \"resources\": 17,\n \"organizations\": 3,\n \"patients\": 2,\n \"practitioners\": 2,\n \"encounters\": 1,\n \"observations\": 8,\n \"medications\": 1,\n \"resource_references\": 17\n },\n \"qualification\": {\n \"native_format\": \"FHIR R4 4.0.1\",\n \"subset\": \"17 selected resources; scalar observation quantities; locally resolved resource references\",\n \"clinical_representativeness\": \"not established\",\n \"source_bundle_validity\": \"not claimed; the corpus is not packaged or validated as a FHIR Bundle\"\n },\n \"execution_profile\": {\n \"version\": \"1.0.0\",\n \"targets\": {\n \"tabular\": [\n \"resources\",\n \"organizations\",\n \"patients\",\n \"practitioners\",\n \"encounters\",\n \"observations\",\n \"medications\",\n \"resource_references\"\n ],\n \"graph\": [\n \"ontology\"\n ]\n },\n \"mode\": \"fixed\",\n \"include_sources\": [\n \"patient-example\",\n \"patient-example-f001-pieter\",\n \"practitioner-example\",\n \"practitioner-example-f005-al\",\n \"organization-example-gastro\",\n \"organization-example-f001-burgers\",\n \"organization-example-f002-burgers-card\",\n \"encounter-example\",\n \"observation-example-f001-glucose\",\n \"observation-example-f002-excess\",\n \"observation-example-f003-co2\",\n \"observation-example-f004-erythrocyte\",\n \"observation-example-f005-hemoglobin\",\n \"observation-example-body-height\",\n \"observation-example-heart-rate\",\n \"observation-example-respiratory-rate\",\n \"medicationexample1\",\n \"csv_resources\",\n \"csv_organizations\",\n \"csv_patients\",\n \"csv_practitioners\",\n \"csv_encounters\",\n \"csv_observations\",\n \"csv_medications\",\n \"csv_resource_references\",\n \"notices\",\n \"loinc_short_notice\"\n ],\n \"qualification\": \"Delivered tabular behavior unchanged. Graph schema candidate only; no graph storage acceptance.\"\n },\n \"family\": {\n \"id\": \"medical\",\n \"version\": \"1.1.0\",\n \"label\": \"Clinical\"\n },\n \"composition\": {\n \"version\": \"1.0.0\",\n \"components\": [\n {\n \"id\": \"medical-carrier\",\n \"version\": \"1.1.0\",\n \"label\": \"Carrier: eligibility, claims and payments\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"3b59727ac3f98690084c703c6f0c2c444e1e00ef0b562bb97131edaec880568c\"\n }\n },\n {\n \"id\": \"medical-epidemiology\",\n \"version\": \"1.1.0\",\n \"label\": \"Epidemiology\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"fa073eeaa754042b9015913a1eba7546bf18d8623279135856856424d4fdfdd5\"\n }\n },\n {\n \"id\": \"medical-imaging\",\n \"version\": \"1.1.0\",\n \"label\": \"Imaging: DICOM and PACS metadata\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"6fac6b9ced73a3aa8022508353c30727ea80e3ad51050a1db9a0f15da750c283\"\n }\n },\n {\n \"id\": \"medical-terminology\",\n \"version\": \"1.1.0\",\n \"label\": \"Terminology\",\n \"checksum\": {\n \"algorithm\": \"sha256\",\n \"value\": \"d67785efcacaea51de46d2e12737d9a69d84428d9380d34dda819a5c54bdd926\"\n }\n }\n ]\n }\n}\n", + "format": "json", + "description": "Official HL7 FHIR R4 example corpus and loss-preserving tabular projections. External rows only; no synthetic fallback or clinical simulation claim.", + "assets": [ + { + "id": "patient-example", + "reference": "sources/patient-example.json", + "url": "pack-assets/medical%401.1.0/sources/patient-example.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "7cc6b3817264c22e722b6bc10e494d3441341032f8294db7ccec796ca7a0cf81", + "revision": "4.0.1" + }, + { + "id": "patient-example-f001-pieter", + "reference": "sources/patient-example-f001-pieter.json", + "url": "pack-assets/medical%401.1.0/sources/patient-example-f001-pieter.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "707159ab47ef675765a89e07833f0146c980ef554aaffed08603b5e762a37838", + "revision": "4.0.1" + }, + { + "id": "practitioner-example", + "reference": "sources/practitioner-example.json", + "url": "pack-assets/medical%401.1.0/sources/practitioner-example.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "f7bdedca23fe131d62bbf7efae8c4dca6c691fe1ab78aa55e81b5fea43a88655", + "revision": "4.0.1" + }, + { + "id": "practitioner-example-f005-al", + "reference": "sources/practitioner-example-f005-al.json", + "url": "pack-assets/medical%401.1.0/sources/practitioner-example-f005-al.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "bea688cbf38ce0e07928cde2b9e4621087d2d2eb4c29b91fe01eaa864713edab", + "revision": "4.0.1" + }, + { + "id": "organization-example-gastro", + "reference": "sources/organization-example-gastro.json", + "url": "pack-assets/medical%401.1.0/sources/organization-example-gastro.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "8116a0f1283be32e20e5b2496467b83b32b1c79b759217c5a1937c11c7e5e2bd", + "revision": "4.0.1" + }, + { + "id": "organization-example-f001-burgers", + "reference": "sources/organization-example-f001-burgers.json", + "url": "pack-assets/medical%401.1.0/sources/organization-example-f001-burgers.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "cec6465ce1513077fc1accfa2abcd049ecd10e7dc37e73e9140bccf17b35da54", + "revision": "4.0.1" + }, + { + "id": "organization-example-f002-burgers-card", + "reference": "sources/organization-example-f002-burgers-card.json", + "url": "pack-assets/medical%401.1.0/sources/organization-example-f002-burgers-card.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "cefea0ad3875422e835f69df47c52575552e6b4f2051e737575fea5f1e29186e", + "revision": "4.0.1" + }, + { + "id": "encounter-example", + "reference": "sources/encounter-example.json", + "url": "pack-assets/medical%401.1.0/sources/encounter-example.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "6ef7c93b28fa76d3f1f1dcd3e795a8e35c70b5f86ad4659b75f7fc3d93ff0bb5", + "revision": "4.0.1" + }, + { + "id": "observation-example-f001-glucose", + "reference": "sources/observation-example-f001-glucose.json", + "url": "pack-assets/medical%401.1.0/sources/observation-example-f001-glucose.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "ce9f8dab3efbdfaa8a734e6c738956656cd444a91b823dcf4458eb833edf4a3f", + "revision": "4.0.1" + }, + { + "id": "observation-example-f002-excess", + "reference": "sources/observation-example-f002-excess.json", + "url": "pack-assets/medical%401.1.0/sources/observation-example-f002-excess.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "9cd95be31d43a6192d29c18b5452a16c512350f2d96d846d4caddcf4156c331a", + "revision": "4.0.1" + }, + { + "id": "observation-example-f003-co2", + "reference": "sources/observation-example-f003-co2.json", + "url": "pack-assets/medical%401.1.0/sources/observation-example-f003-co2.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "e6c700b420ef67bb56ac6093d1131304369d5dd886785da7b68af8a54ee67140", + "revision": "4.0.1" + }, + { + "id": "observation-example-f004-erythrocyte", + "reference": "sources/observation-example-f004-erythrocyte.json", + "url": "pack-assets/medical%401.1.0/sources/observation-example-f004-erythrocyte.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "4c9308712bc8d3b40e47686387ad0f31c02a75c0667d49e9e44b019caf9e4799", + "revision": "4.0.1" + }, + { + "id": "observation-example-f005-hemoglobin", + "reference": "sources/observation-example-f005-hemoglobin.json", + "url": "pack-assets/medical%401.1.0/sources/observation-example-f005-hemoglobin.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "626d6cefa749e4fff6bcc6edf85d51606aa2f25db75f8268e0e734faaf8e904a", + "revision": "4.0.1" + }, + { + "id": "observation-example-body-height", + "reference": "sources/observation-example-body-height.json", + "url": "pack-assets/medical%401.1.0/sources/observation-example-body-height.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "03fc509c667179aa31a781d0d3a5f278cf459a95ba8a20811376e8b80995a824", + "revision": "4.0.1" + }, + { + "id": "observation-example-heart-rate", + "reference": "sources/observation-example-heart-rate.json", + "url": "pack-assets/medical%401.1.0/sources/observation-example-heart-rate.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "d87f95a9cd9b8595b875ae22c38ad73f6d93f1d60d6ee3daf05d9708de1194d3", + "revision": "4.0.1" + }, + { + "id": "observation-example-respiratory-rate", + "reference": "sources/observation-example-respiratory-rate.json", + "url": "pack-assets/medical%401.1.0/sources/observation-example-respiratory-rate.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "34e17df17d4510fe8424c5e1ac9431766838747171718cab8226cfcd5a9920d9", + "revision": "4.0.1" + }, + { + "id": "medicationexample1", + "reference": "sources/medicationexample1.json", + "url": "pack-assets/medical%401.1.0/sources/medicationexample1.json", + "format": "fhir-r4-json", + "dataKind": "fabricated", + "sha256": "7e4840d907254db22a6aa9bce22f1c962a94a7d21cb658ac00f491af8cb37e31", + "revision": "4.0.1" + }, + { + "id": "csv_resources", + "reference": "data/resources.csv", + "url": "pack-assets/medical%401.1.0/data/resources.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "b52e08436fa98b7e0a78a69777196d70c86ff560b78ecaf127961dc3e851d58c", + "revision": "medical-1.0.0" + }, + { + "id": "csv_organizations", + "reference": "data/organizations.csv", + "url": "pack-assets/medical%401.1.0/data/organizations.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "ad25193bf1d73737fbfa22c80cbf92bd4905ec0e8f5185b30822e44e1aa12c4f", + "revision": "medical-1.0.0" + }, + { + "id": "csv_patients", + "reference": "data/patients.csv", + "url": "pack-assets/medical%401.1.0/data/patients.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "f9850c74b803c9a9cbb61b9beb463697da73172c05d934bdec0057a10099fac8", + "revision": "medical-1.0.0" + }, + { + "id": "csv_practitioners", + "reference": "data/practitioners.csv", + "url": "pack-assets/medical%401.1.0/data/practitioners.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "5230332e9ffda03877dd98207471cee08105d422eda9317d19fa22b9fb7d05ab", + "revision": "medical-1.0.0" + }, + { + "id": "csv_encounters", + "reference": "data/encounters.csv", + "url": "pack-assets/medical%401.1.0/data/encounters.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "4b84065bff25911d3f8b40610f652dc24c06ec3563de0adb7200680ca93f556d", + "revision": "medical-1.0.0" + }, + { + "id": "csv_observations", + "reference": "data/observations.csv", + "url": "pack-assets/medical%401.1.0/data/observations.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "de68ab0b1dd3d8ee8568fd12e84caac5afe955927ae0c2a650793e0e75c4dc16", + "revision": "medical-1.0.0" + }, + { + "id": "csv_medications", + "reference": "data/medications.csv", + "url": "pack-assets/medical%401.1.0/data/medications.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "5ba6bb3af8d3d7d8b65052fb071fda4e485805dd89d13bde995129db97d4a9d9", + "revision": "medical-1.0.0" + }, + { + "id": "csv_resource_references", + "reference": "data/resource_references.csv", + "url": "pack-assets/medical%401.1.0/data/resource_references.csv", + "format": "csv", + "dataKind": "fabricated", + "sha256": "d859681af3e620581795b805a1c0cd4ea1a5042d81613d9826eda4492fa90306", + "revision": "medical-1.0.0" + }, + { + "id": "notices", + "reference": "licenses/NOTICE.txt", + "url": "pack-assets/medical%401.1.0/licenses/NOTICE.txt", + "format": "text", + "dataKind": "unknown", + "sha256": "52b89f1d6f81600eb5b6ee87d1fe054a7b2de072f7762789f72d104e0cbd35b2" + }, + { + "id": "loinc_short_notice", + "reference": "licenses/LOINC_short_license.txt", + "url": "pack-assets/medical%401.1.0/licenses/LOINC_short_license.txt", + "format": "text", + "dataKind": "unknown", + "sha256": "cc1aad47fa2c13f4206daeb92dde51a95dca0850029b76bfabdfc997bd6c4985" + } + ], + "aliases": [ + "pack:medical@1.0.0" + ] + }, + { + "id": "schema:medical@1.1.0:resources", "title": "resources", "category": "domain", "path": "umf/resources.json", "pack": "medical", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"resources\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"resource_type\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource type\"\n },\n {\n \"name\": \"native_id\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native id\"\n },\n {\n \"name\": \"source_file\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"source file\"\n },\n {\n \"name\": \"source_sha256\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"source sha256\"\n },\n {\n \"name\": \"resource_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"resource json\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ]\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical/umf/resources.json" + "spec/domain-packs/medical/umf/resources.json", + "schema:medical@1.0.0:resources" ] }, { - "id": "schema:medical@1.0.0:organizations", + "id": "schema:medical@1.1.0:organizations", "title": "organizations", "category": "domain", "path": "umf/organizations.json", "pack": "medical", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"organizations\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"name\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"name\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical/umf/organizations.json" + "spec/domain-packs/medical/umf/organizations.json", + "schema:medical@1.0.0:organizations" ] }, { - "id": "schema:medical@1.0.0:patients", + "id": "schema:medical@1.1.0:patients", "title": "patients", "category": "domain", "path": "umf/patients.json", "pack": "medical", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"patients\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"active\",\n \"data_type\": \"BOOLEAN\",\n \"nullable\": true,\n \"description\": \"active\"\n },\n {\n \"name\": \"gender\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"gender\"\n },\n {\n \"name\": \"birth_date\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"birth date\"\n },\n {\n \"name\": \"organization_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"organization key\"\n },\n {\n \"name\": \"names_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"names json\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n },\n {\n \"column\": \"organization_key\",\n \"references_table\": \"organizations\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical/umf/patients.json" + "spec/domain-packs/medical/umf/patients.json", + "schema:medical@1.0.0:patients" ] }, { - "id": "schema:medical@1.0.0:practitioners", + "id": "schema:medical@1.1.0:practitioners", "title": "practitioners", "category": "domain", "path": "umf/practitioners.json", "pack": "medical", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"practitioners\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"active\",\n \"data_type\": \"BOOLEAN\",\n \"nullable\": true,\n \"description\": \"active\"\n },\n {\n \"name\": \"names_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"names json\"\n },\n {\n \"name\": \"qualifications_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"qualifications json\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical/umf/practitioners.json" + "spec/domain-packs/medical/umf/practitioners.json", + "schema:medical@1.0.0:practitioners" ] }, { - "id": "schema:medical@1.0.0:encounters", + "id": "schema:medical@1.1.0:encounters", "title": "encounters", "category": "domain", "path": "umf/encounters.json", "pack": "medical", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"encounters\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"patient_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"patient key\"\n },\n {\n \"name\": \"status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"status\"\n },\n {\n \"name\": \"class_system\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"class system\"\n },\n {\n \"name\": \"class_code\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"class code\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n },\n {\n \"column\": \"patient_key\",\n \"references_table\": \"patients\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical/umf/encounters.json" + "spec/domain-packs/medical/umf/encounters.json", + "schema:medical@1.0.0:encounters" ] }, { - "id": "schema:medical@1.0.0:observations", + "id": "schema:medical@1.1.0:observations", "title": "observations", "category": "domain", "path": "umf/observations.json", "pack": "medical", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"observations\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"patient_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"patient key\"\n },\n {\n \"name\": \"status\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"status\"\n },\n {\n \"name\": \"code_system\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"code system\"\n },\n {\n \"name\": \"code\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"code\"\n },\n {\n \"name\": \"display\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"display\"\n },\n {\n \"name\": \"effective_kind\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"effective kind\"\n },\n {\n \"name\": \"effective_start\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"effective start\"\n },\n {\n \"name\": \"effective_end\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"effective end\"\n },\n {\n \"name\": \"issued\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"issued\"\n },\n {\n \"name\": \"value_decimal\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"value decimal\"\n },\n {\n \"name\": \"unit_display\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"unit display\"\n },\n {\n \"name\": \"unit_system\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"unit system\"\n },\n {\n \"name\": \"unit_code\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"unit code\"\n },\n {\n \"name\": \"performers_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"performers json\"\n },\n {\n \"name\": \"interpretation_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"interpretation json\"\n },\n {\n \"name\": \"reference_ranges_json\",\n \"data_type\": \"TEXT\",\n \"nullable\": false,\n \"description\": \"reference ranges json\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n },\n {\n \"column\": \"patient_key\",\n \"references_table\": \"patients\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical/umf/observations.json" + "spec/domain-packs/medical/umf/observations.json", + "schema:medical@1.0.0:observations" ] }, { - "id": "schema:medical@1.0.0:medications", + "id": "schema:medical@1.1.0:medications", "title": "medications", "category": "domain", "path": "umf/medications.json", "pack": "medical", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"medications\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"columns\": [\n {\n \"name\": \"resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resource key\"\n },\n {\n \"name\": \"code_text\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"code text\"\n }\n ],\n \"primary_key\": [\n \"resource_key\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical/umf/medications.json" + "spec/domain-packs/medical/umf/medications.json", + "schema:medical@1.0.0:medications" ] }, { - "id": "schema:medical@1.0.0:resource_references", + "id": "schema:medical@1.1.0:resource_references", "title": "resource_references", "category": "domain", "path": "umf/resource_references.json", "pack": "medical", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "tablespec", "text": "{\n \"version\": \"1.0\",\n \"table_name\": \"resource_references\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"columns\": [\n {\n \"name\": \"reference_id\",\n \"data_type\": \"INTEGER\",\n \"nullable\": false,\n \"description\": \"reference id\"\n },\n {\n \"name\": \"source_resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"source resource key\"\n },\n {\n \"name\": \"json_pointer\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"json pointer\"\n },\n {\n \"name\": \"native_reference\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"native reference\"\n },\n {\n \"name\": \"target_resource_key\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": true,\n \"description\": \"target resource key\"\n },\n {\n \"name\": \"resolution\",\n \"data_type\": \"VARCHAR\",\n \"nullable\": false,\n \"description\": \"resolution\"\n }\n ],\n \"primary_key\": [\n \"reference_id\"\n ],\n \"relationships\": {\n \"foreign_keys\": [\n {\n \"column\": \"source_resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n },\n {\n \"column\": \"target_resource_key\",\n \"references_table\": \"resources\",\n \"references_column\": \"resource_key\"\n }\n ]\n }\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical/umf/resource_references.json" + "spec/domain-packs/medical/umf/resource_references.json", + "schema:medical@1.0.0:resource_references" ] }, { - "id": "schema:medical@1.0.0:ontology", + "id": "schema:medical@1.1.0:ontology", "title": "medical ontology", "category": "domain", "path": "ontology.json", "pack": "medical", - "packVersion": "1.0.0", + "packVersion": "1.1.0", "schemaFormat": "umf", "text": "{\n \"umf\": \"0.8.0\",\n \"id\": \"urn:umf:domain:medical\",\n \"title\": \"medical ontology\",\n \"vocabularies\": {},\n \"modules\": [\n {\n \"id\": \"domain\",\n \"namespace\": \"urn:umf:domain:medical:\",\n \"elements\": [\n {\n \"id\": \"resources\",\n \"kind\": \"record\",\n \"name\": \"resources\",\n \"title\": \"resources\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resources.resource_type\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resources.native_id\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resources.source_file\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resources.source_sha256\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resources.resource_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources.resource_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"resources.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"resources.resource_type\",\n \"name\": \"resource_type\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource type\",\n \"extensions\": {}\n },\n {\n \"id\": \"resources.native_id\",\n \"name\": \"native_id\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native id\",\n \"extensions\": {}\n },\n {\n \"id\": \"resources.source_file\",\n \"name\": \"source_file\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"source file\",\n \"extensions\": {}\n },\n {\n \"id\": \"resources.source_sha256\",\n \"name\": \"source_sha256\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"source sha256\",\n \"extensions\": {}\n },\n {\n \"id\": \"resources.resource_json\",\n \"name\": \"resource_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource json\",\n \"extensions\": {}\n },\n {\n \"id\": \"organizations\",\n \"kind\": \"record\",\n \"name\": \"organizations\",\n \"title\": \"organizations\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"organizations.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"organizations.name\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"organizations.resource_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"organizations.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"organizations.name\",\n \"name\": \"name\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"name\",\n \"extensions\": {}\n },\n {\n \"id\": \"patients\",\n \"kind\": \"record\",\n \"name\": \"patients\",\n \"title\": \"patients\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"patients.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"patients.active\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"patients.gender\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"patients.birth_date\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"patients.organization_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"patients.names_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"patients.resource_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"patients.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"patients.active\",\n \"name\": \"active\",\n \"kind\": \"field\",\n \"scalarType\": \"boolean\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"active\",\n \"extensions\": {}\n },\n {\n \"id\": \"patients.gender\",\n \"name\": \"gender\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"gender\",\n \"extensions\": {}\n },\n {\n \"id\": \"patients.birth_date\",\n \"name\": \"birth_date\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"birth date\",\n \"extensions\": {}\n },\n {\n \"id\": \"patients.organization_key\",\n \"name\": \"organization_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"organization key\",\n \"extensions\": {}\n },\n {\n \"id\": \"patients.names_json\",\n \"name\": \"names_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"names json\",\n \"extensions\": {}\n },\n {\n \"id\": \"practitioners\",\n \"kind\": \"record\",\n \"name\": \"practitioners\",\n \"title\": \"practitioners\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"practitioners.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"practitioners.active\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"practitioners.names_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"practitioners.qualifications_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"practitioners.resource_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"practitioners.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"practitioners.active\",\n \"name\": \"active\",\n \"kind\": \"field\",\n \"scalarType\": \"boolean\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"active\",\n \"extensions\": {}\n },\n {\n \"id\": \"practitioners.names_json\",\n \"name\": \"names_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"names json\",\n \"extensions\": {}\n },\n {\n \"id\": \"practitioners.qualifications_json\",\n \"name\": \"qualifications_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"qualifications json\",\n \"extensions\": {}\n },\n {\n \"id\": \"encounters\",\n \"kind\": \"record\",\n \"name\": \"encounters\",\n \"title\": \"encounters\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"encounters.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"encounters.patient_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"encounters.status\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"encounters.class_system\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"encounters.class_code\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"encounters.resource_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"encounters.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"encounters.patient_key\",\n \"name\": \"patient_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"patient key\",\n \"extensions\": {}\n },\n {\n \"id\": \"encounters.status\",\n \"name\": \"status\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"status\",\n \"extensions\": {}\n },\n {\n \"id\": \"encounters.class_system\",\n \"name\": \"class_system\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"class system\",\n \"extensions\": {}\n },\n {\n \"id\": \"encounters.class_code\",\n \"name\": \"class_code\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"class code\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations\",\n \"kind\": \"record\",\n \"name\": \"observations\",\n \"title\": \"observations\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"observations.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.patient_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.status\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.code_system\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.code\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.display\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.effective_kind\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.effective_start\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.effective_end\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.issued\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.value_decimal\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.unit_display\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.unit_system\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.unit_code\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.performers_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.interpretation_json\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"observations.reference_ranges_json\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"observations.resource_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"observations.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.patient_key\",\n \"name\": \"patient_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"patient key\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.status\",\n \"name\": \"status\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"status\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.code_system\",\n \"name\": \"code_system\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"code system\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.code\",\n \"name\": \"code\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"code\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.display\",\n \"name\": \"display\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"display\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.effective_kind\",\n \"name\": \"effective_kind\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"effective kind\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.effective_start\",\n \"name\": \"effective_start\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"effective start\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.effective_end\",\n \"name\": \"effective_end\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"effective end\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.issued\",\n \"name\": \"issued\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"issued\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.value_decimal\",\n \"name\": \"value_decimal\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"value decimal\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.unit_display\",\n \"name\": \"unit_display\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"unit display\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.unit_system\",\n \"name\": \"unit_system\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"unit system\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.unit_code\",\n \"name\": \"unit_code\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"unit code\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.performers_json\",\n \"name\": \"performers_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"performers json\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.interpretation_json\",\n \"name\": \"interpretation_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"interpretation json\",\n \"extensions\": {}\n },\n {\n \"id\": \"observations.reference_ranges_json\",\n \"name\": \"reference_ranges_json\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"reference ranges json\",\n \"extensions\": {}\n },\n {\n \"id\": \"medications\",\n \"kind\": \"record\",\n \"name\": \"medications\",\n \"title\": \"medications\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"medications.resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"medications.code_text\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"medications.resource_key\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"medications.resource_key\",\n \"name\": \"resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"medications.code_text\",\n \"name\": \"code_text\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"code text\",\n \"extensions\": {}\n },\n {\n \"id\": \"resource_references\",\n \"kind\": \"record\",\n \"name\": \"resource_references\",\n \"title\": \"resource_references\",\n \"description\": \"Projection of pinned HL7 FHIR R4 4.0.1 examples. Full original meaning retained in resources.resource_json; not clinical/population evidence.\",\n \"members\": [\n {\n \"module\": \"domain\",\n \"element\": \"resource_references.reference_id\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resource_references.source_resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resource_references.json_pointer\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resource_references.native_reference\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resource_references.target_resource_key\"\n },\n {\n \"module\": \"domain\",\n \"element\": \"resource_references.resolution\"\n }\n ],\n \"keys\": [\n {\n \"id\": \"identity\",\n \"name\": \"Identity\",\n \"fields\": [\n {\n \"module\": \"domain\",\n \"element\": \"resource_references.reference_id\"\n }\n ],\n \"primary\": true\n }\n ],\n \"extensions\": {}\n },\n {\n \"id\": \"resource_references.reference_id\",\n \"name\": \"reference_id\",\n \"kind\": \"field\",\n \"scalarType\": \"integer\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"reference id\",\n \"extensions\": {}\n },\n {\n \"id\": \"resource_references.source_resource_key\",\n \"name\": \"source_resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"source resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"resource_references.json_pointer\",\n \"name\": \"json_pointer\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"json pointer\",\n \"extensions\": {}\n },\n {\n \"id\": \"resource_references.native_reference\",\n \"name\": \"native_reference\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"native reference\",\n \"extensions\": {}\n },\n {\n \"id\": \"resource_references.target_resource_key\",\n \"name\": \"target_resource_key\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"absent-allowed\",\n \"description\": \"target resource key\",\n \"extensions\": {}\n },\n {\n \"id\": \"resource_references.resolution\",\n \"name\": \"resolution\",\n \"kind\": \"field\",\n \"scalarType\": \"string\",\n \"cardinality\": \"one\",\n \"nullability\": \"required\",\n \"description\": \"resolution\",\n \"extensions\": {}\n }\n ],\n \"relationships\": [\n {\n \"id\": \"organizations.resource_key\",\n \"name\": \"organizations.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"organizations\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"patients.resource_key\",\n \"name\": \"patients.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"patients\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"patients.organization_key\",\n \"name\": \"patients.organization_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"patients\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"organizations\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 0,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"practitioners.resource_key\",\n \"name\": \"practitioners.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"practitioners\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"encounters.resource_key\",\n \"name\": \"encounters.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"encounters\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"encounters.patient_key\",\n \"name\": \"encounters.patient_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"encounters\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"patients\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"observations.resource_key\",\n \"name\": \"observations.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"observations\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"observations.patient_key\",\n \"name\": \"observations.patient_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"observations\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"patients\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"medications.resource_key\",\n \"name\": \"medications.resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"medications\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"resource_references.source_resource_key\",\n \"name\": \"resource_references.source_resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"resource_references\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 1,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n },\n {\n \"id\": \"resource_references.target_resource_key\",\n \"name\": \"resource_references.target_resource_key\",\n \"source\": [\n {\n \"module\": \"domain\",\n \"element\": \"resource_references\"\n }\n ],\n \"target\": [\n {\n \"module\": \"domain\",\n \"element\": \"resources\",\n \"key\": \"identity\"\n }\n ],\n \"sourceMultiplicity\": {\n \"min\": 0,\n \"max\": \"*\"\n },\n \"targetMultiplicity\": {\n \"min\": 0,\n \"max\": 1\n },\n \"targetLifecycle\": \"independent\",\n \"directed\": true\n }\n ]\n }\n ]\n}\n", "format": "json", "aliases": [ - "spec/domain-packs/medical/ontology.json" + "spec/domain-packs/medical/ontology.json", + "schema:medical@1.0.0:ontology" ] }, { diff --git a/docs/helix/05-deploy/microsite/explorer-model.ts b/docs/helix/05-deploy/microsite/explorer-model.ts index b57b6bc8b..0300818de 100644 --- a/docs/helix/05-deploy/microsite/explorer-model.ts +++ b/docs/helix/05-deploy/microsite/explorer-model.ts @@ -5,7 +5,8 @@ import {importTableSpec,inspectTableSpec} from '../../../../src/adapters/tablesp import {readDocument} from '../../../../src/model/document'; import {validateDocument} from '../../../../src/validation/document'; import type {Document} from '../../../../src/model/types'; -export interface Entry {id:string;title:string;category:string;path:string;text:string;format:'json'|'yaml';pack?:string;description?:string;schemaFormat?:string;packVersion?:string;aliases?:string[]} +export interface SourceArtifact {id:string;reference:string;url:string;format:string;dataKind:string;sha256:string;revision?:string} +export interface Entry {id:string;title:string;category:string;path:string;text:string;format:'json'|'yaml';pack?:string;description?:string;schemaFormat?:string;packVersion?:string;aliases?:string[];assets?:SourceArtifact[]} export interface Definition {key:string;module:string;id:string;title:string;value:Record;pointer:string} export interface Parsed {document?:Document;native?:Record;label?:string;definitions:Definition[];diagnostics:string;valid:boolean;complete:boolean} export const key=(module:string,id:string)=>JSON.stringify([module,id]); diff --git a/docs/helix/05-deploy/microsite/explorer.ts b/docs/helix/05-deploy/microsite/explorer.ts index cc9ad455d..ae29d0a3b 100644 --- a/docs/helix/05-deploy/microsite/explorer.ts +++ b/docs/helix/05-deploy/microsite/explorer.ts @@ -59,7 +59,7 @@ function render(){ inspector.replaceChildren();if(!selected||!parsed)return;breadcrumbs();renderDownloads(inspector,selected,parsed); if(parsed.native){renderNative();return;} const doc=parsed.document!,top=node('div',undefined,'detail-top'),title=node('div');title.append(node('span',selected.category==='domain'?'Domain pack':'Example','tag'),node('h2',selected.title),node('p',doc.id,'schema-id'));top.append(title); - const download=node('a','Download source','button secondary') as HTMLAnchorElement;download.href=downloadUrl=URL.createObjectURL(new Blob([selected.text],{type:'text/plain'}));download.download=selected.path.split('/').pop()??'schema.json';download.onclick=()=>setTimeout(()=>URL.revokeObjectURL(download.href),1000);top.append(download);inspector.append(top); + const download=node('a','Download source','button secondary') as HTMLAnchorElement;download.href=downloadUrl=URL.createObjectURL(new Blob([selected.text],{type:'text/plain'}));download.download=selected.path.split('/').pop()??'schema.json';download.onclick=()=>setTimeout(()=>URL.revokeObjectURL(download.href),1000);top.append(download);inspector.append(top);renderFamily(); const stats=node('div',undefined,'stats');for(const text of [`UMF ${doc.umf}`,`${doc.modules.length} modules`,`${parsed.definitions.length} definitions`])stats.append(node('span',text,'tag'));inspector.append(stats); inspector.append(node('p',`Source: ${selected.path}`,'schema-id')); if(selected.description)inspector.append(node('p',selected.description)); @@ -82,19 +82,42 @@ function render(){ } function renderRelationships(relationships:any[]){const b=block('Relationships');for(const r of relationships){const d=node('details');d.append(node('summary',String(r.name??r.id)));for(const side of ['source','target']){const p=node('p',side+': ');for(const endpoint of r[side]??[]){p.append(reference(endpoint),document.createTextNode(' '));}d.append(p);}properties(d,r,['source','target']);b.append(d);}} function schemaLink(id:string,title:string){const a=node('a',title,'ref-link') as HTMLAnchorElement;a.href='#'+new URLSearchParams({schema:id});return a;} +function renderFamily(){ + const owner=selected&&packFor(selected);if(!owner)return; + const metadata=JSON.parse(owner.text),family=metadata.family;if(!family)return; + const root=entries.find(e=>e.id===`pack:${family.id}@${family.version}`); + const b=block('Medical family'); + if(root&&root!==owner){b.append(schemaLink(root.id,'Medical overview'));} + const rootMetadata=root?JSON.parse(root.text):undefined; + const members=[...(root?[{id:root.pack,version:root.packVersion,label:'Clinical'}]:[]),...(rootMetadata?.composition?.components??[])]; + for(const member of members){const target=entries.find(e=>e.id===`pack:${member.id}@${member.version}`),p=node('p');p.append(target?schemaLink(target.id,member.label):node('span',member.label+' · unavailable','unresolved'));p.append(node('span',` · ${member.id} ${member.version}`,'quiet'));if(target===owner)p.append(node('span',' · current','tag'));b.append(p);} + b.append(node('p','Separate source namespaces and versions; no automatic patient matching or population joins.','quiet')); +} +function renderSources(){ + const owner=selected&&packFor(selected);if(!owner?.assets?.length)return; + const metadata=JSON.parse(owner.text),b=block(selected===owner?'Sample data and originals':'Sample data'); + const rowIds=new Set((metadata.source_bindings??[]).filter((v:any)=>v.schema_id===selected!.title&&v.role==='rows').map((v:any)=>v.source_id)); + const assets=selected===owner?owner.assets:owner.assets.filter(a=>rowIds.has(a.id)); + for(const asset of assets){const p=node('p'),a=node('a',`Download ${asset.reference.split('/').pop()}`,'ref-link') as HTMLAnchorElement;a.href=asset.url;a.download=asset.reference.split('/').pop()!;p.append(a,node('span',` · ${asset.format} · ${asset.dataKind}`,'quiet'));b.append(p);} + if(!assets.length)b.append(node('p','No row source is bound to this schema.')); + if(selected!==owner)b.append(schemaLink(owner.id,'All sample data and originals')); + b.append(node('p','Downloads contain the pinned sample bytes. Source notices and scope are retained in the pack overview.','quiet')); +} function renderNative(){ const source=parsed!.native!,heading=node('div',undefined,'detail-top');heading.append(node('h2',selected!.title));inspector.append(heading,node('p',`${parsed!.label} · ${selected!.path}`,'schema-id')); + renderFamily(); if(source.description)inspector.append(node('p',String(source.description))); inspector.append(node('p',parsed!.diagnostics||'Source metadata inspection; native execution semantics are not certified.','callout')); const nav=node('div',undefined,'definition-list');const overview=schemaLink(selected!.id,'Overview');nav.append(overview);for(const def of parsed!.definitions){const a=node('a',def.title) as HTMLAnchorElement;a.href='#'+new URLSearchParams({schema:selected!.id,definition:def.key});if(def===definition)a.setAttribute('aria-current','true');nav.append(a);}inspector.append(nav); if(definition){const b=block(definition.title);b.append(node('p',definition.pointer,'schema-id'));if(definition.value.description)b.append(node('p',String(definition.value.description)));properties(b,definition.value,['description','domain_type']);if(typeof definition.value.domain_type==='string'){const p=node('p','Domain type: ');p.append(domainTypeLink(definition.value.domain_type));b.append(p);}raw(b,'Original definition metadata',definition.value,true);schemaSource();return;} if(source.domain_types){ - properties(inspector,source,['domain_types','schemas','description','scale_presets','source_bindings','sources']); + properties(inspector,source,['domain_types','schemas','description','scale_presets','source_bindings','sources',...(source.family?['family','composition','execution_profile','csv_conventions','fixture_counts','qualification']:[])]); + if(source.family){const scope=block('Sample scope');for(const field of ['subset','limits'])if(typeof source.qualification?.[field]==='string')scope.append(node('p',source.qualification[field]));if(source.qualification)raw(scope,'Detailed source qualification',source.qualification);raw(scope,'Pack composition and execution metadata',{family:source.family,...(source.composition?{composition:source.composition}:{}),execution_profile:source.execution_profile,csv_conventions:source.csv_conventions,fixture_counts:source.fixture_counts});} for(const [field,label] of [['scale_presets','Scale presets'],['source_bindings','Source bindings'],['sources','Source declarations']])if(source[field])raw(inspector,label,source[field]); const b=block('Schemas in this pack');for(const declaration of source.schemas??[]){const target=entries.find(e=>e.pack===source.id&&e.packVersion===selected!.packVersion&&e.path===declaration.reference);const p=node('p');p.append(target?schemaLink(target.id,String(declaration.id)):node('span',`${declaration.id} · ${declaration.reference} · not bundled`,'unresolved'));p.append(node('span',` · ${declaration.format}`,'quiet'));b.append(p);}if(!source.schemas?.length)b.append(node('p','No schema references declared.')); const types=block('Domain types');for(const [id,value] of Object.entries(source.domain_types)){const d=node('details');d.append(node('summary',id),node('pre',json(value)));types.append(d);} }else if(Array.isArray(source.columns)){ - const owner=packFor(selected!),targets=owner?JSON.parse(owner.text).execution_profile?.targets:undefined; + const owner=packFor(selected!),targets=owner?JSON.parse(owner.text).execution_profile?.targets:undefined; const ontology=targets?.graph?.includes('ontology')&&entries.find(e=>e.id===`schema:${selected!.pack}@${selected!.packVersion}:ontology`); if(ontology&&targets.tabular?.includes(source.table_name)){const record=parseEntry(ontology).definitions.find(d=>d.id===source.table_name&&d.value.kind==='record');if(record){const a=node('a','View ontology record','ref-link') as HTMLAnchorElement;a.href='#'+new URLSearchParams({schema:ontology.id,definition:record.key});inspector.append(a);}} const b=block('Columns'),wrap=node('div',undefined,'table-wrap'),table=node('table',undefined,'details-table'),head=node('tr');for(const label of ['Column','Native type','Nullable','Domain type'])head.append(node('th',label));table.append(head); @@ -103,6 +126,7 @@ function renderNative(){ if(source.relationships){const r=block('Native relationships');for(const fk of source.relationships.foreign_keys??[]){const target=entries.find(e=>e.pack===selected!.pack&&e.packVersion===selected!.packVersion&&e.title===fk.references_table);const p=node('p',`${fk.column} → `);p.append(target?schemaLink(target.id,`${fk.references_table}.${fk.references_column}`):node('span',`${fk.references_table}.${fk.references_column} · not bundled`,'unresolved'));r.append(p);}raw(r,'Original relationship metadata',source.relationships);} properties(inspector,source,['columns','relationships','primary_key','description','table_name']); }else{const defs=source.$defs??source.definitions??{};const b=block('Definitions');for(const [id,value] of Object.entries(defs)){const d=node('details');d.append(node('summary',id),node('pre',json(value)));b.append(d);}raw(inspector,'Schema keywords',source,true);} + renderSources(); schemaSource(); const a=node('a','Download source','button secondary') as HTMLAnchorElement;a.href=downloadUrl=URL.createObjectURL(new Blob([selected!.text],{type:'text/plain'}));a.download=selected!.path.split('/').pop()??'schema.json';a.onclick=()=>setTimeout(()=>URL.revokeObjectURL(a.href),1000);inspector.append(a); } diff --git a/docs/helix/05-deploy/microsite/verify-explorer.ts b/docs/helix/05-deploy/microsite/verify-explorer.ts index 770aa0080..9baa72a99 100644 --- a/docs/helix/05-deploy/microsite/verify-explorer.ts +++ b/docs/helix/05-deploy/microsite/verify-explorer.ts @@ -25,23 +25,55 @@ try{ }); await page.goto(origin+'/explorer.html'); // @covers US-055-AC6 - await check('Medical subpacks expose all eighteen source-qualified schemas',async()=>{ + await check('Medical subpacks expose all source-qualified tables and ontology schemas',async()=>{ for(const id of ['medical-carrier','medical-epidemiology','medical-imaging','medical-terminology']){ const metadata=await Bun.file(join(import.meta.dir,'../../../../spec/domain-packs',id,'pack.json')).json(); - const pack=page.locator(`[data-pack="pack:${id}@1.0.0"]`); + const pack=page.locator(`[data-pack="pack:${id}@${metadata.version}"]`); await pack.getByRole('button',{name:/^Overview /}).click();await page.getByRole('heading',{name:id,exact:true}).waitFor(); for(const schema of metadata.schemas){ - await pack.getByRole('button',{name:new RegExp('^'+schema.id+' ')}).click(); - await page.getByRole('heading',{name:schema.id,exact:true}).waitFor();await page.getByRole('heading',{name:'Columns',exact:true}).waitFor(); - if(new URLSearchParams(new URL(page.url()).hash.slice(1)).get('schema')!==`schema:${id}@1.0.0:${schema.id}`)throw Error('Subpack selection escaped identity'); + await pack.getByRole('button',{name:new RegExp('^'+(schema.format==='umf'?id+' ontology':schema.id)+' ')}).click(); + await page.getByRole('heading',{name:schema.format==='umf'?id+' ontology':schema.id,exact:true}).waitFor();await page.getByRole('heading',{name:schema.format==='umf'?'Records and properties':'Columns',exact:true}).waitFor(); + if(new URLSearchParams(new URL(page.url()).hash.slice(1)).get('schema')!==`schema:${id}@1.1.0:${schema.id}`)throw Error('Subpack selection escaped identity'); } } }); + // @covers US-055-AC1 @covers US-055-AC4 @covers US-055-AC6 + await check('Medical family links, public samples, exact downloads and old bookmarks',async()=>{ + await page.goto(origin+'/explorer.html#'+new URLSearchParams({schema:'pack:medical@1.0.0'})); + await page.getByRole('heading',{name:'Medical family',exact:true}).waitFor(); + if(new URLSearchParams(new URL(page.url()).hash.slice(1)).get('schema')!=='pack:medical@1.1.0')throw Error('Legacy medical bookmark did not redirect'); + const family=page.locator('#inspector .detail-block').filter({has:page.getByRole('heading',{name:'Medical family',exact:true})}); + await family.getByRole('link',{name:'Carrier: eligibility, claims and payments',exact:true}).click(); + await page.getByRole('heading',{name:'medical-carrier',exact:true}).waitFor(); + if(!(await page.locator('#inspector').innerText()).includes('13 unchanged CMS'))throw Error('Public CMS qualification missing'); + for(const [packId,name] of [['medical-carrier','cms-carrier.csv'],['medical-carrier','hl7-claim.json'],['medical-carrier','cms-beneficiaries.csv'],['medical-imaging','tcia-lidc-0001-ct.dcm'],['medical-imaging','tcia-lidc-0001-ct.json']] as const){ + await page.goto(origin+'/explorer.html#'+new URLSearchParams({schema:`pack:${packId}@1.1.0`})); + const a=page.getByRole('link',{name:'Download '+name,exact:true});await a.waitFor();const href=await a.getAttribute('href'); + const expected=new Bun.CryptoHasher('sha256').update(await Bun.file(join(import.meta.dir,'../../../../spec/domain-packs',packId,'sources',name)).arrayBuffer()).digest('hex'); + const hash=await page.evaluate(async href=>{const bytes=await(await fetch(href!)).arrayBuffer();return [...new Uint8Array(await crypto.subtle.digest('SHA-256',bytes))].map(v=>v.toString(16).padStart(2,'0')).join('');},href); + if(hash!==expected)throw Error('Changed published sample: '+name); + const pending=page.waitForEvent('download');await a.click();const download=await pending;if(download.suggestedFilename()!==name)throw Error('Wrong sample download filename'); + } + for(const [id,record] of [['medical-carrier','cms_carrier_claims'],['medical-imaging','instances'],['medical-epidemiology','measures'],['medical-terminology','concepts']] as const){ + await page.goto(origin+'/explorer.html#'+new URLSearchParams({schema:`schema:${id}@1.1.0:${record}`})); + await page.getByRole('link',{name:'View ontology record',exact:true}).click(); + await page.getByRole('heading',{name:'Outgoing relationships',exact:true}).waitFor(); + await page.getByRole('link',{name:'View corresponding table',exact:true}).click(); + if(new URLSearchParams(new URL(page.url()).hash.slice(1)).get('schema')!==`schema:${id}@1.1.0:${record}`)throw Error('Ontology/table link escaped pack'); + } + await page.goto(origin+'/explorer.html#'+new URLSearchParams({schema:'schema:medical-carrier@1.1.0:eligibility'})); + await page.getByRole('heading',{name:'Columns',exact:true}).waitFor();await page.getByRole('link',{name:'Download eligibility.csv',exact:true}).waitFor(); + await page.getByRole('link',{name:'Medical overview',exact:true}).click();await page.getByRole('heading',{name:'medical',exact:true}).waitFor(); + await page.locator('#search').fill('DICOM');if(!await page.locator('[data-pack="pack:medical-imaging@1.1.0"]').isVisible())throw Error('DICOM search omitted imaging');await page.locator('#search').fill(''); + await page.setViewportSize({width:390,height:844});await page.goto(origin+'/explorer.html#'+new URLSearchParams({schema:'pack:medical-imaging@1.1.0'}));await page.getByRole('link',{name:'Download tcia-lidc-0001-ct.dcm',exact:true}).waitFor(); + if(await page.evaluate(()=>document.documentElement.scrollWidth>window.innerWidth))throw Error('Medical family mobile overflow'); + await page.screenshot({path:'/private/tmp/umf-medical-family-mobile.png',fullPage:true});await page.setViewportSize({width:1440,height:1000}); + }); await check('Pack catalog and linked schemas',async()=>{await page.locator('[data-pack="pack:legal@1.1.0"]').getByRole('button',{name:/^Overview /}).click();await page.locator('#inspector').getByRole('link',{name:'clients',exact:true}).click();await page.getByRole('heading',{name:'Columns',exact:true}).waitFor();if(!await page.locator('#inspector').textContent().then(t=>t?.includes('client_name')))throw new Error('Missing client field');}); await check('Public dataset packs, source downloads and all sixteen schemas',async()=>{ for(const id of ['nyc-tlc','movielens','noaa-ghcn-daily','gtfs-schedule']){ const manifest=await Bun.file(join(import.meta.dir,`../../../../spec/domain-packs/${id}/pack.json`)).json(); - const pack=page.locator(`[data-pack="pack:${id}@1.0.0"]`); + const pack=page.locator(`[data-pack="pack:${id}@${manifest.version}"]`); await pack.getByRole('button',{name:/^Overview /}).click(); await page.getByRole('heading',{name:'Schemas in this pack',exact:true}).waitFor(); const href=await page.getByRole('link',{name:'Download source'}).getAttribute('href'); @@ -89,7 +121,7 @@ try{ await crumbs.getByRole('link',{name:'Legal · 1.1.0',exact:true}).click();await page.getByRole('heading',{name:'Schemas in this pack',exact:true}).waitFor(); }); await check('Medical fixed-source pack and all eight schemas',async()=>{ - const pack=page.locator('[data-pack="pack:medical@1.0.0"]'); + const pack=page.locator('[data-pack="pack:medical@1.1.0"]'); await pack.getByRole('button',{name:/^Overview /}).click();await page.getByRole('heading',{name:'medical',exact:true}).waitFor();await page.getByRole('heading',{name:'Schemas in this pack',exact:true}).waitFor(); const href=await page.getByRole('link',{name:'Download source'}).getAttribute('href');const source=await page.evaluate(async href=>await(await fetch(href!)).text(),href); if(source!==await Bun.file(join(import.meta.dir,'../../../../spec/domain-packs/medical/pack.json')).text())throw new Error('Medical manifest download changed'); @@ -100,12 +132,12 @@ try{ } }); await check('Medical domain types, foreign keys and deep links',async()=>{ - const pack=page.locator('[data-pack="pack:medical@1.0.0"]'); + const pack=page.locator('[data-pack="pack:medical@1.1.0"]'); await pack.locator('summary').filter({hasText:/^Domain types$/}).click(); for(const name of ['fhir_resource_key','fhir_temporal_literal','exact_decimal_text']){await pack.getByRole('button',{name:new RegExp('^'+name+' ')}).click();await page.getByRole('heading',{name,exact:true}).waitFor();} - await page.goto(origin+'/explorer.html#'+new URLSearchParams({schema:'schema:medical@1.0.0:observations'}));await page.getByRole('heading',{name:'Columns',exact:true}).waitFor(); + await page.goto(origin+'/explorer.html#'+new URLSearchParams({schema:'schema:medical@1.1.0:observations'}));await page.getByRole('heading',{name:'Columns',exact:true}).waitFor(); await page.locator('#inspector').getByRole('link',{name:'patients.resource_key',exact:true}).first().click();await page.getByRole('heading',{name:'patients',exact:true}).waitFor(); - if(new URLSearchParams(new URL(page.url()).hash.slice(1)).get('schema')!=='schema:medical@1.0.0:patients')throw new Error('Medical reference escaped its pack'); + if(new URLSearchParams(new URL(page.url()).hash.slice(1)).get('schema')!=='schema:medical@1.1.0:patients')throw new Error('Medical reference escaped its pack'); await page.screenshot({path:'/private/tmp/umf-medical-explorer-desktop.png',fullPage:true}); await page.setViewportSize({width:390,height:844});await page.evaluate(()=>new Promise(resolve=>requestAnimationFrame(()=>requestAnimationFrame(()=>resolve())))); if(await page.evaluate(()=>document.documentElement.scrollWidth>window.innerWidth))throw new Error('Medical mobile overflow'); diff --git a/docs/helix/05-deploy/schema-explorer-evidence.json b/docs/helix/05-deploy/schema-explorer-evidence.json index 167828905..ee0acd549 100644 --- a/docs/helix/05-deploy/schema-explorer-evidence.json +++ b/docs/helix/05-deploy/schema-explorer-evidence.json @@ -7,13 +7,14 @@ }, "catalog": { "packs": 24, - "entries": 266 + "entries": 273 }, "checks": [ "Playground YAML defaults and JSON interchange", "Domain packs start collapsed except the selected pack", "Download target preview, review gate and SQL download", - "Medical subpacks expose all eighteen source-qualified schemas", + "Medical subpacks expose all source-qualified tables and ontology schemas", + "Medical family links, public samples, exact downloads and old bookmarks", "Pack catalog and linked schemas", "Public dataset packs, source downloads and all sixteen schemas", "Ontology context, record pages, relationship map and legacy URLs", diff --git a/docs/helix/README.md b/docs/helix/README.md index a8f671736..98f888f75 100644 --- a/docs/helix/README.md +++ b/docs/helix/README.md @@ -1192,3 +1192,11 @@ profile, bounded small/demo/large replay, graph companion format and source cust [CONTRACT-053](02-design/contracts/CONTRACT-053-domain-pack-profiles.md) govern the platform; native graph intake, independent scaling axes and third-party source coverage remain explicitly qualified. + + +Medical family 1.1.0 now integrates Clinical, Carrier, Epidemiology, Imaging and +Terminology: 29 tables/five ontology schemas, qualified CMS CSV excerpts and one +CC BY 3.0 TCIA DICOM slice with retained originals. The Medical overview links +all five packs; source/row downloads, ontology/table navigation and old bookmarks +have real-browser evidence. See the [integrated medical evidence](04-build/evidence/medical-subpacks.md#integrated-medical-family-110--2026-10-08) +and [complete family export](../../spec/domain-packs/medical/README.md#complete-family-export-and-browser). diff --git a/fixtures/domain-packs/medical-1.1.0.zip b/fixtures/domain-packs/medical-1.1.0.zip new file mode 100644 index 000000000..ffbdfc0f1 Binary files /dev/null and b/fixtures/domain-packs/medical-1.1.0.zip differ diff --git a/fixtures/domain-packs/medical-carrier-1.1.0.zip b/fixtures/domain-packs/medical-carrier-1.1.0.zip new file mode 100644 index 000000000..14cc174bf Binary files /dev/null and b/fixtures/domain-packs/medical-carrier-1.1.0.zip differ diff --git a/fixtures/domain-packs/medical-epidemiology-1.1.0.zip b/fixtures/domain-packs/medical-epidemiology-1.1.0.zip new file mode 100644 index 000000000..d5d677a8a Binary files /dev/null and b/fixtures/domain-packs/medical-epidemiology-1.1.0.zip differ diff --git a/fixtures/domain-packs/medical-imaging-1.1.0.zip b/fixtures/domain-packs/medical-imaging-1.1.0.zip new file mode 100644 index 000000000..2a821ffa0 Binary files /dev/null and b/fixtures/domain-packs/medical-imaging-1.1.0.zip differ diff --git a/fixtures/domain-packs/medical-terminology-1.1.0.zip b/fixtures/domain-packs/medical-terminology-1.1.0.zip new file mode 100644 index 000000000..0c9c2c8a8 Binary files /dev/null and b/fixtures/domain-packs/medical-terminology-1.1.0.zip differ diff --git a/fixtures/validation/medical-family-integration-evidence.json b/fixtures/validation/medical-family-integration-evidence.json new file mode 100644 index 000000000..44a5106da --- /dev/null +++ b/fixtures/validation/medical-family-integration-evidence.json @@ -0,0 +1,319 @@ +{ + "date": "2026-10-08", + "scope": "US-055 integrated medical sample family 1.1.0; no production carrier/PACS or universal native conformance claim", + "base": "a6767a6c5bf17a56f8e4fe7bc4c0dbf7b1353720", + "family": { + "packs": 5, + "tables": 29, + "ontologies": 5, + "rows": 517 + }, + "sources": { + "cms": { + "release": "DE-SynPUF 1.0 Sample 1", + "beneficiaries": 3, + "inpatient_claims": 5, + "carrier_claims": 5, + "origin": "published synthetic", + "selection": "Complete native CSV records; numeric CPT/Level I HCPCS carrier rows excluded; ICD-9 preserved" + }, + "tcia": { + "collection": "LIDC-IDRI", + "license": "CC-BY-3.0", + "doi": "10.7937/K9/TCIA.2015.LO9QL9SX", + "instances": 1, + "series_instances": 133, + "origin": "publisher-deidentified", + "native_dicom_edition": "not supplied", + "qualification": "One unchanged native slice with separate pydicom metadata; no independent deidentification certification or pixel decoding claim" + } + }, + "bun": { + "version": "1.4.2", + "tests": 48, + "failures": 0, + "assertions": 3146, + "scope": "tests/domain-packs and tests/traceability" + }, + "schemas": { + "extension_packages": 61, + "canonical_schemas": 349, + "failures": 0 + }, + "browser_library": { + "chromium": "153.0.8010.12", + "checks": 68, + "status": "passed" + }, + "explorer": { + "date": "2026-10-08", + "scope": "Microsite schema explorer; no new core/native support or data generation claims", + "runtime": { + "bun": "1.4.2", + "chromium": "153.0.8010.12" + }, + "catalog": { + "packs": 24, + "entries": 273 + }, + "checks": [ + "Playground YAML defaults and JSON interchange", + "Domain packs start collapsed except the selected pack", + "Download target preview, review gate and SQL download", + "Medical subpacks expose all source-qualified tables and ontology schemas", + "Medical family links, public samples, exact downloads and old bookmarks", + "Pack catalog and linked schemas", + "Public dataset packs, source downloads and all sixteen schemas", + "Ontology context, record pages, relationship map and legacy URLs", + "Native foreign-key navigation", + "Pack hierarchy, breadcrumbs and domain-type ownership", + "Medical fixed-source pack and all eight schemas", + "Medical domain types, foreign keys and deep links", + "Field detail and history navigation", + "Search and empty state", + "Core definition and exact decimal inspection", + "Local upload, unknown retention, and inert text", + "Original source download", + "Invalid and unresolved sources refuse visibly", + "Deep links and missing selection", + "Same-named domain types stay within their pack version", + "Malformed and duplicate-key JSON refuse", + "Mobile layout and navigation", + "Existing routes expose the explorer", + "All twenty-four packs, every declared schema and ontology target navigate" + ], + "status": "passed" + }, + "native_dicom": { + "oracle": "pydicom", + "version": "3.0.2", + "python": "3.13.16", + "checks": 24, + "public_binary_sha256": "4b5570f8acf2ec6cb086e21cba31d67c1ce13a75897bc759d360d8805d570576", + "binary_sha256": "54f23548d26d998a92fac698f829f330d19bf8633bab848a5b33da5710e1db1d" + }, + "native_tabular": { + "oracle": "TableSpec local ingestion/archive", + "version": "0.0.6.post6.dev0+d2ee70a", + "python": "3.12.15", + "packs": [ + { + "pack": "medical", + "tables": 8, + "rows": 51, + "archive_sha256": "6a83001a930175d77eccf202d0636c3bc8683fffe298a67f7a44ee481747180d", + "originals": 27 + }, + { + "pack": "medical-carrier", + "tables": 15, + "rows": 319, + "archive_sha256": "7a6f9130d19759b36fecd92ebc8d20e73c563e0024afb6fa62dff4259080f807", + "originals": 49 + }, + { + "pack": "medical-epidemiology", + "tables": 2, + "rows": 14, + "archive_sha256": "3d5fa1e50961f6ebf8d04280ef44143b314503ff3afdf70354a314186a9bfc68", + "originals": 6 + }, + { + "pack": "medical-imaging", + "tables": 2, + "rows": 115, + "archive_sha256": "01221acd7c54d23146b679488b68f95acb3092bb1bd0f4f60c684fb88651b5a4", + "originals": 9 + }, + { + "pack": "medical-terminology", + "tables": 2, + "rows": 18, + "archive_sha256": "339b3238cbf8cbb9d37814d1a1c43b6aadf9ae922deb623a7538f7c4a8d76ed9", + "originals": 5 + } + ] + }, + "consumer_checkout": "01e0865c1532f8b61bd858646ee5271f8eb78593", + "other_checks": [ + "Both TypeScript configurations", + "Browser ESM and declarations", + "Deterministic medical regeneration", + "Canonical domain/source schema generation", + "Acceptance traceability inventory", + "Five existing page signatures", + "git diff --check" + ], + "limitations": [ + "Finite public examples and authored supplement coverage, not longitudinal/population realism", + "Five ontology schemas; no Truss/Ashlar storage execution acceptance", + "Licensed full dictionaries/maps, live PACS/DICOMweb/X12 and production processing remain separately governed", + "No full repository/native adapter replay claimed" + ], + "sha256": { + ".github/workflows/microsite.yml": "c96451b1e5c18e4f1723d2e5dd6d4c59f444d3ee9e71d8da546af2775be58de4", + "docs/helix/05-deploy/microsite/build-explorer.ts": "137a5f0e37fd1a276bad9346c07ff999383eae7b84de1511dc448ceef7c93774", + "docs/helix/05-deploy/microsite/dist/schema-catalog.json": "0d9a9442ed35133ed5ccf08bf22c50326bdc8c69580e7b1120244b1a9a080d51", + "docs/helix/05-deploy/microsite/explorer.ts": "e35684a10cc01fd4d4c1ea33cb714b210e468fa6a09a389be4dce7069e48c8ac", + "docs/helix/05-deploy/microsite/verify-explorer.ts": "7d4637ebe54e4d2ee2f65e4005575c90ca854591a16a6b61d9238e1805328404", + "fixtures/domain-packs/medical-1.1.0.zip": "6a83001a930175d77eccf202d0636c3bc8683fffe298a67f7a44ee481747180d", + "fixtures/domain-packs/medical-carrier-1.1.0.zip": "7a6f9130d19759b36fecd92ebc8d20e73c563e0024afb6fa62dff4259080f807", + "fixtures/domain-packs/medical-epidemiology-1.1.0.zip": "3d5fa1e50961f6ebf8d04280ef44143b314503ff3afdf70354a314186a9bfc68", + "fixtures/domain-packs/medical-imaging-1.1.0.zip": "01221acd7c54d23146b679488b68f95acb3092bb1bd0f4f60c684fb88651b5a4", + "fixtures/domain-packs/medical-terminology-1.1.0.zip": "339b3238cbf8cbb9d37814d1a1c43b6aadf9ae922deb623a7538f7c4a8d76ed9", + "scripts/build-medical-subpacks.ts": "a74d49f9985753b86a1f5633399d1294bdafa15dcf7a3023e19175861e882990", + "scripts/collect-medical-public-samples.py": "fbe20895d23c3490c8a2930ab0f960e730aa6d11b164402f59c5c73c5c1cc32c", + "scripts/domain-pack-browser.ts": "b5af64e053a9430fe9868831beb48def53b446d137ca84b1b91dd0a5daaa3b6e", + "scripts/domain-pack-family.ts": "103c2f51277a1868e55d8b70da8d40ac31d496bc87b14900e6a61a0d07080db7", + "scripts/export-domain-family.ts": "158bbb18367217224cc3ab100f92f220916d48c9f68d23bc75ee23afe0cd916b", + "scripts/export-domain-pack.ts": "dec2efacae2fc87e8ec2342a8ce5917e1eaf7d7f55e4187db789fa23167441e1", + "scripts/medical-subpacks-oracle.py": "024dc03860a915394aa3ce2c2fcb8a7baa80d780768dbd75f84928b54191063c", + "spec/domain-packs/medical/README.md": "6320036211085c58e2ccbfe2949707af609c30337f8edfa309dd3d39a8019ce5", + "spec/domain-packs/medical/data/encounters.csv": "4b84065bff25911d3f8b40610f652dc24c06ec3563de0adb7200680ca93f556d", + "spec/domain-packs/medical/data/medications.csv": "5ba6bb3af8d3d7d8b65052fb071fda4e485805dd89d13bde995129db97d4a9d9", + "spec/domain-packs/medical/data/observations.csv": "de68ab0b1dd3d8ee8568fd12e84caac5afe955927ae0c2a650793e0e75c4dc16", + "spec/domain-packs/medical/data/organizations.csv": "ad25193bf1d73737fbfa22c80cbf92bd4905ec0e8f5185b30822e44e1aa12c4f", + "spec/domain-packs/medical/data/patients.csv": "f9850c74b803c9a9cbb61b9beb463697da73172c05d934bdec0057a10099fac8", + "spec/domain-packs/medical/data/practitioners.csv": "5230332e9ffda03877dd98207471cee08105d422eda9317d19fa22b9fb7d05ab", + "spec/domain-packs/medical/data/resource_references.csv": "d859681af3e620581795b805a1c0cd4ea1a5042d81613d9826eda4492fa90306", + "spec/domain-packs/medical/data/resources.csv": "b52e08436fa98b7e0a78a69777196d70c86ff560b78ecaf127961dc3e851d58c", + "spec/domain-packs/medical/graph/fixture.json": "b22d788dcf23e2889f82bd407241d7af4bb5f8a8d4c3316768458a97448f18c4", + "spec/domain-packs/medical/licenses/LOINC_short_license.txt": "cc1aad47fa2c13f4206daeb92dde51a95dca0850029b76bfabdfc997bd6c4985", + "spec/domain-packs/medical/licenses/NOTICE.txt": "52b89f1d6f81600eb5b6ee87d1fe054a7b2de072f7762789f72d104e0cbd35b2", + "spec/domain-packs/medical/ontology.json": "fc9938f152e129e041096219be4d7bef70aa35e16f56745411af232ee9cab1c8", + "spec/domain-packs/medical/pack.json": "e7d3b3c8c39ffb7eb14835b76b371fe1a1c1ba43d38ddc3847914aea35a17574", + "spec/domain-packs/medical/sources/encounter-example.json": "6ef7c93b28fa76d3f1f1dcd3e795a8e35c70b5f86ad4659b75f7fc3d93ff0bb5", + "spec/domain-packs/medical/sources/medicationexample1.json": "7e4840d907254db22a6aa9bce22f1c962a94a7d21cb658ac00f491af8cb37e31", + "spec/domain-packs/medical/sources/observation-example-body-height.json": "03fc509c667179aa31a781d0d3a5f278cf459a95ba8a20811376e8b80995a824", + "spec/domain-packs/medical/sources/observation-example-f001-glucose.json": "ce9f8dab3efbdfaa8a734e6c738956656cd444a91b823dcf4458eb833edf4a3f", + "spec/domain-packs/medical/sources/observation-example-f002-excess.json": "9cd95be31d43a6192d29c18b5452a16c512350f2d96d846d4caddcf4156c331a", + "spec/domain-packs/medical/sources/observation-example-f003-co2.json": "e6c700b420ef67bb56ac6093d1131304369d5dd886785da7b68af8a54ee67140", + "spec/domain-packs/medical/sources/observation-example-f004-erythrocyte.json": "4c9308712bc8d3b40e47686387ad0f31c02a75c0667d49e9e44b019caf9e4799", + "spec/domain-packs/medical/sources/observation-example-f005-hemoglobin.json": "626d6cefa749e4fff6bcc6edf85d51606aa2f25db75f8268e0e734faaf8e904a", + "spec/domain-packs/medical/sources/observation-example-heart-rate.json": "d87f95a9cd9b8595b875ae22c38ad73f6d93f1d60d6ee3daf05d9708de1194d3", + "spec/domain-packs/medical/sources/observation-example-respiratory-rate.json": "34e17df17d4510fe8424c5e1ac9431766838747171718cab8226cfcd5a9920d9", + "spec/domain-packs/medical/sources/organization-example-f001-burgers.json": "cec6465ce1513077fc1accfa2abcd049ecd10e7dc37e73e9140bccf17b35da54", + "spec/domain-packs/medical/sources/organization-example-f002-burgers-card.json": "cefea0ad3875422e835f69df47c52575552e6b4f2051e737575fea5f1e29186e", + "spec/domain-packs/medical/sources/organization-example-gastro.json": "8116a0f1283be32e20e5b2496467b83b32b1c79b759217c5a1937c11c7e5e2bd", + "spec/domain-packs/medical/sources/patient-example-f001-pieter.json": "707159ab47ef675765a89e07833f0146c980ef554aaffed08603b5e762a37838", + "spec/domain-packs/medical/sources/patient-example.json": "7cc6b3817264c22e722b6bc10e494d3441341032f8294db7ccec796ca7a0cf81", + "spec/domain-packs/medical/sources/practitioner-example-f005-al.json": "bea688cbf38ce0e07928cde2b9e4621087d2d2eb4c29b91fe01eaa864713edab", + "spec/domain-packs/medical/sources/practitioner-example.json": "f7bdedca23fe131d62bbf7efae8c4dca6c691fe1ab78aa55e81b5fea43a88655", + "spec/domain-packs/medical/umf/encounters.json": "a7648a2400acaccac37b44a2d6b58c1027c6e4ee39833452bf1ef6c06d63b992", + "spec/domain-packs/medical/umf/medications.json": "43f40a1065e3a83ab8b80ef07eb209618adbd7aec8f8ea9c479089b78d4fb39d", + "spec/domain-packs/medical/umf/observations.json": "14cd97a50b96e6e3a875c7580255e3d0559eb18a0ad4b92c14f32535c9128e8f", + "spec/domain-packs/medical/umf/organizations.json": "c1565f2edfbbe04a4ee3d5c47c4307357291691bff3ba9bf6457588805691d19", + "spec/domain-packs/medical/umf/patients.json": "baed12f381049b3edc190b1bedc85b4a96c83ce7f3b14827f2cae384da10bc46", + "spec/domain-packs/medical/umf/practitioners.json": "34105936952f3dd5f42ba4054cc6ad854d6801555595b9ad99d9bc65e2a8cb38", + "spec/domain-packs/medical/umf/resource_references.json": "3968e6cb4c8c78608826ed7e241c91176576edb0a80e2d35064d02289acbedd7", + "spec/domain-packs/medical/umf/resources.json": "c1a5858389cce2209d8fb364bf5bbb62aae0536ca462e2a83feb9a0641babad1", + "spec/domain-packs/medical-carrier/README.md": "ccf5a89076c257e69d3c8a33bfb135e4d7acd8dc7ab11b866dc526850d6d18c4", + "spec/domain-packs/medical-carrier/data/adjudications.csv": "fa035e3b2b0dfb201414d04b7dcfdf0a7e39fed806de024b6c0be2ac352fab7f", + "spec/domain-packs/medical-carrier/data/claim_lines.csv": "0bd9b58462d29869bcd8a00225f8b1b77b83c81bed04d5a8a44fe7232e94ce37", + "spec/domain-packs/medical-carrier/data/claims.csv": "a902b00758a4972f09f53e2e8b26f9997fdd2bea468e20a1cb7c04adebc8c703", + "spec/domain-packs/medical-carrier/data/cms_beneficiaries.csv": "682d408b477eba199e96c853c7982c0157881768a5b8e7be896a75ca1a91e82e", + "spec/domain-packs/medical-carrier/data/cms_carrier_claims.csv": "a3175dadf541162ed006f3b768cc95c3aad7c06e5ca90bd79b4edebef2138401", + "spec/domain-packs/medical-carrier/data/cms_inpatient_claims.csv": "281f8484b788cdfd0c3545740374675c9b69c350f25b64dd0f9aa26ce8ffdfa8", + "spec/domain-packs/medical-carrier/data/coded_values.csv": "5eeeeb39af2f52c42959c071208ad18f9f8ba335865b5a3703d2df85677b0b48", + "spec/domain-packs/medical-carrier/data/coverage.csv": "5571b3a7a70a61dae1d771dc113c6a0a246e506f8a125de579094f3d87487eda", + "spec/domain-packs/medical-carrier/data/eligibility.csv": "68d560d188c7fa42ac85b331de51ca04c8dd8c64611d3663cf53f5ad0f18a08a", + "spec/domain-packs/medical-carrier/data/enrollments.csv": "5716b79011198e027a81163c62cd97c7c03af0b0b7e27308bd8d12b9c6625eb5", + "spec/domain-packs/medical-carrier/data/payments.csv": "1469a88558a7f262ef85c5fe9b4b6bda7eb7102ea92a992004f35a648ed707ec", + "spec/domain-packs/medical-carrier/data/plans.csv": "f27ca990c8476379a6cc992083451b684eb0a1e54957aa1e985bf216b7f64034", + "spec/domain-packs/medical-carrier/data/resource_references.csv": "1da6ebc223e723755b8476306fb5e8050aa3d0e384fa7048ecc6c26a7aae0aaf", + "spec/domain-packs/medical-carrier/data/resources.csv": "0f4a4537fc78a555ade4a8fe68709458c3b4c0f4a080b99692382dac0ef7f6e9", + "spec/domain-packs/medical-carrier/data/workflow_events.csv": "b27e0b1d336915c55ee950bb82b0cbf6f9cc86799ed6a0babd4ce3d6452f83cb", + "spec/domain-packs/medical-carrier/licenses/NOTICE.txt": "1100d7e599a36762c7159a5fdc0ca81efd19185babaa2a8ec226f970d1e7340c", + "spec/domain-packs/medical-carrier/ontology.json": "90a912d2eaf251c401cef10a1431d0c734298743fb19e1b5ff7e8fb889934458", + "spec/domain-packs/medical-carrier/pack.json": "3b59727ac3f98690084c703c6f0c2c444e1e00ef0b562bb97131edaec880568c", + "spec/domain-packs/medical-carrier/sources/cms-beneficiaries.csv": "500f5a2040cb17376c130884bfafa81bcc8d5acb0a44f89aa2af8701cc2d7349", + "spec/domain-packs/medical-carrier/sources/cms-carrier.csv": "91d44f48211ffe3a0176bcc3fc980672de5db48de1d79783935db703ed0f456d", + "spec/domain-packs/medical-carrier/sources/cms-inpatient.csv": "064973be1b23e48c9df9f4163502282ffc01b1094710cba588beb6d581f6d8b4", + "spec/domain-packs/medical-carrier/sources/cms-selection.json": "ce80cfbfeaa4899356d1877d62bf2404ff53896de7acb69cb64aed94fe5da1c5", + "spec/domain-packs/medical-carrier/sources/hl7-claim.json": "9f5772b885ed9279361b761e5483a929ece57c2e1d32ac2315ce12caef186339", + "spec/domain-packs/medical-carrier/sources/hl7-claimresponse.json": "460c178f1c9248bbcb0677aa96aef9da5353be7e50f3fc84f144f03be227f3c4", + "spec/domain-packs/medical-carrier/sources/hl7-coverage.json": "98fb4fcef07a290efb9e3733714f5e3f29d2943ca4367e7d3e3e59c4339bbf08", + "spec/domain-packs/medical-carrier/sources/hl7-eligibility-request.json": "9e5e4291bec5672542d37151206a3e6433c5c764e91d8c0f927405cd6dd99612", + "spec/domain-packs/medical-carrier/sources/hl7-eligibility-response.json": "c24cdf34a5b9609df131dd1968f7873dad451602a55f0b1185b024b14cfa7d4a", + "spec/domain-packs/medical-carrier/sources/hl7-enrollment.json": "8d625da8606e1f1c0d179401b31d45e53888213e1583c8049f95bd36bb909cd2", + "spec/domain-packs/medical-carrier/sources/hl7-eob.json": "d73617364c6080c39083912e22bb76162e7594611dca360412d7010e74ff68c2", + "spec/domain-packs/medical-carrier/sources/hl7-insuranceplan.json": "5dec5d14070a0ba3a3ad9217c305b35948502fc6e1e8ca2217215c25b022fd0e", + "spec/domain-packs/medical-carrier/sources/hl7-payment.json": "ed5674fda256ae01788491e66078869cdaef41b52261a31af9d1368bebde5a20", + "spec/domain-packs/medical-carrier/sources/supplement-claim-authorization-approved.json": "526b7a991784f8a6cc35981eab28105195ef682755c5067cc45358f672b4b2ee", + "spec/domain-packs/medical-carrier/sources/supplement-claim-authorization-denied.json": "ad9c085fb8d866d1bf201ba317064cec6de3a076bbe27b126688c487c1baf4dd", + "spec/domain-packs/medical-carrier/sources/supplement-claim-paid-denied.json": "d9fe4d6e41c17e28aedb9441267dd33df33f539869fdc056ae0ba302cfb71118", + "spec/domain-packs/medical-carrier/sources/supplement-coverage-active.json": "bfe0d1b789d6b5af1ce3d69cdbec59b7a289c57a8e6b3fa7f704c461a5d59ae1", + "spec/domain-packs/medical-carrier/sources/supplement-coverage-inactive.json": "6bac11dd3d84828012d41bcfe073ea909ee6bb92e45f695ef83b227e8dbdd171", + "spec/domain-packs/medical-carrier/sources/supplement-eligibility-negative-request.json": "26e43d4fd5ebff41ccac60f264c2c68c618efbc04ec2d25814e68d9edf75f9d2", + "spec/domain-packs/medical-carrier/sources/supplement-eligibility-negative-response.json": "facfed979d36ee6ae0cb4f94c718c720fa5227999aa8751bae286c0ef96405f3", + "spec/domain-packs/medical-carrier/sources/supplement-eligibility-positive-request.json": "ac8d756638c079d9fe68d46e211331c575f101edf5ff28bbf1b9605885c57525", + "spec/domain-packs/medical-carrier/sources/supplement-eligibility-positive-response.json": "d8e0e9a8f9025dfac07df8546e81de2e95cd12311bfa24585c6ac131c04f7e9d", + "spec/domain-packs/medical-carrier/sources/supplement-enrollment-request.json": "1bb28887e7ba29630b1726145813675fa9903af02fa5cd462c88ff93762f84dd", + "spec/domain-packs/medical-carrier/sources/supplement-enrollment-response.json": "f0591ee4edbfe089ad1f5c5478b536911ecdb8f17de01d5ae87ae6f0e05d6a2e", + "spec/domain-packs/medical-carrier/sources/supplement-eob.json": "e35a4194dab73e92de8a15613139506b7b52882f96284cf2226fe45d70f8da1a", + "spec/domain-packs/medical-carrier/sources/supplement-patient.json": "7289f945e6acf2ce66c83e3e8a37ebfa6a6556c599d2d12336cbd51396f66424", + "spec/domain-packs/medical-carrier/sources/supplement-payer.json": "4a43f964cbd30343e1280c92e3bb1ed37b7dfb9bf946f6bafd439a51b99a5661", + "spec/domain-packs/medical-carrier/sources/supplement-payment.json": "36284c9df3a93a5f86cbe054435730811fa5a62e2cb233be81da0a174db672b6", + "spec/domain-packs/medical-carrier/sources/supplement-plan.json": "d9886c0b4ce226972752ab72665824aa60c55a06c7fe6ca2ecf927326756c922", + "spec/domain-packs/medical-carrier/sources/supplement-response-authorization-approved.json": "bd267969ba418fc87baf385946c1422f64e913aa7c6a8cc15fa4f16363c8c848", + "spec/domain-packs/medical-carrier/sources/supplement-response-authorization-denied.json": "f709ce1bf67e2a05073a4720de39b1ec718a525cf64fbaff8f32716f33033ce5", + "spec/domain-packs/medical-carrier/sources/supplement-response-paid-denied.json": "c7d4f37c7eec131f9b3474ca7e5ebabb1a8dd0be79bdaed37d9579ce3df3dae5", + "spec/domain-packs/medical-carrier/sources/workflow-events.json": "bb3fae1317c8c050a802b70895d362f263d3114cc65af12fbcb639b9063abaae", + "spec/domain-packs/medical-carrier/umf/adjudications.json": "d6fe7be2413680de55f13669fc23e230abdd7a7e9886ac5ad2e4fd0239e51d58", + "spec/domain-packs/medical-carrier/umf/claim_lines.json": "456a882787508c1222676407a0bd8f8acd259d1a1317e197fe7d4e26ed003f82", + "spec/domain-packs/medical-carrier/umf/claims.json": "817975ff9451d7909084f70cf6f9a38ee8db23e1d25a38f52ee806c5eb775609", + "spec/domain-packs/medical-carrier/umf/cms_beneficiaries.json": "9362e919dbb178c2a4f7097a26c1fe50db535fbeb340d21c12f9bfbc87b8ba6f", + "spec/domain-packs/medical-carrier/umf/cms_carrier_claims.json": "4c9ea0edf7dbc23f2cd5bff3d6a5490da30f70727a1258e3b8038bcd1c5eae0a", + "spec/domain-packs/medical-carrier/umf/cms_inpatient_claims.json": "ff37c73b65bde05d31fec075a2b2a0a99c28dde77c071b4359f3181c50eb6d45", + "spec/domain-packs/medical-carrier/umf/coded_values.json": "18cb81b0f669e28af561b7e62c51c9154107e5ba0448961ae68399c71497899b", + "spec/domain-packs/medical-carrier/umf/coverage.json": "fe31c4795900eb79ebcfc47fb1ace3d7dfd3e920455b430692d1bec622d92b06", + "spec/domain-packs/medical-carrier/umf/eligibility.json": "0a114e4257bbb9b59e8514a9fe452454b5e2e78b484ade2ab5757d05216a37f7", + "spec/domain-packs/medical-carrier/umf/enrollments.json": "3accfbf679b884f62c61c2fbbad7d7559d4aa861e6edaaf195ccc503efbf5145", + "spec/domain-packs/medical-carrier/umf/payments.json": "5056cdde04ab9266512a2087985e4c83be32f3da60994e2ae2c18a17b68da02b", + "spec/domain-packs/medical-carrier/umf/plans.json": "74f95de42e711516b1e4d820f87d253fcb309cb4454e17a1304663d268ca664e", + "spec/domain-packs/medical-carrier/umf/resource_references.json": "01ac20470361af0601b09be0337addd915dbe391c943ff71895de9f3426c1f92", + "spec/domain-packs/medical-carrier/umf/resources.json": "9ef1d2a6c7795825b1f6901ccdd80f4f8e1565f9f7623aa5df8c485b00e40cb6", + "spec/domain-packs/medical-carrier/umf/workflow_events.json": "f86a0bdda384c98561cb48dac473e9f45d7def28ce682c9b4c5933b4b526d883", + "spec/domain-packs/medical-epidemiology/README.md": "a4604dbc905b6baa3074c509fbd5449118915bc02906b7423da3b86bb0cabf49", + "spec/domain-packs/medical-epidemiology/data/measures.csv": "be23947804729c7a64bb5b5d0071a20e5bba619d27cfaa5504188482969f71ab", + "spec/domain-packs/medical-epidemiology/data/supplemental_measures.csv": "05cd03ec8cf05416a2cf296b5272b0540bd87ffd0e44cfc6399c1f93524de415", + "spec/domain-packs/medical-epidemiology/licenses/NOTICE.txt": "fd61c614ae31a5b53877fc0f4246c3f444057f58fb1c0df9f6772bf1b2e77978", + "spec/domain-packs/medical-epidemiology/ontology.json": "c6538ed54f408ec81482c2e7e1c9ded3edd9e75d10e292c36bf4b2c8085baca0", + "spec/domain-packs/medical-epidemiology/pack.json": "fa073eeaa754042b9015913a1eba7546bf18d8623279135856856424d4fdfdd5", + "spec/domain-packs/medical-epidemiology/sources/cdc-metadata.json": "abd2439f7c8f43d9cc551bf9fcb805fb191f57385d69a2250ef6619a9b5b3592", + "spec/domain-packs/medical-epidemiology/sources/cdc-mortality.json": "8a21a792545b670db71b8a53b86b09d75bc471f9c327c5079e47d2c6a74701e4", + "spec/domain-packs/medical-epidemiology/sources/supplement.json": "847575df6aacdc8e2aa007267125f8d3729d6946b6ee8eb8380597fc20c7823b", + "spec/domain-packs/medical-epidemiology/umf/measures.json": "b67343c735958faca9dfbad3945daa287b2a2a272e4a1ecd891fa4d035817d0e", + "spec/domain-packs/medical-epidemiology/umf/supplemental_measures.json": "65c323e6a98237cab75dc79f1fdcaf5552e42562901feb6e513c10724a36457f", + "spec/domain-packs/medical-imaging/README.md": "f45029ebbd3e593a38ba3b0b4cc62cd90fa06225179395656d6b680877496a3f", + "spec/domain-packs/medical-imaging/data/attributes.csv": "642ad1c908d4abbf35b609e7e100a6192df48c950a2fffc79b63ce1863af9070", + "spec/domain-packs/medical-imaging/data/instances.csv": "a9de843fb268c76ae8454e246986df1844ae7077df6b0b459529a0db7501d9cd", + "spec/domain-packs/medical-imaging/licenses/NOTICE.txt": "c810fd8653dd42fc427d84b87c9f786184a8e6df95b8e4430194bfb9904043fb", + "spec/domain-packs/medical-imaging/ontology.json": "2d1c2628f9872ef6d52528b3ed1b9c93ed85cf708500f94ed8ea697dd8e09f20", + "spec/domain-packs/medical-imaging/pack.json": "6fac6b9ced73a3aa8022508353c30727ea80e3ad51050a1db9a0f15da750c283", + "spec/domain-packs/medical-imaging/sources/provenance.json": "41ecb95b1f4c857fc6149d6b0d3c05a0679d241c2b5e8a2cc34cae5a99f0e30c", + "spec/domain-packs/medical-imaging/sources/synthetic-dicom.json": "e6e9beff8acc1a07d1a059f9f75890d6616e90bde906123b3022436e5419ada4", + "spec/domain-packs/medical-imaging/sources/synthetic.dcm": "54f23548d26d998a92fac698f829f330d19bf8633bab848a5b33da5710e1db1d", + "spec/domain-packs/medical-imaging/sources/tcia-lidc-0001-ct.dcm": "4b5570f8acf2ec6cb086e21cba31d67c1ce13a75897bc759d360d8805d570576", + "spec/domain-packs/medical-imaging/sources/tcia-lidc-0001-ct.json": "dce66b9233f07dbe028cad501b7147e8d627b030701fbf3395bfdd4b1072005d", + "spec/domain-packs/medical-imaging/sources/tcia-selection.json": "b374d405939a3c33bd02a13138dbf3c4e963c444a330a9732fc2f18f91945f57", + "spec/domain-packs/medical-imaging/umf/attributes.json": "5b7f10bd6422c3ae477fa5e5f7c16092fefe0bac6665f775a418275cf77e495c", + "spec/domain-packs/medical-imaging/umf/instances.json": "16192c0200da5dcd3198909068242515508565e1a4c88f6a3c2c76c573f7f7cb", + "spec/domain-packs/medical-terminology/README.md": "a681195a09ba9f4c2f5a578f998286abdf390eee62894048950b932501f8afc2", + "spec/domain-packs/medical-terminology/data/concepts.csv": "4c9d331a8e2ef23faf1c2eb0f54c7e96b90ffea6c8ee9490e62b33c515daf954", + "spec/domain-packs/medical-terminology/data/systems.csv": "a5a2fa063a954b57253b9afb34e10605f19e20b565eb037acf9f6483b533f002", + "spec/domain-packs/medical-terminology/licenses/NOTICE.txt": "ad61121d0fb07b2f879541a883454296f688fa6dd9a5a0b26dee97d3943ffb90", + "spec/domain-packs/medical-terminology/ontology.json": "e4ff8e3a6d00ce03c9266cbe362411e26c2e06897f25c6d77c357530b1777c31", + "spec/domain-packs/medical-terminology/pack.json": "d67785efcacaea51de46d2e12737d9a69d84428d9380d34dda819a5c54bdd926", + "spec/domain-packs/medical-terminology/sources/icd10cm-order-2026-subset.txt": "183f8332624cd37f64240f46b6233b3950892bbe710caec13184fb2afbd2f9b1", + "spec/domain-packs/medical-terminology/sources/selection.json": "7a328013f33d3fcdfb67adda62a5dd70d174af9179418da8883689258f163c12", + "spec/domain-packs/medical-terminology/umf/concepts.json": "88cdeaf957de8965af2288cde75898c2713e5b93b0d3fb1b18eeafbcf0abfdc9", + "spec/domain-packs/medical-terminology/umf/systems.json": "896e8689ce86eee231ed8f54018d41448ff29e8220dc4b2520ed628ab8625b81", + "src/domain-packs/profile.ts": "3fe08166deb99f1183127349384b4b60290a03b3826b8bfac69bd3a0aed59213", + "src/domain-packs/schema.ts": "e6699fb9076ad7a242cb5817ce74adba97201212a71499aeea2b1cda65981a41", + "tests/domain-packs/medical-family.test.ts": "a4d16deaff7999d13582d36631402cc037a68151e505273791f439888e43f746", + "tests/domain-packs/medical-subpacks.test.ts": "c930e3dd5e099f35c45eaeeb05c62a6be5a23e8446b3e3579645a021e82d88c1" + }, + "integration_base": "d0feb0a4acdbe18e99990788aaf1172ede5fa92d", + "integration_note": "Rebased onto current master; only docs/helix/05-deploy/pypi.md changed upstream. Medical/test inputs are unchanged." +} diff --git a/scripts/build-medical-subpacks.ts b/scripts/build-medical-subpacks.ts index 603ab0cc7..75067bda2 100644 --- a/scripts/build-medical-subpacks.ts +++ b/scripts/build-medical-subpacks.ts @@ -4,7 +4,10 @@ import {projectMedicalFhir,projectCdcMortality,projectDicomMetadata,type Medical import {createValidator} from '../src/validation/schema'; import {generateDomainPackSchema} from '../src/domain-packs/schema'; import {importTableSpec,exportTableSpec} from '../src/adapters/tablespec'; +import {ontology} from './domain-packs/ontology'; +const packVersion='1.1.0'; +const familyLabels:Record={'medical-carrier':'Carrier: eligibility, claims and payments','medical-epidemiology':'Epidemiology','medical-imaging':'Imaging: DICOM and PACS metadata','medical-terminology':'Terminology'}; const base='spec/domain-packs',check=process.argv.includes('--check'); const validate=createValidator().compile(generateDomainPackSchema()); const sha=(bytes:Uint8Array)=>new Bun.CryptoHasher('sha256').update(bytes).digest('hex'); @@ -27,6 +30,7 @@ async function source(root:string,reference:string,data_kind:string,publisher:st const remote=(reference:string,publisher:string,data_kind='unknown',revision?:string)=>({kind:'external',data_kind,reference,format:'publisher-page', ...(revision?{revision}:{}),license:{redistribution:'unknown',notices:['Reference or consumer-local licensed input only; no bytes bundled or retrieval implied.']},provenance:{publisher}}); async function build(id:string,tables:MedicalTables,sources:Record,qualification:Record,notice:string,bindings:Record={}){ + const nativeSpecs:any[]=[]; const root=join(base,id),schemas=[] as {id:string;format:string;reference:string}[],source_bindings=[] as {schema_id:string;source_id:string;role:string}[]; const fixture_counts:Record={}; await output(join(root,'licenses/NOTICE.txt'),notice); @@ -36,20 +40,22 @@ async function build(id:string,tables:MedicalTables,sources:Record,q const columns=Object.keys(rows[0]!); if(rows.some(r=>Object.keys(r).join('\0')!==columns.join('\0')))throw Error('Inconsistent projection columns: '+name); const schema:any={version:'1.0',table_name:name,description:'Source-qualified selected view. Full original meaning remains in pinned sources. '+String(qualification.subset), - columns:columns.map(n=>({name:n,data_type:n.endsWith('_json')?'TEXT':rows.some(r=>typeof r[n]==='boolean')?'BOOLEAN':'VARCHAR',nullable:rows.some(r=>r[n]===null),description:n.replaceAll('_',' ')})),primary_key:[columns[0]!]}; + columns:columns.map(n=>({name:n,data_type:n.endsWith('_json')?'TEXT':rows.some(r=>typeof r[n]==='boolean')?'BOOLEAN':'VARCHAR',nullable:rows.some(r=>r[n]===null),description:n.replaceAll('_',' ')})),primary_key:name==='cms_beneficiaries'?['DESYNPUF_ID']:name==='cms_inpatient_claims'?['CLM_ID','SEGMENT']:name==='cms_carrier_claims'?['CLM_ID']:[columns[0]!]}; const fks:any[]=[]; if(name!=='resources'&&columns.includes('resource_key')&&tables.resources)fks.push({column:'resource_key',references_table:'resources',references_column:'resource_key'}); if(name==='resource_references')fks.push({column:'target_key',references_table:'resources',references_column:'resource_key'}); if(name==='claim_lines')fks.push({column:'parent_line_key',references_table:'claim_lines',references_column:'line_key'}); if(name==='adjudications')fks.push({column:'line_key',references_table:'claim_lines',references_column:'line_key'}); if(name==='attributes')fks.push({column:'source_id',references_table:'instances',references_column:'source_id'}); + if(name==='cms_inpatient_claims'||name==='cms_carrier_claims')fks.push({column:'DESYNPUF_ID',references_table:'cms_beneficiaries',references_column:'DESYNPUF_ID'}); if(fks.length)schema.relationships={foreign_keys:fks}; + nativeSpecs.push(schema); const schemaText=serialize(schema); if(exportTableSpec(importTableSpec(schemaText,{id:name,format:'json'}))!==schemaText)throw Error('Native schema differs'); await output(join(root,'umf',name+'.json'),schemaText); const reference='data/'+name+'.csv',text=csv(rows,columns);await output(join(root,reference),text); const sourceId='csv_'+name; - sources[sourceId]={kind:'external',data_kind:id==='medical-terminology'?'unknown':id==='medical-epidemiology'&&name==='measures'?'observed':'fabricated',reference,format:'csv',revision:id+'-1.0.0', + sources[sourceId]={kind:'external',data_kind:id==='medical-terminology'||id==='medical-imaging'?'unknown':id==='medical-epidemiology'&&name==='measures'?'observed':'fabricated',reference,format:'csv',revision:id+'-'+packVersion, checksum:{algorithm:'sha256',value:sha(new TextEncoder().encode(text))},license:{redistribution:'allowed',reference:'licenses/NOTICE.txt'}, provenance:{publisher:'UMF project',source_ids:bindings[name]??Object.keys(sources).filter(k=>k!=='notices'&&!k.startsWith('csv_')&&!sources[k].reference.includes(':')),transformations:['Deterministic selected-column projection; original native sources retained separately.']}}; schemas.push({id:name,format:'tablespec',reference:'umf/'+name+'.json'}); @@ -57,17 +63,19 @@ async function build(id:string,tables:MedicalTables,sources:Record,q for(const sourceId of bindings[name]??[])source_bindings.push({schema_id:name,source_id:sourceId,role:id==='medical-terminology'?'terminology':'reference'}); fixture_counts[name]=rows.length; } - const pack={id,version:'1.0.0',description:'Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.', + await output(join(root,'ontology.json'),serialize(ontology(id,nativeSpecs))); + schemas.push({id:'ontology',format:'umf',reference:'ontology.json'}); + const pack={id,version:packVersion,family:{id:'medical',version:packVersion,label:familyLabels[id]},execution_profile:{version:'1.0.0',targets:{tabular:nativeSpecs.map(s=>s.table_name),graph:['ontology']},mode:'fixed',include_sources:Object.keys(sources).filter(k=>!sources[k].reference.includes(':')),qualification:'Fixed source-qualified sample rows and schema-only ontology. No data generation, clinical conformance or graph-storage execution claim.'},description:'Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.', domain_types:{source_qualified_identity:{description:'Source namespace and native identity; no inferred patient identity.'},exact_native_literal:{description:'Numeric and temporal source spelling retained as text.'}}, schemas,sources,source_bindings,csv_conventions:{encoding:'UTF-8',null_value:'\\N',header:true,quote:'"'},fixture_counts,qualification}; if(!validate(pack))throw Error('Invalid generated metadata: '+JSON.stringify(validate.errors)); await output(join(root,'pack.json'),serialize(pack)); - await output(join(root,'README.md'),'# '+id+' 1.0.0\n\n'+String(qualification.subset)+'\n\n'+String(qualification.limits)+'\n\n'+ + await output(join(root,'README.md'),'# '+id+' '+packVersion+'\n\n'+String(qualification.subset)+'\n\n'+String(qualification.limits)+'\n\n'+ 'Use the shared `export-domain-pack.ts --include-sources` command with this pack, then TableSpec `sample-data ingest`. Sources and schemas are local and checksum-pinned. Remote/licensed references remain metadata.\n\nSee `licenses/NOTICE.txt`, source provenance and [governed evidence](../../../docs/helix/04-build/evidence/medical-subpacks.md).\n'); console.log(JSON.stringify({pack:id,schemas:schemas.length,rows:Object.values(fixture_counts).reduce((a,b)=>a+b,0),checked:check})); } -const carrierRoot=join(base,'medical-carrier'),files=(await readdir(join(carrierRoot,'sources'))).filter(n=>n.endsWith('.json')&&n!=='workflow-events.json').sort(); +const carrierRoot=join(base,'medical-carrier'),files=(await readdir(join(carrierRoot,'sources'))).filter(n=>n.endsWith('.json')&&n!=='workflow-events.json'&&!n.startsWith('cms-')).sort(); const carrierSources:Record={}; const groups:Record={hl7:[],supplement:[]}; const upstreamNames:Record={coverage:'coverage-example','eligibility-request':'coverageeligibilityrequest-example','eligibility-response':'coverageeligibilityresponse-example',claim:'claim-example',claimresponse:'claimresponse-example',eob:'explanationofbenefit-example',insuranceplan:'insuranceplan-example',enrollment:'enrollmentrequest-example',payment:'paymentreconciliation-example'}; @@ -85,9 +93,22 @@ carrier.workflow_events=(await Bun.file(join(carrierRoot,'sources/workflow-event carrierSources.workflow=await source(carrierRoot,'sources/workflow-events.json','fabricated','UMF project'); carrierSources.cms_rif=remote('https://data.cms.gov/','Centers for Medicare & Medicaid Services','fabricated'); carrierSources.cms_blue_button=remote('https://bluebutton.cms.gov/data/understanding-the-data/','Centers for Medicare & Medicaid Services','fabricated'); -await build('medical-carrier',carrier,carrierSources,{native_format:'FHIR R4 4.0.1 selected views plus independent UMF scenario events',subset:`${groups.hl7!.length} unchanged official HL7 carrier resources and ${groups.supplement!.length} authored supplemental FHIR-shaped resources, plus four workflow events.`, - limits:'Illustrative sources are not a validated FHIR Bundle or carrier simulation. Native official examples do not form a coherent history. CMS ingestion and X12 services are not implemented. Reference resolution is namespace-local; no patient matching.'}, - 'HL7 FHIR R4 examples: CC0 per https://hl7.org/fhir/R4/license.html. HL7/FHIR trademarks do not imply endorsement. Selected examples contain no explicitly identified SNOMED CT, CPT, CDT or DICOM terminology. Unqualified codes retain their absent system; no dictionary rights or clinical meaning are inferred. UMF-authored supplemental scenarios and projections may be redistributed with this notice.\n'); +const cmsSelection=await Bun.file(join(carrierRoot,'sources/cms-selection.json')).json(); +// The pinned CMS files use single-line RFC4180 records. Keep every native cell as text. +const parseCsvLine=(line:string)=>{const cells:string[]=[];let cell='',quoted=false;for(let i=0;i{const cells=parseCsvLine(line);if(cells.length!==header.length)throw Error('Native CSV width differs');return {...Object.fromEntries(header.map((c,i)=>[c,cells[i]!])),native_record_number:String(pin.selected_record_numbers[index]),native_csv_record:line};}); + carrierSources['cms_'+name]=await source(carrierRoot,reference,'fabricated','CMS',{format:'csv',revision:cmsSelection.release,license:{redistribution:'allowed',reference:'licenses/NOTICE.txt'},provenance:{publisher:'CMS',retrieved_at:'2026-10-08',upstream_url:pin.url,transformations:['Exact native header and selected complete record bytes; see cms-selection.json.']}}); +} +carrierSources.cms_selection=await source(carrierRoot,'sources/cms-selection.json','unknown','UMF project'); +const cmsBindings=Object.fromEntries(['beneficiaries','inpatient','carrier'].map(name=>[name==='beneficiaries'?'cms_beneficiaries':name==='carrier'?'cms_carrier_claims':'cms_inpatient_claims',['cms_'+name,'cms_selection']])); +const carrierBindings=Object.fromEntries(Object.keys(carrier).map(name=>[name,cmsBindings[name]??(name==='workflow_events'?['workflow']:Object.keys(carrierSources).filter(id=>id.startsWith('hl7-')||id.startsWith('supplement-')))])); +await build('medical-carrier',carrier,carrierSources,{native_format:'FHIR R4 4.0.1 selected views plus independent UMF scenario events',subset:`${groups.hl7!.length} unchanged official HL7 carrier resources and ${groups.supplement!.length} authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).`, + limits:'Illustrative sources are not a validated FHIR Bundle or carrier simulation. Native official examples do not form a coherent history. CMS coverage is DE-SynPUF Sample 1, 2008 beneficiaries and 2008–2010 claims; ICD-9 remains native. Numeric CPT/Level I HCPCS carrier rows are excluded. These are synthetic public samples, not real beneficiaries. X12 services are not implemented. Reference resolution is namespace-local; no patient matching.'}, + 'HL7 FHIR R4 examples: CC0 per https://hl7.org/fhir/R4/license.html. HL7/FHIR trademarks do not imply endorsement. Selected examples contain no explicitly identified SNOMED CT, CPT, CDT or DICOM terminology. Unqualified codes retain their absent system; no dictionary rights or clinical meaning are inferred. UMF-authored supplemental scenarios and projections may be redistributed with this notice. CMS DE-SynPUF is a public synthetic software-development release: https://www.cms.gov/data-research/statistics-trends-and-reports/medicare-claims-synthetic-public-use-files ; CMS public-domain site declaration: https://www.cms.gov/about-cms/web-policies-important-links/about-website/link-to-us . This bounded excerpt keeps native bytes; numeric CPT/Level I HCPCS carrier rows are excluded, and no CPT descriptors/dictionary or clinical mapping is distributed. Source files, selection and upstream hashes are in cms-selection.json.\n',carrierBindings); const epiRoot=join(base,'medical-epidemiology'); const epiSources={cdc:await source(epiRoot,'sources/cdc-mortality.json','observed','CDC/NCHS',{revision:'bi63-dtpu-rowsUpdatedAt-1571926785',license:{id:'USGOV_WORKS',reference:'https://data.cdc.gov/api/views/bi63-dtpu.json',redistribution:'allowed'},provenance:{publisher:'CDC/NCHS',retrieved_at:'2026-10-08',upstream_url:'https://data.cdc.gov/resource/bi63-dtpu.json?$limit=12&$order=year,state,cause_name',transformations:[]}}), @@ -102,13 +123,19 @@ const imagingRoot=join(base,'medical-imaging'),imaging=projectDicomMetadata(awai imaging.instances![0]!.binary_reference='sources/synthetic.dcm'; imaging.instances![0]!.binary_sha256=sha(new Uint8Array(await Bun.file(join(imagingRoot,'sources/synthetic.dcm')).arrayBuffer())); imaging.instances![0]!.transfer_syntax='1.2.840.10008.1.2.1'; +const tciaSelection=await Bun.file(join(imagingRoot,'sources/tcia-selection.json')).json(); +const tcia=projectDicomMetadata(await Bun.file(join(imagingRoot,'sources/tcia-lidc-0001-ct.json')).text(),'tcia-lidc-0001-ct'); +tcia.instances![0]!.binary_reference='sources/tcia-lidc-0001-ct.dcm';tcia.instances![0]!.binary_sha256=tciaSelection.member_sha256;tcia.instances![0]!.transfer_syntax=tciaSelection.transfer_syntax; +for(const name of ['instances','attributes'])imaging[name]!.push(...tcia[name]!); await build('medical-imaging',imaging,{dicom_json:await source(imagingRoot,'sources/synthetic-dicom.json','fabricated','UMF project',{format:'dicom-json',revision:'umf-synthetic-1.0.0'}), dicom_binary:await source(imagingRoot,'sources/synthetic.dcm','fabricated','UMF project'),provenance:await source(imagingRoot,'sources/provenance.json','unknown','UMF project'), - tcia:remote('https://www.cancerimagingarchive.net/data-usage-policies-and-restrictions/','The Cancer Imaging Archive','deidentified')}, - {native_format:'DICOM Part 10 Explicit VR Little Endian and DICOM JSON',subset:'One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence.', - projection_losses:['pydicom DICOM JSON normalizes native DS decimal spellings (1.2500 to 1.25); original spellings remain in the unchanged binary object. File-meta elements and preamble are binary-only, retained in the original.'], - limits:'Native metadata and original binary retention only. No public patient images, pixel decoding, full IOD conformance, DICOMweb or live PACS operations. TCIA remains a collection-specific rights/access candidate; no TCIA bytes are bundled.'}, - 'All included DICOM objects, metadata and byte-ramp pixels are UMF-authored fabricated fixtures and may be redistributed with this notice. No real patient or acquired image is represented. DICOM is a NEMA trademark; this fixture does not reproduce the copyrighted DICOM standard or claim endorsement. TCIA collections require their own citation and data-use conditions.\n',{instances:['dicom_json','dicom_binary','provenance'],attributes:['dicom_json']}); + tcia_binary:await source(imagingRoot,'sources/tcia-lidc-0001-ct.dcm','deidentified','TCIA',{revision:tciaSelection.collection_revision,license:{id:'CC-BY-3.0',reference:'licenses/NOTICE.txt',redistribution:'allowed',attribution:'Armato et al. (2015), Data From LIDC-IDRI, doi:10.7937/K9/TCIA.2015.LO9QL9SX'}}), + tcia_json:await source(imagingRoot,'sources/tcia-lidc-0001-ct.json','deidentified','TCIA / UMF projection',{format:'dicom-json',revision:tciaSelection.collection_revision}), + tcia_selection:await source(imagingRoot,'sources/tcia-selection.json','unknown','UMF project')}, + {native_format:'DICOM Part 10 with per-instance transfer syntax and separate DICOM JSON metadata',subset:'One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence; one unchanged public TCIA LIDC-IDRI CT slice with publisher-deidentified source identity.', + projection_losses:['pydicom DICOM JSON normalizes native DS decimal spellings (1.2500 to 1.25); original spellings remain in the unchanged binary object. File-meta elements and preamble are binary-only, retained in the original.',...tciaSelection.projection_losses], + limits:'Native metadata and original binary retention only. The public CT slice is an incomplete 1/133-series selection, not a full study. Its source DICOM edition is unknown; pydicom 3.0.2 JSON inspection is the tested profile. No independent deidentification certification, pixel decoding, full IOD conformance, DICOMweb or live PACS operations.'}, + 'The synthetic DICOM object, its metadata and byte-ramp pixels are UMF-authored fabricated fixtures and may be redistributed with this notice. That synthetic fixture represents no real patient or acquired image; the separately identified public CT object is publisher-deidentified TCIA data. DICOM is a NEMA trademark; this fixture does not reproduce the copyrighted DICOM standard or claim endorsement. Public CT source: Armato III, S. G., et al. (2015). Data From LIDC-IDRI [Data set]. The Cancer Imaging Archive. https://doi.org/10.7937/K9/TCIA.2015.LO9QL9SX . Licensed CC BY 3.0 https://creativecommons.org/licenses/by/3.0/ ; source https://www.cancerimagingarchive.net/collection/lidc-idri/ and policy https://www.cancerimagingarchive.net/data-usage-policies-and-restrictions/ . Selected binary unchanged; UMF/pydicom derived separate JSON metadata normalizes DS/IS and replaces pixel bytes with a local BulkDataURI; complete native binary remains supplied. No endorsement implied.\n',{instances:['dicom_json','dicom_binary','provenance','tcia_binary','tcia_json','tcia_selection'],attributes:['dicom_json','tcia_json']}); const termRoot=join(base,'medical-terminology'),selection=await Bun.file(join(termRoot,'sources/selection.json')).json(); const concepts=(await Bun.file(join(termRoot,'sources/icd10cm-order-2026-subset.txt')).text()).trimEnd().split(/\r?\n/).map(line=>({concept_key:selection.system+'|'+selection.release+'|'+line.slice(6,13).trim(),system:selection.system,release:selection.release,code:line.slice(6,13).trim(),billable:line[14]==='1',short_display:line.slice(16,76).trimEnd(),display:line.slice(77),effective_start:selection.effective_start,effective_end:selection.effective_end,native_line:line})); @@ -133,3 +160,9 @@ await build('medical-terminology',{systems,concepts},{icd10cm:await source(termR {subset:'12 native ICD-10-CM FY2026 October 2025 order-file records; six separately identified system/access descriptors.', limits:'Historical subset only, not current or exhaustive codes. SNOMED CT/CPT have no bundled dictionary or mappings. Exact consumer-local release lookup makes no clinical/billing equivalence claim. An unmatched code means not in this subset, never invalid.'}, 'Source: CDC/NCHS. ICD-10-CM selected order-file lines are unchanged excerpts of the CDC/NCHS FY2026 US government publication, with selected original line bytes and upstream ZIP SHA-256 in sources/selection.json. Include source attribution when redistributing. Materials are available without charge from the CDC source linked in selection.json. Their use and links do not imply endorsement by CDC, ATSDR, HHS or the US Government. See https://www.cdc.gov/other/agencymaterials.html and the ICD-10-CM public-domain publication https://stacks.cdc.gov/view/cdc/148699. No AMA CPT or SNOMED CT vocabulary is bundled; licenses and territory restrictions remain source-specific. UMF-authored projections/metadata may be redistributed with this notice.\n',{concepts:['icd10cm','selection'],systems:['icd10pcs','hcpcs2','snomed','cpt']}); + +// Complete family metadata after child manifests are generated and hashed. +const medicalPath=join(base,'medical/pack.json'),medical=await Bun.file(medicalPath).json(); +medical.version=packVersion;medical.family={id:'medical',version:packVersion,label:'Clinical'}; +medical.composition={version:'1.0.0',components:await Promise.all(Object.entries(familyLabels).map(async([id,label])=>({id,version:packVersion,label,checksum:{algorithm:'sha256',value:sha(new TextEncoder().encode(await Bun.file(join(base,id,'pack.json')).text()))}})))}; +await output(medicalPath,serialize(medical)); diff --git a/scripts/collect-medical-public-samples.py b/scripts/collect-medical-public-samples.py new file mode 100644 index 000000000..309946dfe --- /dev/null +++ b/scripts/collect-medical-public-samples.py @@ -0,0 +1,58 @@ +"""Explicit developer collection from downloaded, fingerprinted public archives. + +Requires pydicom 3.0.2. This never runs in pack ingestion or in the browser. +Download URLs and archive checksums are recorded in the emitted selection files. +""" +import argparse,csv,hashlib,io,json +from pathlib import Path +from zipfile import ZipFile +import pydicom + +ROOT=Path(__file__).resolve().parents[1]/'spec/domain-packs' +def digest(data):return hashlib.sha256(data).hexdigest() +def write_json(path,data):path.parent.mkdir(parents=True,exist_ok=True);path.write_text(json.dumps(data,indent=2,ensure_ascii=False)+'\n') +parser=argparse.ArgumentParser();parser.add_argument('--cache',required=True);args=parser.parse_args();cache=Path(args.cache) +urls={ + 'beneficiaries':'https://www.cms.gov/research-statistics-data-and-systems/downloadable-public-use-files/synpufs/downloads/de1_0_2008_beneficiary_summary_file_sample_1.zip', + 'inpatient':'https://www.cms.gov/research-statistics-data-and-systems/downloadable-public-use-files/synpufs/downloads/de1_0_2008_to_2010_inpatient_claims_sample_1.zip', + 'carrier':'https://downloads.cms.gov/files/DE1_0_2008_to_2010_Carrier_Claims_Sample_1A.zip'} +expected={'beneficiaries':'2b0c9cbfb07a6eb46d5f96472c0891275a390b686c3fa34daae8d3e53d70b18b','inpatient':'ac25124184d22863aff538607097d2d0c880d19f7d58f882f9d31129c492d893','carrier':'4b4038b5f6cd9c524fa3a655a3f467aef01af56c3cae0f08902a35a9945bed97'} +files={};pins={} +for name,url in urls.items(): + data=(cache/('umf-cms-'+name+'.zip')).read_bytes();assert digest(data)==expected[name] + z=ZipFile(io.BytesIO(data));member=z.namelist()[0];raw=z.read(member);lines=raw.splitlines(keepends=True) + # Published CSV records are one physical line each; retain exact selected bytes. + header=next(csv.reader([lines[0].decode()]));files[name]=(header,lines) + pins[name]={'url':url,'archive_sha256':digest(data),'member':member,'member_sha256':digest(raw),'selected_record_numbers':[]} +selected={};beneficiaries=set() +for name in ['inpatient','carrier']: + header,lines=files[name];chosen=[] + for number,line in enumerate(lines[1:],1): + row=dict(zip(header,next(csv.reader([line.decode()])))) + # Avoid distributing CPT/Level I codes: select complete carrier records only + # where every nonempty HCPCS token is alphanumeric Level II-shaped. + if name=='carrier' and any(v and not (v[0].isalpha() and len(v)==5) for k,v in row.items() if k.startswith('HCPCS_CD_')):continue + chosen.append(line);beneficiaries.add(row['DESYNPUF_ID']);pins[name]['selected_record_numbers'].append(number) + if len(chosen)==5:break + assert len(chosen)==5 + selected[name]=chosen +header,lines=files['beneficiaries'];selected['beneficiaries']=[] +for number,line in enumerate(lines[1:],1): + row=dict(zip(header,next(csv.reader([line.decode()])))) + if row['DESYNPUF_ID'] in beneficiaries: + selected['beneficiaries'].append(line);pins['beneficiaries']['selected_record_numbers'].append(number) +assert len(selected['beneficiaries'])==len(beneficiaries) +carrier=ROOT/'medical-carrier'/'sources' +for name,records in selected.items(): + data=files[name][1][0]+b''.join(records);path=carrier/('cms-'+name+'.csv');path.write_bytes(data) + pins[name]['subset_sha256']=digest(data);pins[name]['rows']=len(records) +write_json(carrier/'cms-selection.json',{'release':'DE-SynPUF 1.0 Sample 1; 2008 beneficiary and 2008–2010 claims','retrieved_at':'2026-10-08','data_kind':'fabricated','files':pins,'selection':'First five inpatient rows and first five complete carrier rows without numeric CPT/Level I HCPCS tokens; all matching 2008 beneficiaries. The second carrier file (1B) is outside this tiny subset. Native columns and bytes unchanged. No ICD-9 conversion, clinical validity or longitudinal completeness claimed.','rights':{'basis':'CMS public-domain website declaration and unrestricted DE-SynPUF software-development public release; no CPT code/descriptor vocabulary bundled.','references':['https://www.cms.gov/about-cms/web-policies-important-links/about-website/link-to-us','https://www.cms.gov/data-research/statistics-trends-and-reports/medicare-claims-synthetic-public-use-files','https://www.cms.gov/files/document/de-10-frequently-asked-questions.pdf'],'limit':'Applies to this selected subset, not other CMS files or licensed codebooks.'}}) +series='1.3.6.1.4.1.14519.5.2.1.6279.6001.179049373636438705059720603192' +raw=(cache/'umf-tcia-ct.zip').read_bytes();assert digest(raw)=='368b2d7ca84edc2f1462194282d6cdd52b6624b5c90964eb8a306ebe56328833' +z=ZipFile(io.BytesIO(raw));member=sorted(n for n in z.namelist() if n.endswith('.dcm'))[0];binary=z.read(member);d=pydicom.dcmread(io.BytesIO(binary));assert str(d.SeriesInstanceUID)==series +imaging=ROOT/'medical-imaging'/'sources';binary_ref='sources/tcia-lidc-0001-ct.dcm';(imaging/'tcia-lidc-0001-ct.dcm').write_bytes(binary) +metadata=d.to_json_dict(bulk_data_threshold=1024,bulk_data_element_handler=lambda e:binary_ref+'#tag-'+f'{int(e.tag):08X}') +write_json(imaging/'tcia-lidc-0001-ct.json',metadata) +private=[{'tag':f'{e.tag:08X}','vr':e.VR,'value':str(e.value)} for e in d.iterall() if e.tag.is_private] +write_json(imaging/'tcia-selection.json',{'collection':'LIDC-IDRI','doi':'10.7937/K9/TCIA.2015.LO9QL9SX','collection_revision':'2015 DOI; exact API snapshot retrieved 2026-10-08','license':'CC-BY-3.0','license_url':'https://creativecommons.org/licenses/by/3.0/','collection_url':'https://www.cancerimagingarchive.net/collection/lidc-idri/','policy_url':'https://www.cancerimagingarchive.net/data-usage-policies-and-restrictions/','archive_url':'https://services.cancerimagingarchive.net/nbia-api/services/v1/getImage?SeriesInstanceUID='+series,'archive_sha256':digest(raw),'member':member,'member_sha256':digest(binary),'selection':'Lexicographically first DICOM member from one 133-instance CT series; one slice only, not a complete study. Original binary unchanged.','data_kind':'deidentified','patient_id':str(d.PatientID),'study_uid':str(d.StudyInstanceUID),'series_uid':series,'sop_instance_uid':str(d.SOPInstanceUID),'transfer_syntax':str(d.file_meta.TransferSyntaxUID),'native_dicom_edition':'Not declared by source; inspection profile DICOM JSON PS3.18 Annex F, pydicom 3.0.2.','private_elements':private,'burned_in_annotation':str(d.get('BurnedInAnnotation','not supplied')),'deidentification':'Publisher-deidentified source; no independent patient reidentification or deidentification certification. Retained private creator and CT private values are inspectable.','projection_losses':['DS/IS values may normalize lexical spelling in pydicom JSON; exact spelling stays in original binary.','PixelData becomes an opaque local BulkDataURI; pixel and file-meta bytes stay in the unchanged binary.'],'pydicom_version':pydicom.__version__}) +print(json.dumps({'cms_rows':{k:len(v) for k,v in selected.items()},'dicom_bytes':len(binary),'private_elements':private},indent=2)) diff --git a/scripts/domain-pack-browser.ts b/scripts/domain-pack-browser.ts index 8dfd28475..95d7216bf 100644 --- a/scripts/domain-pack-browser.ts +++ b/scripts/domain-pack-browser.ts @@ -18,6 +18,7 @@ const server=Bun.serve({port:0,hostname:'127.0.0.1',fetch(request){ '/carrier-response.json':'medical-carrier/sources/hl7-claimresponse.json', '/cdc.json':'medical-epidemiology/sources/cdc-mortality.json', '/dicom.json':'medical-imaging/sources/synthetic-dicom.json', + '/public-dicom.json':'medical-imaging/sources/tcia-lidc-0001-ct.json', ...Object.fromEntries(['medical-carrier','medical-epidemiology','medical-imaging','medical-terminology'].map(id=>['/'+id+'.json',id+'/pack.json']))}; if(fixtureFiles[path])return new Response(Bun.file('spec/domain-packs/'+fixtureFiles[path]),{headers:{'content-type':'application/json'}}); return new URL(request.url).pathname==='/umf.js'?new Response(Bun.file('dist/umf.js'),{headers:{'content-type':'text/javascript'}}):new Response('UMF pack schema verification',{headers:{'content-type':'text/html'}}); @@ -70,6 +71,11 @@ try { const dicom=u.projectDicomMetadata(await(await fetch('/dicom.json')).text(),'dicom'); check(dicom.instances[0].sop_instance_uid==='2.25.555001'); check(dicom.attributes.some((a:any)=>a.native_path==='/00111010/Value/0/00111002'&&a.vr==='DS')); + const publicText=await(await fetch('/public-dicom.json')).text(),publicDicom=u.projectDicomMetadata(publicText,'tcia'); + check(publicDicom.instances[0].metadata_json===publicText); + check(publicDicom.instances[0].sop_instance_uid==='1.3.6.1.4.1.14519.5.2.1.6279.6001.143451261327128179989900675595'); + check(publicDicom.attributes.some((a:any)=>a.tag==='7FE00010'&&a.bulk_data_uri==='sources/tcia-lidc-0001-ct.dcm#tag-7FE00010')); + check(publicDicom.attributes.some((a:any)=>a.tag==='00131010'&&a.vr==='LO')); const query={system:'http://www.ama-assn.org/go/cpt',release:'caller-selected',code:'fixture-only'}; check(u.lookupMedicalTerminology(query).status==='source-unavailable'); check(u.lookupMedicalTerminology(query,[{...query,future:{retained:true}}]).matches[0].future.retained); diff --git a/scripts/domain-pack-family.ts b/scripts/domain-pack-family.ts new file mode 100644 index 000000000..67a2b8ecb --- /dev/null +++ b/scripts/domain-pack-family.ts @@ -0,0 +1,23 @@ +import {resolve,dirname,relative,isAbsolute} from 'node:path'; +import {realpath} from 'node:fs/promises'; +import {readJsonValue} from '../src/model/serialization'; +import {requireDomainPackProfile} from '../src/domain-packs/profile'; +export async function resolveDomainFamily(input:string){ + const read=async(path:string)=>{const text=await Bun.file(path).text(),pack:any=readJsonValue(text,'json');requireDomainPackProfile(pack);return {path,text,pack};}; + const root=await read(resolve(input)); + if(!root.pack.composition)throw Error('No composition declared'); + if(!/^[a-z][a-z0-9-]*$/.test(root.pack.id))throw Error('Unsafe root pack identity'); + const familyRoot=await realpath(resolve(dirname(input),'..')); + const members=[root]; + for(const component of root.pack.composition.components){ + const path=await realpath(resolve(familyRoot,component.id,'pack.json')),inside=relative(familyRoot,path); + if(inside==='..'||inside.startsWith('../')||isAbsolute(inside))throw Error('Component symlink leaves family directory'); + const member=await read(path); + if(member.pack.id!==component.id||member.pack.version!==component.version)throw Error('Component identity/version differs'); + if(new Bun.CryptoHasher('sha256').update(member.text).digest('hex')!==component.checksum.value)throw Error('Component manifest checksum differs'); + if(member.pack.family?.id!==root.pack.id||member.pack.family?.version!==root.pack.version)throw Error('Component family differs'); + if(member.pack.composition)throw Error('Nested composition is not supported'); + members.push(member); + } + return members; +} diff --git a/scripts/export-domain-family.ts b/scripts/export-domain-family.ts new file mode 100644 index 000000000..31b318076 --- /dev/null +++ b/scripts/export-domain-family.ts @@ -0,0 +1,26 @@ +import {mkdtemp,mkdir,cp,rm} from 'node:fs/promises'; +import {tmpdir} from 'node:os'; +import {resolve,join} from 'node:path'; +import {resolveDomainFamily} from './domain-pack-family'; +const args=process.argv.slice(2),input=args[args.indexOf('--pack')+1],output=args[args.indexOf('--output')+1]; +if(!args.includes('--pack')||!args.includes('--output')||!input||!output)throw Error('Usage: --pack --output [--include-sources] [--check]'); +const members=await resolveDomainFamily(input),temporary=await mkdtemp(join(tmpdir(),'umf-family-')),destination=resolve(output),check=args.includes('--check'); +async function exportPack(path:string,target:string,verify=false){ + const child=Bun.spawn(['bun',resolve(import.meta.dir,'export-domain-pack.ts'),'--pack',path,'--output',target,...(args.includes('--include-sources')?['--include-sources']:[]),...(verify?['--check']:[])],{stdout:'pipe',stderr:'pipe'}); + const [code,stderr]=await Promise.all([child.exited,new Response(child.stderr).text(),new Response(child.stdout).text()]); + if(code)throw Error(stderr); +} +try{ + // Validate every source/schema before changing the selected destination. + for(const member of members)await exportPack(member.path,join(temporary,member.pack.id+'@'+member.pack.version)); + const inventory=JSON.stringify({version:'1.0.0',id:members[0]!.pack.id,packs:members.map(m=>({id:m.pack.id,version:m.pack.version,reference:m.pack.id+'@'+m.pack.version+'/domain-pack.json',checksum:{algorithm:'sha256',value:new Bun.CryptoHasher('sha256').update(m.text).digest('hex')}}))},null,2)+'\n'; + if(check){ + if(await Bun.file(join(destination,'family.json')).text()!==inventory)throw Error('Stale family inventory'); + for(const member of members)await exportPack(member.path,join(destination,member.pack.id+'@'+member.pack.version),true); + }else{ + await mkdir(destination,{recursive:true}); + for(const member of members)await cp(join(temporary,member.pack.id+'@'+member.pack.version),join(destination,member.pack.id+'@'+member.pack.version),{recursive:true}); + await Bun.write(join(destination,'family.json'),inventory); + } + console.log(JSON.stringify({family:members[0]!.pack.id,packs:members.length,checked:check})); +}finally{await rm(temporary,{recursive:true,force:true});} diff --git a/scripts/medical-subpacks-oracle.py b/scripts/medical-subpacks-oracle.py index 14d400d15..b18e123ad 100644 --- a/scripts/medical-subpacks-oracle.py +++ b/scripts/medical-subpacks-oracle.py @@ -6,6 +6,7 @@ from __future__ import annotations import argparse +import csv import hashlib import json import platform @@ -15,7 +16,7 @@ from zipfile import ZipFile ROOT = Path(__file__).resolve().parents[1] -PACKS = ['medical-carrier', 'medical-epidemiology', 'medical-imaging', 'medical-terminology'] +PACKS = ['medical', 'medical-carrier', 'medical-epidemiology', 'medical-imaging', 'medical-terminology'] def dicom_check(): @@ -41,7 +42,21 @@ def dicom_check(): assert projected['00111010']['Value'][0]['00111002']['Value'] == [1.25, 2.5] pack = json.loads((root.parent / 'pack.json').read_text()) assert '1.2500 to 1.25' in pack['qualification']['projection_losses'][0] - return {'oracle': 'pydicom', 'version': pydicom.__version__, 'python': platform.python_version(), 'checks': 14, + public = pydicom.dcmread(root / 'tcia-lidc-0001-ct.dcm') + selection = json.loads((root / 'tcia-selection.json').read_text()) + assert str(public.SOPInstanceUID) == selection['sop_instance_uid'] + assert str(public.SeriesInstanceUID) == selection['series_uid'] + assert str(public.StudyInstanceUID) == selection['study_uid'] + assert str(public.PatientID) == 'LIDC-IDRI-0001' + assert str(public.file_meta.TransferSyntaxUID) == selection['transfer_syntax'] + assert hashlib.sha256((root / 'tcia-lidc-0001-ct.dcm').read_bytes()).hexdigest() == selection['member_sha256'] + expected = public.to_json_dict(bulk_data_threshold=1024, bulk_data_element_handler=lambda e: 'sources/tcia-lidc-0001-ct.dcm#tag-' + f'{int(e.tag):08X}') + assert expected == json.loads((root / 'tcia-lidc-0001-ct.json').read_text()) + assert len([e for e in public.iterall() if e.tag.is_private]) == 3 + assert expected['7FE00010']['BulkDataURI'] == 'sources/tcia-lidc-0001-ct.dcm#tag-7FE00010' + assert (public.Rows, public.Columns) == (512, 512) + return {'oracle': 'pydicom', 'version': pydicom.__version__, 'python': platform.python_version(), 'checks': 24, + 'public_binary_sha256': selection['member_sha256'], 'binary_sha256': hashlib.sha256((root / 'synthetic.dcm').read_bytes()).hexdigest()} @@ -77,6 +92,8 @@ def tabular_check(output): assert archive.read(member) == (root / reference).read_bytes() for schema in pack['schemas']: assert archive.read(manifest['schema_artifacts'][schema['reference']]) == (root / schema['reference']).read_bytes() + if schema['format'] != 'tablespec': + continue native = json.loads((root / schema['reference']).read_text()) bindings = [b for b in pack['source_bindings'] if b['schema_id'] == schema['id'] and b['role'] == 'rows'] assert len(bindings) == 1 @@ -84,11 +101,20 @@ def tabular_check(output): expected = list(read_csv_rows(root / source['reference'], native)) actual = [row for batch in data.batches(schema['id']) for row in batch] assert actual == expected + if schema['id'].startswith('cms_'): + kind = {'cms_beneficiaries': 'beneficiaries', 'cms_inpatient_claims': 'inpatient', 'cms_carrier_claims': 'carrier'}[schema['id']] + with (root / ('sources/cms-' + kind + '.csv')).open(newline='') as original: + native_rows = list(csv.DictReader(original)) + assert len(native_rows) == len(actual) + for native_row, projected in zip(native_rows, actual): + assert all(projected[column] == value for column, value in native_row.items()) + if kind == 'carrier': + assert all(not value or (value[0].isalpha() and len(value) == 5) for column, value in native_row.items() if column.startswith('HCPCS_CD_')) recovered = temp / 'recovered.csv' recovered.write_bytes(archive.read('data/' + schema['id'] + '.csv')) assert list(read_csv_rows(recovered, native)) == expected if output: - target = Path(output) / (name + '-1.0.0.zip') + target = Path(output) / (name + '-' + pack['version'] + '.zip') target.parent.mkdir(parents=True, exist_ok=True) target.write_bytes(archives[0].read_bytes()) results.append({'pack': name, 'tables': len(data.specs), 'rows': sum(data.counts.values()), diff --git a/spec/domain-packs/medical-carrier/README.md b/spec/domain-packs/medical-carrier/README.md index 25695bf44..41afca60d 100644 --- a/spec/domain-packs/medical-carrier/README.md +++ b/spec/domain-packs/medical-carrier/README.md @@ -1,8 +1,8 @@ -# medical-carrier 1.0.0 +# medical-carrier 1.1.0 -9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events. +9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims). -Illustrative sources are not a validated FHIR Bundle or carrier simulation. Native official examples do not form a coherent history. CMS ingestion and X12 services are not implemented. Reference resolution is namespace-local; no patient matching. +Illustrative sources are not a validated FHIR Bundle or carrier simulation. Native official examples do not form a coherent history. CMS coverage is DE-SynPUF Sample 1, 2008 beneficiaries and 2008–2010 claims; ICD-9 remains native. Numeric CPT/Level I HCPCS carrier rows are excluded. These are synthetic public samples, not real beneficiaries. X12 services are not implemented. Reference resolution is namespace-local; no patient matching. Use the shared `export-domain-pack.ts --include-sources` command with this pack, then TableSpec `sample-data ingest`. Sources and schemas are local and checksum-pinned. Remote/licensed references remain metadata. diff --git a/spec/domain-packs/medical-carrier/data/cms_beneficiaries.csv b/spec/domain-packs/medical-carrier/data/cms_beneficiaries.csv new file mode 100644 index 000000000..8fd66d180 --- /dev/null +++ b/spec/domain-packs/medical-carrier/data/cms_beneficiaries.csv @@ -0,0 +1,4 @@ +DESYNPUF_ID,BENE_BIRTH_DT,BENE_DEATH_DT,BENE_SEX_IDENT_CD,BENE_RACE_CD,BENE_ESRD_IND,SP_STATE_CODE,BENE_COUNTY_CD,BENE_HI_CVRAGE_TOT_MONS,BENE_SMI_CVRAGE_TOT_MONS,BENE_HMO_CVRAGE_TOT_MONS,PLAN_CVRG_MOS_NUM,SP_ALZHDMTA,SP_CHF,SP_CHRNKIDN,SP_CNCR,SP_COPD,SP_DEPRESSN,SP_DIABETES,SP_ISCHMCHT,SP_OSTEOPRS,SP_RA_OA,SP_STRKETIA,MEDREIMB_IP,BENRES_IP,PPPYMT_IP,MEDREIMB_OP,BENRES_OP,PPPYMT_OP,MEDREIMB_CAR,BENRES_CAR,PPPYMT_CAR,native_record_number,native_csv_record +00013D2EFD8E45D1,19230501,,1,1,0,26,950,12,12,12,12,2,2,2,2,2,2,2,2,2,2,2,0.00,0.00,0.00,50.00,10.00,0.00,0.00,0.00,0.00,1,"00013D2EFD8E45D1,19230501,,1,1,0,26,950,12,12,12,12,2,2,2,2,2,2,2,2,2,2,2,0.00,0.00,0.00,50.00,10.00,0.00,0.00,0.00,0.00" +00016F745862898F,19430101,,1,1,0,39,230,12,12,0,00,2,2,2,2,2,2,2,2,2,2,2,0.00,0.00,0.00,0.00,0.00,0.00,700.00,240.00,0.00,2,"00016F745862898F,19430101,,1,1,0,39,230,12,12,0,00,2,2,2,2,2,2,2,2,2,2,2,0.00,0.00,0.00,0.00,0.00,0.00,700.00,240.00,0.00" +00024B3D2352D2D0,19360801,,1,1,0,52,590,12,12,0,00,2,2,2,2,2,2,2,2,1,2,2,0.00,0.00,0.00,30.00,40.00,0.00,220.00,80.00,0.00,5,"00024B3D2352D2D0,19360801,,1,1,0,52,590,12,12,0,00,2,2,2,2,2,2,2,2,1,2,2,0.00,0.00,0.00,30.00,40.00,0.00,220.00,80.00,0.00" diff --git a/spec/domain-packs/medical-carrier/data/cms_carrier_claims.csv b/spec/domain-packs/medical-carrier/data/cms_carrier_claims.csv new file mode 100644 index 000000000..1e86bf797 --- /dev/null +++ b/spec/domain-packs/medical-carrier/data/cms_carrier_claims.csv @@ -0,0 +1,6 @@ +DESYNPUF_ID,CLM_ID,CLM_FROM_DT,CLM_THRU_DT,ICD9_DGNS_CD_1,ICD9_DGNS_CD_2,ICD9_DGNS_CD_3,ICD9_DGNS_CD_4,ICD9_DGNS_CD_5,ICD9_DGNS_CD_6,ICD9_DGNS_CD_7,ICD9_DGNS_CD_8,PRF_PHYSN_NPI_1,PRF_PHYSN_NPI_2,PRF_PHYSN_NPI_3,PRF_PHYSN_NPI_4,PRF_PHYSN_NPI_5,PRF_PHYSN_NPI_6,PRF_PHYSN_NPI_7,PRF_PHYSN_NPI_8,PRF_PHYSN_NPI_9,PRF_PHYSN_NPI_10,PRF_PHYSN_NPI_11,PRF_PHYSN_NPI_12,PRF_PHYSN_NPI_13,TAX_NUM_1,TAX_NUM_2,TAX_NUM_3,TAX_NUM_4,TAX_NUM_5,TAX_NUM_6,TAX_NUM_7,TAX_NUM_8,TAX_NUM_9,TAX_NUM_10,TAX_NUM_11,TAX_NUM_12,TAX_NUM_13,HCPCS_CD_1,HCPCS_CD_2,HCPCS_CD_3,HCPCS_CD_4,HCPCS_CD_5,HCPCS_CD_6,HCPCS_CD_7,HCPCS_CD_8,HCPCS_CD_9,HCPCS_CD_10,HCPCS_CD_11,HCPCS_CD_12,HCPCS_CD_13,LINE_NCH_PMT_AMT_1,LINE_NCH_PMT_AMT_2,LINE_NCH_PMT_AMT_3,LINE_NCH_PMT_AMT_4,LINE_NCH_PMT_AMT_5,LINE_NCH_PMT_AMT_6,LINE_NCH_PMT_AMT_7,LINE_NCH_PMT_AMT_8,LINE_NCH_PMT_AMT_9,LINE_NCH_PMT_AMT_10,LINE_NCH_PMT_AMT_11,LINE_NCH_PMT_AMT_12,LINE_NCH_PMT_AMT_13,LINE_BENE_PTB_DDCTBL_AMT_1,LINE_BENE_PTB_DDCTBL_AMT_2,LINE_BENE_PTB_DDCTBL_AMT_3,LINE_BENE_PTB_DDCTBL_AMT_4,LINE_BENE_PTB_DDCTBL_AMT_5,LINE_BENE_PTB_DDCTBL_AMT_6,LINE_BENE_PTB_DDCTBL_AMT_7,LINE_BENE_PTB_DDCTBL_AMT_8,LINE_BENE_PTB_DDCTBL_AMT_9,LINE_BENE_PTB_DDCTBL_AMT_10,LINE_BENE_PTB_DDCTBL_AMT_11,LINE_BENE_PTB_DDCTBL_AMT_12,LINE_BENE_PTB_DDCTBL_AMT_13,LINE_BENE_PRMRY_PYR_PD_AMT_1,LINE_BENE_PRMRY_PYR_PD_AMT_2,LINE_BENE_PRMRY_PYR_PD_AMT_3,LINE_BENE_PRMRY_PYR_PD_AMT_4,LINE_BENE_PRMRY_PYR_PD_AMT_5,LINE_BENE_PRMRY_PYR_PD_AMT_6,LINE_BENE_PRMRY_PYR_PD_AMT_7,LINE_BENE_PRMRY_PYR_PD_AMT_8,LINE_BENE_PRMRY_PYR_PD_AMT_9,LINE_BENE_PRMRY_PYR_PD_AMT_10,LINE_BENE_PRMRY_PYR_PD_AMT_11,LINE_BENE_PRMRY_PYR_PD_AMT_12,LINE_BENE_PRMRY_PYR_PD_AMT_13,LINE_COINSRNC_AMT_1,LINE_COINSRNC_AMT_2,LINE_COINSRNC_AMT_3,LINE_COINSRNC_AMT_4,LINE_COINSRNC_AMT_5,LINE_COINSRNC_AMT_6,LINE_COINSRNC_AMT_7,LINE_COINSRNC_AMT_8,LINE_COINSRNC_AMT_9,LINE_COINSRNC_AMT_10,LINE_COINSRNC_AMT_11,LINE_COINSRNC_AMT_12,LINE_COINSRNC_AMT_13,LINE_ALOWD_CHRG_AMT_1,LINE_ALOWD_CHRG_AMT_2,LINE_ALOWD_CHRG_AMT_3,LINE_ALOWD_CHRG_AMT_4,LINE_ALOWD_CHRG_AMT_5,LINE_ALOWD_CHRG_AMT_6,LINE_ALOWD_CHRG_AMT_7,LINE_ALOWD_CHRG_AMT_8,LINE_ALOWD_CHRG_AMT_9,LINE_ALOWD_CHRG_AMT_10,LINE_ALOWD_CHRG_AMT_11,LINE_ALOWD_CHRG_AMT_12,LINE_ALOWD_CHRG_AMT_13,LINE_PRCSG_IND_CD_1,LINE_PRCSG_IND_CD_2,LINE_PRCSG_IND_CD_3,LINE_PRCSG_IND_CD_4,LINE_PRCSG_IND_CD_5,LINE_PRCSG_IND_CD_6,LINE_PRCSG_IND_CD_7,LINE_PRCSG_IND_CD_8,LINE_PRCSG_IND_CD_9,LINE_PRCSG_IND_CD_10,LINE_PRCSG_IND_CD_11,LINE_PRCSG_IND_CD_12,LINE_PRCSG_IND_CD_13,LINE_ICD9_DGNS_CD_1,LINE_ICD9_DGNS_CD_2,LINE_ICD9_DGNS_CD_3,LINE_ICD9_DGNS_CD_4,LINE_ICD9_DGNS_CD_5,LINE_ICD9_DGNS_CD_6,LINE_ICD9_DGNS_CD_7,LINE_ICD9_DGNS_CD_8,LINE_ICD9_DGNS_CD_9,LINE_ICD9_DGNS_CD_10,LINE_ICD9_DGNS_CD_11,LINE_ICD9_DGNS_CD_12,LINE_ICD9_DGNS_CD_13,native_record_number,native_csv_record +00016F745862898F,887453384924494,20090716,20090716,78965,78703,5770,78321,,,,,5390193581,,,,,,,,,,,,,602380861,,,,,,,,,,,,,A0427,,,,,,,,,,,,,80.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,90.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,20.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,100.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,A,,,,,,,,,,,,,78907,,,,,,,,,,,,,24,"00016F745862898F,887453384924494,20090716,20090716,78965,78703,5770,78321,,,,,5390193581,,,,,,,,,,,,,602380861,,,,,,,,,,,,,A0427,,,,,,,,,,,,,80.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,90.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,20.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,100.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,A,,,,,,,,,,,,,78907,,,,,,,,,,,," +00024B3D2352D2D0,887753388589395,20080916,20080916,V2882,,,,,,,,7199105618,,,,,,,,,,,,,982048809,,,,,,,,,,,,,G0202,,,,,,,,,,,,,30.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,10.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,100.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,A,,,,,,,,,,,,,V7612,,,,,,,,,,,,,54,"00024B3D2352D2D0,887753388589395,20080916,20080916,V2882,,,,,,,,7199105618,,,,,,,,,,,,,982048809,,,,,,,,,,,,,G0202,,,,,,,,,,,,,30.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,10.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,100.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,A,,,,,,,,,,,,,V7612,,,,,,,,,,,," +00024B3D2352D2D0,887233387820468,20090425,20090425,83510,71901,,,,,,,2655559178,,,,,,,,,,,,,982048809,,,,,,,,,,,,,G0283,,,,,,,,,,,,,10.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,10.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,30.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,A,,,,,,,,,,,,,83100,,,,,,,,,,,,,56,"00024B3D2352D2D0,887233387820468,20090425,20090425,83510,71901,,,,,,,2655559178,,,,,,,,,,,,,982048809,,,,,,,,,,,,,G0283,,,,,,,,,,,,,10.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,10.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,30.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,A,,,,,,,,,,,,,83100,,,,,,,,,,,," +00024B3D2352D2D0,887523387400539,20091118,20091118,V7381,,,,,,,,7812593983,7812593983,,,,,,,,,,,,255271799,255271799,,,,,,,,,,,,G0008,G0008,,,,,,,,,,,,10.00,10.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,10.00,20.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,A,A,,,,,,,,,,,,V0481,V0481,,,,,,,,,,,,66,"00024B3D2352D2D0,887523387400539,20091118,20091118,V7381,,,,,,,,7812593983,7812593983,,,,,,,,,,,,255271799,255271799,,,,,,,,,,,,G0008,G0008,,,,,,,,,,,,10.00,10.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,10.00,20.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,A,A,,,,,,,,,,,,V0481,V0481,,,,,,,,,,," +00024B3D2352D2D0,887023388626288,20100131,20100131,V2881,79382,,,,,,,3295479888,3295479888,,,,,,,,,,,,982048809,982048809,,,,,,,,,,,,G0202,G0202,,,,,,,,,,,,10.00,110.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,10.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,130.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,O,A,,,,,,,,,,,,V7612,V7612,,,,,,,,,,,,68,"00024B3D2352D2D0,887023388626288,20100131,20100131,V2881,79382,,,,,,,3295479888,3295479888,,,,,,,,,,,,982048809,982048809,,,,,,,,,,,,G0202,G0202,,,,,,,,,,,,10.00,110.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,10.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,130.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,O,A,,,,,,,,,,,,V7612,V7612,,,,,,,,,,," diff --git a/spec/domain-packs/medical-carrier/data/cms_inpatient_claims.csv b/spec/domain-packs/medical-carrier/data/cms_inpatient_claims.csv new file mode 100644 index 000000000..a3bfbc7b0 --- /dev/null +++ b/spec/domain-packs/medical-carrier/data/cms_inpatient_claims.csv @@ -0,0 +1,6 @@ +DESYNPUF_ID,CLM_ID,SEGMENT,CLM_FROM_DT,CLM_THRU_DT,PRVDR_NUM,CLM_PMT_AMT,NCH_PRMRY_PYR_CLM_PD_AMT,AT_PHYSN_NPI,OP_PHYSN_NPI,OT_PHYSN_NPI,CLM_ADMSN_DT,ADMTNG_ICD9_DGNS_CD,CLM_PASS_THRU_PER_DIEM_AMT,NCH_BENE_IP_DDCTBL_AMT,NCH_BENE_PTA_COINSRNC_LBLTY_AM,NCH_BENE_BLOOD_DDCTBL_LBLTY_AM,CLM_UTLZTN_DAY_CNT,NCH_BENE_DSCHRG_DT,CLM_DRG_CD,ICD9_DGNS_CD_1,ICD9_DGNS_CD_2,ICD9_DGNS_CD_3,ICD9_DGNS_CD_4,ICD9_DGNS_CD_5,ICD9_DGNS_CD_6,ICD9_DGNS_CD_7,ICD9_DGNS_CD_8,ICD9_DGNS_CD_9,ICD9_DGNS_CD_10,ICD9_PRCDR_CD_1,ICD9_PRCDR_CD_2,ICD9_PRCDR_CD_3,ICD9_PRCDR_CD_4,ICD9_PRCDR_CD_5,ICD9_PRCDR_CD_6,HCPCS_CD_1,HCPCS_CD_2,HCPCS_CD_3,HCPCS_CD_4,HCPCS_CD_5,HCPCS_CD_6,HCPCS_CD_7,HCPCS_CD_8,HCPCS_CD_9,HCPCS_CD_10,HCPCS_CD_11,HCPCS_CD_12,HCPCS_CD_13,HCPCS_CD_14,HCPCS_CD_15,HCPCS_CD_16,HCPCS_CD_17,HCPCS_CD_18,HCPCS_CD_19,HCPCS_CD_20,HCPCS_CD_21,HCPCS_CD_22,HCPCS_CD_23,HCPCS_CD_24,HCPCS_CD_25,HCPCS_CD_26,HCPCS_CD_27,HCPCS_CD_28,HCPCS_CD_29,HCPCS_CD_30,HCPCS_CD_31,HCPCS_CD_32,HCPCS_CD_33,HCPCS_CD_34,HCPCS_CD_35,HCPCS_CD_36,HCPCS_CD_37,HCPCS_CD_38,HCPCS_CD_39,HCPCS_CD_40,HCPCS_CD_41,HCPCS_CD_42,HCPCS_CD_43,HCPCS_CD_44,HCPCS_CD_45,native_record_number,native_csv_record +00013D2EFD8E45D1,196661176988405,1,20100312,20100313,2600GD,4000.00,0.00,3139083564,,,20100312,4580,0.00,1100.00,0.00,0.00,1,20100313,217,7802,78820,V4501,4280,2720,4019,V4502,73300,E9330,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,1,"00013D2EFD8E45D1,196661176988405,1,20100312,20100313,2600GD,4000.00,0.00,3139083564,,,20100312,4580,0.00,1100.00,0.00,0.00,1,20100313,217,7802,78820,V4501,4280,2720,4019,V4502,73300,E9330,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,," +00016F745862898F,196201177000368,1,20090412,20090418,3900MB,26000.00,0.00,6476809087,,,20090412,7866,0.00,1068.00,0.00,0.00,6,20090418,201,1970,4019,5853,7843,2768,71590,2724,19889,5849,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,2,"00016F745862898F,196201177000368,1,20090412,20090418,3900MB,26000.00,0.00,6476809087,,,20090412,7866,0.00,1068.00,0.00,0.00,6,20090418,201,1970,4019,5853,7843,2768,71590,2724,19889,5849,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,," +00016F745862898F,196661177015632,1,20090831,20090902,3900HM,5000.00,0.00,0611998537,0611998537,,20090831,6186,0.00,1068.00,0.00,0.00,2,20090902,750,6186,2948,56400,,,,,,,,7092,6186,V5866,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,3,"00016F745862898F,196661177015632,1,20090831,20090902,3900HM,5000.00,0.00,0611998537,0611998537,,20090831,6186,0.00,1068.00,0.00,0.00,2,20090902,750,6186,2948,56400,,,,,,,,7092,6186,V5866,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,," +00016F745862898F,196091176981058,1,20090917,20090920,3913XU,5000.00,0.00,4971602784,,1119000316,20090917,29590,0.00,1068.00,0.00,0.00,3,20090920,883,29623,30390,71690,34590,V1581,32723,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,4,"00016F745862898F,196091176981058,1,20090917,20090920,3913XU,5000.00,0.00,4971602784,,1119000316,20090917,29590,0.00,1068.00,0.00,0.00,3,20090920,883,29623,30390,71690,34590,V1581,32723,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,," +00016F745862898F,196261176983265,1,20100626,20100701,3900MB,16000.00,0.00,6408400473,1960859579,,20100626,5849,0.00,1100.00,0.00,0.00,5,20100701,983,3569,4019,3542,V8801,78820,2639,7840,7856,4271,,,E8889,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,5,"00016F745862898F,196261176983265,1,20100626,20100701,3900MB,16000.00,0.00,6408400473,1960859579,,20100626,5849,0.00,1100.00,0.00,0.00,5,20100701,983,3569,4019,3542,V8801,78820,2639,7840,7856,4271,,,E8889,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,," diff --git a/spec/domain-packs/medical-carrier/licenses/NOTICE.txt b/spec/domain-packs/medical-carrier/licenses/NOTICE.txt index 5160c4653..e095622ed 100644 --- a/spec/domain-packs/medical-carrier/licenses/NOTICE.txt +++ b/spec/domain-packs/medical-carrier/licenses/NOTICE.txt @@ -1 +1 @@ -HL7 FHIR R4 examples: CC0 per https://hl7.org/fhir/R4/license.html. HL7/FHIR trademarks do not imply endorsement. Selected examples contain no explicitly identified SNOMED CT, CPT, CDT or DICOM terminology. Unqualified codes retain their absent system; no dictionary rights or clinical meaning are inferred. UMF-authored supplemental scenarios and projections may be redistributed with this notice. +HL7 FHIR R4 examples: CC0 per https://hl7.org/fhir/R4/license.html. HL7/FHIR trademarks do not imply endorsement. Selected examples contain no explicitly identified SNOMED CT, CPT, CDT or DICOM terminology. Unqualified codes retain their absent system; no dictionary rights or clinical meaning are inferred. UMF-authored supplemental scenarios and projections may be redistributed with this notice. CMS DE-SynPUF is a public synthetic software-development release: https://www.cms.gov/data-research/statistics-trends-and-reports/medicare-claims-synthetic-public-use-files ; CMS public-domain site declaration: https://www.cms.gov/about-cms/web-policies-important-links/about-website/link-to-us . This bounded excerpt keeps native bytes; numeric CPT/Level I HCPCS carrier rows are excluded, and no CPT descriptors/dictionary or clinical mapping is distributed. Source files, selection and upstream hashes are in cms-selection.json. diff --git a/spec/domain-packs/medical-carrier/ontology.json b/spec/domain-packs/medical-carrier/ontology.json new file mode 100644 index 000000000..1b2a918fd --- /dev/null +++ b/spec/domain-packs/medical-carrier/ontology.json @@ -0,0 +1,5908 @@ +{ + "umf": "0.8.0", + "id": "urn:umf:domain:medical-carrier", + "title": "medical-carrier ontology", + "vocabularies": {}, + "modules": [ + { + "id": "domain", + "namespace": "urn:umf:domain:medical-carrier:", + "elements": [ + { + "id": "resources", + "kind": "record", + "name": "resources", + "title": "resources", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "members": [ + { + "module": "domain", + "element": "resources.resource_key" + }, + { + "module": "domain", + "element": "resources.source_id" + }, + { + "module": "domain", + "element": "resources.resource_type" + }, + { + "module": "domain", + "element": "resources.native_id" + }, + { + "module": "domain", + "element": "resources.resource_json" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "resources.resource_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "resources.resource_key", + "name": "resource_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "resource key", + "extensions": {} + }, + { + "id": "resources.source_id", + "name": "source_id", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "source id", + "extensions": {} + }, + { + "id": "resources.resource_type", + "name": "resource_type", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "resource type", + "extensions": {} + }, + { + "id": "resources.native_id", + "name": "native_id", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native id", + "extensions": {} + }, + { + "id": "resources.resource_json", + "name": "resource_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "resource json", + "extensions": {} + }, + { + "id": "coverage", + "kind": "record", + "name": "coverage", + "title": "coverage", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "members": [ + { + "module": "domain", + "element": "coverage.resource_key" + }, + { + "module": "domain", + "element": "coverage.status" + }, + { + "module": "domain", + "element": "coverage.beneficiary_json" + }, + { + "module": "domain", + "element": "coverage.subscriber_json" + }, + { + "module": "domain", + "element": "coverage.payors_json" + }, + { + "module": "domain", + "element": "coverage.classes_json" + }, + { + "module": "domain", + "element": "coverage.period_start" + }, + { + "module": "domain", + "element": "coverage.period_end" + }, + { + "module": "domain", + "element": "coverage.benefits_json" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "coverage.resource_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "coverage.resource_key", + "name": "resource_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "resource key", + "extensions": {} + }, + { + "id": "coverage.status", + "name": "status", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "status", + "extensions": {} + }, + { + "id": "coverage.beneficiary_json", + "name": "beneficiary_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "beneficiary json", + "extensions": {} + }, + { + "id": "coverage.subscriber_json", + "name": "subscriber_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "subscriber json", + "extensions": {} + }, + { + "id": "coverage.payors_json", + "name": "payors_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "payors json", + "extensions": {} + }, + { + "id": "coverage.classes_json", + "name": "classes_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "classes json", + "extensions": {} + }, + { + "id": "coverage.period_start", + "name": "period_start", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "period start", + "extensions": {} + }, + { + "id": "coverage.period_end", + "name": "period_end", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "period end", + "extensions": {} + }, + { + "id": "coverage.benefits_json", + "name": "benefits_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "benefits json", + "extensions": {} + }, + { + "id": "eligibility", + "kind": "record", + "name": "eligibility", + "title": "eligibility", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "members": [ + { + "module": "domain", + "element": "eligibility.resource_key" + }, + { + "module": "domain", + "element": "eligibility.status" + }, + { + "module": "domain", + "element": "eligibility.patient_reference" + }, + { + "module": "domain", + "element": "eligibility.direction" + }, + { + "module": "domain", + "element": "eligibility.purpose_json" + }, + { + "module": "domain", + "element": "eligibility.created" + }, + { + "module": "domain", + "element": "eligibility.serviced_json" + }, + { + "module": "domain", + "element": "eligibility.request_json" + }, + { + "module": "domain", + "element": "eligibility.outcome" + }, + { + "module": "domain", + "element": "eligibility.insurance_json" + }, + { + "module": "domain", + "element": "eligibility.items_json" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "eligibility.resource_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "eligibility.resource_key", + "name": "resource_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "resource key", + "extensions": {} + }, + { + "id": "eligibility.status", + "name": "status", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "status", + "extensions": {} + }, + { + "id": "eligibility.patient_reference", + "name": "patient_reference", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "patient reference", + "extensions": {} + }, + { + "id": "eligibility.direction", + "name": "direction", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "direction", + "extensions": {} + }, + { + "id": "eligibility.purpose_json", + "name": "purpose_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "purpose json", + "extensions": {} + }, + { + "id": "eligibility.created", + "name": "created", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "created", + "extensions": {} + }, + { + "id": "eligibility.serviced_json", + "name": "serviced_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "serviced json", + "extensions": {} + }, + { + "id": "eligibility.request_json", + "name": "request_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "request json", + "extensions": {} + }, + { + "id": "eligibility.outcome", + "name": "outcome", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "outcome", + "extensions": {} + }, + { + "id": "eligibility.insurance_json", + "name": "insurance_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "insurance json", + "extensions": {} + }, + { + "id": "eligibility.items_json", + "name": "items_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "items json", + "extensions": {} + }, + { + "id": "claims", + "kind": "record", + "name": "claims", + "title": "claims", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "members": [ + { + "module": "domain", + "element": "claims.resource_key" + }, + { + "module": "domain", + "element": "claims.status" + }, + { + "module": "domain", + "element": "claims.patient_reference" + }, + { + "module": "domain", + "element": "claims.resource_type" + }, + { + "module": "domain", + "element": "claims.use" + }, + { + "module": "domain", + "element": "claims.type_json" + }, + { + "module": "domain", + "element": "claims.created" + }, + { + "module": "domain", + "element": "claims.outcome" + }, + { + "module": "domain", + "element": "claims.request_json" + }, + { + "module": "domain", + "element": "claims.insurance_json" + }, + { + "module": "domain", + "element": "claims.diagnoses_json" + }, + { + "module": "domain", + "element": "claims.procedures_json" + }, + { + "module": "domain", + "element": "claims.related_json" + }, + { + "module": "domain", + "element": "claims.totals_json" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "claims.resource_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "claims.resource_key", + "name": "resource_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "resource key", + "extensions": {} + }, + { + "id": "claims.status", + "name": "status", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "status", + "extensions": {} + }, + { + "id": "claims.patient_reference", + "name": "patient_reference", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "patient reference", + "extensions": {} + }, + { + "id": "claims.resource_type", + "name": "resource_type", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "resource type", + "extensions": {} + }, + { + "id": "claims.use", + "name": "use", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "use", + "extensions": {} + }, + { + "id": "claims.type_json", + "name": "type_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "type json", + "extensions": {} + }, + { + "id": "claims.created", + "name": "created", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "created", + "extensions": {} + }, + { + "id": "claims.outcome", + "name": "outcome", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "outcome", + "extensions": {} + }, + { + "id": "claims.request_json", + "name": "request_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "request json", + "extensions": {} + }, + { + "id": "claims.insurance_json", + "name": "insurance_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "insurance json", + "extensions": {} + }, + { + "id": "claims.diagnoses_json", + "name": "diagnoses_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "diagnoses json", + "extensions": {} + }, + { + "id": "claims.procedures_json", + "name": "procedures_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "procedures json", + "extensions": {} + }, + { + "id": "claims.related_json", + "name": "related_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "related json", + "extensions": {} + }, + { + "id": "claims.totals_json", + "name": "totals_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "totals json", + "extensions": {} + }, + { + "id": "claim_lines", + "kind": "record", + "name": "claim_lines", + "title": "claim_lines", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "members": [ + { + "module": "domain", + "element": "claim_lines.line_key" + }, + { + "module": "domain", + "element": "claim_lines.resource_key" + }, + { + "module": "domain", + "element": "claim_lines.parent_line_key" + }, + { + "module": "domain", + "element": "claim_lines.native_path" + }, + { + "module": "domain", + "element": "claim_lines.sequence" + }, + { + "module": "domain", + "element": "claim_lines.product_json" + }, + { + "module": "domain", + "element": "claim_lines.modifiers_json" + }, + { + "module": "domain", + "element": "claim_lines.service_json" + }, + { + "module": "domain", + "element": "claim_lines.quantity" + }, + { + "module": "domain", + "element": "claim_lines.unit_price" + }, + { + "module": "domain", + "element": "claim_lines.net_amount" + }, + { + "module": "domain", + "element": "claim_lines.net_currency" + }, + { + "module": "domain", + "element": "claim_lines.line_json" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "claim_lines.line_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "claim_lines.line_key", + "name": "line_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "line key", + "extensions": {} + }, + { + "id": "claim_lines.resource_key", + "name": "resource_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "resource key", + "extensions": {} + }, + { + "id": "claim_lines.parent_line_key", + "name": "parent_line_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "parent line key", + "extensions": {} + }, + { + "id": "claim_lines.native_path", + "name": "native_path", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native path", + "extensions": {} + }, + { + "id": "claim_lines.sequence", + "name": "sequence", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "sequence", + "extensions": {} + }, + { + "id": "claim_lines.product_json", + "name": "product_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "product json", + "extensions": {} + }, + { + "id": "claim_lines.modifiers_json", + "name": "modifiers_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "modifiers json", + "extensions": {} + }, + { + "id": "claim_lines.service_json", + "name": "service_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "service json", + "extensions": {} + }, + { + "id": "claim_lines.quantity", + "name": "quantity", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "quantity", + "extensions": {} + }, + { + "id": "claim_lines.unit_price", + "name": "unit_price", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "unit price", + "extensions": {} + }, + { + "id": "claim_lines.net_amount", + "name": "net_amount", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "net amount", + "extensions": {} + }, + { + "id": "claim_lines.net_currency", + "name": "net_currency", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "net currency", + "extensions": {} + }, + { + "id": "claim_lines.line_json", + "name": "line_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "line json", + "extensions": {} + }, + { + "id": "adjudications", + "kind": "record", + "name": "adjudications", + "title": "adjudications", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "members": [ + { + "module": "domain", + "element": "adjudications.adjudication_key" + }, + { + "module": "domain", + "element": "adjudications.resource_key" + }, + { + "module": "domain", + "element": "adjudications.line_key" + }, + { + "module": "domain", + "element": "adjudications.category_json" + }, + { + "module": "domain", + "element": "adjudications.reason_json" + }, + { + "module": "domain", + "element": "adjudications.amount" + }, + { + "module": "domain", + "element": "adjudications.currency" + }, + { + "module": "domain", + "element": "adjudications.value" + }, + { + "module": "domain", + "element": "adjudications.native_json" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "adjudications.adjudication_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "adjudications.adjudication_key", + "name": "adjudication_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "adjudication key", + "extensions": {} + }, + { + "id": "adjudications.resource_key", + "name": "resource_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "resource key", + "extensions": {} + }, + { + "id": "adjudications.line_key", + "name": "line_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "line key", + "extensions": {} + }, + { + "id": "adjudications.category_json", + "name": "category_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "category json", + "extensions": {} + }, + { + "id": "adjudications.reason_json", + "name": "reason_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "reason json", + "extensions": {} + }, + { + "id": "adjudications.amount", + "name": "amount", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "amount", + "extensions": {} + }, + { + "id": "adjudications.currency", + "name": "currency", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "currency", + "extensions": {} + }, + { + "id": "adjudications.value", + "name": "value", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "value", + "extensions": {} + }, + { + "id": "adjudications.native_json", + "name": "native_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native json", + "extensions": {} + }, + { + "id": "payments", + "kind": "record", + "name": "payments", + "title": "payments", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "members": [ + { + "module": "domain", + "element": "payments.payment_key" + }, + { + "module": "domain", + "element": "payments.resource_key" + }, + { + "module": "domain", + "element": "payments.date" + }, + { + "module": "domain", + "element": "payments.amount" + }, + { + "module": "domain", + "element": "payments.currency" + }, + { + "module": "domain", + "element": "payments.allocations_json" + }, + { + "module": "domain", + "element": "payments.native_json" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "payments.payment_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "payments.payment_key", + "name": "payment_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "payment key", + "extensions": {} + }, + { + "id": "payments.resource_key", + "name": "resource_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "resource key", + "extensions": {} + }, + { + "id": "payments.date", + "name": "date", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "date", + "extensions": {} + }, + { + "id": "payments.amount", + "name": "amount", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "amount", + "extensions": {} + }, + { + "id": "payments.currency", + "name": "currency", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "currency", + "extensions": {} + }, + { + "id": "payments.allocations_json", + "name": "allocations_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "allocations json", + "extensions": {} + }, + { + "id": "payments.native_json", + "name": "native_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native json", + "extensions": {} + }, + { + "id": "plans", + "kind": "record", + "name": "plans", + "title": "plans", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "members": [ + { + "module": "domain", + "element": "plans.resource_key" + }, + { + "module": "domain", + "element": "plans.status" + }, + { + "module": "domain", + "element": "plans.name" + }, + { + "module": "domain", + "element": "plans.period_json" + }, + { + "module": "domain", + "element": "plans.owner_json" + }, + { + "module": "domain", + "element": "plans.coverage_json" + }, + { + "module": "domain", + "element": "plans.plans_json" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "plans.resource_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "plans.resource_key", + "name": "resource_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "resource key", + "extensions": {} + }, + { + "id": "plans.status", + "name": "status", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "status", + "extensions": {} + }, + { + "id": "plans.name", + "name": "name", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "name", + "extensions": {} + }, + { + "id": "plans.period_json", + "name": "period_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "period json", + "extensions": {} + }, + { + "id": "plans.owner_json", + "name": "owner_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "owner json", + "extensions": {} + }, + { + "id": "plans.coverage_json", + "name": "coverage_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "coverage json", + "extensions": {} + }, + { + "id": "plans.plans_json", + "name": "plans_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "plans json", + "extensions": {} + }, + { + "id": "enrollments", + "kind": "record", + "name": "enrollments", + "title": "enrollments", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "members": [ + { + "module": "domain", + "element": "enrollments.resource_key" + }, + { + "module": "domain", + "element": "enrollments.direction" + }, + { + "module": "domain", + "element": "enrollments.status" + }, + { + "module": "domain", + "element": "enrollments.created" + }, + { + "module": "domain", + "element": "enrollments.candidate_json" + }, + { + "module": "domain", + "element": "enrollments.coverage_json" + }, + { + "module": "domain", + "element": "enrollments.request_json" + }, + { + "module": "domain", + "element": "enrollments.outcome" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "enrollments.resource_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "enrollments.resource_key", + "name": "resource_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "resource key", + "extensions": {} + }, + { + "id": "enrollments.direction", + "name": "direction", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "direction", + "extensions": {} + }, + { + "id": "enrollments.status", + "name": "status", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "status", + "extensions": {} + }, + { + "id": "enrollments.created", + "name": "created", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "created", + "extensions": {} + }, + { + "id": "enrollments.candidate_json", + "name": "candidate_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "candidate json", + "extensions": {} + }, + { + "id": "enrollments.coverage_json", + "name": "coverage_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "coverage json", + "extensions": {} + }, + { + "id": "enrollments.request_json", + "name": "request_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "request json", + "extensions": {} + }, + { + "id": "enrollments.outcome", + "name": "outcome", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "outcome", + "extensions": {} + }, + { + "id": "resource_references", + "kind": "record", + "name": "resource_references", + "title": "resource_references", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "members": [ + { + "module": "domain", + "element": "resource_references.reference_key" + }, + { + "module": "domain", + "element": "resource_references.resource_key" + }, + { + "module": "domain", + "element": "resource_references.native_path" + }, + { + "module": "domain", + "element": "resource_references.native_reference" + }, + { + "module": "domain", + "element": "resource_references.target_key" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "resource_references.reference_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "resource_references.reference_key", + "name": "reference_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "reference key", + "extensions": {} + }, + { + "id": "resource_references.resource_key", + "name": "resource_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "resource key", + "extensions": {} + }, + { + "id": "resource_references.native_path", + "name": "native_path", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native path", + "extensions": {} + }, + { + "id": "resource_references.native_reference", + "name": "native_reference", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native reference", + "extensions": {} + }, + { + "id": "resource_references.target_key", + "name": "target_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "target key", + "extensions": {} + }, + { + "id": "coded_values", + "kind": "record", + "name": "coded_values", + "title": "coded_values", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "members": [ + { + "module": "domain", + "element": "coded_values.coding_key" + }, + { + "module": "domain", + "element": "coded_values.resource_key" + }, + { + "module": "domain", + "element": "coded_values.native_path" + }, + { + "module": "domain", + "element": "coded_values.system" + }, + { + "module": "domain", + "element": "coded_values.release" + }, + { + "module": "domain", + "element": "coded_values.code" + }, + { + "module": "domain", + "element": "coded_values.display" + }, + { + "module": "domain", + "element": "coded_values.native_json" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "coded_values.coding_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "coded_values.coding_key", + "name": "coding_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "coding key", + "extensions": {} + }, + { + "id": "coded_values.resource_key", + "name": "resource_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "resource key", + "extensions": {} + }, + { + "id": "coded_values.native_path", + "name": "native_path", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native path", + "extensions": {} + }, + { + "id": "coded_values.system", + "name": "system", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "system", + "extensions": {} + }, + { + "id": "coded_values.release", + "name": "release", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "release", + "extensions": {} + }, + { + "id": "coded_values.code", + "name": "code", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "code", + "extensions": {} + }, + { + "id": "coded_values.display", + "name": "display", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "display", + "extensions": {} + }, + { + "id": "coded_values.native_json", + "name": "native_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native json", + "extensions": {} + }, + { + "id": "workflow_events", + "kind": "record", + "name": "workflow_events", + "title": "workflow_events", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "members": [ + { + "module": "domain", + "element": "workflow_events.event_key" + }, + { + "module": "domain", + "element": "workflow_events.event_type" + }, + { + "module": "domain", + "element": "workflow_events.subject_key" + }, + { + "module": "domain", + "element": "workflow_events.claim_key" + }, + { + "module": "domain", + "element": "workflow_events.prior_event_key" + }, + { + "module": "domain", + "element": "workflow_events.date" + }, + { + "module": "domain", + "element": "workflow_events.status" + }, + { + "module": "domain", + "element": "workflow_events.amount" + }, + { + "module": "domain", + "element": "workflow_events.currency" + }, + { + "module": "domain", + "element": "workflow_events.details_json" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "workflow_events.event_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "workflow_events.event_key", + "name": "event_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "event key", + "extensions": {} + }, + { + "id": "workflow_events.event_type", + "name": "event_type", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "event type", + "extensions": {} + }, + { + "id": "workflow_events.subject_key", + "name": "subject_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "subject key", + "extensions": {} + }, + { + "id": "workflow_events.claim_key", + "name": "claim_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "claim key", + "extensions": {} + }, + { + "id": "workflow_events.prior_event_key", + "name": "prior_event_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "prior event key", + "extensions": {} + }, + { + "id": "workflow_events.date", + "name": "date", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "date", + "extensions": {} + }, + { + "id": "workflow_events.status", + "name": "status", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "status", + "extensions": {} + }, + { + "id": "workflow_events.amount", + "name": "amount", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "amount", + "extensions": {} + }, + { + "id": "workflow_events.currency", + "name": "currency", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "currency", + "extensions": {} + }, + { + "id": "workflow_events.details_json", + "name": "details_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "details json", + "extensions": {} + }, + { + "id": "cms_beneficiaries", + "kind": "record", + "name": "cms_beneficiaries", + "title": "cms_beneficiaries", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "members": [ + { + "module": "domain", + "element": "cms_beneficiaries.DESYNPUF_ID" + }, + { + "module": "domain", + "element": "cms_beneficiaries.BENE_BIRTH_DT" + }, + { + "module": "domain", + "element": "cms_beneficiaries.BENE_DEATH_DT" + }, + { + "module": "domain", + "element": "cms_beneficiaries.BENE_SEX_IDENT_CD" + }, + { + "module": "domain", + "element": "cms_beneficiaries.BENE_RACE_CD" + }, + { + "module": "domain", + "element": "cms_beneficiaries.BENE_ESRD_IND" + }, + { + "module": "domain", + "element": "cms_beneficiaries.SP_STATE_CODE" + }, + { + "module": "domain", + "element": "cms_beneficiaries.BENE_COUNTY_CD" + }, + { + "module": "domain", + "element": "cms_beneficiaries.BENE_HI_CVRAGE_TOT_MONS" + }, + { + "module": "domain", + "element": "cms_beneficiaries.BENE_SMI_CVRAGE_TOT_MONS" + }, + { + "module": "domain", + "element": "cms_beneficiaries.BENE_HMO_CVRAGE_TOT_MONS" + }, + { + "module": "domain", + "element": "cms_beneficiaries.PLAN_CVRG_MOS_NUM" + }, + { + "module": "domain", + "element": "cms_beneficiaries.SP_ALZHDMTA" + }, + { + "module": "domain", + "element": "cms_beneficiaries.SP_CHF" + }, + { + "module": "domain", + "element": "cms_beneficiaries.SP_CHRNKIDN" + }, + { + "module": "domain", + "element": "cms_beneficiaries.SP_CNCR" + }, + { + "module": "domain", + "element": "cms_beneficiaries.SP_COPD" + }, + { + "module": "domain", + "element": "cms_beneficiaries.SP_DEPRESSN" + }, + { + "module": "domain", + "element": "cms_beneficiaries.SP_DIABETES" + }, + { + "module": "domain", + "element": "cms_beneficiaries.SP_ISCHMCHT" + }, + { + "module": "domain", + "element": "cms_beneficiaries.SP_OSTEOPRS" + }, + { + "module": "domain", + "element": "cms_beneficiaries.SP_RA_OA" + }, + { + "module": "domain", + "element": "cms_beneficiaries.SP_STRKETIA" + }, + { + "module": "domain", + "element": "cms_beneficiaries.MEDREIMB_IP" + }, + { + "module": "domain", + "element": "cms_beneficiaries.BENRES_IP" + }, + { + "module": "domain", + "element": "cms_beneficiaries.PPPYMT_IP" + }, + { + "module": "domain", + "element": "cms_beneficiaries.MEDREIMB_OP" + }, + { + "module": "domain", + "element": "cms_beneficiaries.BENRES_OP" + }, + { + "module": "domain", + "element": "cms_beneficiaries.PPPYMT_OP" + }, + { + "module": "domain", + "element": "cms_beneficiaries.MEDREIMB_CAR" + }, + { + "module": "domain", + "element": "cms_beneficiaries.BENRES_CAR" + }, + { + "module": "domain", + "element": "cms_beneficiaries.PPPYMT_CAR" + }, + { + "module": "domain", + "element": "cms_beneficiaries.native_record_number" + }, + { + "module": "domain", + "element": "cms_beneficiaries.native_csv_record" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "cms_beneficiaries.DESYNPUF_ID" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "cms_beneficiaries.DESYNPUF_ID", + "name": "DESYNPUF_ID", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "DESYNPUF ID", + "extensions": {} + }, + { + "id": "cms_beneficiaries.BENE_BIRTH_DT", + "name": "BENE_BIRTH_DT", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "BENE BIRTH DT", + "extensions": {} + }, + { + "id": "cms_beneficiaries.BENE_DEATH_DT", + "name": "BENE_DEATH_DT", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "BENE DEATH DT", + "extensions": {} + }, + { + "id": "cms_beneficiaries.BENE_SEX_IDENT_CD", + "name": "BENE_SEX_IDENT_CD", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "BENE SEX IDENT CD", + "extensions": {} + }, + { + "id": "cms_beneficiaries.BENE_RACE_CD", + "name": "BENE_RACE_CD", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "BENE RACE CD", + "extensions": {} + }, + { + "id": "cms_beneficiaries.BENE_ESRD_IND", + "name": "BENE_ESRD_IND", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "BENE ESRD IND", + "extensions": {} + }, + { + "id": "cms_beneficiaries.SP_STATE_CODE", + "name": "SP_STATE_CODE", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "SP STATE CODE", + "extensions": {} + }, + { + "id": "cms_beneficiaries.BENE_COUNTY_CD", + "name": "BENE_COUNTY_CD", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "BENE COUNTY CD", + "extensions": {} + }, + { + "id": "cms_beneficiaries.BENE_HI_CVRAGE_TOT_MONS", + "name": "BENE_HI_CVRAGE_TOT_MONS", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "BENE HI CVRAGE TOT MONS", + "extensions": {} + }, + { + "id": "cms_beneficiaries.BENE_SMI_CVRAGE_TOT_MONS", + "name": "BENE_SMI_CVRAGE_TOT_MONS", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "BENE SMI CVRAGE TOT MONS", + "extensions": {} + }, + { + "id": "cms_beneficiaries.BENE_HMO_CVRAGE_TOT_MONS", + "name": "BENE_HMO_CVRAGE_TOT_MONS", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "BENE HMO CVRAGE TOT MONS", + "extensions": {} + }, + { + "id": "cms_beneficiaries.PLAN_CVRG_MOS_NUM", + "name": "PLAN_CVRG_MOS_NUM", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PLAN CVRG MOS NUM", + "extensions": {} + }, + { + "id": "cms_beneficiaries.SP_ALZHDMTA", + "name": "SP_ALZHDMTA", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "SP ALZHDMTA", + "extensions": {} + }, + { + "id": "cms_beneficiaries.SP_CHF", + "name": "SP_CHF", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "SP CHF", + "extensions": {} + }, + { + "id": "cms_beneficiaries.SP_CHRNKIDN", + "name": "SP_CHRNKIDN", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "SP CHRNKIDN", + "extensions": {} + }, + { + "id": "cms_beneficiaries.SP_CNCR", + "name": "SP_CNCR", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "SP CNCR", + "extensions": {} + }, + { + "id": "cms_beneficiaries.SP_COPD", + "name": "SP_COPD", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "SP COPD", + "extensions": {} + }, + { + "id": "cms_beneficiaries.SP_DEPRESSN", + "name": "SP_DEPRESSN", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "SP DEPRESSN", + "extensions": {} + }, + { + "id": "cms_beneficiaries.SP_DIABETES", + "name": "SP_DIABETES", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "SP DIABETES", + "extensions": {} + }, + { + "id": "cms_beneficiaries.SP_ISCHMCHT", + "name": "SP_ISCHMCHT", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "SP ISCHMCHT", + "extensions": {} + }, + { + "id": "cms_beneficiaries.SP_OSTEOPRS", + "name": "SP_OSTEOPRS", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "SP OSTEOPRS", + "extensions": {} + }, + { + "id": "cms_beneficiaries.SP_RA_OA", + "name": "SP_RA_OA", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "SP RA OA", + "extensions": {} + }, + { + "id": "cms_beneficiaries.SP_STRKETIA", + "name": "SP_STRKETIA", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "SP STRKETIA", + "extensions": {} + }, + { + "id": "cms_beneficiaries.MEDREIMB_IP", + "name": "MEDREIMB_IP", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "MEDREIMB IP", + "extensions": {} + }, + { + "id": "cms_beneficiaries.BENRES_IP", + "name": "BENRES_IP", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "BENRES IP", + "extensions": {} + }, + { + "id": "cms_beneficiaries.PPPYMT_IP", + "name": "PPPYMT_IP", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PPPYMT IP", + "extensions": {} + }, + { + "id": "cms_beneficiaries.MEDREIMB_OP", + "name": "MEDREIMB_OP", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "MEDREIMB OP", + "extensions": {} + }, + { + "id": "cms_beneficiaries.BENRES_OP", + "name": "BENRES_OP", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "BENRES OP", + "extensions": {} + }, + { + "id": "cms_beneficiaries.PPPYMT_OP", + "name": "PPPYMT_OP", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PPPYMT OP", + "extensions": {} + }, + { + "id": "cms_beneficiaries.MEDREIMB_CAR", + "name": "MEDREIMB_CAR", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "MEDREIMB CAR", + "extensions": {} + }, + { + "id": "cms_beneficiaries.BENRES_CAR", + "name": "BENRES_CAR", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "BENRES CAR", + "extensions": {} + }, + { + "id": "cms_beneficiaries.PPPYMT_CAR", + "name": "PPPYMT_CAR", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PPPYMT CAR", + "extensions": {} + }, + { + "id": "cms_beneficiaries.native_record_number", + "name": "native_record_number", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native record number", + "extensions": {} + }, + { + "id": "cms_beneficiaries.native_csv_record", + "name": "native_csv_record", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native csv record", + "extensions": {} + }, + { + "id": "cms_inpatient_claims", + "kind": "record", + "name": "cms_inpatient_claims", + "title": "cms_inpatient_claims", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "members": [ + { + "module": "domain", + "element": "cms_inpatient_claims.DESYNPUF_ID" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.CLM_ID" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.SEGMENT" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.CLM_FROM_DT" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.CLM_THRU_DT" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.PRVDR_NUM" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.CLM_PMT_AMT" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.NCH_PRMRY_PYR_CLM_PD_AMT" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.AT_PHYSN_NPI" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.OP_PHYSN_NPI" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.OT_PHYSN_NPI" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.CLM_ADMSN_DT" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ADMTNG_ICD9_DGNS_CD" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.CLM_PASS_THRU_PER_DIEM_AMT" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.NCH_BENE_IP_DDCTBL_AMT" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.NCH_BENE_PTA_COINSRNC_LBLTY_AM" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.NCH_BENE_BLOOD_DDCTBL_LBLTY_AM" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.CLM_UTLZTN_DAY_CNT" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.NCH_BENE_DSCHRG_DT" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.CLM_DRG_CD" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_DGNS_CD_1" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_DGNS_CD_2" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_DGNS_CD_3" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_DGNS_CD_4" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_DGNS_CD_5" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_DGNS_CD_6" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_DGNS_CD_7" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_DGNS_CD_8" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_DGNS_CD_9" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_DGNS_CD_10" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_PRCDR_CD_1" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_PRCDR_CD_2" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_PRCDR_CD_3" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_PRCDR_CD_4" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_PRCDR_CD_5" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.ICD9_PRCDR_CD_6" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_1" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_2" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_3" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_4" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_5" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_6" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_7" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_8" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_9" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_10" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_11" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_12" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_13" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_14" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_15" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_16" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_17" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_18" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_19" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_20" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_21" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_22" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_23" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_24" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_25" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_26" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_27" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_28" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_29" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_30" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_31" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_32" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_33" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_34" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_35" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_36" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_37" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_38" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_39" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_40" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_41" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_42" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_43" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_44" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.HCPCS_CD_45" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.native_record_number" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.native_csv_record" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "cms_inpatient_claims.CLM_ID" + }, + { + "module": "domain", + "element": "cms_inpatient_claims.SEGMENT" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "cms_inpatient_claims.DESYNPUF_ID", + "name": "DESYNPUF_ID", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "DESYNPUF ID", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.CLM_ID", + "name": "CLM_ID", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "CLM ID", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.SEGMENT", + "name": "SEGMENT", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "SEGMENT", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.CLM_FROM_DT", + "name": "CLM_FROM_DT", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "CLM FROM DT", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.CLM_THRU_DT", + "name": "CLM_THRU_DT", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "CLM THRU DT", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.PRVDR_NUM", + "name": "PRVDR_NUM", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PRVDR NUM", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.CLM_PMT_AMT", + "name": "CLM_PMT_AMT", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "CLM PMT AMT", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.NCH_PRMRY_PYR_CLM_PD_AMT", + "name": "NCH_PRMRY_PYR_CLM_PD_AMT", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "NCH PRMRY PYR CLM PD AMT", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.AT_PHYSN_NPI", + "name": "AT_PHYSN_NPI", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "AT PHYSN NPI", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.OP_PHYSN_NPI", + "name": "OP_PHYSN_NPI", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "OP PHYSN NPI", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.OT_PHYSN_NPI", + "name": "OT_PHYSN_NPI", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "OT PHYSN NPI", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.CLM_ADMSN_DT", + "name": "CLM_ADMSN_DT", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "CLM ADMSN DT", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ADMTNG_ICD9_DGNS_CD", + "name": "ADMTNG_ICD9_DGNS_CD", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ADMTNG ICD9 DGNS CD", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.CLM_PASS_THRU_PER_DIEM_AMT", + "name": "CLM_PASS_THRU_PER_DIEM_AMT", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "CLM PASS THRU PER DIEM AMT", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.NCH_BENE_IP_DDCTBL_AMT", + "name": "NCH_BENE_IP_DDCTBL_AMT", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "NCH BENE IP DDCTBL AMT", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.NCH_BENE_PTA_COINSRNC_LBLTY_AM", + "name": "NCH_BENE_PTA_COINSRNC_LBLTY_AM", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "NCH BENE PTA COINSRNC LBLTY AM", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.NCH_BENE_BLOOD_DDCTBL_LBLTY_AM", + "name": "NCH_BENE_BLOOD_DDCTBL_LBLTY_AM", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "NCH BENE BLOOD DDCTBL LBLTY AM", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.CLM_UTLZTN_DAY_CNT", + "name": "CLM_UTLZTN_DAY_CNT", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "CLM UTLZTN DAY CNT", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.NCH_BENE_DSCHRG_DT", + "name": "NCH_BENE_DSCHRG_DT", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "NCH BENE DSCHRG DT", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.CLM_DRG_CD", + "name": "CLM_DRG_CD", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "CLM DRG CD", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_DGNS_CD_1", + "name": "ICD9_DGNS_CD_1", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 1", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_DGNS_CD_2", + "name": "ICD9_DGNS_CD_2", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 2", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_DGNS_CD_3", + "name": "ICD9_DGNS_CD_3", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 3", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_DGNS_CD_4", + "name": "ICD9_DGNS_CD_4", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 4", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_DGNS_CD_5", + "name": "ICD9_DGNS_CD_5", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 5", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_DGNS_CD_6", + "name": "ICD9_DGNS_CD_6", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 6", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_DGNS_CD_7", + "name": "ICD9_DGNS_CD_7", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 7", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_DGNS_CD_8", + "name": "ICD9_DGNS_CD_8", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 8", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_DGNS_CD_9", + "name": "ICD9_DGNS_CD_9", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 9", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_DGNS_CD_10", + "name": "ICD9_DGNS_CD_10", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 10", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_PRCDR_CD_1", + "name": "ICD9_PRCDR_CD_1", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 PRCDR CD 1", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_PRCDR_CD_2", + "name": "ICD9_PRCDR_CD_2", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 PRCDR CD 2", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_PRCDR_CD_3", + "name": "ICD9_PRCDR_CD_3", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 PRCDR CD 3", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_PRCDR_CD_4", + "name": "ICD9_PRCDR_CD_4", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 PRCDR CD 4", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_PRCDR_CD_5", + "name": "ICD9_PRCDR_CD_5", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 PRCDR CD 5", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.ICD9_PRCDR_CD_6", + "name": "ICD9_PRCDR_CD_6", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 PRCDR CD 6", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_1", + "name": "HCPCS_CD_1", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 1", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_2", + "name": "HCPCS_CD_2", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 2", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_3", + "name": "HCPCS_CD_3", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 3", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_4", + "name": "HCPCS_CD_4", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 4", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_5", + "name": "HCPCS_CD_5", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 5", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_6", + "name": "HCPCS_CD_6", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 6", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_7", + "name": "HCPCS_CD_7", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 7", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_8", + "name": "HCPCS_CD_8", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 8", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_9", + "name": "HCPCS_CD_9", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 9", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_10", + "name": "HCPCS_CD_10", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 10", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_11", + "name": "HCPCS_CD_11", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 11", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_12", + "name": "HCPCS_CD_12", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 12", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_13", + "name": "HCPCS_CD_13", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 13", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_14", + "name": "HCPCS_CD_14", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 14", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_15", + "name": "HCPCS_CD_15", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 15", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_16", + "name": "HCPCS_CD_16", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 16", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_17", + "name": "HCPCS_CD_17", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 17", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_18", + "name": "HCPCS_CD_18", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 18", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_19", + "name": "HCPCS_CD_19", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 19", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_20", + "name": "HCPCS_CD_20", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 20", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_21", + "name": "HCPCS_CD_21", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 21", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_22", + "name": "HCPCS_CD_22", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 22", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_23", + "name": "HCPCS_CD_23", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 23", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_24", + "name": "HCPCS_CD_24", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 24", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_25", + "name": "HCPCS_CD_25", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 25", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_26", + "name": "HCPCS_CD_26", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 26", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_27", + "name": "HCPCS_CD_27", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 27", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_28", + "name": "HCPCS_CD_28", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 28", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_29", + "name": "HCPCS_CD_29", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 29", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_30", + "name": "HCPCS_CD_30", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 30", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_31", + "name": "HCPCS_CD_31", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 31", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_32", + "name": "HCPCS_CD_32", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 32", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_33", + "name": "HCPCS_CD_33", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 33", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_34", + "name": "HCPCS_CD_34", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 34", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_35", + "name": "HCPCS_CD_35", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 35", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_36", + "name": "HCPCS_CD_36", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 36", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_37", + "name": "HCPCS_CD_37", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 37", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_38", + "name": "HCPCS_CD_38", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 38", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_39", + "name": "HCPCS_CD_39", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 39", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_40", + "name": "HCPCS_CD_40", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 40", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_41", + "name": "HCPCS_CD_41", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 41", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_42", + "name": "HCPCS_CD_42", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 42", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_43", + "name": "HCPCS_CD_43", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 43", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_44", + "name": "HCPCS_CD_44", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 44", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.HCPCS_CD_45", + "name": "HCPCS_CD_45", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 45", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.native_record_number", + "name": "native_record_number", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native record number", + "extensions": {} + }, + { + "id": "cms_inpatient_claims.native_csv_record", + "name": "native_csv_record", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native csv record", + "extensions": {} + }, + { + "id": "cms_carrier_claims", + "kind": "record", + "name": "cms_carrier_claims", + "title": "cms_carrier_claims", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "members": [ + { + "module": "domain", + "element": "cms_carrier_claims.DESYNPUF_ID" + }, + { + "module": "domain", + "element": "cms_carrier_claims.CLM_ID" + }, + { + "module": "domain", + "element": "cms_carrier_claims.CLM_FROM_DT" + }, + { + "module": "domain", + "element": "cms_carrier_claims.CLM_THRU_DT" + }, + { + "module": "domain", + "element": "cms_carrier_claims.ICD9_DGNS_CD_1" + }, + { + "module": "domain", + "element": "cms_carrier_claims.ICD9_DGNS_CD_2" + }, + { + "module": "domain", + "element": "cms_carrier_claims.ICD9_DGNS_CD_3" + }, + { + "module": "domain", + "element": "cms_carrier_claims.ICD9_DGNS_CD_4" + }, + { + "module": "domain", + "element": "cms_carrier_claims.ICD9_DGNS_CD_5" + }, + { + "module": "domain", + "element": "cms_carrier_claims.ICD9_DGNS_CD_6" + }, + { + "module": "domain", + "element": "cms_carrier_claims.ICD9_DGNS_CD_7" + }, + { + "module": "domain", + "element": "cms_carrier_claims.ICD9_DGNS_CD_8" + }, + { + "module": "domain", + "element": "cms_carrier_claims.PRF_PHYSN_NPI_1" + }, + { + "module": "domain", + "element": "cms_carrier_claims.PRF_PHYSN_NPI_2" + }, + { + "module": "domain", + "element": "cms_carrier_claims.PRF_PHYSN_NPI_3" + }, + { + "module": "domain", + "element": "cms_carrier_claims.PRF_PHYSN_NPI_4" + }, + { + "module": "domain", + "element": "cms_carrier_claims.PRF_PHYSN_NPI_5" + }, + { + "module": "domain", + "element": "cms_carrier_claims.PRF_PHYSN_NPI_6" + }, + { + "module": "domain", + "element": "cms_carrier_claims.PRF_PHYSN_NPI_7" + }, + { + "module": "domain", + "element": "cms_carrier_claims.PRF_PHYSN_NPI_8" + }, + { + "module": "domain", + "element": "cms_carrier_claims.PRF_PHYSN_NPI_9" + }, + { + "module": "domain", + "element": "cms_carrier_claims.PRF_PHYSN_NPI_10" + }, + { + "module": "domain", + "element": "cms_carrier_claims.PRF_PHYSN_NPI_11" + }, + { + "module": "domain", + "element": "cms_carrier_claims.PRF_PHYSN_NPI_12" + }, + { + "module": "domain", + "element": "cms_carrier_claims.PRF_PHYSN_NPI_13" + }, + { + "module": "domain", + "element": "cms_carrier_claims.TAX_NUM_1" + }, + { + "module": "domain", + "element": "cms_carrier_claims.TAX_NUM_2" + }, + { + "module": "domain", + "element": "cms_carrier_claims.TAX_NUM_3" + }, + { + "module": "domain", + "element": "cms_carrier_claims.TAX_NUM_4" + }, + { + "module": "domain", + "element": "cms_carrier_claims.TAX_NUM_5" + }, + { + "module": "domain", + "element": "cms_carrier_claims.TAX_NUM_6" + }, + { + "module": "domain", + "element": "cms_carrier_claims.TAX_NUM_7" + }, + { + "module": "domain", + "element": "cms_carrier_claims.TAX_NUM_8" + }, + { + "module": "domain", + "element": "cms_carrier_claims.TAX_NUM_9" + }, + { + "module": "domain", + "element": "cms_carrier_claims.TAX_NUM_10" + }, + { + "module": "domain", + "element": "cms_carrier_claims.TAX_NUM_11" + }, + { + "module": "domain", + "element": "cms_carrier_claims.TAX_NUM_12" + }, + { + "module": "domain", + "element": "cms_carrier_claims.TAX_NUM_13" + }, + { + "module": "domain", + "element": "cms_carrier_claims.HCPCS_CD_1" + }, + { + "module": "domain", + "element": "cms_carrier_claims.HCPCS_CD_2" + }, + { + "module": "domain", + "element": "cms_carrier_claims.HCPCS_CD_3" + }, + { + "module": "domain", + "element": "cms_carrier_claims.HCPCS_CD_4" + }, + { + "module": "domain", + "element": "cms_carrier_claims.HCPCS_CD_5" + }, + { + "module": "domain", + "element": "cms_carrier_claims.HCPCS_CD_6" + }, + { + "module": "domain", + "element": "cms_carrier_claims.HCPCS_CD_7" + }, + { + "module": "domain", + "element": "cms_carrier_claims.HCPCS_CD_8" + }, + { + "module": "domain", + "element": "cms_carrier_claims.HCPCS_CD_9" + }, + { + "module": "domain", + "element": "cms_carrier_claims.HCPCS_CD_10" + }, + { + "module": "domain", + "element": "cms_carrier_claims.HCPCS_CD_11" + }, + { + "module": "domain", + "element": "cms_carrier_claims.HCPCS_CD_12" + }, + { + "module": "domain", + "element": "cms_carrier_claims.HCPCS_CD_13" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_NCH_PMT_AMT_1" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_NCH_PMT_AMT_2" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_NCH_PMT_AMT_3" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_NCH_PMT_AMT_4" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_NCH_PMT_AMT_5" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_NCH_PMT_AMT_6" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_NCH_PMT_AMT_7" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_NCH_PMT_AMT_8" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_NCH_PMT_AMT_9" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_NCH_PMT_AMT_10" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_NCH_PMT_AMT_11" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_NCH_PMT_AMT_12" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_NCH_PMT_AMT_13" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_1" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_2" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_3" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_4" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_5" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_6" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_7" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_8" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_9" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_10" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_11" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_12" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_13" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_1" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_2" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_3" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_4" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_5" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_6" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_7" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_8" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_9" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_10" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_11" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_12" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_13" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_COINSRNC_AMT_1" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_COINSRNC_AMT_2" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_COINSRNC_AMT_3" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_COINSRNC_AMT_4" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_COINSRNC_AMT_5" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_COINSRNC_AMT_6" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_COINSRNC_AMT_7" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_COINSRNC_AMT_8" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_COINSRNC_AMT_9" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_COINSRNC_AMT_10" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_COINSRNC_AMT_11" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_COINSRNC_AMT_12" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_COINSRNC_AMT_13" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_1" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_2" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_3" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_4" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_5" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_6" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_7" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_8" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_9" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_10" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_11" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_12" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_13" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_PRCSG_IND_CD_1" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_PRCSG_IND_CD_2" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_PRCSG_IND_CD_3" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_PRCSG_IND_CD_4" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_PRCSG_IND_CD_5" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_PRCSG_IND_CD_6" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_PRCSG_IND_CD_7" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_PRCSG_IND_CD_8" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_PRCSG_IND_CD_9" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_PRCSG_IND_CD_10" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_PRCSG_IND_CD_11" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_PRCSG_IND_CD_12" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_PRCSG_IND_CD_13" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ICD9_DGNS_CD_1" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ICD9_DGNS_CD_2" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ICD9_DGNS_CD_3" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ICD9_DGNS_CD_4" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ICD9_DGNS_CD_5" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ICD9_DGNS_CD_6" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ICD9_DGNS_CD_7" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ICD9_DGNS_CD_8" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ICD9_DGNS_CD_9" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ICD9_DGNS_CD_10" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ICD9_DGNS_CD_11" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ICD9_DGNS_CD_12" + }, + { + "module": "domain", + "element": "cms_carrier_claims.LINE_ICD9_DGNS_CD_13" + }, + { + "module": "domain", + "element": "cms_carrier_claims.native_record_number" + }, + { + "module": "domain", + "element": "cms_carrier_claims.native_csv_record" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "cms_carrier_claims.CLM_ID" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "cms_carrier_claims.DESYNPUF_ID", + "name": "DESYNPUF_ID", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "DESYNPUF ID", + "extensions": {} + }, + { + "id": "cms_carrier_claims.CLM_ID", + "name": "CLM_ID", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "CLM ID", + "extensions": {} + }, + { + "id": "cms_carrier_claims.CLM_FROM_DT", + "name": "CLM_FROM_DT", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "CLM FROM DT", + "extensions": {} + }, + { + "id": "cms_carrier_claims.CLM_THRU_DT", + "name": "CLM_THRU_DT", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "CLM THRU DT", + "extensions": {} + }, + { + "id": "cms_carrier_claims.ICD9_DGNS_CD_1", + "name": "ICD9_DGNS_CD_1", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 1", + "extensions": {} + }, + { + "id": "cms_carrier_claims.ICD9_DGNS_CD_2", + "name": "ICD9_DGNS_CD_2", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 2", + "extensions": {} + }, + { + "id": "cms_carrier_claims.ICD9_DGNS_CD_3", + "name": "ICD9_DGNS_CD_3", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 3", + "extensions": {} + }, + { + "id": "cms_carrier_claims.ICD9_DGNS_CD_4", + "name": "ICD9_DGNS_CD_4", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 4", + "extensions": {} + }, + { + "id": "cms_carrier_claims.ICD9_DGNS_CD_5", + "name": "ICD9_DGNS_CD_5", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 5", + "extensions": {} + }, + { + "id": "cms_carrier_claims.ICD9_DGNS_CD_6", + "name": "ICD9_DGNS_CD_6", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 6", + "extensions": {} + }, + { + "id": "cms_carrier_claims.ICD9_DGNS_CD_7", + "name": "ICD9_DGNS_CD_7", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 7", + "extensions": {} + }, + { + "id": "cms_carrier_claims.ICD9_DGNS_CD_8", + "name": "ICD9_DGNS_CD_8", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "ICD9 DGNS CD 8", + "extensions": {} + }, + { + "id": "cms_carrier_claims.PRF_PHYSN_NPI_1", + "name": "PRF_PHYSN_NPI_1", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PRF PHYSN NPI 1", + "extensions": {} + }, + { + "id": "cms_carrier_claims.PRF_PHYSN_NPI_2", + "name": "PRF_PHYSN_NPI_2", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PRF PHYSN NPI 2", + "extensions": {} + }, + { + "id": "cms_carrier_claims.PRF_PHYSN_NPI_3", + "name": "PRF_PHYSN_NPI_3", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PRF PHYSN NPI 3", + "extensions": {} + }, + { + "id": "cms_carrier_claims.PRF_PHYSN_NPI_4", + "name": "PRF_PHYSN_NPI_4", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PRF PHYSN NPI 4", + "extensions": {} + }, + { + "id": "cms_carrier_claims.PRF_PHYSN_NPI_5", + "name": "PRF_PHYSN_NPI_5", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PRF PHYSN NPI 5", + "extensions": {} + }, + { + "id": "cms_carrier_claims.PRF_PHYSN_NPI_6", + "name": "PRF_PHYSN_NPI_6", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PRF PHYSN NPI 6", + "extensions": {} + }, + { + "id": "cms_carrier_claims.PRF_PHYSN_NPI_7", + "name": "PRF_PHYSN_NPI_7", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PRF PHYSN NPI 7", + "extensions": {} + }, + { + "id": "cms_carrier_claims.PRF_PHYSN_NPI_8", + "name": "PRF_PHYSN_NPI_8", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PRF PHYSN NPI 8", + "extensions": {} + }, + { + "id": "cms_carrier_claims.PRF_PHYSN_NPI_9", + "name": "PRF_PHYSN_NPI_9", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PRF PHYSN NPI 9", + "extensions": {} + }, + { + "id": "cms_carrier_claims.PRF_PHYSN_NPI_10", + "name": "PRF_PHYSN_NPI_10", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PRF PHYSN NPI 10", + "extensions": {} + }, + { + "id": "cms_carrier_claims.PRF_PHYSN_NPI_11", + "name": "PRF_PHYSN_NPI_11", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PRF PHYSN NPI 11", + "extensions": {} + }, + { + "id": "cms_carrier_claims.PRF_PHYSN_NPI_12", + "name": "PRF_PHYSN_NPI_12", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PRF PHYSN NPI 12", + "extensions": {} + }, + { + "id": "cms_carrier_claims.PRF_PHYSN_NPI_13", + "name": "PRF_PHYSN_NPI_13", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "PRF PHYSN NPI 13", + "extensions": {} + }, + { + "id": "cms_carrier_claims.TAX_NUM_1", + "name": "TAX_NUM_1", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "TAX NUM 1", + "extensions": {} + }, + { + "id": "cms_carrier_claims.TAX_NUM_2", + "name": "TAX_NUM_2", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "TAX NUM 2", + "extensions": {} + }, + { + "id": "cms_carrier_claims.TAX_NUM_3", + "name": "TAX_NUM_3", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "TAX NUM 3", + "extensions": {} + }, + { + "id": "cms_carrier_claims.TAX_NUM_4", + "name": "TAX_NUM_4", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "TAX NUM 4", + "extensions": {} + }, + { + "id": "cms_carrier_claims.TAX_NUM_5", + "name": "TAX_NUM_5", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "TAX NUM 5", + "extensions": {} + }, + { + "id": "cms_carrier_claims.TAX_NUM_6", + "name": "TAX_NUM_6", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "TAX NUM 6", + "extensions": {} + }, + { + "id": "cms_carrier_claims.TAX_NUM_7", + "name": "TAX_NUM_7", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "TAX NUM 7", + "extensions": {} + }, + { + "id": "cms_carrier_claims.TAX_NUM_8", + "name": "TAX_NUM_8", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "TAX NUM 8", + "extensions": {} + }, + { + "id": "cms_carrier_claims.TAX_NUM_9", + "name": "TAX_NUM_9", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "TAX NUM 9", + "extensions": {} + }, + { + "id": "cms_carrier_claims.TAX_NUM_10", + "name": "TAX_NUM_10", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "TAX NUM 10", + "extensions": {} + }, + { + "id": "cms_carrier_claims.TAX_NUM_11", + "name": "TAX_NUM_11", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "TAX NUM 11", + "extensions": {} + }, + { + "id": "cms_carrier_claims.TAX_NUM_12", + "name": "TAX_NUM_12", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "TAX NUM 12", + "extensions": {} + }, + { + "id": "cms_carrier_claims.TAX_NUM_13", + "name": "TAX_NUM_13", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "TAX NUM 13", + "extensions": {} + }, + { + "id": "cms_carrier_claims.HCPCS_CD_1", + "name": "HCPCS_CD_1", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 1", + "extensions": {} + }, + { + "id": "cms_carrier_claims.HCPCS_CD_2", + "name": "HCPCS_CD_2", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 2", + "extensions": {} + }, + { + "id": "cms_carrier_claims.HCPCS_CD_3", + "name": "HCPCS_CD_3", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 3", + "extensions": {} + }, + { + "id": "cms_carrier_claims.HCPCS_CD_4", + "name": "HCPCS_CD_4", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 4", + "extensions": {} + }, + { + "id": "cms_carrier_claims.HCPCS_CD_5", + "name": "HCPCS_CD_5", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 5", + "extensions": {} + }, + { + "id": "cms_carrier_claims.HCPCS_CD_6", + "name": "HCPCS_CD_6", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 6", + "extensions": {} + }, + { + "id": "cms_carrier_claims.HCPCS_CD_7", + "name": "HCPCS_CD_7", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 7", + "extensions": {} + }, + { + "id": "cms_carrier_claims.HCPCS_CD_8", + "name": "HCPCS_CD_8", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 8", + "extensions": {} + }, + { + "id": "cms_carrier_claims.HCPCS_CD_9", + "name": "HCPCS_CD_9", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 9", + "extensions": {} + }, + { + "id": "cms_carrier_claims.HCPCS_CD_10", + "name": "HCPCS_CD_10", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 10", + "extensions": {} + }, + { + "id": "cms_carrier_claims.HCPCS_CD_11", + "name": "HCPCS_CD_11", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 11", + "extensions": {} + }, + { + "id": "cms_carrier_claims.HCPCS_CD_12", + "name": "HCPCS_CD_12", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 12", + "extensions": {} + }, + { + "id": "cms_carrier_claims.HCPCS_CD_13", + "name": "HCPCS_CD_13", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "HCPCS CD 13", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_NCH_PMT_AMT_1", + "name": "LINE_NCH_PMT_AMT_1", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE NCH PMT AMT 1", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_NCH_PMT_AMT_2", + "name": "LINE_NCH_PMT_AMT_2", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE NCH PMT AMT 2", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_NCH_PMT_AMT_3", + "name": "LINE_NCH_PMT_AMT_3", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE NCH PMT AMT 3", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_NCH_PMT_AMT_4", + "name": "LINE_NCH_PMT_AMT_4", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE NCH PMT AMT 4", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_NCH_PMT_AMT_5", + "name": "LINE_NCH_PMT_AMT_5", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE NCH PMT AMT 5", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_NCH_PMT_AMT_6", + "name": "LINE_NCH_PMT_AMT_6", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE NCH PMT AMT 6", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_NCH_PMT_AMT_7", + "name": "LINE_NCH_PMT_AMT_7", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE NCH PMT AMT 7", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_NCH_PMT_AMT_8", + "name": "LINE_NCH_PMT_AMT_8", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE NCH PMT AMT 8", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_NCH_PMT_AMT_9", + "name": "LINE_NCH_PMT_AMT_9", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE NCH PMT AMT 9", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_NCH_PMT_AMT_10", + "name": "LINE_NCH_PMT_AMT_10", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE NCH PMT AMT 10", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_NCH_PMT_AMT_11", + "name": "LINE_NCH_PMT_AMT_11", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE NCH PMT AMT 11", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_NCH_PMT_AMT_12", + "name": "LINE_NCH_PMT_AMT_12", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE NCH PMT AMT 12", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_NCH_PMT_AMT_13", + "name": "LINE_NCH_PMT_AMT_13", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE NCH PMT AMT 13", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_1", + "name": "LINE_BENE_PTB_DDCTBL_AMT_1", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PTB DDCTBL AMT 1", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_2", + "name": "LINE_BENE_PTB_DDCTBL_AMT_2", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PTB DDCTBL AMT 2", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_3", + "name": "LINE_BENE_PTB_DDCTBL_AMT_3", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PTB DDCTBL AMT 3", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_4", + "name": "LINE_BENE_PTB_DDCTBL_AMT_4", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PTB DDCTBL AMT 4", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_5", + "name": "LINE_BENE_PTB_DDCTBL_AMT_5", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PTB DDCTBL AMT 5", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_6", + "name": "LINE_BENE_PTB_DDCTBL_AMT_6", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PTB DDCTBL AMT 6", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_7", + "name": "LINE_BENE_PTB_DDCTBL_AMT_7", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PTB DDCTBL AMT 7", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_8", + "name": "LINE_BENE_PTB_DDCTBL_AMT_8", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PTB DDCTBL AMT 8", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_9", + "name": "LINE_BENE_PTB_DDCTBL_AMT_9", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PTB DDCTBL AMT 9", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_10", + "name": "LINE_BENE_PTB_DDCTBL_AMT_10", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PTB DDCTBL AMT 10", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_11", + "name": "LINE_BENE_PTB_DDCTBL_AMT_11", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PTB DDCTBL AMT 11", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_12", + "name": "LINE_BENE_PTB_DDCTBL_AMT_12", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PTB DDCTBL AMT 12", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PTB_DDCTBL_AMT_13", + "name": "LINE_BENE_PTB_DDCTBL_AMT_13", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PTB DDCTBL AMT 13", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_1", + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_1", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PRMRY PYR PD AMT 1", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_2", + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_2", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PRMRY PYR PD AMT 2", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_3", + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_3", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PRMRY PYR PD AMT 3", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_4", + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_4", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PRMRY PYR PD AMT 4", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_5", + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_5", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PRMRY PYR PD AMT 5", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_6", + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_6", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PRMRY PYR PD AMT 6", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_7", + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_7", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PRMRY PYR PD AMT 7", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_8", + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_8", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PRMRY PYR PD AMT 8", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_9", + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_9", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PRMRY PYR PD AMT 9", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_10", + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_10", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PRMRY PYR PD AMT 10", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_11", + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_11", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PRMRY PYR PD AMT 11", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_12", + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_12", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PRMRY PYR PD AMT 12", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_BENE_PRMRY_PYR_PD_AMT_13", + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_13", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE BENE PRMRY PYR PD AMT 13", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_COINSRNC_AMT_1", + "name": "LINE_COINSRNC_AMT_1", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE COINSRNC AMT 1", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_COINSRNC_AMT_2", + "name": "LINE_COINSRNC_AMT_2", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE COINSRNC AMT 2", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_COINSRNC_AMT_3", + "name": "LINE_COINSRNC_AMT_3", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE COINSRNC AMT 3", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_COINSRNC_AMT_4", + "name": "LINE_COINSRNC_AMT_4", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE COINSRNC AMT 4", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_COINSRNC_AMT_5", + "name": "LINE_COINSRNC_AMT_5", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE COINSRNC AMT 5", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_COINSRNC_AMT_6", + "name": "LINE_COINSRNC_AMT_6", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE COINSRNC AMT 6", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_COINSRNC_AMT_7", + "name": "LINE_COINSRNC_AMT_7", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE COINSRNC AMT 7", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_COINSRNC_AMT_8", + "name": "LINE_COINSRNC_AMT_8", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE COINSRNC AMT 8", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_COINSRNC_AMT_9", + "name": "LINE_COINSRNC_AMT_9", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE COINSRNC AMT 9", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_COINSRNC_AMT_10", + "name": "LINE_COINSRNC_AMT_10", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE COINSRNC AMT 10", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_COINSRNC_AMT_11", + "name": "LINE_COINSRNC_AMT_11", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE COINSRNC AMT 11", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_COINSRNC_AMT_12", + "name": "LINE_COINSRNC_AMT_12", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE COINSRNC AMT 12", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_COINSRNC_AMT_13", + "name": "LINE_COINSRNC_AMT_13", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE COINSRNC AMT 13", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_1", + "name": "LINE_ALOWD_CHRG_AMT_1", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ALOWD CHRG AMT 1", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_2", + "name": "LINE_ALOWD_CHRG_AMT_2", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ALOWD CHRG AMT 2", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_3", + "name": "LINE_ALOWD_CHRG_AMT_3", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ALOWD CHRG AMT 3", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_4", + "name": "LINE_ALOWD_CHRG_AMT_4", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ALOWD CHRG AMT 4", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_5", + "name": "LINE_ALOWD_CHRG_AMT_5", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ALOWD CHRG AMT 5", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_6", + "name": "LINE_ALOWD_CHRG_AMT_6", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ALOWD CHRG AMT 6", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_7", + "name": "LINE_ALOWD_CHRG_AMT_7", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ALOWD CHRG AMT 7", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_8", + "name": "LINE_ALOWD_CHRG_AMT_8", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ALOWD CHRG AMT 8", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_9", + "name": "LINE_ALOWD_CHRG_AMT_9", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ALOWD CHRG AMT 9", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_10", + "name": "LINE_ALOWD_CHRG_AMT_10", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ALOWD CHRG AMT 10", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_11", + "name": "LINE_ALOWD_CHRG_AMT_11", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ALOWD CHRG AMT 11", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_12", + "name": "LINE_ALOWD_CHRG_AMT_12", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ALOWD CHRG AMT 12", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ALOWD_CHRG_AMT_13", + "name": "LINE_ALOWD_CHRG_AMT_13", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ALOWD CHRG AMT 13", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_PRCSG_IND_CD_1", + "name": "LINE_PRCSG_IND_CD_1", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE PRCSG IND CD 1", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_PRCSG_IND_CD_2", + "name": "LINE_PRCSG_IND_CD_2", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE PRCSG IND CD 2", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_PRCSG_IND_CD_3", + "name": "LINE_PRCSG_IND_CD_3", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE PRCSG IND CD 3", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_PRCSG_IND_CD_4", + "name": "LINE_PRCSG_IND_CD_4", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE PRCSG IND CD 4", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_PRCSG_IND_CD_5", + "name": "LINE_PRCSG_IND_CD_5", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE PRCSG IND CD 5", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_PRCSG_IND_CD_6", + "name": "LINE_PRCSG_IND_CD_6", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE PRCSG IND CD 6", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_PRCSG_IND_CD_7", + "name": "LINE_PRCSG_IND_CD_7", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE PRCSG IND CD 7", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_PRCSG_IND_CD_8", + "name": "LINE_PRCSG_IND_CD_8", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE PRCSG IND CD 8", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_PRCSG_IND_CD_9", + "name": "LINE_PRCSG_IND_CD_9", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE PRCSG IND CD 9", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_PRCSG_IND_CD_10", + "name": "LINE_PRCSG_IND_CD_10", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE PRCSG IND CD 10", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_PRCSG_IND_CD_11", + "name": "LINE_PRCSG_IND_CD_11", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE PRCSG IND CD 11", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_PRCSG_IND_CD_12", + "name": "LINE_PRCSG_IND_CD_12", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE PRCSG IND CD 12", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_PRCSG_IND_CD_13", + "name": "LINE_PRCSG_IND_CD_13", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE PRCSG IND CD 13", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ICD9_DGNS_CD_1", + "name": "LINE_ICD9_DGNS_CD_1", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ICD9 DGNS CD 1", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ICD9_DGNS_CD_2", + "name": "LINE_ICD9_DGNS_CD_2", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ICD9 DGNS CD 2", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ICD9_DGNS_CD_3", + "name": "LINE_ICD9_DGNS_CD_3", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ICD9 DGNS CD 3", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ICD9_DGNS_CD_4", + "name": "LINE_ICD9_DGNS_CD_4", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ICD9 DGNS CD 4", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ICD9_DGNS_CD_5", + "name": "LINE_ICD9_DGNS_CD_5", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ICD9 DGNS CD 5", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ICD9_DGNS_CD_6", + "name": "LINE_ICD9_DGNS_CD_6", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ICD9 DGNS CD 6", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ICD9_DGNS_CD_7", + "name": "LINE_ICD9_DGNS_CD_7", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ICD9 DGNS CD 7", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ICD9_DGNS_CD_8", + "name": "LINE_ICD9_DGNS_CD_8", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ICD9 DGNS CD 8", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ICD9_DGNS_CD_9", + "name": "LINE_ICD9_DGNS_CD_9", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ICD9 DGNS CD 9", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ICD9_DGNS_CD_10", + "name": "LINE_ICD9_DGNS_CD_10", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ICD9 DGNS CD 10", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ICD9_DGNS_CD_11", + "name": "LINE_ICD9_DGNS_CD_11", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ICD9 DGNS CD 11", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ICD9_DGNS_CD_12", + "name": "LINE_ICD9_DGNS_CD_12", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ICD9 DGNS CD 12", + "extensions": {} + }, + { + "id": "cms_carrier_claims.LINE_ICD9_DGNS_CD_13", + "name": "LINE_ICD9_DGNS_CD_13", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "LINE ICD9 DGNS CD 13", + "extensions": {} + }, + { + "id": "cms_carrier_claims.native_record_number", + "name": "native_record_number", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native record number", + "extensions": {} + }, + { + "id": "cms_carrier_claims.native_csv_record", + "name": "native_csv_record", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native csv record", + "extensions": {} + } + ], + "relationships": [ + { + "id": "coverage.resource_key", + "name": "coverage.resource_key", + "source": [ + { + "module": "domain", + "element": "coverage" + } + ], + "target": [ + { + "module": "domain", + "element": "resources", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 1, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + }, + { + "id": "eligibility.resource_key", + "name": "eligibility.resource_key", + "source": [ + { + "module": "domain", + "element": "eligibility" + } + ], + "target": [ + { + "module": "domain", + "element": "resources", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 1, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + }, + { + "id": "claims.resource_key", + "name": "claims.resource_key", + "source": [ + { + "module": "domain", + "element": "claims" + } + ], + "target": [ + { + "module": "domain", + "element": "resources", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 1, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + }, + { + "id": "claim_lines.resource_key", + "name": "claim_lines.resource_key", + "source": [ + { + "module": "domain", + "element": "claim_lines" + } + ], + "target": [ + { + "module": "domain", + "element": "resources", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 1, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + }, + { + "id": "claim_lines.parent_line_key", + "name": "claim_lines.parent_line_key", + "source": [ + { + "module": "domain", + "element": "claim_lines" + } + ], + "target": [ + { + "module": "domain", + "element": "claim_lines", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 0, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + }, + { + "id": "adjudications.resource_key", + "name": "adjudications.resource_key", + "source": [ + { + "module": "domain", + "element": "adjudications" + } + ], + "target": [ + { + "module": "domain", + "element": "resources", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 1, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + }, + { + "id": "adjudications.line_key", + "name": "adjudications.line_key", + "source": [ + { + "module": "domain", + "element": "adjudications" + } + ], + "target": [ + { + "module": "domain", + "element": "claim_lines", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 1, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + }, + { + "id": "payments.resource_key", + "name": "payments.resource_key", + "source": [ + { + "module": "domain", + "element": "payments" + } + ], + "target": [ + { + "module": "domain", + "element": "resources", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 1, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + }, + { + "id": "plans.resource_key", + "name": "plans.resource_key", + "source": [ + { + "module": "domain", + "element": "plans" + } + ], + "target": [ + { + "module": "domain", + "element": "resources", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 1, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + }, + { + "id": "enrollments.resource_key", + "name": "enrollments.resource_key", + "source": [ + { + "module": "domain", + "element": "enrollments" + } + ], + "target": [ + { + "module": "domain", + "element": "resources", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 1, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + }, + { + "id": "resource_references.resource_key", + "name": "resource_references.resource_key", + "source": [ + { + "module": "domain", + "element": "resource_references" + } + ], + "target": [ + { + "module": "domain", + "element": "resources", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 1, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + }, + { + "id": "resource_references.target_key", + "name": "resource_references.target_key", + "source": [ + { + "module": "domain", + "element": "resource_references" + } + ], + "target": [ + { + "module": "domain", + "element": "resources", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 0, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + }, + { + "id": "coded_values.resource_key", + "name": "coded_values.resource_key", + "source": [ + { + "module": "domain", + "element": "coded_values" + } + ], + "target": [ + { + "module": "domain", + "element": "resources", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 1, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + }, + { + "id": "cms_inpatient_claims.DESYNPUF_ID", + "name": "cms_inpatient_claims.DESYNPUF_ID", + "source": [ + { + "module": "domain", + "element": "cms_inpatient_claims" + } + ], + "target": [ + { + "module": "domain", + "element": "cms_beneficiaries", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 1, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + }, + { + "id": "cms_carrier_claims.DESYNPUF_ID", + "name": "cms_carrier_claims.DESYNPUF_ID", + "source": [ + { + "module": "domain", + "element": "cms_carrier_claims" + } + ], + "target": [ + { + "module": "domain", + "element": "cms_beneficiaries", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 1, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + } + ] + } + ] +} diff --git a/spec/domain-packs/medical-carrier/pack.json b/spec/domain-packs/medical-carrier/pack.json index b3ec664b1..89b610efd 100644 --- a/spec/domain-packs/medical-carrier/pack.json +++ b/spec/domain-packs/medical-carrier/pack.json @@ -1,6 +1,89 @@ { "id": "medical-carrier", - "version": "1.0.0", + "version": "1.1.0", + "family": { + "id": "medical", + "version": "1.1.0", + "label": "Carrier: eligibility, claims and payments" + }, + "execution_profile": { + "version": "1.0.0", + "targets": { + "tabular": [ + "resources", + "coverage", + "eligibility", + "claims", + "claim_lines", + "adjudications", + "payments", + "plans", + "enrollments", + "resource_references", + "coded_values", + "workflow_events", + "cms_beneficiaries", + "cms_inpatient_claims", + "cms_carrier_claims" + ], + "graph": [ + "ontology" + ] + }, + "mode": "fixed", + "include_sources": [ + "hl7-claim", + "hl7-claimresponse", + "hl7-coverage", + "hl7-eligibility-request", + "hl7-eligibility-response", + "hl7-enrollment", + "hl7-eob", + "hl7-insuranceplan", + "hl7-payment", + "supplement-claim-authorization-approved", + "supplement-claim-authorization-denied", + "supplement-claim-paid-denied", + "supplement-coverage-active", + "supplement-coverage-inactive", + "supplement-eligibility-negative-request", + "supplement-eligibility-negative-response", + "supplement-eligibility-positive-request", + "supplement-eligibility-positive-response", + "supplement-enrollment-request", + "supplement-enrollment-response", + "supplement-eob", + "supplement-patient", + "supplement-payer", + "supplement-payment", + "supplement-plan", + "supplement-response-authorization-approved", + "supplement-response-authorization-denied", + "supplement-response-paid-denied", + "workflow", + "cms_beneficiaries", + "cms_inpatient", + "cms_carrier", + "cms_selection", + "notices", + "csv_resources", + "csv_coverage", + "csv_eligibility", + "csv_claims", + "csv_claim_lines", + "csv_adjudications", + "csv_payments", + "csv_plans", + "csv_enrollments", + "csv_resource_references", + "csv_coded_values", + "csv_workflow_events", + "csv_cms_beneficiaries", + "csv_cms_inpatient_claims", + "csv_cms_carrier_claims" + ], + "qualification": "Fixed source-qualified sample rows and schema-only ontology. No data generation, clinical conformance or graph-storage execution claim." + }, "description": "Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.", "domain_types": { "source_qualified_identity": { @@ -70,6 +153,26 @@ "id": "workflow_events", "format": "tablespec", "reference": "umf/workflow_events.json" + }, + { + "id": "cms_beneficiaries", + "format": "tablespec", + "reference": "umf/cms_beneficiaries.json" + }, + { + "id": "cms_inpatient_claims", + "format": "tablespec", + "reference": "umf/cms_inpatient_claims.json" + }, + { + "id": "cms_carrier_claims", + "format": "tablespec", + "reference": "umf/cms_carrier_claims.json" + }, + { + "id": "ontology", + "format": "umf", + "reference": "ontology.json" } ], "sources": { @@ -700,6 +803,94 @@ "publisher": "Centers for Medicare & Medicaid Services" } }, + "cms_beneficiaries": { + "kind": "external", + "data_kind": "fabricated", + "reference": "sources/cms-beneficiaries.csv", + "format": "csv", + "checksum": { + "algorithm": "sha256", + "value": "500f5a2040cb17376c130884bfafa81bcc8d5acb0a44f89aa2af8701cc2d7349" + }, + "license": { + "redistribution": "allowed", + "reference": "licenses/NOTICE.txt" + }, + "provenance": { + "publisher": "CMS", + "retrieved_at": "2026-10-08", + "upstream_url": "https://www.cms.gov/research-statistics-data-and-systems/downloadable-public-use-files/synpufs/downloads/de1_0_2008_beneficiary_summary_file_sample_1.zip", + "transformations": [ + "Exact native header and selected complete record bytes; see cms-selection.json." + ] + }, + "revision": "DE-SynPUF 1.0 Sample 1; 2008 beneficiary and 2008–2010 claims" + }, + "cms_inpatient": { + "kind": "external", + "data_kind": "fabricated", + "reference": "sources/cms-inpatient.csv", + "format": "csv", + "checksum": { + "algorithm": "sha256", + "value": "064973be1b23e48c9df9f4163502282ffc01b1094710cba588beb6d581f6d8b4" + }, + "license": { + "redistribution": "allowed", + "reference": "licenses/NOTICE.txt" + }, + "provenance": { + "publisher": "CMS", + "retrieved_at": "2026-10-08", + "upstream_url": "https://www.cms.gov/research-statistics-data-and-systems/downloadable-public-use-files/synpufs/downloads/de1_0_2008_to_2010_inpatient_claims_sample_1.zip", + "transformations": [ + "Exact native header and selected complete record bytes; see cms-selection.json." + ] + }, + "revision": "DE-SynPUF 1.0 Sample 1; 2008 beneficiary and 2008–2010 claims" + }, + "cms_carrier": { + "kind": "external", + "data_kind": "fabricated", + "reference": "sources/cms-carrier.csv", + "format": "csv", + "checksum": { + "algorithm": "sha256", + "value": "91d44f48211ffe3a0176bcc3fc980672de5db48de1d79783935db703ed0f456d" + }, + "license": { + "redistribution": "allowed", + "reference": "licenses/NOTICE.txt" + }, + "provenance": { + "publisher": "CMS", + "retrieved_at": "2026-10-08", + "upstream_url": "https://downloads.cms.gov/files/DE1_0_2008_to_2010_Carrier_Claims_Sample_1A.zip", + "transformations": [ + "Exact native header and selected complete record bytes; see cms-selection.json." + ] + }, + "revision": "DE-SynPUF 1.0 Sample 1; 2008 beneficiary and 2008–2010 claims" + }, + "cms_selection": { + "kind": "external", + "data_kind": "unknown", + "reference": "sources/cms-selection.json", + "format": "json", + "checksum": { + "algorithm": "sha256", + "value": "ce80cfbfeaa4899356d1877d62bf2404ff53896de7acb69cb64aed94fe5da1c5" + }, + "license": { + "redistribution": "allowed", + "reference": "licenses/NOTICE.txt" + }, + "provenance": { + "publisher": "UMF project", + "retrieved_at": "2026-10-08", + "transformations": [] + } + }, "notices": { "kind": "external", "data_kind": "unknown", @@ -707,7 +898,7 @@ "format": "text", "checksum": { "algorithm": "sha256", - "value": "7d17b67002331831971ff865c563c1ef265da9fcb77068f90dd979f7b0a69b24" + "value": "1100d7e599a36762c7159a5fdc0ca81efd19185babaa2a8ec226f970d1e7340c" }, "license": { "redistribution": "allowed", @@ -724,7 +915,7 @@ "data_kind": "fabricated", "reference": "data/resources.csv", "format": "csv", - "revision": "medical-carrier-1.0.0", + "revision": "medical-carrier-1.1.0", "checksum": { "algorithm": "sha256", "value": "0f4a4537fc78a555ade4a8fe68709458c3b4c0f4a080b99692382dac0ef7f6e9" @@ -763,8 +954,7 @@ "supplement-plan", "supplement-response-authorization-approved", "supplement-response-authorization-denied", - "supplement-response-paid-denied", - "workflow" + "supplement-response-paid-denied" ], "transformations": [ "Deterministic selected-column projection; original native sources retained separately." @@ -776,7 +966,7 @@ "data_kind": "fabricated", "reference": "data/coverage.csv", "format": "csv", - "revision": "medical-carrier-1.0.0", + "revision": "medical-carrier-1.1.0", "checksum": { "algorithm": "sha256", "value": "5571b3a7a70a61dae1d771dc113c6a0a246e506f8a125de579094f3d87487eda" @@ -815,8 +1005,7 @@ "supplement-plan", "supplement-response-authorization-approved", "supplement-response-authorization-denied", - "supplement-response-paid-denied", - "workflow" + "supplement-response-paid-denied" ], "transformations": [ "Deterministic selected-column projection; original native sources retained separately." @@ -828,7 +1017,7 @@ "data_kind": "fabricated", "reference": "data/eligibility.csv", "format": "csv", - "revision": "medical-carrier-1.0.0", + "revision": "medical-carrier-1.1.0", "checksum": { "algorithm": "sha256", "value": "68d560d188c7fa42ac85b331de51ca04c8dd8c64611d3663cf53f5ad0f18a08a" @@ -867,8 +1056,7 @@ "supplement-plan", "supplement-response-authorization-approved", "supplement-response-authorization-denied", - "supplement-response-paid-denied", - "workflow" + "supplement-response-paid-denied" ], "transformations": [ "Deterministic selected-column projection; original native sources retained separately." @@ -880,7 +1068,7 @@ "data_kind": "fabricated", "reference": "data/claims.csv", "format": "csv", - "revision": "medical-carrier-1.0.0", + "revision": "medical-carrier-1.1.0", "checksum": { "algorithm": "sha256", "value": "a902b00758a4972f09f53e2e8b26f9997fdd2bea468e20a1cb7c04adebc8c703" @@ -919,8 +1107,7 @@ "supplement-plan", "supplement-response-authorization-approved", "supplement-response-authorization-denied", - "supplement-response-paid-denied", - "workflow" + "supplement-response-paid-denied" ], "transformations": [ "Deterministic selected-column projection; original native sources retained separately." @@ -932,7 +1119,7 @@ "data_kind": "fabricated", "reference": "data/claim_lines.csv", "format": "csv", - "revision": "medical-carrier-1.0.0", + "revision": "medical-carrier-1.1.0", "checksum": { "algorithm": "sha256", "value": "0bd9b58462d29869bcd8a00225f8b1b77b83c81bed04d5a8a44fe7232e94ce37" @@ -971,8 +1158,7 @@ "supplement-plan", "supplement-response-authorization-approved", "supplement-response-authorization-denied", - "supplement-response-paid-denied", - "workflow" + "supplement-response-paid-denied" ], "transformations": [ "Deterministic selected-column projection; original native sources retained separately." @@ -984,7 +1170,7 @@ "data_kind": "fabricated", "reference": "data/adjudications.csv", "format": "csv", - "revision": "medical-carrier-1.0.0", + "revision": "medical-carrier-1.1.0", "checksum": { "algorithm": "sha256", "value": "fa035e3b2b0dfb201414d04b7dcfdf0a7e39fed806de024b6c0be2ac352fab7f" @@ -1023,8 +1209,7 @@ "supplement-plan", "supplement-response-authorization-approved", "supplement-response-authorization-denied", - "supplement-response-paid-denied", - "workflow" + "supplement-response-paid-denied" ], "transformations": [ "Deterministic selected-column projection; original native sources retained separately." @@ -1036,7 +1221,7 @@ "data_kind": "fabricated", "reference": "data/payments.csv", "format": "csv", - "revision": "medical-carrier-1.0.0", + "revision": "medical-carrier-1.1.0", "checksum": { "algorithm": "sha256", "value": "1469a88558a7f262ef85c5fe9b4b6bda7eb7102ea92a992004f35a648ed707ec" @@ -1075,8 +1260,7 @@ "supplement-plan", "supplement-response-authorization-approved", "supplement-response-authorization-denied", - "supplement-response-paid-denied", - "workflow" + "supplement-response-paid-denied" ], "transformations": [ "Deterministic selected-column projection; original native sources retained separately." @@ -1088,7 +1272,7 @@ "data_kind": "fabricated", "reference": "data/plans.csv", "format": "csv", - "revision": "medical-carrier-1.0.0", + "revision": "medical-carrier-1.1.0", "checksum": { "algorithm": "sha256", "value": "f27ca990c8476379a6cc992083451b684eb0a1e54957aa1e985bf216b7f64034" @@ -1127,8 +1311,7 @@ "supplement-plan", "supplement-response-authorization-approved", "supplement-response-authorization-denied", - "supplement-response-paid-denied", - "workflow" + "supplement-response-paid-denied" ], "transformations": [ "Deterministic selected-column projection; original native sources retained separately." @@ -1140,7 +1323,7 @@ "data_kind": "fabricated", "reference": "data/enrollments.csv", "format": "csv", - "revision": "medical-carrier-1.0.0", + "revision": "medical-carrier-1.1.0", "checksum": { "algorithm": "sha256", "value": "5716b79011198e027a81163c62cd97c7c03af0b0b7e27308bd8d12b9c6625eb5" @@ -1179,8 +1362,7 @@ "supplement-plan", "supplement-response-authorization-approved", "supplement-response-authorization-denied", - "supplement-response-paid-denied", - "workflow" + "supplement-response-paid-denied" ], "transformations": [ "Deterministic selected-column projection; original native sources retained separately." @@ -1192,7 +1374,7 @@ "data_kind": "fabricated", "reference": "data/resource_references.csv", "format": "csv", - "revision": "medical-carrier-1.0.0", + "revision": "medical-carrier-1.1.0", "checksum": { "algorithm": "sha256", "value": "1da6ebc223e723755b8476306fb5e8050aa3d0e384fa7048ecc6c26a7aae0aaf" @@ -1231,8 +1413,7 @@ "supplement-plan", "supplement-response-authorization-approved", "supplement-response-authorization-denied", - "supplement-response-paid-denied", - "workflow" + "supplement-response-paid-denied" ], "transformations": [ "Deterministic selected-column projection; original native sources retained separately." @@ -1244,7 +1425,7 @@ "data_kind": "fabricated", "reference": "data/coded_values.csv", "format": "csv", - "revision": "medical-carrier-1.0.0", + "revision": "medical-carrier-1.1.0", "checksum": { "algorithm": "sha256", "value": "5eeeeb39af2f52c42959c071208ad18f9f8ba335865b5a3703d2df85677b0b48" @@ -1283,8 +1464,7 @@ "supplement-plan", "supplement-response-authorization-approved", "supplement-response-authorization-denied", - "supplement-response-paid-denied", - "workflow" + "supplement-response-paid-denied" ], "transformations": [ "Deterministic selected-column projection; original native sources retained separately." @@ -1296,7 +1476,7 @@ "data_kind": "fabricated", "reference": "data/workflow_events.csv", "format": "csv", - "revision": "medical-carrier-1.0.0", + "revision": "medical-carrier-1.1.0", "checksum": { "algorithm": "sha256", "value": "b27e0b1d336915c55ee950bb82b0cbf6f9cc86799ed6a0babd4ce3d6452f83cb" @@ -1308,40 +1488,87 @@ "provenance": { "publisher": "UMF project", "source_ids": [ - "hl7-claim", - "hl7-claimresponse", - "hl7-coverage", - "hl7-eligibility-request", - "hl7-eligibility-response", - "hl7-enrollment", - "hl7-eob", - "hl7-insuranceplan", - "hl7-payment", - "supplement-claim-authorization-approved", - "supplement-claim-authorization-denied", - "supplement-claim-paid-denied", - "supplement-coverage-active", - "supplement-coverage-inactive", - "supplement-eligibility-negative-request", - "supplement-eligibility-negative-response", - "supplement-eligibility-positive-request", - "supplement-eligibility-positive-response", - "supplement-enrollment-request", - "supplement-enrollment-response", - "supplement-eob", - "supplement-patient", - "supplement-payer", - "supplement-payment", - "supplement-plan", - "supplement-response-authorization-approved", - "supplement-response-authorization-denied", - "supplement-response-paid-denied", "workflow" ], "transformations": [ "Deterministic selected-column projection; original native sources retained separately." ] } + }, + "csv_cms_beneficiaries": { + "kind": "external", + "data_kind": "fabricated", + "reference": "data/cms_beneficiaries.csv", + "format": "csv", + "revision": "medical-carrier-1.1.0", + "checksum": { + "algorithm": "sha256", + "value": "682d408b477eba199e96c853c7982c0157881768a5b8e7be896a75ca1a91e82e" + }, + "license": { + "redistribution": "allowed", + "reference": "licenses/NOTICE.txt" + }, + "provenance": { + "publisher": "UMF project", + "source_ids": [ + "cms_beneficiaries", + "cms_selection" + ], + "transformations": [ + "Deterministic selected-column projection; original native sources retained separately." + ] + } + }, + "csv_cms_inpatient_claims": { + "kind": "external", + "data_kind": "fabricated", + "reference": "data/cms_inpatient_claims.csv", + "format": "csv", + "revision": "medical-carrier-1.1.0", + "checksum": { + "algorithm": "sha256", + "value": "281f8484b788cdfd0c3545740374675c9b69c350f25b64dd0f9aa26ce8ffdfa8" + }, + "license": { + "redistribution": "allowed", + "reference": "licenses/NOTICE.txt" + }, + "provenance": { + "publisher": "UMF project", + "source_ids": [ + "cms_inpatient", + "cms_selection" + ], + "transformations": [ + "Deterministic selected-column projection; original native sources retained separately." + ] + } + }, + "csv_cms_carrier_claims": { + "kind": "external", + "data_kind": "fabricated", + "reference": "data/cms_carrier_claims.csv", + "format": "csv", + "revision": "medical-carrier-1.1.0", + "checksum": { + "algorithm": "sha256", + "value": "a3175dadf541162ed006f3b768cc95c3aad7c06e5ca90bd79b4edebef2138401" + }, + "license": { + "redistribution": "allowed", + "reference": "licenses/NOTICE.txt" + }, + "provenance": { + "publisher": "UMF project", + "source_ids": [ + "cms_carrier", + "cms_selection" + ], + "transformations": [ + "Deterministic selected-column projection; original native sources retained separately." + ] + } } }, "source_bindings": [ @@ -1351,59 +1578,1649 @@ "role": "rows" }, { - "schema_id": "coverage", - "source_id": "csv_coverage", - "role": "rows" + "schema_id": "resources", + "source_id": "hl7-claim", + "role": "reference" }, { - "schema_id": "eligibility", - "source_id": "csv_eligibility", - "role": "rows" + "schema_id": "resources", + "source_id": "hl7-claimresponse", + "role": "reference" }, { - "schema_id": "claims", - "source_id": "csv_claims", - "role": "rows" + "schema_id": "resources", + "source_id": "hl7-coverage", + "role": "reference" }, { - "schema_id": "claim_lines", - "source_id": "csv_claim_lines", - "role": "rows" + "schema_id": "resources", + "source_id": "hl7-eligibility-request", + "role": "reference" }, { - "schema_id": "adjudications", - "source_id": "csv_adjudications", - "role": "rows" + "schema_id": "resources", + "source_id": "hl7-eligibility-response", + "role": "reference" }, { - "schema_id": "payments", - "source_id": "csv_payments", - "role": "rows" + "schema_id": "resources", + "source_id": "hl7-enrollment", + "role": "reference" }, { - "schema_id": "plans", - "source_id": "csv_plans", - "role": "rows" + "schema_id": "resources", + "source_id": "hl7-eob", + "role": "reference" }, { - "schema_id": "enrollments", - "source_id": "csv_enrollments", - "role": "rows" + "schema_id": "resources", + "source_id": "hl7-insuranceplan", + "role": "reference" }, { - "schema_id": "resource_references", - "source_id": "csv_resource_references", - "role": "rows" + "schema_id": "resources", + "source_id": "hl7-payment", + "role": "reference" }, { - "schema_id": "coded_values", - "source_id": "csv_coded_values", - "role": "rows" + "schema_id": "resources", + "source_id": "supplement-claim-authorization-approved", + "role": "reference" }, { - "schema_id": "workflow_events", - "source_id": "csv_workflow_events", - "role": "rows" + "schema_id": "resources", + "source_id": "supplement-claim-authorization-denied", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-claim-paid-denied", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-coverage-active", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-coverage-inactive", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-eligibility-negative-request", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-eligibility-negative-response", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-eligibility-positive-request", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-eligibility-positive-response", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-enrollment-request", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-enrollment-response", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-eob", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-patient", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-payer", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-payment", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-plan", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-response-authorization-approved", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-response-authorization-denied", + "role": "reference" + }, + { + "schema_id": "resources", + "source_id": "supplement-response-paid-denied", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "csv_coverage", + "role": "rows" + }, + { + "schema_id": "coverage", + "source_id": "hl7-claim", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "hl7-claimresponse", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "hl7-coverage", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "hl7-eligibility-request", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "hl7-eligibility-response", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "hl7-enrollment", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "hl7-eob", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "hl7-insuranceplan", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "hl7-payment", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-claim-authorization-approved", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-claim-authorization-denied", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-claim-paid-denied", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-coverage-active", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-coverage-inactive", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-eligibility-negative-request", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-eligibility-negative-response", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-eligibility-positive-request", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-eligibility-positive-response", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-enrollment-request", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-enrollment-response", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-eob", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-patient", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-payer", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-payment", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-plan", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-response-authorization-approved", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-response-authorization-denied", + "role": "reference" + }, + { + "schema_id": "coverage", + "source_id": "supplement-response-paid-denied", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "csv_eligibility", + "role": "rows" + }, + { + "schema_id": "eligibility", + "source_id": "hl7-claim", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "hl7-claimresponse", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "hl7-coverage", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "hl7-eligibility-request", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "hl7-eligibility-response", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "hl7-enrollment", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "hl7-eob", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "hl7-insuranceplan", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "hl7-payment", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-claim-authorization-approved", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-claim-authorization-denied", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-claim-paid-denied", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-coverage-active", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-coverage-inactive", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-eligibility-negative-request", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-eligibility-negative-response", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-eligibility-positive-request", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-eligibility-positive-response", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-enrollment-request", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-enrollment-response", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-eob", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-patient", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-payer", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-payment", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-plan", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-response-authorization-approved", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-response-authorization-denied", + "role": "reference" + }, + { + "schema_id": "eligibility", + "source_id": "supplement-response-paid-denied", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "csv_claims", + "role": "rows" + }, + { + "schema_id": "claims", + "source_id": "hl7-claim", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "hl7-claimresponse", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "hl7-coverage", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "hl7-eligibility-request", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "hl7-eligibility-response", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "hl7-enrollment", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "hl7-eob", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "hl7-insuranceplan", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "hl7-payment", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-claim-authorization-approved", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-claim-authorization-denied", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-claim-paid-denied", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-coverage-active", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-coverage-inactive", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-eligibility-negative-request", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-eligibility-negative-response", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-eligibility-positive-request", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-eligibility-positive-response", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-enrollment-request", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-enrollment-response", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-eob", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-patient", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-payer", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-payment", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-plan", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-response-authorization-approved", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-response-authorization-denied", + "role": "reference" + }, + { + "schema_id": "claims", + "source_id": "supplement-response-paid-denied", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "csv_claim_lines", + "role": "rows" + }, + { + "schema_id": "claim_lines", + "source_id": "hl7-claim", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "hl7-claimresponse", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "hl7-coverage", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "hl7-eligibility-request", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "hl7-eligibility-response", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "hl7-enrollment", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "hl7-eob", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "hl7-insuranceplan", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "hl7-payment", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-claim-authorization-approved", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-claim-authorization-denied", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-claim-paid-denied", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-coverage-active", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-coverage-inactive", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-eligibility-negative-request", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-eligibility-negative-response", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-eligibility-positive-request", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-eligibility-positive-response", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-enrollment-request", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-enrollment-response", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-eob", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-patient", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-payer", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-payment", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-plan", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-response-authorization-approved", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-response-authorization-denied", + "role": "reference" + }, + { + "schema_id": "claim_lines", + "source_id": "supplement-response-paid-denied", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "csv_adjudications", + "role": "rows" + }, + { + "schema_id": "adjudications", + "source_id": "hl7-claim", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "hl7-claimresponse", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "hl7-coverage", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "hl7-eligibility-request", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "hl7-eligibility-response", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "hl7-enrollment", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "hl7-eob", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "hl7-insuranceplan", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "hl7-payment", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-claim-authorization-approved", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-claim-authorization-denied", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-claim-paid-denied", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-coverage-active", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-coverage-inactive", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-eligibility-negative-request", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-eligibility-negative-response", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-eligibility-positive-request", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-eligibility-positive-response", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-enrollment-request", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-enrollment-response", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-eob", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-patient", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-payer", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-payment", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-plan", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-response-authorization-approved", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-response-authorization-denied", + "role": "reference" + }, + { + "schema_id": "adjudications", + "source_id": "supplement-response-paid-denied", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "csv_payments", + "role": "rows" + }, + { + "schema_id": "payments", + "source_id": "hl7-claim", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "hl7-claimresponse", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "hl7-coverage", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "hl7-eligibility-request", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "hl7-eligibility-response", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "hl7-enrollment", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "hl7-eob", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "hl7-insuranceplan", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "hl7-payment", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-claim-authorization-approved", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-claim-authorization-denied", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-claim-paid-denied", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-coverage-active", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-coverage-inactive", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-eligibility-negative-request", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-eligibility-negative-response", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-eligibility-positive-request", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-eligibility-positive-response", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-enrollment-request", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-enrollment-response", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-eob", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-patient", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-payer", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-payment", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-plan", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-response-authorization-approved", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-response-authorization-denied", + "role": "reference" + }, + { + "schema_id": "payments", + "source_id": "supplement-response-paid-denied", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "csv_plans", + "role": "rows" + }, + { + "schema_id": "plans", + "source_id": "hl7-claim", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "hl7-claimresponse", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "hl7-coverage", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "hl7-eligibility-request", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "hl7-eligibility-response", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "hl7-enrollment", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "hl7-eob", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "hl7-insuranceplan", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "hl7-payment", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-claim-authorization-approved", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-claim-authorization-denied", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-claim-paid-denied", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-coverage-active", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-coverage-inactive", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-eligibility-negative-request", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-eligibility-negative-response", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-eligibility-positive-request", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-eligibility-positive-response", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-enrollment-request", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-enrollment-response", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-eob", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-patient", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-payer", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-payment", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-plan", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-response-authorization-approved", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-response-authorization-denied", + "role": "reference" + }, + { + "schema_id": "plans", + "source_id": "supplement-response-paid-denied", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "csv_enrollments", + "role": "rows" + }, + { + "schema_id": "enrollments", + "source_id": "hl7-claim", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "hl7-claimresponse", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "hl7-coverage", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "hl7-eligibility-request", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "hl7-eligibility-response", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "hl7-enrollment", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "hl7-eob", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "hl7-insuranceplan", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "hl7-payment", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-claim-authorization-approved", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-claim-authorization-denied", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-claim-paid-denied", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-coverage-active", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-coverage-inactive", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-eligibility-negative-request", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-eligibility-negative-response", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-eligibility-positive-request", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-eligibility-positive-response", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-enrollment-request", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-enrollment-response", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-eob", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-patient", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-payer", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-payment", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-plan", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-response-authorization-approved", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-response-authorization-denied", + "role": "reference" + }, + { + "schema_id": "enrollments", + "source_id": "supplement-response-paid-denied", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "csv_resource_references", + "role": "rows" + }, + { + "schema_id": "resource_references", + "source_id": "hl7-claim", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "hl7-claimresponse", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "hl7-coverage", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "hl7-eligibility-request", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "hl7-eligibility-response", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "hl7-enrollment", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "hl7-eob", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "hl7-insuranceplan", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "hl7-payment", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-claim-authorization-approved", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-claim-authorization-denied", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-claim-paid-denied", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-coverage-active", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-coverage-inactive", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-eligibility-negative-request", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-eligibility-negative-response", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-eligibility-positive-request", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-eligibility-positive-response", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-enrollment-request", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-enrollment-response", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-eob", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-patient", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-payer", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-payment", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-plan", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-response-authorization-approved", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-response-authorization-denied", + "role": "reference" + }, + { + "schema_id": "resource_references", + "source_id": "supplement-response-paid-denied", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "csv_coded_values", + "role": "rows" + }, + { + "schema_id": "coded_values", + "source_id": "hl7-claim", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "hl7-claimresponse", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "hl7-coverage", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "hl7-eligibility-request", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "hl7-eligibility-response", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "hl7-enrollment", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "hl7-eob", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "hl7-insuranceplan", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "hl7-payment", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-claim-authorization-approved", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-claim-authorization-denied", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-claim-paid-denied", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-coverage-active", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-coverage-inactive", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-eligibility-negative-request", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-eligibility-negative-response", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-eligibility-positive-request", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-eligibility-positive-response", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-enrollment-request", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-enrollment-response", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-eob", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-patient", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-payer", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-payment", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-plan", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-response-authorization-approved", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-response-authorization-denied", + "role": "reference" + }, + { + "schema_id": "coded_values", + "source_id": "supplement-response-paid-denied", + "role": "reference" + }, + { + "schema_id": "workflow_events", + "source_id": "csv_workflow_events", + "role": "rows" + }, + { + "schema_id": "workflow_events", + "source_id": "workflow", + "role": "reference" + }, + { + "schema_id": "cms_beneficiaries", + "source_id": "csv_cms_beneficiaries", + "role": "rows" + }, + { + "schema_id": "cms_beneficiaries", + "source_id": "cms_beneficiaries", + "role": "reference" + }, + { + "schema_id": "cms_beneficiaries", + "source_id": "cms_selection", + "role": "reference" + }, + { + "schema_id": "cms_inpatient_claims", + "source_id": "csv_cms_inpatient_claims", + "role": "rows" + }, + { + "schema_id": "cms_inpatient_claims", + "source_id": "cms_inpatient", + "role": "reference" + }, + { + "schema_id": "cms_inpatient_claims", + "source_id": "cms_selection", + "role": "reference" + }, + { + "schema_id": "cms_carrier_claims", + "source_id": "csv_cms_carrier_claims", + "role": "rows" + }, + { + "schema_id": "cms_carrier_claims", + "source_id": "cms_carrier", + "role": "reference" + }, + { + "schema_id": "cms_carrier_claims", + "source_id": "cms_selection", + "role": "reference" } ], "csv_conventions": { @@ -1424,11 +3241,14 @@ "enrollments": 3, "resource_references": 95, "coded_values": 101, - "workflow_events": 4 + "workflow_events": 4, + "cms_beneficiaries": 3, + "cms_inpatient_claims": 5, + "cms_carrier_claims": 5 }, "qualification": { "native_format": "FHIR R4 4.0.1 selected views plus independent UMF scenario events", - "subset": "9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.", - "limits": "Illustrative sources are not a validated FHIR Bundle or carrier simulation. Native official examples do not form a coherent history. CMS ingestion and X12 services are not implemented. Reference resolution is namespace-local; no patient matching." + "subset": "9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "limits": "Illustrative sources are not a validated FHIR Bundle or carrier simulation. Native official examples do not form a coherent history. CMS coverage is DE-SynPUF Sample 1, 2008 beneficiaries and 2008–2010 claims; ICD-9 remains native. Numeric CPT/Level I HCPCS carrier rows are excluded. These are synthetic public samples, not real beneficiaries. X12 services are not implemented. Reference resolution is namespace-local; no patient matching." } } diff --git a/spec/domain-packs/medical-carrier/sources/cms-beneficiaries.csv b/spec/domain-packs/medical-carrier/sources/cms-beneficiaries.csv new file mode 100644 index 000000000..6e2300bf9 --- /dev/null +++ b/spec/domain-packs/medical-carrier/sources/cms-beneficiaries.csv @@ -0,0 +1,4 @@ +"DESYNPUF_ID","BENE_BIRTH_DT","BENE_DEATH_DT","BENE_SEX_IDENT_CD","BENE_RACE_CD","BENE_ESRD_IND","SP_STATE_CODE","BENE_COUNTY_CD","BENE_HI_CVRAGE_TOT_MONS","BENE_SMI_CVRAGE_TOT_MONS","BENE_HMO_CVRAGE_TOT_MONS","PLAN_CVRG_MOS_NUM","SP_ALZHDMTA","SP_CHF","SP_CHRNKIDN","SP_CNCR","SP_COPD","SP_DEPRESSN","SP_DIABETES","SP_ISCHMCHT","SP_OSTEOPRS","SP_RA_OA","SP_STRKETIA","MEDREIMB_IP","BENRES_IP","PPPYMT_IP","MEDREIMB_OP","BENRES_OP","PPPYMT_OP","MEDREIMB_CAR","BENRES_CAR","PPPYMT_CAR" +00013D2EFD8E45D1,19230501,,1,1,0,26,950,12,12,12,12,2,2,2,2,2,2,2,2,2,2,2,0.00,0.00,0.00,50.00,10.00,0.00,0.00,0.00,0.00 +00016F745862898F,19430101,,1,1,0,39,230,12,12,0,00,2,2,2,2,2,2,2,2,2,2,2,0.00,0.00,0.00,0.00,0.00,0.00,700.00,240.00,0.00 +00024B3D2352D2D0,19360801,,1,1,0,52,590,12,12,0,00,2,2,2,2,2,2,2,2,1,2,2,0.00,0.00,0.00,30.00,40.00,0.00,220.00,80.00,0.00 diff --git a/spec/domain-packs/medical-carrier/sources/cms-carrier.csv b/spec/domain-packs/medical-carrier/sources/cms-carrier.csv new file mode 100644 index 000000000..960e4849a --- /dev/null +++ b/spec/domain-packs/medical-carrier/sources/cms-carrier.csv @@ -0,0 +1,6 @@ +"DESYNPUF_ID","CLM_ID","CLM_FROM_DT","CLM_THRU_DT","ICD9_DGNS_CD_1","ICD9_DGNS_CD_2","ICD9_DGNS_CD_3","ICD9_DGNS_CD_4","ICD9_DGNS_CD_5","ICD9_DGNS_CD_6","ICD9_DGNS_CD_7","ICD9_DGNS_CD_8","PRF_PHYSN_NPI_1","PRF_PHYSN_NPI_2","PRF_PHYSN_NPI_3","PRF_PHYSN_NPI_4","PRF_PHYSN_NPI_5","PRF_PHYSN_NPI_6","PRF_PHYSN_NPI_7","PRF_PHYSN_NPI_8","PRF_PHYSN_NPI_9","PRF_PHYSN_NPI_10","PRF_PHYSN_NPI_11","PRF_PHYSN_NPI_12","PRF_PHYSN_NPI_13","TAX_NUM_1","TAX_NUM_2","TAX_NUM_3","TAX_NUM_4","TAX_NUM_5","TAX_NUM_6","TAX_NUM_7","TAX_NUM_8","TAX_NUM_9","TAX_NUM_10","TAX_NUM_11","TAX_NUM_12","TAX_NUM_13","HCPCS_CD_1","HCPCS_CD_2","HCPCS_CD_3","HCPCS_CD_4","HCPCS_CD_5","HCPCS_CD_6","HCPCS_CD_7","HCPCS_CD_8","HCPCS_CD_9","HCPCS_CD_10","HCPCS_CD_11","HCPCS_CD_12","HCPCS_CD_13","LINE_NCH_PMT_AMT_1","LINE_NCH_PMT_AMT_2","LINE_NCH_PMT_AMT_3","LINE_NCH_PMT_AMT_4","LINE_NCH_PMT_AMT_5","LINE_NCH_PMT_AMT_6","LINE_NCH_PMT_AMT_7","LINE_NCH_PMT_AMT_8","LINE_NCH_PMT_AMT_9","LINE_NCH_PMT_AMT_10","LINE_NCH_PMT_AMT_11","LINE_NCH_PMT_AMT_12","LINE_NCH_PMT_AMT_13","LINE_BENE_PTB_DDCTBL_AMT_1","LINE_BENE_PTB_DDCTBL_AMT_2","LINE_BENE_PTB_DDCTBL_AMT_3","LINE_BENE_PTB_DDCTBL_AMT_4","LINE_BENE_PTB_DDCTBL_AMT_5","LINE_BENE_PTB_DDCTBL_AMT_6","LINE_BENE_PTB_DDCTBL_AMT_7","LINE_BENE_PTB_DDCTBL_AMT_8","LINE_BENE_PTB_DDCTBL_AMT_9","LINE_BENE_PTB_DDCTBL_AMT_10","LINE_BENE_PTB_DDCTBL_AMT_11","LINE_BENE_PTB_DDCTBL_AMT_12","LINE_BENE_PTB_DDCTBL_AMT_13","LINE_BENE_PRMRY_PYR_PD_AMT_1","LINE_BENE_PRMRY_PYR_PD_AMT_2","LINE_BENE_PRMRY_PYR_PD_AMT_3","LINE_BENE_PRMRY_PYR_PD_AMT_4","LINE_BENE_PRMRY_PYR_PD_AMT_5","LINE_BENE_PRMRY_PYR_PD_AMT_6","LINE_BENE_PRMRY_PYR_PD_AMT_7","LINE_BENE_PRMRY_PYR_PD_AMT_8","LINE_BENE_PRMRY_PYR_PD_AMT_9","LINE_BENE_PRMRY_PYR_PD_AMT_10","LINE_BENE_PRMRY_PYR_PD_AMT_11","LINE_BENE_PRMRY_PYR_PD_AMT_12","LINE_BENE_PRMRY_PYR_PD_AMT_13","LINE_COINSRNC_AMT_1","LINE_COINSRNC_AMT_2","LINE_COINSRNC_AMT_3","LINE_COINSRNC_AMT_4","LINE_COINSRNC_AMT_5","LINE_COINSRNC_AMT_6","LINE_COINSRNC_AMT_7","LINE_COINSRNC_AMT_8","LINE_COINSRNC_AMT_9","LINE_COINSRNC_AMT_10","LINE_COINSRNC_AMT_11","LINE_COINSRNC_AMT_12","LINE_COINSRNC_AMT_13","LINE_ALOWD_CHRG_AMT_1","LINE_ALOWD_CHRG_AMT_2","LINE_ALOWD_CHRG_AMT_3","LINE_ALOWD_CHRG_AMT_4","LINE_ALOWD_CHRG_AMT_5","LINE_ALOWD_CHRG_AMT_6","LINE_ALOWD_CHRG_AMT_7","LINE_ALOWD_CHRG_AMT_8","LINE_ALOWD_CHRG_AMT_9","LINE_ALOWD_CHRG_AMT_10","LINE_ALOWD_CHRG_AMT_11","LINE_ALOWD_CHRG_AMT_12","LINE_ALOWD_CHRG_AMT_13","LINE_PRCSG_IND_CD_1","LINE_PRCSG_IND_CD_2","LINE_PRCSG_IND_CD_3","LINE_PRCSG_IND_CD_4","LINE_PRCSG_IND_CD_5","LINE_PRCSG_IND_CD_6","LINE_PRCSG_IND_CD_7","LINE_PRCSG_IND_CD_8","LINE_PRCSG_IND_CD_9","LINE_PRCSG_IND_CD_10","LINE_PRCSG_IND_CD_11","LINE_PRCSG_IND_CD_12","LINE_PRCSG_IND_CD_13","LINE_ICD9_DGNS_CD_1","LINE_ICD9_DGNS_CD_2","LINE_ICD9_DGNS_CD_3","LINE_ICD9_DGNS_CD_4","LINE_ICD9_DGNS_CD_5","LINE_ICD9_DGNS_CD_6","LINE_ICD9_DGNS_CD_7","LINE_ICD9_DGNS_CD_8","LINE_ICD9_DGNS_CD_9","LINE_ICD9_DGNS_CD_10","LINE_ICD9_DGNS_CD_11","LINE_ICD9_DGNS_CD_12","LINE_ICD9_DGNS_CD_13" +00016F745862898F,887453384924494,20090716,20090716,78965,78703,5770,78321,,,,,5390193581,,,,,,,,,,,,,602380861,,,,,,,,,,,,,A0427,,,,,,,,,,,,,80.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,90.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,20.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,100.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,A,,,,,,,,,,,,,78907,,,,,,,,,,,, +00024B3D2352D2D0,887753388589395,20080916,20080916,V2882,,,,,,,,7199105618,,,,,,,,,,,,,982048809,,,,,,,,,,,,,G0202,,,,,,,,,,,,,30.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,10.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,100.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,A,,,,,,,,,,,,,V7612,,,,,,,,,,,, +00024B3D2352D2D0,887233387820468,20090425,20090425,83510,71901,,,,,,,2655559178,,,,,,,,,,,,,982048809,,,,,,,,,,,,,G0283,,,,,,,,,,,,,10.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,10.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,30.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,A,,,,,,,,,,,,,83100,,,,,,,,,,,, +00024B3D2352D2D0,887523387400539,20091118,20091118,V7381,,,,,,,,7812593983,7812593983,,,,,,,,,,,,255271799,255271799,,,,,,,,,,,,G0008,G0008,,,,,,,,,,,,10.00,10.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,10.00,20.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,A,A,,,,,,,,,,,,V0481,V0481,,,,,,,,,,, +00024B3D2352D2D0,887023388626288,20100131,20100131,V2881,79382,,,,,,,3295479888,3295479888,,,,,,,,,,,,982048809,982048809,,,,,,,,,,,,G0202,G0202,,,,,,,,,,,,10.00,110.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,10.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,130.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,0.00,O,A,,,,,,,,,,,,V7612,V7612,,,,,,,,,,, diff --git a/spec/domain-packs/medical-carrier/sources/cms-inpatient.csv b/spec/domain-packs/medical-carrier/sources/cms-inpatient.csv new file mode 100644 index 000000000..207e7738f --- /dev/null +++ b/spec/domain-packs/medical-carrier/sources/cms-inpatient.csv @@ -0,0 +1,6 @@ +"DESYNPUF_ID","CLM_ID","SEGMENT","CLM_FROM_DT","CLM_THRU_DT","PRVDR_NUM","CLM_PMT_AMT","NCH_PRMRY_PYR_CLM_PD_AMT","AT_PHYSN_NPI","OP_PHYSN_NPI","OT_PHYSN_NPI","CLM_ADMSN_DT","ADMTNG_ICD9_DGNS_CD","CLM_PASS_THRU_PER_DIEM_AMT","NCH_BENE_IP_DDCTBL_AMT","NCH_BENE_PTA_COINSRNC_LBLTY_AM","NCH_BENE_BLOOD_DDCTBL_LBLTY_AM","CLM_UTLZTN_DAY_CNT","NCH_BENE_DSCHRG_DT","CLM_DRG_CD","ICD9_DGNS_CD_1","ICD9_DGNS_CD_2","ICD9_DGNS_CD_3","ICD9_DGNS_CD_4","ICD9_DGNS_CD_5","ICD9_DGNS_CD_6","ICD9_DGNS_CD_7","ICD9_DGNS_CD_8","ICD9_DGNS_CD_9","ICD9_DGNS_CD_10","ICD9_PRCDR_CD_1","ICD9_PRCDR_CD_2","ICD9_PRCDR_CD_3","ICD9_PRCDR_CD_4","ICD9_PRCDR_CD_5","ICD9_PRCDR_CD_6","HCPCS_CD_1","HCPCS_CD_2","HCPCS_CD_3","HCPCS_CD_4","HCPCS_CD_5","HCPCS_CD_6","HCPCS_CD_7","HCPCS_CD_8","HCPCS_CD_9","HCPCS_CD_10","HCPCS_CD_11","HCPCS_CD_12","HCPCS_CD_13","HCPCS_CD_14","HCPCS_CD_15","HCPCS_CD_16","HCPCS_CD_17","HCPCS_CD_18","HCPCS_CD_19","HCPCS_CD_20","HCPCS_CD_21","HCPCS_CD_22","HCPCS_CD_23","HCPCS_CD_24","HCPCS_CD_25","HCPCS_CD_26","HCPCS_CD_27","HCPCS_CD_28","HCPCS_CD_29","HCPCS_CD_30","HCPCS_CD_31","HCPCS_CD_32","HCPCS_CD_33","HCPCS_CD_34","HCPCS_CD_35","HCPCS_CD_36","HCPCS_CD_37","HCPCS_CD_38","HCPCS_CD_39","HCPCS_CD_40","HCPCS_CD_41","HCPCS_CD_42","HCPCS_CD_43","HCPCS_CD_44","HCPCS_CD_45" +00013D2EFD8E45D1,196661176988405,1,20100312,20100313,2600GD,4000.00,0.00,3139083564,,,20100312,4580,0.00,1100.00,0.00,0.00,1,20100313,217,7802,78820,V4501,4280,2720,4019,V4502,73300,E9330,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +00016F745862898F,196201177000368,1,20090412,20090418,3900MB,26000.00,0.00,6476809087,,,20090412,7866,0.00,1068.00,0.00,0.00,6,20090418,201,1970,4019,5853,7843,2768,71590,2724,19889,5849,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +00016F745862898F,196661177015632,1,20090831,20090902,3900HM,5000.00,0.00,0611998537,0611998537,,20090831,6186,0.00,1068.00,0.00,0.00,2,20090902,750,6186,2948,56400,,,,,,,,7092,6186,V5866,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +00016F745862898F,196091176981058,1,20090917,20090920,3913XU,5000.00,0.00,4971602784,,1119000316,20090917,29590,0.00,1068.00,0.00,0.00,3,20090920,883,29623,30390,71690,34590,V1581,32723,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +00016F745862898F,196261176983265,1,20100626,20100701,3900MB,16000.00,0.00,6408400473,1960859579,,20100626,5849,0.00,1100.00,0.00,0.00,5,20100701,983,3569,4019,3542,V8801,78820,2639,7840,7856,4271,,,E8889,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, diff --git a/spec/domain-packs/medical-carrier/sources/cms-selection.json b/spec/domain-packs/medical-carrier/sources/cms-selection.json new file mode 100644 index 000000000..97f624e29 --- /dev/null +++ b/spec/domain-packs/medical-carrier/sources/cms-selection.json @@ -0,0 +1,60 @@ +{ + "release": "DE-SynPUF 1.0 Sample 1; 2008 beneficiary and 2008–2010 claims", + "retrieved_at": "2026-10-08", + "data_kind": "fabricated", + "files": { + "beneficiaries": { + "url": "https://www.cms.gov/research-statistics-data-and-systems/downloadable-public-use-files/synpufs/downloads/de1_0_2008_beneficiary_summary_file_sample_1.zip", + "archive_sha256": "2b0c9cbfb07a6eb46d5f96472c0891275a390b686c3fa34daae8d3e53d70b18b", + "member": "DE1_0_2008_Beneficiary_Summary_File_Sample_1.csv", + "member_sha256": "3a8ca1a6540f5ffa1666e6f051ec0756e2212cda9ff9b4c18f0c1a1594f70fbe", + "selected_record_numbers": [ + 1, + 2, + 5 + ], + "subset_sha256": "500f5a2040cb17376c130884bfafa81bcc8d5acb0a44f89aa2af8701cc2d7349", + "rows": 3 + }, + "inpatient": { + "url": "https://www.cms.gov/research-statistics-data-and-systems/downloadable-public-use-files/synpufs/downloads/de1_0_2008_to_2010_inpatient_claims_sample_1.zip", + "archive_sha256": "ac25124184d22863aff538607097d2d0c880d19f7d58f882f9d31129c492d893", + "member": "DE1_0_2008_to_2010_Inpatient_Claims_Sample_1.csv", + "member_sha256": "8e3e8469f7e68d9cb8db0642aa4a7f2fa78004973c28973458a07f122a568681", + "selected_record_numbers": [ + 1, + 2, + 3, + 4, + 5 + ], + "subset_sha256": "064973be1b23e48c9df9f4163502282ffc01b1094710cba588beb6d581f6d8b4", + "rows": 5 + }, + "carrier": { + "url": "https://downloads.cms.gov/files/DE1_0_2008_to_2010_Carrier_Claims_Sample_1A.zip", + "archive_sha256": "4b4038b5f6cd9c524fa3a655a3f467aef01af56c3cae0f08902a35a9945bed97", + "member": "DE1_0_2008_to_2010_Carrier_Claims_Sample_1A.csv", + "member_sha256": "bb4f7ffe7187741e049c6a0234410df309be9fe644ec63437070ca6f4d7132d3", + "selected_record_numbers": [ + 24, + 54, + 56, + 66, + 68 + ], + "subset_sha256": "91d44f48211ffe3a0176bcc3fc980672de5db48de1d79783935db703ed0f456d", + "rows": 5 + } + }, + "selection": "First five inpatient rows and first five complete carrier rows without numeric CPT/Level I HCPCS tokens; all matching 2008 beneficiaries. The second carrier file (1B) is outside this tiny subset. Native columns and bytes unchanged. No ICD-9 conversion, clinical validity or longitudinal completeness claimed.", + "rights": { + "basis": "CMS public-domain website declaration and unrestricted DE-SynPUF software-development public release; no CPT code/descriptor vocabulary bundled.", + "references": [ + "https://www.cms.gov/about-cms/web-policies-important-links/about-website/link-to-us", + "https://www.cms.gov/data-research/statistics-trends-and-reports/medicare-claims-synthetic-public-use-files", + "https://www.cms.gov/files/document/de-10-frequently-asked-questions.pdf" + ], + "limit": "Applies to this selected subset, not other CMS files or licensed codebooks." + } +} diff --git a/spec/domain-packs/medical-carrier/umf/adjudications.json b/spec/domain-packs/medical-carrier/umf/adjudications.json index ca759aa56..7557f8476 100644 --- a/spec/domain-packs/medical-carrier/umf/adjudications.json +++ b/spec/domain-packs/medical-carrier/umf/adjudications.json @@ -1,7 +1,7 @@ { "version": "1.0", "table_name": "adjudications", - "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", "columns": [ { "name": "adjudication_key", diff --git a/spec/domain-packs/medical-carrier/umf/claim_lines.json b/spec/domain-packs/medical-carrier/umf/claim_lines.json index f47ec4fe5..768dacd06 100644 --- a/spec/domain-packs/medical-carrier/umf/claim_lines.json +++ b/spec/domain-packs/medical-carrier/umf/claim_lines.json @@ -1,7 +1,7 @@ { "version": "1.0", "table_name": "claim_lines", - "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", "columns": [ { "name": "line_key", diff --git a/spec/domain-packs/medical-carrier/umf/claims.json b/spec/domain-packs/medical-carrier/umf/claims.json index 60a9f5f06..47c232b53 100644 --- a/spec/domain-packs/medical-carrier/umf/claims.json +++ b/spec/domain-packs/medical-carrier/umf/claims.json @@ -1,7 +1,7 @@ { "version": "1.0", "table_name": "claims", - "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", "columns": [ { "name": "resource_key", diff --git a/spec/domain-packs/medical-carrier/umf/cms_beneficiaries.json b/spec/domain-packs/medical-carrier/umf/cms_beneficiaries.json new file mode 100644 index 000000000..ace6b5fa7 --- /dev/null +++ b/spec/domain-packs/medical-carrier/umf/cms_beneficiaries.json @@ -0,0 +1,214 @@ +{ + "version": "1.0", + "table_name": "cms_beneficiaries", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "columns": [ + { + "name": "DESYNPUF_ID", + "data_type": "VARCHAR", + "nullable": false, + "description": "DESYNPUF ID" + }, + { + "name": "BENE_BIRTH_DT", + "data_type": "VARCHAR", + "nullable": false, + "description": "BENE BIRTH DT" + }, + { + "name": "BENE_DEATH_DT", + "data_type": "VARCHAR", + "nullable": false, + "description": "BENE DEATH DT" + }, + { + "name": "BENE_SEX_IDENT_CD", + "data_type": "VARCHAR", + "nullable": false, + "description": "BENE SEX IDENT CD" + }, + { + "name": "BENE_RACE_CD", + "data_type": "VARCHAR", + "nullable": false, + "description": "BENE RACE CD" + }, + { + "name": "BENE_ESRD_IND", + "data_type": "VARCHAR", + "nullable": false, + "description": "BENE ESRD IND" + }, + { + "name": "SP_STATE_CODE", + "data_type": "VARCHAR", + "nullable": false, + "description": "SP STATE CODE" + }, + { + "name": "BENE_COUNTY_CD", + "data_type": "VARCHAR", + "nullable": false, + "description": "BENE COUNTY CD" + }, + { + "name": "BENE_HI_CVRAGE_TOT_MONS", + "data_type": "VARCHAR", + "nullable": false, + "description": "BENE HI CVRAGE TOT MONS" + }, + { + "name": "BENE_SMI_CVRAGE_TOT_MONS", + "data_type": "VARCHAR", + "nullable": false, + "description": "BENE SMI CVRAGE TOT MONS" + }, + { + "name": "BENE_HMO_CVRAGE_TOT_MONS", + "data_type": "VARCHAR", + "nullable": false, + "description": "BENE HMO CVRAGE TOT MONS" + }, + { + "name": "PLAN_CVRG_MOS_NUM", + "data_type": "VARCHAR", + "nullable": false, + "description": "PLAN CVRG MOS NUM" + }, + { + "name": "SP_ALZHDMTA", + "data_type": "VARCHAR", + "nullable": false, + "description": "SP ALZHDMTA" + }, + { + "name": "SP_CHF", + "data_type": "VARCHAR", + "nullable": false, + "description": "SP CHF" + }, + { + "name": "SP_CHRNKIDN", + "data_type": "VARCHAR", + "nullable": false, + "description": "SP CHRNKIDN" + }, + { + "name": "SP_CNCR", + "data_type": "VARCHAR", + "nullable": false, + "description": "SP CNCR" + }, + { + "name": "SP_COPD", + "data_type": "VARCHAR", + "nullable": false, + "description": "SP COPD" + }, + { + "name": "SP_DEPRESSN", + "data_type": "VARCHAR", + "nullable": false, + "description": "SP DEPRESSN" + }, + { + "name": "SP_DIABETES", + "data_type": "VARCHAR", + "nullable": false, + "description": "SP DIABETES" + }, + { + "name": "SP_ISCHMCHT", + "data_type": "VARCHAR", + "nullable": false, + "description": "SP ISCHMCHT" + }, + { + "name": "SP_OSTEOPRS", + "data_type": "VARCHAR", + "nullable": false, + "description": "SP OSTEOPRS" + }, + { + "name": "SP_RA_OA", + "data_type": "VARCHAR", + "nullable": false, + "description": "SP RA OA" + }, + { + "name": "SP_STRKETIA", + "data_type": "VARCHAR", + "nullable": false, + "description": "SP STRKETIA" + }, + { + "name": "MEDREIMB_IP", + "data_type": "VARCHAR", + "nullable": false, + "description": "MEDREIMB IP" + }, + { + "name": "BENRES_IP", + "data_type": "VARCHAR", + "nullable": false, + "description": "BENRES IP" + }, + { + "name": "PPPYMT_IP", + "data_type": "VARCHAR", + "nullable": false, + "description": "PPPYMT IP" + }, + { + "name": "MEDREIMB_OP", + "data_type": "VARCHAR", + "nullable": false, + "description": "MEDREIMB OP" + }, + { + "name": "BENRES_OP", + "data_type": "VARCHAR", + "nullable": false, + "description": "BENRES OP" + }, + { + "name": "PPPYMT_OP", + "data_type": "VARCHAR", + "nullable": false, + "description": "PPPYMT OP" + }, + { + "name": "MEDREIMB_CAR", + "data_type": "VARCHAR", + "nullable": false, + "description": "MEDREIMB CAR" + }, + { + "name": "BENRES_CAR", + "data_type": "VARCHAR", + "nullable": false, + "description": "BENRES CAR" + }, + { + "name": "PPPYMT_CAR", + "data_type": "VARCHAR", + "nullable": false, + "description": "PPPYMT CAR" + }, + { + "name": "native_record_number", + "data_type": "VARCHAR", + "nullable": false, + "description": "native record number" + }, + { + "name": "native_csv_record", + "data_type": "VARCHAR", + "nullable": false, + "description": "native csv record" + } + ], + "primary_key": [ + "DESYNPUF_ID" + ] +} diff --git a/spec/domain-packs/medical-carrier/umf/cms_carrier_claims.json b/spec/domain-packs/medical-carrier/umf/cms_carrier_claims.json new file mode 100644 index 000000000..4908edc6c --- /dev/null +++ b/spec/domain-packs/medical-carrier/umf/cms_carrier_claims.json @@ -0,0 +1,883 @@ +{ + "version": "1.0", + "table_name": "cms_carrier_claims", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "columns": [ + { + "name": "DESYNPUF_ID", + "data_type": "VARCHAR", + "nullable": false, + "description": "DESYNPUF ID" + }, + { + "name": "CLM_ID", + "data_type": "VARCHAR", + "nullable": false, + "description": "CLM ID" + }, + { + "name": "CLM_FROM_DT", + "data_type": "VARCHAR", + "nullable": false, + "description": "CLM FROM DT" + }, + { + "name": "CLM_THRU_DT", + "data_type": "VARCHAR", + "nullable": false, + "description": "CLM THRU DT" + }, + { + "name": "ICD9_DGNS_CD_1", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 1" + }, + { + "name": "ICD9_DGNS_CD_2", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 2" + }, + { + "name": "ICD9_DGNS_CD_3", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 3" + }, + { + "name": "ICD9_DGNS_CD_4", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 4" + }, + { + "name": "ICD9_DGNS_CD_5", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 5" + }, + { + "name": "ICD9_DGNS_CD_6", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 6" + }, + { + "name": "ICD9_DGNS_CD_7", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 7" + }, + { + "name": "ICD9_DGNS_CD_8", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 8" + }, + { + "name": "PRF_PHYSN_NPI_1", + "data_type": "VARCHAR", + "nullable": false, + "description": "PRF PHYSN NPI 1" + }, + { + "name": "PRF_PHYSN_NPI_2", + "data_type": "VARCHAR", + "nullable": false, + "description": "PRF PHYSN NPI 2" + }, + { + "name": "PRF_PHYSN_NPI_3", + "data_type": "VARCHAR", + "nullable": false, + "description": "PRF PHYSN NPI 3" + }, + { + "name": "PRF_PHYSN_NPI_4", + "data_type": "VARCHAR", + "nullable": false, + "description": "PRF PHYSN NPI 4" + }, + { + "name": "PRF_PHYSN_NPI_5", + "data_type": "VARCHAR", + "nullable": false, + "description": "PRF PHYSN NPI 5" + }, + { + "name": "PRF_PHYSN_NPI_6", + "data_type": "VARCHAR", + "nullable": false, + "description": "PRF PHYSN NPI 6" + }, + { + "name": "PRF_PHYSN_NPI_7", + "data_type": "VARCHAR", + "nullable": false, + "description": "PRF PHYSN NPI 7" + }, + { + "name": "PRF_PHYSN_NPI_8", + "data_type": "VARCHAR", + "nullable": false, + "description": "PRF PHYSN NPI 8" + }, + { + "name": "PRF_PHYSN_NPI_9", + "data_type": "VARCHAR", + "nullable": false, + "description": "PRF PHYSN NPI 9" + }, + { + "name": "PRF_PHYSN_NPI_10", + "data_type": "VARCHAR", + "nullable": false, + "description": "PRF PHYSN NPI 10" + }, + { + "name": "PRF_PHYSN_NPI_11", + "data_type": "VARCHAR", + "nullable": false, + "description": "PRF PHYSN NPI 11" + }, + { + "name": "PRF_PHYSN_NPI_12", + "data_type": "VARCHAR", + "nullable": false, + "description": "PRF PHYSN NPI 12" + }, + { + "name": "PRF_PHYSN_NPI_13", + "data_type": "VARCHAR", + "nullable": false, + "description": "PRF PHYSN NPI 13" + }, + { + "name": "TAX_NUM_1", + "data_type": "VARCHAR", + "nullable": false, + "description": "TAX NUM 1" + }, + { + "name": "TAX_NUM_2", + "data_type": "VARCHAR", + "nullable": false, + "description": "TAX NUM 2" + }, + { + "name": "TAX_NUM_3", + "data_type": "VARCHAR", + "nullable": false, + "description": "TAX NUM 3" + }, + { + "name": "TAX_NUM_4", + "data_type": "VARCHAR", + "nullable": false, + "description": "TAX NUM 4" + }, + { + "name": "TAX_NUM_5", + "data_type": "VARCHAR", + "nullable": false, + "description": "TAX NUM 5" + }, + { + "name": "TAX_NUM_6", + "data_type": "VARCHAR", + "nullable": false, + "description": "TAX NUM 6" + }, + { + "name": "TAX_NUM_7", + "data_type": "VARCHAR", + "nullable": false, + "description": "TAX NUM 7" + }, + { + "name": "TAX_NUM_8", + "data_type": "VARCHAR", + "nullable": false, + "description": "TAX NUM 8" + }, + { + "name": "TAX_NUM_9", + "data_type": "VARCHAR", + "nullable": false, + "description": "TAX NUM 9" + }, + { + "name": "TAX_NUM_10", + "data_type": "VARCHAR", + "nullable": false, + "description": "TAX NUM 10" + }, + { + "name": "TAX_NUM_11", + "data_type": "VARCHAR", + "nullable": false, + "description": "TAX NUM 11" + }, + { + "name": "TAX_NUM_12", + "data_type": "VARCHAR", + "nullable": false, + "description": "TAX NUM 12" + }, + { + "name": "TAX_NUM_13", + "data_type": "VARCHAR", + "nullable": false, + "description": "TAX NUM 13" + }, + { + "name": "HCPCS_CD_1", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 1" + }, + { + "name": "HCPCS_CD_2", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 2" + }, + { + "name": "HCPCS_CD_3", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 3" + }, + { + "name": "HCPCS_CD_4", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 4" + }, + { + "name": "HCPCS_CD_5", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 5" + }, + { + "name": "HCPCS_CD_6", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 6" + }, + { + "name": "HCPCS_CD_7", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 7" + }, + { + "name": "HCPCS_CD_8", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 8" + }, + { + "name": "HCPCS_CD_9", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 9" + }, + { + "name": "HCPCS_CD_10", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 10" + }, + { + "name": "HCPCS_CD_11", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 11" + }, + { + "name": "HCPCS_CD_12", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 12" + }, + { + "name": "HCPCS_CD_13", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 13" + }, + { + "name": "LINE_NCH_PMT_AMT_1", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE NCH PMT AMT 1" + }, + { + "name": "LINE_NCH_PMT_AMT_2", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE NCH PMT AMT 2" + }, + { + "name": "LINE_NCH_PMT_AMT_3", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE NCH PMT AMT 3" + }, + { + "name": "LINE_NCH_PMT_AMT_4", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE NCH PMT AMT 4" + }, + { + "name": "LINE_NCH_PMT_AMT_5", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE NCH PMT AMT 5" + }, + { + "name": "LINE_NCH_PMT_AMT_6", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE NCH PMT AMT 6" + }, + { + "name": "LINE_NCH_PMT_AMT_7", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE NCH PMT AMT 7" + }, + { + "name": "LINE_NCH_PMT_AMT_8", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE NCH PMT AMT 8" + }, + { + "name": "LINE_NCH_PMT_AMT_9", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE NCH PMT AMT 9" + }, + { + "name": "LINE_NCH_PMT_AMT_10", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE NCH PMT AMT 10" + }, + { + "name": "LINE_NCH_PMT_AMT_11", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE NCH PMT AMT 11" + }, + { + "name": "LINE_NCH_PMT_AMT_12", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE NCH PMT AMT 12" + }, + { + "name": "LINE_NCH_PMT_AMT_13", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE NCH PMT AMT 13" + }, + { + "name": "LINE_BENE_PTB_DDCTBL_AMT_1", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PTB DDCTBL AMT 1" + }, + { + "name": "LINE_BENE_PTB_DDCTBL_AMT_2", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PTB DDCTBL AMT 2" + }, + { + "name": "LINE_BENE_PTB_DDCTBL_AMT_3", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PTB DDCTBL AMT 3" + }, + { + "name": "LINE_BENE_PTB_DDCTBL_AMT_4", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PTB DDCTBL AMT 4" + }, + { + "name": "LINE_BENE_PTB_DDCTBL_AMT_5", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PTB DDCTBL AMT 5" + }, + { + "name": "LINE_BENE_PTB_DDCTBL_AMT_6", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PTB DDCTBL AMT 6" + }, + { + "name": "LINE_BENE_PTB_DDCTBL_AMT_7", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PTB DDCTBL AMT 7" + }, + { + "name": "LINE_BENE_PTB_DDCTBL_AMT_8", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PTB DDCTBL AMT 8" + }, + { + "name": "LINE_BENE_PTB_DDCTBL_AMT_9", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PTB DDCTBL AMT 9" + }, + { + "name": "LINE_BENE_PTB_DDCTBL_AMT_10", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PTB DDCTBL AMT 10" + }, + { + "name": "LINE_BENE_PTB_DDCTBL_AMT_11", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PTB DDCTBL AMT 11" + }, + { + "name": "LINE_BENE_PTB_DDCTBL_AMT_12", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PTB DDCTBL AMT 12" + }, + { + "name": "LINE_BENE_PTB_DDCTBL_AMT_13", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PTB DDCTBL AMT 13" + }, + { + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_1", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PRMRY PYR PD AMT 1" + }, + { + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_2", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PRMRY PYR PD AMT 2" + }, + { + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_3", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PRMRY PYR PD AMT 3" + }, + { + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_4", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PRMRY PYR PD AMT 4" + }, + { + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_5", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PRMRY PYR PD AMT 5" + }, + { + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_6", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PRMRY PYR PD AMT 6" + }, + { + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_7", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PRMRY PYR PD AMT 7" + }, + { + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_8", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PRMRY PYR PD AMT 8" + }, + { + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_9", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PRMRY PYR PD AMT 9" + }, + { + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_10", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PRMRY PYR PD AMT 10" + }, + { + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_11", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PRMRY PYR PD AMT 11" + }, + { + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_12", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PRMRY PYR PD AMT 12" + }, + { + "name": "LINE_BENE_PRMRY_PYR_PD_AMT_13", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE BENE PRMRY PYR PD AMT 13" + }, + { + "name": "LINE_COINSRNC_AMT_1", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE COINSRNC AMT 1" + }, + { + "name": "LINE_COINSRNC_AMT_2", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE COINSRNC AMT 2" + }, + { + "name": "LINE_COINSRNC_AMT_3", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE COINSRNC AMT 3" + }, + { + "name": "LINE_COINSRNC_AMT_4", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE COINSRNC AMT 4" + }, + { + "name": "LINE_COINSRNC_AMT_5", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE COINSRNC AMT 5" + }, + { + "name": "LINE_COINSRNC_AMT_6", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE COINSRNC AMT 6" + }, + { + "name": "LINE_COINSRNC_AMT_7", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE COINSRNC AMT 7" + }, + { + "name": "LINE_COINSRNC_AMT_8", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE COINSRNC AMT 8" + }, + { + "name": "LINE_COINSRNC_AMT_9", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE COINSRNC AMT 9" + }, + { + "name": "LINE_COINSRNC_AMT_10", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE COINSRNC AMT 10" + }, + { + "name": "LINE_COINSRNC_AMT_11", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE COINSRNC AMT 11" + }, + { + "name": "LINE_COINSRNC_AMT_12", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE COINSRNC AMT 12" + }, + { + "name": "LINE_COINSRNC_AMT_13", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE COINSRNC AMT 13" + }, + { + "name": "LINE_ALOWD_CHRG_AMT_1", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ALOWD CHRG AMT 1" + }, + { + "name": "LINE_ALOWD_CHRG_AMT_2", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ALOWD CHRG AMT 2" + }, + { + "name": "LINE_ALOWD_CHRG_AMT_3", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ALOWD CHRG AMT 3" + }, + { + "name": "LINE_ALOWD_CHRG_AMT_4", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ALOWD CHRG AMT 4" + }, + { + "name": "LINE_ALOWD_CHRG_AMT_5", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ALOWD CHRG AMT 5" + }, + { + "name": "LINE_ALOWD_CHRG_AMT_6", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ALOWD CHRG AMT 6" + }, + { + "name": "LINE_ALOWD_CHRG_AMT_7", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ALOWD CHRG AMT 7" + }, + { + "name": "LINE_ALOWD_CHRG_AMT_8", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ALOWD CHRG AMT 8" + }, + { + "name": "LINE_ALOWD_CHRG_AMT_9", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ALOWD CHRG AMT 9" + }, + { + "name": "LINE_ALOWD_CHRG_AMT_10", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ALOWD CHRG AMT 10" + }, + { + "name": "LINE_ALOWD_CHRG_AMT_11", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ALOWD CHRG AMT 11" + }, + { + "name": "LINE_ALOWD_CHRG_AMT_12", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ALOWD CHRG AMT 12" + }, + { + "name": "LINE_ALOWD_CHRG_AMT_13", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ALOWD CHRG AMT 13" + }, + { + "name": "LINE_PRCSG_IND_CD_1", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE PRCSG IND CD 1" + }, + { + "name": "LINE_PRCSG_IND_CD_2", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE PRCSG IND CD 2" + }, + { + "name": "LINE_PRCSG_IND_CD_3", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE PRCSG IND CD 3" + }, + { + "name": "LINE_PRCSG_IND_CD_4", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE PRCSG IND CD 4" + }, + { + "name": "LINE_PRCSG_IND_CD_5", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE PRCSG IND CD 5" + }, + { + "name": "LINE_PRCSG_IND_CD_6", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE PRCSG IND CD 6" + }, + { + "name": "LINE_PRCSG_IND_CD_7", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE PRCSG IND CD 7" + }, + { + "name": "LINE_PRCSG_IND_CD_8", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE PRCSG IND CD 8" + }, + { + "name": "LINE_PRCSG_IND_CD_9", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE PRCSG IND CD 9" + }, + { + "name": "LINE_PRCSG_IND_CD_10", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE PRCSG IND CD 10" + }, + { + "name": "LINE_PRCSG_IND_CD_11", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE PRCSG IND CD 11" + }, + { + "name": "LINE_PRCSG_IND_CD_12", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE PRCSG IND CD 12" + }, + { + "name": "LINE_PRCSG_IND_CD_13", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE PRCSG IND CD 13" + }, + { + "name": "LINE_ICD9_DGNS_CD_1", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ICD9 DGNS CD 1" + }, + { + "name": "LINE_ICD9_DGNS_CD_2", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ICD9 DGNS CD 2" + }, + { + "name": "LINE_ICD9_DGNS_CD_3", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ICD9 DGNS CD 3" + }, + { + "name": "LINE_ICD9_DGNS_CD_4", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ICD9 DGNS CD 4" + }, + { + "name": "LINE_ICD9_DGNS_CD_5", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ICD9 DGNS CD 5" + }, + { + "name": "LINE_ICD9_DGNS_CD_6", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ICD9 DGNS CD 6" + }, + { + "name": "LINE_ICD9_DGNS_CD_7", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ICD9 DGNS CD 7" + }, + { + "name": "LINE_ICD9_DGNS_CD_8", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ICD9 DGNS CD 8" + }, + { + "name": "LINE_ICD9_DGNS_CD_9", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ICD9 DGNS CD 9" + }, + { + "name": "LINE_ICD9_DGNS_CD_10", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ICD9 DGNS CD 10" + }, + { + "name": "LINE_ICD9_DGNS_CD_11", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ICD9 DGNS CD 11" + }, + { + "name": "LINE_ICD9_DGNS_CD_12", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ICD9 DGNS CD 12" + }, + { + "name": "LINE_ICD9_DGNS_CD_13", + "data_type": "VARCHAR", + "nullable": false, + "description": "LINE ICD9 DGNS CD 13" + }, + { + "name": "native_record_number", + "data_type": "VARCHAR", + "nullable": false, + "description": "native record number" + }, + { + "name": "native_csv_record", + "data_type": "VARCHAR", + "nullable": false, + "description": "native csv record" + } + ], + "primary_key": [ + "CLM_ID" + ], + "relationships": { + "foreign_keys": [ + { + "column": "DESYNPUF_ID", + "references_table": "cms_beneficiaries", + "references_column": "DESYNPUF_ID" + } + ] + } +} diff --git a/spec/domain-packs/medical-carrier/umf/cms_inpatient_claims.json b/spec/domain-packs/medical-carrier/umf/cms_inpatient_claims.json new file mode 100644 index 000000000..479fc0147 --- /dev/null +++ b/spec/domain-packs/medical-carrier/umf/cms_inpatient_claims.json @@ -0,0 +1,518 @@ +{ + "version": "1.0", + "table_name": "cms_inpatient_claims", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", + "columns": [ + { + "name": "DESYNPUF_ID", + "data_type": "VARCHAR", + "nullable": false, + "description": "DESYNPUF ID" + }, + { + "name": "CLM_ID", + "data_type": "VARCHAR", + "nullable": false, + "description": "CLM ID" + }, + { + "name": "SEGMENT", + "data_type": "VARCHAR", + "nullable": false, + "description": "SEGMENT" + }, + { + "name": "CLM_FROM_DT", + "data_type": "VARCHAR", + "nullable": false, + "description": "CLM FROM DT" + }, + { + "name": "CLM_THRU_DT", + "data_type": "VARCHAR", + "nullable": false, + "description": "CLM THRU DT" + }, + { + "name": "PRVDR_NUM", + "data_type": "VARCHAR", + "nullable": false, + "description": "PRVDR NUM" + }, + { + "name": "CLM_PMT_AMT", + "data_type": "VARCHAR", + "nullable": false, + "description": "CLM PMT AMT" + }, + { + "name": "NCH_PRMRY_PYR_CLM_PD_AMT", + "data_type": "VARCHAR", + "nullable": false, + "description": "NCH PRMRY PYR CLM PD AMT" + }, + { + "name": "AT_PHYSN_NPI", + "data_type": "VARCHAR", + "nullable": false, + "description": "AT PHYSN NPI" + }, + { + "name": "OP_PHYSN_NPI", + "data_type": "VARCHAR", + "nullable": false, + "description": "OP PHYSN NPI" + }, + { + "name": "OT_PHYSN_NPI", + "data_type": "VARCHAR", + "nullable": false, + "description": "OT PHYSN NPI" + }, + { + "name": "CLM_ADMSN_DT", + "data_type": "VARCHAR", + "nullable": false, + "description": "CLM ADMSN DT" + }, + { + "name": "ADMTNG_ICD9_DGNS_CD", + "data_type": "VARCHAR", + "nullable": false, + "description": "ADMTNG ICD9 DGNS CD" + }, + { + "name": "CLM_PASS_THRU_PER_DIEM_AMT", + "data_type": "VARCHAR", + "nullable": false, + "description": "CLM PASS THRU PER DIEM AMT" + }, + { + "name": "NCH_BENE_IP_DDCTBL_AMT", + "data_type": "VARCHAR", + "nullable": false, + "description": "NCH BENE IP DDCTBL AMT" + }, + { + "name": "NCH_BENE_PTA_COINSRNC_LBLTY_AM", + "data_type": "VARCHAR", + "nullable": false, + "description": "NCH BENE PTA COINSRNC LBLTY AM" + }, + { + "name": "NCH_BENE_BLOOD_DDCTBL_LBLTY_AM", + "data_type": "VARCHAR", + "nullable": false, + "description": "NCH BENE BLOOD DDCTBL LBLTY AM" + }, + { + "name": "CLM_UTLZTN_DAY_CNT", + "data_type": "VARCHAR", + "nullable": false, + "description": "CLM UTLZTN DAY CNT" + }, + { + "name": "NCH_BENE_DSCHRG_DT", + "data_type": "VARCHAR", + "nullable": false, + "description": "NCH BENE DSCHRG DT" + }, + { + "name": "CLM_DRG_CD", + "data_type": "VARCHAR", + "nullable": false, + "description": "CLM DRG CD" + }, + { + "name": "ICD9_DGNS_CD_1", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 1" + }, + { + "name": "ICD9_DGNS_CD_2", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 2" + }, + { + "name": "ICD9_DGNS_CD_3", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 3" + }, + { + "name": "ICD9_DGNS_CD_4", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 4" + }, + { + "name": "ICD9_DGNS_CD_5", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 5" + }, + { + "name": "ICD9_DGNS_CD_6", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 6" + }, + { + "name": "ICD9_DGNS_CD_7", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 7" + }, + { + "name": "ICD9_DGNS_CD_8", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 8" + }, + { + "name": "ICD9_DGNS_CD_9", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 9" + }, + { + "name": "ICD9_DGNS_CD_10", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 DGNS CD 10" + }, + { + "name": "ICD9_PRCDR_CD_1", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 PRCDR CD 1" + }, + { + "name": "ICD9_PRCDR_CD_2", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 PRCDR CD 2" + }, + { + "name": "ICD9_PRCDR_CD_3", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 PRCDR CD 3" + }, + { + "name": "ICD9_PRCDR_CD_4", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 PRCDR CD 4" + }, + { + "name": "ICD9_PRCDR_CD_5", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 PRCDR CD 5" + }, + { + "name": "ICD9_PRCDR_CD_6", + "data_type": "VARCHAR", + "nullable": false, + "description": "ICD9 PRCDR CD 6" + }, + { + "name": "HCPCS_CD_1", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 1" + }, + { + "name": "HCPCS_CD_2", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 2" + }, + { + "name": "HCPCS_CD_3", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 3" + }, + { + "name": "HCPCS_CD_4", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 4" + }, + { + "name": "HCPCS_CD_5", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 5" + }, + { + "name": "HCPCS_CD_6", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 6" + }, + { + "name": "HCPCS_CD_7", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 7" + }, + { + "name": "HCPCS_CD_8", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 8" + }, + { + "name": "HCPCS_CD_9", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 9" + }, + { + "name": "HCPCS_CD_10", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 10" + }, + { + "name": "HCPCS_CD_11", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 11" + }, + { + "name": "HCPCS_CD_12", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 12" + }, + { + "name": "HCPCS_CD_13", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 13" + }, + { + "name": "HCPCS_CD_14", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 14" + }, + { + "name": "HCPCS_CD_15", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 15" + }, + { + "name": "HCPCS_CD_16", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 16" + }, + { + "name": "HCPCS_CD_17", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 17" + }, + { + "name": "HCPCS_CD_18", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 18" + }, + { + "name": "HCPCS_CD_19", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 19" + }, + { + "name": "HCPCS_CD_20", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 20" + }, + { + "name": "HCPCS_CD_21", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 21" + }, + { + "name": "HCPCS_CD_22", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 22" + }, + { + "name": "HCPCS_CD_23", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 23" + }, + { + "name": "HCPCS_CD_24", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 24" + }, + { + "name": "HCPCS_CD_25", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 25" + }, + { + "name": "HCPCS_CD_26", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 26" + }, + { + "name": "HCPCS_CD_27", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 27" + }, + { + "name": "HCPCS_CD_28", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 28" + }, + { + "name": "HCPCS_CD_29", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 29" + }, + { + "name": "HCPCS_CD_30", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 30" + }, + { + "name": "HCPCS_CD_31", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 31" + }, + { + "name": "HCPCS_CD_32", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 32" + }, + { + "name": "HCPCS_CD_33", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 33" + }, + { + "name": "HCPCS_CD_34", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 34" + }, + { + "name": "HCPCS_CD_35", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 35" + }, + { + "name": "HCPCS_CD_36", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 36" + }, + { + "name": "HCPCS_CD_37", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 37" + }, + { + "name": "HCPCS_CD_38", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 38" + }, + { + "name": "HCPCS_CD_39", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 39" + }, + { + "name": "HCPCS_CD_40", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 40" + }, + { + "name": "HCPCS_CD_41", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 41" + }, + { + "name": "HCPCS_CD_42", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 42" + }, + { + "name": "HCPCS_CD_43", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 43" + }, + { + "name": "HCPCS_CD_44", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 44" + }, + { + "name": "HCPCS_CD_45", + "data_type": "VARCHAR", + "nullable": false, + "description": "HCPCS CD 45" + }, + { + "name": "native_record_number", + "data_type": "VARCHAR", + "nullable": false, + "description": "native record number" + }, + { + "name": "native_csv_record", + "data_type": "VARCHAR", + "nullable": false, + "description": "native csv record" + } + ], + "primary_key": [ + "CLM_ID", + "SEGMENT" + ], + "relationships": { + "foreign_keys": [ + { + "column": "DESYNPUF_ID", + "references_table": "cms_beneficiaries", + "references_column": "DESYNPUF_ID" + } + ] + } +} diff --git a/spec/domain-packs/medical-carrier/umf/coded_values.json b/spec/domain-packs/medical-carrier/umf/coded_values.json index 829f102ad..8a7c96bf9 100644 --- a/spec/domain-packs/medical-carrier/umf/coded_values.json +++ b/spec/domain-packs/medical-carrier/umf/coded_values.json @@ -1,7 +1,7 @@ { "version": "1.0", "table_name": "coded_values", - "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", "columns": [ { "name": "coding_key", diff --git a/spec/domain-packs/medical-carrier/umf/coverage.json b/spec/domain-packs/medical-carrier/umf/coverage.json index acb15da88..7ae6b2644 100644 --- a/spec/domain-packs/medical-carrier/umf/coverage.json +++ b/spec/domain-packs/medical-carrier/umf/coverage.json @@ -1,7 +1,7 @@ { "version": "1.0", "table_name": "coverage", - "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", "columns": [ { "name": "resource_key", diff --git a/spec/domain-packs/medical-carrier/umf/eligibility.json b/spec/domain-packs/medical-carrier/umf/eligibility.json index 2190d3b20..bf568773d 100644 --- a/spec/domain-packs/medical-carrier/umf/eligibility.json +++ b/spec/domain-packs/medical-carrier/umf/eligibility.json @@ -1,7 +1,7 @@ { "version": "1.0", "table_name": "eligibility", - "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", "columns": [ { "name": "resource_key", diff --git a/spec/domain-packs/medical-carrier/umf/enrollments.json b/spec/domain-packs/medical-carrier/umf/enrollments.json index afca9b666..84c53eee4 100644 --- a/spec/domain-packs/medical-carrier/umf/enrollments.json +++ b/spec/domain-packs/medical-carrier/umf/enrollments.json @@ -1,7 +1,7 @@ { "version": "1.0", "table_name": "enrollments", - "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", "columns": [ { "name": "resource_key", diff --git a/spec/domain-packs/medical-carrier/umf/payments.json b/spec/domain-packs/medical-carrier/umf/payments.json index c419c8925..1f4d703c1 100644 --- a/spec/domain-packs/medical-carrier/umf/payments.json +++ b/spec/domain-packs/medical-carrier/umf/payments.json @@ -1,7 +1,7 @@ { "version": "1.0", "table_name": "payments", - "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", "columns": [ { "name": "payment_key", diff --git a/spec/domain-packs/medical-carrier/umf/plans.json b/spec/domain-packs/medical-carrier/umf/plans.json index f562be768..d589c4631 100644 --- a/spec/domain-packs/medical-carrier/umf/plans.json +++ b/spec/domain-packs/medical-carrier/umf/plans.json @@ -1,7 +1,7 @@ { "version": "1.0", "table_name": "plans", - "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", "columns": [ { "name": "resource_key", diff --git a/spec/domain-packs/medical-carrier/umf/resource_references.json b/spec/domain-packs/medical-carrier/umf/resource_references.json index a5f67f3a7..66cd05687 100644 --- a/spec/domain-packs/medical-carrier/umf/resource_references.json +++ b/spec/domain-packs/medical-carrier/umf/resource_references.json @@ -1,7 +1,7 @@ { "version": "1.0", "table_name": "resource_references", - "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", "columns": [ { "name": "reference_key", diff --git a/spec/domain-packs/medical-carrier/umf/resources.json b/spec/domain-packs/medical-carrier/umf/resources.json index 8945f5408..e887e228f 100644 --- a/spec/domain-packs/medical-carrier/umf/resources.json +++ b/spec/domain-packs/medical-carrier/umf/resources.json @@ -1,7 +1,7 @@ { "version": "1.0", "table_name": "resources", - "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", "columns": [ { "name": "resource_key", diff --git a/spec/domain-packs/medical-carrier/umf/workflow_events.json b/spec/domain-packs/medical-carrier/umf/workflow_events.json index 50ca433c2..8f9bb2599 100644 --- a/spec/domain-packs/medical-carrier/umf/workflow_events.json +++ b/spec/domain-packs/medical-carrier/umf/workflow_events.json @@ -1,7 +1,7 @@ { "version": "1.0", "table_name": "workflow_events", - "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events.", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 9 unchanged official HL7 carrier resources and 19 authored supplemental FHIR-shaped resources, plus four workflow events; 13 unchanged CMS DE-SynPUF native CSV records (three beneficiaries, five inpatient and five carrier claims).", "columns": [ { "name": "event_key", diff --git a/spec/domain-packs/medical-epidemiology/README.md b/spec/domain-packs/medical-epidemiology/README.md index e64cccd52..fb6a4ef56 100644 --- a/spec/domain-packs/medical-epidemiology/README.md +++ b/spec/domain-packs/medical-epidemiology/README.md @@ -1,4 +1,4 @@ -# medical-epidemiology 1.0.0 +# medical-epidemiology 1.1.0 12 CDC/NCHS leading-causes-of-death aggregate records and two separate fabricated zero/suppression cases. diff --git a/spec/domain-packs/medical-epidemiology/ontology.json b/spec/domain-packs/medical-epidemiology/ontology.json new file mode 100644 index 000000000..c03379d84 --- /dev/null +++ b/spec/domain-packs/medical-epidemiology/ontology.json @@ -0,0 +1,565 @@ +{ + "umf": "0.8.0", + "id": "urn:umf:domain:medical-epidemiology", + "title": "medical-epidemiology ontology", + "vocabularies": {}, + "modules": [ + { + "id": "domain", + "namespace": "urn:umf:domain:medical-epidemiology:", + "elements": [ + { + "id": "measures", + "kind": "record", + "name": "measures", + "title": "measures", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 12 CDC/NCHS leading-causes-of-death aggregate records and two separate fabricated zero/suppression cases.", + "members": [ + { + "module": "domain", + "element": "measures.measure_key" + }, + { + "module": "domain", + "element": "measures.source_id" + }, + { + "module": "domain", + "element": "measures.year" + }, + { + "module": "domain", + "element": "measures.geography" + }, + { + "module": "domain", + "element": "measures.geography_vintage" + }, + { + "module": "domain", + "element": "measures.cause" + }, + { + "module": "domain", + "element": "measures.case_definition" + }, + { + "module": "domain", + "element": "measures.measure" + }, + { + "module": "domain", + "element": "measures.count" + }, + { + "module": "domain", + "element": "measures.count_status" + }, + { + "module": "domain", + "element": "measures.adjusted_rate" + }, + { + "module": "domain", + "element": "measures.rate_status" + }, + { + "module": "domain", + "element": "measures.rate_unit" + }, + { + "module": "domain", + "element": "measures.adjustment" + }, + { + "module": "domain", + "element": "measures.population_denominator" + }, + { + "module": "domain", + "element": "measures.denominator_status" + }, + { + "module": "domain", + "element": "measures.uncertainty_json" + }, + { + "module": "domain", + "element": "measures.native_json" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "measures.measure_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "measures.measure_key", + "name": "measure_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "measure key", + "extensions": {} + }, + { + "id": "measures.source_id", + "name": "source_id", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "source id", + "extensions": {} + }, + { + "id": "measures.year", + "name": "year", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "year", + "extensions": {} + }, + { + "id": "measures.geography", + "name": "geography", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "geography", + "extensions": {} + }, + { + "id": "measures.geography_vintage", + "name": "geography_vintage", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "geography vintage", + "extensions": {} + }, + { + "id": "measures.cause", + "name": "cause", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "cause", + "extensions": {} + }, + { + "id": "measures.case_definition", + "name": "case_definition", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "case definition", + "extensions": {} + }, + { + "id": "measures.measure", + "name": "measure", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "measure", + "extensions": {} + }, + { + "id": "measures.count", + "name": "count", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "count", + "extensions": {} + }, + { + "id": "measures.count_status", + "name": "count_status", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "count status", + "extensions": {} + }, + { + "id": "measures.adjusted_rate", + "name": "adjusted_rate", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "adjusted rate", + "extensions": {} + }, + { + "id": "measures.rate_status", + "name": "rate_status", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "rate status", + "extensions": {} + }, + { + "id": "measures.rate_unit", + "name": "rate_unit", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "rate unit", + "extensions": {} + }, + { + "id": "measures.adjustment", + "name": "adjustment", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "adjustment", + "extensions": {} + }, + { + "id": "measures.population_denominator", + "name": "population_denominator", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "population denominator", + "extensions": {} + }, + { + "id": "measures.denominator_status", + "name": "denominator_status", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "denominator status", + "extensions": {} + }, + { + "id": "measures.uncertainty_json", + "name": "uncertainty_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "uncertainty json", + "extensions": {} + }, + { + "id": "measures.native_json", + "name": "native_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native json", + "extensions": {} + }, + { + "id": "supplemental_measures", + "kind": "record", + "name": "supplemental_measures", + "title": "supplemental_measures", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 12 CDC/NCHS leading-causes-of-death aggregate records and two separate fabricated zero/suppression cases.", + "members": [ + { + "module": "domain", + "element": "supplemental_measures.measure_key" + }, + { + "module": "domain", + "element": "supplemental_measures.source_id" + }, + { + "module": "domain", + "element": "supplemental_measures.year" + }, + { + "module": "domain", + "element": "supplemental_measures.geography" + }, + { + "module": "domain", + "element": "supplemental_measures.geography_vintage" + }, + { + "module": "domain", + "element": "supplemental_measures.cause" + }, + { + "module": "domain", + "element": "supplemental_measures.case_definition" + }, + { + "module": "domain", + "element": "supplemental_measures.measure" + }, + { + "module": "domain", + "element": "supplemental_measures.count" + }, + { + "module": "domain", + "element": "supplemental_measures.count_status" + }, + { + "module": "domain", + "element": "supplemental_measures.adjusted_rate" + }, + { + "module": "domain", + "element": "supplemental_measures.rate_status" + }, + { + "module": "domain", + "element": "supplemental_measures.rate_unit" + }, + { + "module": "domain", + "element": "supplemental_measures.adjustment" + }, + { + "module": "domain", + "element": "supplemental_measures.population_denominator" + }, + { + "module": "domain", + "element": "supplemental_measures.denominator_status" + }, + { + "module": "domain", + "element": "supplemental_measures.uncertainty_json" + }, + { + "module": "domain", + "element": "supplemental_measures.native_json" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "supplemental_measures.measure_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "supplemental_measures.measure_key", + "name": "measure_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "measure key", + "extensions": {} + }, + { + "id": "supplemental_measures.source_id", + "name": "source_id", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "source id", + "extensions": {} + }, + { + "id": "supplemental_measures.year", + "name": "year", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "year", + "extensions": {} + }, + { + "id": "supplemental_measures.geography", + "name": "geography", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "geography", + "extensions": {} + }, + { + "id": "supplemental_measures.geography_vintage", + "name": "geography_vintage", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "geography vintage", + "extensions": {} + }, + { + "id": "supplemental_measures.cause", + "name": "cause", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "cause", + "extensions": {} + }, + { + "id": "supplemental_measures.case_definition", + "name": "case_definition", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "case definition", + "extensions": {} + }, + { + "id": "supplemental_measures.measure", + "name": "measure", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "measure", + "extensions": {} + }, + { + "id": "supplemental_measures.count", + "name": "count", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "count", + "extensions": {} + }, + { + "id": "supplemental_measures.count_status", + "name": "count_status", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "count status", + "extensions": {} + }, + { + "id": "supplemental_measures.adjusted_rate", + "name": "adjusted_rate", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "adjusted rate", + "extensions": {} + }, + { + "id": "supplemental_measures.rate_status", + "name": "rate_status", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "rate status", + "extensions": {} + }, + { + "id": "supplemental_measures.rate_unit", + "name": "rate_unit", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "rate unit", + "extensions": {} + }, + { + "id": "supplemental_measures.adjustment", + "name": "adjustment", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "adjustment", + "extensions": {} + }, + { + "id": "supplemental_measures.population_denominator", + "name": "population_denominator", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "population denominator", + "extensions": {} + }, + { + "id": "supplemental_measures.denominator_status", + "name": "denominator_status", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "denominator status", + "extensions": {} + }, + { + "id": "supplemental_measures.uncertainty_json", + "name": "uncertainty_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "uncertainty json", + "extensions": {} + }, + { + "id": "supplemental_measures.native_json", + "name": "native_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native json", + "extensions": {} + } + ], + "relationships": [] + } + ] +} diff --git a/spec/domain-packs/medical-epidemiology/pack.json b/spec/domain-packs/medical-epidemiology/pack.json index db1a932b4..8cbde960a 100644 --- a/spec/domain-packs/medical-epidemiology/pack.json +++ b/spec/domain-packs/medical-epidemiology/pack.json @@ -1,6 +1,33 @@ { "id": "medical-epidemiology", - "version": "1.0.0", + "version": "1.1.0", + "family": { + "id": "medical", + "version": "1.1.0", + "label": "Epidemiology" + }, + "execution_profile": { + "version": "1.0.0", + "targets": { + "tabular": [ + "measures", + "supplemental_measures" + ], + "graph": [ + "ontology" + ] + }, + "mode": "fixed", + "include_sources": [ + "cdc", + "cdc_metadata", + "supplement", + "notices", + "csv_measures", + "csv_supplemental_measures" + ], + "qualification": "Fixed source-qualified sample rows and schema-only ontology. No data generation, clinical conformance or graph-storage execution claim." + }, "description": "Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.", "domain_types": { "source_qualified_identity": { @@ -20,6 +47,11 @@ "id": "supplemental_measures", "format": "tablespec", "reference": "umf/supplemental_measures.json" + }, + { + "id": "ontology", + "format": "umf", + "reference": "ontology.json" } ], "sources": { @@ -122,7 +154,7 @@ "data_kind": "observed", "reference": "data/measures.csv", "format": "csv", - "revision": "medical-epidemiology-1.0.0", + "revision": "medical-epidemiology-1.1.0", "checksum": { "algorithm": "sha256", "value": "be23947804729c7a64bb5b5d0071a20e5bba619d27cfaa5504188482969f71ab" @@ -147,7 +179,7 @@ "data_kind": "fabricated", "reference": "data/supplemental_measures.csv", "format": "csv", - "revision": "medical-epidemiology-1.0.0", + "revision": "medical-epidemiology-1.1.0", "checksum": { "algorithm": "sha256", "value": "05cd03ec8cf05416a2cf296b5272b0540bd87ffd0e44cfc6399c1f93524de415" diff --git a/spec/domain-packs/medical-imaging/README.md b/spec/domain-packs/medical-imaging/README.md index 144f298aa..331336e28 100644 --- a/spec/domain-packs/medical-imaging/README.md +++ b/spec/domain-packs/medical-imaging/README.md @@ -1,8 +1,8 @@ -# medical-imaging 1.0.0 +# medical-imaging 1.1.0 -One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence. +One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence; one unchanged public TCIA LIDC-IDRI CT slice with publisher-deidentified source identity. -Native metadata and original binary retention only. No public patient images, pixel decoding, full IOD conformance, DICOMweb or live PACS operations. TCIA remains a collection-specific rights/access candidate; no TCIA bytes are bundled. +Native metadata and original binary retention only. The public CT slice is an incomplete 1/133-series selection, not a full study. Its source DICOM edition is unknown; pydicom 3.0.2 JSON inspection is the tested profile. No independent deidentification certification, pixel decoding, full IOD conformance, DICOMweb or live PACS operations. Use the shared `export-domain-pack.ts --include-sources` command with this pack, then TableSpec `sample-data ingest`. Sources and schemas are local and checksum-pinned. Remote/licensed references remain metadata. diff --git a/spec/domain-packs/medical-imaging/data/attributes.csv b/spec/domain-packs/medical-imaging/data/attributes.csv index 2df7ea1f2..433fe749f 100644 --- a/spec/domain-packs/medical-imaging/data/attributes.csv +++ b/spec/domain-packs/medical-imaging/data/attributes.csv @@ -23,3 +23,92 @@ synthetic-dicom/00111001,synthetic-dicom,/00111001,00111001,LO,"[""unknown priva synthetic-dicom/00111010,synthetic-dicom,/00111010,00111010,SQ,"[{""00110010"":{""vr"":""LO"",""Value"":[""UMF_SYNTHETIC""]},""00111002"":{""vr"":""DS"",""Value"":[1.25,2.5]}}]",\N,\N,"{""vr"":""SQ"",""Value"":[{""00110010"":{""vr"":""LO"",""Value"":[""UMF_SYNTHETIC""]},""00111002"":{""vr"":""DS"",""Value"":[1.25,2.5]}}]}" synthetic-dicom/00111010/Value/0/00110010,synthetic-dicom,/00111010/Value/0/00110010,00110010,LO,"[""UMF_SYNTHETIC""]",\N,\N,"{""vr"":""LO"",""Value"":[""UMF_SYNTHETIC""]}" synthetic-dicom/00111010/Value/0/00111002,synthetic-dicom,/00111010/Value/0/00111002,00111002,DS,"[1.25,2.5]",\N,\N,"{""vr"":""DS"",""Value"":[1.25,2.5]}" +tcia-lidc-0001-ct/00080005,tcia-lidc-0001-ct,/00080005,00080005,CS,"[""ISO_IR 100""]",\N,\N,"{""vr"":""CS"",""Value"":[""ISO_IR 100""]}" +tcia-lidc-0001-ct/00080008,tcia-lidc-0001-ct,/00080008,00080008,CS,"[""ORIGINAL"",""PRIMARY"",""AXIAL""]",\N,\N,"{""vr"":""CS"",""Value"":[""ORIGINAL"",""PRIMARY"",""AXIAL""]}" +tcia-lidc-0001-ct/00080016,tcia-lidc-0001-ct,/00080016,00080016,UI,"[""1.2.840.10008.5.1.4.1.1.2""]",\N,\N,"{""vr"":""UI"",""Value"":[""1.2.840.10008.5.1.4.1.1.2""]}" +tcia-lidc-0001-ct/00080018,tcia-lidc-0001-ct,/00080018,00080018,UI,"[""1.3.6.1.4.1.14519.5.2.1.6279.6001.143451261327128179989900675595""]",\N,\N,"{""vr"":""UI"",""Value"":[""1.3.6.1.4.1.14519.5.2.1.6279.6001.143451261327128179989900675595""]}" +tcia-lidc-0001-ct/00080020,tcia-lidc-0001-ct,/00080020,00080020,DA,"[""20000101""]",\N,\N,"{""vr"":""DA"",""Value"":[""20000101""]}" +tcia-lidc-0001-ct/00080021,tcia-lidc-0001-ct,/00080021,00080021,DA,"[""20000101""]",\N,\N,"{""vr"":""DA"",""Value"":[""20000101""]}" +tcia-lidc-0001-ct/00080022,tcia-lidc-0001-ct,/00080022,00080022,DA,"[""20000101""]",\N,\N,"{""vr"":""DA"",""Value"":[""20000101""]}" +tcia-lidc-0001-ct/00080023,tcia-lidc-0001-ct,/00080023,00080023,DA,"[""20000101""]",\N,\N,"{""vr"":""DA"",""Value"":[""20000101""]}" +tcia-lidc-0001-ct/00080024,tcia-lidc-0001-ct,/00080024,00080024,DA,"[""20000101""]",\N,\N,"{""vr"":""DA"",""Value"":[""20000101""]}" +tcia-lidc-0001-ct/00080025,tcia-lidc-0001-ct,/00080025,00080025,DA,"[""20000101""]",\N,\N,"{""vr"":""DA"",""Value"":[""20000101""]}" +tcia-lidc-0001-ct/0008002A,tcia-lidc-0001-ct,/0008002A,0008002A,DT,"[""20000101""]",\N,\N,"{""vr"":""DT"",""Value"":[""20000101""]}" +tcia-lidc-0001-ct/00080030,tcia-lidc-0001-ct,/00080030,00080030,TM,\N,\N,\N,"{""vr"":""TM""}" +tcia-lidc-0001-ct/00080032,tcia-lidc-0001-ct,/00080032,00080032,TM,\N,\N,\N,"{""vr"":""TM""}" +tcia-lidc-0001-ct/00080033,tcia-lidc-0001-ct,/00080033,00080033,TM,\N,\N,\N,"{""vr"":""TM""}" +tcia-lidc-0001-ct/00080050,tcia-lidc-0001-ct,/00080050,00080050,SH,\N,\N,\N,"{""vr"":""SH""}" +tcia-lidc-0001-ct/00080060,tcia-lidc-0001-ct,/00080060,00080060,CS,"[""CT""]",\N,\N,"{""vr"":""CS"",""Value"":[""CT""]}" +tcia-lidc-0001-ct/00080070,tcia-lidc-0001-ct,/00080070,00080070,LO,"[""GE MEDICAL SYSTEMS""]",\N,\N,"{""vr"":""LO"",""Value"":[""GE MEDICAL SYSTEMS""]}" +tcia-lidc-0001-ct/00080090,tcia-lidc-0001-ct,/00080090,00080090,PN,\N,\N,\N,"{""vr"":""PN""}" +tcia-lidc-0001-ct/00081090,tcia-lidc-0001-ct,/00081090,00081090,LO,"[""LightSpeed Plus""]",\N,\N,"{""vr"":""LO"",""Value"":[""LightSpeed Plus""]}" +tcia-lidc-0001-ct/00081155,tcia-lidc-0001-ct,/00081155,00081155,UI,"[""1.3.6.1.4.1.14519.5.2.1.6279.6001.675906998158803995297223798692""]",\N,\N,"{""vr"":""UI"",""Value"":[""1.3.6.1.4.1.14519.5.2.1.6279.6001.675906998158803995297223798692""]}" +tcia-lidc-0001-ct/00100010,tcia-lidc-0001-ct,/00100010,00100010,PN,\N,\N,\N,"{""vr"":""PN""}" +tcia-lidc-0001-ct/00100020,tcia-lidc-0001-ct,/00100020,00100020,LO,"[""LIDC-IDRI-0001""]",\N,\N,"{""vr"":""LO"",""Value"":[""LIDC-IDRI-0001""]}" +tcia-lidc-0001-ct/00100030,tcia-lidc-0001-ct,/00100030,00100030,DA,\N,\N,\N,"{""vr"":""DA""}" +tcia-lidc-0001-ct/00100040,tcia-lidc-0001-ct,/00100040,00100040,CS,\N,\N,\N,"{""vr"":""CS""}" +tcia-lidc-0001-ct/00101010,tcia-lidc-0001-ct,/00101010,00101010,AS,\N,\N,\N,"{""vr"":""AS""}" +tcia-lidc-0001-ct/001021D0,tcia-lidc-0001-ct,/001021D0,001021D0,DA,"[""20000101""]",\N,\N,"{""vr"":""DA"",""Value"":[""20000101""]}" +tcia-lidc-0001-ct/00120062,tcia-lidc-0001-ct,/00120062,00120062,CS,"[""YES""]",\N,\N,"{""vr"":""CS"",""Value"":[""YES""]}" +tcia-lidc-0001-ct/00120063,tcia-lidc-0001-ct,/00120063,00120063,LO,"[""DCM:113100/113105/113107/113108/113109/113111""]",\N,\N,"{""vr"":""LO"",""Value"":[""DCM:113100/113105/113107/113108/113109/113111""]}" +tcia-lidc-0001-ct/00130010,tcia-lidc-0001-ct,/00130010,00130010,LO,"[""CTP""]",\N,\N,"{""vr"":""LO"",""Value"":[""CTP""]}" +tcia-lidc-0001-ct/00131010,tcia-lidc-0001-ct,/00131010,00131010,LO,"[""LIDC-IDRI""]",\N,\N,"{""vr"":""LO"",""Value"":[""LIDC-IDRI""]}" +tcia-lidc-0001-ct/00131013,tcia-lidc-0001-ct,/00131013,00131013,LO,"[""62796001""]",\N,\N,"{""vr"":""LO"",""Value"":[""62796001""]}" +tcia-lidc-0001-ct/00180010,tcia-lidc-0001-ct,/00180010,00180010,LO,"[""IV""]",\N,\N,"{""vr"":""LO"",""Value"":[""IV""]}" +tcia-lidc-0001-ct/00180015,tcia-lidc-0001-ct,/00180015,00180015,CS,"[""CHEST""]",\N,\N,"{""vr"":""CS"",""Value"":[""CHEST""]}" +tcia-lidc-0001-ct/00180022,tcia-lidc-0001-ct,/00180022,00180022,CS,"[""HELICAL MODE""]",\N,\N,"{""vr"":""CS"",""Value"":[""HELICAL MODE""]}" +tcia-lidc-0001-ct/00180050,tcia-lidc-0001-ct,/00180050,00180050,DS,[2.5],\N,\N,"{""vr"":""DS"",""Value"":[2.5]}" +tcia-lidc-0001-ct/00180060,tcia-lidc-0001-ct,/00180060,00180060,DS,[120.0],\N,\N,"{""vr"":""DS"",""Value"":[120.0]}" +tcia-lidc-0001-ct/00180090,tcia-lidc-0001-ct,/00180090,00180090,DS,[500.0],\N,\N,"{""vr"":""DS"",""Value"":[500.0]}" +tcia-lidc-0001-ct/00181020,tcia-lidc-0001-ct,/00181020,00181020,LO,"[""LightSpeedApps2.4.2_H2.4M5""]",\N,\N,"{""vr"":""LO"",""Value"":[""LightSpeedApps2.4.2_H2.4M5""]}" +tcia-lidc-0001-ct/00181100,tcia-lidc-0001-ct,/00181100,00181100,DS,[360.0],\N,\N,"{""vr"":""DS"",""Value"":[360.0]}" +tcia-lidc-0001-ct/00181110,tcia-lidc-0001-ct,/00181110,00181110,DS,[949.075012],\N,\N,"{""vr"":""DS"",""Value"":[949.075012]}" +tcia-lidc-0001-ct/00181111,tcia-lidc-0001-ct,/00181111,00181111,DS,[541.0],\N,\N,"{""vr"":""DS"",""Value"":[541.0]}" +tcia-lidc-0001-ct/00181120,tcia-lidc-0001-ct,/00181120,00181120,DS,[0.0],\N,\N,"{""vr"":""DS"",""Value"":[0.0]}" +tcia-lidc-0001-ct/00181130,tcia-lidc-0001-ct,/00181130,00181130,DS,[144.399994],\N,\N,"{""vr"":""DS"",""Value"":[144.399994]}" +tcia-lidc-0001-ct/00181140,tcia-lidc-0001-ct,/00181140,00181140,CS,"[""CW""]",\N,\N,"{""vr"":""CS"",""Value"":[""CW""]}" +tcia-lidc-0001-ct/00181150,tcia-lidc-0001-ct,/00181150,00181150,IS,[570],\N,\N,"{""vr"":""IS"",""Value"":[570]}" +tcia-lidc-0001-ct/00181151,tcia-lidc-0001-ct,/00181151,00181151,IS,[400],\N,\N,"{""vr"":""IS"",""Value"":[400]}" +tcia-lidc-0001-ct/00181152,tcia-lidc-0001-ct,/00181152,00181152,IS,[4684],\N,\N,"{""vr"":""IS"",""Value"":[4684]}" +tcia-lidc-0001-ct/00181160,tcia-lidc-0001-ct,/00181160,00181160,SH,"[""BODY FILTER""]",\N,\N,"{""vr"":""SH"",""Value"":[""BODY FILTER""]}" +tcia-lidc-0001-ct/00181170,tcia-lidc-0001-ct,/00181170,00181170,IS,[48000],\N,\N,"{""vr"":""IS"",""Value"":[48000]}" +tcia-lidc-0001-ct/00181190,tcia-lidc-0001-ct,/00181190,00181190,DS,[1.2],\N,\N,"{""vr"":""DS"",""Value"":[1.2]}" +tcia-lidc-0001-ct/00181210,tcia-lidc-0001-ct,/00181210,00181210,SH,"[""STANDARD""]",\N,\N,"{""vr"":""SH"",""Value"":[""STANDARD""]}" +tcia-lidc-0001-ct/00185100,tcia-lidc-0001-ct,/00185100,00185100,CS,"[""FFS""]",\N,\N,"{""vr"":""CS"",""Value"":[""FFS""]}" +tcia-lidc-0001-ct/0020000D,tcia-lidc-0001-ct,/0020000D,0020000D,UI,"[""1.3.6.1.4.1.14519.5.2.1.6279.6001.298806137288633453246975630178""]",\N,\N,"{""vr"":""UI"",""Value"":[""1.3.6.1.4.1.14519.5.2.1.6279.6001.298806137288633453246975630178""]}" +tcia-lidc-0001-ct/0020000E,tcia-lidc-0001-ct,/0020000E,0020000E,UI,"[""1.3.6.1.4.1.14519.5.2.1.6279.6001.179049373636438705059720603192""]",\N,\N,"{""vr"":""UI"",""Value"":[""1.3.6.1.4.1.14519.5.2.1.6279.6001.179049373636438705059720603192""]}" +tcia-lidc-0001-ct/00200010,tcia-lidc-0001-ct,/00200010,00200010,SH,\N,\N,\N,"{""vr"":""SH""}" +tcia-lidc-0001-ct/00200011,tcia-lidc-0001-ct,/00200011,00200011,IS,[3000566],\N,\N,"{""vr"":""IS"",""Value"":[3000566]}" +tcia-lidc-0001-ct/00200013,tcia-lidc-0001-ct,/00200013,00200013,IS,[80],\N,\N,"{""vr"":""IS"",""Value"":[80]}" +tcia-lidc-0001-ct/00200032,tcia-lidc-0001-ct,/00200032,00200032,DS,"[-166.0,-171.699997,-207.5]",\N,\N,"{""vr"":""DS"",""Value"":[-166.0,-171.699997,-207.5]}" +tcia-lidc-0001-ct/00200037,tcia-lidc-0001-ct,/00200037,00200037,DS,"[1.0,0.0,0.0,0.0,1.0,0.0]",\N,\N,"{""vr"":""DS"",""Value"":[1.0,0.0,0.0,0.0,1.0,0.0]}" +tcia-lidc-0001-ct/00200052,tcia-lidc-0001-ct,/00200052,00200052,UI,"[""1.3.6.1.4.1.14519.5.2.1.6279.6001.229925374658226729607867499499""]",\N,\N,"{""vr"":""UI"",""Value"":[""1.3.6.1.4.1.14519.5.2.1.6279.6001.229925374658226729607867499499""]}" +tcia-lidc-0001-ct/00201040,tcia-lidc-0001-ct,/00201040,00201040,LO,"[""SN""]",\N,\N,"{""vr"":""LO"",""Value"":[""SN""]}" +tcia-lidc-0001-ct/00201041,tcia-lidc-0001-ct,/00201041,00201041,DS,[-207.5],\N,\N,"{""vr"":""DS"",""Value"":[-207.5]}" +tcia-lidc-0001-ct/00280002,tcia-lidc-0001-ct,/00280002,00280002,US,[1],\N,\N,"{""vr"":""US"",""Value"":[1]}" +tcia-lidc-0001-ct/00280004,tcia-lidc-0001-ct,/00280004,00280004,CS,"[""MONOCHROME2""]",\N,\N,"{""vr"":""CS"",""Value"":[""MONOCHROME2""]}" +tcia-lidc-0001-ct/00280010,tcia-lidc-0001-ct,/00280010,00280010,US,[512],\N,\N,"{""vr"":""US"",""Value"":[512]}" +tcia-lidc-0001-ct/00280011,tcia-lidc-0001-ct,/00280011,00280011,US,[512],\N,\N,"{""vr"":""US"",""Value"":[512]}" +tcia-lidc-0001-ct/00280030,tcia-lidc-0001-ct,/00280030,00280030,DS,"[0.703125,0.703125]",\N,\N,"{""vr"":""DS"",""Value"":[0.703125,0.703125]}" +tcia-lidc-0001-ct/00280100,tcia-lidc-0001-ct,/00280100,00280100,US,[16],\N,\N,"{""vr"":""US"",""Value"":[16]}" +tcia-lidc-0001-ct/00280101,tcia-lidc-0001-ct,/00280101,00280101,US,[16],\N,\N,"{""vr"":""US"",""Value"":[16]}" +tcia-lidc-0001-ct/00280102,tcia-lidc-0001-ct,/00280102,00280102,US,[15],\N,\N,"{""vr"":""US"",""Value"":[15]}" +tcia-lidc-0001-ct/00280103,tcia-lidc-0001-ct,/00280103,00280103,US,[1],\N,\N,"{""vr"":""US"",""Value"":[1]}" +tcia-lidc-0001-ct/00280120,tcia-lidc-0001-ct,/00280120,00280120,US,[63536],\N,\N,"{""vr"":""US"",""Value"":[63536]}" +tcia-lidc-0001-ct/00280303,tcia-lidc-0001-ct,/00280303,00280303,CS,"[""MODIFIED""]",\N,\N,"{""vr"":""CS"",""Value"":[""MODIFIED""]}" +tcia-lidc-0001-ct/00281050,tcia-lidc-0001-ct,/00281050,00281050,DS,[-600.0],\N,\N,"{""vr"":""DS"",""Value"":[-600.0]}" +tcia-lidc-0001-ct/00281051,tcia-lidc-0001-ct,/00281051,00281051,DS,[1600.0],\N,\N,"{""vr"":""DS"",""Value"":[1600.0]}" +tcia-lidc-0001-ct/00281052,tcia-lidc-0001-ct,/00281052,00281052,DS,[-1024.0],\N,\N,"{""vr"":""DS"",""Value"":[-1024.0]}" +tcia-lidc-0001-ct/00281053,tcia-lidc-0001-ct,/00281053,00281053,DS,[1.0],\N,\N,"{""vr"":""DS"",""Value"":[1.0]}" +tcia-lidc-0001-ct/00380020,tcia-lidc-0001-ct,/00380020,00380020,DA,"[""20000101""]",\N,\N,"{""vr"":""DA"",""Value"":[""20000101""]}" +tcia-lidc-0001-ct/00400002,tcia-lidc-0001-ct,/00400002,00400002,DA,"[""20000101""]",\N,\N,"{""vr"":""DA"",""Value"":[""20000101""]}" +tcia-lidc-0001-ct/00400004,tcia-lidc-0001-ct,/00400004,00400004,DA,"[""20000101""]",\N,\N,"{""vr"":""DA"",""Value"":[""20000101""]}" +tcia-lidc-0001-ct/00400244,tcia-lidc-0001-ct,/00400244,00400244,DA,"[""20000101""]",\N,\N,"{""vr"":""DA"",""Value"":[""20000101""]}" +tcia-lidc-0001-ct/00402016,tcia-lidc-0001-ct,/00402016,00402016,LO,\N,\N,\N,"{""vr"":""LO""}" +tcia-lidc-0001-ct/00402017,tcia-lidc-0001-ct,/00402017,00402017,LO,\N,\N,\N,"{""vr"":""LO""}" +tcia-lidc-0001-ct/0040A075,tcia-lidc-0001-ct,/0040A075,0040A075,PN,"[{""Alphabetic"":""Removed by CTP""}]",\N,\N,"{""vr"":""PN"",""Value"":[{""Alphabetic"":""Removed by CTP""}]}" +tcia-lidc-0001-ct/0040A123,tcia-lidc-0001-ct,/0040A123,0040A123,PN,"[{""Alphabetic"":""Removed by CTP""}]",\N,\N,"{""vr"":""PN"",""Value"":[{""Alphabetic"":""Removed by CTP""}]}" +tcia-lidc-0001-ct/0040A124,tcia-lidc-0001-ct,/0040A124,0040A124,UI,"[""1.3.6.1.4.1.14519.5.2.1.6279.6001.335419887712224178340067932923""]",\N,\N,"{""vr"":""UI"",""Value"":[""1.3.6.1.4.1.14519.5.2.1.6279.6001.335419887712224178340067932923""]}" +tcia-lidc-0001-ct/00700084,tcia-lidc-0001-ct,/00700084,00700084,PN,\N,\N,\N,"{""vr"":""PN""}" +tcia-lidc-0001-ct/00880140,tcia-lidc-0001-ct,/00880140,00880140,UI,"[""1.3.6.1.4.1.14519.5.2.1.6279.6001.211790042620307056609660772296""]",\N,\N,"{""vr"":""UI"",""Value"":[""1.3.6.1.4.1.14519.5.2.1.6279.6001.211790042620307056609660772296""]}" +tcia-lidc-0001-ct/7FE00010,tcia-lidc-0001-ct,/7FE00010,7FE00010,OW,\N,sources/tcia-lidc-0001-ct.dcm#tag-7FE00010,\N,"{""vr"":""OW"",""BulkDataURI"":""sources/tcia-lidc-0001-ct.dcm#tag-7FE00010""}" diff --git a/spec/domain-packs/medical-imaging/data/instances.csv b/spec/domain-packs/medical-imaging/data/instances.csv index a2a42f46f..cfb54c671 100644 --- a/spec/domain-packs/medical-imaging/data/instances.csv +++ b/spec/domain-packs/medical-imaging/data/instances.csv @@ -148,3 +148,513 @@ synthetic-dicom,synthetic-dicom,2.25.555010,2.25.555020,2.25.555001,1.2.840.1000 } } ",sources/synthetic.dcm,54f23548d26d998a92fac698f829f330d19bf8633bab848a5b33da5710e1db1d,1.2.840.10008.1.2.1 +tcia-lidc-0001-ct,tcia-lidc-0001-ct,1.3.6.1.4.1.14519.5.2.1.6279.6001.298806137288633453246975630178,1.3.6.1.4.1.14519.5.2.1.6279.6001.179049373636438705059720603192,1.3.6.1.4.1.14519.5.2.1.6279.6001.143451261327128179989900675595,1.2.840.10008.5.1.4.1.1.2,CT,"{ + ""00080005"": { + ""vr"": ""CS"", + ""Value"": [ + ""ISO_IR 100"" + ] + }, + ""00080008"": { + ""vr"": ""CS"", + ""Value"": [ + ""ORIGINAL"", + ""PRIMARY"", + ""AXIAL"" + ] + }, + ""00080016"": { + ""vr"": ""UI"", + ""Value"": [ + ""1.2.840.10008.5.1.4.1.1.2"" + ] + }, + ""00080018"": { + ""vr"": ""UI"", + ""Value"": [ + ""1.3.6.1.4.1.14519.5.2.1.6279.6001.143451261327128179989900675595"" + ] + }, + ""00080020"": { + ""vr"": ""DA"", + ""Value"": [ + ""20000101"" + ] + }, + ""00080021"": { + ""vr"": ""DA"", + ""Value"": [ + ""20000101"" + ] + }, + ""00080022"": { + ""vr"": ""DA"", + ""Value"": [ + ""20000101"" + ] + }, + ""00080023"": { + ""vr"": ""DA"", + ""Value"": [ + ""20000101"" + ] + }, + ""00080024"": { + ""vr"": ""DA"", + ""Value"": [ + ""20000101"" + ] + }, + ""00080025"": { + ""vr"": ""DA"", + ""Value"": [ + ""20000101"" + ] + }, + ""0008002A"": { + ""vr"": ""DT"", + ""Value"": [ + ""20000101"" + ] + }, + ""00080030"": { + ""vr"": ""TM"" + }, + ""00080032"": { + ""vr"": ""TM"" + }, + ""00080033"": { + ""vr"": ""TM"" + }, + ""00080050"": { + ""vr"": ""SH"" + }, + ""00080060"": { + ""vr"": ""CS"", + ""Value"": [ + ""CT"" + ] + }, + ""00080070"": { + ""vr"": ""LO"", + ""Value"": [ + ""GE MEDICAL SYSTEMS"" + ] + }, + ""00080090"": { + ""vr"": ""PN"" + }, + ""00081090"": { + ""vr"": ""LO"", + ""Value"": [ + ""LightSpeed Plus"" + ] + }, + ""00081155"": { + ""vr"": ""UI"", + ""Value"": [ + ""1.3.6.1.4.1.14519.5.2.1.6279.6001.675906998158803995297223798692"" + ] + }, + ""00100010"": { + ""vr"": ""PN"" + }, + ""00100020"": { + ""vr"": ""LO"", + ""Value"": [ + ""LIDC-IDRI-0001"" + ] + }, + ""00100030"": { + ""vr"": ""DA"" + }, + ""00100040"": { + ""vr"": ""CS"" + }, + ""00101010"": { + ""vr"": ""AS"" + }, + ""001021D0"": { + ""vr"": ""DA"", + ""Value"": [ + ""20000101"" + ] + }, + ""00120062"": { + ""vr"": ""CS"", + ""Value"": [ + ""YES"" + ] + }, + ""00120063"": { + ""vr"": ""LO"", + ""Value"": [ + ""DCM:113100/113105/113107/113108/113109/113111"" + ] + }, + ""00130010"": { + ""vr"": ""LO"", + ""Value"": [ + ""CTP"" + ] + }, + ""00131010"": { + ""vr"": ""LO"", + ""Value"": [ + ""LIDC-IDRI"" + ] + }, + ""00131013"": { + ""vr"": ""LO"", + ""Value"": [ + ""62796001"" + ] + }, + ""00180010"": { + ""vr"": ""LO"", + ""Value"": [ + ""IV"" + ] + }, + ""00180015"": { + ""vr"": ""CS"", + ""Value"": [ + ""CHEST"" + ] + }, + ""00180022"": { + ""vr"": ""CS"", + ""Value"": [ + ""HELICAL MODE"" + ] + }, + ""00180050"": { + ""vr"": ""DS"", + ""Value"": [ + 2.5 + ] + }, + ""00180060"": { + ""vr"": ""DS"", + ""Value"": [ + 120.0 + ] + }, + ""00180090"": { + ""vr"": ""DS"", + ""Value"": [ + 500.0 + ] + }, + ""00181020"": { + ""vr"": ""LO"", + ""Value"": [ + ""LightSpeedApps2.4.2_H2.4M5"" + ] + }, + ""00181100"": { + ""vr"": ""DS"", + ""Value"": [ + 360.0 + ] + }, + ""00181110"": { + ""vr"": ""DS"", + ""Value"": [ + 949.075012 + ] + }, + ""00181111"": { + ""vr"": ""DS"", + ""Value"": [ + 541.0 + ] + }, + ""00181120"": { + ""vr"": ""DS"", + ""Value"": [ + 0.0 + ] + }, + ""00181130"": { + ""vr"": ""DS"", + ""Value"": [ + 144.399994 + ] + }, + ""00181140"": { + ""vr"": ""CS"", + ""Value"": [ + ""CW"" + ] + }, + ""00181150"": { + ""vr"": ""IS"", + ""Value"": [ + 570 + ] + }, + ""00181151"": { + ""vr"": ""IS"", + ""Value"": [ + 400 + ] + }, + ""00181152"": { + ""vr"": ""IS"", + ""Value"": [ + 4684 + ] + }, + ""00181160"": { + ""vr"": ""SH"", + ""Value"": [ + ""BODY FILTER"" + ] + }, + ""00181170"": { + ""vr"": ""IS"", + ""Value"": [ + 48000 + ] + }, + ""00181190"": { + ""vr"": ""DS"", + ""Value"": [ + 1.2 + ] + }, + ""00181210"": { + ""vr"": ""SH"", + ""Value"": [ + ""STANDARD"" + ] + }, + ""00185100"": { + ""vr"": ""CS"", + ""Value"": [ + ""FFS"" + ] + }, + ""0020000D"": { + ""vr"": ""UI"", + ""Value"": [ + ""1.3.6.1.4.1.14519.5.2.1.6279.6001.298806137288633453246975630178"" + ] + }, + ""0020000E"": { + ""vr"": ""UI"", + ""Value"": [ + ""1.3.6.1.4.1.14519.5.2.1.6279.6001.179049373636438705059720603192"" + ] + }, + ""00200010"": { + ""vr"": ""SH"" + }, + ""00200011"": { + ""vr"": ""IS"", + ""Value"": [ + 3000566 + ] + }, + ""00200013"": { + ""vr"": ""IS"", + ""Value"": [ + 80 + ] + }, + ""00200032"": { + ""vr"": ""DS"", + ""Value"": [ + -166.0, + -171.699997, + -207.5 + ] + }, + ""00200037"": { + ""vr"": ""DS"", + ""Value"": [ + 1.0, + 0.0, + 0.0, + 0.0, + 1.0, + 0.0 + ] + }, + ""00200052"": { + ""vr"": ""UI"", + ""Value"": [ + ""1.3.6.1.4.1.14519.5.2.1.6279.6001.229925374658226729607867499499"" + ] + }, + ""00201040"": { + ""vr"": ""LO"", + ""Value"": [ + ""SN"" + ] + }, + ""00201041"": { + ""vr"": ""DS"", + ""Value"": [ + -207.5 + ] + }, + ""00280002"": { + ""vr"": ""US"", + ""Value"": [ + 1 + ] + }, + ""00280004"": { + ""vr"": ""CS"", + ""Value"": [ + ""MONOCHROME2"" + ] + }, + ""00280010"": { + ""vr"": ""US"", + ""Value"": [ + 512 + ] + }, + ""00280011"": { + ""vr"": ""US"", + ""Value"": [ + 512 + ] + }, + ""00280030"": { + ""vr"": ""DS"", + ""Value"": [ + 0.703125, + 0.703125 + ] + }, + ""00280100"": { + ""vr"": ""US"", + ""Value"": [ + 16 + ] + }, + ""00280101"": { + ""vr"": ""US"", + ""Value"": [ + 16 + ] + }, + ""00280102"": { + ""vr"": ""US"", + ""Value"": [ + 15 + ] + }, + ""00280103"": { + ""vr"": ""US"", + ""Value"": [ + 1 + ] + }, + ""00280120"": { + ""vr"": ""US"", + ""Value"": [ + 63536 + ] + }, + ""00280303"": { + ""vr"": ""CS"", + ""Value"": [ + ""MODIFIED"" + ] + }, + ""00281050"": { + ""vr"": ""DS"", + ""Value"": [ + -600.0 + ] + }, + ""00281051"": { + ""vr"": ""DS"", + ""Value"": [ + 1600.0 + ] + }, + ""00281052"": { + ""vr"": ""DS"", + ""Value"": [ + -1024.0 + ] + }, + ""00281053"": { + ""vr"": ""DS"", + ""Value"": [ + 1.0 + ] + }, + ""00380020"": { + ""vr"": ""DA"", + ""Value"": [ + ""20000101"" + ] + }, + ""00400002"": { + ""vr"": ""DA"", + ""Value"": [ + ""20000101"" + ] + }, + ""00400004"": { + ""vr"": ""DA"", + ""Value"": [ + ""20000101"" + ] + }, + ""00400244"": { + ""vr"": ""DA"", + ""Value"": [ + ""20000101"" + ] + }, + ""00402016"": { + ""vr"": ""LO"" + }, + ""00402017"": { + ""vr"": ""LO"" + }, + ""0040A075"": { + ""vr"": ""PN"", + ""Value"": [ + { + ""Alphabetic"": ""Removed by CTP"" + } + ] + }, + ""0040A123"": { + ""vr"": ""PN"", + ""Value"": [ + { + ""Alphabetic"": ""Removed by CTP"" + } + ] + }, + ""0040A124"": { + ""vr"": ""UI"", + ""Value"": [ + ""1.3.6.1.4.1.14519.5.2.1.6279.6001.335419887712224178340067932923"" + ] + }, + ""00700084"": { + ""vr"": ""PN"" + }, + ""00880140"": { + ""vr"": ""UI"", + ""Value"": [ + ""1.3.6.1.4.1.14519.5.2.1.6279.6001.211790042620307056609660772296"" + ] + }, + ""7FE00010"": { + ""vr"": ""OW"", + ""BulkDataURI"": ""sources/tcia-lidc-0001-ct.dcm#tag-7FE00010"" + } +} +",sources/tcia-lidc-0001-ct.dcm,4b5570f8acf2ec6cb086e21cba31d67c1ce13a75897bc759d360d8805d570576,1.2.840.10008.1.2.1 diff --git a/spec/domain-packs/medical-imaging/licenses/NOTICE.txt b/spec/domain-packs/medical-imaging/licenses/NOTICE.txt index 5b91a110a..a1b8f1d46 100644 --- a/spec/domain-packs/medical-imaging/licenses/NOTICE.txt +++ b/spec/domain-packs/medical-imaging/licenses/NOTICE.txt @@ -1 +1 @@ -All included DICOM objects, metadata and byte-ramp pixels are UMF-authored fabricated fixtures and may be redistributed with this notice. No real patient or acquired image is represented. DICOM is a NEMA trademark; this fixture does not reproduce the copyrighted DICOM standard or claim endorsement. TCIA collections require their own citation and data-use conditions. +The synthetic DICOM object, its metadata and byte-ramp pixels are UMF-authored fabricated fixtures and may be redistributed with this notice. That synthetic fixture represents no real patient or acquired image; the separately identified public CT object is publisher-deidentified TCIA data. DICOM is a NEMA trademark; this fixture does not reproduce the copyrighted DICOM standard or claim endorsement. Public CT source: Armato III, S. G., et al. (2015). Data From LIDC-IDRI [Data set]. The Cancer Imaging Archive. https://doi.org/10.7937/K9/TCIA.2015.LO9QL9SX . Licensed CC BY 3.0 https://creativecommons.org/licenses/by/3.0/ ; source https://www.cancerimagingarchive.net/collection/lidc-idri/ and policy https://www.cancerimagingarchive.net/data-usage-policies-and-restrictions/ . Selected binary unchanged; UMF/pydicom derived separate JSON metadata normalizes DS/IS and replaces pixel bytes with a local BulkDataURI; complete native binary remains supplied. No endorsement implied. diff --git a/spec/domain-packs/medical-imaging/ontology.json b/spec/domain-packs/medical-imaging/ontology.json new file mode 100644 index 000000000..835b4dc66 --- /dev/null +++ b/spec/domain-packs/medical-imaging/ontology.json @@ -0,0 +1,369 @@ +{ + "umf": "0.8.0", + "id": "urn:umf:domain:medical-imaging", + "title": "medical-imaging ontology", + "vocabularies": {}, + "modules": [ + { + "id": "domain", + "namespace": "urn:umf:domain:medical-imaging:", + "elements": [ + { + "id": "instances", + "kind": "record", + "name": "instances", + "title": "instances", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence; one unchanged public TCIA LIDC-IDRI CT slice with publisher-deidentified source identity.", + "members": [ + { + "module": "domain", + "element": "instances.instance_key" + }, + { + "module": "domain", + "element": "instances.source_id" + }, + { + "module": "domain", + "element": "instances.study_uid" + }, + { + "module": "domain", + "element": "instances.series_uid" + }, + { + "module": "domain", + "element": "instances.sop_instance_uid" + }, + { + "module": "domain", + "element": "instances.sop_class_uid" + }, + { + "module": "domain", + "element": "instances.modality" + }, + { + "module": "domain", + "element": "instances.metadata_json" + }, + { + "module": "domain", + "element": "instances.binary_reference" + }, + { + "module": "domain", + "element": "instances.binary_sha256" + }, + { + "module": "domain", + "element": "instances.transfer_syntax" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "instances.instance_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "instances.instance_key", + "name": "instance_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "instance key", + "extensions": {} + }, + { + "id": "instances.source_id", + "name": "source_id", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "source id", + "extensions": {} + }, + { + "id": "instances.study_uid", + "name": "study_uid", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "study uid", + "extensions": {} + }, + { + "id": "instances.series_uid", + "name": "series_uid", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "series uid", + "extensions": {} + }, + { + "id": "instances.sop_instance_uid", + "name": "sop_instance_uid", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "sop instance uid", + "extensions": {} + }, + { + "id": "instances.sop_class_uid", + "name": "sop_class_uid", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "sop class uid", + "extensions": {} + }, + { + "id": "instances.modality", + "name": "modality", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "modality", + "extensions": {} + }, + { + "id": "instances.metadata_json", + "name": "metadata_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "metadata json", + "extensions": {} + }, + { + "id": "instances.binary_reference", + "name": "binary_reference", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "binary reference", + "extensions": {} + }, + { + "id": "instances.binary_sha256", + "name": "binary_sha256", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "binary sha256", + "extensions": {} + }, + { + "id": "instances.transfer_syntax", + "name": "transfer_syntax", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "transfer syntax", + "extensions": {} + }, + { + "id": "attributes", + "kind": "record", + "name": "attributes", + "title": "attributes", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence; one unchanged public TCIA LIDC-IDRI CT slice with publisher-deidentified source identity.", + "members": [ + { + "module": "domain", + "element": "attributes.attribute_key" + }, + { + "module": "domain", + "element": "attributes.source_id" + }, + { + "module": "domain", + "element": "attributes.native_path" + }, + { + "module": "domain", + "element": "attributes.tag" + }, + { + "module": "domain", + "element": "attributes.vr" + }, + { + "module": "domain", + "element": "attributes.value_json" + }, + { + "module": "domain", + "element": "attributes.bulk_data_uri" + }, + { + "module": "domain", + "element": "attributes.inline_binary" + }, + { + "module": "domain", + "element": "attributes.native_json" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "attributes.attribute_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "attributes.attribute_key", + "name": "attribute_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "attribute key", + "extensions": {} + }, + { + "id": "attributes.source_id", + "name": "source_id", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "source id", + "extensions": {} + }, + { + "id": "attributes.native_path", + "name": "native_path", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native path", + "extensions": {} + }, + { + "id": "attributes.tag", + "name": "tag", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "tag", + "extensions": {} + }, + { + "id": "attributes.vr", + "name": "vr", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "vr", + "extensions": {} + }, + { + "id": "attributes.value_json", + "name": "value_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "value json", + "extensions": {} + }, + { + "id": "attributes.bulk_data_uri", + "name": "bulk_data_uri", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "bulk data uri", + "extensions": {} + }, + { + "id": "attributes.inline_binary", + "name": "inline_binary", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "inline binary", + "extensions": {} + }, + { + "id": "attributes.native_json", + "name": "native_json", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native json", + "extensions": {} + } + ], + "relationships": [ + { + "id": "attributes.source_id", + "name": "attributes.source_id", + "source": [ + { + "module": "domain", + "element": "attributes" + } + ], + "target": [ + { + "module": "domain", + "element": "instances", + "key": "identity" + } + ], + "sourceMultiplicity": { + "min": 0, + "max": "*" + }, + "targetMultiplicity": { + "min": 1, + "max": 1 + }, + "targetLifecycle": "independent", + "directed": true + } + ] + } + ] +} diff --git a/spec/domain-packs/medical-imaging/pack.json b/spec/domain-packs/medical-imaging/pack.json index f6377c0fd..3786c2a79 100644 --- a/spec/domain-packs/medical-imaging/pack.json +++ b/spec/domain-packs/medical-imaging/pack.json @@ -1,6 +1,36 @@ { "id": "medical-imaging", - "version": "1.0.0", + "version": "1.1.0", + "family": { + "id": "medical", + "version": "1.1.0", + "label": "Imaging: DICOM and PACS metadata" + }, + "execution_profile": { + "version": "1.0.0", + "targets": { + "tabular": [ + "instances", + "attributes" + ], + "graph": [ + "ontology" + ] + }, + "mode": "fixed", + "include_sources": [ + "dicom_json", + "dicom_binary", + "provenance", + "tcia_binary", + "tcia_json", + "tcia_selection", + "notices", + "csv_instances", + "csv_attributes" + ], + "qualification": "Fixed source-qualified sample rows and schema-only ontology. No data generation, clinical conformance or graph-storage execution claim." + }, "description": "Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.", "domain_types": { "source_qualified_identity": { @@ -20,6 +50,11 @@ "id": "attributes", "format": "tablespec", "reference": "umf/attributes.json" + }, + { + "id": "ontology", + "format": "umf", + "reference": "ontology.json" } ], "sources": { @@ -81,19 +116,65 @@ "transformations": [] } }, - "tcia": { + "tcia_binary": { "kind": "external", "data_kind": "deidentified", - "reference": "https://www.cancerimagingarchive.net/data-usage-policies-and-restrictions/", - "format": "publisher-page", + "reference": "sources/tcia-lidc-0001-ct.dcm", + "format": "dicom-part10", + "checksum": { + "algorithm": "sha256", + "value": "4b5570f8acf2ec6cb086e21cba31d67c1ce13a75897bc759d360d8805d570576" + }, "license": { - "redistribution": "unknown", - "notices": [ - "Reference or consumer-local licensed input only; no bytes bundled or retrieval implied." - ] + "id": "CC-BY-3.0", + "reference": "licenses/NOTICE.txt", + "redistribution": "allowed", + "attribution": "Armato et al. (2015), Data From LIDC-IDRI, doi:10.7937/K9/TCIA.2015.LO9QL9SX" + }, + "provenance": { + "publisher": "TCIA", + "retrieved_at": "2026-10-08", + "transformations": [] + }, + "revision": "2015 DOI; exact API snapshot retrieved 2026-10-08" + }, + "tcia_json": { + "kind": "external", + "data_kind": "deidentified", + "reference": "sources/tcia-lidc-0001-ct.json", + "format": "dicom-json", + "checksum": { + "algorithm": "sha256", + "value": "dce66b9233f07dbe028cad501b7147e8d627b030701fbf3395bfdd4b1072005d" + }, + "license": { + "redistribution": "allowed", + "reference": "licenses/NOTICE.txt" + }, + "provenance": { + "publisher": "TCIA / UMF projection", + "retrieved_at": "2026-10-08", + "transformations": [] + }, + "revision": "2015 DOI; exact API snapshot retrieved 2026-10-08" + }, + "tcia_selection": { + "kind": "external", + "data_kind": "unknown", + "reference": "sources/tcia-selection.json", + "format": "json", + "checksum": { + "algorithm": "sha256", + "value": "b374d405939a3c33bd02a13138dbf3c4e963c444a330a9732fc2f18f91945f57" + }, + "license": { + "redistribution": "allowed", + "reference": "licenses/NOTICE.txt" }, "provenance": { - "publisher": "The Cancer Imaging Archive" + "publisher": "UMF project", + "retrieved_at": "2026-10-08", + "transformations": [] } }, "notices": { @@ -103,7 +184,7 @@ "format": "text", "checksum": { "algorithm": "sha256", - "value": "5406b7be08334dbd64bcfb0523895a594fd39992a4196ebe5398e3baefd53804" + "value": "c810fd8653dd42fc427d84b87c9f786184a8e6df95b8e4430194bfb9904043fb" }, "license": { "redistribution": "allowed", @@ -117,13 +198,13 @@ }, "csv_instances": { "kind": "external", - "data_kind": "fabricated", + "data_kind": "unknown", "reference": "data/instances.csv", "format": "csv", - "revision": "medical-imaging-1.0.0", + "revision": "medical-imaging-1.1.0", "checksum": { "algorithm": "sha256", - "value": "78a44cc081c21c2c7a4efde37309458ec474953ca6df7924933ced31f5bca552" + "value": "a9de843fb268c76ae8454e246986df1844ae7077df6b0b459529a0db7501d9cd" }, "license": { "redistribution": "allowed", @@ -134,7 +215,10 @@ "source_ids": [ "dicom_json", "dicom_binary", - "provenance" + "provenance", + "tcia_binary", + "tcia_json", + "tcia_selection" ], "transformations": [ "Deterministic selected-column projection; original native sources retained separately." @@ -143,13 +227,13 @@ }, "csv_attributes": { "kind": "external", - "data_kind": "fabricated", + "data_kind": "unknown", "reference": "data/attributes.csv", "format": "csv", - "revision": "medical-imaging-1.0.0", + "revision": "medical-imaging-1.1.0", "checksum": { "algorithm": "sha256", - "value": "414edf65a0f5c21865bb296a5e150ddaa7cbb60817bd9a257f94ad4340ca7f8e" + "value": "642ad1c908d4abbf35b609e7e100a6192df48c950a2fffc79b63ce1863af9070" }, "license": { "redistribution": "allowed", @@ -158,7 +242,8 @@ "provenance": { "publisher": "UMF project", "source_ids": [ - "dicom_json" + "dicom_json", + "tcia_json" ], "transformations": [ "Deterministic selected-column projection; original native sources retained separately." @@ -187,6 +272,21 @@ "source_id": "provenance", "role": "reference" }, + { + "schema_id": "instances", + "source_id": "tcia_binary", + "role": "reference" + }, + { + "schema_id": "instances", + "source_id": "tcia_json", + "role": "reference" + }, + { + "schema_id": "instances", + "source_id": "tcia_selection", + "role": "reference" + }, { "schema_id": "attributes", "source_id": "csv_attributes", @@ -196,6 +296,11 @@ "schema_id": "attributes", "source_id": "dicom_json", "role": "reference" + }, + { + "schema_id": "attributes", + "source_id": "tcia_json", + "role": "reference" } ], "csv_conventions": { @@ -205,15 +310,17 @@ "quote": "\"" }, "fixture_counts": { - "instances": 1, - "attributes": 24 + "instances": 2, + "attributes": 113 }, "qualification": { - "native_format": "DICOM Part 10 Explicit VR Little Endian and DICOM JSON", - "subset": "One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence.", + "native_format": "DICOM Part 10 with per-instance transfer syntax and separate DICOM JSON metadata", + "subset": "One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence; one unchanged public TCIA LIDC-IDRI CT slice with publisher-deidentified source identity.", "projection_losses": [ - "pydicom DICOM JSON normalizes native DS decimal spellings (1.2500 to 1.25); original spellings remain in the unchanged binary object. File-meta elements and preamble are binary-only, retained in the original." + "pydicom DICOM JSON normalizes native DS decimal spellings (1.2500 to 1.25); original spellings remain in the unchanged binary object. File-meta elements and preamble are binary-only, retained in the original.", + "DS/IS values may normalize lexical spelling in pydicom JSON; exact spelling stays in original binary.", + "PixelData becomes an opaque local BulkDataURI; pixel and file-meta bytes stay in the unchanged binary." ], - "limits": "Native metadata and original binary retention only. No public patient images, pixel decoding, full IOD conformance, DICOMweb or live PACS operations. TCIA remains a collection-specific rights/access candidate; no TCIA bytes are bundled." + "limits": "Native metadata and original binary retention only. The public CT slice is an incomplete 1/133-series selection, not a full study. Its source DICOM edition is unknown; pydicom 3.0.2 JSON inspection is the tested profile. No independent deidentification certification, pixel decoding, full IOD conformance, DICOMweb or live PACS operations." } } diff --git a/spec/domain-packs/medical-imaging/sources/tcia-lidc-0001-ct.dcm b/spec/domain-packs/medical-imaging/sources/tcia-lidc-0001-ct.dcm new file mode 100644 index 000000000..91c93329e Binary files /dev/null and b/spec/domain-packs/medical-imaging/sources/tcia-lidc-0001-ct.dcm differ diff --git a/spec/domain-packs/medical-imaging/sources/tcia-lidc-0001-ct.json b/spec/domain-packs/medical-imaging/sources/tcia-lidc-0001-ct.json new file mode 100644 index 000000000..23dc00783 --- /dev/null +++ b/spec/domain-packs/medical-imaging/sources/tcia-lidc-0001-ct.json @@ -0,0 +1,509 @@ +{ + "00080005": { + "vr": "CS", + "Value": [ + "ISO_IR 100" + ] + }, + "00080008": { + "vr": "CS", + "Value": [ + "ORIGINAL", + "PRIMARY", + "AXIAL" + ] + }, + "00080016": { + "vr": "UI", + "Value": [ + "1.2.840.10008.5.1.4.1.1.2" + ] + }, + "00080018": { + "vr": "UI", + "Value": [ + "1.3.6.1.4.1.14519.5.2.1.6279.6001.143451261327128179989900675595" + ] + }, + "00080020": { + "vr": "DA", + "Value": [ + "20000101" + ] + }, + "00080021": { + "vr": "DA", + "Value": [ + "20000101" + ] + }, + "00080022": { + "vr": "DA", + "Value": [ + "20000101" + ] + }, + "00080023": { + "vr": "DA", + "Value": [ + "20000101" + ] + }, + "00080024": { + "vr": "DA", + "Value": [ + "20000101" + ] + }, + "00080025": { + "vr": "DA", + "Value": [ + "20000101" + ] + }, + "0008002A": { + "vr": "DT", + "Value": [ + "20000101" + ] + }, + "00080030": { + "vr": "TM" + }, + "00080032": { + "vr": "TM" + }, + "00080033": { + "vr": "TM" + }, + "00080050": { + "vr": "SH" + }, + "00080060": { + "vr": "CS", + "Value": [ + "CT" + ] + }, + "00080070": { + "vr": "LO", + "Value": [ + "GE MEDICAL SYSTEMS" + ] + }, + "00080090": { + "vr": "PN" + }, + "00081090": { + "vr": "LO", + "Value": [ + "LightSpeed Plus" + ] + }, + "00081155": { + "vr": "UI", + "Value": [ + "1.3.6.1.4.1.14519.5.2.1.6279.6001.675906998158803995297223798692" + ] + }, + "00100010": { + "vr": "PN" + }, + "00100020": { + "vr": "LO", + "Value": [ + "LIDC-IDRI-0001" + ] + }, + "00100030": { + "vr": "DA" + }, + "00100040": { + "vr": "CS" + }, + "00101010": { + "vr": "AS" + }, + "001021D0": { + "vr": "DA", + "Value": [ + "20000101" + ] + }, + "00120062": { + "vr": "CS", + "Value": [ + "YES" + ] + }, + "00120063": { + "vr": "LO", + "Value": [ + "DCM:113100/113105/113107/113108/113109/113111" + ] + }, + "00130010": { + "vr": "LO", + "Value": [ + "CTP" + ] + }, + "00131010": { + "vr": "LO", + "Value": [ + "LIDC-IDRI" + ] + }, + "00131013": { + "vr": "LO", + "Value": [ + "62796001" + ] + }, + "00180010": { + "vr": "LO", + "Value": [ + "IV" + ] + }, + "00180015": { + "vr": "CS", + "Value": [ + "CHEST" + ] + }, + "00180022": { + "vr": "CS", + "Value": [ + "HELICAL MODE" + ] + }, + "00180050": { + "vr": "DS", + "Value": [ + 2.5 + ] + }, + "00180060": { + "vr": "DS", + "Value": [ + 120.0 + ] + }, + "00180090": { + "vr": "DS", + "Value": [ + 500.0 + ] + }, + "00181020": { + "vr": "LO", + "Value": [ + "LightSpeedApps2.4.2_H2.4M5" + ] + }, + "00181100": { + "vr": "DS", + "Value": [ + 360.0 + ] + }, + "00181110": { + "vr": "DS", + "Value": [ + 949.075012 + ] + }, + "00181111": { + "vr": "DS", + "Value": [ + 541.0 + ] + }, + "00181120": { + "vr": "DS", + "Value": [ + 0.0 + ] + }, + "00181130": { + "vr": "DS", + "Value": [ + 144.399994 + ] + }, + "00181140": { + "vr": "CS", + "Value": [ + "CW" + ] + }, + "00181150": { + "vr": "IS", + "Value": [ + 570 + ] + }, + "00181151": { + "vr": "IS", + "Value": [ + 400 + ] + }, + "00181152": { + "vr": "IS", + "Value": [ + 4684 + ] + }, + "00181160": { + "vr": "SH", + "Value": [ + "BODY FILTER" + ] + }, + "00181170": { + "vr": "IS", + "Value": [ + 48000 + ] + }, + "00181190": { + "vr": "DS", + "Value": [ + 1.2 + ] + }, + "00181210": { + "vr": "SH", + "Value": [ + "STANDARD" + ] + }, + "00185100": { + "vr": "CS", + "Value": [ + "FFS" + ] + }, + "0020000D": { + "vr": "UI", + "Value": [ + "1.3.6.1.4.1.14519.5.2.1.6279.6001.298806137288633453246975630178" + ] + }, + "0020000E": { + "vr": "UI", + "Value": [ + "1.3.6.1.4.1.14519.5.2.1.6279.6001.179049373636438705059720603192" + ] + }, + "00200010": { + "vr": "SH" + }, + "00200011": { + "vr": "IS", + "Value": [ + 3000566 + ] + }, + "00200013": { + "vr": "IS", + "Value": [ + 80 + ] + }, + "00200032": { + "vr": "DS", + "Value": [ + -166.0, + -171.699997, + -207.5 + ] + }, + "00200037": { + "vr": "DS", + "Value": [ + 1.0, + 0.0, + 0.0, + 0.0, + 1.0, + 0.0 + ] + }, + "00200052": { + "vr": "UI", + "Value": [ + "1.3.6.1.4.1.14519.5.2.1.6279.6001.229925374658226729607867499499" + ] + }, + "00201040": { + "vr": "LO", + "Value": [ + "SN" + ] + }, + "00201041": { + "vr": "DS", + "Value": [ + -207.5 + ] + }, + "00280002": { + "vr": "US", + "Value": [ + 1 + ] + }, + "00280004": { + "vr": "CS", + "Value": [ + "MONOCHROME2" + ] + }, + "00280010": { + "vr": "US", + "Value": [ + 512 + ] + }, + "00280011": { + "vr": "US", + "Value": [ + 512 + ] + }, + "00280030": { + "vr": "DS", + "Value": [ + 0.703125, + 0.703125 + ] + }, + "00280100": { + "vr": "US", + "Value": [ + 16 + ] + }, + "00280101": { + "vr": "US", + "Value": [ + 16 + ] + }, + "00280102": { + "vr": "US", + "Value": [ + 15 + ] + }, + "00280103": { + "vr": "US", + "Value": [ + 1 + ] + }, + "00280120": { + "vr": "US", + "Value": [ + 63536 + ] + }, + "00280303": { + "vr": "CS", + "Value": [ + "MODIFIED" + ] + }, + "00281050": { + "vr": "DS", + "Value": [ + -600.0 + ] + }, + "00281051": { + "vr": "DS", + "Value": [ + 1600.0 + ] + }, + "00281052": { + "vr": "DS", + "Value": [ + -1024.0 + ] + }, + "00281053": { + "vr": "DS", + "Value": [ + 1.0 + ] + }, + "00380020": { + "vr": "DA", + "Value": [ + "20000101" + ] + }, + "00400002": { + "vr": "DA", + "Value": [ + "20000101" + ] + }, + "00400004": { + "vr": "DA", + "Value": [ + "20000101" + ] + }, + "00400244": { + "vr": "DA", + "Value": [ + "20000101" + ] + }, + "00402016": { + "vr": "LO" + }, + "00402017": { + "vr": "LO" + }, + "0040A075": { + "vr": "PN", + "Value": [ + { + "Alphabetic": "Removed by CTP" + } + ] + }, + "0040A123": { + "vr": "PN", + "Value": [ + { + "Alphabetic": "Removed by CTP" + } + ] + }, + "0040A124": { + "vr": "UI", + "Value": [ + "1.3.6.1.4.1.14519.5.2.1.6279.6001.335419887712224178340067932923" + ] + }, + "00700084": { + "vr": "PN" + }, + "00880140": { + "vr": "UI", + "Value": [ + "1.3.6.1.4.1.14519.5.2.1.6279.6001.211790042620307056609660772296" + ] + }, + "7FE00010": { + "vr": "OW", + "BulkDataURI": "sources/tcia-lidc-0001-ct.dcm#tag-7FE00010" + } +} diff --git a/spec/domain-packs/medical-imaging/sources/tcia-selection.json b/spec/domain-packs/medical-imaging/sources/tcia-selection.json new file mode 100644 index 000000000..4a719dd90 --- /dev/null +++ b/spec/domain-packs/medical-imaging/sources/tcia-selection.json @@ -0,0 +1,45 @@ +{ + "collection": "LIDC-IDRI", + "doi": "10.7937/K9/TCIA.2015.LO9QL9SX", + "collection_revision": "2015 DOI; exact API snapshot retrieved 2026-10-08", + "license": "CC-BY-3.0", + "license_url": "https://creativecommons.org/licenses/by/3.0/", + "collection_url": "https://www.cancerimagingarchive.net/collection/lidc-idri/", + "policy_url": "https://www.cancerimagingarchive.net/data-usage-policies-and-restrictions/", + "archive_url": "https://services.cancerimagingarchive.net/nbia-api/services/v1/getImage?SeriesInstanceUID=1.3.6.1.4.1.14519.5.2.1.6279.6001.179049373636438705059720603192", + "archive_sha256": "368b2d7ca84edc2f1462194282d6cdd52b6624b5c90964eb8a306ebe56328833", + "member": "00000001.dcm", + "member_sha256": "4b5570f8acf2ec6cb086e21cba31d67c1ce13a75897bc759d360d8805d570576", + "selection": "Lexicographically first DICOM member from one 133-instance CT series; one slice only, not a complete study. Original binary unchanged.", + "data_kind": "deidentified", + "patient_id": "LIDC-IDRI-0001", + "study_uid": "1.3.6.1.4.1.14519.5.2.1.6279.6001.298806137288633453246975630178", + "series_uid": "1.3.6.1.4.1.14519.5.2.1.6279.6001.179049373636438705059720603192", + "sop_instance_uid": "1.3.6.1.4.1.14519.5.2.1.6279.6001.143451261327128179989900675595", + "transfer_syntax": "1.2.840.10008.1.2.1", + "native_dicom_edition": "Not declared by source; inspection profile DICOM JSON PS3.18 Annex F, pydicom 3.0.2.", + "private_elements": [ + { + "tag": "00130010", + "vr": "LO", + "value": "CTP" + }, + { + "tag": "00131010", + "vr": "LO", + "value": "LIDC-IDRI" + }, + { + "tag": "00131013", + "vr": "LO", + "value": "62796001" + } + ], + "burned_in_annotation": "not supplied", + "deidentification": "Publisher-deidentified source; no independent patient reidentification or deidentification certification. Retained private creator and CT private values are inspectable.", + "projection_losses": [ + "DS/IS values may normalize lexical spelling in pydicom JSON; exact spelling stays in original binary.", + "PixelData becomes an opaque local BulkDataURI; pixel and file-meta bytes stay in the unchanged binary." + ], + "pydicom_version": "3.0.2" +} diff --git a/spec/domain-packs/medical-imaging/umf/attributes.json b/spec/domain-packs/medical-imaging/umf/attributes.json index 590e6fba4..cfbfdc767 100644 --- a/spec/domain-packs/medical-imaging/umf/attributes.json +++ b/spec/domain-packs/medical-imaging/umf/attributes.json @@ -1,7 +1,7 @@ { "version": "1.0", "table_name": "attributes", - "description": "Source-qualified selected view. Full original meaning remains in pinned sources. One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence.", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence; one unchanged public TCIA LIDC-IDRI CT slice with publisher-deidentified source identity.", "columns": [ { "name": "attribute_key", diff --git a/spec/domain-packs/medical-imaging/umf/instances.json b/spec/domain-packs/medical-imaging/umf/instances.json index 16611e3aa..d247c2261 100644 --- a/spec/domain-packs/medical-imaging/umf/instances.json +++ b/spec/domain-packs/medical-imaging/umf/instances.json @@ -1,7 +1,7 @@ { "version": "1.0", "table_name": "instances", - "description": "Source-qualified selected view. Full original meaning remains in pinned sources. One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence.", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. One authored 4x4 Secondary Capture instance with fixed synthetic study/series/SOP UIDs, private tags and nested private sequence; one unchanged public TCIA LIDC-IDRI CT slice with publisher-deidentified source identity.", "columns": [ { "name": "instance_key", diff --git a/spec/domain-packs/medical-terminology/README.md b/spec/domain-packs/medical-terminology/README.md index 7373550f8..0a372d8f2 100644 --- a/spec/domain-packs/medical-terminology/README.md +++ b/spec/domain-packs/medical-terminology/README.md @@ -1,4 +1,4 @@ -# medical-terminology 1.0.0 +# medical-terminology 1.1.0 12 native ICD-10-CM FY2026 October 2025 order-file records; six separately identified system/access descriptors. diff --git a/spec/domain-packs/medical-terminology/ontology.json b/spec/domain-packs/medical-terminology/ontology.json new file mode 100644 index 000000000..f01a04786 --- /dev/null +++ b/spec/domain-packs/medical-terminology/ontology.json @@ -0,0 +1,271 @@ +{ + "umf": "0.8.0", + "id": "urn:umf:domain:medical-terminology", + "title": "medical-terminology ontology", + "vocabularies": {}, + "modules": [ + { + "id": "domain", + "namespace": "urn:umf:domain:medical-terminology:", + "elements": [ + { + "id": "systems", + "kind": "record", + "name": "systems", + "title": "systems", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 12 native ICD-10-CM FY2026 October 2025 order-file records; six separately identified system/access descriptors.", + "members": [ + { + "module": "domain", + "element": "systems.system_key" + }, + { + "module": "domain", + "element": "systems.system" + }, + { + "module": "domain", + "element": "systems.release" + }, + { + "module": "domain", + "element": "systems.availability" + }, + { + "module": "domain", + "element": "systems.description" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "systems.system_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "systems.system_key", + "name": "system_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "system key", + "extensions": {} + }, + { + "id": "systems.system", + "name": "system", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "system", + "extensions": {} + }, + { + "id": "systems.release", + "name": "release", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "absent-allowed", + "description": "release", + "extensions": {} + }, + { + "id": "systems.availability", + "name": "availability", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "availability", + "extensions": {} + }, + { + "id": "systems.description", + "name": "description", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "description", + "extensions": {} + }, + { + "id": "concepts", + "kind": "record", + "name": "concepts", + "title": "concepts", + "description": "Source-qualified selected view. Full original meaning remains in pinned sources. 12 native ICD-10-CM FY2026 October 2025 order-file records; six separately identified system/access descriptors.", + "members": [ + { + "module": "domain", + "element": "concepts.concept_key" + }, + { + "module": "domain", + "element": "concepts.system" + }, + { + "module": "domain", + "element": "concepts.release" + }, + { + "module": "domain", + "element": "concepts.code" + }, + { + "module": "domain", + "element": "concepts.billable" + }, + { + "module": "domain", + "element": "concepts.short_display" + }, + { + "module": "domain", + "element": "concepts.display" + }, + { + "module": "domain", + "element": "concepts.effective_start" + }, + { + "module": "domain", + "element": "concepts.effective_end" + }, + { + "module": "domain", + "element": "concepts.native_line" + } + ], + "keys": [ + { + "id": "identity", + "name": "Identity", + "fields": [ + { + "module": "domain", + "element": "concepts.concept_key" + } + ], + "primary": true + } + ], + "extensions": {} + }, + { + "id": "concepts.concept_key", + "name": "concept_key", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "concept key", + "extensions": {} + }, + { + "id": "concepts.system", + "name": "system", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "system", + "extensions": {} + }, + { + "id": "concepts.release", + "name": "release", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "release", + "extensions": {} + }, + { + "id": "concepts.code", + "name": "code", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "code", + "extensions": {} + }, + { + "id": "concepts.billable", + "name": "billable", + "kind": "field", + "scalarType": "boolean", + "cardinality": "one", + "nullability": "required", + "description": "billable", + "extensions": {} + }, + { + "id": "concepts.short_display", + "name": "short_display", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "short display", + "extensions": {} + }, + { + "id": "concepts.display", + "name": "display", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "display", + "extensions": {} + }, + { + "id": "concepts.effective_start", + "name": "effective_start", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "effective start", + "extensions": {} + }, + { + "id": "concepts.effective_end", + "name": "effective_end", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "effective end", + "extensions": {} + }, + { + "id": "concepts.native_line", + "name": "native_line", + "kind": "field", + "scalarType": "string", + "cardinality": "one", + "nullability": "required", + "description": "native line", + "extensions": {} + } + ], + "relationships": [] + } + ] +} diff --git a/spec/domain-packs/medical-terminology/pack.json b/spec/domain-packs/medical-terminology/pack.json index 68500c9d3..0f0e8ac7d 100644 --- a/spec/domain-packs/medical-terminology/pack.json +++ b/spec/domain-packs/medical-terminology/pack.json @@ -1,6 +1,32 @@ { "id": "medical-terminology", - "version": "1.0.0", + "version": "1.1.0", + "family": { + "id": "medical", + "version": "1.1.0", + "label": "Terminology" + }, + "execution_profile": { + "version": "1.0.0", + "targets": { + "tabular": [ + "systems", + "concepts" + ], + "graph": [ + "ontology" + ] + }, + "mode": "fixed", + "include_sources": [ + "icd10cm", + "selection", + "notices", + "csv_systems", + "csv_concepts" + ], + "qualification": "Fixed source-qualified sample rows and schema-only ontology. No data generation, clinical conformance or graph-storage execution claim." + }, "description": "Independently versioned medical-family subpack; no implicit retrieval, code execution or native equivalence.", "domain_types": { "source_qualified_identity": { @@ -20,6 +46,11 @@ "id": "concepts", "format": "tablespec", "reference": "umf/concepts.json" + }, + { + "id": "ontology", + "format": "umf", + "reference": "ontology.json" } ], "sources": { @@ -171,7 +202,7 @@ "data_kind": "unknown", "reference": "data/systems.csv", "format": "csv", - "revision": "medical-terminology-1.0.0", + "revision": "medical-terminology-1.1.0", "checksum": { "algorithm": "sha256", "value": "a5a2fa063a954b57253b9afb34e10605f19e20b565eb037acf9f6483b533f002" @@ -198,7 +229,7 @@ "data_kind": "unknown", "reference": "data/concepts.csv", "format": "csv", - "revision": "medical-terminology-1.0.0", + "revision": "medical-terminology-1.1.0", "checksum": { "algorithm": "sha256", "value": "4c9d331a8e2ef23faf1c2eb0f54c7e96b90ffea6c8ee9490e62b33c515daf954" diff --git a/spec/domain-packs/medical/README.md b/spec/domain-packs/medical/README.md index 5910d44e8..61a1d6f25 100644 --- a/spec/domain-packs/medical/README.md +++ b/spec/domain-packs/medical/README.md @@ -1,4 +1,4 @@ -# Medical 1.0.0 +# Medical family 1.1.0 A bounded official HL7 FHIR R4 4.0.1 sample corpus using the same domain-pack contract and TableSpec schema profile as the legal pack. UMF owns this metadata, @@ -43,7 +43,7 @@ Regenstrief Institute, Inc. ## Composable medical subpacks -The clinical corpus remains medical 1.0.0. Independently versioned siblings add +The clinical source corpus is unchanged in medical 1.1.0. Independently versioned siblings add [carrier workflows](../medical-carrier/README.md), [epidemiological aggregates](../medical-epidemiology/README.md), [imaging/PACS metadata](../medical-imaging/README.md) and @@ -51,3 +51,23 @@ The clinical corpus remains medical 1.0.0. Independently versioned siblings add Each has its own pack metadata, local source pins, schemas, row bindings and rights notices. Select/export each explicitly; this list does not authorize automatic retrieval, patient matching or merging population records with individuals. + +## Complete family export and browser + +The Medical overview links Clinical, Carrier, Epidemiology, Imaging and Terminology. +Each 1.1.0 pack has fixed tabular targets and a table-derived ontology; combined +inventory: 29 tables, five ontology schemas and 517 projected rows. Carrier adds +13 unchanged CMS DE-SynPUF CSV records beside retained FHIR R4 resources. Imaging +adds one unchanged CC BY 3.0 TCIA LIDC-IDRI CT slice beside the private-sequence +synthetic control. Source provenance, selected releases and limitations stay local. + +Export all five packs, including permitted original CSV/FHIR/DICOM bytes: + +```sh +bun scripts/export-domain-family.ts --pack spec/domain-packs/medical/pack.json --output /tmp/medical-family --include-sources +``` + +Use `--check` to verify that export. The output keeps ID/version directories and +`family.json`; ingest each `domain-pack.json` separately through TableSpec. Composition +never merges patients or creates links between clinical, CMS and TCIA sources. +Previous 1.0.0 browser bookmarks redirect to the current qualified subset. diff --git a/spec/domain-packs/medical/pack.json b/spec/domain-packs/medical/pack.json index 5cdbfdb0b..781624ef0 100644 --- a/spec/domain-packs/medical/pack.json +++ b/spec/domain-packs/medical/pack.json @@ -1,6 +1,6 @@ { "id": "medical", - "version": "1.0.0", + "version": "1.1.0", "description": "Official HL7 FHIR R4 example corpus and loss-preserving tabular projections. External rows only; no synthetic fallback or clinical simulation claim.", "domain_types": { "fhir_resource_key": { @@ -1132,5 +1132,51 @@ "loinc_short_notice" ], "qualification": "Delivered tabular behavior unchanged. Graph schema candidate only; no graph storage acceptance." + }, + "family": { + "id": "medical", + "version": "1.1.0", + "label": "Clinical" + }, + "composition": { + "version": "1.0.0", + "components": [ + { + "id": "medical-carrier", + "version": "1.1.0", + "label": "Carrier: eligibility, claims and payments", + "checksum": { + "algorithm": "sha256", + "value": "3b59727ac3f98690084c703c6f0c2c444e1e00ef0b562bb97131edaec880568c" + } + }, + { + "id": "medical-epidemiology", + "version": "1.1.0", + "label": "Epidemiology", + "checksum": { + "algorithm": "sha256", + "value": "fa073eeaa754042b9015913a1eba7546bf18d8623279135856856424d4fdfdd5" + } + }, + { + "id": "medical-imaging", + "version": "1.1.0", + "label": "Imaging: DICOM and PACS metadata", + "checksum": { + "algorithm": "sha256", + "value": "6fac6b9ced73a3aa8022508353c30727ea80e3ad51050a1db9a0f15da750c283" + } + }, + { + "id": "medical-terminology", + "version": "1.1.0", + "label": "Terminology", + "checksum": { + "algorithm": "sha256", + "value": "d67785efcacaea51de46d2e12737d9a69d84428d9380d34dda819a5c54bdd926" + } + } + ] } } diff --git a/spec/extensions/domain-pack/package.json b/spec/extensions/domain-pack/package.json index 07dc8464f..ee69f68c5 100644 --- a/spec/extensions/domain-pack/package.json +++ b/spec/extensions/domain-pack/package.json @@ -42,6 +42,88 @@ "description": { "type": "string" }, + "family": { + "type": "object", + "required": [ + "id", + "version", + "label" + ], + "properties": { + "id": { + "type": "string", + "minLength": 1 + }, + "version": { + "type": "string", + "pattern": "^[0-9]+\\.[0-9]+\\.[0-9]+$" + }, + "label": { + "type": "string", + "minLength": 1 + } + }, + "additionalProperties": true + }, + "composition": { + "type": "object", + "required": [ + "version", + "components" + ], + "properties": { + "version": { + "const": "1.0.0" + }, + "components": { + "type": "array", + "minItems": 1, + "maxItems": 32, + "items": { + "type": "object", + "required": [ + "id", + "version", + "label", + "checksum" + ], + "properties": { + "id": { + "type": "string", + "pattern": "^[a-z][a-z0-9-]*$" + }, + "version": { + "type": "string", + "pattern": "^[0-9]+\\.[0-9]+\\.[0-9]+$" + }, + "label": { + "type": "string", + "minLength": 1 + }, + "checksum": { + "type": "object", + "required": [ + "algorithm", + "value" + ], + "properties": { + "algorithm": { + "const": "sha256" + }, + "value": { + "type": "string", + "pattern": "^[a-f0-9]{64}$" + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, "generator": { "type": "object", "required": [ diff --git a/spec/extensions/domain-pack/schema.json b/spec/extensions/domain-pack/schema.json index 6fe9037f9..1dc6f1a6d 100644 --- a/spec/extensions/domain-pack/schema.json +++ b/spec/extensions/domain-pack/schema.json @@ -37,6 +37,88 @@ "description": { "type": "string" }, + "family": { + "type": "object", + "required": [ + "id", + "version", + "label" + ], + "properties": { + "id": { + "type": "string", + "minLength": 1 + }, + "version": { + "type": "string", + "pattern": "^[0-9]+\\.[0-9]+\\.[0-9]+$" + }, + "label": { + "type": "string", + "minLength": 1 + } + }, + "additionalProperties": true + }, + "composition": { + "type": "object", + "required": [ + "version", + "components" + ], + "properties": { + "version": { + "const": "1.0.0" + }, + "components": { + "type": "array", + "minItems": 1, + "maxItems": 32, + "items": { + "type": "object", + "required": [ + "id", + "version", + "label", + "checksum" + ], + "properties": { + "id": { + "type": "string", + "pattern": "^[a-z][a-z0-9-]*$" + }, + "version": { + "type": "string", + "pattern": "^[0-9]+\\.[0-9]+\\.[0-9]+$" + }, + "label": { + "type": "string", + "minLength": 1 + }, + "checksum": { + "type": "object", + "required": [ + "algorithm", + "value" + ], + "properties": { + "algorithm": { + "const": "sha256" + }, + "value": { + "type": "string", + "pattern": "^[a-f0-9]{64}$" + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, "generator": { "type": "object", "required": [ diff --git a/src/domain-packs/profile.ts b/src/domain-packs/profile.ts index bfe2d4d4b..719b89959 100644 --- a/src/domain-packs/profile.ts +++ b/src/domain-packs/profile.ts @@ -11,6 +11,12 @@ function inspectDomainPackInternal(input:unknown):{valid:boolean;complete:boolea const schemas=pack.schemas??[],ids=schemas.map((s:any)=>s.id),sources=pack.sources??{}; if(new Set(ids).size!==ids.length)diagnostics.push('Duplicate schema identity'); for(const b of pack.source_bindings??[])if(!ids.includes(b.schema_id)||!Object.hasOwn(sources,b.source_id))diagnostics.push('Unresolved source binding'); + if(pack.composition){ + const components=pack.composition.components; + const identities=components.map((c:any)=>c.id+'@'+c.version); + if(new Set(identities).size!==identities.length||new Set(components.map((c:any)=>c.id)).size!==components.length)diagnostics.push('Duplicate component identity'); + if(components.some((c:any)=>c.id===pack.id))diagnostics.push('Self composition is not supported'); + } const profile=pack.execution_profile; if(Object.hasOwn(pack,'execution_profile')){ if(!profile||typeof profile!=='object'||Array.isArray(profile))return {valid:false,complete:false,diagnostics:['Malformed execution profile']}; diff --git a/src/domain-packs/schema.ts b/src/domain-packs/schema.ts index b12199fc2..0eb846529 100644 --- a/src/domain-packs/schema.ts +++ b/src/domain-packs/schema.ts @@ -10,6 +10,13 @@ export function generateDomainPackSchema() { anyOf: [{properties:{generator:{}},required:['generator']},{properties:{sources:{}},required:['sources']}], properties: { id: text, version, description: {type: 'string'}, + family: {type:'object',required:['id','version','label'],properties:{id:text,version,label:text},additionalProperties:true}, + composition: {type:'object',required:['version','components'],properties:{ + version:{const:'1.0.0'},components:{type:'array',minItems:1,maxItems:32,items:{type:'object',required:['id','version','label','checksum'],properties:{ + id:{type:'string',pattern:'^[a-z][a-z0-9-]*$'},version,label:text, + checksum:{type:'object',required:['algorithm','value'],properties:{algorithm:{const:'sha256'},value:{type:'string',pattern:'^[a-f0-9]{64}$'}},additionalProperties:true}, + },additionalProperties:true}}, + },additionalProperties:true}, generator: {type: 'object', required: ['id', 'version'], properties: {id: text, version}, additionalProperties: true}, domain_types: {type: 'object', minProperties: 1, diff --git a/tests/domain-packs/medical-family.test.ts b/tests/domain-packs/medical-family.test.ts new file mode 100644 index 000000000..dccd537b4 --- /dev/null +++ b/tests/domain-packs/medical-family.test.ts @@ -0,0 +1,36 @@ +import {expect,test} from 'bun:test'; +import {mkdtemp,cp,rm,stat} from 'node:fs/promises'; +import {join} from 'node:path'; +import {tmpdir} from 'node:os'; +import {resolveDomainFamily} from '../../scripts/domain-pack-family'; +import {inspectDomainPack} from '../../src/domain-packs/profile'; +import {readDocument} from '../../src/model/document'; +import {validateDocument} from '../../src/validation/document'; +const root='spec/domain-packs/medical/pack.json'; +async function run(input:string,output:string,check=false){const p=Bun.spawn(['bun','scripts/export-domain-family.ts','--pack',input,'--output',output,'--include-sources',...(check?['--check']:[])],{stdout:'pipe',stderr:'pipe'});const [code,stderr]=await Promise.all([p.exited,new Response(p.stderr).text(),new Response(p.stdout).text()]);return {code,stderr};} +// @covers US-055-AC1 @covers US-055-AC4 @covers US-055-AC6 + test('medical composition preserves five independent fixed profiles and ontology/table closure',async()=>{ + const members=await resolveDomainFamily(root);expect(members.map(m=>m.pack.id)).toEqual(['medical','medical-carrier','medical-epidemiology','medical-imaging','medical-terminology']); + let tables=0; + for(const {path,pack} of members){expect(inspectDomainPack(pack)).toEqual({valid:true,complete:true,diagnostics:[]});expect(pack.version).toBe('1.1.0');expect(pack.execution_profile.mode).toBe('fixed'); + const ontology=readDocument(await Bun.file(join(path,'../ontology.json')).text(),'json');expect(validateDocument(ontology).valid).toBe(true); + const records=ontology.modules.flatMap(m=>m.elements.filter(e=>e.kind==='record'));expect(records.map(r=>r.id)).toEqual(pack.execution_profile.targets.tabular);tables+=records.length; + for(const record of records){const native=await Bun.file(join(path,'../umf/'+record.id+'.json')).json();expect((Array.isArray(record.members)?record.members.length:0)).toBe(native.columns.length);} + } + expect(tables).toBe(29); + const metadata=members[0]!.pack; + for(const composition of [{...metadata.composition,version:'2.0.0'},{...metadata.composition,components:[...metadata.composition.components,metadata.composition.components[0]]},{...metadata.composition,components:[{...metadata.composition.components[0],id:'../medical-carrier'}]},{...metadata.composition,components:[{...metadata.composition.components[0],id:'medical'}]}])expect(inspectDomainPack({...metadata,composition}).valid).toBe(false); +}); +// @covers US-055-AC5 @covers US-055-AC6 + test('complete medical export recovers all original sources and preflights member failures',async()=>{ + const dir=await mkdtemp(join(tmpdir(),'umf-medical-family-')); + try{ + expect((await run(root,join(dir,'export'))).code).toBe(0);expect((await run(root,join(dir,'export'),true)).code).toBe(0); + const inventory=await Bun.file(join(dir,'export/family.json')).json();expect(inventory.packs).toHaveLength(5); + for(const member of await resolveDomainFamily(root))for(const source of Object.values(member.pack.sources) as any[]){if(source.reference.includes(':'))continue;const a=new Uint8Array(await Bun.file(join(member.path,'../'+source.reference)).arrayBuffer()),b=new Uint8Array(await Bun.file(join(dir,'export',member.pack.id+'@1.1.0',source.reference)).arrayBuffer());expect(b).toEqual(a);} + for(const member of await resolveDomainFamily(root))await cp(join(member.path,'..'),join(dir,member.pack.id),{recursive:true}); + const copy=join(dir,'medical/pack.json'),parent=await Bun.file(copy).json();parent.composition.components[0].version='9.0.0';await Bun.write(copy,JSON.stringify(parent));expect((await run(copy,join(dir,'blocked'))).stderr).toContain('version');expect(await stat(join(dir,'blocked')).then(()=>true,()=>false)).toBe(false); + parent.composition.components[0].version='1.1.0';parent.composition.components[0].checksum.value='0'.repeat(64);await Bun.write(copy,JSON.stringify(parent));expect((await run(copy,join(dir,'blocked'))).stderr).toContain('checksum'); + const child=join(dir,'medical-carrier/pack.json'),metadata=await Bun.file(child).json();metadata.sources.cms_carrier.license.redistribution='unknown';const text=JSON.stringify(metadata);await Bun.write(child,text);parent.composition.components[0].checksum.value=new Bun.CryptoHasher('sha256').update(text).digest('hex');await Bun.write(copy,JSON.stringify(parent));expect((await run(copy,join(dir,'blocked'))).stderr).toContain('redistribution');expect(await stat(join(dir,'blocked')).then(()=>true,()=>false)).toBe(false); + }finally{await rm(dir,{recursive:true,force:true});} +},30000); diff --git a/tests/domain-packs/medical-subpacks.test.ts b/tests/domain-packs/medical-subpacks.test.ts index 0380a4653..29e72a9a7 100644 --- a/tests/domain-packs/medical-subpacks.test.ts +++ b/tests/domain-packs/medical-subpacks.test.ts @@ -23,7 +23,7 @@ const run=async(args:string[])=>{ expect(t.payments![0]!.amount).toBe('100.47'); expect(t.resource_references!.every(r=>r.target_key===null)).toBe(true); const carrier=await Bun.file(root+'/medical-carrier/pack.json').json(); - expect(carrier.schemas.map((s:any)=>s.id)).toEqual(['resources','coverage','eligibility','claims','claim_lines','adjudications','payments','plans','enrollments','resource_references','coded_values','workflow_events']); + expect(carrier.schemas.map((s:any)=>s.id)).toEqual(['resources','coverage','eligibility','claims','claim_lines','adjudications','payments','plans','enrollments','resource_references','coded_values','workflow_events','cms_beneficiaries','cms_inpatient_claims','cms_carrier_claims','ontology']); const positive=JSON.parse(await read('medical-carrier','supplement-eligibility-positive-response.json')); const negative=JSON.parse(await read('medical-carrier','supplement-eligibility-negative-response.json')); expect(positive.insurance[0].inforce).toBe(true);expect(negative.insurance[0].inforce).toBe(false); @@ -99,7 +99,7 @@ const run=async(args:string[])=>{ for(const id of packs){ const pack=await Bun.file(root+'/'+id+'/pack.json').json(); expect(createValidator().compile(generateDomainPackSchema())(pack)).toBe(true);expect(pack.generator).toBeUndefined(); - for(const s of pack.schemas){const text=await Bun.file(root+'/'+id+'/'+s.reference).text();expect(exportTableSpec(importTableSpec(text,{id:s.id,format:'json'}))).toBe(text);} + for(const s of pack.schemas.filter((s:any)=>s.format==='tablespec')){const text=await Bun.file(root+'/'+id+'/'+s.reference).text();expect(exportTableSpec(importTableSpec(text,{id:s.id,format:'json'}))).toBe(text);} for(const source of Object.values(pack.sources) as any[]){ if(source.reference.includes(':')){expect(source.license.redistribution).toBe('unknown');continue;} const bytes=await Bun.file(root+'/'+id+'/'+source.reference).arrayBuffer();