SYMBOL INDEX (611 symbols across 200 files) FILE: app/api/advanced-search/route.ts constant SEARXNG_MAX_RESULTS (line 22) | const SEARXNG_MAX_RESULTS = Math.max( constant CACHE_TTL (line 27) | const CACHE_TTL = 3600 // Cache time-to-live in seconds (1 hour) constant CACHE_EXPIRATION_CHECK_INTERVAL (line 28) | const CACHE_EXPIRATION_CHECK_INTERVAL = 3600000 // 1 hour in milliseconds function initializeRedisClient (line 33) | async function initializeRedisClient() { function getCachedResults (line 67) | async function getCachedResults( function setCachedResults (line 95) | async function setCachedResults( function cleanupExpiredCache (line 116) | async function cleanupExpiredCache() { function POST (line 137) | async function POST(request: Request) { function advancedSearchXNGSearch (line 183) | async function advancedSearchXNGSearch( function crawlPage (line 313) | async function crawlPage( function highlightQueryTerms (line 409) | function highlightQueryTerms(content: string, query: string): string { function calculateRelevanceScore (line 434) | function calculateRelevanceScore(result: SearXNGResult, query: string): ... function extractPublicationDate (line 503) | function extractPublicationDate(document: Document): Date | null { function fetchJsonWithRetry (line 539) | async function fetchJsonWithRetry(url: string, retries: number): Promise... function fetchJson (line 550) | function fetchJson(url: string): Promise { function fetchHtmlWithTimeout (line 586) | async function fetchHtmlWithTimeout( function fetchHtml (line 602) | function fetchHtml(url: string): Promise { function timeout (line 638) | function timeout(ms: number, message: string): Promise { function isQualityContent (line 646) | function isQualityContent(text: string): boolean { FILE: app/api/chat/route.ts function POST (line 19) | async function POST(req: Request) { FILE: app/api/chats/route.ts type ChatPageResponse (line 6) | interface ChatPageResponse { function GET (line 11) | async function GET(request: NextRequest) { FILE: app/api/feedback/route.ts function POST (line 7) | async function POST(req: Request) { FILE: app/api/upload/route.ts constant MAX_FILE_SIZE (line 12) | const MAX_FILE_SIZE = 5 * 1024 * 1024 // 5MB constant ALLOWED_TYPES (line 13) | const ALLOWED_TYPES = ['image/jpeg', 'image/png', 'application/pdf'] function POST (line 15) | async function POST(req: NextRequest) { function sanitizeFilename (line 60) | function sanitizeFilename(filename: string) { function uploadFileToR2 (line 64) | async function uploadFileToR2(file: File, userId: string, chatId: string) { FILE: app/auth/confirm/route.ts function GET (line 8) | async function GET(request: NextRequest) { FILE: app/auth/error/page.tsx function Page (line 3) | async function Page({ FILE: app/auth/forgot-password/page.tsx function Page (line 3) | function Page() { FILE: app/auth/login/page.tsx function Page (line 3) | function Page() { FILE: app/auth/oauth/route.ts function GET (line 6) | async function GET(request: Request) { FILE: app/auth/sign-up-success/page.tsx function Page (line 9) | function Page() { FILE: app/auth/sign-up/page.tsx function Page (line 3) | function Page() { FILE: app/auth/update-password/page.tsx function Page (line 3) | function Page() { FILE: app/layout.tsx function RootLayout (line 52) | async function RootLayout({ FILE: app/page.tsx function Page (line 5) | async function Page() { FILE: app/search/[id]/page.tsx function generateMetadata (line 12) | async function generateMetadata(props: { function SearchPage (line 29) | async function SearchPage(props: { FILE: app/search/loading.tsx function Loading (line 5) | function Loading() { FILE: app/search/page.tsx function SearchPage (line 10) | async function SearchPage(props: { FILE: components/action-buttons.tsx constant FOCUS_OUT_DELAY_MS (line 19) | const FOCUS_OUT_DELAY_MS = 100 // Delay to ensure focus has actually moved type ActionCategory (line 21) | interface ActionCategory { type ActionButtonsProps (line 88) | interface ActionButtonsProps { function ActionButtons (line 95) | function ActionButtons({ FILE: components/answer-section.tsx type AnswerSectionProps (line 18) | type AnswerSectionProps = { function AnswerSection (line 35) | function AnswerSection({ FILE: components/app-sidebar.tsx function AppSidebar (line 23) | function AppSidebar() { FILE: components/artifact/artifact-content.tsx function isTodoToolPart (line 10) | function isTodoToolPart(part: Part): part is ToolPart<'todoWrite'> { function ArtifactContent (line 14) | function ArtifactContent({ part }: { part: Part | null }) { FILE: components/artifact/artifact-context.tsx constant ANIMATION_DURATION (line 17) | const ANIMATION_DURATION = 300 type ArtifactState (line 19) | interface ArtifactState { type ArtifactAction (line 24) | type ArtifactAction = function artifactReducer (line 34) | function artifactReducer( type ArtifactContextValue (line 50) | interface ArtifactContextValue { function ArtifactProvider (line 60) | function ArtifactProvider({ children }: { children: ReactNode }) { function useArtifact (line 91) | function useArtifact() { FILE: components/artifact/artifact-root.tsx function ArtifactRoot (line 8) | function ArtifactRoot({ children }: { children: ReactNode }) { FILE: components/artifact/chat-artifact-container.tsx constant DEFAULT_WIDTH (line 15) | const DEFAULT_WIDTH = 500 constant MIN_WIDTH (line 16) | const MIN_WIDTH = 320 constant MAX_WIDTH (line 17) | const MAX_WIDTH = 800 constant CHAT_MIN_WIDTH (line 18) | const CHAT_MIN_WIDTH = 360 constant RESIZE_OVERLAY_Z_INDEX (line 19) | const RESIZE_OVERLAY_Z_INDEX = 9999 function getAllowedWidthBounds (line 22) | function getAllowedWidthBounds(containerWidth: number): { function ChatArtifactContainer (line 39) | function ChatArtifactContainer({ FILE: components/artifact/reasoning-content.tsx function ReasoningContent (line 8) | function ReasoningContent({ reasoning }: { reasoning: string }) { FILE: components/artifact/search-artifact-content.tsx function SearchArtifactContent (line 14) | function SearchArtifactContent({ tool }: { tool: ToolPart<'search'> }) { FILE: components/artifact/todo-invocation-content.tsx type TodoInvocationContentProps (line 7) | interface TodoInvocationContentProps { function TodoInvocationContent (line 11) | function TodoInvocationContent({ part }: TodoInvocationContentProps) { FILE: components/artifact/tool-invocation-content.tsx function ToolInvocationContent (line 7) | function ToolInvocationContent({ part }: { part: ToolPart }) { FILE: components/attachment-preview.tsx type Attachment (line 5) | interface Attachment { type AttachmentPreviewProps (line 11) | interface AttachmentPreviewProps { FILE: components/auth-modal.tsx type AuthModalProps (line 15) | interface AuthModalProps { function AuthModal (line 20) | function AuthModal({ open, onOpenChange }: AuthModalProps) { FILE: components/chat-error.tsx type ChatErrorProps (line 5) | interface ChatErrorProps { function ChatError (line 9) | function ChatError({ error }: ChatErrorProps) { FILE: components/chat-messages.tsx type ChatSection (line 17) | interface ChatSection { type ChatMessagesProps (line 23) | interface ChatMessagesProps { function ChatMessages (line 37) | function ChatMessages({ FILE: components/chat-panel.tsx constant INPUT_UPDATE_DELAY_MS (line 25) | const INPUT_UPDATE_DELAY_MS = 10 // Delay to ensure input value is updat... type ChatPanelProps (line 27) | interface ChatPanelProps { function ChatPanel (line 50) | function ChatPanel({ FILE: components/chat-share.tsx type ChatShareProps (line 24) | interface ChatShareProps { function ChatShare (line 29) | function ChatShare({ chatId, className }: ChatShareProps) { FILE: components/chat.tsx type ChatSection (line 28) | interface ChatSection { function Chat (line 34) | function Chat({ FILE: components/citation-context.tsx type CitationContextValue (line 7) | interface CitationContextValue { function CitationProvider (line 15) | function CitationProvider({ function useCitation (line 29) | function useCitation() { FILE: components/citation-link.tsx type CitationLinkProps (line 16) | interface CitationLinkProps { FILE: components/collapsible-message.tsx type CollapsibleMessageProps (line 14) | interface CollapsibleMessageProps { function CollapsibleMessage (line 30) | function CollapsibleMessage({ FILE: components/custom-link.tsx type CustomLinkProps (line 9) | type CustomLinkProps = Omit< function Citing (line 14) | function Citing({ FILE: components/data-section.tsx type DataSectionProps (line 9) | interface DataSectionProps { function DataSection (line 14) | function DataSection({ part, onQuerySelect }: DataSectionProps) { FILE: components/default-skeleton.tsx function SearchSkeleton (line 15) | function SearchSkeleton() { FILE: components/drag-overlay.tsx function DragOverlay (line 6) | function DragOverlay({ visible }: { visible: boolean }) { FILE: components/dynamic-tool-display.tsx type DynamicToolPart (line 6) | type DynamicToolPart = type DynamicToolDisplayProps (line 38) | interface DynamicToolDisplayProps { function DynamicToolDisplay (line 42) | function DynamicToolDisplay({ part }: DynamicToolDisplayProps) { FILE: components/error-modal.tsx type ErrorModalProps (line 17) | interface ErrorModalProps { function ErrorModal (line 29) | function ErrorModal({ FILE: components/external-link-items.tsx function ExternalLinkItems (line 26) | function ExternalLinkItems() { FILE: components/feedback-modal.tsx type Sentiment (line 21) | type Sentiment = 'positive' | 'neutral' | 'negative' type FeedbackModalProps (line 23) | interface FeedbackModalProps { function FeedbackModal (line 28) | function FeedbackModal({ open, onOpenChange }: FeedbackModalProps) { FILE: components/fetch-section.tsx type FetchSectionProps (line 12) | interface FetchSectionProps { function FetchSection (line 22) | function FetchSection({ FILE: components/file-upload-button.tsx function FileUploadButton (line 22) | function FileUploadButton({ FILE: components/forgot-password-form.tsx function ForgotPasswordForm (line 20) | function ForgotPasswordForm({ FILE: components/guest-menu.tsx function GuestMenu (line 27) | function GuestMenu() { FILE: components/header.tsx type HeaderProps (line 19) | interface HeaderProps { FILE: components/inspector/inspector-drawer.tsx function InspectorDrawer (line 13) | function InspectorDrawer() { FILE: components/inspector/inspector-panel.tsx function InspectorPanel (line 18) | function InspectorPanel() { FILE: components/login-form.tsx function LoginForm (line 24) | function LoginForm({ FILE: components/message-actions.tsx type MessageActionsProps (line 18) | interface MessageActionsProps { function MessageActions (line 32) | function MessageActions({ FILE: components/message.tsx function MarkdownMessage (line 18) | function MarkdownMessage({ FILE: components/model-type-selector.tsx constant MODEL_TYPE_OPTIONS (line 18) | const MODEL_TYPE_OPTIONS: { value: ModelType; label: string }[] = [ function ModelTypeSelector (line 23) | function ModelTypeSelector({ FILE: components/process-header.tsx type ProcessHeaderProps (line 7) | type ProcessHeaderProps = { function ProcessHeader (line 16) | function ProcessHeader({ FILE: components/process-rail.tsx type ProcessRailProps (line 3) | interface ProcessRailProps { function ProcessRail (line 9) | function ProcessRail({ FILE: components/question-confirmation.tsx type QuestionConfirmationProps (line 14) | interface QuestionConfirmationProps { type QuestionOption (line 20) | interface QuestionOption { type QuestionInput (line 25) | interface QuestionInput { type QuestionOutput (line 33) | interface QuestionOutput { function QuestionConfirmation (line 39) | function QuestionConfirmation({ FILE: components/reasoning-section.tsx type ReasoningContent (line 16) | interface ReasoningContent { type ReasoningSectionProps (line 21) | interface ReasoningSectionProps { function ReasoningSection (line 32) | function ReasoningSection({ FILE: components/related-questions.tsx type RelatedQuestionsProps (line 14) | interface RelatedQuestionsProps { FILE: components/render-message.tsx type RenderMessageProps (line 18) | interface RenderMessageProps { function RenderMessage (line 34) | function RenderMessage({ FILE: components/research-process-section.tsx type TextPart (line 29) | type TextPart = { type DataPart (line 34) | type DataPart = UIDataPart type MessagePart (line 36) | type MessagePart = function isReasoningPart (line 44) | function isReasoningPart(part: MessagePart): part is ReasoningPart { function isToolPart (line 48) | function isToolPart(part: MessagePart): part is ToolPart { function isTextPart (line 54) | function isTextPart(part: MessagePart): part is TextPart { function isDataPart (line 58) | function isDataPart(part: MessagePart): part is DataPart { type Props (line 62) | type Props = { function splitByText (line 80) | function splitByText(parts: MessagePart[]): MessagePart[][] { function groupConsecutiveParts (line 110) | function groupConsecutiveParts(segment: MessagePart[]): MessagePart[][] { function useAccordionState (line 148) | function useAccordionState(onOpenChange: (id: string, open: boolean) => ... function RenderPart (line 176) | function RenderPart({ function useHasSubsequentContent (line 264) | function useHasSubsequentContent( function ResearchProcessSection (line 293) | function ResearchProcessSection({ FILE: components/retry-button.tsx type RetryButtonProps (line 7) | interface RetryButtonProps { FILE: components/search-mode-selector.tsx function SearchModeSelector (line 21) | function SearchModeSelector() { FILE: components/search-results-image.tsx type SearchResultsImageSectionProps (line 33) | interface SearchResultsImageSectionProps { type NormalizedImage (line 39) | type NormalizedImage = { id: string; url: string; description: string } type FilterStatus (line 41) | type FilterStatus = 'loading' | 'ready' | 'empty' type FilteredImagesState (line 43) | interface FilteredImagesState { FILE: components/search-results.tsx type SearchResultsProps (line 13) | interface SearchResultsProps { function SearchResults (line 18) | function SearchResults({ FILE: components/search-section.tsx type SearchSectionProps (line 25) | interface SearchSectionProps { function SearchSection (line 35) | function SearchSection({ FILE: components/section.tsx type SectionProps (line 24) | type SectionProps = { function ToolArgsSection (line 100) | function ToolArgsSection({ FILE: components/sidebar/chat-history-client.tsx type ChatPageResponse (line 19) | interface ChatPageResponse { function ChatHistoryClient (line 24) | function ChatHistoryClient() { FILE: components/sidebar/chat-history-section.tsx function ChatHistorySection (line 3) | async function ChatHistorySection() { FILE: components/sidebar/chat-history-skeleton.tsx function ChatHistorySkeleton (line 7) | function ChatHistorySkeleton() { FILE: components/sidebar/chat-menu-item.tsx type ChatMenuItemProps (line 38) | interface ChatMenuItemProps { function ChatMenuItem (line 80) | function ChatMenuItem({ chat }: ChatMenuItemProps) { FILE: components/sidebar/clear-history-action.tsx type ClearHistoryActionProps (line 31) | interface ClearHistoryActionProps { function ClearHistoryAction (line 35) | function ClearHistoryAction({ empty }: ClearHistoryActionProps) { FILE: components/sign-up-form.tsx function SignUpForm (line 22) | function SignUpForm({ FILE: components/source-favicons.tsx type SourceFaviconsProps (line 6) | interface SourceFaviconsProps { function SourceFavicons (line 15) | function SourceFavicons({ FILE: components/theme-menu-items.tsx function ThemeMenuItems (line 9) | function ThemeMenuItems() { FILE: components/theme-provider.tsx function ThemeProvider (line 7) | function ThemeProvider({ children, ...props }: ThemeProviderProps) { FILE: components/todo-list-content.tsx type TodoListContentProps (line 8) | type TodoListContentProps = { function TodoListContent (line 20) | function TodoListContent({ FILE: components/tool-badge.tsx type ToolBadgeProps (line 9) | type ToolBadgeProps = { FILE: components/tool-section.tsx type ToolSectionProps (line 12) | interface ToolSectionProps { function ToolSection (line 24) | function ToolSection({ FILE: components/tool-todo-display.tsx type ToolTodoDisplayProps (line 11) | interface ToolTodoDisplayProps { function ToolTodoDisplay (line 36) | function ToolTodoDisplay({ FILE: components/ui/animated-logo.tsx function AnimatedLogo (line 5) | function AnimatedLogo({ FILE: components/ui/badge.tsx type BadgeProps (line 27) | interface BadgeProps function Badge (line 31) | function Badge({ className, variant, ...props }: BadgeProps) { FILE: components/ui/button.tsx type ButtonProps (line 37) | interface ButtonProps FILE: components/ui/carousel.tsx type CarouselApi (line 14) | type CarouselApi = UseEmblaCarouselType[1] type UseCarouselParameters (line 15) | type UseCarouselParameters = Parameters type CarouselOptions (line 16) | type CarouselOptions = UseCarouselParameters[0] type CarouselPlugin (line 17) | type CarouselPlugin = UseCarouselParameters[1] type CarouselProps (line 19) | type CarouselProps = { type CarouselContextProps (line 26) | type CarouselContextProps = { function useCarousel (line 37) | function useCarousel() { FILE: components/ui/dropdown-menu.tsx function DropdownMenu (line 10) | function DropdownMenu({ function DropdownMenuPortal (line 16) | function DropdownMenuPortal({ function DropdownMenuTrigger (line 24) | function DropdownMenuTrigger({ function DropdownMenuContent (line 35) | function DropdownMenuContent({ function DropdownMenuGroup (line 55) | function DropdownMenuGroup({ function DropdownMenuItem (line 63) | function DropdownMenuItem({ function DropdownMenuCheckboxItem (line 86) | function DropdownMenuCheckboxItem({ function DropdownMenuRadioGroup (line 112) | function DropdownMenuRadioGroup({ function DropdownMenuRadioItem (line 123) | function DropdownMenuRadioItem({ function DropdownMenuLabel (line 147) | function DropdownMenuLabel({ function DropdownMenuSeparator (line 167) | function DropdownMenuSeparator({ function DropdownMenuShortcut (line 180) | function DropdownMenuShortcut({ function DropdownMenuSub (line 196) | function DropdownMenuSub({ function DropdownMenuSubTrigger (line 202) | function DropdownMenuSubTrigger({ function DropdownMenuSubContent (line 226) | function DropdownMenuSubContent({ FILE: components/ui/icons.tsx function IconLogo (line 7) | function IconLogo({ className, ...props }: React.ComponentProps<'svg'>) { function IconLogoOutline (line 24) | function IconLogoOutline({ className, ...props }: React.ComponentProps<'... function IconBlinkingLogo (line 48) | function IconBlinkingLogo({ FILE: components/ui/input.tsx type InputProps (line 5) | interface InputProps FILE: components/ui/sheet.tsx type SheetContentProps (line 53) | interface SheetContentProps FILE: components/ui/sidebar.tsx constant SIDEBAR_COOKIE_NAME (line 31) | const SIDEBAR_COOKIE_NAME = 'sidebar_state' constant SIDEBAR_COOKIE_MAX_AGE (line 32) | const SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7 constant SIDEBAR_WIDTH (line 33) | const SIDEBAR_WIDTH = '16rem' constant SIDEBAR_WIDTH_MOBILE (line 34) | const SIDEBAR_WIDTH_MOBILE = '18rem' constant SIDEBAR_WIDTH_ICON (line 35) | const SIDEBAR_WIDTH_ICON = '3rem' constant SIDEBAR_KEYBOARD_SHORTCUT (line 36) | const SIDEBAR_KEYBOARD_SHORTCUT = 'b' type SidebarContextProps (line 38) | type SidebarContextProps = { function useSidebar (line 50) | function useSidebar() { function getCookie (line 60) | function getCookie(name: string): string | null { FILE: components/ui/skeleton.tsx function Skeleton (line 3) | function Skeleton({ FILE: components/ui/sonner.tsx type ToasterProps (line 7) | type ToasterProps = React.ComponentProps FILE: components/ui/spinner.tsx type SpinnerProps (line 7) | interface SpinnerProps extends React.SVGProps {} FILE: components/ui/status-indicator.tsx type StatusIndicatorProps (line 5) | interface StatusIndicatorProps { function StatusIndicator (line 11) | function StatusIndicator({ FILE: components/ui/textarea.tsx type TextareaProps (line 5) | interface TextareaProps FILE: components/ui/tooltip-button.tsx type TooltipButtonProps (line 12) | interface TooltipButtonProps extends ButtonProps { FILE: components/update-password-form.tsx function UpdatePasswordForm (line 20) | function UpdatePasswordForm({ FILE: components/uploaded-file-list.tsx type UploadedFileListProps (line 10) | interface UploadedFileListProps { FILE: components/user-file-section.tsx type UserFileSectionProps (line 5) | interface UserFileSectionProps { FILE: components/user-menu.tsx type UserMenuProps (line 27) | interface UserMenuProps { function UserMenu (line 31) | function UserMenu({ user }: UserMenuProps) { FILE: components/user-text-section.tsx type UserTextSectionProps (line 13) | interface UserTextSectionProps { FILE: components/video-carousel-dialog.tsx type VideoCarouselDialogProps (line 24) | interface VideoCarouselDialogProps { function VideoCarouselDialog (line 31) | function VideoCarouselDialog({ FILE: components/video-result-grid.tsx type VideoResultGridProps (line 14) | interface VideoResultGridProps { function VideoResultGrid (line 20) | function VideoResultGrid({ FILE: components/video-search-results.tsx type VideoSearchResultsProps (line 8) | interface VideoSearchResultsProps { function createVideoSearchResults (line 14) | function createVideoSearchResults( function VideoSearchResults (line 29) | function VideoSearchResults({ FILE: drizzle/0000_black_lifeguard.sql type "chats" (line 1) | CREATE TABLE "chats" ( type "messages" (line 9) | CREATE TABLE "messages" ( FILE: drizzle/0003_heavy_whirlwind.sql type "feedback" (line 1) | CREATE TABLE "feedback" ( type "feedback" (line 11) | CREATE INDEX "feedback_user_id_idx" ON "feedback" USING btree ("user_id") type "feedback" (line 12) | CREATE INDEX "feedback_created_at_idx" ON "feedback" USING btree ("creat... FILE: drizzle/0004_natural_wallow.sql type "chats" (line 1) | CREATE INDEX "chats_user_id_idx" ON "chats" USING btree ("user_id") type "chats" (line 2) | CREATE INDEX "chats_user_id_created_at_idx" ON "chats" USING btree ("use... type "chats" (line 3) | CREATE INDEX "chats_created_at_idx" ON "chats" USING btree ("created_at"... FILE: drizzle/0009_thankful_may_parker.sql type "chats" (line 1) | CREATE INDEX "chats_id_user_id_idx" ON "chats" USING btree ("id","user_id") FILE: hooks/use-auth-check.tsx function useAuthCheck (line 9) | function useAuthCheck() { FILE: hooks/use-file-dropzone.ts type UseFileDropzoneProps (line 7) | type UseFileDropzoneProps = { function useFileDropzone (line 15) | function useFileDropzone({ FILE: hooks/use-mobile.tsx constant MOBILE_BREAKPOINT (line 3) | const MOBILE_BREAKPOINT = 768 function useIsMobile (line 5) | function useIsMobile() { FILE: instrumentation.ts function register (line 4) | async function register() { FILE: lib/actions/chat.ts constant DEFAULT_CHAT_TITLE (line 14) | const DEFAULT_CHAT_TITLE = 'Untitled' function getChats (line 39) | async function getChats() { function getChatsPage (line 50) | async function getChatsPage(limit = 20, offset = 0) { function loadChat (line 63) | async function loadChat( function createChat (line 75) | async function createChat( function createChatAndSaveMessage (line 100) | async function createChatAndSaveMessage( function createChatWithFirstMessage (line 141) | async function createChatWithFirstMessage( function upsertMessage (line 179) | async function upsertMessage( function deleteChat (line 205) | async function deleteChat(chatId: string) { function clearChats (line 223) | async function clearChats() { function deleteMessagesAfter (line 243) | async function deleteMessagesAfter(chatId: string, messageId: string) { function shareChat (line 265) | async function shareChat(chatId: string) { function deleteMessagesFromIndex (line 287) | async function deleteMessagesFromIndex( function saveChatTitle (line 321) | async function saveChatTitle( FILE: lib/actions/feedback.ts function updateMessageFeedback (line 12) | async function updateMessageFeedback( function getMessageFeedback (line 77) | async function getMessageFeedback( FILE: lib/actions/site-feedback.ts function submitFeedback (line 8) | async function submitFeedback(data: { FILE: lib/agents/generate-related-questions.ts function createRelatedQuestionsStream (line 10) | function createRelatedQuestionsStream( FILE: lib/agents/prompts/related-questions-prompt.ts constant RELATED_QUESTIONS_PROMPT (line 1) | const RELATED_QUESTIONS_PROMPT = `You are a professional web researcher ... FILE: lib/agents/prompts/search-mode-prompts.ts function getQuickModePrompt (line 8) | function getQuickModePrompt(): string { function getApproachStrategy (line 144) | function getApproachStrategy(): string { function getAdaptiveModePrompt (line 190) | function getAdaptiveModePrompt(): string { constant QUICK_MODE_PROMPT (line 316) | const QUICK_MODE_PROMPT = getQuickModePrompt() FILE: lib/agents/researcher.ts function wrapSearchToolForQuickMode (line 21) | function wrapSearchToolForQuickMode< function createResearcher (line 68) | function createResearcher({ function getResearcherTools (line 159) | function getResearcherTools( FILE: lib/agents/title-generator.ts type GenerateChatTitleParams (line 6) | interface GenerateChatTitleParams { function generateChatTitle (line 19) | async function generateChatTitle({ FILE: lib/analytics/track-chat-event.ts function trackChatEvent (line 31) | async function trackChatEvent(data: ChatEventData): Promise { FILE: lib/analytics/types.ts type ChatEventData (line 12) | interface ChatEventData { type AnalyticsProvider (line 36) | interface AnalyticsProvider { FILE: lib/analytics/utils.ts function calculateConversationTurn (line 22) | function calculateConversationTurn(messages: UIMessage[]): number { FILE: lib/auth/get-current-user.ts function getCurrentUser (line 5) | async function getCurrentUser() { function getCurrentUserId (line 18) | async function getCurrentUserId() { FILE: lib/config/load-models-config.ts type ModelsConfig (line 8) | interface ModelsConfig { constant VALID_MODEL_TYPES (line 19) | const VALID_MODEL_TYPES: ModelType[] = ['speed', 'quality'] constant VALID_SEARCH_MODES (line 20) | const VALID_SEARCH_MODES: SearchMode[] = ['quick', 'adaptive'] function validateModelsConfigStructure (line 22) | function validateModelsConfigStructure( function loadModelsConfig (line 62) | async function loadModelsConfig(): Promise { function loadModelsConfigSync (line 79) | function loadModelsConfigSync(): ModelsConfig { function getModelsConfig (line 96) | function getModelsConfig(): ModelsConfig { FILE: lib/config/model-types.ts function getModelForModeAndType (line 8) | function getModelForModeAndType( function getRelatedQuestionsModel (line 17) | function getRelatedQuestionsModel(): Model { FILE: lib/config/ollama-validator.ts function getConfiguredOllamaModels (line 15) | async function getConfiguredOllamaModels(): Promise { function initializeOllamaValidation (line 46) | async function initializeOllamaValidation(): Promise { function validateOllamaModel (line 154) | function validateOllamaModel(modelId: string): { function getValidatedOllamaModels (line 190) | function getValidatedOllamaModels(): string[] { FILE: lib/config/search-modes.ts type SearchModeConfig (line 7) | interface SearchModeConfig { constant SEARCH_MODE_CONFIGS (line 16) | const SEARCH_MODE_CONFIGS: SearchModeConfig[] = [ function getSearchModeConfig (line 34) | function getSearchModeConfig( FILE: lib/constants/index.ts constant CHAT_ID (line 1) | const CHAT_ID = 'search' as const FILE: lib/contexts/user-context.tsx function UserProvider (line 7) | function UserProvider({ function useHasUser (line 17) | function useHasUser() { FILE: lib/db/__tests__/with-rls.test.ts function createMockTx (line 17) | function createMockTx(overrides: Partial = {}): TxInstance { FILE: lib/db/actions.ts function createChat (line 23) | async function createChat({ function getChat (line 52) | async function getChat( function upsertMessage (line 86) | async function upsertMessage( function loadChat (line 131) | async function loadChat( function loadChatWithMessages (line 155) | async function loadChatWithMessages( function deleteMessagesAfter (line 198) | async function deleteMessagesAfter( function deleteMessagesFromIndex (line 240) | async function deleteMessagesFromIndex( function getChats (line 275) | async function getChats(userId: string): Promise { function getChatsPage (line 288) | async function getChatsPage( function deleteChat (line 319) | async function deleteChat( function updateChatVisibility (line 350) | async function updateChatVisibility( function updateChatTitle (line 374) | async function updateChatTitle( function createChatWithFirstMessageTransaction (line 394) | async function createChatWithFirstMessageTransaction({ FILE: lib/db/index.ts type Schema (line 65) | type Schema = typeof schema FILE: lib/db/schema.ts constant ID_LENGTH (line 17) | const ID_LENGTH = 191 constant USER_ID_LENGTH (line 18) | const USER_ID_LENGTH = 255 constant VARCHAR_LENGTH (line 19) | const VARCHAR_LENGTH = 256 constant FILENAME_LENGTH (line 20) | const FILENAME_LENGTH = 1024 type Chat (line 70) | type Chat = InferSelectModel type Message (line 120) | type Message = InferSelectModel type Part (line 258) | type Part = InferSelectModel type NewPart (line 259) | type NewPart = typeof parts.$inferInsert type Feedback (line 300) | type Feedback = InferSelectModel FILE: lib/db/with-rls.ts type DbInstance (line 6) | type DbInstance = typeof db type TxInstance (line 7) | type TxInstance = Parameters[0]>[0] class RLSViolationError (line 12) | class RLSViolationError extends Error { method constructor (line 13) | constructor(message = 'Row level security policy violation') { function withRLS (line 39) | async function withRLS( function withOptionalRLS (line 80) | async function withOptionalRLS( FILE: lib/firecrawl/client.ts class FirecrawlClient (line 8) | class FirecrawlClient { method constructor (line 12) | constructor(apiKey: string) { method search (line 16) | async search( method searchImages (line 40) | async searchImages( method getImagesForQuery (line 58) | async getImagesForQuery( method getHeaders (line 82) | private getHeaders(): Record { method handleResponse (line 89) | private async handleResponse(response: Response): Promise { FILE: lib/firecrawl/types.ts type FirecrawlSource (line 1) | type FirecrawlSource = 'web' | 'news' | 'images' type FirecrawlSearchOptions (line 3) | type FirecrawlSearchOptions = { type FirecrawlImageSearchOptions (line 11) | type FirecrawlImageSearchOptions = { type FirecrawlImageResult (line 17) | type FirecrawlImageResult = { type FirecrawlWebResult (line 26) | type FirecrawlWebResult = { type FirecrawlNewsResult (line 34) | type FirecrawlNewsResult = { type FirecrawlSearchResponseData (line 42) | type FirecrawlSearchResponseData = { type FirecrawlSearchResponse (line 47) | type FirecrawlSearchResponse = { type FirecrawlImageSearchResponseData (line 52) | type FirecrawlImageSearchResponseData = { type FirecrawlImageSearchResponse (line 56) | type FirecrawlImageSearchResponse = { FILE: lib/hooks/use-copy-to-clipboard.ts type useCopyToClipboardProps (line 5) | interface useCopyToClipboardProps { function useCopyToClipboard (line 9) | function useCopyToClipboard({ FILE: lib/hooks/use-media-query.ts function useMediaQuery (line 10) | function useMediaQuery(query: string): boolean { FILE: lib/ollama/client.ts class OllamaClient (line 8) | class OllamaClient { method constructor (line 11) | constructor(baseUrl: string) { method getModels (line 19) | async getModels(): Promise { method getModelCapabilities (line 46) | async getModelCapabilities( method isAvailable (line 81) | async isAvailable(): Promise { FILE: lib/ollama/types.ts type OllamaModel (line 1) | interface OllamaModel { type OllamaModelCapabilities (line 16) | interface OllamaModelCapabilities { type OllamaModelsResponse (line 24) | interface OllamaModelsResponse { type OllamaShowResponse (line 28) | interface OllamaShowResponse { FILE: lib/rate-limit/chat-limits.ts constant DAILY_CHAT_LIMIT (line 5) | const DAILY_CHAT_LIMIT = 100 function getSecondsUntilMidnight (line 10) | function getSecondsUntilMidnight(): number { function getNextMidnightTimestamp (line 20) | function getNextMidnightTimestamp(): number { function checkOverallChatLimit (line 27) | async function checkOverallChatLimit(userId: string): Promise<{ function checkAndEnforceOverallChatLimit (line 84) | async function checkAndEnforceOverallChatLimit( FILE: lib/rate-limit/guest-limit.ts constant DEFAULT_GUEST_DAILY_LIMIT (line 3) | const DEFAULT_GUEST_DAILY_LIMIT = 10 function getGuestDailyLimit (line 5) | function getGuestDailyLimit(): number { function getSecondsUntilMidnight (line 14) | function getSecondsUntilMidnight(): number { function getNextMidnightTimestamp (line 21) | function getNextMidnightTimestamp(): number { function checkGuestLimit (line 28) | async function checkGuestLimit(ip: string): Promise<{ function checkAndEnforceGuestLimit (line 81) | async function checkAndEnforceGuestLimit( FILE: lib/schema/fetch.tsx type PartialInquiry (line 14) | type PartialInquiry = DeepPartial FILE: lib/schema/question.ts function getQuestionSchemaForModel (line 42) | function getQuestionSchemaForModel(fullModel: string) { FILE: lib/schema/related.tsx type RelatedQuestion (line 9) | type RelatedQuestion = z.infer type Related (line 10) | type Related = z.infer FILE: lib/schema/search.tsx function getSearchSchemaForModel (line 81) | function getSearchSchemaForModel(fullModel: string) { type PartialInquiry (line 96) | type PartialInquiry = DeepPartial FILE: lib/storage/r2-client.ts constant R2_BUCKET_NAME (line 3) | const R2_BUCKET_NAME = process.env.R2_BUCKET_NAME || 'user-uploads' constant R2_PUBLIC_URL (line 4) | const R2_PUBLIC_URL = process.env.R2_PUBLIC_URL || '' function getR2Client (line 8) | function getR2Client(): S3Client { FILE: lib/streaming/create-chat-stream-response.ts constant DEFAULT_CHAT_TITLE (line 35) | const DEFAULT_CHAT_TITLE = 'Untitled' function createChatStreamResponse (line 37) | async function createChatStreamResponse( FILE: lib/streaming/create-ephemeral-chat-stream-response.ts type EphemeralStreamConfig (line 27) | type EphemeralStreamConfig = Pick< function createEphemeralChatStreamResponse (line 35) | async function createEphemeralChatStreamResponse( FILE: lib/streaming/helpers/persist-stream-results.ts constant DEFAULT_CHAT_TITLE (line 9) | const DEFAULT_CHAT_TITLE = 'Untitled' function persistStreamResults (line 11) | async function persistStreamResults( FILE: lib/streaming/helpers/prepare-messages.ts constant DEFAULT_CHAT_TITLE (line 15) | const DEFAULT_CHAT_TITLE = 'Untitled' function prepareMessages (line 17) | async function prepareMessages( FILE: lib/streaming/helpers/stream-related-questions.ts function streamRelatedQuestions (line 10) | async function streamRelatedQuestions( FILE: lib/streaming/helpers/strip-reasoning-parts.ts function stripReasoningParts (line 15) | function stripReasoningParts(messages: UIMessage[]): UIMessage[] { FILE: lib/streaming/helpers/types.ts type StreamContext (line 4) | interface StreamContext { FILE: lib/streaming/types.ts type BaseStreamConfig (line 7) | interface BaseStreamConfig { FILE: lib/supabase/client.ts function createClient (line 3) | function createClient() { FILE: lib/supabase/middleware.ts function updateSession (line 5) | async function updateSession(request: NextRequest) { FILE: lib/supabase/server.ts function createClient (line 5) | async function createClient() { FILE: lib/tools/dynamic.ts function createDynamicTool (line 10) | function createDynamicTool( function createMCPTool (line 34) | function createMCPTool( function createCustomTool (line 48) | function createCustomTool( FILE: lib/tools/fetch.ts constant CONTENT_CHARACTER_LIMIT (line 6) | const CONTENT_CHARACTER_LIMIT = 50000 constant TITLE_CHARACTER_LIMIT (line 7) | const TITLE_CHARACTER_LIMIT = 100 function fetchRegularData (line 9) | async function fetchRegularData(url: string): Promise { function fetchJinaReaderData (line 90) | async function fetchJinaReaderData(url: string): Promise FILE: lib/tools/question.ts function createQuestionTool (line 8) | function createQuestionTool(fullModel: string) { FILE: lib/tools/search.ts function createSearchTool (line 20) | function createSearchTool(fullModel: string) { type SearchUIToolInvocation (line 173) | type SearchUIToolInvocation = UIToolInvocation function search (line 175) | async function search( FILE: lib/tools/search/providers/base.ts type SearchProvider (line 3) | interface SearchProvider { method validateApiKey (line 30) | protected validateApiKey( method validateApiUrl (line 41) | protected validateApiUrl( FILE: lib/tools/search/providers/brave.ts type BraveWebResult (line 9) | interface BraveWebResult { type BraveVideoResult (line 15) | interface BraveVideoResult { type BraveImageResult (line 30) | interface BraveImageResult { class BraveSearchProvider (line 46) | class BraveSearchProvider implements SearchProvider { method constructor (line 49) | constructor() { method getImageThumbnailUrl (line 53) | private getImageThumbnailUrl(result: BraveImageResult): string { method search (line 59) | async search( method searchWeb (line 106) | private async searchWeb( method searchVideos (line 143) | private async searchVideos( method searchImages (line 190) | private async searchImages( FILE: lib/tools/search/providers/exa.ts class ExaSearchProvider (line 7) | class ExaSearchProvider extends BaseSearchProvider { method search (line 8) | async search( FILE: lib/tools/search/providers/firecrawl.ts class FirecrawlSearchProvider (line 10) | class FirecrawlSearchProvider extends BaseSearchProvider { method search (line 11) | async search( FILE: lib/tools/search/providers/index.ts type SearchProviderType (line 8) | type SearchProviderType = constant DEFAULT_PROVIDER (line 14) | const DEFAULT_PROVIDER: SearchProviderType = 'tavily' function createSearchProvider (line 16) | function createSearchProvider( FILE: lib/tools/search/providers/searxng.ts class SearXNGSearchProvider (line 10) | class SearXNGSearchProvider extends BaseSearchProvider { method search (line 11) | async search( FILE: lib/tools/search/providers/tavily.ts class TavilySearchProvider (line 6) | class TavilySearchProvider extends BaseSearchProvider { method search (line 7) | async search( FILE: lib/tools/todo.ts type TodoItem (line 18) | type TodoItem = z.infer function createTodoTools (line 30) | function createTodoTools() { FILE: lib/types/agent.ts type ResearcherTools (line 15) | type ResearcherTools = { type ResearcherAgent (line 23) | type ResearcherAgent = ToolLoopAgent type ResearcherUIMessage (line 26) | type ResearcherUIMessage = InferAgentUIMessage type ResearcherUITools (line 29) | type ResearcherUITools = InferUITools type SearchToolInvocation (line 32) | type SearchToolInvocation = UIToolInvocation type FetchToolInvocation (line 33) | type FetchToolInvocation = UIToolInvocation type QuestionToolInvocation (line 34) | type QuestionToolInvocation = UIToolInvocation< type TodoWriteToolInvocation (line 37) | type TodoWriteToolInvocation = UIToolInvocation< type ResearcherToolInvocation (line 42) | type ResearcherToolInvocation = type ResearcherToolName (line 49) | type ResearcherToolName = keyof ResearcherTools function isSearchToolInvocation (line 52) | function isSearchToolInvocation( function isFetchToolInvocation (line 58) | function isFetchToolInvocation( type ResearcherResponse (line 65) | type ResearcherResponse = Response type ResearcherRespondOptions (line 68) | type ResearcherRespondOptions = { FILE: lib/types/ai.ts type UIMessageMetadata (line 14) | interface UIMessageMetadata { type UIMessage (line 22) | type UIMessage< type RelatedQuestionsData (line 28) | interface RelatedQuestionsData { type UIDataTypes (line 33) | type UIDataTypes = { type DataRelatedQuestionsPart (line 39) | type DataRelatedQuestionsPart = { type DataPart (line 45) | type DataPart = DataRelatedQuestionsPart type UITools (line 50) | type UITools = { type ToolPart (line 59) | type ToolPart = { type Part (line 72) | type Part = TextPart | ReasoningPart | ToolPart FILE: lib/types/dynamic-tools.ts type MCPClient (line 6) | interface MCPClient { type DynamicToolConfig (line 14) | interface DynamicToolConfig { type DynamicToolPart (line 22) | type DynamicToolPart = type DynamicToolPartBase (line 28) | interface DynamicToolPartBase { type DynamicToolPartInputStreaming (line 34) | interface DynamicToolPartInputStreaming extends DynamicToolPartBase { type DynamicToolPartInputAvailable (line 39) | interface DynamicToolPartInputAvailable extends DynamicToolPartBase { type DynamicToolPartOutputAvailable (line 44) | interface DynamicToolPartOutputAvailable extends DynamicToolPartBase { type DynamicToolPartOutputError (line 50) | interface DynamicToolPartOutputError extends DynamicToolPartBase { function isDynamicToolPart (line 57) | function isDynamicToolPart(part: unknown): part is DynamicToolPart { function isToolCallPart (line 66) | function isToolCallPart( function isToolTypePart (line 77) | function isToolTypePart( FILE: lib/types/index.ts type SearchResults (line 4) | type SearchResults = { type SearchResultImage (line 16) | type SearchResultImage = type ExaSearchResults (line 24) | type ExaSearchResults = { type SerperSearchResults (line 28) | type SerperSearchResults = { type SearchResultItem (line 37) | type SearchResultItem = { type ExaSearchResultItem (line 43) | type ExaSearchResultItem = { type SerperSearchResultItem (line 52) | type SerperSearchResultItem = { type SearchImageItem (line 64) | type SearchImageItem = { type SearXNGResult (line 70) | interface SearXNGResult { type SearXNGResponse (line 79) | interface SearXNGResponse { type SearXNGImageResult (line 85) | type SearXNGImageResult = string type SearXNGSearchResults (line 87) | type SearXNGSearchResults = { type UploadedFile (line 94) | type UploadedFile = { FILE: lib/types/message-persistence.ts type Metadata (line 8) | type Metadata = z.infer type DataPart (line 12) | type DataPart = z.infer type ProviderMetadata (line 15) | type ProviderMetadata = Record type DBMessagePart (line 18) | type DBMessagePart = typeof parts.$inferInsert type DBMessagePartSelect (line 19) | type DBMessagePartSelect = typeof parts.$inferSelect type ToolState (line 22) | type ToolState = type DynamicToolInput (line 29) | type DynamicToolInput = { type DynamicToolOutput (line 34) | type DynamicToolOutput = unknown type DynamicToolType (line 37) | type DynamicToolType = 'mcp' | 'dynamic' | 'custom' type MCPGitHubInput (line 40) | type MCPGitHubInput = { type DBMessage (line 51) | type DBMessage = { type PersistableUIMessage (line 59) | type PersistableUIMessage = UIMessage & { FILE: lib/types/model-type.ts type ModelType (line 2) | type ModelType = 'speed' | 'quality' FILE: lib/types/models.ts type Model (line 1) | interface Model { FILE: lib/types/search.ts type SearchMode (line 2) | type SearchMode = 'quick' | 'adaptive' FILE: lib/utils/__tests__/model-selection.test.ts type Matrix (line 19) | type Matrix = Record>> function setMatrixImplementation (line 51) | function setMatrixImplementation() { function createCookieStore (line 57) | function createCookieStore(modelType?: string): ReadonlyRequestCookies { FILE: lib/utils/citation.ts function isValidUrl (line 8) | function isValidUrl(url: string): boolean { function extractCitationMaps (line 21) | function extractCitationMaps( function extractCitationMapsFromMessages (line 51) | function extractCitationMapsFromMessages( function processCitations (line 72) | function processCitations( FILE: lib/utils/context-window.ts type ModelContextInfo (line 6) | interface ModelContextInfo { constant MODEL_CONTEXT_WINDOWS (line 12) | const MODEL_CONTEXT_WINDOWS: Record = { constant DEFAULT_CONTEXT_WINDOW (line 37) | const DEFAULT_CONTEXT_WINDOW = 16384 constant DEFAULT_OUTPUT_TOKENS (line 38) | const DEFAULT_OUTPUT_TOKENS = 4096 constant SAFETY_BUFFER_RATIO (line 41) | const SAFETY_BUFFER_RATIO = 0.1 constant MODEL_TO_ENCODING (line 48) | const MODEL_TO_ENCODING: Record = { function getModelContextInfo (line 68) | function getModelContextInfo(modelId: string): ModelContextInfo { function getMaxAllowedTokens (line 81) | function getMaxAllowedTokens(model: Model): number { function extractTextContent (line 98) | function extractTextContent(content: ModelMessage['content']): string { function getEncoder (line 125) | function getEncoder(modelId: string) { function estimateTokenCount (line 151) | function estimateTokenCount( function truncateMessages (line 189) | function truncateMessages( function shouldTruncateMessages (line 290) | function shouldTruncateMessages( FILE: lib/utils/cookies.ts function setCookie (line 1) | function setCookie(name: string, value: string, days = 30) { function getCookie (line 10) | function getCookie(name: string): string | null { function deleteCookie (line 23) | function deleteCookie(name: string) { FILE: lib/utils/index.ts function generateUUID (line 7) | function generateUUID(): string { function cn (line 16) | function cn(...inputs: ClassValue[]) { function sanitizeUrl (line 25) | function sanitizeUrl(url: string): string { function createModelId (line 29) | function createModelId(model: Model): string { function getDefaultModelId (line 33) | function getDefaultModelId(models: Model[]): string { FILE: lib/utils/message-mapping.ts type TextUIPart (line 16) | type TextUIPart = { type: 'text'; text: string; providerMetadata?: any } type ReasoningUIPart (line 17) | type ReasoningUIPart = { type FileUIPart (line 22) | type FileUIPart = { type SourceUrlUIPart (line 28) | type SourceUrlUIPart = { type SourceDocumentUIPart (line 34) | type SourceDocumentUIPart = { type ToolCallPart (line 43) | type ToolCallPart = { type ToolResultPart (line 49) | type ToolResultPart = { type DataPart (line 55) | type DataPart = { type: string; [key: string]: any } type UIMessagePart (line 57) | type UIMessagePart = function isToolCallPart (line 68) | function isToolCallPart(part: any): part is ToolCallPart { function isToolResultPart (line 77) | function isToolResultPart(part: any): part is ToolResultPart { type ExtendedToolPart (line 86) | type ExtendedToolPart = { function isExtendedToolPart (line 95) | function isExtendedToolPart(part: any): part is ExtendedToolPart { function createToolPartMapping (line 105) | function createToolPartMapping( function mapUIMessagePartsToDBParts (line 127) | function mapUIMessagePartsToDBParts( function mapDBPartToUIMessagePart (line 344) | function mapDBPartToUIMessagePart( function getToolNameFromType (line 671) | function getToolNameFromType(toolName: string): string { function getToolNameFromCallId (line 693) | function getToolNameFromCallId( function getOriginalToolName (line 713) | function getOriginalToolName(dbToolName: string): string { function mapUIMessageToDBMessage (line 729) | function mapUIMessageToDBMessage( function buildUIMessageFromDB (line 748) | function buildUIMessageFromDB( FILE: lib/utils/message-utils.ts type DatabaseMessageInput (line 6) | interface DatabaseMessageInput { function convertMessageForDB (line 16) | function convertMessageForDB( function convertMessagesForDB (line 55) | function convertMessagesForDB( function extractTitleFromMessage (line 67) | function extractTitleFromMessage( function getTextFromParts (line 94) | function getTextFromParts(parts?: UIMessage['parts']): string { function mergeUIMessages (line 109) | function mergeUIMessages( function hasToolCalls (line 124) | function hasToolCalls(message: UIMessage | null): boolean { FILE: lib/utils/model-selection.ts constant DEFAULT_MODEL (line 9) | const DEFAULT_MODEL: Model = { constant VALID_MODEL_TYPES (line 22) | const VALID_MODEL_TYPES: ModelType[] = ['speed', 'quality'] constant MODE_FALLBACK_ORDER (line 23) | const MODE_FALLBACK_ORDER: SearchMode[] = ['quick', 'adaptive'] type ModelSelectionParams (line 25) | interface ModelSelectionParams { function resolveModelForModeAndType (line 30) | function resolveModelForModeAndType( function selectModel (line 66) | function selectModel({ FILE: lib/utils/perf-logging.ts function perfLog (line 5) | function perfLog(message: string) { function perfTime (line 11) | function perfTime(label: string, startTime: number) { FILE: lib/utils/perf-tracking.ts function resetAuthCallCount (line 17) | function resetAuthCallCount() { function incrementAuthCallCount (line 21) | function incrementAuthCallCount() { function resetDbOperationCount (line 26) | function resetDbOperationCount() { function incrementDbOperationCount (line 30) | function incrementDbOperationCount() { function resetAllCounters (line 35) | function resetAllCounters() { FILE: lib/utils/registry.ts function getModel (line 31) | function getModel(model: string): LanguageModel { function isProviderEnabled (line 37) | function isProviderEnabled(providerId: string): boolean { FILE: lib/utils/retry.ts type RetryOptions (line 3) | interface RetryOptions { function retryWithBackoff (line 11) | async function retryWithBackoff( function retryDatabaseOperation (line 54) | async function retryDatabaseOperation( FILE: lib/utils/search-config.ts function isGeneralSearchProviderAvailable (line 10) | function isGeneralSearchProviderAvailable(): boolean { function getGeneralSearchProviderName (line 17) | function getGeneralSearchProviderName(): string { function supportsMultimediaContentTypes (line 27) | function supportsMultimediaContentTypes(): boolean { function getSearchTypeDescription (line 35) | function getSearchTypeDescription(): string { function getSearchToolDescription (line 49) | function getSearchToolDescription(): string { function getContentTypesGuidance (line 62) | function getContentTypesGuidance(): string { function getSearchStrategyGuidance (line 90) | function getSearchStrategyGuidance(): string { function getGeneralSearchProviderType (line 113) | function getGeneralSearchProviderType(): 'brave' | null { FILE: lib/utils/telemetry.ts function isTracingEnabled (line 5) | function isTracingEnabled(): boolean { FILE: lib/utils/url.ts function getBaseUrlFromHeaders (line 7) | async function getBaseUrlFromHeaders(): Promise { function getBaseUrl (line 39) | async function getBaseUrl(): Promise { function getBaseUrlString (line 65) | async function getBaseUrlString(): Promise { FILE: proxy.ts function proxy (line 5) | async function proxy(request: NextRequest) { FILE: scripts/chat-cli.ts constant DEFAULT_MESSAGE (line 11) | const DEFAULT_MESSAGE = 'Hello, how are you?' type ChatApiConfig (line 13) | interface ChatApiConfig { type UIMessage (line 23) | interface UIMessage { type ChatPayload (line 35) | interface ChatPayload { class ChatApiTester (line 43) | class ChatApiTester { method validateUrl (line 46) | private validateUrl(url?: string): string | undefined { method constructor (line 85) | constructor(config: Partial = {}) { method generateId (line 98) | private generateId(): string { method createUserMessage (line 102) | private createUserMessage(text: string, messageId?: string): UIMessage { method loadCookiesFromEnv (line 120) | private loadCookiesFromEnv(): string | undefined { method sendMessage (line 128) | async sendMessage(message?: string): Promise { function parseArgs (line 312) | function parseArgs(): Partial { function main (line 427) | async function main() { FILE: scripts/test-cache-performance.ts constant API_URL (line 7) | const API_URL = process.env.API_URL || 'http://localhost:3001/api/chat' constant COOKIES (line 8) | const COOKIES = process.env.MORPHIC_COOKIES function measureRequest (line 10) | async function measureRequest( function runPerformanceTests (line 61) | async function runPerformanceTests() {