diff --git a/frontend/src/App.jsx b/frontend/src/App.jsx
index 8a57d27bb..9ef160e72 100644
--- a/frontend/src/App.jsx
+++ b/frontend/src/App.jsx
@@ -50,6 +50,9 @@ const EmbedConfigSetup = lazy(
() => import("@/pages/GeneralSettings/EmbedConfigs")
);
const EmbedChats = lazy(() => import("@/pages/GeneralSettings/EmbedChats"));
+const PrivacyAndData = lazy(
+ () => import("@/pages/GeneralSettings/PrivacyAndData")
+);
export default function App() {
return (
@@ -110,6 +113,10 @@ export default function App() {
path="/settings/security"
element={ }
/>
+ }
+ />
}
diff --git a/frontend/src/components/SettingsSidebar/index.jsx b/frontend/src/components/SettingsSidebar/index.jsx
index a7aca7ffe..66f881ff6 100644
--- a/frontend/src/components/SettingsSidebar/index.jsx
+++ b/frontend/src/components/SettingsSidebar/index.jsx
@@ -20,6 +20,7 @@ import {
CodeBlock,
Barcode,
ClosedCaptioning,
+ EyeSlash,
} from "@phosphor-icons/react";
import useUser from "@/hooks/useUser";
import { USER_BACKGROUND_COLOR } from "@/utils/constants";
@@ -349,5 +350,13 @@ const SidebarOptions = ({ user = null }) => (
flex={true}
allowedRole={["admin"]}
/>
+ }
+ user={user}
+ flex={true}
+ allowedRole={["admin"]}
+ />
>
);
diff --git a/frontend/src/pages/GeneralSettings/PrivacyAndData/index.jsx b/frontend/src/pages/GeneralSettings/PrivacyAndData/index.jsx
new file mode 100644
index 000000000..dfc4b29f9
--- /dev/null
+++ b/frontend/src/pages/GeneralSettings/PrivacyAndData/index.jsx
@@ -0,0 +1,206 @@
+import { useEffect, useState } from "react";
+import Sidebar from "@/components/SettingsSidebar";
+import { isMobile } from "react-device-detect";
+import showToast from "@/utils/toast";
+import System from "@/models/system";
+import PreLoader from "@/components/Preloader";
+import {
+ EMBEDDING_ENGINE_PRIVACY,
+ LLM_SELECTION_PRIVACY,
+ VECTOR_DB_PRIVACY,
+} from "@/pages/OnboardingFlow/Steps/DataHandling";
+
+export default function PrivacyAndDataHandling() {
+ const [settings, setSettings] = useState({});
+ const [loading, setLoading] = useState(true);
+
+ useEffect(() => {
+ async function fetchSettings() {
+ setLoading(true);
+ const settings = await System.keys();
+ setSettings(settings);
+ setLoading(false);
+ }
+ fetchSettings();
+ }, []);
+
+ return (
+
+
+
+
+
+
+
+ Privacy & Data-Handling
+
+
+
+ This is your configuration for how connected third party providers
+ and AnythingLLM handle your data.
+
+
+ {loading ? (
+
+ ) : (
+ <>
+
+
+ >
+ )}
+
+
+
+ );
+}
+
+function ThirdParty({ settings }) {
+ const llmChoice = settings?.LLMProvider || "openai";
+ const embeddingEngine = settings?.EmbeddingEngine || "openai";
+ const vectorDb = settings?.VectorDB || "pinecone";
+
+ return (
+
+
+
+
LLM Selection
+
+
+
+ {LLM_SELECTION_PRIVACY[llmChoice].name}
+
+
+
+ {LLM_SELECTION_PRIVACY[llmChoice].description.map((desc) => (
+ {desc}
+ ))}
+
+
+
+
Embedding Engine
+
+
+
+ {EMBEDDING_ENGINE_PRIVACY[embeddingEngine].name}
+
+
+
+ {EMBEDDING_ENGINE_PRIVACY[embeddingEngine].description.map(
+ (desc) => (
+ {desc}
+ )
+ )}
+
+
+
+
+
Vector Database
+
+
+
+ {VECTOR_DB_PRIVACY[vectorDb].name}
+
+
+
+ {VECTOR_DB_PRIVACY[vectorDb].description.map((desc) => (
+ {desc}
+ ))}
+
+
+
+
+ );
+}
+
+function TelemetryLogs({ settings }) {
+ const [telemetry, setTelemetry] = useState(
+ settings?.DisableTelemetry !== "true"
+ );
+ async function toggleTelemetry() {
+ await System.updateSystem({
+ DisableTelemetry: !telemetry ? "false" : "true",
+ });
+ setTelemetry(!telemetry);
+ showToast(
+ `Anonymous Telemetry has been ${!telemetry ? "enabled" : "disabled"}.`,
+ "info",
+ { clear: true }
+ );
+ }
+
+ return (
+
+
+
+
+
+
+
+ Anonymous Telemetry Enabled
+
+
+
+
+
+
+
+
+
+
+ All events do not record IP-address and contain{" "}
+ no identifying content, settings, chats, or other non-usage
+ based information. To see the list of event tags collected you can
+ look on{" "}
+
+ Github here
+
+ .
+
+
+ As an open-source project we respect your right to privacy. We are
+ dedicated to building the best solution for integrating AI and
+ documents privately and securely. If you do decide to turn off
+ telemetry all we ask is to consider sending us feedback and thoughts
+ so that we can continue to improve AnythingLLM for you.{" "}
+
+ team@mintplexlabs.com
+
+ .
+
+
+
+
+ );
+}
diff --git a/frontend/src/pages/OnboardingFlow/Steps/DataHandling/index.jsx b/frontend/src/pages/OnboardingFlow/Steps/DataHandling/index.jsx
index af3b3a9d0..bd8487842 100644
--- a/frontend/src/pages/OnboardingFlow/Steps/DataHandling/index.jsx
+++ b/frontend/src/pages/OnboardingFlow/Steps/DataHandling/index.jsx
@@ -29,7 +29,7 @@ import { useNavigate } from "react-router-dom";
const TITLE = "Data Handling & Privacy";
const DESCRIPTION =
"We are committed to transparency and control when it comes to your personal data.";
-const LLM_SELECTION_PRIVACY = {
+export const LLM_SELECTION_PRIVACY = {
openai: {
name: "OpenAI",
description: [
@@ -138,7 +138,7 @@ const LLM_SELECTION_PRIVACY = {
},
};
-const VECTOR_DB_PRIVACY = {
+export const VECTOR_DB_PRIVACY = {
chroma: {
name: "Chroma",
description: [
@@ -199,7 +199,7 @@ const VECTOR_DB_PRIVACY = {
},
};
-const EMBEDDING_ENGINE_PRIVACY = {
+export const EMBEDDING_ENGINE_PRIVACY = {
native: {
name: "AnythingLLM Embedder",
description: [
diff --git a/frontend/src/utils/paths.js b/frontend/src/utils/paths.js
index 6c8745af3..0f42e2237 100644
--- a/frontend/src/utils/paths.js
+++ b/frontend/src/utils/paths.js
@@ -113,6 +113,9 @@ export default {
logs: () => {
return "/settings/event-logs";
},
+ privacy: () => {
+ return "/settings/privacy";
+ },
embedSetup: () => {
return `/settings/embed-config`;
},
diff --git a/server/models/systemSettings.js b/server/models/systemSettings.js
index 680ecf4f7..dbf95238e 100644
--- a/server/models/systemSettings.js
+++ b/server/models/systemSettings.js
@@ -43,6 +43,7 @@ const SystemSettings = {
EmbeddingModelMaxChunkLength:
process.env.EMBEDDING_MODEL_MAX_CHUNK_LENGTH,
LocalAiApiKey: !!process.env.LOCAL_AI_API_KEY,
+ DisableTelemetry: process.env.DISABLE_TELEMETRY || "false",
...(vectorDB === "pinecone"
? {
PineConeKey: !!process.env.PINECONE_API_KEY,
diff --git a/server/utils/helpers/updateENV.js b/server/utils/helpers/updateENV.js
index d0044357e..f8e3d9cec 100644
--- a/server/utils/helpers/updateENV.js
+++ b/server/utils/helpers/updateENV.js
@@ -285,6 +285,10 @@ const KEY_MAPPING = {
envKey: "JWT_SECRET",
checks: [requiresForceMode],
},
+ DisableTelemetry: {
+ envKey: "DISABLE_TELEMETRY",
+ checks: [],
+ },
};
function isNotEmpty(input = "") {