diff --git a/VERSION b/VERSION deleted file mode 100644 index 8a9ecc2..0000000 --- a/VERSION +++ /dev/null @@ -1 +0,0 @@ -0.0.1 \ No newline at end of file diff --git a/surfsense_backend/app/connectors/github_connector.py b/surfsense_backend/app/connectors/github_connector.py index a25bc98..6434f1e 100644 --- a/surfsense_backend/app/connectors/github_connector.py +++ b/surfsense_backend/app/connectors/github_connector.py @@ -1,6 +1,6 @@ import base64 import logging -from typing import List, Optional, Dict, Any, Tuple +from typing import List, Optional, Dict, Any from github3 import login as github_login, exceptions as github_exceptions from github3.repos.contents import Contents from github3.exceptions import ForbiddenError, NotFoundError diff --git a/surfsense_backend/app/connectors/slack_history.py b/surfsense_backend/app/connectors/slack_history.py index 1c1ec56..13e366c 100644 --- a/surfsense_backend/app/connectors/slack_history.py +++ b/surfsense_backend/app/connectors/slack_history.py @@ -5,13 +5,12 @@ A module for retrieving conversation history from Slack channels. Allows fetching channel lists and message history with date range filtering. """ -import os import time # Added import import logging # Added import from slack_sdk import WebClient from slack_sdk.errors import SlackApiError from datetime import datetime -from typing import Dict, List, Optional, Tuple, Any, Union +from typing import Dict, List, Optional, Tuple, Any logger = logging.getLogger(__name__) # Added logger diff --git a/surfsense_backend/app/connectors/test_github_connector.py b/surfsense_backend/app/connectors/test_github_connector.py index ad8a068..d55ebf3 100644 --- a/surfsense_backend/app/connectors/test_github_connector.py +++ b/surfsense_backend/app/connectors/test_github_connector.py @@ -1,5 +1,5 @@ import unittest -from unittest.mock import patch, Mock, call +from unittest.mock import patch, Mock from datetime import datetime # Adjust the import path based on the actual location if test_github_connector.py diff --git a/surfsense_backend/app/schemas/documents.py b/surfsense_backend/app/schemas/documents.py index ad8bd95..b83a749 100644 --- a/surfsense_backend/app/schemas/documents.py +++ b/surfsense_backend/app/schemas/documents.py @@ -1,4 +1,4 @@ -from typing import List, Any +from typing import List from pydantic import BaseModel, ConfigDict from app.db import DocumentType from datetime import datetime diff --git a/surfsense_backend/app/tasks/background_tasks.py b/surfsense_backend/app/tasks/background_tasks.py index 18ac291..2641895 100644 --- a/surfsense_backend/app/tasks/background_tasks.py +++ b/surfsense_backend/app/tasks/background_tasks.py @@ -6,7 +6,6 @@ from app.db import Document, DocumentType, Chunk from app.schemas import ExtensionDocumentContent from app.config import config from app.prompts import SUMMARY_PROMPT_TEMPLATE -from datetime import datetime from app.utils.document_converters import convert_document_to_markdown, generate_content_hash from langchain_core.documents import Document as LangChainDocument from langchain_community.document_loaders import FireCrawlLoader, AsyncChromiumLoader diff --git a/surfsense_backend/app/tasks/connectors_indexing_tasks.py b/surfsense_backend/app/tasks/connectors_indexing_tasks.py index 3904287..8317ac0 100644 --- a/surfsense_backend/app/tasks/connectors_indexing_tasks.py +++ b/surfsense_backend/app/tasks/connectors_indexing_tasks.py @@ -2,7 +2,6 @@ from typing import Optional, Tuple from sqlalchemy.ext.asyncio import AsyncSession from sqlalchemy.exc import SQLAlchemyError from sqlalchemy.future import select -from sqlalchemy import delete from datetime import datetime, timedelta, timezone from app.db import Document, DocumentType, Chunk, SearchSourceConnector, SearchSourceConnectorType from app.config import config @@ -15,7 +14,6 @@ from app.connectors.discord_connector import DiscordConnector from slack_sdk.errors import SlackApiError import logging import asyncio -from concurrent.futures import ThreadPoolExecutor from app.utils.document_converters import generate_content_hash diff --git a/surfsense_backend/app/utils/connector_service.py b/surfsense_backend/app/utils/connector_service.py index 6b0558f..650259b 100644 --- a/surfsense_backend/app/utils/connector_service.py +++ b/surfsense_backend/app/utils/connector_service.py @@ -1,5 +1,4 @@ -import json -from typing import List, Dict, Any, Optional, Tuple +from typing import List, Dict, Optional import asyncio from sqlalchemy.ext.asyncio import AsyncSession from sqlalchemy.future import select diff --git a/surfsense_web/app/dashboard/[search_space_id]/connectors/(manage)/page.tsx b/surfsense_web/app/dashboard/[search_space_id]/connectors/(manage)/page.tsx index 95c769c..e238e9d 100644 --- a/surfsense_web/app/dashboard/[search_space_id]/connectors/(manage)/page.tsx +++ b/surfsense_web/app/dashboard/[search_space_id]/connectors/(manage)/page.tsx @@ -7,9 +7,7 @@ import { toast } from "sonner"; import { Edit, Plus, - Search, Trash2, - ExternalLink, RefreshCw, } from "lucide-react"; @@ -19,7 +17,6 @@ import { Card, CardContent, CardDescription, - CardFooter, CardHeader, CardTitle, } from "@/components/ui/card"; diff --git a/surfsense_web/app/dashboard/[search_space_id]/documents/upload/page.tsx b/surfsense_web/app/dashboard/[search_space_id]/documents/upload/page.tsx index b8848b0..87d6b4e 100644 --- a/surfsense_web/app/dashboard/[search_space_id]/documents/upload/page.tsx +++ b/surfsense_web/app/dashboard/[search_space_id]/documents/upload/page.tsx @@ -4,7 +4,7 @@ import { useState, useCallback, useRef } from "react" import { useDropzone } from "react-dropzone" import { Button } from "@/components/ui/button" import { toast } from "sonner" -import { X, Upload, FileIcon, Tag, AlertCircle, CheckCircle2, Calendar, FileType } from "lucide-react" +import { X, Upload, Tag, CheckCircle2, Calendar, FileType } from "lucide-react" import { useRouter, useParams } from "next/navigation" import { motion, AnimatePresence } from "framer-motion" diff --git a/surfsense_web/app/dashboard/[search_space_id]/layout.tsx b/surfsense_web/app/dashboard/[search_space_id]/layout.tsx index a3c344a..93e9f2d 100644 --- a/surfsense_web/app/dashboard/[search_space_id]/layout.tsx +++ b/surfsense_web/app/dashboard/[search_space_id]/layout.tsx @@ -12,7 +12,6 @@ export default function DashboardLayout({ // Use React.use to unwrap the params Promise const { search_space_id } = use(params); - // TODO: Get search space name from our FastAPI backend const customNavSecondary = [ { title: `All Search Spaces`, @@ -80,22 +79,6 @@ export default function DashboardLayout({ items: [ ], } - // TODO: Add research synthesizer's - // { - // title: "Research Synthesizer's", - // url: `#`, - // icon: "SquareLibrary", - // items: [ - // { - // title: "Podcast Creator", - // url: `/dashboard/${search_space_id}/synthesizer/podcast`, - // }, - // { - // title: "Presentation Creator", - // url: `/dashboard/${search_space_id}/synthesizer/presentation`, - // }, - // ], - // }, ] return ( diff --git a/surfsense_web/app/dashboard/[search_space_id]/researcher/[chat_id]/page.tsx b/surfsense_web/app/dashboard/[search_space_id]/researcher/[chat_id]/page.tsx index b7963fc..aa8c33d 100644 --- a/surfsense_web/app/dashboard/[search_space_id]/researcher/[chat_id]/page.tsx +++ b/surfsense_web/app/dashboard/[search_space_id]/researcher/[chat_id]/page.tsx @@ -31,13 +31,10 @@ import { DialogFooter } from "@/components/ui/dialog"; import { - SegmentedControl, ConnectorButton as ConnectorButtonComponent, getConnectorIcon, - getMainViewSources as getMainViewSourcesUtil, getFilteredSources as getFilteredSourcesUtil, getPaginatedDialogSources as getPaginatedDialogSourcesUtil, - getSourcesCount as getSourcesCountUtil, useScrollToBottom, updateScrollIndicators as updateScrollIndicatorsUtil, useScrollIndicators, diff --git a/surfsense_web/components/chat/ScrollUtils.tsx b/surfsense_web/components/chat/ScrollUtils.tsx index 8977e90..8db7ca2 100644 --- a/surfsense_web/components/chat/ScrollUtils.tsx +++ b/surfsense_web/components/chat/ScrollUtils.tsx @@ -1,4 +1,4 @@ -import React, { RefObject, useEffect } from 'react'; +import { RefObject, useEffect } from 'react'; /** * Function to scroll to the bottom of a container diff --git a/surfsense_web/components/chat/SourceUtils.tsx b/surfsense_web/components/chat/SourceUtils.tsx index 84422d1..941ea42 100644 --- a/surfsense_web/components/chat/SourceUtils.tsx +++ b/surfsense_web/components/chat/SourceUtils.tsx @@ -1,4 +1,3 @@ -import React from 'react'; import { Source, Connector } from './types'; /** diff --git a/surfsense_web/components/sidebar/AppSidebarProvider.tsx b/surfsense_web/components/sidebar/AppSidebarProvider.tsx index 679157c..f422661 100644 --- a/surfsense_web/components/sidebar/AppSidebarProvider.tsx +++ b/surfsense_web/components/sidebar/AppSidebarProvider.tsx @@ -2,7 +2,6 @@ import { useEffect, useState } from 'react'; import { AppSidebar } from '@/components/sidebar/app-sidebar'; -import { iconMap } from '@/components/sidebar/app-sidebar'; import { Dialog, DialogContent, diff --git a/surfsense_web/components/sidebar/nav-main.tsx b/surfsense_web/components/sidebar/nav-main.tsx index 6a8446f..43b31e3 100644 --- a/surfsense_web/components/sidebar/nav-main.tsx +++ b/surfsense_web/components/sidebar/nav-main.tsx @@ -1,7 +1,6 @@ "use client" import { ChevronRight, type LucideIcon } from "lucide-react" -import Link from "next/link" import { Collapsible, diff --git a/surfsense_web/components/sidebar/nav-secondary.tsx b/surfsense_web/components/sidebar/nav-secondary.tsx index dbf6b52..5425583 100644 --- a/surfsense_web/components/sidebar/nav-secondary.tsx +++ b/surfsense_web/components/sidebar/nav-secondary.tsx @@ -5,7 +5,6 @@ import { type LucideIcon } from "lucide-react" import { SidebarGroup, - SidebarGroupContent, SidebarMenu, SidebarMenuButton, SidebarMenuItem, diff --git a/surfsense_web/components/sidebar/nav-user.tsx b/surfsense_web/components/sidebar/nav-user.tsx index 1e020f3..934a582 100644 --- a/surfsense_web/components/sidebar/nav-user.tsx +++ b/surfsense_web/components/sidebar/nav-user.tsx @@ -2,11 +2,8 @@ import { BadgeCheck, - Bell, ChevronsUpDown, - CreditCard, LogOut, - Sparkles, } from "lucide-react" import {