SYMBOL INDEX (589 symbols across 187 files) FILE: scripts/config.ts function clear (line 40) | async function clear() { function add (line 45) | async function add(key: string, value: string) { function remove (line 54) | async function remove(key: string) { FILE: scripts/populate.ts function generateMessages (line 43) | async function generateMessages(preprompt?: string): Promise { function seed (line 121) | async function seed() { FILE: scripts/updateLocalEnv.ts constant PUBLIC_CONFIG (line 10) | let PUBLIC_CONFIG = ""; constant SECRET_CONFIG (line 29) | const SECRET_CONFIG = FILE: src/app.d.ts type Locals (line 11) | interface Locals { type Error (line 20) | interface Error { FILE: src/lib/APIClient.ts type FetchFn (line 21) | type FetchFn = typeof globalThis.fetch; type ApiResponse (line 23) | interface ApiResponse { function apiCall (line 29) | async function apiCall( function endpoint (line 71) | function endpoint(fetcher: FetchFn, baseUrl: string) { function useAPIClient (line 88) | function useAPIClient({ function handleResponse (line 136) | function handleResponse(response: ApiResponse): any { FILE: src/lib/actions/clickOutside.ts function clickOutside (line 1) | function clickOutside(element: HTMLElement, callbackFunction: () => void) { FILE: src/lib/actions/snapScrollToBottom.ts constant BOTTOM_THRESHOLD (line 5) | const BOTTOM_THRESHOLD = 50; constant USER_SCROLL_DEBOUNCE_MS (line 6) | const USER_SCROLL_DEBOUNCE_MS = 150; constant PROGRAMMATIC_SCROLL_GRACE_MS (line 7) | const PROGRAMMATIC_SCROLL_GRACE_MS = 100; constant TOUCH_DETACH_THRESHOLD_PX (line 8) | const TOUCH_DETACH_THRESHOLD_PX = 10; type ScrollDependency (line 10) | interface ScrollDependency { type MaybeScrollDependency (line 15) | type MaybeScrollDependency = ScrollDependency | unknown; function updateScroll (line 205) | async function updateScroll(newDependency?: MaybeScrollDependency) { FILE: src/lib/buildPrompt.ts type buildPromptOptions (line 4) | type buildPromptOptions = Pick { FILE: src/lib/jobs/refresh-conversation-stats.ts function getLastComputationTime (line 8) | async function getLastComputationTime(): Promise { function shouldComputeStats (line 13) | async function shouldComputeStats(): Promise { function computeAllStats (line 19) | async function computeAllStats() { function computeStats (line 33) | async function computeStats(params: { function maintainLock (line 268) | async function maintainLock() { function refreshConversationStats (line 283) | function refreshConversationStats() { FILE: src/lib/migrations/lock.ts function acquireLock (line 8) | async function acquireLock(key: Semaphores | string): Promise { function refreshLock (line 41) | async function refreshLock(key: Semaphores | string, lockId: ObjectId): ... FILE: src/lib/migrations/migrations.ts function checkAndRunMigrations (line 8) | async function checkAndRunMigrations() { FILE: src/lib/migrations/routines/04-update-message-updates.ts type FinalAnswer (line 15) | type FinalAnswer = { type TextStreamUpdate (line 20) | type TextStreamUpdate = { type WebSearchUpdate (line 25) | type WebSearchUpdate = { type StatusUpdate (line 33) | type StatusUpdate = { type ErrorUpdate (line 39) | type ErrorUpdate = { type FileUpdate (line 45) | type FileUpdate = { type OldMessageUpdate (line 50) | type OldMessageUpdate = function convertMessageUpdate (line 59) | function convertMessageUpdate(message: Message, update: OldMessageUpdate... FILE: src/lib/migrations/routines/06-trim-message-updates.ts function convertMessageUpdate (line 12) | function convertMessageUpdate(message: Message, update: unknown): Messag... FILE: src/lib/migrations/routines/09-delete-empty-conversations.spec.ts type Message (line 9) | type Message = Conversation["messages"][number]; FILE: src/lib/migrations/routines/09-delete-empty-conversations.ts constant BATCH_SIZE (line 7) | const BATCH_SIZE = 1000; constant DELETE_THRESHOLD_MS (line 8) | const DELETE_THRESHOLD_MS = 60 * 60 * 1000; function deleteBatch (line 10) | async function deleteBatch(conversations: Collection, ids:... function processCursor (line 16) | async function processCursor( function deleteConversations (line 36) | async function deleteConversations( FILE: src/lib/migrations/routines/index.ts type Migration (line 5) | interface Migration { FILE: src/lib/server/abortRegistry.ts class AbortRegistry (line 7) | class AbortRegistry { method getInstance (line 12) | public static getInstance(): AbortRegistry { method register (line 19) | public register(conversationId: string, controller: AbortController) { method abort (line 36) | public abort(conversationId: string) { method unregister (line 49) | public unregister(conversationId: string, controller: AbortController) { FILE: src/lib/server/abortedGenerations.ts class AbortedGenerations (line 7) | class AbortedGenerations { method constructor (line 12) | private constructor() { method getInstance (line 20) | public static getInstance(): AbortedGenerations { method getAbortTime (line 28) | public getAbortTime(conversationId: string): Date | undefined { method updateList (line 32) | private async updateList() { FILE: src/lib/server/adminToken.ts class AdminTokenManager (line 6) | class AdminTokenManager { method enabled (line 11) | public get enabled() { method isAdmin (line 15) | public isAdmin(sessionId: Session["sessionId"]) { method checkToken (line 20) | public checkToken(token: string, sessionId: Session["sessionId"]) { method removeSession (line 32) | public removeSession(sessionId: Session["sessionId"]) { method displayToken (line 36) | public displayToken() { FILE: src/lib/server/api/__tests__/conversations-id.spec.ts function parseResponse (line 14) | async function parseResponse(res: Response): Promise { function mockUrl (line 18) | function mockUrl(): URL { FILE: src/lib/server/api/__tests__/conversations-message.spec.ts function parseResponse (line 16) | async function parseResponse(res: Response): Promise { function buildMessageTree (line 29) | function buildMessageTree(): { FILE: src/lib/server/api/__tests__/conversations.spec.ts function parseResponse (line 14) | async function parseResponse(res: Response): Promise { function mockUrl (line 18) | function mockUrl(params?: Record): URL { FILE: src/lib/server/api/__tests__/misc.spec.ts function parseResponse (line 8) | async function parseResponse(res: Response): Promise { function mockRequestEvent (line 12) | function mockRequestEvent(locals: App.Locals) { FILE: src/lib/server/api/__tests__/testHelpers.ts function createTestLocals (line 7) | function createTestLocals(overrides?: Partial): App.Locals { function createTestUser (line 17) | async function createTestUser(): Promise<{ function createTestConversation (line 59) | async function createTestConversation( function cleanupTestData (line 78) | async function cleanupTestData() { FILE: src/lib/server/api/__tests__/user-reports.spec.ts function parseResponse (line 9) | async function parseResponse(res: Response): Promise { function mockRequestEvent (line 13) | function mockRequestEvent(locals: App.Locals) { FILE: src/lib/server/api/__tests__/user.spec.ts function parseResponse (line 11) | async function parseResponse(res: Response): Promise { function mockRequestEvent (line 15) | function mockRequestEvent(locals: App.Locals, overrides?: Record { method updateConfig (line 65) | async updateConfig() { method get (line 78) | get(key: ConfigKey): string { method updateSemaphore (line 85) | async updateSemaphore() { method set (line 100) | async set(key: ConfigKey, value: string) { method delete (line 107) | async delete(key: ConfigKey) { method clear (line 114) | async clear() { method getPublicConfig (line 121) | getPublicConfig() { type ExtraConfigKeys (line 154) | type ExtraConfigKeys = type ConfigProxy (line 165) | type ConfigProxy = ConfigManager & { [K in ConfigKey | ExtraConfigKeys]:... method get (line 168) | get(target, prop, receiver) { method set (line 177) | set(target, prop, value, receiver) { FILE: src/lib/server/conversation.ts function createConversationFromShare (line 12) | async function createConversationFromShare( FILE: src/lib/server/database.ts constant CONVERSATION_STATS_COLLECTION (line 27) | const CONVERSATION_STATS_COLLECTION = "conversations.stats"; class Database (line 29) | class Database { method init (line 35) | private async init() { method getInstance (line 87) | public static async getInstance(): Promise { method getClient (line 99) | public getClient(): MongoClient { method getCollections (line 110) | public getCollections() { method initDatabase (line 176) | private initDatabase() { function getCollectionsEarly (line 396) | async function getCollectionsEarly(): Promise< FILE: src/lib/server/endpoints/document.ts type FileProcessorOptions (line 4) | interface FileProcessorOptions { type AsyncDocumentProcessor (line 31) | type AsyncDocumentProcessor = ( function makeDocumentProcessor (line 38) | function makeDocumentProcessor( FILE: src/lib/server/endpoints/endpoints.ts type EndpointMessage (line 13) | type EndpointMessage = Omit; type EndpointParameters (line 16) | interface EndpointParameters { type TextGenerationStreamOutputSimplified (line 28) | type TextGenerationStreamOutputSimplified = TextGenerationStreamOutput & { type Endpoint (line 33) | type Endpoint = ( FILE: src/lib/server/endpoints/images.ts type ImageProcessorOptions (line 6) | interface ImageProcessorOptions { type ImageProcessor (line 13) | type ImageProcessor = (file: MessageF... function createImageProcessorOptionsValidator (line 18) | function createImageProcessorOptionsValidator( type OutputImgFormat (line 92) | type OutputImgFormat = (typeof outputFormats)[number]; function convertImage (line 96) | function convertImage(sharpInst: Sharp, outputMime: string): Sharp { function chooseMimeType (line 126) | function chooseMimeType( type ImageSizeOptions (line 150) | interface ImageSizeOptions { function chooseImageSize (line 160) | function chooseImageSize({ function estimateImageSizeInBytes (line 198) | function estimateImageSizeInBytes(mime: string, width: number, height: n... function resizeImage (line 209) | function resizeImage(sharpInst: Sharp, maxWidth: number, maxHeight: numb... FILE: src/lib/server/endpoints/openai/endpointOai.ts function endpointOai (line 53) | async function endpointOai( FILE: src/lib/server/endpoints/preprocessMessages.ts function preprocessMessages (line 6) | async function preprocessMessages( function downloadFiles (line 16) | async function downloadFiles(messages: Message[], convId: ObjectId): Pro... function injectClipboardFiles (line 26) | async function injectClipboardFiles(messages: EndpointMessage[]) { function stripEmptyInitialSystemMessage (line 48) | function stripEmptyInitialSystemMessage(messages: EndpointMessage[]): En... FILE: src/lib/server/exitHandler.ts type ExitHandler (line 5) | type ExitHandler = () => void | Promise; type ExitHandlerUnsubscribe (line 6) | type ExitHandlerUnsubscribe = () => void; function onExit (line 10) | function onExit(cb: ExitHandler): ExitHandlerUnsubscribe { function runExitHandler (line 18) | async function runExitHandler(handler: ExitHandler): Promise { function initExitHandler (line 24) | function initExitHandler() { FILE: src/lib/server/files/downloadFile.ts function downloadFile (line 7) | async function downloadFile( FILE: src/lib/server/files/uploadFile.ts function uploadFile (line 7) | async function uploadFile(file: File, conv: Conversation): Promise[0]; function handleServerError (line 6) | async function handleServerError({ FILE: src/lib/server/hooks/fetch.ts type HandleFetchInput (line 4) | type HandleFetchInput = Parameters[0]; function handleFetchRequest (line 6) | async function handleFetchRequest({ FILE: src/lib/server/hooks/handle.ts type HandleInput (line 19) | type HandleInput = Parameters[0]; function getClientAddressSafe (line 21) | function getClientAddressSafe(event: RequestEvent): string | undefined { function handleRequest (line 29) | async function handleRequest({ event, resolve }: HandleInput): Promise { FILE: src/lib/server/isURLLocal.ts function assertValidHostname (line 14) | function assertValidHostname(hostname: string): void { function isURLLocal (line 36) | async function isURLLocal(URL: URL): Promise { function isURLStringLocal (line 57) | function isURLStringLocal(url: string) { function isHostLocalhost (line 67) | function isHostLocalhost(host: string): boolean { FILE: src/lib/server/logger.ts method mixin (line 28) | mixin() { FILE: src/lib/server/mcp/clientPool.ts function keyOf (line 8) | function keyOf(server: McpServerConfig) { function getClient (line 16) | async function getClient(server: McpServerConfig, signal?: AbortSignal):... function drainPool (line 54) | async function drainPool() { function evictFromPool (line 63) | function evictFromPool(server: McpServerConfig): Client | undefined { FILE: src/lib/server/mcp/httpClient.ts function isConnectionClosedError (line 5) | function isConnectionClosedError(err: unknown): boolean { type McpServerConfig (line 10) | interface McpServerConfig { constant DEFAULT_TIMEOUT_MS (line 16) | const DEFAULT_TIMEOUT_MS = 120_000; function getMcpToolTimeoutMs (line 18) | function getMcpToolTimeoutMs(): number { type McpToolTextResponse (line 29) | type McpToolTextResponse = { type McpToolProgress (line 37) | type McpToolProgress = { function callMcpTool (line 43) | async function callMcpTool( FILE: src/lib/server/mcp/registry.ts function parseServers (line 9) | function parseServers(raw: string): McpServerConfig[] { function setServers (line 42) | function setServers(raw: string) { function loadMcpServersOnStartup (line 53) | function loadMcpServersOnStartup(): McpServerConfig[] { function refreshMcpServersIfChanged (line 59) | function refreshMcpServersIfChanged(): void { function getMcpServers (line 71) | function getMcpServers(): McpServerConfig[] { FILE: src/lib/server/mcp/tools.ts type OpenAiTool (line 8) | type OpenAiTool = { type McpToolMapping (line 13) | interface McpToolMapping { type CacheEntry (line 19) | interface CacheEntry { constant DEFAULT_TTL_MS (line 26) | const DEFAULT_TTL_MS = 60_000; function sanitizeName (line 33) | function sanitizeName(name: string) { function buildCacheKey (line 37) | function buildCacheKey(servers: McpServerConfig[]): string { type ListedTool (line 57) | type ListedTool = { function listServerTools (line 64) | async function listServerTools( function getOpenAiToolsForMcp (line 106) | async function getOpenAiToolsForMcp( function resetMcpToolsCache (line 194) | function resetMcpToolsCache() { FILE: src/lib/server/metrics.ts type ModelLabel (line 7) | type ModelLabel = "model"; type ToolLabel (line 8) | type ToolLabel = "tool"; type Metrics (line 10) | interface Metrics { class MetricsServer (line 36) | class MetricsServer { method constructor (line 43) | private constructor() { method getInstance (line 58) | public static getInstance(): MetricsServer { method getMetrics (line 65) | public static getMetrics(): Metrics { method isEnabled (line 69) | public static isEnabled(): boolean { method render (line 73) | public async render(): Promise { method createMetrics (line 81) | private createMetrics(): Metrics { method startStandaloneServer (line 210) | private startStandaloneServer() { FILE: src/lib/server/models.ts type Optional (line 10) | type Optional = Pick, K> & Omit; type ModelConfig (line 67) | type ModelConfig = z.infer; type ModelOverride (line 79) | type ModelOverride = z.infer; function getChatPromptRender (line 106) | function getChatPromptRender(_m: ModelConfig): (inputs: ChatTemplateInpu... type InternalProcessedModel (line 146) | type InternalProcessedModel = Awaited> & { type ModelsRefreshSummary (line 168) | type ModelsRefreshSummary = { type ProcessedModel (line 177) | type ProcessedModel = InternalProcessedModel; type BackendModel (line 495) | type BackendModel = Optional< FILE: src/lib/server/requestContext.ts type RequestContext (line 4) | interface RequestContext { function runWithRequestContext (line 18) | function runWithRequestContext( function updateRequestContext (line 36) | function updateRequestContext(updates: Partial(arr: T[], n = DEFAULT_LAST_TURNS) { function toRouterPrompt (line 76) | function toRouterPrompt(messages: EndpointMessage[], routes: Route[]) { function parseRouteName (line 121) | function parseRouteName(text: string): string | undefined { function archSelectRoute (line 136) | async function archSelectRoute( FILE: src/lib/server/router/endpoint.ts constant REASONING_BLOCK_REGEX (line 23) | const REASONING_BLOCK_REGEX = /[\s\S]*?(?:<\/think>|$)/g; constant ROUTER_MULTIMODAL_ROUTE (line 25) | const ROUTER_MULTIMODAL_ROUTE = "multimodal"; function getModels (line 30) | async function getModels(): Promise { class HTTPError (line 41) | class HTTPError extends Error { method constructor (line 42) | constructor( function extractUpstreamError (line 54) | function extractUpstreamError(error: unknown): { message: string; status... function isPolicyError (line 95) | function isPolicyError(statusCode?: number): boolean { function stripReasoningBlocks (line 101) | function stripReasoningBlocks(text: string): string { function stripReasoningFromMessage (line 106) | function stripReasoningFromMessage(message: EndpointMessage): EndpointMe... function makeRouterEndpoint (line 119) | async function makeRouterEndpoint(routerModel: ProcessedModel): Promise<... FILE: src/lib/server/router/multimodal.ts function findConfiguredMultimodalModel (line 9) | function findConfiguredMultimodalModel( function getConfiguredMultimodalModelId (line 23) | function getConfiguredMultimodalModelId( FILE: src/lib/server/router/policy.ts constant ROUTES (line 5) | let ROUTES: Route[] = []; function loadPolicy (line 8) | async function loadPolicy(): Promise { function getRoutes (line 30) | async function getRoutes(): Promise { function resolveRouteModels (line 35) | function resolveRouteModels( FILE: src/lib/server/router/toolsRoute.ts constant ROUTER_TOOLS_ROUTE (line 5) | const ROUTER_TOOLS_ROUTE = "agentic"; type LocalsWithMcp (line 7) | type LocalsWithMcp = App.Locals & { function isRouterToolsBypassEnabled (line 14) | function isRouterToolsBypassEnabled(): boolean { function hasActiveToolsSelection (line 18) | function hasActiveToolsSelection(locals: App.Locals | undefined): boolean { function pickToolsCapableModel (line 31) | function pickToolsCapableModel( FILE: src/lib/server/router/types.ts type Route (line 1) | interface Route { type RouteConfig (line 8) | interface RouteConfig { type RouteSelection (line 13) | interface RouteSelection { constant ROUTER_FAILURE (line 21) | const ROUTER_FAILURE = "arch_router_failure"; FILE: src/lib/server/sendSlack.ts function sendSlack (line 4) | async function sendSlack(text: string) { FILE: src/lib/server/textGeneration/generate.ts type GenerateContext (line 14) | type GenerateContext = Omit & { messa... FILE: src/lib/server/textGeneration/mcp/fileRefs.ts type FileRefPayload (line 3) | type FileRefPayload = { type RefKind (line 9) | type RefKind = { type ResolvedFileRef (line 15) | type ResolvedFileRef = FileRefPayload & { refKind: RefKind }; type FileRefResolver (line 16) | type FileRefResolver = (ref: string) => ResolvedFileRef | undefined; constant IMAGE_REF_KIND (line 18) | const IMAGE_REF_KIND: RefKind = { constant DEFAULT_REF_KINDS (line 24) | const DEFAULT_REF_KINDS: RefKind[] = [IMAGE_REF_KIND]; function buildFileRefResolver (line 33) | function buildFileRefResolver( function buildImageRefResolver (line 75) | function buildImageRefResolver(messages: EndpointMessage[]): FileRefReso... type FieldRule (line 79) | type FieldRule = { constant DEFAULT_FIELD_RULES (line 86) | const DEFAULT_FIELD_RULES: FieldRule[] = [ function attachFileRefsToArgs (line 104) | function attachFileRefsToArgs( FILE: src/lib/server/textGeneration/mcp/routerResolution.ts type RouterResolutionInput (line 16) | interface RouterResolutionInput { type RouterResolutionResult (line 24) | interface RouterResolutionResult { function resolveRouterTarget (line 31) | async function resolveRouterTarget({ FILE: src/lib/server/textGeneration/mcp/runMcpFlow.ts type RunMcpFlowContext (line 32) | type RunMcpFlowContext = Pick< type McpFlowResult (line 38) | type McpFlowResult = "completed" | "not_applicable" | "aborted"; FILE: src/lib/server/textGeneration/mcp/toolInvocation.ts type Primitive (line 18) | type Primitive = string | number | boolean; type ToolRun (line 20) | type ToolRun = { type NormalizedToolCall (line 26) | interface NormalizedToolCall { type ExecuteToolCallsParams (line 32) | interface ExecuteToolCallsParams { type ToolCallExecutionResult (line 47) | interface ToolCallExecutionResult { type ToolExecutionEvent (line 53) | type ToolExecutionEvent = type TaskResult (line 83) | type TaskResult = { function createQueue (line 148) | function createQueue() { FILE: src/lib/server/textGeneration/reasoning.ts function generateSummaryOfReasoning (line 4) | async function generateSummaryOfReasoning( FILE: src/lib/server/textGeneration/title.ts function generateTitle (line 30) | async function generateTitle( FILE: src/lib/server/textGeneration/types.ts type TextGenerationContext (line 7) | interface TextGenerationContext { FILE: src/lib/server/textGeneration/utils/prepareFiles.ts function prepareMessagesWithFiles (line 13) | async function prepareMessagesWithFiles( function prepareFiles (line 44) | async function prepareFiles( FILE: src/lib/server/textGeneration/utils/routing.ts constant ROUTER_REASONING_REGEX (line 3) | const ROUTER_REASONING_REGEX = /[\s\S]*?(?:<\/think>|$)/g; function stripReasoningBlocks (line 5) | function stripReasoningBlocks(text: string): string { function stripReasoningFromMessageForRouting (line 10) | function stripReasoningFromMessageForRouting(message: EndpointMessage): ... FILE: src/lib/server/textGeneration/utils/toolPrompt.ts function buildToolPreprompt (line 3) | function buildToolPreprompt(tools: OpenAiTool[]): string { FILE: src/lib/server/urlSafety.ts constant UNSAFE_IPV4_SUBNETS (line 4) | const UNSAFE_IPV4_SUBNETS = [ function isUnsafeIp (line 13) | function isUnsafeIp(address: string): boolean { function isValidUrl (line 37) | function isValidUrl(urlString: string): boolean { function assertSafeIp (line 63) | function assertSafeIp(address: string, hostname: string): void { FILE: src/lib/stores/backgroundGenerations.svelte.ts type BackgroundGeneration (line 1) | type BackgroundGeneration = { function addBackgroundGeneration (line 8) | function addBackgroundGeneration(entry: BackgroundGeneration) { function removeBackgroundGeneration (line 19) | function removeBackgroundGeneration(id: string) { function clearBackgroundGenerations (line 26) | function clearBackgroundGenerations() { function hasBackgroundGeneration (line 30) | function hasBackgroundGeneration(id: string) { FILE: src/lib/stores/errors.ts constant ERROR_MESSAGES (line 3) | const ERROR_MESSAGES = { FILE: src/lib/stores/mcpServers.ts function toKeyPart (line 14) | function toKeyPart(s: string | undefined): string { constant KEY_PREFIX (line 21) | const KEY_PREFIX = appLabel || baseLabel || "app"; constant STORAGE_KEYS (line 23) | const STORAGE_KEYS = { function loadCustomServers (line 32) | function loadCustomServers(): MCPServer[] { function loadSelectedIds (line 45) | function loadSelectedIds(): Set { function saveCustomServers (line 59) | function saveCustomServers(servers: MCPServer[]) { function saveSelectedIds (line 70) | function saveSelectedIds(ids: Set) { function loadDisabledBaseIds (line 81) | function loadDisabledBaseIds(): Set { function saveDisabledBaseIds (line 94) | function saveDisabledBaseIds(ids: Set) { function refreshMcpServers (line 143) | async function refreshMcpServers() { function toggleServer (line 194) | function toggleServer(id: string) { function disableAllServers (line 221) | function disableAllServers() { function addCustomServer (line 236) | function addCustomServer(server: Omit) { function deleteCustomServer (line 271) | function deleteCustomServer(id: string) { function updateServerStatus (line 289) | function updateServerStatus( function healthCheckServer (line 314) | async function healthCheckServer( FILE: src/lib/stores/settings.ts type SettingsStore (line 9) | type SettingsStore = { type SettingsStoreWritable (line 26) | type SettingsStoreWritable = Writable & { function useSettingsStore (line 35) | function useSettingsStore() { function createSettingsStore (line 39) | function createSettingsStore(initialValue: Omit void; function notify (line 13) | function notify(preference: ThemePreference, isDark: boolean) { function subscribeToTheme (line 19) | function subscribeToTheme(subscriber: ThemeSubscriber) { function setMetaThemeColor (line 35) | function setMetaThemeColor(isDark: boolean) { function applyDarkClass (line 41) | function applyDarkClass(isDark: boolean) { function getThemePreference (line 49) | function getThemePreference(): ThemePreference { function setTheme (line 65) | function setTheme(preference: ThemePreference) { function switchTheme (line 119) | function switchTheme() { FILE: src/lib/types/AbortedGeneration.ts type AbortedGeneration (line 6) | interface AbortedGeneration extends Timestamps { FILE: src/lib/types/Assistant.ts type Assistant (line 6) | interface Assistant extends Timestamps { FILE: src/lib/types/AssistantStats.ts type AssistantStats (line 4) | interface AssistantStats extends Timestamps { FILE: src/lib/types/ConfigKey.ts type ConfigKey (line 1) | interface ConfigKey { FILE: src/lib/types/ConvSidebar.ts type ConvSidebar (line 3) | interface ConvSidebar { FILE: src/lib/types/Conversation.ts type Conversation (line 7) | interface Conversation extends Timestamps { FILE: src/lib/types/ConversationStats.ts type ConversationStats (line 3) | interface ConversationStats extends Timestamps { FILE: src/lib/types/Message.ts type Message (line 6) | type Message = Partial & { type MessageFile (line 36) | type MessageFile = { FILE: src/lib/types/MessageEvent.ts type MessageEvent (line 5) | interface MessageEvent extends Pick { FILE: src/lib/types/MessageUpdate.ts type MessageUpdate (line 4) | type MessageUpdate = type MessageUpdateType (line 14) | enum MessageUpdateType { type MessageUpdateStatus (line 26) | enum MessageUpdateStatus { type MessageStatusUpdate (line 32) | interface MessageStatusUpdate { type MessageTitleUpdate (line 40) | interface MessageTitleUpdate { type MessageStreamUpdate (line 44) | interface MessageStreamUpdate { type MessageToolUpdateType (line 52) | enum MessageToolUpdateType { type MessageToolUpdateBase (line 60) | interface MessageToolUpdateBase { type MessageToolCallUpdate (line 66) | interface MessageToolCallUpdate extends MessageToolUpdateBase) { method init (line 21) | init(publicConfig: Record) { method get (line 25) | get(key: PublicConfigKey) { method getPublicConfig (line 29) | getPublicConfig() { method isHuggingChat (line 33) | get isHuggingChat() { method assetPath (line 37) | get assetPath() { type ConfigProxy (line 46) | type ConfigProxy = PublicConfigManager & { [K in PublicConfigKey]: strin... function getConfigManager (line 48) | function getConfigManager(initialConfig?: Record(arr: T, chunkSize: number):... function range (line 25) | function range(n: number, b?: number): number[] { FILE: src/lib/utils/cookiesAreEnabled.ts function cookiesAreEnabled (line 3) | function cookiesAreEnabled(): boolean { FILE: src/lib/utils/debounce.ts function debounce (line 5) | function debounce( FILE: src/lib/utils/deepestChild.ts function deepestChild (line 1) | function deepestChild(el: HTMLElement): HTMLElement { FILE: src/lib/utils/favicon.ts function getMcpServerFaviconUrl (line 7) | function getMcpServerFaviconUrl(serverUrl: string, size: number = 64): s... FILE: src/lib/utils/fetchJSON.ts function fetchJSON (line 1) | async function fetchJSON( FILE: src/lib/utils/formatUserCount.ts function formatUserCount (line 1) | function formatUserCount(userCount: number): string { FILE: src/lib/utils/generationState.spec.ts function assistantMessage (line 7) | function assistantMessage(overrides: Partial = {}): Message { FILE: src/lib/utils/generationState.ts function isAssistantGenerationTerminal (line 4) | function isAssistantGenerationTerminal(message?: Message): boolean { function isConversationGenerationActive (line 21) | function isConversationGenerationActive(messages: Message[]): boolean { FILE: src/lib/utils/getHref.ts function getHref (line 1) | function getHref( FILE: src/lib/utils/getReturnFromGenerator.ts function getReturnFromGenerator (line 1) | async function getReturnFromGenerator(generator: AsyncGenerator { function setHapticsEnabled (line 25) | function setHapticsEnabled(value: boolean) { function supportsHaptics (line 30) | function supportsHaptics(): boolean { function fire (line 37) | function fire(pattern: string): void { function tap (line 47) | function tap() { function confirm (line 52) | function confirm() { function error (line 57) | function error() { function selection (line 62) | function selection() { function streamStart (line 67) | function streamStart(): void { FILE: src/lib/utils/hashConv.ts function hashConv (line 4) | async function hashConv(conv: Conversation) { FILE: src/lib/utils/hf.ts function isStrictHfMcpLogin (line 3) | function isStrictHfMcpLogin(urlString: string): boolean { FILE: src/lib/utils/isDesktop.ts constant TABLET_VIEWPORT_WIDTH (line 2) | const TABLET_VIEWPORT_WIDTH = 768; function isDesktop (line 4) | function isDesktop(window: Window) { FILE: src/lib/utils/isUrl.ts function isURL (line 1) | function isURL(url: string) { FILE: src/lib/utils/isVirtualKeyboard.ts function isVirtualKeyboard (line 3) | function isVirtualKeyboard(): boolean { FILE: src/lib/utils/loadAttachmentsFromUrls.ts type AttachmentLoadResult (line 4) | interface AttachmentLoadResult { function parseAttachmentUrls (line 13) | function parseAttachmentUrls(searchParams: URLSearchParams): string[] { function extractFilename (line 32) | function extractFilename(url: string, contentDisposition?: string | null... function loadAttachmentsFromUrls (line 69) | async function loadAttachmentsFromUrls( FILE: src/lib/utils/marked.spec.ts function renderHtml (line 4) | function renderHtml(md: string): string { FILE: src/lib/utils/marked.ts type SimpleSource (line 7) | type SimpleSource = { constant VIDEO_EXTENSIONS (line 61) | const VIDEO_EXTENSIONS = /\.(mp4|webm|ogg|mov|m4v)([?#]|$)/i; constant AUDIO_EXTENSIONS (line 62) | const AUDIO_EXTENSIONS = /\.(mp3|wav|m4a|aac|flac)([?#]|$)/i; function isVideoUrl (line 64) | function isVideoUrl(url: string): boolean { function isAudioUrl (line 68) | function isAudioUrl(url: string): boolean { constant MULTIMEDIA_TAGS (line 73) | const MULTIMEDIA_TAGS = new Set(["video", "source", "audio"]); constant MULTIMEDIA_ALLOWED_ATTRS (line 74) | const MULTIMEDIA_ALLOWED_ATTRS = new Set([ constant MULTIMEDIA_BOOLEAN_ATTRS (line 87) | const MULTIMEDIA_BOOLEAN_ATTRS = new Set(["controls", "autoplay", "loop"... constant MULTIMEDIA_URI_ATTRS (line 88) | const MULTIMEDIA_URI_ATTRS = new Set(["src", "poster"]); constant MULTIMEDIA_ALLOWED_URI_PATTERN (line 89) | const MULTIMEDIA_ALLOWED_URI_PATTERN = /^(?!javascript:|data:text\/html)/i; constant MULTIMEDIA_HTML_REGEX (line 90) | const MULTIMEDIA_HTML_REGEX = /<\/?(video|source|audio)\b/i; type HtmlNode (line 92) | type HtmlNode = { type katexBlockToken (line 100) | interface katexBlockToken extends Tokens.Generic { type katexInlineToken (line 107) | interface katexInlineToken extends Tokens.Generic { method start (line 118) | start(src: string): number | undefined { method tokenizer (line 123) | tokenizer(src: string): katexBlockToken | undefined { method renderer (line 153) | renderer(token) { method start (line 168) | start(src: string): number | undefined { method tokenizer (line 173) | tokenizer(src: string): katexInlineToken | undefined { method renderer (line 203) | renderer(token) { function escapeHTML (line 214) | function escapeHTML(content: string) { function addInlineCitations (line 228) | function addInlineCitations(md: string, webSearchSources: SimpleSource[]... function sanitizeHref (line 248) | function sanitizeHref(href?: string | null): string | undefined { function highlightCode (line 258) | function highlightCode(text: string, lang?: string): string { function sanitizeMediaUrl (line 269) | function sanitizeMediaUrl(value: string): string | undefined { function serializeMediaAttributes (line 275) | function serializeMediaAttributes(attribs?: Record): str... function serializeMediaNode (line 296) | function serializeMediaNode(node: HtmlNode, state: { hasDisallowedTag: b... function sanitizeHtmlForMultimedia (line 326) | function sanitizeHtmlForMultimedia(html: string): string { function createMarkedInstance (line 345) | function createMarkedInstance(sources: SimpleSource[]): Marked { function isFencedBlockClosed (line 380) | function isFencedBlockClosed(raw?: string): boolean { type CodeToken (line 393) | type CodeToken = { type TextToken (line 401) | type TextToken = { function cacheKey (line 408) | function cacheKey(index: number, blockContent: string, sources: SimpleSo... function processTokens (line 413) | async function processTokens(content: string, sources: SimpleSource[]): ... function processTokensSync (line 442) | function processTokensSync(content: string, sources: SimpleSource[]): To... type Token (line 462) | type Token = CodeToken | TextToken; type BlockToken (line 464) | type BlockToken = { function hashString (line 473) | function hashString(str: string): string { function processBlocks (line 487) | async function processBlocks( function processBlocksSync (line 514) | function processBlocksSync(content: string, sources: SimpleSource[] = []... FILE: src/lib/utils/mcpValidation.ts function validateMcpServerUrl (line 13) | function validateMcpServerUrl(urlString: string): string | null { function isPrivateOrLocalhost (line 48) | function isPrivateOrLocalhost(hostname: string): boolean { function sanitizeUrlForDisplay (line 72) | function sanitizeUrlForDisplay(urlString: string): string { function checkUrlSafety (line 88) | function checkUrlSafety(urlString: string): string | null { function isSensitiveHeader (line 111) | function isSensitiveHeader(key: string): boolean { function validateHeader (line 133) | function validateHeader(key: string, value: string): string | null { FILE: src/lib/utils/mergeAsyncGenerators.ts type Gen (line 1) | type Gen = AsyncGenerator; type GenPromiseMap (line 3) | type GenPromiseMap = Map< FILE: src/lib/utils/messageUpdates.spec.ts function collect (line 15) | async function collect(iter: AsyncGenerator) { FILE: src/lib/utils/messageUpdates.ts type MessageUpdateRequestOptions (line 15) | type MessageUpdateRequestOptions = { type ChunkDetector (line 29) | type ChunkDetector = (buffer: string) => string | null; type SmoothStreamConfig (line 31) | type SmoothStreamConfig = { function fetchMessageUpdates (line 43) | async function fetchMessageUpdates( function applyStreamingMode (line 94) | function applyStreamingMode( function resolveStreamingMode (line 106) | function resolveStreamingMode(s: { streamingMode?: unknown }): Streaming... function parseMessageUpdates (line 140) | function parseMessageUpdates(value: string): { function createWordChunkDetector (line 264) | function createWordChunkDetector(): ChunkDetector { FILE: src/lib/utils/mime.ts constant EXTENSION_TO_MIME (line 3) | const EXTENSION_TO_MIME: Record = { function guessMimeFromUrl (line 30) | function guessMimeFromUrl(url: string): string | undefined { function pickSafeMime (line 41) | function pickSafeMime( FILE: src/lib/utils/parseBlocks.ts function parseMarkdownIntoBlocks (line 12) | function parseMarkdownIntoBlocks(markdown: string): string[] { FILE: src/lib/utils/parseStringToList.ts function parseStringToList (line 1) | function parseStringToList(links: unknown): string[] { FILE: src/lib/utils/randomUuid.ts type UUID (line 1) | type UUID = ReturnType; function randomUUID (line 3) | function randomUUID(): UUID { FILE: src/lib/utils/searchTokens.ts constant PUNCTUATION_REGEX (line 1) | const PUNCTUATION_REGEX = /\p{P}/gu; function removeDiacritics (line 3) | function removeDiacritics(s: string, form: "NFD" | "NFKD" = "NFD"): stri... function generateSearchTokens (line 7) | function generateSearchTokens(value: string): string[] { function escapeForRegExp (line 23) | function escapeForRegExp(s: string): string { function generateQueryTokens (line 27) | function generateQueryTokens(query: string): RegExp[] { FILE: src/lib/utils/sha256.ts function sha256 (line 1) | async function sha256(input: string): Promise { FILE: src/lib/utils/stringifyError.ts function stringifyError (line 2) | function stringifyError(error: unknown): string { FILE: src/lib/utils/sum.ts function sum (line 1) | function sum(nums: number[]): number { FILE: src/lib/utils/template.ts function compileTemplate (line 19) | function compileTemplate( FILE: src/lib/utils/toolProgress.ts function formatToolProgressLabel (line 3) | function formatToolProgressLabel(progress?: MessageToolProgressUpdate): ... FILE: src/lib/utils/tree/addChildren.ts function addChildren (line 4) | function addChildren(conv: Tree, message: NewNode, parentId?: T... FILE: src/lib/utils/tree/addSibling.ts function addSibling (line 4) | function addSibling(conv: Tree, message: NewNode, siblingId: Tr... FILE: src/lib/utils/tree/buildSubtree.ts function buildSubtree (line 3) | function buildSubtree(conv: Tree, id: TreeId): TreeNode[] { FILE: src/lib/utils/tree/convertLegacyConversation.ts function convertLegacyConversation (line 5) | function convertLegacyConversation( FILE: src/lib/utils/tree/isMessageId.ts function isMessageId (line 3) | function isMessageId(id: string): id is Message["id"] { FILE: src/lib/utils/tree/tree.d.ts type TreeId (line 1) | type TreeId = string; type Tree (line 3) | type Tree = { type TreeNode (line 8) | type TreeNode = T & { type NewNode (line 14) | type NewNode = Omit, "id">; FILE: src/lib/utils/updates.ts class UpdateDebouncer (line 6) | class UpdateDebouncer { method maxUpdateTime (line 10) | get maxUpdateTime() { method startRender (line 21) | public startRender() { method endRender (line 25) | public endRender() { FILE: src/lib/utils/urlParams.ts constant MAX_PARAM_LENGTH (line 1) | const MAX_PARAM_LENGTH = 10_000; function sanitizeUrlParam (line 3) | function sanitizeUrlParam(value: string | null): string | null { FILE: src/lib/workers/markdownWorker.ts type SimpleSource (line 2) | type SimpleSource = { type IncomingMessage (line 8) | type IncomingMessage = { type OutgoingMessage (line 15) | type OutgoingMessage = { function processMessage (line 28) | async function processMessage() { FILE: src/routes/+layout.ts type ConversationListItem (line 7) | interface ConversationListItem { type UserInfo (line 14) | interface UserInfo { type SettingsResponse (line 23) | interface SettingsResponse { FILE: src/routes/__debug/openai/+server.ts constant DEFAULT_OPENAI_BASE (line 3) | const DEFAULT_OPENAI_BASE = "https://router.huggingface.co/v1"; function GET (line 5) | async function GET() { FILE: src/routes/admin/export/+server.ts function POST (line 15) | async function POST({ request }) { FILE: src/routes/admin/stats/compute/+server.ts function POST (line 8) | async function POST() { FILE: src/routes/api/conversation/[id]/+server.ts function GET (line 6) | async function GET({ locals, params }) { FILE: src/routes/api/conversation/[id]/message/[messageId]/+server.ts function DELETE (line 6) | async function DELETE({ locals, params }) { FILE: src/routes/api/conversations/+server.ts function GET (line 6) | async function GET({ locals, url }) { function DELETE (line 40) | async function DELETE({ locals }) { FILE: src/routes/api/fetch-url/+server.ts constant MAX_FILE_SIZE (line 7) | const MAX_FILE_SIZE = 10 * 1024 * 1024; constant FETCH_TIMEOUT (line 8) | const FETCH_TIMEOUT = 30000; constant MAX_REDIRECTS (line 9) | const MAX_REDIRECTS = 5; constant SECURITY_HEADERS (line 10) | const SECURITY_HEADERS: HeadersInit = { function GET (line 49) | async function GET({ url }) { FILE: src/routes/api/mcp/health/+server.ts type HealthCheckRequest (line 11) | interface HealthCheckRequest { type HealthCheckResponse (line 16) | interface HealthCheckResponse { FILE: src/routes/api/mcp/servers/+server.ts function GET (line 4) | async function GET() { FILE: src/routes/api/models/+server.ts function GET (line 3) | async function GET() { FILE: src/routes/api/transcribe/+server.ts constant MAX_AUDIO_SIZE (line 6) | const MAX_AUDIO_SIZE = 25 * 1024 * 1024; constant TRANSCRIPTION_TIMEOUT (line 7) | const TRANSCRIPTION_TIMEOUT = 60000; constant ALLOWED_CONTENT_TYPES (line 9) | const ALLOWED_CONTENT_TYPES = [ function POST (line 19) | async function POST({ request, locals }) { FILE: src/routes/api/user/+server.ts function GET (line 1) | async function GET({ locals }) { FILE: src/routes/conversation/[id]/+page.ts type ConversationData (line 8) | interface ConversationData { FILE: src/routes/conversation/[id]/+server.ts function POST (line 30) | async function POST({ request, locals, params, getClientAddress }) { function DELETE (line 679) | async function DELETE({ locals, params }) { function PATCH (line 696) | async function PATCH({ request, locals, params }) { FILE: src/routes/conversation/[id]/message/[messageId]/prompt/+server.ts function GET (line 10) | async function GET({ params, locals }) { FILE: src/routes/conversation/[id]/share/+server.ts function POST (line 9) | async function POST({ params, locals }) { FILE: src/routes/conversation/[id]/stop-generating/+server.ts function POST (line 10) | async function POST({ params, locals }) { FILE: src/routes/healthcheck/+server.ts function GET (line 1) | async function GET() { FILE: src/routes/login/+server.ts function GET (line 3) | async function GET(event) { FILE: src/routes/login/callback/+server.ts function GET (line 27) | async function GET({ url, locals, cookies, request, getClientAddress }) { FILE: src/routes/login/callback/updateUser.ts function updateUser (line 19) | async function updateUser(params: { FILE: src/routes/logout/+server.ts function POST (line 7) | async function POST({ locals, cookies }) { FILE: src/routes/metrics/+server.ts function GET (line 4) | async function GET() { FILE: src/routes/models/[...model]/+page.ts function load (line 3) | async function load({ params, parent, fetch }) { FILE: src/routes/settings/(nav)/+server.ts function POST (line 24) | async function POST({ request, locals }) { FILE: src/routes/settings/(nav)/[...model]/+page.ts function load (line 4) | async function load({ parent, params }) { FILE: svelte.config.js function getCurrentCommitSHA (line 12) | function getCurrentCommitSHA() { FILE: vite.config.ts function loadTTFAsArrayBuffer (line 10) | function loadTTFAsArrayBuffer() {