1!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="9c44a61e-804f-40ba-94e7-63bccbafb3cf",e._sentryDebugIdIdentifier="sentry-dbid-9c44a61e-804f-40ba-94e7-63bccbafb3cf")}catch(e){}}();"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4356],{44356:(e,t,a)=>{a.d(t,{default:()=>E});var n=a(95155),s=a(12480),i=a(16214),o=a(70062),r=a(18695),l=a(99660),c=a(43312),d=a(90747),h=a(64771),u=a(57303),m=a(47250),p=a(39493),f=a(61108),g=a(42695),x=a(29468),y=a(73691),v=a(66088),b=a(94514),w=a(61878),j=a(23714),T=a(12115),k=a(68332),N=a(58391),I=a(4066);function S(e){let{makeUrl:t}=e,a=(0,m.rd)();return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("div",{className:"mb-1.5 flex flex-row items-center justify-start gap-x-2 text-center font-sans text-[10px] uppercase text-slate-500",children:"Run Example Search"}),(0,n.jsxs)("div",{className:"grid grid-cols-3 gap-x-1.5 gap-y-1.5 sm:grid-cols-6",children:[(0,n.jsxs)(c.$,{onClick:e=>{e.preventDefault();let n=N.K[Math.floor(Math.random()*N.K.length)];a.push(t(n))},variant:"outline",size:"sm",className:"h-12 gap-x-2 shadow-sm","data-sentry-element":"Button","data-sentry-source-file":"examples-buttons.tsx",children:[(0,n.jsx)(I.A,{className:"h-4 w-4","data-sentry-element":"Dices","data-sentry-source-file":"examples-buttons.tsx"}),"Random"]}),N.C.map(e=>(0,n.jsx)(c.$,{onClick:n=>{var s;n.preventDefault();let i=null==(s=N.C.find(t=>t.type===e.type))?void 0:s.examples;if(i){let e=i[Math.floor(Math.random()*i.length)];a.push(t(e))}},variant:"outline",size:"sm",className:"h-12 gap-x-2 shadow-sm",children:e.type},e.type))]})]})}var C=a(53869),A=a(45108);function D(e){var t,a,s,i,o,l,c,d;let{result:u,tokens:m,topExplanation:p,searchSortIndexes:f,showDashboards:g}=e,{getSourceSet:x}=(0,r.SF)();return(0,n.jsx)("a",{href:"/".concat(u.modelId,"/").concat(u.layer,"/").concat(u.index),target:"_blank",rel:"noreferrer",className:"group flex w-full cursor-pointer flex-col items-center justify-center border-b border-slate-100 bg-white px-3 py-5 sm:px-5","data-sentry-component":"ResultItem","data-sentry-source-file":"result-item.tsx",children:(0,n.jsxs)("div",{className:"flex w-full max-w-screen-lg flex-col items-start justify-center gap-x-2 sm:flex-row sm:gap-x-5",children:[(0,n.jsxs)("div",{className:"flex basis-4/12 flex-col items-center justify-start font-mono text-[11px] font-medium text-slate-500 sm:basis-3/12",children:[(0,n.jsx)("span",{className:"mb-1 mt-0 flex flex-col font-sans leading-tight ".concat(p?"text-[12px] text-slate-700 sm:text-sm":"text-[12px] text-slate-500 sm:text-xs"),children:p?p.description:(0,n.jsx)("div",{className:"flex flex-col items-center justify-center gap-y-0.5 text-center",children:(0,n.jsx)("div",{children:"No Explanation"})})}),(0,n.jsxs)("span",{className:"mb-2.5 rounded-md px-2 py-1 text-[10px] font-bold uppercase text-slate-600 group-hover:bg-sky-200 sm:mb-1 sm:text-xs",children:[u.layer,":",u.index]})]}),(0,n.jsxs)("div",{className:"flex basis-8/12 flex-col sm:basis-9/12",children:[(0,n.jsxs)("div",{className:"mt-0 flex ".concat(f.length>0?"flex-col":"flex-row items-center"," gap-x-2"),children:[f.length>0?(0,n.jsxs)("div",{className:"mb-1.5 flex max-w-screen-md flex-row gap-x-1 overflow-x-scroll",children:[f.length>1&&(0,n.jsxs)("div",{className:"sticky left-0 flex flex-col items-center justify-center gap-y-0.5 bg-white pr-1",children:[(0,n.jsx)("div",{className:"px-1 text-[10px] font-bold uppercase text-slate-400",children:"Sum"}),(0,n.jsx)("span",{className:"mt-0 text-[11px] text-emerald-700",children:f.map(e=>u.values[e]).reduce((e,t)=>e+t,0).toFixed(1)})]}),f.map(e=>(0,n.jsxs)("div",{className:"flex flex-col items-center justify-center gap-y-0.5",children:[(0,n.jsx)("div",{className:"whitespace-pre rounded bg-slate-200 px-1 font-mono text-xs font-medium",children:(0,h.Bn)(m[e])}),(0,n.jsx)("span",{className:"mt-0 text-[11px] text-emerald-700",children:u.values[e].toFixed(1)})]},e))]}):(0,n.jsxs)("div",{className:"flex flex-col items-center gap-y-0.5 px-2 text-xs text-slate-700",children:[(0,n.jsx)("div",{className:"whitespace-pre rounded bg-slate-200 px-1 font-mono font-medium",children:(0,h.Bn)(m[u.maxValueIndex])}),(0,n.jsx)("span",{className:"mt-0 text-[11px] text-emerald-700",children:u.maxValue.toFixed(1)})]}),(0,n.jsx)(C.default,{showLineBreaks:!1,activation:{values:u.values,tokens:m,maxValueTokenIndex:u.maxValueIndex,maxValue:u.maxValue,dfaValues:u.dfaValues,dfaMaxValue:u.dfaMaxValue,dfaTargetIndex:u.dfaTargetIndex},enableExpanding:!1,overrideLeading:"leading-none",overrideTextSize:"text-xs",dfa:null==(t=x((null==(a=u.neuron)?void 0:a.modelId)||"",(null==(s=u.neuron)?void 0:s.sourceSetName)||""))?void 0:t.showDfa,"data-sentry-element":"ActivationItem","data-sentry-source-file":"result-item.tsx"})]}),g&&u.neuron&&(0,n.jsxs)("div",{className:"mt-3 flex flex-col rounded-md border border-slate-200 px-3 pb-3",children:[u.neuron&&u.neuron.activations&&u.neuron.activations[0]&&(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("div",{className:"mb-0.5 mt-3 text-left text-[12px] font-bold uppercase text-slate-600",children:"Top Activation"}),(0,n.jsxs)("div",{className:"mt-1 flex flex-row gap-x-2",children:[u.neuron.activations&&u.neuron.activations.length>0&&u.neuron.activations[0].tokens&&u.neuron.activations[0].values&&(0,n.jsxs)("div",{className:"flex flex-col items-center gap-y-0.5 px-2 text-xs text-slate-700",children:[(0,n.jsx)("span",{className:"whitespace-pre rounded bg-slate-200 px-1 font-mono font-medium",children:(0,h.Bn)(u.neuron.activations[0].tokens[u.neuron.activations[0].maxValueTokenIndex||0])}),(0,n.jsx)("span",{className:"mt-0 text-[11px] text-emerald-700",children:u.neuron.activations[0].values[u.neuron.activations[0].maxValueTokenIndex||0].toFixed(1)})]}),(0,n.jsx)(C.default,{showLineBreaks:!1,activation:{values:u.neuron.activations[0].values,tokens:u.neuron.activations[0].tokens,maxValueTokenIndex:u.neuron.activations[0].maxValueTokenIndex,maxValue:u.neuron.activations[0].maxValue,dfaValues:u.neuron.activations[0].dfaValues,dfaMaxValue:u.neuron.activations[0].dfaMaxValue,dfaTargetIndex:u.neuron.activations[0].dfaTargetIndex},enableExpanding:!1,tokensToDisplayAroundMaxActToken:10,overrideLeading:"leading-none",overrideTextSize:"text-xs",dfa:null==(i=x(null==(o=u.neuron)?void 0:o.modelId,(null==(l=u.neuron)?void 0:l.sourceSetName)||""))?void 0:i.showDfa})]})]}),(null==(c=u.neuron)?void 0:c.pos_str)&&(null==(d=u.neuron)?void 0:d.pos_str.length)>0&&(0,n.jsx)("div",{className:"pointer-events-none mb-0 mt-2 pt-2",children:(0,n.jsx)(A.A,{currentNeuron:u.neuron})})]})]})]})},u.index)}function E(e){var t;let{q:a,initialSelectedLayers:N=[],initialSortIndexes:I,initialModelId:C,initialSourceSet:A,initialIgnoreBos:E,showSourceSets:L=!0,showModels:V=!0,showExamples:O=!0,filterToRelease:M}=e,{exploreState:z,submitSearchAll:R,setTokens:F,tokens:q,searchSortIndexes:H,setSearchResults:B,searchResults:P}=(0,l.TT)(),{getSourcesForSourceSet:G,getDefaultModel:U,globalModels:W}=(0,r.SF)(),[J,_]=(0,T.useState)(I||[]),[Q,K]=(0,T.useState)(C||d.rH||(null==(t=U())?void 0:t.id)||d.rH),[Y,$]=(0,T.useState)(A||d.id),[Z,X]=(0,T.useState)(N),[ee,et]=(0,T.useState)(void 0===E||E),[ea,en]=(0,T.useState)(!0),[es,ei]=(0,T.useState)([]),[eo,er]=(0,T.useState)(!0),[el,ec]=(0,T.useState)(!1),ed=(0,T.useRef)(null),eh=(0,m.rd)(),eu=void 0===a;function em(e){return"/".concat(Q,"/?sourceSet=").concat(Y,"&selectedLayers=").concat(JSON.stringify(Z),"&sortIndexes=").concat(JSON.stringify(J),"&ignoreBos=").concat(ee,"&q=").concat(encodeURIComponent(e))}function ep(){var e;let t=null==(e=ed.current)?void 0:e.values;if(void 0!==t){if(t.searchQuery.length>800)return void alert("Must be shorter than ".concat(800," characters"));if(!Z)return void alert("Please select at least one layer to search.");if(0===t.searchQuery.trim().length)return void alert("Please enter a search query.");if(eu)return void eh.push(em(t.searchQuery));B([]),F([]),R(Q,t.searchQuery,Z,Y,ee,J)}}return(0,T.useEffect)(()=>
1{z===l.Cs.LOADED&&ec(!0)},[Z,J,ee]),(0,T.useEffect)(()=>{if(void 0!==a){var e;R(Q,a,Z,Y,ee,J),null==(e=ed.current)||e.setFieldValue("searchQuery",a)}},[a]),(0,T.useEffect)(()=>{z===l.Cs.LOADED&&ed.current?(window.history.pushState({},"",em(ed.current.values.searchQuery)),ei(G(Q,Y,!1,!0,!1))):window.history.pushState({},"",document.location.toString().split(/[?#]/)[0]),z===l.Cs.RUNNING&&ec(!1)},[z]),(0,T.useEffect)(()=>{ei(G(Q,Y,!1,!0,!1))},[]),(0,n.jsxs)("div",{className:"flex w-full flex-col items-center justify-center gap-x-1.5","data-sentry-component":"InferenceSearcher","data-sentry-source-file":"inference-searcher.tsx",children:[(0,n.jsxs)("div",{className:"".concat(z===l.Cs.LOADED?"pt-0":"mt-0"," flex w-full flex-col items-start justify-center transition-all sm:max-w-screen-lg"),children:[(0,n.jsx)("div",{className:"flex flex-col items-center justify-center",children:(0,n.jsxs)("div",{className:"mb-2 flex w-auto flex-row items-center justify-center gap-x-2 text-center font-sans text-xs font-medium uppercase leading-none text-slate-500",children:[V&&(0,n.jsx)("div",{className:"flex flex-col font-mono",children:(0,n.jsx)(s.A,{modelId:Q,modelIdChangedCallback:e=>{K(e);
1let t=(0,u.gC)(W[e],p.Visibility.PUBLIC,!0,!1);t?($(t.name),ei(G(e,t.name,!1,!0,!1))):($(d.id),ei([])),X([])},filterToInferenceEnabled:!0,filterToRelease:M})}),L&&(0,n.jsx)(i.A,{modelId:Q,sourceSet:Y,filterToOnlyVisible:!0,sourceSetChangedCallback:e=>{$(e),ei(G(Q,e,!1,!0,!1)),X([])},filterToRelease:M,filterToInferenceEnabled:!0,filterToAllowInferenceSearch:!0}),(0,n.jsx)("div",{className:"flex flex-col",children:(0,n.jsxs)(f.bL,{"data-sentry-element":"DropdownMenu.Root","data-sentry-source-file":"inference-searcher.tsx",children:[(0,n.jsxs)(f.l9,{className:"flex h-10 max-h-[40px] min-h-[40px] w-full flex-1 flex-row items-center justify-center gap-x-1 whitespace-pre rounded border border-slate-300 bg-white px-2 font-mono text-[10px] font-medium leading-tight text-sky-700 hover:bg-slate-50 sm:pl-4 sm:pr-2 sm:text-xs","data-sentry-element":"DropdownMenu.Trigger","data-sentry-source-file":"inference-searcher.tsx",children:[Z?(null==Z?void 0:Z.length)===0?"All Layers":"Layer".concat(Z.length>1?"s ":" ").concat(Z.map(e=>(0,u.cF)(e)+((0,u.fm)(e).length>0?" ".concat((0,u.fm)(e)):"")).join(", ")):"No Layers Selected",(0,n.jsx)(g.In,{"data-sentry-element":"Select.Icon","data-sentry-source-file":"inference-searcher.tsx",children:(0,n.jsx)(v.A,{className:"-mr-1 ml-0 w-4 leading-none","data-sentry-element":"ChevronDownIcon","data-sentry-source-file":"inference-searcher.tsx"})})]}),(0,n.jsx)(f.ZL,{"data-sentry-element":"DropdownMenu.Portal","data-sentry-source-file":"inference-searcher.tsx",children:(0,n.jsxs)(f.UC,{className:"z-30 max-h-[305px] cursor-pointer overflow-scroll rounded-md border border-slate-300 bg-white text-[10px] font-medium text-sky-700 shadow",sideOffset:5,"data-sentry-element":"DropdownMenu.Content","data-sentry-source-file":"inference-searcher.tsx",children:[(0,n.jsxs)(f.H_,{className:"flex h-8 min-w-[100px] flex-row items-center overflow-hidden border-b px-3 font-mono text-xs hover:bg-slate-100 focus:outline-none",checked:(null==Z?void 0:Z.length)===0,onSelect:e=>{e.preventDefault(),X([])},"data-sentry-element":"DropdownMenu.CheckboxItem","data-sentry-source-file":"inference-searcher.tsx",children:[(0,n.jsx)("div",{className:"w-7",children:(0,n.jsx)(f.VF,{"data-sentry-element":"DropdownMenu.ItemIndicator","data-sentry-source-file":"inference-searcher.tsx",children:(0,n.jsx)(b.A,{className:"h-4 w-4","data-sentry-element":"Check","data-sentry-source-file":"inference-searcher.tsx"})})}),(0,n.jsx)("div",{className:"flex items-center justify-center leading-none",children:"All Layers"})]}),es.map(e=>(0,n.jsxs)(f.H_,{className:"flex h-8 flex-row items-center overflow-hidden border-b px-3 font-mono text-xs hover:bg-slate-100 focus:outline-none",checked:(null==Z?void 0:Z.indexOf(e))!==-1,onSelect:t=>{t.preventDefault(),(null==Z?void 0:Z.indexOf(e))===-1?X([...Z,e].toSorted()):X(null==Z?void 0:Z.filter(t=>t!==e))},children:[(0,n.jsx)("div",{className:"w-7",children:(0,n.jsx)(f.VF,{children:(0,n.jsx)(b.A,{className:"h-4 w-4"})})}),(0,n.jsxs)("div",{className:"flex items-center justify-center uppercase leading-none",children:[(0,u.cF)(e),(0,u.fm)(e).length>0&&" ".concat((0,u.fm)(e))]})]},e))]})})]})})]})}),(0,n.jsx)("div",{className:"mb-2 flex w-full flex-col items-center justify-center px-0",children:(0,n.jsx)(y.l1,{innerRef:ed,initialValues:{searchQuery:""},onSubmit:()=>{ep()},"data-sentry-element":"Formik","data-sentry-source-file":"inference-searcher.tsx",children:e=>{let{submitForm:t,values:a,setFieldValue:s}=e;return(0,n.jsx)(y.lV,{className:"flex w-full gap-x-1.5 gap-y-1.5 sm:max-w-screen-lg sm:flex-row ".concat(z===l.Cs.LOADED?"flex-row":"flex-col"),children:(0,n.jsxs)("div",{className:"mt-0 flex flex-1 flex-row gap-x-2",children:[(0,n.jsx)(k.A,{name:"searchQuery",disabled:z===l.Cs.RUNNING,value:a.searchQuery,minRows:2,onChange:e=>{ec(!0),J.length>0&&_([]),s("searchQuery",e.target.value)},required:!0,placeholder:"Enter any text or sentence to search (e.g, 'I like cats!')",className:"mt-0 min-w-[10px] flex-1 resize-none rounded-md border border-slate-200 px-3 py-2 text-left font-mono text-xs font-medium text-slate-800 placeholder-slate-400 shadow-sm transition-all focus:border-sky-700 focus:outline-none focus:ring-0 disabled:bg-slate-200 sm:text-[13px]"}),(0,n.jsxs)(c.$,{variant:"default",type:"submit",disabled:0===a.searchQuery.length||z===l.Cs.RUNNING||z===l.Cs.LOADED&&!el,onClick:e=>{e.preventDefault(),t()},className:"group flex h-full min-w-[48px] flex-col items-center justify-center gap-y-1 overflow-hidden font-bold uppercase transition-all sm:min-w-[54px] sm:max-w-[70px] sm:text-xs",children:[(0,n.jsx)(w.A,{className:"h-5 w-5"}),(0,n.jsx)("div",{className:"block text-[9px] font-medium uppercase leading-none sm:w-24 sm:px-2",children:"SEARCH"})]})]})})}})})]}),z===l.Cs.DEFAULT&&(0,n.jsx)("div",{className:"mt-4 flex w-full max-w-screen-lg flex-col px-0 sm:mt-4",children:O&&(0,n.jsx)(S,{makeUrl:em})}),z===l.Cs.RUNNING&&(0,n.jsx)("div",{children:(0,n.jsx)(o.A,{showBackgroun
1d:!1})}),z===l.Cs.LOADED&&(0,n.jsxs)("div",{className:"flex w-full flex-col overscroll-contain bg-white",children:[(0,n.jsxs)("div",{className:"mb-3 mt-0 flex w-full flex-col items-start justify-center overflow-x-hidden border-b px-0 pb-3 pt-0",children:[(0,n.jsxs)("div",{className:"mb-2 flex w-full max-w-sm flex-row gap-x-0.5 px-0 leading-tight sm:max-w-screen-lg sm:gap-x-2 sm:leading-normal",children:[(0,n.jsxs)("button",{type:"button",onClick:()=>{alert("Click a token to sort results by highest activations for that token.")},className:"flex w-16 flex-row items-center justify-center rounded border border-slate-300 bg-slate-300 px-2 py-1 text-center text-[11px] text-slate-600 hover:bg-white sm:w-36",children:["How To ",(0,n.jsx)("div",{className:"ml-0.5 hidden sm:block",children:" Use"}),(0,n.jsx)(j.A,{className:"ml-1 hidden h-3 w-3 sm:block"})]}),(0,n.jsxs)(x.bL,{className:"inline-flex flex-1 overflow-hidden rounded border border-slate-300 bg-slate-300 px-0 py-0 sm:rounded",type:"single",defaultValue:eo?"showDashboards":"hideDashboards",value:eo?"showDashboards":"hideDashboards",onValueChange:e=>{er("showDashboards"===e)},"aria-label":"show dashboards or not",children:[(0,n.jsx)(x.q7,{className:"flex-auto items-center rounded-l px-1 py-1 text-[10px] font-medium text-slate-500 transition-all hover:bg-slate-100 data-[state=on]:bg-white data-[state=on]:text-slate-600 sm:px-4 sm:text-[11px]",value:"showDashboards","aria-label":"showDashboards",children:"Show Dashboards"},"showDashboards"),(0,n.jsx)(x.q7,{className:"flex-auto items-center rounded-r px-1 py-1 text-[10px] font-medium text-slate-500 transition-all hover:bg-slate-100 data-[state=on]:bg-white data-[state=on]:text-slate-600 sm:px-4 sm:text-[11px]",value:"hideDashboards","aria-label":"hideDashboards",children:"Hide Dashboards"},"hideDashboards")]}),(0,n.jsxs)(x.bL,{className:"inline-flex flex-1 overflow-hidden rounded border border-slate-300 bg-slate-300 px-0 py-0 sm:rounded",type:"single",defaultValue:ea?"hide":"show",value:ea?"hide":"show",onValueChange:e=>{en("hide"===e)},"aria-label":"Show results where activation density is > 1%",children:[(0,n.jsx)(x.q7,{className:"flex-auto items-center rounded-l px-1 py-1 text-[10px] font-medium text-slate-500 transition-all hover:bg-slate-100 data-[state=on]:bg-white data-[state=on]:text-slate-600 sm:px-4 sm:text-[11px]",value:"show","aria-label":"show",children:"Show >1% Density"},"show"),(0,n.jsx)(x.q7,{className:"flex-auto items-center rounded-r px-1 py-1 text-[10px] font-medium text-slate-500 transition-all hover:bg-slate-100 data-[state=on]:bg-white data-[state=on]:text-slate-600 sm:px-4 sm:text-[11px]",value:"hide","aria-label":"hide",children:"Hide >1% Density"},"hide")]}),(0,n.jsxs)(x.bL,{className:"inline-flex flex-1 overflow-hidden rounded border border-slate-300 bg-slate-300 px-0 py-0 sm:rounded",type:"single",defaultValue:ee?"ignore":"show",value:ee?"ignore":"show",onValueChange:e=>{et("ignore"===e)},"aria-label":"Show results where the max token was the BOS token",children:[(0,n.jsx)(x.q7,{className:"flex-auto items-center rounded-l px-1 py-1 text-[10px] font-medium text-slate-500 transition-all hover:bg-slate-100 data-[state=on]:bg-white data-[state=on]:text-slate-600 sm:px-4 sm:text-[11px]",value:"show","aria-label":"show",children:"Show BOS Results"},"show"),(0,n.jsx)(x.q7,{className:"flex-auto items-center rounded-r px-1 py-1 text-[10px] font-medium text-slate-500 transition-all hover:bg-slate-100 data-[state=on]:bg-white data-[state=on]:text-slate-600 sm:px-4 sm:text-[11px]",value:"ignore","aria-label":"ignore",children:"Ignore BOS Results"},"ignore")]})]}),(0,n.jsx)("div",{className:"sticky left-0.5 top-0 mb-1 mt-2 hidden w-full text-left font-sans text-[11px] font-medium text-slate-400 sm:block",children:"Select tokens below to sort results by highest activations for those tokens."}),(0,n.jsx)("div",{className:"forceShowScrollBarHorizontal my-0 flex w-full max-w-sm flex-col overflow-x-scroll pb-1 font-mono sm:max-w-[calc(1024px-50px)]",children:(0,n.jsxs)("div",{className:"flex flex-row items-center gap-x-0.5",children:[(0,n.jsx)("button",{type:"button",className:"flex w-20 min-w-20 cursor-pointer items-center justify-center whitespace-nowrap rounded ".concat(J.length===q.length?"bg-emerald-700 text-white hover:bg-emerald-600":"bg-slate-100 text-slate-500 hover:bg-emerald-100"," select-none py-1.5 text-[9px] font-bold uppercase leading-none shadow outline-none"),onClick:()=>{J.length<q.length?_(Array.from(Array(q.length).keys())):_([])},children:"ALL TOKENS"}),q.map((e,t)=>(0,n.jsx)("div",{className:"px-[1px] text-center leading-none",children:(0,n.jsx)("button",{type:"button",onClick:()=>{-1!==J.indexOf(t)?_(J.filter(e=>e!==t).toSorted()):_([...J,t].toSorted())},className:"flex-1 cursor-pointer whitespace-pre rounded border px-[2px] py-0.5 font-mono text-[12px] font-medium leading-none hover:border-emerald-600 ".concat(-1!==J.indexOf(t)?"border-emerald-600 bg-emerald-600 text-white":"border-slate-300 text-slate-600"),children:(0,h.Bn)(e)})},t))]})})]}),(0,n.jsxs)("div",{className:"mx-auto flex w-full flex-col items-center overscroll-contain bg-white",children:[z===l.Cs.LOADED&&el&&(0,n.jsxs)("div",{className:"flex w-full flex-row items-center justify-center gap-x-3 bg-slate-200 py-2 text-[13px] text-slate-600",children:["Search parameters changed."," ",(0,n.jsx)("button",{type:"button",className:"rounded-md bg-sky-700 px-3 py-2 text-[10px] font-medium uppercase leading-none text-white transition-all hover:bg-sky-900",onClick:()=>{ep()},children:"Reload Search"})]}),P.filter(e=>{var t;return!ea||!e.neuron||!((null==(t=e.neuron)?void 0:t.frac_nonzero)>.01)}).map(e=>{var t,a;let s=(null==(t=e.neuron)?void 0:t.explanations)?null==(a=e.neuron)?void 0:a.explanations[0]:void 0;return(0,n.jsx)(D,{result:e,tokens:q,topExplanation:s,searchSortIndexes:H,showDashboards:eo},e.index)})]})]})]})}},58391:(e,t,a)=>{a.d(t,{C:()=>n,K:()=>s});let n=[{type:"\uD83C\uDF2E Food",examples:["The chocolate lava cake at La Petite Boulangerie is a delight, oozing with rich, molten chocolate as soon as you break into its perfectly baked exterior.","Avocado toast, a simple yet trendy breakfast option, gains a delightful twist with a sprinkle of chili flakes and a drizzle of honey for that perfect balance of spicy and sweet.","Chef Ramirez's signature dish, a fusion of Thai and Mexican cuisine, features spicy green curry enchiladas, tantalizing the taste buds with a bold, innovative flavor combination.","Did you know that pineapples were a symbol of hospital
1ity in colonial America? This exotic fruit, once a rare delicacy, was often displayed at gatherings to impress guests.","The Farmers' Market Salad at Green Acres Caf\xe9, with its fresh, locally-sourced ingredients and homemade vinaigrette, is a true celebration of seasonal flavors.","A culinary secret: soaking chicken in buttermilk for at least an hour before frying ensures a juicy, tender inside and a perfectly crispy exterior.","At Tokyo's Sushi Zen, the chef's mastery is evident in the simple yet sublime salmon nigiri, where the freshness of the fish is the star of the show.","In the heart of Tuscany, a family-owned vineyard pairs its robust Chianti with a hearty wild boar rag\xf9, creating an unforgettable taste of Italian countryside cuisine.","Exploring the streets of Bangkok, one must try the street vendor's mango sticky rice, a delightful dessert that perfectly balances sweet and savory with creamy coconut milk.","The humble potato, a staple in diets around the world, was once considered so strange and feared in Europe that it was initially used only as animal feed and decoration."]},{type:"\uD83D\uDCF0 News",examples:["In a landmark decision, the Supreme Court has ruled in favor of expanding environmental protections, setting a new legal standard for future legislation and sparking nationwide discussions on environmental policy.","The recent volcanic eruption has caused significant disruptions, prompting urgent evacuations and international aid efforts. Scientists warn of potential long-term ecological and economic impacts.","In an exclusive interview, the newly elected mayor shares her vision for the city's future, focusing on sustainable development, public transportation improvements, and increased affordable housing.","The tech industry faces a major shift as the leading company announces significant layoffs amidst economic downturns. Analysts predict this could have a ripple effect across the global market.","A groundbreaking medical study reveals a potential cure for a rare disease, offering hope to thousands of patients worldwide. The discovery marks a significant milestone in medical research and treatment.","The international sports event concluded with a stunning victory, shattering records and capturing the hearts of fans around the world. The event highlighted the power of sports in uniting diverse cultures.","A major cybersecurity breach has compromised millions of users' data, raising questions about digital security and privacy in the age of information. Experts urge stronger safeguards and consumer awareness.","The art world is abuzz as a long-lost masterpiece is discovered, shedding new light on the artist's work and era. This discovery has sparked renewed interest in the history and value of classic art.","Amidst economic challenges, the government unveils a stimulus package aimed at boosting growth and supporting vulnerable sectors. The plan includes tax relief, small business support, and infrastructure projects.","The festival celebrated cultural diversity through music, dance, and food, drawing thousands of attendees and promoting cross-cultural understanding. It showcased the rich tapestry of traditions in our global society."]},{type:"\uD83D\uDCD6 Literary",examples:["In 'Pride and Prejudice', Elizabeth Bennet's sharp wit and independent spirit challenge the social norms of her time, as she navigates the complexities of love, family, and societal expectations in early 19th-century England.","The narrative of 'Moby-Dick' delves deep into the human psyche through Captain Ahab's obsessive quest for the white whale, symbolizing the eternal struggle between man and nature, and man's pursuit of the unattainable.","'To Kill a Mockingbird' by Harper Lee poignantly addresses themes of racial injustice and moral growth, as seen through the eyes of young Scout Finch, in a small Southern town during the Great Depression.","F. Scott Fitzgerald's 'The Great Gatsby' elegantly captures the disillusionment of the American Dream in the Roaring Twenties, through the tragic story of Jay Gatsby and his unrequited love for Daisy Buchanan.","George Orwell's '1984' presents a chilling dystopian world where government surveillance and public manipulation create a society marked by fear, conformity, and the loss of individuality.","In 'The Catcher in the Rye', J.D. Salinger portrays the complexities of teenage angst and rebellion through the eyes of Holden Caulfield, as he navigates the challenges of adulthood and identity.","'Hamlet' by William Shakespeare masterfully explores themes of betrayal, revenge, and madness, as Prince Hamlet is consumed by the need to avenge his father's murder in a corrupt and decaying kingdom.","Leo Tolstoy's 'War and Peace' offers a sweeping narrative that intertwines the lives of its characters with the tumultuous events of the Napoleonic Wars, reflecting on the broader human experiences of love, loss, and destiny.","In 'The Odyssey', Homer takes us on an epic journey with Odysseus, whose adventures and trials on his way back to Ithaca after the Trojan War offer timeless insights into the human condition and the quest for home.","Charles Dickens' 'Great Expectations' skillfully weaves a tale of personal growth and societal critique, as young Pip's journey from humble beginnings to the complexities of London society reveals the illusions of wealth and class."]},{type:"\uD83D\uDC6F Personal",examples:["Hey there! Just wanted to check in and see how you're doing. It's been a while since we last caught up. Hope everything is going well with you. Are you still at the same job, or have you moved on to something new?","Can't believe it's already been a year since our last trip! Time flies. We should definitely plan another getaway soon. What do you think? Maybe something tropical or perhaps a city break somewhere we've never been?","Happy Birthday! Hope your day is filled with lots of love, laughter, and cake. Wishing you all the best on your special day. Let's get together so
1on for a proper celebration with all our friends!","I'm so proud of you and everything you've achieved this year. You've worked so hard, and it's great to see your efforts paying off. Keep chasing your dreams - you're doing amazing!","Just saw the funniest meme and thought of you. It reminded me of that time we... [continues with a personal anecdote]... Do you remember how hard we laughed back then? Good times!","OMG, did you see the latest episode of our favorite show? Can't believe that twist at the end! I need to know what happens next. Let's watch the next one together and have a movie night.","Had the most amazing coffee this morning at that new cafe downtown. You'd love it. Let's catch up there soon! It has this cozy vibe and the pastries are to die for. What do you say?","Remember how we used to dream about traveling the world? Let's start planning our next adventure. We could make a list of all the places we want to visit and start ticking them off.","Feeling so grateful for our friendship. You've been there for me through thick and thin. Thank you for everything. Can't imagine what I would do without you.","Was just reminiscing about our college days. We've come so far since then. Let's plan a reunion soon! It would be amazing to catch up with everyone and see where life has taken us all."]},{type:"\uD83E\uDDD1â\uD83D\uDCBB Programming",examples:["function calculateSum(a, b) { return a + b; } // A simple function to add two numbers. It takes two parameters and returns their sum, which is a fundamental operation in programming.","let user = { name: 'Alice', age: 25 }; // Creating an object in JavaScript. This is a basic example of object creation, where 'user' is an object with properties 'name' and 'age'.","#include <iostream> using namespace std; int main() { cout << 'Hello, world!'; return 0; } // Basic C++ program. This is a classic example of a beginner's program in C++.","SELECT * FROM users WHERE age > 18; // SQL query to select users over 18 years old. This is a simple database query to retrieve information from a table based on a condition.","if (temperature > 100) { alert('High temperature!'); } // Conditional statement in JavaScript. This code checks if the temperature exceeds 100 and displays a warning if it does.","for (int i = 0; i < 10; i++) { console.log(i); } // Looping in JavaScript. This loop prints numbers from 0 to 9, demonstrating a basic for loop structure.","class Car { constructor(brand) { this.carname = brand; } } // Class definition in JavaScript. This snippet defines a class 'Car' with a constructor that assigns a brand name to each instance.","<div class='container'>Hello World!</div> // Basic HTML structure. This is an example of a simple HTML element with a class, often used in web development.","Array.prototype.map = function(callback) { // ... }; // Extending an array in JavaScript. This method creates a new array populated with the results of calling a provided function on every element.","document.getElementById('myElement').style.display = 'none'; // Manipulating DOM in JavaScript. This line of code selects an HTML element and changes its display style, often used in web interactivity."]},{type:"\uD83E\uDDD1â\uD83D\uDD2C Technical",examples:["This user manual provides step-by-step instructions for operating the device, including safety precautions, troubleshooting tips, and maintenance guidelines. It is essential for ensuring proper use and longevity.","Our feasibility study assesses the viability of the proposed project, analyzing market trends, financial projections, and potential risks. This comprehensive evaluation is crucial for informed decision-making.","The research paper explores the effects of climate change on marine ecosystems, presenting data collected over a decade. It contributes valuable insights to the ongoing discourse on environmental conservation.","This technical report outlines the results of the engineering assessment, detailing structural integrity, design considerations, and recommendations for improvements to meet industry standards.","The policy brief highlights key issues in urban transportation planning, offering evidence-based recommendations for reducing traffic congestion and improving public transit systems in metropolitan areas.","Our white paper discusses the emerging trends in renewable energy technology, examining the potential impact on global energy markets and sustainability goals. It serves as a resource for policymakers and industry leaders.","This project proposal outlines the objectives, scope, timeline, and budget for the new initiative. It serves as a roadmap for execution and is essential for securing stakeholder approval and funding.","The compliance report verifies adherence to regulatory standards, documenting audits, inspections, and corrective actions taken. It is vital for maintaining legal and ethical practices within the organization.","Our training manual provides comprehensive guidance for new employees, covering company policies, job responsibilities, and professional development opportunities. It is a key tool for onboarding and staff development.","The annual report summarizes the company's performance over the past year, including financial highlights, achievements, and future goals. It provides transparency and accountability to stakeholders."]},{type:"\uD83E\uDDD1â\uD83C\uDFEB Academic",examples:["The study explores the implications of quantum computing on current encryption methods, highlighting the potential for both advancements in computing power and challenges in cybersecurity. The paper argues that quantum computing will necessitate a paradigm shift in data protection.","This article examines the social impacts of the gig economy, particularly focusing on the changing nature of employment and worker rights. It draws on case studies and statistical analysis to argue for policy reform in labor laws.","In exploring the relationship between climate change and urban planning, the research identifies key strategies for sustainable development. It underscores the urgency of integrating environmental considerations into city planning.","The thesis presents an analysis of Shakespeare's use of irony in 'Macbeth', exploring how it contributes to the play's themes of ambition and fate. The study offers a new perspective on the interpretation of these literary elements.","This dissertation investigates the historical context of the French Revolution, providing a nuanced understanding of the political, social, and economic factors that led to this pivotal event in European history.","The journal article delves into the advancements in gene editing technology, specifically CRISPR-Cas9, and its ethical impl
1ications. It discusses the potential applications in medicine and the moral considerations involved.","Exploring the concept of artificial intelligence in the workplace, this paper examines its impact on productivity and employee dynamics. It provides a comprehensive overview of AI integration in various industries.","The research on renewable energy technologies assesses their viability as sustainable alternatives to fossil fuels. The study provides a critical analysis of solar, wind, and hydroelectric power in the context of global energy needs.","This scholarly article analyzes the role of social media in modern political discourse, examining its influence on public opinion and election outcomes. It presents a detailed study of social media trends and voter behavior.","Focusing on the cultural significance of mythology in ancient civilizations, the paper explores how myths shaped societal norms, religious beliefs, and artistic expressions. It draws comparisons across various cultures to highlight common themes and differences."]},{type:"\uD83D\uDCBC Business",examples:["Our quarterly sales report indicates a significant increase in revenue, suggesting our new marketing strategies are paying off. Continued investment in digital advertising is recommended to maintain this growth trajectory.","The strategic merger between the two leading tech companies will create a synergy that promises to revolutionize the industry. This collaboration is expected to yield innovative products and enhanced services.","Effective immediately, all employees are encouraged to participate in our new remote work program. This initiative aims to improve work-life balance and enhance productivity across all departments.","Our customer satisfaction scores have improved by 15% this quarter, a testament to our team's dedication to providing exceptional service. Ongoing training and development will ensure we continue this positive trend.","The launch of our latest product line exceeded expectations, with initial sales surpassing projections by 25%. This success underscores the importance of our customer-focused approach in product development.","To stay competitive in the global market, our company will be investing in cutting-edge technology to streamline operations. This technological advancement will position us at the forefront of industry innovation.","Our comprehensive marketing plan for the upcoming year focuses on expanding our digital presence and engaging with younger demographics through social media platforms and influencer partnerships.","In response to recent market fluctuations, we are adjusting our investment strategies to prioritize long-term stability and sustainable growth. This shift will better align with our overall financial goals.","The annual shareholders' meeting will discuss the company's performance, future strategies, and the appointment of new board members. Shareholder engagement and input are crucial for our continued success.","Our new sustainability initiative aims to reduce the company's carbon footprint by 30% over the next five years. This commitment to environmental responsibility will also enhance our brand reputation."]},{type:"\uD83E\uDDD1ââï¸ Legal",examples:["This agreement, entered into on this day, establishes the terms and conditions of the partnership between the parties. It outlines the responsibilities, profit-sharing ratios, and dispute resolution mechanisms.","The proposed legislation aims to enhance public health safety by implementing stricter regulations on food labeling and quality control. Public comments on the bill are encouraged and will be considered.","This court ruling sets a precedent in corporate law, emphasizing the importance of ethical business practices and accountability in financial dealings. The decision underscores the need for transparent corporate governance.","The new zoning laws will affect residential and commercial development, aiming to balance urban growth with environmental conservation. These regulations are part of the city's long-term urban planning strategy.","Under the terms of this contract, the service provider agrees to deliver the specified services within the agreed-upon timeframe. Failure to comply will result in penalties as outlined in the agreement.","This patent grants the inventor exclusive rights to the use, production, and sale of the invention for a period of twenty years, fostering innovation and protecting intellectual property rights.","The privacy policy has been updated to comply with new data protection regulations. It outlines how personal data is collected, used, and safeguarded, reflecting our commitment to user privacy.","This ordinance prohibits parking in designated areas during specific hours to facilitate street cleaning and maintenance. Violations will result in fines and possible towing at the vehicle owner's expense.","The government's budget proposal allocates funds for public infrastru
1cture projects, education, healthcare, and national defense. It reflects priorities for the fiscal year and aims to address key societal needs.","This employment agreement outlines the terms of employment, including job responsibilities, salary, benefits, and conditions for termination. It serves as a binding legal document between the employer and employee."]},{type:"\uD83E\uDDD1â\uD83C\uDFEB Educational",examples:["To solve a quadratic equation, use the formula: x = (-b \xb1 â(b\xb2-4ac)) / 2a. This formula is derived from the general form ax\xb2 + bx + c = 0 and is fundamental in algebra.","Photosynthesis is the process by which green plants and some other organisms use sunlight to synthesize foods from carbon dioxide and water. This process is crucial for life on Earth.","The French Revolution, beginning in 1789, was a period of radical social and political upheaval in France that had a lasting impact on French history and fundamentally transformed French society.","In economics, supply and demand is a model for understanding how prices and quantities are determined in a market system. This concept is foundational in economic theory and affects various market structures.","The human circulatory system consists of the heart, blood vessels, and blood, and is responsible for transporting nutrients and oxygen to the body cells. This system is vital for maintaining life and health.","Mitosis is a process of cell division that results in two genetically identical daughter cells developing from a single parent cell. This process is key to growth and tissue repair in multicellular organisms.","The Pythagorean theorem states that in a right triangle, the square of the length of the hypotenuse is equal to the sum of the squares of the other two sides. This theorem is a cornerstone of geometry.","During the Industrial Revolution, there was a major shift from manual labor and agrarian economies to industrial and machine manufacturing processes. This period marked a significant change in history.","In literature, a metaphor is a figure of speech that describes an object or action in a way that isnât literally true, but helps explain an idea or make a comparison. Metaphors enrich language and thought.","The water cycle describes the continuous movement of water on, above, and below the surface of the Earth, involving processes such as evaporation, condensation, and precipitation. This cycle is vital for life."]},{type:"\uD83D\uDDFC Cultural",examples:["The Declaration of Independence, adopted on July 4, 1776, stated that the thirteen American colonies were free and independent states. This document is a pivotal moment in American history.","'All men are created equal, that they are endowed by their Creator with certain unalienable Rights.' - from the United States Declaration of Independence. This line is a cornerstone of American democracy.","In his 'I Have a Dream' speech, Martin Luther King Jr. envisioned a future where people would be judged by their character, not the color of their skin. This speech is iconic in the civil rights movement.","The Magna Carta, signed in 1215, was a significant early step in the process of constitutional development in England. It laid the groundwork for the development of parliamentary democracy.","'To be, or not to be, that is the question.' - from Shakespeare's Hamlet, reflecting on life and death. This famous line explores the essence of human existence and philosophical thought.","The Rosetta Stone, discovered in 1799, was crucial in deciphering Egyptian hieroglyphs, a script made up of small pictures. This discovery opened a window into ancient Egyptian civilization.","The Emancipation Proclamation, issued by Abraham Lincoln in 1863, declared that all slaves in Confederate states were to be set free. This was a turning point in the American Civil War.","The Code of Hammurabi is one of the oldest deciphered writings of significant length in the world, dating back to 1754 BC in ancient Mesopotamia. It is a cornerstone of ancient law and governance.","The Treaty of Versailles, signed in 1919, ended the state of war between Germany and the Allied Powers after World War I. It reshaped the map of Europe and had lasting geopolitical consequences.","'Give me liberty, or give me death!' - a famous quotation attributed to Patrick Henry from a speech he made to the Second Virginia Convention in 1775. This phrase became a rallying cry for American independence."]}],s=n.map(e=>e.examples).flat()},99660:(e,t,a)=>{a.d(t,{Cs:()=>r,TT:()=>c,default:()=>d});var n=a(95155),s=a(12115),i=a(18695),o=a(26654),r=function(e){return e[e.DEFAULT=0]="DEFAULT",e[e.RUNNING=1]="RUNNING",e[e.LOADED=2]="LOADED",e}({});let[l,c]=(0,o.A)("InferenceActivationAllContext");function d(e){let{children:t}=e,{showToastServerError:a,showToastMessage:o}
1=(0,i.SF)(),[r,c]=(0,s.useState)(0),[d,h]=(0,s.useState)([]),[u,m]=(0,s.useState)([]),[p,f]=(0,s.useState)([]),[g,x]=(0,s.useState)(-10),[y,v]=(0,s.useState)([]);async function b(e,t,n,s,i){let r=arguments.length>5&&void 0!==arguments[5]?arguments[5]:[];if(!n)return void alert("Please select at least one layer to search.");c(1);try{let l=await fetch("/api/search-all",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({modelId:e,text:t,selectedLayers:n,sortIndexes:r,sourceSet:s,ignoreBos:i})}),d=await l.json().catch(()=>void 0);if(!l.ok||!Array.isArray(null==d?void 0:d.tokens)||!Array.isArray(null==d?void 0:d.result)){let e=l.status>=400&&l.status<500?(null==d?void 0:d.message)||(null==d?void 0:d.error):void 0;e?o(e):a(),c(0);return}h(d.result),m(d.sortIndexes||[]),v(d.tokens),c(2)}catch(e){a(),c(0)}}return(0,s.useEffect)(()=>{if(d.length>0){let e=-10;d.forEach(t=>{t.maxValue>e&&(e=t.maxValue)}),x(e)}},[d]),(0,n.jsx)(l.Provider,{value:(0,s.useMemo)(()=>({exploreState:r,setExploreState:c,submitSearchAll:b,tokens:y,setTokens:v,searchResults:d,overallMaxValue:g,setSearchResults:h,searchSortIndexes:u,resultsGrid:p,setResultsGrid:f}),[r,b,y,d,g,u,p]),"data-sentry-element":"InferenceActivationAllContext.Provider","data-sentry-component":"InferenceActivationAllProvider","data-sentry-source-file":"inference-activation-all-provider.tsx",children:t})}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.