AssistAI is a macOS application designed to enhance your productivity by indexing your files in background and enabling you to interact with them through a chat interface. It leverages the Retrieval-Augmented Generation (RAG) model to provide informative and context-aware responses. The backend functionality is powered by BubbleAI endpoints.
- File Indexing: AssistAI continuously monitors selected folders for changes, indexing new or modified files to keep the search database up-to-date.
- Chat Interface: Interact with your indexed files through a chat interface, asking questions or retrieving information directly related to your documents.
- Settings Customization: Configure which folders to index and manage other preferences through a user-friendly settings interface.
The core of AssistAI is the Ingester
class, which is responsible for indexing the files. It watches for file changes in specified directories using a FileWatcher
and processes files based on their extensions. When a new or modified file is detected, it's queued for uploading to the BubbleAI backend, where it's indexed for future retrieval. The application supports indexing for PDF files by default, but this can be extended to include other file types.
The chat functionality is implemented in the ChatView
SwiftUI view. Users can type messages or questions, which are then processed by the ChatController
. The controller interacts with the BubbleAI backend to fetch relevant information or answers based on the indexed content.
AssistAI communicates with the BubbleAI backend through the NetworkService
class, which handles various network requests, including file ingestion, deletion, and chat queries. The backend endpoints are defined in the BubbleEndpoint
enum, ensuring a structured and maintainable approach to API requests.
The application's user interface is designed to be minimalistic and intuitive. The main window, implemented in AssistWindow
, provides a transparent, draggable interface for the chat functionality. Settings and logs can be accessed through the status bar menu, constructed in the AppDelegate
class.
To use AssistAI, clone the repository and open the project in Xcode. Before running the application, ensure you have access to the BubbleAI backend and configure the necessary endpoints and authorization tokens in the BubbleEndpoint
class.
- macOS 10.15 or later
- Xcode 12.0 or later
- Clone the repository:
git clone https://github.com/CocoaPriest/AssistAI.git
- Open
AssistAI.xcodeproj
in Xcode. - Build and run the application.
To customize which folders are indexed by AssistAI, navigate to the settings menu accessible from the status bar icon. Here, you can add or remove folders from the indexing process. Changes take effect immediately, with the application starting to index the new content or stopping the indexing of removed folders.
Contributions to AssistAI are welcome. Please feel free to fork the repository, make changes, and submit pull requests. For major changes, please open an issue first to discuss what you would like to change.
Distributed under the MIT License. See LICENSE
for more information.