hra-api
Version:
The Human Reference Atlas (HRA) API deployed to https://apps.humanatlas.io/api/
392 lines • 1.89 MB
JavaScript
const SPARQL_ENDPOINT = 'https://lod.humanatlas.io/sparql';
var W_e=Object.create;var HR=Object.defineProperty;var H_e=Object.getOwnPropertyDescriptor;var V_e=Object.getOwnPropertyNames;var z_e=Object.getPrototypeOf,$_e=Object.prototype.hasOwnProperty;var L=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),Eo=(t,e)=>{for(var r in e)HR(t,r,{get:e[r],enumerable:!0})},
X_e=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of V_e(e))!$_e.call(t,o)&&o!==r&&HR(t,o,{get:()=>e[o],
enumerable:!(n=H_e(e,o))||n.enumerable});return t};var er=(t,e,r)=>(r=t!=null?W_e(z_e(t)):{},X_e(e||!t||!t.__esModule?HR(r,"default",{value:t,enumerable:!0}):r,t));var Zg=L((zR,$R)=>{(function(t,e){typeof define=="function"&&define.amd?define([],e):typeof $R=="object"&&typeof zR<"u"?
$R.exports=e():t.Papa=e()})(zR,function t(){"use strict";var e=typeof self<"u"?self:typeof window<"u"?window:e!==void 0?
e:{},r=!e.document&&!!e.postMessage,n=e.IS_PAPA_WORKER||!1,o={},s=0,a={parse:function(x,R){var D=(R=R||{}).dynamicTyping||
!1;if(S(D)&&(R.dynamicTypingFunction=D,D={}),R.dynamicTyping=D,R.transform=!!S(R.transform)&&R.transform,R.worker&&a.WORKERS_SUPPORTED){
var B=function(){if(!a.WORKERS_SUPPORTED)return!1;var F=(P=e.URL||e.webkitURL||null,G=t.toString(),a.BLOB_URL||(a.BLOB_URL=
P.createObjectURL(new Blob(["var global = (function() { if (typeof self !== 'undefined') { return self; } if (typeof win\
dow !== 'undefined') { return window; } if (typeof global !== 'undefined') { return global; } return {}; })(); global.IS\
_PAPA_WORKER=true; ","(",G,")();"],{type:"text/javascript"})))),O=new e.Worker(F),P,G;return O.onmessage=m,O.id=s++,o[O.
id]=O}();return B.userStep=R.step,B.userChunk=R.chunk,B.userComplete=R.complete,B.userError=R.error,R.step=S(R.step),R.chunk=
S(R.chunk),R.complete=S(R.complete),R.error=S(R.error),delete R.worker,void B.postMessage({input:x,config:R,workerId:B.id})}
var A=null;return a.NODE_STREAM_INPUT,typeof x=="string"?(x=function(F){return F.charCodeAt(0)===65279?F.slice(1):F}(x),
A=R.download?new u(R):new d(R)):x.readable===!0&&S(x.read)&&S(x.on)?A=new h(R):(e.File&&x instanceof File||x instanceof Object)&&
(A=new f(R)),A.stream(x)},unparse:function(x,R){var D=!1,B=!0,A=",",F=`\r
`,O='"',P=O+O,G=!1,q=null,j=!1;(function(){if(typeof R=="object"){if(typeof R.delimiter!="string"||a.BAD_DELIMITERS.filter(
function(V){return R.delimiter.indexOf(V)!==-1}).length||(A=R.delimiter),(typeof R.quotes=="boolean"||typeof R.quotes=="\
function"||Array.isArray(R.quotes))&&(D=R.quotes),typeof R.skipEmptyLines!="boolean"&&typeof R.skipEmptyLines!="string"||
(G=R.skipEmptyLines),typeof R.newline=="string"&&(F=R.newline),typeof R.quoteChar=="string"&&(O=R.quoteChar),typeof R.header==
"boolean"&&(B=R.header),Array.isArray(R.columns)){if(R.columns.length===0)throw new Error("Option columns is empty");q=R.
columns}R.escapeChar!==void 0&&(P=R.escapeChar+O),(typeof R.escapeFormulae=="boolean"||R.escapeFormulae instanceof RegExp)&&
(j=R.escapeFormulae instanceof RegExp?R.escapeFormulae:/^[=+\-@\t\r].*$/)}})();var X=new RegExp(y(O),"g");if(typeof x=="\
string"&&(x=JSON.parse(x)),Array.isArray(x)){if(!x.length||Array.isArray(x[0]))return K(null,x,G);if(typeof x[0]=="objec\
t")return K(q||Object.keys(x[0]),x,G)}else if(typeof x=="object")return typeof x.data=="string"&&(x.data=JSON.parse(x.data)),
Array.isArray(x.data)&&(x.fields||(x.fields=x.meta&&x.meta.fields||q),x.fields||(x.fields=Array.isArray(x.data[0])?x.fields:
typeof x.data[0]=="object"?Object.keys(x.data[0]):[]),Array.isArray(x.data[0])||typeof x.data[0]=="object"||(x.data=[x.data])),
K(x.fields||[],x.data||[],G);throw new Error("Unable to serialize unrecognized input");function K(V,te,Z){var oe="";typeof V==
"string"&&(V=JSON.parse(V)),typeof te=="string"&&(te=JSON.parse(te));var ie=Array.isArray(V)&&0<V.length,se=!Array.isArray(
te[0]);if(ie&&B){for(var J=0;J<V.length;J++)0<J&&(oe+=A),oe+=Y(V[J],J);0<te.length&&(oe+=F)}for(var z=0;z<te.length;z++){
var ne=ie?V.length:te[z].length,Be=!1,be=ie?Object.keys(te[z]).length===0:te[z].length===0;if(Z&&!ie&&(Be=Z==="greedy"?te[z].
join("").trim()==="":te[z].length===1&&te[z][0].length===0),Z==="greedy"&&ie){for(var Le=[],Oe=0;Oe<ne;Oe++){var De=se?V[Oe]:
Oe;Le.push(te[z][De])}Be=Le.join("").trim()===""}if(!Be){for(var Ne=0;Ne<ne;Ne++){0<Ne&&!be&&(oe+=A);var Ue=ie&&se?V[Ne]:
Ne;oe+=Y(te[z][Ue],Ne)}z<te.length-1&&(!Z||0<ne&&!be)&&(oe+=F)}}return oe}function Y(V,te){if(V==null)return"";if(V.constructor===
Date)return JSON.stringify(V).slice(1,25);var Z=!1;j&&typeof V=="string"&&j.test(V)&&(V="'"+V,Z=!0);var oe=V.toString().
replace(X,P);return(Z=Z||D===!0||typeof D=="function"&&D(V,te)||Array.isArray(D)&&D[te]||function(ie,se){for(var J=0;J<se.
length;J++)if(-1<ie.indexOf(se[J]))return!0;return!1}(oe,a.BAD_DELIMITERS)||-1<oe.indexOf(A)||oe.charAt(0)===" "||oe.charAt(
oe.length-1)===" ")?O+oe+O:oe}}};if(a.RECORD_SEP=String.fromCharCode(30),a.UNIT_SEP=String.fromCharCode(31),a.BYTE_ORDER_MARK=
"\uFEFF",a.BAD_DELIMITERS=["\r",`
`,'"',a.BYTE_ORDER_MARK],a.WORKERS_SUPPORTED=!r&&!!e.Worker,a.NODE_STREAM_INPUT=1,a.LocalChunkSize=10485760,a.RemoteChunkSize=
5242880,a.DefaultDelimiter=",",a.Parser=g,a.ParserHandle=p,a.NetworkStreamer=u,a.FileStreamer=f,a.StringStreamer=d,a.ReadableStreamStreamer=
h,e.jQuery){var l=e.jQuery;l.fn.parse=function(x){var R=x.config||{},D=[];return this.each(function(F){if(!(l(this).prop(
"tagName").toUpperCase()==="INPUT"&&l(this).attr("type").toLowerCase()==="file"&&e.FileReader)||!this.files||this.files.
length===0)return!0;for(var O=0;O<this.files.length;O++)D.push({file:this.files[O],inputElem:this,instanceConfig:l.extend(
{},R)})}),B(),this;function B(){if(D.length!==0){var F,O,P,G,q=D[0];if(S(x.before)){var j=x.before(q.file,q.inputElem);if(typeof j==
"object"){if(j.action==="abort")return F="AbortError",O=q.file,P=q.inputElem,G=j.reason,void(S(x.error)&&x.error({name:F},
O,P,G));if(j.action==="skip")return void A();typeof j.config=="object"&&(q.instanceConfig=l.extend(q.instanceConfig,j.config))}else if(j===
"skip")return void A()}var X=q.instanceConfig.complete;q.instanceConfig.complete=function(K){S(X)&&X(K,q.file,q.inputElem),
A()},a.parse(q.file,q.instanceConfig)}else S(x.complete)&&x.complete()}function A(){D.splice(0,1),B()}}}function c(x){this.
_handle=null,this._finished=!1,this._completed=!1,this._halted=!1,this._input=null,this._baseIndex=0,this._partialLine="",
this._rowCount=0,this._start=0,this._nextChunk=null,this.isFirstChunk=!0,this._completeResults={data:[],errors:[],meta:{}},
function(R){var D=E(R);D.chunkSize=parseInt(D.chunkSize),R.step||R.chunk||(D.chunkSize=null),this._handle=new p(D),(this.
_handle.streamer=this)._config=D}.call(this,x),this.parseChunk=function(R,D){if(this.isFirstChunk&&S(this._config.beforeFirstChunk)){
var B=this._config.beforeFirstChunk(R);B!==void 0&&(R=B)}this.isFirstChunk=!1,this._halted=!1;var A=this._partialLine+R;
this._partialLine="";var F=this._handle.parse(A,this._baseIndex,!this._finished);if(!this._handle.paused()&&!this._handle.
aborted()){var O=F.meta.cursor;this._finished||(this._partialLine=A.substring(O-this._baseIndex),this._baseIndex=O),F&&F.
data&&(this._rowCount+=F.data.length);var P=this._finished||this._config.preview&&this._rowCount>=this._config.preview;if(n)
e.postMessage({results:F,workerId:a.WORKER_ID,finished:P});else if(S(this._config.chunk)&&!D){if(this._config.chunk(F,this.
_handle),this._handle.paused()||this._handle.aborted())return void(this._halted=!0);F=void 0,this._completeResults=void 0}
return this._config.step||this._config.chunk||(this._completeResults.data=this._completeResults.data.concat(F.data),this.
_completeResults.errors=this._completeResults.errors.concat(F.errors),this._completeResults.meta=F.meta),this._completed||
!P||!S(this._config.complete)||F&&F.meta.aborted||(this._config.complete(this._completeResults,this._input),this._completed=
!0),P||F&&F.meta.paused||this._nextChunk(),F}this._halted=!0},this._sendError=function(R){S(this._config.error)?this._config.
error(R):n&&this._config.error&&e.postMessage({workerId:a.WORKER_ID,error:R,finished:!1})}}function u(x){var R;(x=x||{}).
chunkSize||(x.chunkSize=a.RemoteChunkSize),c.call(this,x),this._nextChunk=r?function(){this._readChunk(),this._chunkLoaded()}:
function(){this._readChunk()},this.stream=function(D){this._input=D,this._nextChunk()},this._readChunk=function(){if(this.
_finished)this._chunkLoaded();else{if(R=new XMLHttpRequest,this._config.withCredentials&&(R.withCredentials=this._config.
withCredentials),r||(R.onload=_(this._chunkLoaded,this),R.onerror=_(this._chunkError,this)),R.open(this._config.downloadRequestBody?
"POST":"GET",this._input,!r),this._config.downloadRequestHeaders){var D=this._config.downloadRequestHeaders;for(var B in D)
R.setRequestHeader(B,D[B])}if(this._config.chunkSize){var A=this._start+this._config.chunkSize-1;R.setRequestHeader("Ran\
ge","bytes="+this._start+"-"+A)}try{R.send(this._config.downloadRequestBody)}catch(F){this._chunkError(F.message)}r&&R.status===
0&&this._chunkError()}},this._chunkLoaded=function(){R.readyState===4&&(R.status<200||400<=R.status?this._chunkError():(this.
_start+=this._config.chunkSize?this._config.chunkSize:R.responseText.length,this._finished=!this._config.chunkSize||this.
_start>=function(D){var B=D.getResponseHeader("Content-Range");return B===null?-1:parseInt(B.substring(B.lastIndexOf("/")+
1))}(R),this.parseChunk(R.responseText)))},this._chunkError=function(D){var B=R.statusText||D;this._sendError(new Error(
B))}}function f(x){var R,D;(x=x||{}).chunkSize||(x.chunkSize=a.LocalChunkSize),c.call(this,x);var B=typeof FileReader<"u";
this.stream=function(A){this._input=A,D=A.slice||A.webkitSlice||A.mozSlice,B?((R=new FileReader).onload=_(this._chunkLoaded,
this),R.onerror=_(this._chunkError,this)):R=new FileReaderSync,this._nextChunk()},this._nextChunk=function(){this._finished||
this._config.preview&&!(this._rowCount<this._config.preview)||this._readChunk()},this._readChunk=function(){var A=this._input;
if(this._config.chunkSize){var F=Math.min(this._start+this._config.chunkSize,this._input.size);A=D.call(A,this._start,F)}
var O=R.readAsText(A,this._config.encoding);B||this._chunkLoaded({target:{result:O}})},this._chunkLoaded=function(A){this.
_start+=this._config.chunkSize,this._finished=!this._config.chunkSize||this._start>=this._input.size,this.parseChunk(A.target.
result)},this._chunkError=function(){this._sendError(R.error)}}function d(x){var R;c.call(this,x=x||{}),this.stream=function(D){
return R=D,this._nextChunk()},this._nextChunk=function(){if(!this._finished){var D,B=this._config.chunkSize;return B?(D=
R.substring(0,B),R=R.substring(B)):(D=R,R=""),this._finished=!R,this.parseChunk(D)}}}function h(x){c.call(this,x=x||{});
var R=[],D=!0,B=!1;this.pause=function(){c.prototype.pause.apply(this,arguments),this._input.pause()},this.resume=function(){
c.prototype.resume.apply(this,arguments),this._input.resume()},this.stream=function(A){this._input=A,this._input.on("dat\
a",this._streamData),this._input.on("end",this._streamEnd),this._input.on("error",this._streamError)},this._checkIsFinished=
function(){B&&R.length===1&&(this._finished=!0)},this._nextChunk=function(){this._checkIsFinished(),R.length?this.parseChunk(
R.shift()):D=!0},this._streamData=_(function(A){try{R.push(typeof A=="string"?A:A.toString(this._config.encoding)),D&&(D=
!1,this._checkIsFinished(),this.parseChunk(R.shift()))}catch(F){this._streamError(F)}},this),this._streamError=_(function(A){
this._streamCleanUp(),this._sendError(A)},this),this._streamEnd=_(function(){this._streamCleanUp(),B=!0,this._streamData(
"")},this),this._streamCleanUp=_(function(){this._input.removeListener("data",this._streamData),this._input.removeListener(
"end",this._streamEnd),this._input.removeListener("error",this._streamError)},this)}function p(x){var R,D,B,A=Math.pow(2,
53),F=-A,O=/^\s*-?(\d+\.?|\.\d+|\d+\.\d+)([eE][-+]?\d+)?\s*$/,P=/^((\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z)))$/,
G=this,q=0,j=0,X=!1,K=!1,Y=[],V={data:[],errors:[],meta:{}};if(S(x.step)){var te=x.step;x.step=function(z){if(V=z,ie())oe();else{
if(oe(),V.data.length===0)return;q+=z.data.length,x.preview&&q>x.preview?D.abort():(V.data=V.data[0],te(V,G))}}}function Z(z){
return x.skipEmptyLines==="greedy"?z.join("").trim()==="":z.length===1&&z[0].length===0}function oe(){return V&&B&&(J("D\
elimiter","UndetectableDelimiter","Unable to auto-detect delimiting character; defaulted to '"+a.DefaultDelimiter+"'"),B=
!1),x.skipEmptyLines&&(V.data=V.data.filter(function(z){return!Z(z)})),ie()&&function(){if(!V)return;function z(Be,be){S(
x.transformHeader)&&(Be=x.transformHeader(Be,be)),Y.push(Be)}if(Array.isArray(V.data[0])){for(var ne=0;ie()&&ne<V.data.length;ne++)
V.data[ne].forEach(z);V.data.splice(0,1)}else V.data.forEach(z)}(),function(){if(!V||!x.header&&!x.dynamicTyping&&!x.transform)
return V;function z(Be,be){var Le,Oe=x.header?{}:[];for(Le=0;Le<Be.length;Le++){var De=Le,Ne=Be[Le];x.header&&(De=Le>=Y.
length?"__parsed_extra":Y[Le]),x.transform&&(Ne=x.transform(Ne,De)),Ne=se(De,Ne),De==="__parsed_extra"?(Oe[De]=Oe[De]||[],
Oe[De].push(Ne)):Oe[De]=Ne}return x.header&&(Le>Y.length?J("FieldMismatch","TooManyFields","Too many fields: expected "+
Y.length+" fields but parsed "+Le,j+be):Le<Y.length&&J("FieldMismatch","TooFewFields","Too few fields: expected "+Y.length+
" fields but parsed "+Le,j+be)),Oe}var ne=1;return!V.data.length||Array.isArray(V.data[0])?(V.data=V.data.map(z),ne=V.data.
length):V.data=z(V.data,0),x.header&&V.meta&&(V.meta.fields=Y),j+=ne,V}()}function ie(){return x.header&&Y.length===0}function se(z,ne){
return Be=z,x.dynamicTypingFunction&&x.dynamicTyping[Be]===void 0&&(x.dynamicTyping[Be]=x.dynamicTypingFunction(Be)),(x.
dynamicTyping[Be]||x.dynamicTyping)===!0?ne==="true"||ne==="TRUE"||ne!=="false"&&ne!=="FALSE"&&(function(be){if(O.test(be)){
var Le=parseFloat(be);if(F<Le&&Le<A)return!0}return!1}(ne)?parseFloat(ne):P.test(ne)?new Date(ne):ne===""?null:ne):ne;var Be}
function J(z,ne,Be,be){var Le={type:z,code:ne,message:Be};be!==void 0&&(Le.row=be),V.errors.push(Le)}this.parse=function(z,ne,Be){
var be=x.quoteChar||'"';if(x.newline||(x.newline=function(De,Ne){De=De.substring(0,1048576);var Ue=new RegExp(y(Ne)+"([^\
]*?)"+y(Ne),"gm"),Ve=(De=De.replace(Ue,"")).split("\r"),st=De.split(`
`),Ye=1<st.length&&st[0].length<Ve[0].length;if(Ve.length===1||Ye)return`
`;for(var tt=0,ze=0;ze<Ve.length;ze++)Ve[ze][0]===`
`&&tt++;return tt>=Ve.length/2?`\r
`:"\r"}(z,be)),B=!1,x.delimiter)S(x.delimiter)&&(x.delimiter=x.delimiter(z),V.meta.delimiter=x.delimiter);else{var Le=function(De,Ne,Ue,Ve,st){
var Ye,tt,ze,it;st=st||[","," ","|",";",a.RECORD_SEP,a.UNIT_SEP];for(var jt=0;jt<st.length;jt++){var rt=st[jt],Kr=0,Zt=0,
Qn=0;ze=void 0;for(var Zn=new g({comments:Ve,delimiter:rt,newline:Ne,preview:10}).parse(De),Nr=0;Nr<Zn.data.length;Nr++)
if(Ue&&Z(Zn.data[Nr]))Qn++;else{var W=Zn.data[Nr].length;Zt+=W,ze!==void 0?0<W&&(Kr+=Math.abs(W-ze),ze=W):ze=W}0<Zn.data.
length&&(Zt/=Zn.data.length-Qn),(tt===void 0||Kr<=tt)&&(it===void 0||it<Zt)&&1.99<Zt&&(tt=Kr,Ye=rt,it=Zt)}return{successful:!!(x.
delimiter=Ye),bestDelimiter:Ye}}(z,x.newline,x.skipEmptyLines,x.comments,x.delimitersToGuess);Le.successful?x.delimiter=
Le.bestDelimiter:(B=!0,x.delimiter=a.DefaultDelimiter),V.meta.delimiter=x.delimiter}var Oe=E(x);return x.preview&&x.header&&
Oe.preview++,R=z,D=new g(Oe),V=D.parse(R,ne,Be),oe(),X?{meta:{paused:!0}}:V||{meta:{paused:!1}}},this.paused=function(){
return X},this.pause=function(){X=!0,D.abort(),R=S(x.chunk)?"":R.substring(D.getCharIndex())},this.resume=function(){G.streamer.
_halted?(X=!1,G.streamer.parseChunk(R,!0)):setTimeout(G.resume,3)},this.aborted=function(){return K},this.abort=function(){
K=!0,D.abort(),V.meta.aborted=!0,S(x.complete)&&x.complete(V),R=""}}function y(x){return x.replace(/[.*+?^${}()|[\]\\]/g,
"\\$&")}function g(x){var R,D=(x=x||{}).delimiter,B=x.newline,A=x.comments,F=x.step,O=x.preview,P=x.fastMode,G=R=x.quoteChar===
void 0||x.quoteChar===null?'"':x.quoteChar;if(x.escapeChar!==void 0&&(G=x.escapeChar),(typeof D!="string"||-1<a.BAD_DELIMITERS.
indexOf(D))&&(D=","),A===D)throw new Error("Comment character same as delimiter");A===!0?A="#":(typeof A!="string"||-1<a.
BAD_DELIMITERS.indexOf(A))&&(A=!1),B!==`
`&&B!=="\r"&&B!==`\r
`&&(B=`
`);var q=0,j=!1;this.parse=function(X,K,Y){if(typeof X!="string")throw new Error("Input must be a string");var V=X.length,
te=D.length,Z=B.length,oe=A.length,ie=S(F),se=[],J=[],z=[],ne=q=0;if(!X)return $();if(x.header&&!K){var Be=X.split(B)[0].
split(D),be=[],Le={},Oe=!1;for(var De in Be){var Ne=Be[De];S(x.transformHeader)&&(Ne=x.transformHeader(Ne,De));var Ue=Ne,
Ve=Le[Ne]||0;for(0<Ve&&(Oe=!0,Ue=Ne+"_"+Ve),Le[Ne]=Ve+1;be.includes(Ue);)Ue=Ue+"_"+Ve;be.push(Ue)}if(Oe){var st=X.split(
B);st[0]=be.join(D),X=st.join(B)}}if(P||P!==!1&&X.indexOf(R)===-1){for(var Ye=X.split(B),tt=0;tt<Ye.length;tt++){if(z=Ye[tt],
q+=z.length,tt!==Ye.length-1)q+=B.length;else if(Y)return $();if(!A||z.substring(0,oe)!==A){if(ie){if(se=[],Qn(z.split(D)),
re(),j)return $()}else Qn(z.split(D));if(O&&O<=tt)return se=se.slice(0,O),$(!0)}}return $()}for(var ze=X.indexOf(D,q),it=X.
indexOf(B,q),jt=new RegExp(y(G)+y(R),"g"),rt=X.indexOf(R,q);;)if(X[q]!==R)if(A&&z.length===0&&X.substring(q,q+oe)===A){if(it===
-1)return $();q=it+Z,it=X.indexOf(B,q),ze=X.indexOf(D,q)}else if(ze!==-1&&(ze<it||it===-1))z.push(X.substring(q,ze)),q=ze+
te,ze=X.indexOf(D,q);else{if(it===-1)break;if(z.push(X.substring(q,it)),W(it+Z),ie&&(re(),j))return $();if(O&&se.length>=
O)return $(!0)}else for(rt=q,q++;;){if((rt=X.indexOf(R,rt+1))===-1)return Y||J.push({type:"Quotes",code:"MissingQuotes",
message:"Quoted field unterminated",row:se.length,index:q}),Nr();if(rt===V-1)return Nr(X.substring(q,rt).replace(jt,R));
if(R!==G||X[rt+1]!==G){if(R===G||rt===0||X[rt-1]!==G){ze!==-1&&ze<rt+1&&(ze=X.indexOf(D,rt+1)),it!==-1&&it<rt+1&&(it=X.indexOf(
B,rt+1));var Kr=Zn(it===-1?ze:Math.min(ze,it));if(X.substr(rt+1+Kr,te)===D){z.push(X.substring(q,rt).replace(jt,R)),X[q=
rt+1+Kr+te]!==R&&(rt=X.indexOf(R,q)),ze=X.indexOf(D,q),it=X.indexOf(B,q);break}var Zt=Zn(it);if(X.substring(rt+1+Zt,rt+1+
Zt+Z)===B){if(z.push(X.substring(q,rt).replace(jt,R)),W(rt+1+Zt+Z),ze=X.indexOf(D,q),rt=X.indexOf(R,q),ie&&(re(),j))return $();
if(O&&se.length>=O)return $(!0);break}J.push({type:"Quotes",code:"InvalidQuotes",message:"Trailing quote on quoted field\
is malformed",row:se.length,index:q}),rt++}}else rt++}return Nr();function Qn(ae){se.push(ae),ne=q}function Zn(ae){var Ae=0;
if(ae!==-1){var we=X.substring(rt+1,ae);we&&we.trim()===""&&(Ae=we.length)}return Ae}function Nr(ae){return Y||(ae===void 0&&
(ae=X.substring(q)),z.push(ae),q=V,Qn(z),ie&&re()),$()}function W(ae){q=ae,Qn(z),z=[],it=X.indexOf(B,q)}function $(ae){return{
data:se,errors:J,meta:{delimiter:D,linebreak:B,aborted:j,truncated:!!ae,cursor:ne+(K||0)}}}function re(){F($()),se=[],J=
[]}},this.abort=function(){j=!0},this.getCharIndex=function(){return q}}function m(x){var R=x.data,D=o[R.workerId],B=!1;
if(R.error)D.userError(R.error,R.file);else if(R.results&&R.results.data){var A={abort:function(){B=!0,b(R.workerId,{data:[],
errors:[],meta:{aborted:!0}})},pause:w,resume:w};if(S(D.userStep)){for(var F=0;F<R.results.data.length&&(D.userStep({data:R.
results.data[F],errors:R.results.errors,meta:R.results.meta},A),!B);F++);delete R.results}else S(D.userChunk)&&(D.userChunk(
R.results,A,R.file),delete R.results)}R.finished&&!B&&b(R.workerId,R.results)}function b(x,R){var D=o[x];S(D.userComplete)&&
D.userComplete(R),D.terminate(),delete o[x]}function w(){throw new Error("Not implemented.")}function E(x){if(typeof x!=
"object"||x===null)return x;var R=Array.isArray(x)?[]:{};for(var D in x)R[D]=E(x[D]);return R}function _(x,R){return function(){
x.apply(R,arguments)}}function S(x){return typeof x=="function"}return n&&(e.onmessage=function(x){var R=x.data;if(a.WORKER_ID===
void 0&&R&&(a.WORKER_ID=R.workerId),typeof R.input=="string")e.postMessage({workerId:a.WORKER_ID,results:a.parse(R.input,
R.config),finished:!0});else if(e.File&&R.input instanceof File||R.input instanceof Object){var D=a.parse(R.input,R.config);
D&&e.postMessage({workerId:a.WORKER_ID,results:D,finished:!0})}}),(u.prototype=Object.create(c.prototype)).constructor=u,
(f.prototype=Object.create(c.prototype)).constructor=f,(d.prototype=Object.create(d.prototype)).constructor=d,(h.prototype=
Object.create(c.prototype)).constructor=h,a})});var Ew=L((o_t,F4)=>{"use strict";F4.exports=class C4{constructor(e,r=new Map,n=0){this.prefix=e,this._existing=r,this.counter=
n}clone(){let{prefix:e,_existing:r,counter:n}=this;return new C4(e,new Map(r),n)}getId(e){let r=e&&this._existing.get(e);
if(r)return r;let n=this.prefix+this.counter;return this.counter++,e&&this._existing.set(e,n),n}hasId(e){return this._existing.
has(e)}getOldIds(){return[...this._existing.keys()]}}});var M4=L(N4=>{(function(t,e){"use strict";if(t.setImmediate)return;var r=1,n={},o=!1,s=t.document,a;function l(w){typeof w!=
"function"&&(w=new Function(""+w));for(var E=new Array(arguments.length-1),_=0;_<E.length;_++)E[_]=arguments[_+1];var S={
callback:w,args:E};return n[r]=S,a(r),r++}function c(w){delete n[w]}function u(w){var E=w.callback,_=w.args;switch(_.length){case 0:
E();break;case 1:E(_[0]);break;case 2:E(_[0],_[1]);break;case 3:E(_[0],_[1],_[2]);break;default:E.apply(e,_);break}}function f(w){
if(o)setTimeout(f,0,w);else{var E=n[w];if(E){o=!0;try{u(E)}finally{c(w),o=!1}}}}function d(){a=function(w){process.nextTick(
function(){f(w)})}}function h(){if(t.postMessage&&!t.importScripts){var w=!0,E=t.onmessage;return t.onmessage=function(){
w=!1},t.postMessage("","*"),t.onmessage=E,w}}function p(){var w="setImmediate$"+Math.random()+"$",E=function(_){_.source===
t&&typeof _.data=="string"&&_.data.indexOf(w)===0&&f(+_.data.slice(w.length))};t.addEventListener?t.addEventListener("me\
ssage",E,!1):t.attachEvent("onmessage",E),a=function(_){t.postMessage(w+_,"*")}}function y(){var w=new MessageChannel;w.
port1.onmessage=function(E){var _=E.data;f(_)},a=function(E){w.port2.postMessage(E)}}function g(){var w=s.documentElement;
a=function(E){var _=s.createElement("script");_.onreadystatechange=function(){f(E),_.onreadystatechange=null,w.removeChild(
_),_=null},w.appendChild(_)}}function m(){a=function(w){setTimeout(f,0,w)}}var b=Object.getPrototypeOf&&Object.getPrototypeOf(
t);b=b&&b.setTimeout?b:t,{}.toString.call(t.process)==="[object process]"?d():h()?p():t.MessageChannel?y():s&&"onreadyst\
atechange"in s.createElement("script")?g():m(),b.setImmediate=l,b.clearImmediate=c})(typeof self>"u"?typeof global>"u"?N4:
global:self)});var ey=L((l_t,O4)=>{"use strict";M4();var XR=self.crypto||self.msCrypto;O4.exports=class{constructor(e){if(!(XR&&XR.subtle))
throw new Error("crypto.subtle not found.");if(e==="sha256")this.algorithm={name:"SHA-256"};else if(e==="sha1")this.algorithm=
{name:"SHA-1"};else throw new Error(`Unsupported algorithm "${e}".`);this._content=""}update(e){this._content+=e}async digest(){
let e=new TextEncoder().encode(this._content),r=new Uint8Array(await XR.subtle.digest(this.algorithm,e)),n="";for(let o=0;o<
r.length;++o)n+=r[o].toString(16).padStart(2,"0");return n}}});var JR=L((c_t,L4)=>{"use strict";L4.exports=class{constructor(e){this.current=e.sort(),this.done=!1,this.dir=new Map;for(let r=0;r<
e.length;++r)this.dir.set(e[r],!0)}hasNext(){return!this.done}next(){let{current:e,dir:r}=this,n=e.slice(),o=null,s=0,a=e.
length;for(let l=0;l<a;++l){let c=e[l],u=r.get(c);(o===null||c>o)&&(u&&l>0&&c>e[l-1]||!u&&l<a-1&&c>e[l+1])&&(o=c,s=l)}if(o===
null)this.done=!0;else{let l=r.get(o)?s-1:s+1;e[s]=e[l],e[l]=o;for(let c of e)c>o&&r.set(c,!r.get(c))}return n}}});var Sw=L((f_t,k4)=>{"use strict";var eEe="http://www.w3.org/1999/02/22-rdf-syntax-ns#",YR=eEe+"langString",KR="http://ww\
w.w3.org/2001/XMLSchema#string",Zo="NamedNode",Oc="BlankNode",xw="Literal",P4="DefaultGraph",uh={};(()=>{let t="(?:<([^:\
]+:[^>]*)>)",r="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"+
"_",n=r+"0-9-\xB7\u0300-\u036F\u203F-\u2040",s="(_:(?:["+r+"0-9])(?:(?:["+n+".])*(?:["+n+"]))?)",a='"([^"\\\\]*(?:\\\\.[^"\\\\\
]*)*)"',l="(?:\\^\\^"+t+")",c="(?:@([a-zA-Z]+(?:-[a-zA-Z0-9]+)*))",u="(?:"+a+"(?:"+l+"|"+c+")?)",f="[ \\t]+",d="[ \\t]*",
h="(?:"+t+"|"+s+")"+f,p=t+f,y="(?:"+t+"|"+s+"|"+u+")"+d,g="(?:\\.|(?:(?:"+t+"|"+s+")"+d+"\\.))";uh.eoln=/(?:\r\n)|(?:\n)|(?:\r)/g,
uh.empty=new RegExp("^"+d+"$"),uh.quad=new RegExp("^"+d+h+p+y+g+d+"$")})();k4.exports=class Aw{static parse(e){let r=[],
n={},o=e.split(uh.eoln),s=0;for(let a of o){if(s++,uh.empty.test(a))continue;let l=a.match(uh.quad);if(l===null)throw new Error(
"N-Quads parse error on line "+s+".");let c={subject:null,predicate:null,object:null,graph:null};if(l[1]!==void 0?c.subject=
{termType:Zo,value:l[1]}:c.subject={termType:Oc,value:l[2]},c.predicate={termType:Zo,value:l[3]},l[4]!==void 0?c.object=
{termType:Zo,value:l[4]}:l[5]!==void 0?c.object={termType:Oc,value:l[5]}:(c.object={termType:xw,value:void 0,datatype:{termType:Zo}},
l[7]!==void 0?c.object.datatype.value=l[7]:l[8]!==void 0?(c.object.datatype.value=YR,c.object.language=l[8]):c.object.datatype.
value=KR,c.object.value=oEe(l[6])),l[9]!==void 0?c.graph={termType:Zo,value:l[9]}:l[10]!==void 0?c.graph={termType:Oc,value:l[10]}:
c.graph={termType:P4,value:""},!(c.graph.value in n))n[c.graph.value]=[c],r.push(c);else{let u=!0,f=n[c.graph.value];for(let d of f)
if(tEe(d,c)){u=!1;break}u&&(f.push(c),r.push(c))}}return r}static serialize(e){Array.isArray(e)||(e=Aw.legacyDatasetToQuads(
e));let r=[];for(let n of e)r.push(Aw.serializeQuad(n));return r.sort().join("")}static serializeQuadComponents(e,r,n,o){
let s="";return e.termType===Zo?s+=`<${e.value}>`:s+=`${e.value}`,s+=` <${r.value}> `,n.termType===Zo?s+=`<${n.value}>`:
n.termType===Oc?s+=n.value:(s+=`"${nEe(n.value)}"`,n.datatype.value===YR?n.language&&(s+=`@${n.language}`):n.datatype.value!==
KR&&(s+=`^^<${n.datatype.value}>`)),o.termType===Zo?s+=` <${o.value}>`:o.termType===Oc&&(s+=` ${o.value}`),s+=` .
`,s}static serializeQuad(e){return Aw.serializeQuadComponents(e.subject,e.predicate,e.object,e.graph)}static legacyDatasetToQuads(e){
let r=[],n={"blank node":Oc,IRI:Zo,literal:xw};for(let o in e)e[o].forEach(a=>{let l={};for(let c in a){let u=a[c],f={termType:n[u.
type],value:u.value};f.termType===xw&&(f.datatype={termType:Zo},"datatype"in u&&(f.datatype.value=u.datatype),"language"in
u?("datatype"in u||(f.datatype.value=YR),f.language=u.language):"datatype"in u||(f.datatype.value=KR)),l[c]=f}o==="@defa\
ult"?l.graph={termType:P4,value:""}:l.graph={termType:o.startsWith("_:")?Oc:Zo,value:o},r.push(l)});return r}};function tEe(t,e){
return!(t.subject.termType===e.subject.termType&&t.object.termType===e.object.termType)||!(t.subject.value===e.subject.value&&
t.predicate.value===e.predicate.value&&t.object.value===e.object.value)?!1:t.object.termType!==xw?!0:t.object.datatype.termType===
e.object.datatype.termType&&t.object.language===e.object.language&&t.object.datatype.value===e.object.datatype.value}var rEe=/["\\\n\r]/g;
function nEe(t){return t.replace(rEe,function(e){switch(e){case'"':return'\\"';case"\\":return"\\\\";case`
`:return"\\n";case"\r":return"\\r"}})}var iEe=/(?:\\([tbnrf"'\\]))|(?:\\u([0-9A-Fa-f]{4}))|(?:\\U([0-9A-Fa-f]{8}))/g;function oEe(t){
return t.replace(iEe,function(e,r,n,o){if(r)switch(r){case"t":return" ";case"b":return"\b";case"n":return`
`;case"r":return"\r";case"f":return"\f";case'"':return'"';case"'":return"'";case"\\":return"\\"}if(n)return String.fromCharCode(
parseInt(n,16));if(o)throw new Error("Unsupported U escape")})}});var QR=L((h_t,G4)=>{"use strict";var U4=Ew(),sEe=ey(),aEe=JR(),q4=Sw();G4.exports=class{constructor({createMessageDigest:e=()=>new sEe(
"sha256"),canonicalIdMap:r=new Map,maxDeepIterations:n=1/0}={}){this.name="URDNA2015",this.blankNodeInfo=new Map,this.canonicalIssuer=
new U4("_:c14n",r),this.createMessageDigest=e,this.maxDeepIterations=n,this.quads=null,this.deepIterations=null}async main(e){
this.deepIterations=new Map,this.quads=e;for(let c of e)this._addBlankNodeQuadInfo({quad:c,component:c.subject}),this._addBlankNodeQuadInfo(
{quad:c,component:c.object}),this._addBlankNodeQuadInfo({quad:c,component:c.graph});let r=new Map,n=[...this.blankNodeInfo.
keys()],o=0;for(let c of n)++o%100===0&&await this._yield(),await this._hashAndTrackBlankNode({id:c,hashToBlankNodes:r});
let s=[...r.keys()].sort(),a=[];for(let c of s){let u=r.get(c);if(u.length>1){a.push(u);continue}let f=u[0];this.canonicalIssuer.
getId(f)}for(let c of a){let u=[];for(let f of c){if(this.canonicalIssuer.hasId(f))continue;let d=new U4("_:b");d.getId(
f);let h=await this.hashNDegreeQuads(f,d);u.push(h)}u.sort(lEe);for(let f of u){let d=f.issuer.getOldIds();for(let h of d)
this.canonicalIssuer.getId(h)}}let l=[];for(let c of this.quads){let u=q4.serializeQuadComponents(this._componentWithCanonicalId(
c.subject),c.predicate,this._componentWithCanonicalId(c.object),this._componentWithCanonicalId(c.graph));l.push(u)}return l.
sort(),l.join("")}async hashFirstDegreeQuads(e){let r=[],n=this.blankNodeInfo.get(e),o=n.quads;for(let a of o){let l={subject:null,
predicate:a.predicate,object:null,graph:null};l.subject=this.modifyFirstDegreeComponent(e,a.subject,"subject"),l.object=
this.modifyFirstDegreeComponent(e,a.object,"object"),l.graph=this.modifyFirstDegreeComponent(e,a.graph,"graph"),r.push(q4.
serializeQuad(l))}r.sort();let s=this.createMessageDigest();for(let a of r)s.update(a);return n.hash=await s.digest(),n.
hash}async hashRelatedBlankNode(e,r,n,o){let s;this.canonicalIssuer.hasId(e)?s=this.canonicalIssuer.getId(e):n.hasId(e)?
s=n.getId(e):s=this.blankNodeInfo.get(e).hash;let a=this.createMessageDigest();return a.update(o),o!=="g"&&a.update(this.
getRelatedPredicate(r)),a.update(s),a.digest()}async hashNDegreeQuads(e,r){let n=this.deepIterations.get(e)||0;if(n>this.
maxDeepIterations)throw new Error(`Maximum deep iterations (${this.maxDeepIterations}) exceeded.`);this.deepIterations.set(
e,n+1);let o=this.createMessageDigest(),s=await this.createHashToRelated(e,r),a=[...s.keys()].sort();for(let l of a){o.update(
l);let c="",u,f=new aEe(s.get(l)),d=0;for(;f.hasNext();){let h=f.next();++d%3===0&&await this._yield();let p=r.clone(),y="",
g=[],m=!1;for(let b of h)if(this.canonicalIssuer.hasId(b)?y+=this.canonicalIssuer.getId(b):(p.hasId(b)||g.push(b),y+=p.getId(
b)),c.length!==0&&y>c){m=!0;break}if(!m){for(let b of g){let w=await this.hashNDegreeQuads(b,p);if(y+=p.getId(b),y+=`<${w.
hash}>`,p=w.issuer,c.length!==0&&y>c){m=!0;break}}m||(c.length===0||y<c)&&(c=y,u=p)}}o.update(c),r=u}return{hash:await o.
digest(),issuer:r}}modifyFirstDegreeComponent(e,r){return r.termType!=="BlankNode"?r:{termType:"BlankNode",value:r.value===
e?"_:a":"_:z"}}getRelatedPredicate(e){return`<${e.predicate.value}>`}async createHashToRelated(e,r){let n=new Map,o=this.
blankNodeInfo.get(e).quads,s=0;for(let a of o)++s%100===0&&await this._yield(),await Promise.all([this._addRelatedBlankNodeHash(
{quad:a,component:a.subject,position:"s",id:e,issuer:r,hashToRelated:n}),this._addRelatedBlankNodeHash({quad:a,component:a.
object,position:"o",id:e,issuer:r,hashToRelated:n}),this._addRelatedBlankNodeHash({quad:a,component:a.graph,position:"g",
id:e,issuer:r,hashToRelated:n})]);return n}async _hashAndTrackBlankNode({id:e,hashToBlankNodes:r}){let n=await this.hashFirstDegreeQuads(
e),o=r.get(n);o?o.push(e):r.set(n,[e])}_addBlankNodeQuadInfo({quad:e,component:r}){if(r.termType!=="BlankNode")return;let n=r.
value,o=this.blankNodeInfo.get(n);o?o.quads.add(e):this.blankNodeInfo.set(n,{quads:new Set([e]),hash:null})}async _addRelatedBlankNodeHash({
quad:e,component:r,position:n,id:o,issuer:s,hashToRelated:a}){if(!(r.termType==="BlankNode"&&r.value!==o))return;let l=r.
value,c=await this.hashRelatedBlankNode(l,e,s,n),u=a.get(c);u?u.push(l):a.set(c,[l])}_componentWithCanonicalId(e){return e.
termType==="BlankNode"&&!e.value.startsWith(this.canonicalIssuer.prefix)?{termType:"BlankNode",value:this.canonicalIssuer.
getId(e.value)}:e}async _yield(){return new Promise(e=>setImmediate(e))}};function lEe(t,e){return t.hash<e.hash?-1:t.hash>
e.hash?1:0}});var W4=L((g_t,j4)=>{"use strict";var uEe=ey(),cEe=QR();j4.exports=class extends cEe{constructor(){super(),this.name="URG\
NA2012",this.createMessageDigest=()=>new uEe("sha1")}modifyFirstDegreeComponent(e,r,n){return r.termType!=="BlankNode"?r:
n==="graph"?{termType:"BlankNode",value:"_:g"}:{termType:"BlankNode",value:r.value===e?"_:a":"_:z"}}getRelatedPredicate(e){
return e.predicate.value}async createHashToRelated(e,r){let n=new Map,o=this.blankNodeInfo.get(e).quads,s=0;for(let a of o){
let l,c;if(a.subject.termType==="BlankNode"&&a.subject.value!==e)c=a.subject.value,l="p";else if(a.object.termType==="Bl\
ankNode"&&a.object.value!==e)c=a.object.value,l="r";else continue;++s%100===0&&await this._yield();let u=await this.hashRelatedBlankNode(
c,a,r,l),f=n.get(u);f?f.push(c):n.set(u,[c])}return n}}});var ZR=L((m_t,z4)=>{"use strict";var H4=Ew(),fEe=ey(),dEe=JR(),V4=Sw();z4.exports=class{constructor({createMessageDigest:e=()=>new fEe(
"sha256"),canonicalIdMap:r=new Map,maxDeepIterations:n=1/0}={}){this.name="URDNA2015",this.blankNodeInfo=new Map,this.canonicalIssuer=
new H4("_:c14n",r),this.createMessageDigest=e,this.maxDeepIterations=n,this.quads=null,this.deepIterations=null}main(e){
this.deepIterations=new Map,this.quads=e;for(let l of e)this._addBlankNodeQuadInfo({quad:l,component:l.subject}),this._addBlankNodeQuadInfo(
{quad:l,component:l.object}),this._addBlankNodeQuadInfo({quad:l,component:l.graph});let r=new Map,n=[...this.blankNodeInfo.
keys()];for(let l of n)this._hashAndTrackBlankNode({id:l,hashToBlankNodes:r});let o=[...r.keys()].sort(),s=[];for(let l of o){
let c=r.get(l);if(c.length>1){s.push(c);continue}let u=c[0];this.canonicalIssuer.getId(u)}for(let l of s){let c=[];for(let u of l){
if(this.canonicalIssuer.hasId(u))continue;let f=new H4("_:b");f.getId(u);let d=this.hashNDegreeQuads(u,f);c.push(d)}c.sort(
hEe);for(let u of c){let f=u.issuer.getOldIds();for(let d of f)this.canonicalIssuer.getId(d)}}let a=[];for(let l of this.
quads){let c=V4.serializeQuadComponents(this._componentWithCanonicalId({component:l.subject}),l.predicate,this._componentWithCanonicalId(
{component:l.object}),this._componentWithCanonicalId({component:l.graph}));a.push(c)}return a.sort(),a.join("")}hashFirstDegreeQuads(e){
let r=[],n=this.blankNodeInfo.get(e),o=n.quads;for(let a of o){let l={subject:null,predicate:a.predicate,object:null,graph:null};
l.subject=this.modifyFirstDegreeComponent(e,a.subject,"subject"),l.object=this.modifyFirstDegreeComponent(e,a.object,"ob\
ject"),l.graph=this.modifyFirstDegreeComponent(e,a.graph,"graph"),r.push(V4.serializeQuad(l))}r.sort();let s=this.createMessageDigest();
for(let a of r)s.update(a);return n.hash=s.digest(),n.hash}hashRelatedBlankNode(e,r,n,o){let s;this.canonicalIssuer.hasId(
e)?s=this.canonicalIssuer.getId(e):n.hasId(e)?s=n.getId(e):s=this.blankNodeInfo.get(e).hash;let a=this.createMessageDigest();
return a.update(o),o!=="g"&&a.update(this.getRelatedPredicate(r)),a.update(s),a.digest()}hashNDegreeQuads(e,r){let n=this.
deepIterations.get(e)||0;if(n>this.maxDeepIterations)throw new Error(`Maximum deep iterations (${this.maxDeepIterations}\
) exceeded.`);this.deepIterations.set(e,n+1);let o=this.createMessageDigest(),s=this.createHashToRelated(e,r),a=[...s.keys()].
sort();for(let l of a){o.update(l);let c="",u,f=new dEe(s.get(l));for(;f.hasNext();){let d=f.next(),h=r.clone(),p="",y=[],
g=!1;for(let m of d)if(this.canonicalIssuer.hasId(m)?p+=this.canonicalIssuer.getId(m):(h.hasId(m)||y.push(m),p+=h.getId(
m)),c.length!==0&&p>c){g=!0;break}if(!g){for(let m of y){let b=this.hashNDegreeQuads(m,h);if(p+=h.getId(m),p+=`<${b.hash}\
>`,h=b.issuer,c.length!==0&&p>c){g=!0;break}}g||(c.length===0||p<c)&&(c=p,u=h)}}o.update(c),r=u}return{hash:o.digest(),issuer:r}}modifyFirstDegreeComponent(e,r){
return r.termType!=="BlankNode"?r:{termType:"BlankNode",value:r.value===e?"_:a":"_:z"}}getRelatedPredicate(e){return`<${e.
predicate.value}>`}createHashToRelated(e,r){let n=new Map,o=this.blankNodeInfo.get(e).quads;for(let s of o)this._addRelatedBlankNodeHash(
{quad:s,component:s.subject,position:"s",id:e,issuer:r,hashToRelated:n}),this._addRelatedBlankNodeHash({quad:s,component:s.
object,position:"o",id:e,issuer:r,hashToRelated:n}),this._addRelatedBlankNodeHash({quad:s,component:s.graph,position:"g",
id:e,issuer:r,hashToRelated:n});return n}_hashAndTrackBlankNode({id:e,hashToBlankNodes:r}){let n=this.hashFirstDegreeQuads(
e),o=r.get(n);o?o.push(e):r.set(n,[e])}_addBlankNodeQuadInfo({quad:e,component:r}){if(r.termType!=="BlankNode")return;let n=r.
value,o=this.blankNodeInfo.get(n);o?o.quads.add(e):this.blankNodeInfo.set(n,{quads:new Set([e]),hash:null})}_addRelatedBlankNodeHash({
quad:e,component:r,position:n,id:o,issuer:s,hashToRelated:a}){if(!(r.termType==="BlankNode"&&r.value!==o))return;let l=r.
value,c=this.hashRelatedBlankNode(l,e,s,n),u=a.get(c);u?u.push(l):a.set(c,[l])}_componentWithCanonicalId({component:e}){
return e.termType==="BlankNode"&&!e.value.startsWith(this.canonicalIssuer.prefix)?{termType:"BlankNode",value:this.canonicalIssuer.
getId(e.value)}:e}};function hEe(t,e){return t.hash<e.hash?-1:t.hash>e.hash?1:0}});var X4=L((w_t,$4)=>{"use strict";var pEe=ey(),gEe=ZR();$4.exports=class extends gEe{constructor(){super(),this.name="URG\
NA2012",this.createMessageDigest=()=>new pEe("sha1")}modifyFirstDegreeComponent(e,r,n){return r.termType!=="BlankNode"?r:
n==="graph"?{termType:"BlankNode",value:"_:g"}:{termType:"BlankNode",value:r.value===e?"_:a":"_:z"}}getRelatedPredicate(e){
return e.predicate.value}createHashToRelated(e,r){let n=new Map,o=this.blankNodeInfo.get(e).quads;for(let s of o){let a,
l;if(s.subject.termType==="BlankNode"&&s.subject.value!==e)l=s.subject.value,a="p";else if(s.object.termType==="BlankNod\
e"&&s.object.value!==e)l=s.object.value,a="r";else continue;let c=this.hashRelatedBlankNode(l,s,r,a),u=n.get(c);u?u.push(
l):n.set(c,[l])}return n}}});var J4=L(()=>{});var K4=L(Pc=>{"use strict";var yEe=QR(),mEe=W4(),bEe=ZR(),wEe=X4(),Lc;try{Lc=J4()}catch{}function Y4(t){return Array.isArray(
t)?t:Pc.NQuads.legacyDatasetToQuads(t)}Pc.NQuads=Sw();Pc.IdentifierIssuer=Ew();Pc._rdfCanonizeNative=function(t){return t&&
(Lc=t),Lc};Pc.canonize=async function(t,e){let r=Y4(t,e);if(e.useNative){if(!Lc)throw new Error("rdf-canonize-native not\
available");if(e.createMessageDigest)throw new Error('"createMessageDigest" cannot be used with "useNative".');return new Promise(
(n,o)=>Lc.canonize(r,e,(s,a)=>s?o(s):n(a)))}if(e.algorithm==="URDNA2015")return new yEe(e).main(r);if(e.algorithm==="URG\
NA2012"){if(e.createMessageDigest)throw new Error('"createMessageDigest" cannot be used with "URGNA2012".');return new mEe(
e).main(r)}throw"algorithm"in e?new Error("Invalid RDF Dataset Canonicalization algorithm: "+e.algorithm):new Error("No \
RDF Dataset Canonicalization algorithm specified.")};Pc._canonizeSync=function(t,e){let r=Y4(t,e);if(e.useNative){if(!Lc)
throw new Error("rdf-canonize-native not available");if(e.createMessageDigest)throw new Error('"createMessageDigest" can\
not be used with "useNative".');return Lc.canonizeSync(r,e)}if(e.algorithm==="URDNA2015")return new bEe(e).main(r);if(e.
algorithm==="URGNA2012"){if(e.createMessageDigest)throw new Error('"createMessageDigest" cannot be used with "URGNA2012"\
.');return new wEe(e).main(r)}throw"algorithm"in e?new Error("Invalid RDF Dataset Canonicalization algorithm: "+e.algorithm):
new Error("No RDF Dataset Canonicalization algorithm specified.")}});var vw=L((A_t,Q4)=>{Q4.exports=K4()});var Gi=L((S_t,Z4)=>{"use strict";var xo={};Z4.exports=xo;xo.isArray=Array.isArray;xo.isBoolean=t=>typeof t=="boolean"||Object.
prototype.toString.call(t)==="[object Boolean]";xo.isDouble=t=>xo.isNumber(t)&&(String(t).indexOf(".")!==-1||Math.abs(t)>=
1e21);xo.isEmptyObject=t=>xo.isObject(t)&&Object.keys(t).length===0;xo.isNumber=t=>typeof t=="number"||Object.prototype.
toString.call(t)==="[object Number]";xo.isNumeric=t=>!isNaN(parseFloat(t))&&isFinite(t);xo.isObject=t=>Object.prototype.
toString.call(t)==="[object Object]";xo.isString=t=>typeof t=="string"||Object.prototype.toString.call(t)==="[object Str\
ing]";xo.isUndefined=t=>typeof t>"u"});var Is=L((v_t,e6)=>{"use strict";var kc=Gi(),tl={};e6.exports=tl;tl.isSubject=t=>kc.isObject(t)&&!("@value"in t||"@set"in
t||"@list"in t)?Object.keys(t).length>1||!("@id"in t):!1;tl.isSubjectReference=t=>kc.isObject(t)&&Object.keys(t).length===
1&&"@id"in t;tl.isValue=t=>kc.isObject(t)&&"@value"in t;tl.isList=t=>kc.isObject(t)&&"@list"in t;tl.isGraph=t=>kc.isObject(
t)&&"@graph"in t&&Object.keys(t).filter(e=>e!=="@id"&&e!=="@index").length===1;tl.isSimpleGraph=t=>tl.isGraph(t)&&!("@id"in
t);tl.isBlankNode=t=>{if(kc.isObject(t)){if("@id"in t){let e=t["@id"];return!kc.isString(e)||e.indexOf("_:")===0}return Object.
keys(t).length===0||!("@value"in t||"@set"in t||"@list"in t)}return!1}});var uo=L((I_t,t6)=>{"use strict";t6.exports=class extends Error{constructor(e="An unspecified JSON-LD error occurred.",r="\
jsonld.Error",n={}){super(e),this.name=r,this.message=e,this.details=n}}});var co=L((D_t,i6)=>{"use strict";var ty=Is(),ei=Gi(),n6=vw().IdentifierIssuer,_Ee=uo(),EEe=/^[a-zA-Z]{1,8}(-[a-zA-Z0-9]{1,8})*$/,
xEe=/(?:<[^>]*?>|"[^"]*?"|[^,])+/g,AEe=/\s*<([^>]*?)>\s*(?:;\s*(.*))?/,SEe=/(.*?)=(?:(?:"([^"]*?)")|([^"]*?))\s*(?:(?:;\s*)|$)/g,
vEe=/^@[a-zA-Z]+$/,r6={headers:{accept:"application/ld+json, application/json"}},kt={};i6.exports=kt;kt.IdentifierIssuer=
n6;kt.REGEX_BCP47=EEe;kt.REGEX_KEYWORD=vEe;kt.clone=function(t){if(t&&typeof t=="object"){let e;if(ei.isArray(t)){e=[];for(let r=0;r<
t.length;++r)e[r]=kt.clone(t[r])}else if(t instanceof Map){e=new Map;for(let[r,n]of t)e.set(r,kt.clone(n))}else if(t instanceof
Set){e=new Set;for(let r of t)e.add(kt.clone(r))}else if(ei.isObject(t)){e={};for(let r in t)e[r]=kt.clone(t[r])}else e=
t.toString();return e}return t};kt.asArray=function(t){return Array.isArray(t)?t:[t]};kt.buildHeaders=(t={})=>{if(Object.
keys(t).some(r=>r.toLowerCase()==="accept"))throw new RangeError('Accept header may not be specified; only "'+r6.headers.
accept+'" is supported.');return Object.assign({Accept:r6.headers.accept},t)};kt.parseLinkHeader=t=>{let e={},r=t.match(
xEe);for(let n=0;n<r.length;++n){let o=r[n].match(AEe);if(!o)continue;let s={target:o[1]},a=o[2];for(;o=SEe.exec(a);)s[o[1]]=
o[2]===void 0?o[3]:o[2];let l=s.rel||"";Array.isArray(e[l])?e[l].push(s):e.hasOwnProperty(l)?e[l]=[e[l],s]:e[l]=s}return e};
kt.validateTypeValue=(t,e)=>{if(!ei.isString(t)&&!(ei.isArray(t)&&t.every(r=>ei.isString(r)))){if(e&&ei.isObject(t))switch(Object.
keys(t).length){case 0:return;case 1:if("@default"in t&&kt.asArray(t["@default"]).every(r=>ei.isString(r)))return}throw new _Ee(
'Invalid JSON-LD syntax; "@type" value must a string, an array of strings, an empty object, or a default object.',"jsonl\
d.SyntaxError",{code:"invalid type value",value:t})}};kt.hasProperty=(t,e)=>{if(t.hasOwnProperty(e)){let r=t[e];return!ei.
isArray(r)||r.length>0}return!1};kt.hasValue=(t,e,r)=>{if(kt.hasProperty(t,e)){let n=t[e],o=ty.isList(n);if(ei.isArray(n)||
o){o&&(n=n["@list"]);for(let s=0;s<n.length;++s)if(kt.compareValues(r,n[s]))return!0}else if(!ei.isArray(r))return kt.compareValues(
r,n)}return!1};kt.addValue=(t,e,r,n)=>{if(n=n||{},"propertyIsArray"in n||(n.propertyIsArray=!1),"valueIsArray"in n||(n.valueIsArray=
!1),"allowDuplicate"in n||(n.allowDuplicate=!0),"prependValue"in n||(n.prependValue=!1),n.valueIsArray)t[e]=r;else if(ei.
isArray(r)){r.length===0&&n.propertyIsArray&&!t.hasOwnProperty(e)&&(t[e]=[]),n.prependValue&&(r=r.concat(t[e]),t[e]=[]);
for(let o=0;o<r.length;++o)kt.addValue(t,e,r[o],n)}else if(t.hasOwnProperty(e)){let o=!n.allowDuplicate&&kt.hasValue(t,e,
r);!ei.isArray(t[e])&&(!o||n.propertyIsArray)&&(t[e]=[t[e]]),o||(n.prependValue?t[e].unshift(r):t[e].push(r))}else t[e]=
n.propertyIsArray?[r]:r};kt.getValues=(t,e)=>[].concat(t[e]||[]);kt.removeProperty=(t,e)=>{delete t[e]};kt.removeValue=(t,e,r,n)=>{
n=n||{},"propertyIsArray"in n||(n.propertyIsArray=!1);let o=kt.getValues(t,e).filter(s=>!kt.compareValues(s,r));o.length===
0?kt.removeProperty(t,e):o.length===1&&!n.propertyIsArray?t[e]=o[0]:t[e]=o};kt.relabelBlankNodes=(t,e)=>{e=e||{};let r=e.
issuer||new n6("_:b");return Rw(r,t)};kt.compareValues=(t,e)=>t===e||ty.isValue(t)&&ty.isValue(e)&&t["@value"]===e["@val\
ue"]&&t["@type"]===e["@type"]&&t["@language"]===e["@language"]&&t["@index"]===e["@index"]?!0:ei.isObject(t)&&"@id"in t&&
ei.isObject(e)&&"@id"in e?t["@id"]===e["@id"]:!1;kt.compareShortestLeast=(t,e)=>t.length<e.length?-1:e.length<t.length?1:
t===e?0:t<e?-1:1;function Rw(t,e){if(ei.isArray(e))for(let r=0;r<e.length;++r)e[r]=Rw(t,e[r]);else if(ty.isList(e))e["@l\
ist"]=Rw(t,e["@list"]);else if(ei.isObject(e)){ty.isBlankNode(e)&&(e["@id"]=t.getId(e["@id"]));let r=Object.keys(e).sort();
for(let n=0;n<r.length;++n){let o=r[n];o!=="@id"&&(e[o]=Rw(t,e[o]))}}return e}});var Iw=L((B_t,o6)=>{"use strict";var es="http://www.w3.org/1999/02/22-rdf-syntax-ns#",ry="http://www.w3.org/2001/XMLSche\
ma#";o6.exports={LINK_HEADER_REL:"http://www.w3.org/ns/json-ld#context",LINK_HEADER_CONTEXT:"http://www.w3.org/ns/json-l\
d#context",RDF:es,RDF_LIST:es+"List",RDF_FIRST:es+"first",RDF_REST:es+"rest",RDF_NIL:es+"nil",RDF_TYPE:es+"type",RDF_PLAIN_LITERAL:es+
"PlainLiteral",RDF_XML_LITERAL:es+"XMLLiteral",RDF_JSON_LITERAL:es+"JSON",RDF_OBJECT:es+"object",RDF_LANGSTRING:es+"lang\
String",XSD:ry,XSD_BOOLEAN:ry+"boolean",XSD_DOUBLE:ry+"double",XSD_INTEGER:ry+"integer",XSD_STRING:ry+"string"}});var eI=L((C_t,s6)=>{"use strict";s6.exports=class{constructor(){this._requests={}}wrapLoader(e){let r=this;return r._loader=
e,function(){return r.add.apply(r,arguments)}}async add(e){let r=this._requests[e];if(r)return Promise.resolve(r);r=this.
_requests[e]=this._loader(e);try{return await r}finally{delete this._requests[e]}}}});var rl=L((F_t,a6)=>{"use strict";var Dw=Gi(),ti={};a6.exports=ti;ti.parsers={simple:{keys:["href","scheme","authority","\
path","query","fragment"],regex:/^(?:([^:\/?#]+):)?(?:\/\/([^\/?#]*))?([^?#]*)(?:\?([^#]*))?(?:#(.*))?/},full:{keys:["hr\
ef","protocol","scheme","authority","auth","user","password","hostname","port","path","directory","file","query","fragme\
nt"],regex:/^(([a-zA-Z][a-zA-Z0-9+-.]*):)?(?:\/\/((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?))?(?:(((?:[^?#\/]*\/)*)([^?#]*))(?:\?([^#]*))?(?:#(.*))?)/}};
ti.parse=(t,e)=>{let r={},n=ti.parsers[e||"full"],o=n.regex.exec(t),s=n.keys.length;for(;s--;)r[n.keys[s]]=o[s]===void 0?
null:o[s];return(r.scheme==="https"&&r.port==="443"||r.scheme==="http"&&r.port==="80")&&(r.href=r.href.replace(":"+r.port,
""),r.authority=r.authority.replace(":"+r.port,""),r.port=null),r.normalizedPath=ti.removeDotSegments(r.path),r};ti.prependBase=
(t,e)=>{if(t===null||ti.isAbsolute(e))return e;(!t||Dw.isString(t))&&(t=ti.parse(t||""));let r=ti.parse(e),n={protocol:t.
protocol||""};if(r.authority!==null)n.authority=r.authority,n.path=r.path,n.query=r.query;else if(n.authority=t.authority,
r.path==="")n.path=t.path,r.query!==null?n.query=r.query:n.query=t.query;else{if(r.path.indexOf("/")===0)n.path=r.path;else{
let s=t.path;s=s.substr(0,s.lastIndexOf("/")+1),(s.length>0||t.authority)&&s.substr(-1)!=="/"&&(s+="/"),s+=r.path,n.path=
s}n.query=r.query}r.path!==""&&(n.path=ti.removeDotSegments(n.path));let o=n.protocol;return n.authority!==null&&(o+="//"+
n.authority),o+=n.path,n.query!==null&&(o+="?"+n.query),r.fragment!==null&&(o+="#"+r.fragment),o===""&&(o="./"),o};ti.removeBase=
(t,e)=>{if(t===null)return e;(!t||Dw.isString(t))&&(t=ti.parse(t||""));let r="";if(t.href!==""?r+=(t.protocol||"")+"//"+
(t.authority||""):e.indexOf("//")&&(r+="//"),e.indexOf(r)!==0)return e;let n=ti.parse(e.substr(r.length)),o=t.normalizedPath.
split("/"),s=n.normalizedPath.split("/"),a=n.fragment||n.query?0:1;for(;o.length>0&&s.length>a&&o[0]===s[0];)o.shift(),s.
shift();let l="";if(o.length>0){o.pop();for(let c=0;c<o.length;++c)l+="../"}return l+=s.join("/"),n.query!==null&&(l+="?"+
n.query),n.fragment!==null&&(l+="#"+n.fragment),l===""&&(l="./"),l};ti.removeDotSegments=t=>{if(t.length===0)return"";let e=t.
split("/"),r=[];for(;e.length>0;){let n=e.shift(),o=e.length===0;if(n==="."){o&&r.push("");continue}if(n===".."){r.pop(),
o&&r.push("");continue}r.push(n)}return t[0]==="/"&&r.length>0&&r[0]!==""&&r.unshift(""),r.length===1&&r[0]===""?"/":r.join(
"/")};var REe=/^([A-Za-z][A-Za-z0-9+-.]*|_):[^\s]*$/;ti.isAbsolute=t=>Dw.isString(t)&&REe.test(t);ti.isRelative=t=>Dw.isString(
t)});var u6=L((N_t,l6)=>{"use strict";var{parseLinkHeader:IEe,buildHeaders:DEe}=co(),{LINK_HEADER_CONTEXT:BEe}=Iw(),ny=uo(),TEe=eI(),
{prependBase:CEe}=rl(),FEe=/(^|(\r\n))link:/i;l6.exports=({secure:t,headers:e={},xhr:r}={headers:{}})=>{return e=DEe(e),
new TEe().wrapLoader(o);async function o(s){if(s.indexOf("http:")!==0&&s.indexOf("https:")!==0)throw new ny('URL could n\
ot be dereferenced; only "http" and "https" URLs are supported.',"jsonld.InvalidUrl",{code:"loading document failed",url:s});
if(t&&s.indexOf("https")!==0)throw new ny(`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 a;try{a=await NEe(r,s,e)}catch(d){throw new ny(
"URL could not be dereferenced, an error occurred.","jsonld.LoadDocumentError",{code:"loading document failed",url:s,cause:d})}
if(a.status>=400)throw new ny("URL could not be dereferenced: "+a.statusText,"jsonld.LoadDocumentError",{code:"loading d\
ocument failed",url:s,httpStatusCode:a.status});let l={contextUrl:null,documentUrl:s,document:a.