diff --git a/.gitmodules b/.gitmodules index 98c9a214..77533f6a 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,7 +1,7 @@ [submodule "llama.cpp-mainline"] - path = gpt4all-backend/llama.cpp-mainline + path = gpt4all-backend/deps/llama.cpp-mainline url = https://github.com/nomic-ai/llama.cpp.git branch = master [submodule "gpt4all-chat/usearch"] - path = gpt4all-chat/usearch + path = gpt4all-chat/deps/usearch url = https://github.com/nomic-ai/usearch.git diff --git a/gpt4all-backend/CMakeLists.txt b/gpt4all-backend/CMakeLists.txt index 684080ab..2c1fbb46 100644 --- a/gpt4all-backend/CMakeLists.txt +++ b/gpt4all-backend/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) # for PROJECT_IS_TOP_LEVEL +cmake_minimum_required(VERSION 3.23) # for FILE_SET set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) set(CMAKE_EXPORT_COMPILE_COMMANDS ON) @@ -47,7 +47,7 @@ else() message(STATUS "Interprocedural optimization support detected") endif() -set(DIRECTORY llama.cpp-mainline) +set(DIRECTORY deps/llama.cpp-mainline) include(llama.cpp.cmake) set(BUILD_VARIANTS) @@ -146,9 +146,12 @@ foreach(BUILD_VARIANT IN LISTS BUILD_VARIANTS) # Add each individual implementations add_library(llamamodel-mainline-${BUILD_VARIANT} SHARED - llamamodel.cpp llmodel_shared.cpp) + src/llamamodel.cpp src/llmodel_shared.cpp) target_compile_definitions(llamamodel-mainline-${BUILD_VARIANT} PRIVATE LLAMA_VERSIONS=>=3 LLAMA_DATE=999999) + target_include_directories(llamamodel-mainline-${BUILD_VARIANT} PRIVATE + src include/gpt4all-backend + ) prepare_target(llamamodel-mainline llama-mainline) if (NOT PROJECT_IS_TOP_LEVEL AND BUILD_VARIANT STREQUAL cuda) @@ -157,11 +160,19 @@ foreach(BUILD_VARIANT IN LISTS BUILD_VARIANTS) endforeach() add_library(llmodel - llmodel.h llmodel.cpp llmodel_shared.cpp - llmodel_c.h llmodel_c.cpp - dlhandle.cpp + src/dlhandle.cpp + src/llmodel.cpp + src/llmodel_c.cpp + src/llmodel_shared.cpp +) +target_sources(llmodel PUBLIC + FILE_SET public_headers TYPE HEADERS BASE_DIRS include + FILES include/gpt4all-backend/llmodel.h + include/gpt4all-backend/llmodel_c.h + include/gpt4all-backend/sysinfo.h ) target_compile_definitions(llmodel PRIVATE LIB_FILE_EXT="${CMAKE_SHARED_LIBRARY_SUFFIX}") +target_include_directories(llmodel PRIVATE src include/gpt4all-backend) set_target_properties(llmodel PROPERTIES VERSION ${PROJECT_VERSION} diff --git a/gpt4all-backend/llama.cpp-mainline b/gpt4all-backend/deps/llama.cpp-mainline similarity index 100% rename from gpt4all-backend/llama.cpp-mainline rename to gpt4all-backend/deps/llama.cpp-mainline diff --git a/gpt4all-backend/llmodel.h b/gpt4all-backend/include/gpt4all-backend/llmodel.h similarity index 100% rename from gpt4all-backend/llmodel.h rename to gpt4all-backend/include/gpt4all-backend/llmodel.h diff --git a/gpt4all-backend/llmodel_c.h b/gpt4all-backend/include/gpt4all-backend/llmodel_c.h similarity index 100% rename from gpt4all-backend/llmodel_c.h rename to gpt4all-backend/include/gpt4all-backend/llmodel_c.h diff --git a/gpt4all-backend/sysinfo.h b/gpt4all-backend/include/gpt4all-backend/sysinfo.h similarity index 100% rename from gpt4all-backend/sysinfo.h rename to gpt4all-backend/include/gpt4all-backend/sysinfo.h diff --git a/gpt4all-backend/llama.cpp.cmake b/gpt4all-backend/llama.cpp.cmake index c82668d7..5d5ceb20 100644 --- a/gpt4all-backend/llama.cpp.cmake +++ b/gpt4all-backend/llama.cpp.cmake @@ -811,7 +811,8 @@ function(include_ggml SUFFIX) list(APPEND XC_FLAGS -std=${GGML_METAL_STD}) endif() - set(GGML_METALLIB ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/default.metallib) + set(GGML_METALLIB "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/default.metallib") + set(GGML_METALLIB "${GGML_METALLIB}" PARENT_SCOPE) add_custom_command( OUTPUT ${GGML_METALLIB} COMMAND xcrun -sdk macosx metal ${XC_FLAGS} -c ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/ggml-metal.metal -o ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/ggml-metal.air @@ -822,7 +823,6 @@ function(include_ggml SUFFIX) DEPENDS ${DIRECTORY}/ggml/src/ggml-metal.metal ${DIRECTORY}/ggml/src/ggml-common.h COMMENT "Compiling Metal kernels" ) - set_source_files_properties(${GGML_METALLIB} DIRECTORY ${CMAKE_SOURCE_DIR} PROPERTIES GENERATED ON) add_custom_target( ggml-metal ALL diff --git a/gpt4all-backend/dlhandle.cpp b/gpt4all-backend/src/dlhandle.cpp similarity index 100% rename from gpt4all-backend/dlhandle.cpp rename to gpt4all-backend/src/dlhandle.cpp diff --git a/gpt4all-backend/dlhandle.h b/gpt4all-backend/src/dlhandle.h similarity index 100% rename from gpt4all-backend/dlhandle.h rename to gpt4all-backend/src/dlhandle.h diff --git a/gpt4all-backend/llamamodel.cpp b/gpt4all-backend/src/llamamodel.cpp similarity index 100% rename from gpt4all-backend/llamamodel.cpp rename to gpt4all-backend/src/llamamodel.cpp diff --git a/gpt4all-backend/llamamodel_impl.h b/gpt4all-backend/src/llamamodel_impl.h similarity index 100% rename from gpt4all-backend/llamamodel_impl.h rename to gpt4all-backend/src/llamamodel_impl.h diff --git a/gpt4all-backend/llmodel.cpp b/gpt4all-backend/src/llmodel.cpp similarity index 100% rename from gpt4all-backend/llmodel.cpp rename to gpt4all-backend/src/llmodel.cpp diff --git a/gpt4all-backend/llmodel_c.cpp b/gpt4all-backend/src/llmodel_c.cpp similarity index 100% rename from gpt4all-backend/llmodel_c.cpp rename to gpt4all-backend/src/llmodel_c.cpp diff --git a/gpt4all-backend/llmodel_shared.cpp b/gpt4all-backend/src/llmodel_shared.cpp similarity index 100% rename from gpt4all-backend/llmodel_shared.cpp rename to gpt4all-backend/src/llmodel_shared.cpp diff --git a/gpt4all-backend/llmodel_shared.h b/gpt4all-backend/src/llmodel_shared.h similarity index 100% rename from gpt4all-backend/llmodel_shared.h rename to gpt4all-backend/src/llmodel_shared.h diff --git a/gpt4all-backend/utils.cpp b/gpt4all-backend/src/utils.cpp similarity index 100% rename from gpt4all-backend/utils.cpp rename to gpt4all-backend/src/utils.cpp diff --git a/gpt4all-backend/utils.h b/gpt4all-backend/src/utils.h similarity index 100% rename from gpt4all-backend/utils.h rename to gpt4all-backend/src/utils.h diff --git a/gpt4all-chat/CMakeLists.txt b/gpt4all-chat/CMakeLists.txt index 7a96cce0..d8c92ead 100644 --- a/gpt4all-chat/CMakeLists.txt +++ b/gpt4all-chat/CMakeLists.txt @@ -70,7 +70,7 @@ set(CHAT_EXE_RESOURCES) # Metal shader library if (APPLE) - list(APPEND CHAT_EXE_RESOURCES "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/default.metallib") + list(APPEND CHAT_EXE_RESOURCES "${GGML_METALLIB}") endif() # App icon @@ -105,75 +105,11 @@ if (APPLE) list(APPEND CHAT_EXE_RESOURCES "${LOCAL_EMBEDDING_MODEL_PATH}") endif() -qt_add_executable(chat - main.cpp - chat.h chat.cpp - chatllm.h chatllm.cpp - chatmodel.h chatlistmodel.h chatlistmodel.cpp - chatapi.h chatapi.cpp - chatviewtextprocessor.h chatviewtextprocessor.cpp - database.h database.cpp - download.h download.cpp - embllm.cpp embllm.h - localdocs.h localdocs.cpp localdocsmodel.h localdocsmodel.cpp - llm.h llm.cpp - modellist.h modellist.cpp - mysettings.h mysettings.cpp - network.h network.cpp - server.h server.cpp - logger.h logger.cpp - ${APP_ICON_RESOURCE} - ${CHAT_EXE_RESOURCES} -) +add_subdirectory(src) -qt_add_qml_module(chat - URI gpt4all - VERSION 1.0 - NO_CACHEGEN - QML_FILES - main.qml - qml/AddCollectionView.qml - qml/AddModelView.qml - qml/ApplicationSettings.qml - qml/ChatDrawer.qml - qml/ChatView.qml - qml/CollectionsDrawer.qml - qml/HomeView.qml - qml/LocalDocsSettings.qml - qml/LocalDocsView.qml - qml/ModelSettings.qml - qml/ModelsView.qml - qml/NetworkDialog.qml - qml/NewVersionDialog.qml - qml/PopupDialog.qml - qml/SettingsView.qml - qml/StartupDialog.qml - qml/SwitchModelDialog.qml - qml/Theme.qml - qml/ThumbsDownDialog.qml - qml/Toast.qml - qml/ToastManager.qml - qml/MyBusyIndicator.qml - qml/MyButton.qml - qml/MyCheckBox.qml - qml/MyComboBox.qml - qml/MyDialog.qml - qml/MyDirectoryField.qml - qml/MyFancyLink.qml - qml/MyMenu.qml - qml/MyMenuItem.qml - qml/MyMiniButton.qml - qml/MySettingsButton.qml - qml/MySettingsDestructiveButton.qml - qml/MySettingsLabel.qml - qml/MySettingsStack.qml - qml/MySettingsTab.qml - qml/MySlug.qml - qml/MyTextArea.qml - qml/MyTextButton.qml - qml/MyTextField.qml - qml/MyToolButton.qml - qml/MyWelcomeButton.qml +target_sources(chat PRIVATE ${APP_ICON_RESOURCE} ${CHAT_EXE_RESOURCES}) + +qt_target_qml_sources(chat RESOURCES icons/antenna_1.svg icons/antenna_2.svg @@ -286,11 +222,13 @@ endif() target_compile_definitions(chat PRIVATE $<$,$>:QT_QML_DEBUG>) +target_include_directories(chat PRIVATE src) + # usearch uses the identifier 'slots' which conflicts with Qt's 'slots' keyword target_compile_definitions(chat PRIVATE QT_NO_SIGNALS_SLOTS_KEYWORDS) -target_include_directories(chat PRIVATE usearch/include - usearch/fp16/include) +target_include_directories(chat PRIVATE deps/usearch/include + deps/usearch/fp16/include) if(LINUX) target_link_libraries(chat diff --git a/gpt4all-chat/usearch b/gpt4all-chat/deps/usearch similarity index 100% rename from gpt4all-chat/usearch rename to gpt4all-chat/deps/usearch diff --git a/gpt4all-chat/src/CMakeLists.txt b/gpt4all-chat/src/CMakeLists.txt new file mode 100644 index 00000000..e489fd86 --- /dev/null +++ b/gpt4all-chat/src/CMakeLists.txt @@ -0,0 +1,72 @@ +set_source_files_properties("${GGML_METALLIB}" PROPERTIES GENERATED ON) + +qt_add_executable(chat + main.cpp + chat.cpp chat.h + chatapi.cpp chatapi.h + chatlistmodel.cpp chatlistmodel.h + chatllm.cpp chatllm.h + chatmodel.h + chatviewtextprocessor.cpp chatviewtextprocessor.h + database.cpp database.h + download.cpp download.h + embllm.cpp embllm.h + llm.cpp llm.h + localdocs.cpp localdocs.h + localdocsmodel.cpp localdocsmodel.h + logger.cpp logger.h + modellist.cpp modellist.h + mysettings.cpp mysettings.h + network.cpp network.h + server.cpp server.h +) + +qt_add_qml_module(chat + URI gpt4all + VERSION 1.0 + NO_CACHEGEN + QML_FILES + main.qml + qml/AddCollectionView.qml + qml/AddModelView.qml + qml/ApplicationSettings.qml + qml/ChatDrawer.qml + qml/ChatView.qml + qml/CollectionsDrawer.qml + qml/HomeView.qml + qml/LocalDocsSettings.qml + qml/LocalDocsView.qml + qml/ModelSettings.qml + qml/ModelsView.qml + qml/NetworkDialog.qml + qml/NewVersionDialog.qml + qml/PopupDialog.qml + qml/SettingsView.qml + qml/StartupDialog.qml + qml/SwitchModelDialog.qml + qml/Theme.qml + qml/ThumbsDownDialog.qml + qml/Toast.qml + qml/ToastManager.qml + qml/MyBusyIndicator.qml + qml/MyButton.qml + qml/MyCheckBox.qml + qml/MyComboBox.qml + qml/MyDialog.qml + qml/MyDirectoryField.qml + qml/MyFancyLink.qml + qml/MyMenu.qml + qml/MyMenuItem.qml + qml/MyMiniButton.qml + qml/MySettingsButton.qml + qml/MySettingsDestructiveButton.qml + qml/MySettingsLabel.qml + qml/MySettingsStack.qml + qml/MySettingsTab.qml + qml/MySlug.qml + qml/MyTextArea.qml + qml/MyTextButton.qml + qml/MyTextField.qml + qml/MyToolButton.qml + qml/MyWelcomeButton.qml +) diff --git a/gpt4all-chat/chat.cpp b/gpt4all-chat/src/chat.cpp similarity index 100% rename from gpt4all-chat/chat.cpp rename to gpt4all-chat/src/chat.cpp diff --git a/gpt4all-chat/chat.h b/gpt4all-chat/src/chat.h similarity index 100% rename from gpt4all-chat/chat.h rename to gpt4all-chat/src/chat.h diff --git a/gpt4all-chat/chatapi.cpp b/gpt4all-chat/src/chatapi.cpp similarity index 99% rename from gpt4all-chat/chatapi.cpp rename to gpt4all-chat/src/chatapi.cpp index b443f24c..06594a32 100644 --- a/gpt4all-chat/chatapi.cpp +++ b/gpt4all-chat/src/chatapi.cpp @@ -1,6 +1,6 @@ #include "chatapi.h" -#include "../gpt4all-backend/llmodel.h" +#include #include #include diff --git a/gpt4all-chat/chatapi.h b/gpt4all-chat/src/chatapi.h similarity index 99% rename from gpt4all-chat/chatapi.h rename to gpt4all-chat/src/chatapi.h index 59b68f58..724178de 100644 --- a/gpt4all-chat/chatapi.h +++ b/gpt4all-chat/src/chatapi.h @@ -1,7 +1,7 @@ #ifndef CHATAPI_H #define CHATAPI_H -#include "../gpt4all-backend/llmodel.h" +#include #include #include diff --git a/gpt4all-chat/chatlistmodel.cpp b/gpt4all-chat/src/chatlistmodel.cpp similarity index 100% rename from gpt4all-chat/chatlistmodel.cpp rename to gpt4all-chat/src/chatlistmodel.cpp diff --git a/gpt4all-chat/chatlistmodel.h b/gpt4all-chat/src/chatlistmodel.h similarity index 100% rename from gpt4all-chat/chatlistmodel.h rename to gpt4all-chat/src/chatlistmodel.h diff --git a/gpt4all-chat/chatllm.cpp b/gpt4all-chat/src/chatllm.cpp similarity index 100% rename from gpt4all-chat/chatllm.cpp rename to gpt4all-chat/src/chatllm.cpp diff --git a/gpt4all-chat/chatllm.h b/gpt4all-chat/src/chatllm.h similarity index 99% rename from gpt4all-chat/chatllm.h rename to gpt4all-chat/src/chatllm.h index d123358a..eb8d044f 100644 --- a/gpt4all-chat/chatllm.h +++ b/gpt4all-chat/src/chatllm.h @@ -4,7 +4,7 @@ #include "database.h" // IWYU pragma: keep #include "modellist.h" -#include "../gpt4all-backend/llmodel.h" +#include #include #include diff --git a/gpt4all-chat/chatmodel.h b/gpt4all-chat/src/chatmodel.h similarity index 100% rename from gpt4all-chat/chatmodel.h rename to gpt4all-chat/src/chatmodel.h diff --git a/gpt4all-chat/chatviewtextprocessor.cpp b/gpt4all-chat/src/chatviewtextprocessor.cpp similarity index 100% rename from gpt4all-chat/chatviewtextprocessor.cpp rename to gpt4all-chat/src/chatviewtextprocessor.cpp diff --git a/gpt4all-chat/chatviewtextprocessor.h b/gpt4all-chat/src/chatviewtextprocessor.h similarity index 100% rename from gpt4all-chat/chatviewtextprocessor.h rename to gpt4all-chat/src/chatviewtextprocessor.h diff --git a/gpt4all-chat/database.cpp b/gpt4all-chat/src/database.cpp similarity index 100% rename from gpt4all-chat/database.cpp rename to gpt4all-chat/src/database.cpp diff --git a/gpt4all-chat/database.h b/gpt4all-chat/src/database.h similarity index 100% rename from gpt4all-chat/database.h rename to gpt4all-chat/src/database.h diff --git a/gpt4all-chat/download.cpp b/gpt4all-chat/src/download.cpp similarity index 100% rename from gpt4all-chat/download.cpp rename to gpt4all-chat/src/download.cpp diff --git a/gpt4all-chat/download.h b/gpt4all-chat/src/download.h similarity index 100% rename from gpt4all-chat/download.h rename to gpt4all-chat/src/download.h diff --git a/gpt4all-chat/embllm.cpp b/gpt4all-chat/src/embllm.cpp similarity index 99% rename from gpt4all-chat/embllm.cpp rename to gpt4all-chat/src/embllm.cpp index 615a6ce4..81b1e9e1 100644 --- a/gpt4all-chat/embllm.cpp +++ b/gpt4all-chat/src/embllm.cpp @@ -3,7 +3,7 @@ #include "modellist.h" #include "mysettings.h" -#include "../gpt4all-backend/llmodel.h" +#include #include #include diff --git a/gpt4all-chat/embllm.h b/gpt4all-chat/src/embllm.h similarity index 100% rename from gpt4all-chat/embllm.h rename to gpt4all-chat/src/embllm.h diff --git a/gpt4all-chat/llm.cpp b/gpt4all-chat/src/llm.cpp similarity index 97% rename from gpt4all-chat/llm.cpp rename to gpt4all-chat/src/llm.cpp index c8a3c3fe..aed1a7db 100644 --- a/gpt4all-chat/llm.cpp +++ b/gpt4all-chat/src/llm.cpp @@ -1,7 +1,7 @@ #include "llm.h" -#include "../gpt4all-backend/llmodel.h" -#include "../gpt4all-backend/sysinfo.h" +#include +#include #include #include diff --git a/gpt4all-chat/llm.h b/gpt4all-chat/src/llm.h similarity index 100% rename from gpt4all-chat/llm.h rename to gpt4all-chat/src/llm.h diff --git a/gpt4all-chat/localdocs.cpp b/gpt4all-chat/src/localdocs.cpp similarity index 100% rename from gpt4all-chat/localdocs.cpp rename to gpt4all-chat/src/localdocs.cpp diff --git a/gpt4all-chat/localdocs.h b/gpt4all-chat/src/localdocs.h similarity index 100% rename from gpt4all-chat/localdocs.h rename to gpt4all-chat/src/localdocs.h diff --git a/gpt4all-chat/localdocsmodel.cpp b/gpt4all-chat/src/localdocsmodel.cpp similarity index 100% rename from gpt4all-chat/localdocsmodel.cpp rename to gpt4all-chat/src/localdocsmodel.cpp diff --git a/gpt4all-chat/localdocsmodel.h b/gpt4all-chat/src/localdocsmodel.h similarity index 100% rename from gpt4all-chat/localdocsmodel.h rename to gpt4all-chat/src/localdocsmodel.h diff --git a/gpt4all-chat/logger.cpp b/gpt4all-chat/src/logger.cpp similarity index 100% rename from gpt4all-chat/logger.cpp rename to gpt4all-chat/src/logger.cpp diff --git a/gpt4all-chat/logger.h b/gpt4all-chat/src/logger.h similarity index 100% rename from gpt4all-chat/logger.h rename to gpt4all-chat/src/logger.h diff --git a/gpt4all-chat/main.cpp b/gpt4all-chat/src/main.cpp similarity index 98% rename from gpt4all-chat/main.cpp rename to gpt4all-chat/src/main.cpp index 49f1ea3a..8521f4ea 100644 --- a/gpt4all-chat/main.cpp +++ b/gpt4all-chat/src/main.cpp @@ -8,7 +8,7 @@ #include "mysettings.h" #include "network.h" -#include "../gpt4all-backend/llmodel.h" +#include #include #include diff --git a/gpt4all-chat/main.qml b/gpt4all-chat/src/main.qml similarity index 100% rename from gpt4all-chat/main.qml rename to gpt4all-chat/src/main.qml diff --git a/gpt4all-chat/modellist.cpp b/gpt4all-chat/src/modellist.cpp similarity index 99% rename from gpt4all-chat/modellist.cpp rename to gpt4all-chat/src/modellist.cpp index 580b615f..13711057 100644 --- a/gpt4all-chat/modellist.cpp +++ b/gpt4all-chat/src/modellist.cpp @@ -4,7 +4,7 @@ #include "mysettings.h" #include "network.h" -#include "../gpt4all-backend/llmodel.h" +#include #include #include diff --git a/gpt4all-chat/modellist.h b/gpt4all-chat/src/modellist.h similarity index 100% rename from gpt4all-chat/modellist.h rename to gpt4all-chat/src/modellist.h diff --git a/gpt4all-chat/mysettings.cpp b/gpt4all-chat/src/mysettings.cpp similarity index 99% rename from gpt4all-chat/mysettings.cpp rename to gpt4all-chat/src/mysettings.cpp index 525ccc1e..29354382 100644 --- a/gpt4all-chat/mysettings.cpp +++ b/gpt4all-chat/src/mysettings.cpp @@ -1,6 +1,6 @@ #include "mysettings.h" -#include "../gpt4all-backend/llmodel.h" +#include #include #include diff --git a/gpt4all-chat/mysettings.h b/gpt4all-chat/src/mysettings.h similarity index 100% rename from gpt4all-chat/mysettings.h rename to gpt4all-chat/src/mysettings.h diff --git a/gpt4all-chat/network.cpp b/gpt4all-chat/src/network.cpp similarity index 99% rename from gpt4all-chat/network.cpp rename to gpt4all-chat/src/network.cpp index e7ee616c..19e96a10 100644 --- a/gpt4all-chat/network.cpp +++ b/gpt4all-chat/src/network.cpp @@ -9,7 +9,7 @@ #include "modellist.h" #include "mysettings.h" -#include "../gpt4all-backend/llmodel.h" +#include #include #include diff --git a/gpt4all-chat/network.h b/gpt4all-chat/src/network.h similarity index 100% rename from gpt4all-chat/network.h rename to gpt4all-chat/src/network.h diff --git a/gpt4all-chat/qml/AddCollectionView.qml b/gpt4all-chat/src/qml/AddCollectionView.qml similarity index 100% rename from gpt4all-chat/qml/AddCollectionView.qml rename to gpt4all-chat/src/qml/AddCollectionView.qml diff --git a/gpt4all-chat/qml/AddModelView.qml b/gpt4all-chat/src/qml/AddModelView.qml similarity index 100% rename from gpt4all-chat/qml/AddModelView.qml rename to gpt4all-chat/src/qml/AddModelView.qml diff --git a/gpt4all-chat/qml/ApplicationSettings.qml b/gpt4all-chat/src/qml/ApplicationSettings.qml similarity index 100% rename from gpt4all-chat/qml/ApplicationSettings.qml rename to gpt4all-chat/src/qml/ApplicationSettings.qml diff --git a/gpt4all-chat/qml/ChatDrawer.qml b/gpt4all-chat/src/qml/ChatDrawer.qml similarity index 100% rename from gpt4all-chat/qml/ChatDrawer.qml rename to gpt4all-chat/src/qml/ChatDrawer.qml diff --git a/gpt4all-chat/qml/ChatView.qml b/gpt4all-chat/src/qml/ChatView.qml similarity index 100% rename from gpt4all-chat/qml/ChatView.qml rename to gpt4all-chat/src/qml/ChatView.qml diff --git a/gpt4all-chat/qml/CollectionsDrawer.qml b/gpt4all-chat/src/qml/CollectionsDrawer.qml similarity index 100% rename from gpt4all-chat/qml/CollectionsDrawer.qml rename to gpt4all-chat/src/qml/CollectionsDrawer.qml diff --git a/gpt4all-chat/qml/HomeView.qml b/gpt4all-chat/src/qml/HomeView.qml similarity index 100% rename from gpt4all-chat/qml/HomeView.qml rename to gpt4all-chat/src/qml/HomeView.qml diff --git a/gpt4all-chat/qml/LocalDocsSettings.qml b/gpt4all-chat/src/qml/LocalDocsSettings.qml similarity index 100% rename from gpt4all-chat/qml/LocalDocsSettings.qml rename to gpt4all-chat/src/qml/LocalDocsSettings.qml diff --git a/gpt4all-chat/qml/LocalDocsView.qml b/gpt4all-chat/src/qml/LocalDocsView.qml similarity index 100% rename from gpt4all-chat/qml/LocalDocsView.qml rename to gpt4all-chat/src/qml/LocalDocsView.qml diff --git a/gpt4all-chat/qml/ModelSettings.qml b/gpt4all-chat/src/qml/ModelSettings.qml similarity index 100% rename from gpt4all-chat/qml/ModelSettings.qml rename to gpt4all-chat/src/qml/ModelSettings.qml diff --git a/gpt4all-chat/qml/ModelsView.qml b/gpt4all-chat/src/qml/ModelsView.qml similarity index 100% rename from gpt4all-chat/qml/ModelsView.qml rename to gpt4all-chat/src/qml/ModelsView.qml diff --git a/gpt4all-chat/qml/MyBusyIndicator.qml b/gpt4all-chat/src/qml/MyBusyIndicator.qml similarity index 100% rename from gpt4all-chat/qml/MyBusyIndicator.qml rename to gpt4all-chat/src/qml/MyBusyIndicator.qml diff --git a/gpt4all-chat/qml/MyButton.qml b/gpt4all-chat/src/qml/MyButton.qml similarity index 100% rename from gpt4all-chat/qml/MyButton.qml rename to gpt4all-chat/src/qml/MyButton.qml diff --git a/gpt4all-chat/qml/MyCheckBox.qml b/gpt4all-chat/src/qml/MyCheckBox.qml similarity index 100% rename from gpt4all-chat/qml/MyCheckBox.qml rename to gpt4all-chat/src/qml/MyCheckBox.qml diff --git a/gpt4all-chat/qml/MyComboBox.qml b/gpt4all-chat/src/qml/MyComboBox.qml similarity index 100% rename from gpt4all-chat/qml/MyComboBox.qml rename to gpt4all-chat/src/qml/MyComboBox.qml diff --git a/gpt4all-chat/qml/MyDialog.qml b/gpt4all-chat/src/qml/MyDialog.qml similarity index 100% rename from gpt4all-chat/qml/MyDialog.qml rename to gpt4all-chat/src/qml/MyDialog.qml diff --git a/gpt4all-chat/qml/MyDirectoryField.qml b/gpt4all-chat/src/qml/MyDirectoryField.qml similarity index 100% rename from gpt4all-chat/qml/MyDirectoryField.qml rename to gpt4all-chat/src/qml/MyDirectoryField.qml diff --git a/gpt4all-chat/qml/MyFancyLink.qml b/gpt4all-chat/src/qml/MyFancyLink.qml similarity index 100% rename from gpt4all-chat/qml/MyFancyLink.qml rename to gpt4all-chat/src/qml/MyFancyLink.qml diff --git a/gpt4all-chat/qml/MyMenu.qml b/gpt4all-chat/src/qml/MyMenu.qml similarity index 100% rename from gpt4all-chat/qml/MyMenu.qml rename to gpt4all-chat/src/qml/MyMenu.qml diff --git a/gpt4all-chat/qml/MyMenuItem.qml b/gpt4all-chat/src/qml/MyMenuItem.qml similarity index 100% rename from gpt4all-chat/qml/MyMenuItem.qml rename to gpt4all-chat/src/qml/MyMenuItem.qml diff --git a/gpt4all-chat/qml/MyMiniButton.qml b/gpt4all-chat/src/qml/MyMiniButton.qml similarity index 100% rename from gpt4all-chat/qml/MyMiniButton.qml rename to gpt4all-chat/src/qml/MyMiniButton.qml diff --git a/gpt4all-chat/qml/MySettingsButton.qml b/gpt4all-chat/src/qml/MySettingsButton.qml similarity index 100% rename from gpt4all-chat/qml/MySettingsButton.qml rename to gpt4all-chat/src/qml/MySettingsButton.qml diff --git a/gpt4all-chat/qml/MySettingsDestructiveButton.qml b/gpt4all-chat/src/qml/MySettingsDestructiveButton.qml similarity index 100% rename from gpt4all-chat/qml/MySettingsDestructiveButton.qml rename to gpt4all-chat/src/qml/MySettingsDestructiveButton.qml diff --git a/gpt4all-chat/qml/MySettingsLabel.qml b/gpt4all-chat/src/qml/MySettingsLabel.qml similarity index 100% rename from gpt4all-chat/qml/MySettingsLabel.qml rename to gpt4all-chat/src/qml/MySettingsLabel.qml diff --git a/gpt4all-chat/qml/MySettingsStack.qml b/gpt4all-chat/src/qml/MySettingsStack.qml similarity index 100% rename from gpt4all-chat/qml/MySettingsStack.qml rename to gpt4all-chat/src/qml/MySettingsStack.qml diff --git a/gpt4all-chat/qml/MySettingsTab.qml b/gpt4all-chat/src/qml/MySettingsTab.qml similarity index 100% rename from gpt4all-chat/qml/MySettingsTab.qml rename to gpt4all-chat/src/qml/MySettingsTab.qml diff --git a/gpt4all-chat/qml/MySlug.qml b/gpt4all-chat/src/qml/MySlug.qml similarity index 100% rename from gpt4all-chat/qml/MySlug.qml rename to gpt4all-chat/src/qml/MySlug.qml diff --git a/gpt4all-chat/qml/MyTextArea.qml b/gpt4all-chat/src/qml/MyTextArea.qml similarity index 100% rename from gpt4all-chat/qml/MyTextArea.qml rename to gpt4all-chat/src/qml/MyTextArea.qml diff --git a/gpt4all-chat/qml/MyTextButton.qml b/gpt4all-chat/src/qml/MyTextButton.qml similarity index 100% rename from gpt4all-chat/qml/MyTextButton.qml rename to gpt4all-chat/src/qml/MyTextButton.qml diff --git a/gpt4all-chat/qml/MyTextField.qml b/gpt4all-chat/src/qml/MyTextField.qml similarity index 100% rename from gpt4all-chat/qml/MyTextField.qml rename to gpt4all-chat/src/qml/MyTextField.qml diff --git a/gpt4all-chat/qml/MyToolButton.qml b/gpt4all-chat/src/qml/MyToolButton.qml similarity index 100% rename from gpt4all-chat/qml/MyToolButton.qml rename to gpt4all-chat/src/qml/MyToolButton.qml diff --git a/gpt4all-chat/qml/MyWelcomeButton.qml b/gpt4all-chat/src/qml/MyWelcomeButton.qml similarity index 100% rename from gpt4all-chat/qml/MyWelcomeButton.qml rename to gpt4all-chat/src/qml/MyWelcomeButton.qml diff --git a/gpt4all-chat/qml/NetworkDialog.qml b/gpt4all-chat/src/qml/NetworkDialog.qml similarity index 100% rename from gpt4all-chat/qml/NetworkDialog.qml rename to gpt4all-chat/src/qml/NetworkDialog.qml diff --git a/gpt4all-chat/qml/NewVersionDialog.qml b/gpt4all-chat/src/qml/NewVersionDialog.qml similarity index 100% rename from gpt4all-chat/qml/NewVersionDialog.qml rename to gpt4all-chat/src/qml/NewVersionDialog.qml diff --git a/gpt4all-chat/qml/PopupDialog.qml b/gpt4all-chat/src/qml/PopupDialog.qml similarity index 100% rename from gpt4all-chat/qml/PopupDialog.qml rename to gpt4all-chat/src/qml/PopupDialog.qml diff --git a/gpt4all-chat/qml/SettingsView.qml b/gpt4all-chat/src/qml/SettingsView.qml similarity index 100% rename from gpt4all-chat/qml/SettingsView.qml rename to gpt4all-chat/src/qml/SettingsView.qml diff --git a/gpt4all-chat/qml/StartupDialog.qml b/gpt4all-chat/src/qml/StartupDialog.qml similarity index 100% rename from gpt4all-chat/qml/StartupDialog.qml rename to gpt4all-chat/src/qml/StartupDialog.qml diff --git a/gpt4all-chat/qml/SwitchModelDialog.qml b/gpt4all-chat/src/qml/SwitchModelDialog.qml similarity index 100% rename from gpt4all-chat/qml/SwitchModelDialog.qml rename to gpt4all-chat/src/qml/SwitchModelDialog.qml diff --git a/gpt4all-chat/qml/Theme.qml b/gpt4all-chat/src/qml/Theme.qml similarity index 100% rename from gpt4all-chat/qml/Theme.qml rename to gpt4all-chat/src/qml/Theme.qml diff --git a/gpt4all-chat/qml/ThumbsDownDialog.qml b/gpt4all-chat/src/qml/ThumbsDownDialog.qml similarity index 100% rename from gpt4all-chat/qml/ThumbsDownDialog.qml rename to gpt4all-chat/src/qml/ThumbsDownDialog.qml diff --git a/gpt4all-chat/qml/Toast.qml b/gpt4all-chat/src/qml/Toast.qml similarity index 100% rename from gpt4all-chat/qml/Toast.qml rename to gpt4all-chat/src/qml/Toast.qml diff --git a/gpt4all-chat/qml/ToastManager.qml b/gpt4all-chat/src/qml/ToastManager.qml similarity index 100% rename from gpt4all-chat/qml/ToastManager.qml rename to gpt4all-chat/src/qml/ToastManager.qml diff --git a/gpt4all-chat/server.cpp b/gpt4all-chat/src/server.cpp similarity index 100% rename from gpt4all-chat/server.cpp rename to gpt4all-chat/src/server.cpp diff --git a/gpt4all-chat/server.h b/gpt4all-chat/src/server.h similarity index 100% rename from gpt4all-chat/server.h rename to gpt4all-chat/src/server.h