severo HF Staff commited on
Commit
23b93ff
·
verified ·
1 Parent(s): 6699df1

Upload folder using huggingface_hub

Browse files
assets/index-BYAzjtBd.css DELETED
@@ -1 +0,0 @@
1
- .table-container{display:flex;flex:1;min-height:0;position:relative}.table-container *{box-sizing:border-box;margin:0;padding:0}.table-scroll{flex:1;overflow:auto}.table-scroll>div{position:relative}.table-scroll .table{position:absolute}.table{border-collapse:separate;border-spacing:0;border-top-right-radius:4px;border-bottom-right-radius:4px;border-bottom-left-radius:4px;max-width:100%;overflow-x:auto}.table:focus-visible{outline:none}.table thead th{background-color:#eaeaeb;border:none;border-bottom:2px solid #c9c9c9;box-sizing:content-box;color:#444;height:20px;padding-top:8px;position:sticky;top:-1px;-webkit-user-select:none;user-select:none;z-index:10}.table thead th:first-child{border:none}.table thead th:first-child span{cursor:default;width:0}.table tbody tr:first-child td{border-top:1px solid transparent}.table.sortable thead th{cursor:pointer}.table thead th.orderby :after{position:absolute;right:8px;top:8px;padding-left:2px;background-color:#eaeaeb;content:"▾"}.table thead span{position:absolute;border-right:1px solid #ddd;top:0;right:0;bottom:0;width:8px;cursor:col-resize;transition:background-color .2s ease}.table thead span:hover{background-color:#aab}.table td:first-child{background-color:#eaeaeb;border-right:1px solid #ddd;color:#888;font-size:10px;padding:0 2px;position:sticky;left:0;text-align:center;-webkit-user-select:none;user-select:none;min-width:32px;max-width:none;width:32px}.table th,.table td{border-bottom:1px solid #ddd;border-right:1px solid #ddd;height:32px;max-width:2000px;padding:4px 12px;text-align:left;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.table th:before{content:"";position:absolute;top:0;left:0;width:100%;height:4px;background-color:#706fb1;z-index:100}.pending .table th:before{animation:shimmer 2s infinite linear}@keyframes shimmer{0%,to{background-color:#6fb176}50%{background-color:#adc6b0}}@media (hover: hover){.table tbody tr:hover{background-color:#dbdbe5}.table tbody tr:hover td{border-right-color:#bbb}.table tbody tr:hover td:first-child{background-color:#ccd}}.table tr[title]{color:#a11}.table-corner{background-color:#e4e4e6;border-right:1px solid #ccc;position:absolute;height:33px;width:32px;top:0;left:0;z-index:15;box-shadow:inset 0 0 4px #0003}.mock-row-label{content:"";position:absolute;top:0;left:0;bottom:0;background:#eaeaeb;z-index:-10}*{box-sizing:border-box;margin:0;padding:0}#app{display:flex;font-family:Mulish,Helvetica Neue,Helvetica,Arial,sans-serif;flex-direction:column;height:100vh}.brand{color:#fff;display:flex;align-items:center;filter:drop-shadow(0 0 2px #444);font-family:Century Gothic,Helvetica Neue,Helvetica,Arial,sans-serif;font-size:1.1em;font-weight:700;text-orientation:mixed;opacity:.85;padding:10px 12px;-webkit-user-select:none;user-select:none;writing-mode:vertical-rl}.brand:hover{color:#fff;filter:drop-shadow(0 0 2px #333);opacity:.9;text-decoration:none}.brand:before{content:"";background:url("data:image/svg+xml,%3csvg%20width='96'%20height='96'%20version='1.1'%20viewBox='0%200%2096%2096'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='m48%203.5%2038.37%2022.25v44.5l-38.37%2022.25-38.37-22.25v-44.5z'%20fill='%2343a'%20stroke='%2343a'%20stroke-linejoin='round'%20stroke-width='7'/%3e%3cg%20fill='none'%20stroke='%23fff'%20stroke-linejoin='round'%20stroke-width='8'%3e%3cpath%20d='m48%2048-29.14-17%202.81e-4%2034%2029.14%2017z'/%3e%3cpath%20d='m77.14%2031-29.14%2017v34l29.14-17z'/%3e%3cpath%20d='m48%2048-29.14-17%2029.14-17%2029.14%2017z'/%3e%3c/g%3e%3c/svg%3e") no-repeat 0 center;background-size:26px;height:26px;width:26px;margin-bottom:10px}a{color:#342267;cursor:pointer;text-decoration:none}a:hover{color:#000;text-decoration:underline}main{display:flex;height:100vh;max-width:100vw}.nav{display:flex;flex-direction:column;min-width:48px;background-image:linear-gradient(to bottom,#667,#585669);box-shadow:0 0 4px #0a0a0a80;height:100vh}.content-container{min-width:0;height:100vh;display:flex;flex-direction:column;flex:1}.content{display:flex;flex-direction:column;flex:1;height:100vh;padding:0;overflow:hidden}.top-header{align-items:center;background:linear-gradient(to right,#353540,#24202b);color:#dde4ea;display:flex;height:32px;min-height:32px;padding-left:8px}.top-header h1{font-size:18px;margin:0}.top-header a{color:#e0e8ee}.path{margin:0 4px 0 2px;min-width:0;overflow:auto}.path::-webkit-scrollbar{display:none}.home{background:url("data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='1rem'%20height='1rem'%20viewBox='0%200%2020%2020'%3e%3cpath%20fill='%23f0f8ff'%20fill-rule='evenodd'%20d='M9.293%202.293a1%201%200%200%201%201.414%200l7%207A1%201%200%200%201%2017%2011h-1v6a1%201%200%200%201-1%201h-2a1%201%200%200%201-1-1v-3a1%201%200%200%200-1-1H9a1%201%200%200%200-1%201v3a1%201%200%200%201-1%201H5a1%201%200%200%201-1-1v-6H3a1%201%200%200%201-.707-1.707z'%20clip-rule='evenodd'/%3e%3c/svg%3e");background-position:left center;background-repeat:no-repeat;width:22px;height:100%}.path a{color:#f0f8ff;font-family:Courier New,Courier,monospace;font-size:18px;text-overflow:ellipsis;white-space:nowrap;text-decoration-thickness:1px}.path a:not(:first-child):before{content:"/"}@media (max-width: 360px){.path a:not(:last-child){display:none}}.progress-bar{position:fixed;top:0;left:0;right:0;height:2px;z-index:1000;transition:width .3s;background-image:linear-gradient(to right,#ddd,#cbb,#ddd);background-size:1000px;animation:shimmer 4s infinite linear}@keyframes shimmer{0%{background-position:-1000px}to{background-position:1000px}}.progress-bar>div{height:100%;background-color:#3a4}.error-bar{max-height:0;padding:0;background-color:#d119;font-family:monospace;overflow-y:auto;transition:max-height .3s;white-space:pre-wrap}.show-error{max-height:30%;padding:10px}.ref-list{flex:1;list-style:none;overflow-y:auto;padding-bottom:24px;margin:8px 0}.ref-list li{margin:0}.ref-list li:first-child a{border-top:1px solid #bbb}.ref-list a{border-bottom:1px solid #bbb;color:#444;display:flex;padding:8px 12px;text-decoration:none}.ref-list a:hover{background-color:#e2e2ee}.ref-list a>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.ref-tags{background-color:#fffbeb}.ref-converts{background-color:#fee2e2}.file-list{flex:1;list-style:none;overflow-y:auto;padding-bottom:24px}.file-list li{margin:0}.file-list li:first-child a{border-top:none}.file-list a{border-top:1px solid #bbb;color:#444;display:flex;padding:8px 12px;text-decoration:none}.file-list a:hover{background-color:#e2e2ee}.file-list a>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.file-name{flex:1;min-width:80px}.file-size{color:#666;margin:0 16px;text-align:right}.file-date{min-width:90px;text-align:right}.file{background:url("data:image/svg+xml,%3csvg%20width='16'%20height='16'%20version='1.1'%20viewBox='0%200%2064%2064'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='m38%203v14.5h14m-40-14.5v58h40v-43.5l-14-14.5z'%20fill='none'%20stroke='%23666'%20stroke-linejoin='round'%20stroke-width='6'/%3e%3c/svg%3e");background-position:left center;background-repeat:no-repeat;background-size:12px;padding-left:22px}.folder{background-image:url("data:image/svg+xml,%3csvg%20width='16'%20height='16'%20version='1.1'%20viewBox='0%200%2064%2064'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='m4%2012v40h56v-30h-24l-10-10z'%20fill='%23666'%20stroke='%23666'%20stroke-linejoin='round'%20stroke-width='8'/%3e%3c/svg%3e")}.viewer{display:flex;flex:1;flex-direction:column;white-space:pre-wrap;overflow-y:auto}.view-header{align-items:center;background-color:#ccc;color:#444;display:flex;gap:16px;height:24px;padding:0 8px;text-overflow:ellipsis;white-space:nowrap}.text{background-color:#22222b;color:#d6d6d6;display:block;flex:1;padding:8px;width:100%;overflow-x:auto;white-space:pre-wrap}.image{display:block;flex:1;min-width:0;object-fit:scale-down;background-image:linear-gradient(45deg,#ddd 25%,transparent 25%),linear-gradient(135deg,#ddd 25%,transparent 25%),linear-gradient(45deg,transparent 75%,#ddd 75%),linear-gradient(135deg,transparent 75%,#ddd 75%);background-size:32px 32px;background-position:0 0,16px 0,16px -16px,0px 16px}.markdown{background-color:#222226;color:#ddd;flex:1;padding:8px 20px;white-space:pre-wrap;overflow-y:auto}.markdown a{color:#cdf}.markdown p{margin-block:1em}.markdown pre{background-color:#34343a;border-left:#446 solid 5px;margin:0;padding:12px 14px;white-space:pre-wrap}.markdown h1{font-size:32px;font-weight:500;margin-bottom:8px}.markdown h2{font-weight:500;margin-bottom:8px;margin-top:16px}#welcome{position:relative;border:2px #777;border-radius:10px;color:#444;padding:10px;display:flex;flex-direction:column;flex:1;font-size:20px;justify-content:center;max-width:640px;margin:0 auto}.quick-links{display:flex;flex-wrap:wrap;gap:10px;list-style:none}.quick-links li{display:flex;flex:1 1 calc(50% - 10px);min-width:0}.quick-links a{background-position:10px center;background-size:18px;border:1px solid #444;border-radius:4px;font-size:8pt;overflow:hidden;padding:12px 12px 12px 36px;text-overflow:ellipsis;white-space:nowrap;width:100%}.quick-links a:hover{background-color:#cec}.huggingface{background:url(/assets/huggingface-Df0G9hpA.svg) no-repeat 8px center}.github{background:url("data:image/svg+xml,%3csvg%20width='92'%20height='92'%20version='1.1'%20viewBox='0%200%2092%2092'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='m89.7%2041.9-39.7-39.7a5.86%205.86%200%200%200-8.29%200l-8.25%208.25%2010.5%2010.5a6.97%206.97%200%200%201%207.16%201.66%206.98%206.98%200%200%201%201.65%207.21l10.1%2010.1a6.97%206.97%200%200%201%207.21%201.65%206.98%206.98%200%200%201%200%209.87%206.98%206.98%200%200%201-9.87%200%206.98%206.98%200%200%201-1.52-7.59l-9.41-9.41v24.8a6.98%206.98%200%200%201%201.84%2011.2%206.98%206.98%200%200%201-9.87%200%206.98%206.98%200%200%201%200-9.87%206.97%206.97%200%200%201%202.29-1.53v-25a6.94%206.94%200%200%201-2.29-1.53%206.99%206.99%200%200%201-1.51-7.63l-10.3-10.3-27.2%2027.2a5.87%205.87%200%200%200%200%208.29l39.7%2039.7a5.87%205.87%200%200%200%208.29%200l39.5-39.5a5.87%205.87%200%200%200%200-8.29'%20fill='%23333'/%3e%3c/svg%3e") no-repeat 8px center}.aws{background:url("data:image/svg+xml,%3csvg%20width='128'%20height='128'%20version='1.1'%20viewBox='0%200%20128%20128'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20class='st0'%20d='m64%202.561c28.87%200%2052.27%2010.96%2052.27%2024.46%200%2013.51-23.41%2024.46-52.27%2024.46s-52.27-10.96-52.27-24.46%2023.41-24.46%2052.27-24.46zm-52.27%2081.83v18.78c9.3%2033.03%20101.2%2026.65%20104.6-1.69v-18.76c-4.59%2031.11-97.2%2033.35-104.6%201.67zm-0.26-48.89v18.34c9.3%2032.26%20101.7%2027.9%20105.1%200.23v-18.33c-4.6%2030.39-97.72%2030.7-105.1-0.24zm0%2023.7v18.78c9.3%2033.03%20101.7%2028.57%20105.1%200.23v-18.76c-4.6%2031.11-97.72%2031.43-105.1-0.25z'%20fill='%23333'/%3e%3c/svg%3e") no-repeat 8px center}.azure{background:url("data:image/svg+xml,%3csvg%20width='128'%20height='128'%20version='1.1'%20viewBox='0%200%20128%20128'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='m59.2%20108c16.4-2.91%2030-5.31%2030.2-5.34l0.284-0.0602-15.5-18.5c-8.54-10.2-15.5-18.5-15.5-18.6%200-0.0911%2016-44.2%2016.1-44.4%200.0302-0.0524%2010.9%2018.8%2026.4%2045.7%2014.5%2025.2%2026.5%2045.9%2026.6%2046.1l0.202%200.353-98.7-0.012%2029.9-5.28zm-59.2-5.63c0-0.026%207.32-12.7%2016.3-28.2l16.3-28.2%2018.9-15.9c10.4-8.74%2019-15.9%2019-15.9%200.0343-0.0127-0.103%200.332-0.305%200.767-0.202%200.435-9.46%2020.3-20.6%2044.1l-20.2%2043.3-14.7%200.0184c-8.08%200.0102-14.7-0.00282-14.7-0.0288z'%20fill='%23222'/%3e%3c/svg%3e") no-repeat 8px center}h1{font-size:22pt}h2{margin-top:10px;font-size:12pt}p{margin:15px 0}code{font-family:monospace;padding:10px;white-space:pre-wrap;word-break:break-all}sub{align-items:center;display:flex;gap:5px}sub img{cursor:pointer}input{width:100%;height:2rem;padding:.5rem;font-size:1rem}
 
 
assets/index-CoWC0pAZ.css ADDED
@@ -0,0 +1 @@
 
 
1
+ .table-container{display:flex;flex:1;min-height:0;position:relative}.table-container *{box-sizing:border-box;margin:0;padding:0}.table-scroll{flex:1;overflow:auto}.table-scroll>div{position:relative}.table-scroll .table{position:absolute}.table{border-collapse:separate;border-spacing:0;border-top-right-radius:4px;border-bottom-right-radius:4px;border-bottom-left-radius:4px;max-width:100%;overflow-x:auto}.table:focus-visible{outline:none}.table thead th{background-color:#eaeaeb;border:none;border-bottom:2px solid #c9c9c9;box-sizing:content-box;color:#444;height:20px;padding-top:8px;position:sticky;top:-1px;-webkit-user-select:none;user-select:none;z-index:10}.table thead th:first-child{border:none}.table thead th:first-child span{cursor:default;width:0}.table tbody tr:first-child td{border-top:1px solid transparent}.table.sortable thead th{cursor:pointer}.table thead th.orderby :after{position:absolute;right:8px;top:8px;padding-left:2px;background-color:#eaeaeb;content:"▾"}.table thead span{position:absolute;border-right:1px solid #ddd;top:0;right:0;bottom:0;width:8px;cursor:col-resize;transition:background-color .2s ease}.table thead span:hover{background-color:#aab}.table td:first-child{background-color:#eaeaeb;border-right:1px solid #ddd;color:#888;font-size:10px;padding:0 2px;position:sticky;left:0;text-align:center;-webkit-user-select:none;user-select:none;min-width:32px;max-width:none;width:32px}.table th,.table td{border-bottom:1px solid #ddd;border-right:1px solid #ddd;height:32px;max-width:2000px;padding:4px 12px;text-align:left;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.table td.pending{position:relative}.table td.pending:after{content:"";position:absolute;top:8px;left:8px;right:8px;bottom:8px;border-radius:4px;background:linear-gradient(60deg,#0000000d 25%,#00000014,#0000000d 75%);background-size:120px 100%;animation:textshimmer 3s infinite linear}.table tr:nth-child(2n) td.pending:after{animation-delay:-1s}.table tr:nth-child(odd) td.pending:after{animation-delay:-3s}.table tr:nth-child(3n) td.pending:after{animation-delay:-2s}.table tr:nth-child(5n) td.pending:after{animation-delay:-4s}.table tr:nth-child(7n) td.pending:after{animation-delay:-1.5s}@keyframes textshimmer{0%{background-position:-120px 0}to{background-position:120px 0}}.table th:before{content:"";position:absolute;top:0;left:0;width:100%;height:4px;background-color:#706fb1;z-index:100}.pending .table th:before{animation:shimmer 2s infinite linear}@keyframes shimmer{0%,to{background-color:#6fb176}50%{background-color:#adc6b0}}@media (hover: hover){.table tbody tr:hover{background-color:#dbdbe5}.table tbody tr:hover td{border-right-color:#bbb}.table tbody tr:hover td:first-child{background-color:#ccd}}.table tr[title]{color:#a11}.table-corner{background-color:#e4e4e6;border-right:1px solid #ccc;position:absolute;height:33px;width:32px;top:0;left:0;z-index:15;box-shadow:inset 0 0 4px #0003}.mock-row-label{content:"";position:absolute;top:0;left:0;bottom:0;background:#eaeaeb;z-index:-10}*{box-sizing:border-box;margin:0;padding:0}#app{display:flex;font-family:Mulish,Helvetica Neue,Helvetica,Arial,sans-serif;flex-direction:column;height:100vh}.brand{color:#fff;display:flex;align-items:center;filter:drop-shadow(0 0 2px #444);font-family:Century Gothic,Helvetica Neue,Helvetica,Arial,sans-serif;font-size:1.1em;font-weight:700;text-orientation:mixed;opacity:.85;padding:10px 12px;-webkit-user-select:none;user-select:none;writing-mode:vertical-rl}.brand:hover{color:#fff;filter:drop-shadow(0 0 2px #333);opacity:.9;text-decoration:none}.brand:before{content:"";background:url("data:image/svg+xml,%3csvg%20width='96'%20height='96'%20version='1.1'%20viewBox='0%200%2096%2096'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='m48%203.5%2038.37%2022.25v44.5l-38.37%2022.25-38.37-22.25v-44.5z'%20fill='%2343a'%20stroke='%2343a'%20stroke-linejoin='round'%20stroke-width='7'/%3e%3cg%20fill='none'%20stroke='%23fff'%20stroke-linejoin='round'%20stroke-width='8'%3e%3cpath%20d='m48%2048-29.14-17%202.81e-4%2034%2029.14%2017z'/%3e%3cpath%20d='m77.14%2031-29.14%2017v34l29.14-17z'/%3e%3cpath%20d='m48%2048-29.14-17%2029.14-17%2029.14%2017z'/%3e%3c/g%3e%3c/svg%3e") no-repeat 0 center;background-size:26px;height:26px;width:26px;margin-bottom:10px}a{color:#342267;cursor:pointer;text-decoration:none}a:hover{color:#000;text-decoration:underline}main{display:flex;height:100vh;max-width:100vw}.nav{display:flex;flex-direction:column;min-width:48px;background-image:linear-gradient(to bottom,#667,#585669);box-shadow:0 0 4px #0a0a0a80;height:100vh}.content-container{min-width:0;height:100vh;display:flex;flex-direction:column;flex:1}.content{display:flex;flex-direction:column;flex:1;height:100vh;padding:0;overflow:hidden}.top-header{align-items:center;background:linear-gradient(to right,#353540,#24202b);color:#dde4ea;display:flex;height:32px;min-height:32px;padding-left:8px}.top-header h1{font-size:18px;margin:0}.top-header a{color:#e0e8ee}.path{margin:0 4px 0 2px;min-width:0;overflow:auto}.path::-webkit-scrollbar{display:none}.home{background:url("data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='1rem'%20height='1rem'%20viewBox='0%200%2020%2020'%3e%3cpath%20fill='%23f0f8ff'%20fill-rule='evenodd'%20d='M9.293%202.293a1%201%200%200%201%201.414%200l7%207A1%201%200%200%201%2017%2011h-1v6a1%201%200%200%201-1%201h-2a1%201%200%200%201-1-1v-3a1%201%200%200%200-1-1H9a1%201%200%200%200-1%201v3a1%201%200%200%201-1%201H5a1%201%200%200%201-1-1v-6H3a1%201%200%200%201-.707-1.707z'%20clip-rule='evenodd'/%3e%3c/svg%3e");background-position:left center;background-repeat:no-repeat;width:22px;height:100%}.path a{color:#f0f8ff;font-family:Courier New,Courier,monospace;font-size:18px;text-overflow:ellipsis;white-space:nowrap;text-decoration-thickness:1px}.path a:not(:first-child):before{content:"/"}@media (max-width: 360px){.path a:not(:last-child){display:none}}.progress-bar{position:fixed;top:0;left:0;right:0;height:2px;z-index:1000;transition:width .3s;background-image:linear-gradient(to right,#ddd,#cbb,#ddd);background-size:1000px;animation:shimmer 4s infinite linear}@keyframes shimmer{0%{background-position:-1000px}to{background-position:1000px}}.progress-bar>div{height:100%;background-color:#3a4}.error-bar{max-height:0;padding:0;background-color:#d119;font-family:monospace;overflow-y:auto;transition:max-height .3s;white-space:pre-wrap}.show-error{max-height:30%;padding:10px}.ref-list{flex:1;list-style:none;overflow-y:auto;padding-bottom:24px;margin:8px 0}.ref-list li{margin:0}.ref-list li:first-child a{border-top:1px solid #bbb}.ref-list a{border-bottom:1px solid #bbb;color:#444;display:flex;padding:8px 12px;text-decoration:none}.ref-list a:hover{background-color:#e2e2ee}.ref-list a>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.ref-tags{background-color:#fffbeb}.ref-converts{background-color:#fee2e2}.file-list{flex:1;list-style:none;overflow-y:auto;padding-bottom:24px}.file-list li{margin:0}.file-list li:first-child a{border-top:none}.file-list a{border-top:1px solid #bbb;color:#444;display:flex;padding:8px 12px;text-decoration:none}.file-list a:hover{background-color:#e2e2ee}.file-list a>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.file-name{flex:1;min-width:80px}.file-size{color:#666;margin:0 16px;text-align:right}.file-date{min-width:90px;text-align:right}.file{background:url("data:image/svg+xml,%3csvg%20width='16'%20height='16'%20version='1.1'%20viewBox='0%200%2064%2064'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='m38%203v14.5h14m-40-14.5v58h40v-43.5l-14-14.5z'%20fill='none'%20stroke='%23666'%20stroke-linejoin='round'%20stroke-width='6'/%3e%3c/svg%3e");background-position:left center;background-repeat:no-repeat;background-size:12px;padding-left:22px}.folder{background-image:url("data:image/svg+xml,%3csvg%20width='16'%20height='16'%20version='1.1'%20viewBox='0%200%2064%2064'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='m4%2012v40h56v-30h-24l-10-10z'%20fill='%23666'%20stroke='%23666'%20stroke-linejoin='round'%20stroke-width='8'/%3e%3c/svg%3e")}.viewer{display:flex;flex:1;flex-direction:column;white-space:pre-wrap;overflow-y:auto}.view-header{align-items:center;background-color:#ccc;color:#444;display:flex;gap:16px;height:24px;padding:0 8px;text-overflow:ellipsis;white-space:nowrap}.text{background-color:#22222b;color:#d6d6d6;display:block;flex:1;padding:8px;width:100%;overflow-x:auto;white-space:pre-wrap}.image{display:block;flex:1;min-width:0;object-fit:scale-down;background-image:linear-gradient(45deg,#ddd 25%,transparent 25%),linear-gradient(135deg,#ddd 25%,transparent 25%),linear-gradient(45deg,transparent 75%,#ddd 75%),linear-gradient(135deg,transparent 75%,#ddd 75%);background-size:32px 32px;background-position:0 0,16px 0,16px -16px,0px 16px}.markdown{background-color:#222226;color:#ddd;flex:1;padding:8px 20px;white-space:pre-wrap;overflow-y:auto}.markdown a{color:#cdf}.markdown p{margin-block:1em}.markdown pre{background-color:#34343a;border-left:#446 solid 5px;margin:0;padding:12px 14px;white-space:pre-wrap}.markdown h1{font-size:32px;font-weight:500;margin-bottom:8px}.markdown h2{font-weight:500;margin-bottom:8px;margin-top:16px}#welcome{position:relative;border:2px #777;border-radius:10px;color:#444;padding:10px;display:flex;flex-direction:column;flex:1;font-size:20px;justify-content:center;max-width:640px;margin:0 auto}.quick-links{display:flex;flex-wrap:wrap;gap:10px;list-style:none}.quick-links li{display:flex;flex:1 1 calc(50% - 10px);min-width:0}.quick-links a{background-position:10px center;background-size:18px;border:1px solid #444;border-radius:4px;font-size:8pt;overflow:hidden;padding:12px 12px 12px 36px;text-overflow:ellipsis;white-space:nowrap;width:100%}.quick-links a:hover{background-color:#cec}.huggingface{background:url(/assets/huggingface-Df0G9hpA.svg) no-repeat 8px center}.github{background:url("data:image/svg+xml,%3csvg%20width='92'%20height='92'%20version='1.1'%20viewBox='0%200%2092%2092'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='m89.7%2041.9-39.7-39.7a5.86%205.86%200%200%200-8.29%200l-8.25%208.25%2010.5%2010.5a6.97%206.97%200%200%201%207.16%201.66%206.98%206.98%200%200%201%201.65%207.21l10.1%2010.1a6.97%206.97%200%200%201%207.21%201.65%206.98%206.98%200%200%201%200%209.87%206.98%206.98%200%200%201-9.87%200%206.98%206.98%200%200%201-1.52-7.59l-9.41-9.41v24.8a6.98%206.98%200%200%201%201.84%2011.2%206.98%206.98%200%200%201-9.87%200%206.98%206.98%200%200%201%200-9.87%206.97%206.97%200%200%201%202.29-1.53v-25a6.94%206.94%200%200%201-2.29-1.53%206.99%206.99%200%200%201-1.51-7.63l-10.3-10.3-27.2%2027.2a5.87%205.87%200%200%200%200%208.29l39.7%2039.7a5.87%205.87%200%200%200%208.29%200l39.5-39.5a5.87%205.87%200%200%200%200-8.29'%20fill='%23333'/%3e%3c/svg%3e") no-repeat 8px center}.aws{background:url("data:image/svg+xml,%3csvg%20width='128'%20height='128'%20version='1.1'%20viewBox='0%200%20128%20128'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20class='st0'%20d='m64%202.561c28.87%200%2052.27%2010.96%2052.27%2024.46%200%2013.51-23.41%2024.46-52.27%2024.46s-52.27-10.96-52.27-24.46%2023.41-24.46%2052.27-24.46zm-52.27%2081.83v18.78c9.3%2033.03%20101.2%2026.65%20104.6-1.69v-18.76c-4.59%2031.11-97.2%2033.35-104.6%201.67zm-0.26-48.89v18.34c9.3%2032.26%20101.7%2027.9%20105.1%200.23v-18.33c-4.6%2030.39-97.72%2030.7-105.1-0.24zm0%2023.7v18.78c9.3%2033.03%20101.7%2028.57%20105.1%200.23v-18.76c-4.6%2031.11-97.72%2031.43-105.1-0.25z'%20fill='%23333'/%3e%3c/svg%3e") no-repeat 8px center}.azure{background:url("data:image/svg+xml,%3csvg%20width='128'%20height='128'%20version='1.1'%20viewBox='0%200%20128%20128'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='m59.2%20108c16.4-2.91%2030-5.31%2030.2-5.34l0.284-0.0602-15.5-18.5c-8.54-10.2-15.5-18.5-15.5-18.6%200-0.0911%2016-44.2%2016.1-44.4%200.0302-0.0524%2010.9%2018.8%2026.4%2045.7%2014.5%2025.2%2026.5%2045.9%2026.6%2046.1l0.202%200.353-98.7-0.012%2029.9-5.28zm-59.2-5.63c0-0.026%207.32-12.7%2016.3-28.2l16.3-28.2%2018.9-15.9c10.4-8.74%2019-15.9%2019-15.9%200.0343-0.0127-0.103%200.332-0.305%200.767-0.202%200.435-9.46%2020.3-20.6%2044.1l-20.2%2043.3-14.7%200.0184c-8.08%200.0102-14.7-0.00282-14.7-0.0288z'%20fill='%23222'/%3e%3c/svg%3e") no-repeat 8px center}h1{font-size:22pt}h2{margin-top:10px;font-size:12pt}p{margin:15px 0}code{font-family:monospace;padding:10px;white-space:pre-wrap;word-break:break-all}sub{align-items:center;display:flex;gap:5px}sub img{cursor:pointer}input{width:100%;height:2rem;padding:.5rem;font-size:1rem}
assets/{index-Cf29TKpY.js → index-r_9wT5u5.js} RENAMED
@@ -45,5 +45,5 @@ ${e.map(t=>Bp(bi(t),2)).join(`,
45
  `)}const Wp=["branches","tags","converts","pullRequests"];async function Vp(e,t){const n=await fetch(`https://huggingface.co/api/datasets/${e}/${t}/refs`);if(!n.ok)throw new Error(`HTTP error ${n.status.toString()}`);const r=await n.json();return Wp.flatMap(l=>{var i;return((i=r[l])==null?void 0:i.map(o=>({refType:l,...o})))??[]})}function Hp(e){return(e==null?void 0:e.fileSize)!==void 0?Ac(e.fileSize):""}function Ac(e){const t=["b","kb","mb","gb","tb"];if(e===0)return"0 b";const n=Math.floor(Math.log2(e)/10);if(n===0)return e.toLocaleString("en-US")+" b";const r=e/Math.pow(1024,n);return(r<10?r.toFixed(1):Math.round(r)).toLocaleString("en-US")+" "+t[n]}function Qp(e){const t=e.get("content-length");return t?Number(t):void 0}const Yp={png:"image/png",jpg:"image/jpeg",jpeg:"image/jpeg",gif:"image/gif",svg:"image/svg+xml"},Kp=[".png",".jpg",".jpeg",".gif",".svg"];function Ol({content:e,headers:t,children:n}){return v.jsxs("div",{className:"viewer",children:[v.jsxs("div",{className:"view-header",children:[(e==null?void 0:e.fileSize)&&v.jsx("span",{title:e.fileSize.toLocaleString("en-US")+" bytes",children:Hp(e)}),t]}),n]})}function qp({url:e,setError:t}){const[n,r]=j.useState(0),[l,i]=j.useState();return j.useEffect(()=>{async function o(){try{const u=await fetch(e),s=await u.arrayBuffer(),a=Xp(s),h=`data:${Gp(e)};base64,${a}`,p=Qp(u.headers);i({dataUri:h,fileSize:p})}catch(u){t(u)}finally{r(2)}}r(u=>u!==0?u:(o().catch(()=>{}),1))},[e,n,t]),v.jsx(Ol,{content:l,children:(l==null?void 0:l.dataUri)&&v.jsx("img",{alt:e,className:"image",src:l.dataUri})})}function Xp(e){let t="";const n=new Uint8Array(e);for(let r=0;r<n.byteLength;r++)t+=String.fromCharCode(n[r]);return btoa(t)}function Gp(e){const t=e.split(".").pop()??"";return Yp[t]||"image/png"}function Zp({text:e,className:t}){function n(r){const l=[],i=r.split(`
46
  `);let o=!1,u=[],s=!1,a=[];for(let h=0;h<i.length;h++){const p=i[h];if(p.startsWith("```")){o?(l.push(v.jsx("pre",{children:u.join(`
47
  `)},`code-${h.toLocaleString("en-US")}`)),o=!1,u=[]):o=!0;continue}if(o){u.push(p);continue}if(p.includes("**")){const y=p.split("**");l.push(v.jsx("p",{children:y.map((g,S)=>S%2?v.jsx("strong",{children:g},S):g)},h));continue}if(p.includes("*")){const y=p.split("*");l.push(v.jsx("p",{children:y.map((g,S)=>S%2?v.jsx("em",{children:g},S):g)},h));continue}if(p.startsWith("#")){const y=p.split(" ")[0].length,g=p.slice(y+1),S=`h${y.toLocaleString("en-US")}`;l.push(v.jsx(S,{children:g},h));continue}const m=/!\[(.*?)\]\((.*?)\)/.exec(p);if(m){const[,y,g]=m;l.push(v.jsx("img",{src:g,alt:y},h));continue}if(p.includes("[")&&p.includes("]")&&p.includes("(")&&p.includes(")")){const y=p.replace(/\[(.*?)\]\((.*?)\)/g,(g,S,I)=>`<a href="${I}" target="_blank" rel="noreferrer">${S}</a>`);l.push(v.jsx("p",{dangerouslySetInnerHTML:{__html:y}},h));continue}if(p.startsWith("-")||p.startsWith("*")||p.startsWith("+")){const y=p.slice(1).trim();a.push(v.jsx("li",{children:y},`list-item-${h.toLocaleString("en-US")}`)),s=!0;continue}s&&a.length>0&&(l.push(v.jsx("ul",{children:a},`list-${h.toLocaleString("en-US")}`)),a=[],s=!1),l.push(v.jsx("p",{children:p},h))}return o&&u.length>0&&l.push(v.jsx("pre",{children:u.join(`
48
- `)},`code-${i.length.toLocaleString("en-US")}`)),s&&a.length>0&&l.push(v.jsx("ul",{children:a},`list-${i.length.toLocaleString("en-US")}`)),v.jsx("div",{className:t,children:l})}return n(e)}function Jp({url:e,setError:t}){const[n,r]=j.useState(0),[l,i]=j.useState();return j.useEffect(()=>{async function o(){try{const s=await(await fetch(e)).text();i(s)}catch(u){t(u)}finally{r(2)}}r(u=>u!==0?u:(o().catch(()=>{}),1))},[e,n,t]),v.jsx(Ol,{content:{fileSize:l==null?void 0:l.length},children:v.jsx(Zp,{className:"markdown",text:l??""})})}var hs,ms,vs={exports:{}},jn={},q=(ms||(ms=1,vs.exports=function(){if(hs)return jn;hs=1;var e=sf,t=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,l=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,i={key:!0,ref:!0,__self:!0,__source:!0};function o(u,s,a){var h,p={},m=null,y=null;for(h in a!==void 0&&(m=""+a),s.key!==void 0&&(m=""+s.key),s.ref!==void 0&&(y=s.ref),s)r.call(s,h)&&!i.hasOwnProperty(h)&&(p[h]=s[h]);if(u&&u.defaultProps)for(h in s=u.defaultProps)p[h]===void 0&&(p[h]=s[h]);return{$$typeof:t,type:u,key:m,ref:y,props:p,_owner:l.current}}return jn.Fragment=n,jn.jsx=o,jn.jsxs=o,jn}()),vs.exports);function eo(e,t,n){if(Array.isArray(e))return e;const r=new Array(t).fill(null).map(l=>Object.fromEntries(n.map(i=>[i,eh()])));return(e instanceof Promise?e:Promise.resolve(e)).then(l=>{l.length!==t&&console.warn(`Expected ${t} rows, got ${l.length}`);for(let i=0;i<l.length;i++){const o=l[i];for(const u of n)r[i][u].resolve(o[u])}}).catch(l=>{for(let i=0;i<t;i++)for(const o of n)r[i][o].reject(l)}),r}function bp(e){e instanceof Promise||(e=Promise.resolve(e));const t=e.then(n=>(t.resolved=n,n)).catch(n=>{throw t.rejected=n,n});return t}function eh(){let e,t;const n=bp(new Promise((r,l)=>{e=r,t=l}));return n.resolve=e,n.reject=t,n}const th=10;function nh({header:e,columnWidths:t,orderBy:n,setColumnWidth:r,setColumnWidths:l,setOrderBy:i,dataReady:o}){const[u,s]=j.useState(),a=j.useRef(e.map(()=>j.createRef()));function h(m){return m.current?m.current.offsetWidth-2*th:void 0}j.useEffect(()=>{if(o){const m=a.current.map(h);l(m)}},[o,e]),j.useEffect(()=>{function m(){u&&s(void 0)}function y({clientX:g}){u&&r(u.columnIndex,Math.max(1,g-u.clientX))}return u&&(window.addEventListener("mousemove",y),window.addEventListener("mouseup",m)),()=>{window.removeEventListener("mousemove",y),window.removeEventListener("mouseup",m)}},[e,u,l]);const p=j.useMemo(()=>t.map(to),[t]);return q.jsx("thead",{children:q.jsxs("tr",{children:[q.jsx("th",{children:q.jsx("span",{})}),e.map((m,y)=>q.jsxs("th",{className:n===m?"orderby":void 0,onClick:()=>function(g){i==null||i(n===g?void 0:g)}(m),ref:a.current[y],style:p[y],title:m,children:[m,q.jsx("span",{onDoubleClick:()=>function(g){Rc.flushSync(()=>{r(g,void 0)});const S=h(a.current[g]);r(g,S)}(y),onMouseDown:g=>function(S,I){I.stopPropagation(),s({columnIndex:S,clientX:I.clientX-(t[S]||0)})}(y,g)})]},y))]})})}function to(e){const t=e?`${e}px`:void 0;return{minWidth:t,maxWidth:t}}function rh(e){const t={};return{...e,rows(n,r,l){var u;const i=t[u=l||""]||(t[u]=new Array(e.numRows));let o;for(let s=n;s<r;s++)if(i[s]){if(o!==void 0){const a=s,h=a-o,p=eo(e.rows(o,a,l),h,e.header);for(let m=0;m<a-o;m++)i[o+m]=p[m];o=void 0}}else o===void 0&&(o=s);if(o!==void 0){const s=r,a=s-o,h=eo(e.rows(o,s,l),a,e.header);for(let p=0;p<s-o;p++)i[o+p]=h[p]}return i.slice(n,r)}}}function lh(e,t){switch(t.type){case"SET_ROWS":return{...e,startIndex:t.start,rows:t.rows,dataReady:e.dataReady||t.hasCompleteRow};case"SET_COLUMN_WIDTH":{const n=[...e.columnWidths];return n[t.columnIndex]=t.columnWidth,{...e,columnWidths:n}}case"SET_COLUMN_WIDTHS":return{...e,columnWidths:t.columnWidths};case"SET_ORDER":return{...e,orderBy:t.orderBy};case"SET_PENDING":return{...e,pending:t.pending};case"DATA_CHANGED":return{...e,dataReady:!1};default:return e}}const ih={columnWidths:[],startIndex:0,rows:[],dataReady:!1,pending:!1};function oh({data:e,overscan:t=20,padding:n=20,onDoubleClickCell:r,onError:l=console.error}){const[i,o]=j.useReducer(lh,ih),{columnWidths:u,startIndex:s,rows:a,orderBy:h,dataReady:p,pending:m}=i,y=j.useRef(0),g=j.useRef(null),S=j.useRef(null),I=j.useRef(0),c=j.useRef(!1);if(!e)throw new Error("HighTable: data is required");const f=33*(e.numRows+1);function d(L,O){if(L.length>0&&L.length!==e.header.length)return`Row ${O+1} length ${L.length} does not match header length ${e.header.length}`}j.useEffect(()=>{async function L(){var st,E;const Xe=((st=g.current)==null?void 0:st.clientHeight)||100,Oe=((E=g.current)==null?void 0:E.scrollTop)||0;let Se=Math.floor(e.numRows*Oe/f),We=Math.ceil(e.numRows*(Oe+Xe)/f);if(Se=Math.max(0,Se-t),We=Math.min(e.numRows,We+t),isNaN(Se))throw new Error("invalid start row "+Se);if(isNaN(We))throw new Error("invalid end row "+We);const Ge=Math.max(0,Oe-33*n);try{const R=++I.current,T=eo(e.rows(Se,We,h),We-Se,e.header),W=function($,_e){let ie=0,Ve=!1;return()=>{const he=Date.now();he-ie>_e?(ie=he,$()):Ve||(Ve=!0,setTimeout(()=>{ie=Date.now(),Ve=!1,$()},_e-(he-ie)))}}(()=>{const $=[];let _e=!1;for(const ie of T){const Ve={};let he=!0;for(const[Vt,eu]of Object.entries(ie))"resolved"in eu?Ve[Vt]=eu.resolved:he=!1;he&&(_e=!0),$.push(Ve)}y.current=Ge,o({type:"SET_ROWS",start:Se,rows:$,hasCompleteRow:_e})},10);W();for(const $ of T)for(const[_e,ie]of Object.entries($))ie.then(()=>{I.current===R&&W()}).catch(()=>{});for(const $ of T)for(const _e of Object.values($))await _e;c.current&&(c.current=!1,L())}catch(R){o({type:"SET_PENDING",pending:!1}),l(R)}}L();const O=g.current;return O==null||O.addEventListener("scroll",L),window.addEventListener("resize",L),()=>{O==null||O.removeEventListener("scroll",L),window.removeEventListener("resize",L)}},[e,h,t,n,f,l]);const w=j.useMemo(()=>u.map(to),[u]);j.useEffect(()=>{var L;(L=S.current)==null||L.focus()},[]),j.useEffect(()=>{o({type:"DATA_CHANGED"})},[e]);const k=j.useCallback(L=>a[L].__index__??L+s+1,[a,s]),N=Array.from({length:Math.min(n,s)},()=>[]),C=Array.from({length:Math.min(n,e.numRows-s-a.length)},()=>[]),P=4*Math.ceil(Math.log10(e.numRows+1))+22,U=j.useMemo(()=>to(P),[P]);if(e.header.length)return q.jsxs("div",{className:m?"table-container pending":"table-container",children:[q.jsx("div",{className:"table-scroll",ref:g,children:q.jsx("div",{style:{height:`${f}px`},children:q.jsxs("table",{"aria-colcount":e.header.length,"aria-rowcount":e.numRows,className:e.sortable?"table sortable":"table",ref:S,role:"grid",style:{top:`${y.current}px`},tabIndex:0,children:[q.jsx(nh,{columnWidths:u,dataReady:p,header:e.header,orderBy:h,setColumnWidth:(L,O)=>o({type:"SET_COLUMN_WIDTH",columnIndex:L,columnWidth:O}),setColumnWidths:L=>o({type:"SET_COLUMN_WIDTHS",columnWidths:L}),setOrderBy:L=>e.sortable&&o({type:"SET_ORDER",orderBy:L})}),q.jsxs("tbody",{children:[N.map((L,O)=>q.jsx("tr",{children:q.jsx("td",{style:U,children:(s-N.length+O+1).toLocaleString()})},s-N.length+O)),a.map((L,O)=>q.jsxs("tr",{title:d(L,O),children:[q.jsx("td",{style:U,children:k(O).toLocaleString()}),e.header.map((Xe,Oe)=>{var Se;return function(We,Ge,st,E){let R,T=no(We);return typeof T=="string"&&(T.length>400&&(T=`${T.slice(0,397)}…`),T.length>100&&(R=T)),q.jsx("td",{onDoubleClick:()=>r==null?void 0:r(Ge,E??st),style:w[Ge],title:R,children:T},Ge)}(L[Xe],Oe,s+O,(Se=L.__index__)==null?void 0:Se.resolved)})]},s+O)),C.map((L,O)=>q.jsx("tr",{children:q.jsx("td",{style:U,children:(s+a.length+O+1).toLocaleString()})},s+a.length+O))]})]})})}),q.jsx("div",{className:"table-corner",style:U,children:" "}),q.jsx("div",{className:"mock-row-label",style:U,children:" "})]})}function no(e){return typeof e=="string"?e:typeof e=="number"?e.toLocaleString():Array.isArray(e)?`[${e.map(no).join(", ")}]`:e==null?JSON.stringify(e):e instanceof Date?e.toISOString():typeof e=="object"?`{${Object.entries(e).map(([t,n])=>`${t}: ${no(n)}`).join(", ")}}`:e.toString()}function uh({url:e,resolveUrl:t,setProgress:n,setError:r}){const[l,i]=j.useState(0),[o,u]=j.useState();j.useEffect(()=>{async function h(){try{n(.33);const p=await $c(t),m={url:t,byteLength:p.byteLength};n(.66);const y=await Mc(p);let g=Uc(m,y);g=rh(g);const S=p.byteLength;u({dataframe:g,fileSize:S})}catch(p){r(p)}finally{i(2),n(1)}}l===0&&(i(1),h().catch(()=>{}))},[l,e,t,r,n]);const s=(h,p)=>{bo(`?url=${e}&row=${p.toString()}&col=${h.toString()}`)},a=v.jsx(v.Fragment,{children:(o==null?void 0:o.dataframe)&&v.jsxs("span",{children:[o.dataframe.numRows.toLocaleString("en-US")," rows"]})});return v.jsxs(Ol,{content:o,headers:a,children:[(o==null?void 0:o.dataframe)&&v.jsx(oh,{data:o.dataframe,onDoubleClickCell:s,onError:r}),l&&v.jsx(Rl,{className:"center"})]})}function sh({url:e,setError:t}){const[n,r]=j.useState(0),[l,i]=j.useState(),o=j.useRef(null);j.useEffect(()=>{async function s(){try{const h=await(await fetch(e)).text();i(h)}catch(a){t(a)}finally{r(2)}}r(a=>a!==0?a:(s().catch(()=>{}),1))},[e,n,t]);const u=v.jsx(v.Fragment,{children:v.jsxs("span",{children:[l?ah(l):0," lines"]})});return v.jsxs(Ol,{content:{fileSize:l==null?void 0:l.length},headers:u,children:[v.jsx("code",{className:"text",ref:o,children:l}),n&&v.jsx(Rl,{className:"center"})]})}function ah(e){let t=0;for(const n of e)n===`
49
  `&&t++;return t.toLocaleString("en-US")}function ch({url:e,resolveUrl:t,setError:n,setProgress:r}){const l=e.replace(/\?.*$/,"");return l.endsWith(".md")?v.jsx(Jp,{url:t,setError:n}):l.endsWith(".parquet")?v.jsx(uh,{url:e,resolveUrl:t,setError:n,setProgress:r}):Kp.some(i=>l.endsWith(i))?v.jsx(qp,{url:t,setError:n}):v.jsx(sh,{url:t,setError:n,setProgress:r})}function fh({url:e}){const[t,n]=j.useState(),[r,l]=j.useState(),i=e.kind==="file"?e.resolveUrl:e.raw,o=i.split("/");if(o.length<1)throw new Error("Invalid URL path");const u=o.at(-1);return v.jsxs(cr,{progress:t,error:r,title:u,children:[v.jsx(zl,{url:e}),v.jsx(ch,{url:e.raw,resolveUrl:i,setProgress:n,setError:l})]})}var dh=Object.defineProperty,ph=(e,t,n)=>t in e?dh(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Tr=(e,t,n)=>(ph(e,typeof t!="symbol"?t+"":t,n),n),Fc="https://huggingface.co";async function Bc(e,t){var n,r;const l=new hh(e.url,e.status,(n=e.headers.get("X-Request-Id"))!=null?n:void 0);l.message=`Api error with status ${l.statusCode}`;const i=[`URL: ${l.url}`,l.requestId?`Request ID: ${l.requestId}`:void 0].filter(Boolean).join(". ");if((r=e.headers.get("Content-Type"))!=null&&r.startsWith("application/json")){const o=await e.json();l.message=o.error||o.message||l.message,l.data=o}else l.data={message:await e.text()};throw l.message+=`. ${i}`,l}var hh=class extends Error{constructor(e,t,n,r){super(r),Tr(this,"statusCode"),Tr(this,"url"),Tr(this,"requestId"),Tr(this,"data"),this.statusCode=t,this.requestId=n,this.url=e}};function gs(e){if(!e.startsWith("hf_"))throw new TypeError("Your access token must start with 'hf_'")}function Wc(e){var t;if(e.accessToken)return gs(e.accessToken),e.accessToken;if((t=e.credentials)!=null&&t.accessToken)return gs(e.credentials.accessToken),e.credentials.accessToken}function mh(e){if(typeof e!="string")return e;if(e.startsWith("model/")||e.startsWith("models/"))throw new TypeError("A repo designation for a model should not start with 'models/', directly specify the model namespace / name");if(e.startsWith("space/"))throw new TypeError("Spaces should start with 'spaces/', plural, not 'space/'");if(e.startsWith("dataset/"))throw new TypeError("Datasets should start with 'dataset/', plural, not 'dataset/'");const t=e.split("/").length-1;if(e.startsWith("spaces/")){if(t!==2)throw new TypeError("Space Id must include namespace and name of the space");return{type:"space",name:e.slice(7)}}if(e.startsWith("datasets/")){if(t>2)throw new TypeError("Too many slashes in repo designation: "+e);return{type:"dataset",name:e.slice(9)}}if(t>1)throw new TypeError("Too many slashes in repo designation: "+e);return{type:"model",name:e}}new Promise(e=>{});function vh(e,t){return Object.assign({},...t.map(n=>{if(e[n]!==void 0)return{[n]:e[n]}}))}function Vc(e){const t=/<(https?:[/][/][^>]+)>;\s+rel="([^"]+)"/g;return Object.fromEntries([...e.matchAll(t)].map(([,n,r])=>[r,n]))}var gh=["private","downloads","gated","likes","lastModified"];async function*yh(e){var t,n,r,l,i,o,u,s,a;const h=e&&Wc(e);let p=(t=e==null?void 0:e.limit)!=null?t:1/0;const m=new URLSearchParams([...Object.entries({limit:String(Math.min(p,500)),...(n=e==null?void 0:e.search)!=null&&n.owner?{author:e.search.owner}:void 0,...(r=e==null?void 0:e.search)!=null&&r.query?{search:e.search.query}:void 0}),...(o=(i=(l=e==null?void 0:e.search)==null?void 0:l.tags)==null?void 0:i.map(g=>["filter",g]))!=null?o:[],...gh.map(g=>["expand",g]),...(s=(u=e==null?void 0:e.additionalFields)==null?void 0:u.map(g=>["expand",g]))!=null?s:[]]).toString();let y=`${(e==null?void 0:e.hubUrl)||Fc}/api/datasets`+(m?"?"+m:"");for(;y;){const g=await((a=e==null?void 0:e.fetch)!=null?a:fetch)(y,{headers:{accept:"application/json",...e!=null&&e.credentials?{Authorization:`Bearer ${h}`}:void 0}});if(!g.ok)throw await Bc(g);const S=await g.json();for(const c of S)if(yield{...(e==null?void 0:e.additionalFields)&&vh(c,e.additionalFields),id:c._id,name:c.id,private:c.private,downloads:c.downloads,likes:c.likes,gated:c.gated,updatedAt:new Date(c.lastModified)},p--,p<=0)return;const I=g.headers.get("Link");y=I?Vc(I).next:void 0}}async function*wh(e){var t;const n=Wc(e),r=mh(e.repo);let l=`${e.hubUrl||Fc}/api/${r.type}s/${r.name}/tree/${e.revision||"main"}${e.path?"/"+e.path:""}?recursive=${!!e.recursive}&expand=${!!e.expand}`;for(;l;){const i=await((t=e.fetch)!=null?t:fetch)(l,{headers:{accept:"application/json",...n?{Authorization:`Bearer ${n}`}:void 0}});if(!i.ok)throw await Bc(i);const o=await i.json();for(const s of o)yield s;const u=i.headers.get("Link");l=u?Vc(u).next:void 0}}function Sh({url:e}){const[t,n]=j.useState(),[r,l]=j.useState(),i=j.useRef(null);j.useEffect(()=>{async function s(){const a=wh({repo:`datasets/${e.namespace}/${e.repo}`,revision:e.branch,path:e.path.replace(/^\//,"")}),h=[];for await(const p of a)h.push(p);n(h)}s().catch(a=>{n([]),l(a)})},[e]);const o=j.useCallback(s=>{const a=s.type==="directory"?"tree":"blob";return`${be}/${e.namespace}/${e.repo}/${a}/${e.branch}/${s.path}`},[e]),u=j.useCallback(s=>s.path.split("/").at(-1),[]);return v.jsxs(cr,{error:r,title:e.path,children:[v.jsx(zl,{url:e}),t&&t.length>0&&v.jsx("ul",{className:"file-list",ref:i,children:t.map((s,a)=>v.jsx("li",{children:v.jsxs(Il,{url:o(s),children:[v.jsx("span",{className:hl("file-name","file",s.type==="directory"&&"folder"),children:u(s)}),s.type==="file"&&v.jsx(v.Fragment,{children:v.jsx("span",{className:"file-size",title:s.size.toLocaleString("en-US")+" bytes",children:Ac(s.size)})})]})},a))}),(t==null?void 0:t.length)===0&&v.jsx("div",{className:"center",children:"No files"}),t===void 0&&v.jsx(Rl,{className:"center"})]})}function _h({url:e}){const[t,n]=j.useState(),[r,l]=j.useState(),i=j.useRef(null);j.useEffect(()=>{Vp(e.namespace,e.repo).then(n).catch(u=>{n([]),l(u)})},[e]);const o=j.useCallback(u=>{var h,p;const s=((p=(h=/^(refs\/(heads|tags)\/)?(?<pathElement>[^/]+)$/.exec(u.ref))==null?void 0:h.groups)==null?void 0:p.pathElement)??u.ref,a=`${be}/${e.namespace}/${e.repo}/tree/${encodeURIComponent(s)}/`;return v.jsx(Il,{url:a,children:s})},[e]);return v.jsxs(cr,{error:r,title:`${e.namespace}/${e.repo}`,children:[v.jsx(zl,{url:e}),v.jsxs("h2",{children:["Dataset ",v.jsxs("code",{children:[e.namespace,"/",e.repo]})]}),v.jsx("p",{children:"Select a branch"}),t&&t.length>0&&v.jsx("ul",{className:"ref-list",ref:i,children:t.map((u,s)=>v.jsx("li",{className:"ref-"+u.refType,children:o(u)},s))}),(t==null?void 0:t.length)===0&&v.jsx("div",{className:"center",children:"No branches"}),t===void 0&&v.jsx(Rl,{className:"center"})]})}function kh(){const[e,t]=j.useState(),[n,r]=j.useState([]);j.useEffect(()=>{async function i(){const o=[];for await(const u of yh({search:{query:e},limit:10}))o.push(u);r(o)}i().catch(o=>{r([]),console.error(o)})},[e]);function l(i){t(i.target.value)}return v.jsxs(v.Fragment,{children:[v.jsx("input",{type:"search",onChange:l}),v.jsx("ul",{className:"ref-list",children:n.map(i=>v.jsx("li",{style:{fontSize:"0.9rem"},children:v.jsx(Il,{url:`${be}/${i.name}`,children:i.name})},i.name))})]})}function ys(){const e=j.useRef(null);function t(n){n.preventDefault();const r=new FormData(n.currentTarget).get("url");bo(`?url=${r}`)}return v.jsxs("div",{id:"welcome",children:[v.jsx("h1",{children:"hyparquet"}),v.jsxs("sub",{children:["/haɪ pɑːrˈkeɪ/",v.jsx("img",{src:"audio.svg",alt:"play hyparquet pronunciation",height:"18",width:"18",onClick:()=>{var n;(n=e.current)==null||n.play().catch(()=>{})}})]}),v.jsx("audio",{ref:e,src:"hyparquet.mp3"}),v.jsx("h2",{children:"in-browser parquet file reader"}),v.jsxs("p",{children:[v.jsx("a",{href:"https://www.npmjs.com/package/hyparquet",children:v.jsx("img",{src:"https://img.shields.io/npm/v/hyparquet",alt:"npm hyparquet"})})," ",v.jsx("a",{href:"https://github.com/hyparam/hyparquet",children:v.jsx("img",{src:"https://img.shields.io/github/stars/hyparam/hyparquet?style=social",alt:"star hyparquet"})})]}),v.jsxs("p",{children:["Online demo of"," ",v.jsx("a",{href:"https://github.com/hyparam/hyparquet",children:"hyparquet"}),": a parser for apache parquet files. Uses"," ",v.jsx("a",{href:"https://github.com/hyparam/hightable",children:"hightable"})," for high performance windowed table viewing."]}),v.jsxs("section",{children:[v.jsx("h3",{children:"Select a dataset on Hugging Face"}),v.jsx("p",{children:"Search for a dataset:"}),v.jsx(kh,{})]}),v.jsxs("section",{children:[v.jsx("h3",{children:"Parquet URL"}),v.jsx("p",{children:"You can also set a url to see your parquet data. 👀"}),v.jsxs("form",{onSubmit:t,style:{display:"flex",gap:"1rem"},children:[v.jsx("label",{htmlFor:"url",children:"URL"}),v.jsx("input",{name:"url",defaultValue:"https://huggingface.co/datasets/codeparrot/github-code/resolve/main/data/train-00000-of-01126.parquet",style:{width:"100%"},type:"url"}),v.jsx("button",{style:{fontSize:"1rem",padding:"0 0.5rem"},type:"submit",children:"Open"})]}),v.jsxs("p",{children:[v.jsx("p",{children:"Example files:"}),v.jsxs("ul",{className:"quick-links",children:[v.jsx("li",{children:v.jsx("a",{className:"aws",href:"?url=https://hyperparam-public.s3.amazonaws.com/wiki-en-00000-of-00041.parquet",children:"s3://wiki-en-00000-of-00041.parquet"})}),v.jsx("li",{children:v.jsx("a",{className:"azure",href:"?url=https://hyperparam.blob.core.windows.net/hyperparam/starcoderdata-js-00000-of-00065.parquet",children:"azure://starcoderdata-js-00000-of-00065.parquet"})}),v.jsx("li",{children:v.jsx("a",{className:"huggingface",href:"?url=https://huggingface.co/datasets/codeparrot/github-code/resolve/main/data/train-00000-of-01126.parquet?download=true",children:"huggingface://github-code-00000-of-01126.parquet"})}),v.jsx("li",{children:v.jsx("a",{className:"github",href:"?url=https://raw.githubusercontent.com/hyparam/hyparquet/master/test/files/rowgroups.parquet",children:"github://rowgroups.parquet"})})]})]})]})]})}function Eh(){const e=new URLSearchParams(location.search),t=e.get("url");if(Array.isArray(t))throw new Error("url must be a string");if(t===null)return v.jsx(ys,{});try{const n=Up(t);return n.kind==="base"?v.jsx(ys,{}):n.kind==="repo"?v.jsx(_h,{url:n}):n.kind==="folder"?v.jsx(Sh,{url:n}):e.has("col")&&e.has("row")?v.jsx(Fp,{url:n,row:Number(e.get("row")),col:Number(e.get("col"))}):v.jsx(fh,{url:n})}catch(n){return v.jsx(cr,{error:n,title:"Error",children:v.jsx("div",{className:"error",children:n.message})})}}const Hc=document.getElementById("app");if(!Hc)throw new Error("No root element");Ic(Hc).render(v.jsx(j.StrictMode,{children:v.jsx(Eh,{})}));
 
45
  `)}const Wp=["branches","tags","converts","pullRequests"];async function Vp(e,t){const n=await fetch(`https://huggingface.co/api/datasets/${e}/${t}/refs`);if(!n.ok)throw new Error(`HTTP error ${n.status.toString()}`);const r=await n.json();return Wp.flatMap(l=>{var i;return((i=r[l])==null?void 0:i.map(o=>({refType:l,...o})))??[]})}function Hp(e){return(e==null?void 0:e.fileSize)!==void 0?Ac(e.fileSize):""}function Ac(e){const t=["b","kb","mb","gb","tb"];if(e===0)return"0 b";const n=Math.floor(Math.log2(e)/10);if(n===0)return e.toLocaleString("en-US")+" b";const r=e/Math.pow(1024,n);return(r<10?r.toFixed(1):Math.round(r)).toLocaleString("en-US")+" "+t[n]}function Qp(e){const t=e.get("content-length");return t?Number(t):void 0}const Yp={png:"image/png",jpg:"image/jpeg",jpeg:"image/jpeg",gif:"image/gif",svg:"image/svg+xml"},Kp=[".png",".jpg",".jpeg",".gif",".svg"];function Ol({content:e,headers:t,children:n}){return v.jsxs("div",{className:"viewer",children:[v.jsxs("div",{className:"view-header",children:[(e==null?void 0:e.fileSize)&&v.jsx("span",{title:e.fileSize.toLocaleString("en-US")+" bytes",children:Hp(e)}),t]}),n]})}function qp({url:e,setError:t}){const[n,r]=j.useState(0),[l,i]=j.useState();return j.useEffect(()=>{async function o(){try{const u=await fetch(e),s=await u.arrayBuffer(),a=Xp(s),h=`data:${Gp(e)};base64,${a}`,p=Qp(u.headers);i({dataUri:h,fileSize:p})}catch(u){t(u)}finally{r(2)}}r(u=>u!==0?u:(o().catch(()=>{}),1))},[e,n,t]),v.jsx(Ol,{content:l,children:(l==null?void 0:l.dataUri)&&v.jsx("img",{alt:e,className:"image",src:l.dataUri})})}function Xp(e){let t="";const n=new Uint8Array(e);for(let r=0;r<n.byteLength;r++)t+=String.fromCharCode(n[r]);return btoa(t)}function Gp(e){const t=e.split(".").pop()??"";return Yp[t]||"image/png"}function Zp({text:e,className:t}){function n(r){const l=[],i=r.split(`
46
  `);let o=!1,u=[],s=!1,a=[];for(let h=0;h<i.length;h++){const p=i[h];if(p.startsWith("```")){o?(l.push(v.jsx("pre",{children:u.join(`
47
  `)},`code-${h.toLocaleString("en-US")}`)),o=!1,u=[]):o=!0;continue}if(o){u.push(p);continue}if(p.includes("**")){const y=p.split("**");l.push(v.jsx("p",{children:y.map((g,S)=>S%2?v.jsx("strong",{children:g},S):g)},h));continue}if(p.includes("*")){const y=p.split("*");l.push(v.jsx("p",{children:y.map((g,S)=>S%2?v.jsx("em",{children:g},S):g)},h));continue}if(p.startsWith("#")){const y=p.split(" ")[0].length,g=p.slice(y+1),S=`h${y.toLocaleString("en-US")}`;l.push(v.jsx(S,{children:g},h));continue}const m=/!\[(.*?)\]\((.*?)\)/.exec(p);if(m){const[,y,g]=m;l.push(v.jsx("img",{src:g,alt:y},h));continue}if(p.includes("[")&&p.includes("]")&&p.includes("(")&&p.includes(")")){const y=p.replace(/\[(.*?)\]\((.*?)\)/g,(g,S,I)=>`<a href="${I}" target="_blank" rel="noreferrer">${S}</a>`);l.push(v.jsx("p",{dangerouslySetInnerHTML:{__html:y}},h));continue}if(p.startsWith("-")||p.startsWith("*")||p.startsWith("+")){const y=p.slice(1).trim();a.push(v.jsx("li",{children:y},`list-item-${h.toLocaleString("en-US")}`)),s=!0;continue}s&&a.length>0&&(l.push(v.jsx("ul",{children:a},`list-${h.toLocaleString("en-US")}`)),a=[],s=!1),l.push(v.jsx("p",{children:p},h))}return o&&u.length>0&&l.push(v.jsx("pre",{children:u.join(`
48
+ `)},`code-${i.length.toLocaleString("en-US")}`)),s&&a.length>0&&l.push(v.jsx("ul",{children:a},`list-${i.length.toLocaleString("en-US")}`)),v.jsx("div",{className:t,children:l})}return n(e)}function Jp({url:e,setError:t}){const[n,r]=j.useState(0),[l,i]=j.useState();return j.useEffect(()=>{async function o(){try{const s=await(await fetch(e)).text();i(s)}catch(u){t(u)}finally{r(2)}}r(u=>u!==0?u:(o().catch(()=>{}),1))},[e,n,t]),v.jsx(Ol,{content:{fileSize:l==null?void 0:l.length},children:v.jsx(Zp,{className:"markdown",text:l??""})})}var hs,ms,vs={exports:{}},jn={},q=(ms||(ms=1,vs.exports=function(){if(hs)return jn;hs=1;var e=sf,t=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,l=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,i={key:!0,ref:!0,__self:!0,__source:!0};function o(u,s,a){var h,p={},m=null,y=null;for(h in a!==void 0&&(m=""+a),s.key!==void 0&&(m=""+s.key),s.ref!==void 0&&(y=s.ref),s)r.call(s,h)&&!i.hasOwnProperty(h)&&(p[h]=s[h]);if(u&&u.defaultProps)for(h in s=u.defaultProps)p[h]===void 0&&(p[h]=s[h]);return{$$typeof:t,type:u,key:m,ref:y,props:p,_owner:l.current}}return jn.Fragment=n,jn.jsx=o,jn.jsxs=o,jn}()),vs.exports);function eo(e,t,n){if(Array.isArray(e))return e;const r=new Array(t).fill(null).map(l=>Object.fromEntries(n.map(i=>[i,eh()])));return(e instanceof Promise?e:Promise.resolve(e)).then(l=>{l.length!==t&&console.warn(`Expected ${t} rows, got ${l.length}`);for(let i=0;i<l.length;i++){const o=l[i];for(const u of n)r[i][u].resolve(o[u])}}).catch(l=>{for(let i=0;i<t;i++)for(const o of n)r[i][o].reject(l)}),r}function bp(e){e instanceof Promise||(e=Promise.resolve(e));const t=e.then(n=>(t.resolved=n,n)).catch(n=>{throw t.rejected=n,n});return t}function eh(){let e,t;const n=bp(new Promise((r,l)=>{e=r,t=l}));return n.resolve=e,n.reject=t,n}const th=10;function nh({header:e,columnWidths:t,orderBy:n,setColumnWidth:r,setColumnWidths:l,setOrderBy:i,dataReady:o}){const[u,s]=j.useState(),a=j.useRef(e.map(()=>j.createRef()));function h(m){return m.current?m.current.offsetWidth-2*th:void 0}j.useEffect(()=>{if(o){const m=a.current.map(h);l(m)}},[o,e]),j.useEffect(()=>{function m(){u&&s(void 0)}function y({clientX:g}){u&&r(u.columnIndex,Math.max(1,g-u.clientX))}return u&&(window.addEventListener("mousemove",y),window.addEventListener("mouseup",m)),()=>{window.removeEventListener("mousemove",y),window.removeEventListener("mouseup",m)}},[e,u,l]);const p=j.useMemo(()=>t.map(to),[t]);return q.jsx("thead",{children:q.jsxs("tr",{children:[q.jsx("th",{children:q.jsx("span",{})}),e.map((m,y)=>q.jsxs("th",{className:n===m?"orderby":void 0,onClick:()=>function(g){i==null||i(n===g?void 0:g)}(m),ref:a.current[y],style:p[y],title:m,children:[m,q.jsx("span",{onDoubleClick:()=>function(g){Rc.flushSync(()=>{r(g,void 0)});const S=h(a.current[g]);r(g,S)}(y),onMouseDown:g=>function(S,I){I.stopPropagation(),s({columnIndex:S,clientX:I.clientX-(t[S]||0)})}(y,g)})]},y))]})})}function to(e){const t=e?`${e}px`:void 0;return{minWidth:t,maxWidth:t}}function rh(e){const t={};return{...e,rows(n,r,l){var u;const i=t[u=l||""]||(t[u]=new Array(e.numRows));let o;for(let s=n;s<r;s++)if(i[s]){if(o!==void 0){const a=s,h=a-o,p=eo(e.rows(o,a,l),h,e.header);for(let m=0;m<a-o;m++)i[o+m]=p[m];o=void 0}}else o===void 0&&(o=s);if(o!==void 0){const s=r,a=s-o,h=eo(e.rows(o,s,l),a,e.header);for(let p=0;p<s-o;p++)i[o+p]=h[p]}return i.slice(n,r)}}}function lh(e,t){switch(t.type){case"SET_ROWS":return{...e,startIndex:t.start,rows:t.rows,dataReady:e.dataReady||t.hasCompleteRow};case"SET_COLUMN_WIDTH":{const n=[...e.columnWidths];return n[t.columnIndex]=t.columnWidth,{...e,columnWidths:n}}case"SET_COLUMN_WIDTHS":return{...e,columnWidths:t.columnWidths};case"SET_ORDER":return{...e,orderBy:t.orderBy};case"SET_PENDING":return{...e,pending:t.pending};case"DATA_CHANGED":return{...e,dataReady:!1};default:return e}}const ih={columnWidths:[],startIndex:0,rows:[],dataReady:!1,pending:!1};function oh({data:e,overscan:t=20,padding:n=20,onDoubleClickCell:r,onError:l=console.error}){const[i,o]=j.useReducer(lh,ih),{columnWidths:u,startIndex:s,rows:a,orderBy:h,dataReady:p,pending:m}=i,y=j.useRef(0),g=j.useRef(null),S=j.useRef(null),I=j.useRef(0),c=j.useRef(!1);if(!e)throw new Error("HighTable: data is required");const f=33*(e.numRows+1);function d(L,O){if(L.length>0&&L.length!==e.header.length)return`Row ${O+1} length ${L.length} does not match header length ${e.header.length}`}j.useEffect(()=>{async function L(){var st,E;const Xe=((st=g.current)==null?void 0:st.clientHeight)||100,Oe=((E=g.current)==null?void 0:E.scrollTop)||0;let Se=Math.floor(e.numRows*Oe/f),We=Math.ceil(e.numRows*(Oe+Xe)/f);if(Se=Math.max(0,Se-t),We=Math.min(e.numRows,We+t),isNaN(Se))throw new Error("invalid start row "+Se);if(isNaN(We))throw new Error("invalid end row "+We);const Ge=Math.max(0,Oe-33*n);try{const R=++I.current,T=eo(e.rows(Se,We,h),We-Se,e.header),W=function($,_e){let ie=0,Ve=!1;return()=>{const he=Date.now();he-ie>_e?(ie=he,$()):Ve||(Ve=!0,setTimeout(()=>{ie=Date.now(),Ve=!1,$()},_e-(he-ie)))}}(()=>{const $=[];let _e=!1;for(const ie of T){const Ve={};let he=!0;for(const[Vt,eu]of Object.entries(ie))"resolved"in eu?Ve[Vt]=eu.resolved:he=!1;he&&(_e=!0),$.push(Ve)}y.current=Ge,o({type:"SET_ROWS",start:Se,rows:$,hasCompleteRow:_e})},10);W();for(const $ of T)for(const[_e,ie]of Object.entries($))ie.then(()=>{I.current===R&&W()}).catch(()=>{});for(const $ of T)for(const _e of Object.values($))await _e;c.current&&(c.current=!1,L())}catch(R){o({type:"SET_PENDING",pending:!1}),l(R)}}L();const O=g.current;return O==null||O.addEventListener("scroll",L),window.addEventListener("resize",L),()=>{O==null||O.removeEventListener("scroll",L),window.removeEventListener("resize",L)}},[e,h,t,n,f,l]);const w=j.useMemo(()=>u.map(to),[u]);j.useEffect(()=>{var L;(L=S.current)==null||L.focus()},[]),j.useEffect(()=>{o({type:"DATA_CHANGED"})},[e]);const k=j.useCallback(L=>a[L].__index__??L+s+1,[a,s]),N=Array.from({length:Math.min(n,s)},()=>[]),C=Array.from({length:Math.min(n,e.numRows-s-a.length)},()=>[]),P=4*Math.ceil(Math.log10(e.numRows+1))+22,U=j.useMemo(()=>to(P),[P]);if(e.header.length)return q.jsxs("div",{className:m?"table-container pending":"table-container",children:[q.jsx("div",{className:"table-scroll",ref:g,children:q.jsx("div",{style:{height:`${f}px`},children:q.jsxs("table",{"aria-colcount":e.header.length,"aria-rowcount":e.numRows,className:e.sortable?"table sortable":"table",ref:S,role:"grid",style:{top:`${y.current}px`},tabIndex:0,children:[q.jsx(nh,{columnWidths:u,dataReady:p,header:e.header,orderBy:h,setColumnWidth:(L,O)=>o({type:"SET_COLUMN_WIDTH",columnIndex:L,columnWidth:O}),setColumnWidths:L=>o({type:"SET_COLUMN_WIDTHS",columnWidths:L}),setOrderBy:L=>e.sortable&&o({type:"SET_ORDER",orderBy:L})}),q.jsxs("tbody",{children:[N.map((L,O)=>q.jsx("tr",{children:q.jsx("td",{style:U,children:(s-N.length+O+1).toLocaleString()})},s-N.length+O)),a.map((L,O)=>q.jsxs("tr",{title:d(L,O),children:[q.jsx("td",{style:U,children:k(O).toLocaleString()}),e.header.map((Xe,Oe)=>{var Se;return function(We,Ge,st,E){let R,T=no(We);return typeof T=="string"&&(T.length>400&&(T=`${T.slice(0,397)}…`),T.length>100&&(R=T)),q.jsx("td",{className:T===void 0?"pending":void 0,onDoubleClick:()=>r==null?void 0:r(Ge,E??st),style:w[Ge],title:R,children:T},Ge)}(L[Xe],Oe,s+O,(Se=L.__index__)==null?void 0:Se.resolved)})]},s+O)),C.map((L,O)=>q.jsx("tr",{children:q.jsx("td",{style:U,children:(s+a.length+O+1).toLocaleString()})},s+a.length+O))]})]})})}),q.jsx("div",{className:"table-corner",style:U,children:" "}),q.jsx("div",{className:"mock-row-label",style:U,children:" "})]})}function no(e){return typeof e=="string"?e:typeof e=="number"?e.toLocaleString():Array.isArray(e)?`[${e.map(no).join(", ")}]`:e==null?JSON.stringify(e):e instanceof Date?e.toISOString():typeof e=="object"?`{${Object.entries(e).map(([t,n])=>`${t}: ${no(n)}`).join(", ")}}`:e.toString()}function uh({url:e,resolveUrl:t,setProgress:n,setError:r}){const[l,i]=j.useState(0),[o,u]=j.useState();j.useEffect(()=>{async function h(){try{n(.33);const p=await $c(t),m={url:t,byteLength:p.byteLength};n(.66);const y=await Mc(p);let g=Uc(m,y);g=rh(g);const S=p.byteLength;u({dataframe:g,fileSize:S})}catch(p){r(p)}finally{i(2),n(1)}}l===0&&(i(1),h().catch(()=>{}))},[l,e,t,r,n]);const s=(h,p)=>{bo(`?url=${e}&row=${p.toString()}&col=${h.toString()}`)},a=v.jsx(v.Fragment,{children:(o==null?void 0:o.dataframe)&&v.jsxs("span",{children:[o.dataframe.numRows.toLocaleString("en-US")," rows"]})});return v.jsxs(Ol,{content:o,headers:a,children:[(o==null?void 0:o.dataframe)&&v.jsx(oh,{data:o.dataframe,onDoubleClickCell:s,onError:r}),l&&v.jsx(Rl,{className:"center"})]})}function sh({url:e,setError:t}){const[n,r]=j.useState(0),[l,i]=j.useState(),o=j.useRef(null);j.useEffect(()=>{async function s(){try{const h=await(await fetch(e)).text();i(h)}catch(a){t(a)}finally{r(2)}}r(a=>a!==0?a:(s().catch(()=>{}),1))},[e,n,t]);const u=v.jsx(v.Fragment,{children:v.jsxs("span",{children:[l?ah(l):0," lines"]})});return v.jsxs(Ol,{content:{fileSize:l==null?void 0:l.length},headers:u,children:[v.jsx("code",{className:"text",ref:o,children:l}),n&&v.jsx(Rl,{className:"center"})]})}function ah(e){let t=0;for(const n of e)n===`
49
  `&&t++;return t.toLocaleString("en-US")}function ch({url:e,resolveUrl:t,setError:n,setProgress:r}){const l=e.replace(/\?.*$/,"");return l.endsWith(".md")?v.jsx(Jp,{url:t,setError:n}):l.endsWith(".parquet")?v.jsx(uh,{url:e,resolveUrl:t,setError:n,setProgress:r}):Kp.some(i=>l.endsWith(i))?v.jsx(qp,{url:t,setError:n}):v.jsx(sh,{url:t,setError:n,setProgress:r})}function fh({url:e}){const[t,n]=j.useState(),[r,l]=j.useState(),i=e.kind==="file"?e.resolveUrl:e.raw,o=i.split("/");if(o.length<1)throw new Error("Invalid URL path");const u=o.at(-1);return v.jsxs(cr,{progress:t,error:r,title:u,children:[v.jsx(zl,{url:e}),v.jsx(ch,{url:e.raw,resolveUrl:i,setProgress:n,setError:l})]})}var dh=Object.defineProperty,ph=(e,t,n)=>t in e?dh(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Tr=(e,t,n)=>(ph(e,typeof t!="symbol"?t+"":t,n),n),Fc="https://huggingface.co";async function Bc(e,t){var n,r;const l=new hh(e.url,e.status,(n=e.headers.get("X-Request-Id"))!=null?n:void 0);l.message=`Api error with status ${l.statusCode}`;const i=[`URL: ${l.url}`,l.requestId?`Request ID: ${l.requestId}`:void 0].filter(Boolean).join(". ");if((r=e.headers.get("Content-Type"))!=null&&r.startsWith("application/json")){const o=await e.json();l.message=o.error||o.message||l.message,l.data=o}else l.data={message:await e.text()};throw l.message+=`. ${i}`,l}var hh=class extends Error{constructor(e,t,n,r){super(r),Tr(this,"statusCode"),Tr(this,"url"),Tr(this,"requestId"),Tr(this,"data"),this.statusCode=t,this.requestId=n,this.url=e}};function gs(e){if(!e.startsWith("hf_"))throw new TypeError("Your access token must start with 'hf_'")}function Wc(e){var t;if(e.accessToken)return gs(e.accessToken),e.accessToken;if((t=e.credentials)!=null&&t.accessToken)return gs(e.credentials.accessToken),e.credentials.accessToken}function mh(e){if(typeof e!="string")return e;if(e.startsWith("model/")||e.startsWith("models/"))throw new TypeError("A repo designation for a model should not start with 'models/', directly specify the model namespace / name");if(e.startsWith("space/"))throw new TypeError("Spaces should start with 'spaces/', plural, not 'space/'");if(e.startsWith("dataset/"))throw new TypeError("Datasets should start with 'dataset/', plural, not 'dataset/'");const t=e.split("/").length-1;if(e.startsWith("spaces/")){if(t!==2)throw new TypeError("Space Id must include namespace and name of the space");return{type:"space",name:e.slice(7)}}if(e.startsWith("datasets/")){if(t>2)throw new TypeError("Too many slashes in repo designation: "+e);return{type:"dataset",name:e.slice(9)}}if(t>1)throw new TypeError("Too many slashes in repo designation: "+e);return{type:"model",name:e}}new Promise(e=>{});function vh(e,t){return Object.assign({},...t.map(n=>{if(e[n]!==void 0)return{[n]:e[n]}}))}function Vc(e){const t=/<(https?:[/][/][^>]+)>;\s+rel="([^"]+)"/g;return Object.fromEntries([...e.matchAll(t)].map(([,n,r])=>[r,n]))}var gh=["private","downloads","gated","likes","lastModified"];async function*yh(e){var t,n,r,l,i,o,u,s,a;const h=e&&Wc(e);let p=(t=e==null?void 0:e.limit)!=null?t:1/0;const m=new URLSearchParams([...Object.entries({limit:String(Math.min(p,500)),...(n=e==null?void 0:e.search)!=null&&n.owner?{author:e.search.owner}:void 0,...(r=e==null?void 0:e.search)!=null&&r.query?{search:e.search.query}:void 0}),...(o=(i=(l=e==null?void 0:e.search)==null?void 0:l.tags)==null?void 0:i.map(g=>["filter",g]))!=null?o:[],...gh.map(g=>["expand",g]),...(s=(u=e==null?void 0:e.additionalFields)==null?void 0:u.map(g=>["expand",g]))!=null?s:[]]).toString();let y=`${(e==null?void 0:e.hubUrl)||Fc}/api/datasets`+(m?"?"+m:"");for(;y;){const g=await((a=e==null?void 0:e.fetch)!=null?a:fetch)(y,{headers:{accept:"application/json",...e!=null&&e.credentials?{Authorization:`Bearer ${h}`}:void 0}});if(!g.ok)throw await Bc(g);const S=await g.json();for(const c of S)if(yield{...(e==null?void 0:e.additionalFields)&&vh(c,e.additionalFields),id:c._id,name:c.id,private:c.private,downloads:c.downloads,likes:c.likes,gated:c.gated,updatedAt:new Date(c.lastModified)},p--,p<=0)return;const I=g.headers.get("Link");y=I?Vc(I).next:void 0}}async function*wh(e){var t;const n=Wc(e),r=mh(e.repo);let l=`${e.hubUrl||Fc}/api/${r.type}s/${r.name}/tree/${e.revision||"main"}${e.path?"/"+e.path:""}?recursive=${!!e.recursive}&expand=${!!e.expand}`;for(;l;){const i=await((t=e.fetch)!=null?t:fetch)(l,{headers:{accept:"application/json",...n?{Authorization:`Bearer ${n}`}:void 0}});if(!i.ok)throw await Bc(i);const o=await i.json();for(const s of o)yield s;const u=i.headers.get("Link");l=u?Vc(u).next:void 0}}function Sh({url:e}){const[t,n]=j.useState(),[r,l]=j.useState(),i=j.useRef(null);j.useEffect(()=>{async function s(){const a=wh({repo:`datasets/${e.namespace}/${e.repo}`,revision:e.branch,path:e.path.replace(/^\//,"")}),h=[];for await(const p of a)h.push(p);n(h)}s().catch(a=>{n([]),l(a)})},[e]);const o=j.useCallback(s=>{const a=s.type==="directory"?"tree":"blob";return`${be}/${e.namespace}/${e.repo}/${a}/${e.branch}/${s.path}`},[e]),u=j.useCallback(s=>s.path.split("/").at(-1),[]);return v.jsxs(cr,{error:r,title:e.path,children:[v.jsx(zl,{url:e}),t&&t.length>0&&v.jsx("ul",{className:"file-list",ref:i,children:t.map((s,a)=>v.jsx("li",{children:v.jsxs(Il,{url:o(s),children:[v.jsx("span",{className:hl("file-name","file",s.type==="directory"&&"folder"),children:u(s)}),s.type==="file"&&v.jsx(v.Fragment,{children:v.jsx("span",{className:"file-size",title:s.size.toLocaleString("en-US")+" bytes",children:Ac(s.size)})})]})},a))}),(t==null?void 0:t.length)===0&&v.jsx("div",{className:"center",children:"No files"}),t===void 0&&v.jsx(Rl,{className:"center"})]})}function _h({url:e}){const[t,n]=j.useState(),[r,l]=j.useState(),i=j.useRef(null);j.useEffect(()=>{Vp(e.namespace,e.repo).then(n).catch(u=>{n([]),l(u)})},[e]);const o=j.useCallback(u=>{var h,p;const s=((p=(h=/^(refs\/(heads|tags)\/)?(?<pathElement>[^/]+)$/.exec(u.ref))==null?void 0:h.groups)==null?void 0:p.pathElement)??u.ref,a=`${be}/${e.namespace}/${e.repo}/tree/${encodeURIComponent(s)}/`;return v.jsx(Il,{url:a,children:s})},[e]);return v.jsxs(cr,{error:r,title:`${e.namespace}/${e.repo}`,children:[v.jsx(zl,{url:e}),v.jsxs("h2",{children:["Dataset ",v.jsxs("code",{children:[e.namespace,"/",e.repo]})]}),v.jsx("p",{children:"Select a branch"}),t&&t.length>0&&v.jsx("ul",{className:"ref-list",ref:i,children:t.map((u,s)=>v.jsx("li",{className:"ref-"+u.refType,children:o(u)},s))}),(t==null?void 0:t.length)===0&&v.jsx("div",{className:"center",children:"No branches"}),t===void 0&&v.jsx(Rl,{className:"center"})]})}function kh(){const[e,t]=j.useState(),[n,r]=j.useState([]);j.useEffect(()=>{async function i(){const o=[];for await(const u of yh({search:{query:e},limit:10}))o.push(u);r(o)}i().catch(o=>{r([]),console.error(o)})},[e]);function l(i){t(i.target.value)}return v.jsxs(v.Fragment,{children:[v.jsx("input",{type:"search",onChange:l}),v.jsx("ul",{className:"ref-list",children:n.map(i=>v.jsx("li",{style:{fontSize:"0.9rem"},children:v.jsx(Il,{url:`${be}/${i.name}`,children:i.name})},i.name))})]})}function ys(){const e=j.useRef(null);function t(n){n.preventDefault();const r=new FormData(n.currentTarget).get("url");bo(`?url=${r}`)}return v.jsxs("div",{id:"welcome",children:[v.jsx("h1",{children:"hyparquet"}),v.jsxs("sub",{children:["/haɪ pɑːrˈkeɪ/",v.jsx("img",{src:"audio.svg",alt:"play hyparquet pronunciation",height:"18",width:"18",onClick:()=>{var n;(n=e.current)==null||n.play().catch(()=>{})}})]}),v.jsx("audio",{ref:e,src:"hyparquet.mp3"}),v.jsx("h2",{children:"in-browser parquet file reader"}),v.jsxs("p",{children:[v.jsx("a",{href:"https://www.npmjs.com/package/hyparquet",children:v.jsx("img",{src:"https://img.shields.io/npm/v/hyparquet",alt:"npm hyparquet"})})," ",v.jsx("a",{href:"https://github.com/hyparam/hyparquet",children:v.jsx("img",{src:"https://img.shields.io/github/stars/hyparam/hyparquet?style=social",alt:"star hyparquet"})})]}),v.jsxs("p",{children:["Online demo of"," ",v.jsx("a",{href:"https://github.com/hyparam/hyparquet",children:"hyparquet"}),": a parser for apache parquet files. Uses"," ",v.jsx("a",{href:"https://github.com/hyparam/hightable",children:"hightable"})," for high performance windowed table viewing."]}),v.jsxs("section",{children:[v.jsx("h3",{children:"Select a dataset on Hugging Face"}),v.jsx("p",{children:"Search for a dataset:"}),v.jsx(kh,{})]}),v.jsxs("section",{children:[v.jsx("h3",{children:"Parquet URL"}),v.jsx("p",{children:"You can also set a url to see your parquet data. 👀"}),v.jsxs("form",{onSubmit:t,style:{display:"flex",gap:"1rem"},children:[v.jsx("label",{htmlFor:"url",children:"URL"}),v.jsx("input",{name:"url",defaultValue:"https://huggingface.co/datasets/codeparrot/github-code/resolve/main/data/train-00000-of-01126.parquet",style:{width:"100%"},type:"url"}),v.jsx("button",{style:{fontSize:"1rem",padding:"0 0.5rem"},type:"submit",children:"Open"})]}),v.jsxs("p",{children:[v.jsx("p",{children:"Example files:"}),v.jsxs("ul",{className:"quick-links",children:[v.jsx("li",{children:v.jsx("a",{className:"aws",href:"?url=https://hyperparam-public.s3.amazonaws.com/wiki-en-00000-of-00041.parquet",children:"s3://wiki-en-00000-of-00041.parquet"})}),v.jsx("li",{children:v.jsx("a",{className:"azure",href:"?url=https://hyperparam.blob.core.windows.net/hyperparam/starcoderdata-js-00000-of-00065.parquet",children:"azure://starcoderdata-js-00000-of-00065.parquet"})}),v.jsx("li",{children:v.jsx("a",{className:"huggingface",href:"?url=https://huggingface.co/datasets/codeparrot/github-code/resolve/main/data/train-00000-of-01126.parquet?download=true",children:"huggingface://github-code-00000-of-01126.parquet"})}),v.jsx("li",{children:v.jsx("a",{className:"github",href:"?url=https://raw.githubusercontent.com/hyparam/hyparquet/master/test/files/rowgroups.parquet",children:"github://rowgroups.parquet"})})]})]})]})]})}function Eh(){const e=new URLSearchParams(location.search),t=e.get("url");if(Array.isArray(t))throw new Error("url must be a string");if(t===null)return v.jsx(ys,{});try{const n=Up(t);return n.kind==="base"?v.jsx(ys,{}):n.kind==="repo"?v.jsx(_h,{url:n}):n.kind==="folder"?v.jsx(Sh,{url:n}):e.has("col")&&e.has("row")?v.jsx(Fp,{url:n,row:Number(e.get("row")),col:Number(e.get("col"))}):v.jsx(fh,{url:n})}catch(n){return v.jsx(cr,{error:n,title:"Error",children:v.jsx("div",{className:"error",children:n.message})})}}const Hc=document.getElementById("app");if(!Hc)throw new Error("No root element");Ic(Hc).render(v.jsx(j.StrictMode,{children:v.jsx(Eh,{})}));
index.html CHANGED
@@ -9,8 +9,8 @@
9
  <link rel="icon" type="image/svg+xml" href="/assets/logo.svg" />
10
  <meta name="theme-color" content="#6b00ff">
11
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
12
- <script type="module" crossorigin src="/assets/index-Cf29TKpY.js"></script>
13
- <link rel="stylesheet" crossorigin href="/assets/index-BYAzjtBd.css">
14
  </head>
15
  <body>
16
  <div id="app"></div>
 
9
  <link rel="icon" type="image/svg+xml" href="/assets/logo.svg" />
10
  <meta name="theme-color" content="#6b00ff">
11
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
12
+ <script type="module" crossorigin src="/assets/index-r_9wT5u5.js"></script>
13
+ <link rel="stylesheet" crossorigin href="/assets/index-CoWC0pAZ.css">
14
  </head>
15
  <body>
16
  <div id="app"></div>