diff --git a/frontend/src/components/WorkspaceChat/ChatContainer/ChatHistory/FileDownloadCard/index.jsx b/frontend/src/components/WorkspaceChat/ChatContainer/ChatHistory/FileDownloadCard/index.jsx
new file mode 100644
index 000000000..f43c3b585
--- /dev/null
+++ b/frontend/src/components/WorkspaceChat/ChatContainer/ChatHistory/FileDownloadCard/index.jsx
@@ -0,0 +1,126 @@
+import { memo, useState } from "react";
+import { saveAs } from "file-saver";
+import { DownloadSimple, CircleNotch } from "@phosphor-icons/react";
+import { humanFileSize } from "@/utils/numbers";
+import StorageFiles from "@/models/files";
+
+/**
+ * @param {{content: {filename: string, storageFilename?: string, fileSize?: number}}} props
+ */
+function FileDownloadCard({ props }) {
+ const { filename, storageFilename, fileSize } = props.content || {};
+ const { badge, badgeBg, badgeText, fileType } = getFileDisplayInfo(filename);
+ const [downloading, setDownloading] = useState(false);
+
+ const handleDownload = async () => {
+ if (downloading) return;
+ if (!storageFilename) return;
+
+ setDownloading(true);
+ try {
+ const blob = await StorageFiles.download(storageFilename);
+ if (!blob) throw new Error("Failed to download file");
+ saveAs(blob, filename || storageFilename);
+ } catch {
+ console.error("Failed to download file");
+ } finally {
+ setDownloading(false);
+ }
+ };
+
+ return (
+
diff --git a/frontend/src/components/WorkspaceChat/ChatContainer/ChatHistory/index.jsx b/frontend/src/components/WorkspaceChat/ChatContainer/ChatHistory/index.jsx
index aa615559b..5f60fd3ed 100644
--- a/frontend/src/components/WorkspaceChat/ChatContainer/ChatHistory/index.jsx
+++ b/frontend/src/components/WorkspaceChat/ChatContainer/ChatHistory/index.jsx
@@ -10,6 +10,7 @@ import HistoricalMessage from "./HistoricalMessage";
import PromptReply from "./PromptReply";
import StatusResponse from "./StatusResponse";
import ToolApprovalRequest from "./ToolApprovalRequest";
+import FileDownloadCard from "./FileDownloadCard";
import { useManageWorkspaceModal } from "../../../Modals/ManageWorkspace";
import ManageWorkspace from "../../../Modals/ManageWorkspace";
import { ArrowDown } from "@phosphor-icons/react";
@@ -307,6 +308,8 @@ function buildMessages({
if (props.type === "rechartVisualize" && !!props.content) {
acc.push(
);
+ } else if (props.type === "fileDownloadCard" && !!props.content) {
+ acc.push(
);
} else if (isLastBotReply && props.animate) {
acc.push(
);
}
diff --git a/frontend/src/locales/ar/common.js b/frontend/src/locales/ar/common.js
index f276c92a2..540e258ea 100644
--- a/frontend/src/locales/ar/common.js
+++ b/frontend/src/locales/ar/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "مرحبا في",
getStarted: "بسم الله",
welcome: "أهلاً وسهلاً",
},
@@ -308,11 +307,6 @@ const TRANSLATIONS = {
description:
"تمكين الوكيل الافتراضي لإنشاء أنواع مختلفة من المخططات من البيانات المقدمة أو المعطاة في المحادثة.",
},
- save: {
- title: "إنشاء الملفات وحفظها في المتصفح",
- description:
- "تمكين الوكيل الافتراضي من إنشاء الملفات والكتابة عليها وحفظها و تنزيلها في متصفحك.",
- },
web: {
title: "البحث والتصفح المباشر على الويب",
description:
@@ -357,10 +351,6 @@ const TRANSLATIONS = {
title: "الحصول على معلومات الملف",
description: "احصل على بيانات وصف تفصيلية حول الملفات.",
},
- "write-file": {
- title: "إنشاء ملف",
- description: "إنشاء ملفات جديدة أو استبدال الملفات الموجودة.",
- },
"edit-file": {
title: "تحرير الملف",
description:
@@ -378,6 +368,43 @@ const TRANSLATIONS = {
title: "نسخ الملف",
description: "نسخ الملفات والمجلدات",
},
+ "write-text-file": {
+ title: "إنشاء ملف نصي",
+ description:
+ "إنشاء ملفات نصية جديدة أو استبدال الملفات النصية الموجودة.",
+ },
+ },
+ },
+ createFiles: {
+ title: "إنشاء المستندات",
+ description:
+ "اسمح لمسؤولك بإنشاء ملفات بتنسيقات ثنائية مثل عروض PowerPoint وجداول Excel ووثائق Word وملفات PDF. يمكن تنزيل الملفات مباشرة من نافذة الدردشة.",
+ configuration: "أنواع المستندات المتاحة",
+ skills: {
+ "create-text-file": {
+ title: "ملفات النصوص",
+ description:
+ "إنشاء ملفات نصية تحتوي على أي محتوى وتنسيق (مثل .txt، .md، .json، .csv، إلخ).",
+ },
+ "create-pptx": {
+ title: "عروض تقديمية باستخدام برنامج باوربوينت",
+ description:
+ "إنشاء عروض تقديمية جديدة باستخدام برنامج باوربوينت، تتضمن الشرائح والعناوين والنقاط.",
+ },
+ "create-pdf": {
+ title: "ملفات PDF",
+ description:
+ "إنشاء مستندات PDF من ملفات Markdown أو النصوص البسيطة مع تنسيق أساسي.",
+ },
+ "create-xlsx": {
+ title: "جداول بيانات في برنامج إكسل",
+ description:
+ "إنشاء مستندات Excel للبيانات الجدولية مع الأوراق والتصميم.",
+ },
+ "create-docx": {
+ title: "ملفات مستندات مايكروسوفت",
+ description: "إنشاء مستندات Word مع تنسيق وتصميم أساسي.",
+ },
},
},
},
@@ -694,7 +721,6 @@ const TRANSLATIONS = {
select_all: "حدد الكل",
deselect_all: "إلغاء التحديد الكل",
remove_selected: "حذف المحدد",
- costs: "*تكلفة ثابتة لإنشاء التمثيلات",
save_embed: "حفظ و تضمين",
"total-documents_one": "{{count}}",
"total-documents_other": "{{count}} المستندات",
diff --git a/frontend/src/locales/cs/common.js b/frontend/src/locales/cs/common.js
index b5e962993..222a532b1 100644
--- a/frontend/src/locales/cs/common.js
+++ b/frontend/src/locales/cs/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "Vítejte v",
getStarted: "Začít",
welcome: "Vítejte",
},
@@ -324,11 +323,6 @@ const TRANSLATIONS = {
description:
"Umožněte výchozímu agentovi generovat různé typy grafů z dat poskytnutých nebo uvedených v chatu.",
},
- save: {
- title: "Generovat a ukládat soubory",
- description:
- "Umožněte výchozímu agentovi generovat a zapisovat do souborů, které lze uložit do počítače.",
- },
web: {
title: "Živé webové vyhledávání a prohlížení",
description:
@@ -373,11 +367,6 @@ const TRANSLATIONS = {
title: "Získejte informace o souboru",
description: "Získejte podrobné metadatumy o souborech.",
},
- "write-file": {
- title: "Vytvoř soubor",
- description:
- "Vytvořte nové soubory nebo přepsat stávající soubory.",
- },
"edit-file": {
title: "Upravit soubor",
description:
@@ -395,6 +384,44 @@ const TRANSLATIONS = {
title: "Zkopírovat soubor",
description: "Zkopírujte soubory a adresáře",
},
+ "write-text-file": {
+ title: "Vytvořte soubor s textem",
+ description:
+ "Vytvořte nové textové soubory nebo přepsáním existujících textových souborů.",
+ },
+ },
+ },
+ createFiles: {
+ title: "Vytváření dokumentů",
+ description:
+ "Umožněte svému zástupci vytvářet soubory ve formátech jako PowerPoint prezentace, tabulky v Excelu, dokumenty ve formátu Word a soubory ve formátu PDF. Soubory lze stahovat přímo z chatu.",
+ configuration: "Dostupné typy dokumentů",
+ skills: {
+ "create-text-file": {
+ title: "Soubory v textovém formátu",
+ description:
+ "Vytvořte textové soubory s libovolným obsahem a příponou (např. .txt, .md, .json, .csv atd.)",
+ },
+ "create-pptx": {
+ title: "Prezentace v PowerPointu",
+ description:
+ "Vytvořte nové prezentace v programu PowerPoint, včetně slidů, nadpisů a odrážek.",
+ },
+ "create-pdf": {
+ title: "Dokumenty ve formátu PDF",
+ description:
+ "Vytvořte PDF dokumenty z Markdownu nebo jednoduchého textu s základním formátováním.",
+ },
+ "create-xlsx": {
+ title: "Tabulky v programu Excel",
+ description:
+ "Vytvořte tabulkové dokumenty v programu Excel, které budou obsahovat listy a stylování.",
+ },
+ "create-docx": {
+ title: "Dokumenty ve formátu Word",
+ description:
+ "Vytvořte dokumenty ve formátu Word s základním formátováním a stylováním.",
+ },
},
},
},
@@ -833,7 +860,6 @@ const TRANSLATIONS = {
select_all: "Vybrat vše",
deselect_all: "Zrušit výběr všeho",
remove_selected: "Odebrat vybrané",
- costs: "*Jednorázové náklady pro embeddingy",
save_embed: "Uložit a vložit",
"total-documents_one": "{{count}} dokument",
"total-documents_other": "{{count}} dokumenty",
diff --git a/frontend/src/locales/da/common.js b/frontend/src/locales/da/common.js
index a6b2e3d2d..d51599e5c 100644
--- a/frontend/src/locales/da/common.js
+++ b/frontend/src/locales/da/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "Velkommen til",
getStarted: "Kom godt i gang",
welcome: "Velkommen",
},
@@ -312,11 +311,6 @@ const TRANSLATIONS = {
description:
"Gør det muligt for standardagenten at generere forskellige typer diagrammer fra data, der leveres eller gives i chat.",
},
- save: {
- title: "Generer og gem filer i browseren",
- description:
- "Gør det muligt for standardagenten at generere og skrive til filer, der gemmes og kan downloades i din browser.",
- },
web: {
title: "Live web-søgning og browsing",
description:
@@ -361,10 +355,6 @@ const TRANSLATIONS = {
title: "Få filinformation",
description: "Få detaljerede metadata om filer",
},
- "write-file": {
- title: "Opret fil",
- description: "Opret nye filer eller skriv over eksisterende filer.",
- },
"edit-file": {
title: "Rediger fil",
description: "Rediger tekstfiler baseret på linjer",
@@ -381,6 +371,44 @@ const TRANSLATIONS = {
title: "Kopier fil",
description: "Kopier filer og mapper",
},
+ "write-text-file": {
+ title: "Opret tekstfil",
+ description:
+ "Opret nye tekstfiler eller overskriv eksisterende tekstfiler.",
+ },
+ },
+ },
+ createFiles: {
+ title: "Dokumentoprettelse",
+ description:
+ "Giv din agent mulighed for at oprette binære dokumentformater som PowerPoint-præsentationer, Excel-regneark, Word-dokumenter og PDF-filer. Filerne kan downloades direkte fra chatvinduet.",
+ configuration: "Tilgængelige dokumenttyper",
+ skills: {
+ "create-text-file": {
+ title: "Tekstfiler",
+ description:
+ "Opret tekstfiler med enhver indhold og filtype (.txt, .md, .json, .csv osv.)",
+ },
+ "create-pptx": {
+ title: "PowerPoint-præsentationer",
+ description:
+ "Opret nye PowerPoint-præsentationer med slides, overskrifter og punktlister.",
+ },
+ "create-pdf": {
+ title: "PDF-dokumenter",
+ description:
+ "Opret PDF-dokumenter fra Markdown eller almindelig tekst med grundlæggende formatering.",
+ },
+ "create-xlsx": {
+ title: "Excel-regneark",
+ description:
+ "Opret Excel-dokumenter med tabellerede data, inklusive ark og formatering.",
+ },
+ "create-docx": {
+ title: "Ord-dokumenter",
+ description:
+ "Opret Word-dokumenter med grundlæggende formatering og stil.",
+ },
},
},
},
@@ -700,7 +728,6 @@ const TRANSLATIONS = {
select_all: "Vælg alle",
deselect_all: "Fravælg alle",
remove_selected: "Fjern valgte",
- costs: "*Engangsomkostning for indlejringer",
save_embed: "Gem og indlejr",
"total-documents_one": "{{count}} dokument",
"total-documents_other": "{{count}} dokumenter",
diff --git a/frontend/src/locales/de/common.js b/frontend/src/locales/de/common.js
index 7bd574c48..518f90d80 100644
--- a/frontend/src/locales/de/common.js
+++ b/frontend/src/locales/de/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "Willkommen bei",
getStarted: "Jetzt starten",
welcome: "Herzlich willkommen",
},
@@ -315,11 +314,6 @@ const TRANSLATIONS = {
description:
"Aktivieren Sie den Standard-Agenten, um verschiedene Arten von Diagrammen aus bereitgestellten oder im Chat gegebenen Daten zu generieren.",
},
- save: {
- title: "Dateien generieren & im Browser speichern",
- description:
- "Aktivieren Sie den Standard-Agenten, um Dateien zu generieren und zu schreiben, die gespeichert und in Ihrem Browser heruntergeladen werden können.",
- },
web: {
title: "Live-Websuche und -Browsing",
description:
@@ -365,11 +359,6 @@ const TRANSLATIONS = {
title: "Dateieninformationen abrufen",
description: "Erhalten Sie detaillierte Metadaten über Dateien.",
},
- "write-file": {
- title: "Datei erstellen",
- description:
- "Neue Dateien erstellen oder vorhandene Dateien überschreiben.",
- },
"edit-file": {
title: "Datei bearbeiten",
description:
@@ -388,6 +377,44 @@ const TRANSLATIONS = {
title: "Datei kopieren",
description: "Dateien und Verzeichnisse kopieren",
},
+ "write-text-file": {
+ title: "Textdatei erstellen",
+ description:
+ "Erstellen Sie neue Textdateien oder überschreiben Sie vorhandene Textdateien.",
+ },
+ },
+ },
+ createFiles: {
+ title: "Dokumentenerstellung",
+ description:
+ "Ermöglichen Sie Ihrem Agenten, binäre Dokumentformate wie PowerPoint-Präsentationen, Excel-Tabellen, Word-Dokumente und PDFs zu erstellen. Die Dateien können direkt aus dem Chat-Fenster heruntergeladen werden.",
+ configuration: "Verfügbare Dokumenttypen",
+ skills: {
+ "create-text-file": {
+ title: "Textdateien",
+ description:
+ "Erstellen Sie Textdateien mit beliebigen Inhalten und Dateiendungen (.txt, .md, .json, .csv usw.)",
+ },
+ "create-pptx": {
+ title: "Präsentationen mit PowerPoint",
+ description:
+ "Erstellen Sie neue PowerPoint-Präsentationen mit Folien, Überschriften und Stichpunkten.",
+ },
+ "create-pdf": {
+ title: "PDF-Dokumente",
+ description:
+ "Erstellen Sie PDF-Dokumente aus Markdown- oder reinen Textdateien mit grundlegender Formatierung.",
+ },
+ "create-xlsx": {
+ title: "Excel-Tabellen",
+ description:
+ "Erstellen Sie Excel-Dokumente für tabellarische Daten mit Tabellen und Formatierungen.",
+ },
+ "create-docx": {
+ title: "Word-Dokumente",
+ description:
+ "Erstellen Sie Word-Dokumente mit grundlegender Formatierung und Gestaltung.",
+ },
},
},
},
@@ -813,7 +840,6 @@ const TRANSLATIONS = {
deselect_all: "Auswahl abbrechen",
no_docs: "Keine Dokumente vorhanden.",
remove_selected: "Ausgewähltes entfernen",
- costs: "*Einmalige Kosten für das Einbetten",
save_embed: "Speichern und Einbetten",
"total-documents_one": "{{count}} Dokument",
"total-documents_other": "{{count}} Dokumente",
diff --git a/frontend/src/locales/en/common.js b/frontend/src/locales/en/common.js
index 0750f52c7..fd5e8bcac 100644
--- a/frontend/src/locales/en/common.js
+++ b/frontend/src/locales/en/common.js
@@ -1,7 +1,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "Welcome to",
welcome: "Welcome",
getStarted: "Get Started",
},
@@ -323,11 +322,6 @@ const TRANSLATIONS = {
description:
"Enable the default agent to generate various types of charts from data provided or given in chat.",
},
- save: {
- title: "Generate & save files",
- description:
- "Enable the default agent to generate and write to files that can be saved to your computer.",
- },
web: {
title: "Web Search",
description:
@@ -370,9 +364,10 @@ const TRANSLATIONS = {
title: "Get File Info",
description: "Get detailed metadata about files",
},
- "write-file": {
- title: "Write File",
- description: "Create new files or overwrite existing files",
+ "write-text-file": {
+ title: "Write Text File",
+ description:
+ "Create new text files or overwrite existing text files",
},
"edit-file": {
title: "Edit File",
@@ -392,6 +387,39 @@ const TRANSLATIONS = {
},
},
},
+ createFiles: {
+ title: "Document Creation",
+ description:
+ "Enable your agent to create binary document formats like PowerPoint presentations, Excel spreadsheets, Word documents, and PDFs. Files can be downloaded directly from the chat window.",
+ configuration: "Available Document Types",
+ skills: {
+ "create-text-file": {
+ title: "Text Files",
+ description:
+ "Create text files with any content and extension (.txt, .md, .json, .csv, etc.)",
+ },
+ "create-pptx": {
+ title: "PowerPoint Presentations",
+ description:
+ "Create new PowerPoint presentations with slides, titles, and bullet points",
+ },
+ "create-pdf": {
+ title: "PDF Documents",
+ description:
+ "Create PDF documents from markdown or plain text with basic styling",
+ },
+ "create-xlsx": {
+ title: "Excel Spreadsheets",
+ description:
+ "Create Excel documents for tabular data with sheets and styling",
+ },
+ "create-docx": {
+ title: "Word Documents",
+ description:
+ "Create Word documents with basic styling and formatting",
+ },
+ },
+ },
default_skill:
"By default, this skill is enabled, but you can disable it if you don't want it to be available to the agent.",
},
@@ -909,7 +937,6 @@ const TRANSLATIONS = {
select_all: "Select All",
deselect_all: "Deselect All",
remove_selected: "Remove Selected",
- costs: "*One time cost for embeddings",
save_embed: "Save and Embed",
},
upload: {
diff --git a/frontend/src/locales/es/common.js b/frontend/src/locales/es/common.js
index d1de55314..0e7c83f7d 100644
--- a/frontend/src/locales/es/common.js
+++ b/frontend/src/locales/es/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "Bienvenido a",
getStarted: "Comenzar",
welcome: "Bienvenido",
},
@@ -321,11 +320,6 @@ const TRANSLATIONS = {
description:
"Habilita al agente predeterminado para generar varios tipos de gráficos a partir de datos proporcionados o dados en el chat.",
},
- save: {
- title: "Generar y guardar archivos en el navegador",
- description:
- "Habilita al agente predeterminado para generar y escribir en archivos que se guardan y se pueden descargar en tu navegador.",
- },
web: {
title: "Búsqueda y navegación web en vivo",
description:
@@ -372,11 +366,6 @@ const TRANSLATIONS = {
description:
"Obtenga información detallada sobre los metadatos de los archivos.",
},
- "write-file": {
- title: "Crear archivo",
- description:
- "Crear nuevos archivos o sobrescribir archivos existentes.",
- },
"edit-file": {
title: "Editar archivo",
description:
@@ -394,6 +383,44 @@ const TRANSLATIONS = {
title: "Copiar archivo",
description: "Copiar archivos y directorios",
},
+ "write-text-file": {
+ title: "Crear un archivo de texto",
+ description:
+ "Cree nuevos archivos de texto o sobrescriba archivos de texto existentes.",
+ },
+ },
+ },
+ createFiles: {
+ title: "Creación de documentos",
+ description:
+ "Permita que su agente cree formatos de documentos binarios como presentaciones de PowerPoint, hojas de cálculo de Excel, documentos de Word y archivos PDF. Los archivos se pueden descargar directamente desde la ventana de chat.",
+ configuration: "Tipos de documentos disponibles",
+ skills: {
+ "create-text-file": {
+ title: "Archivos de texto",
+ description:
+ "Cree archivos de texto con cualquier contenido y extensión (por ejemplo, .txt, .md, .json, .csv, etc.).",
+ },
+ "create-pptx": {
+ title: "Presentaciones en PowerPoint",
+ description:
+ "Crea nuevas presentaciones de PowerPoint con diapositivas, títulos y viñetas.",
+ },
+ "create-pdf": {
+ title: "Documentos en formato PDF",
+ description:
+ "Cree documentos PDF a partir de archivos Markdown o texto plano, con un estilo básico.",
+ },
+ "create-xlsx": {
+ title: "Hojas de cálculo de Excel",
+ description:
+ "Cree documentos de Excel para datos tabulares, con hojas y opciones de formato.",
+ },
+ "create-docx": {
+ title: "Documentos de Microsoft Word",
+ description:
+ "Crea documentos de Word con un estilo y formato básicos.",
+ },
},
},
},
@@ -822,7 +849,6 @@ const TRANSLATIONS = {
select_all: "Seleccionar todo",
deselect_all: "Deseleccionar todo",
remove_selected: "Eliminar seleccionados",
- costs: "*Costo único por incrustaciones",
save_embed: "Guardar e incrustar",
"total-documents_one": "{{count}} documento",
"total-documents_other": "{{count}} documentos",
diff --git a/frontend/src/locales/et/common.js b/frontend/src/locales/et/common.js
index c41c561c2..5ebf36664 100644
--- a/frontend/src/locales/et/common.js
+++ b/frontend/src/locales/et/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "Tere tulemast",
getStarted: "Alusta",
welcome: "Tere tulemast",
},
@@ -307,11 +306,6 @@ const TRANSLATIONS = {
title: "Loo diagramme",
description: "Lubab agendil luua erinevaid diagramme antud andmetest.",
},
- save: {
- title: "Loo ja salvesta faile brauserisse",
- description:
- "Lubab agendil luua faile, mis salvestatakse ja allalaaditakse brauseris.",
- },
web: {
title: "Reaalajas veebihaku tugi",
description:
@@ -356,10 +350,6 @@ const TRANSLATIONS = {
title: "Hankige faili teave",
description: "Hankige üksikasjalik teavet failide kohta",
},
- "write-file": {
- title: "Faili loomine",
- description: "Loo uusi faili või asenda olemasoleva faili",
- },
"edit-file": {
title: "Faili redigeerimine",
description: "Muuda teksti failide sisu rida- järgselt.",
@@ -376,6 +366,44 @@ const TRANSLATIONS = {
title: "Kopeeri fail",
description: "Kopeeri failid ja kaardi",
},
+ "write-text-file": {
+ title: "Loo teksti fail",
+ description:
+ "Loo uusi teksti faili või asenda olemasolevaid teksti faile",
+ },
+ },
+ },
+ createFiles: {
+ title: "Dokumendi koostamine",
+ description:
+ "Laske oma esindajal luua binaarsed dokumendiformaadid, näiteks PowerPointi esitlused, Exceli lehed, Wordi dokumendid ja PDF-failid. Failid saab alla laadida otse vestlusaknast.",
+ configuration: "Saadaval olevad dokumendi tüübid",
+ skills: {
+ "create-text-file": {
+ title: "Tekstifailid",
+ description:
+ "Loo teksti failid, milles on mis tahes sisu ja laiendus (esimärkid .txt, .md, .json, .csv jne).",
+ },
+ "create-pptx": {
+ title: "PowerPointi esitlused",
+ description:
+ "Loo uusi PowerPointi esitlusi, mis sisaldavad slaidide, pealkirjade ja punktide.",
+ },
+ "create-pdf": {
+ title: "PDF-failid",
+ description:
+ "Loo PDF-failid Markdown- või tavaline tekstist, kasutades lihtsaid stiilid",
+ },
+ "create-xlsx": {
+ title: "Excel-i lehed",
+ description:
+ "Loo Excel-failid, mis sisaldavad tabeli andmeid, lehtede ja stiilidega.",
+ },
+ "create-docx": {
+ title: "Microsoft Word-failid",
+ description:
+ "Loo Microsoft Wordi dokumende, kasutades põhise stiili ja vormistuse",
+ },
},
},
},
@@ -778,7 +806,6 @@ const TRANSLATIONS = {
select_all: "Vali kõik",
deselect_all: "Tühista valik",
remove_selected: "Eemalda valitud",
- costs: "*Ühekordne embeddingu kulu",
save_embed: "Salvesta ja põimi",
"total-documents_one": "{{count}} dokument",
"total-documents_other": "{{count}} dokumendid",
diff --git a/frontend/src/locales/fa/common.js b/frontend/src/locales/fa/common.js
index 22e4cdd3b..94f0de03a 100644
--- a/frontend/src/locales/fa/common.js
+++ b/frontend/src/locales/fa/common.js
@@ -17,7 +17,6 @@ const TRANSLATIONS = {
"ما را در ساخت مدل AnythingLLM متناسب با نیازهای شما یاری دهید. (این بخش اختیاری است)",
},
home: {
- title: "به",
getStarted: "شروع کنید",
welcome: "به شما خوش آمد میگوییم",
},
@@ -310,11 +309,6 @@ const TRANSLATIONS = {
description:
"به عامل پیشفرض امکان تولید انواع مختلف نمودار از دادههای ارائه شده یا داده شده در گفتگو را بدهید.",
},
- save: {
- title: "تولید و ذخیره فایلها در مرورگر",
- description:
- "به عامل پیشفرض امکان تولید و نوشتن در فایلهایی که ذخیره میشوند و میتوانند در مرورگر شما دانلود شوند را بدهید.",
- },
web: {
title: "جستجو و مرور زنده وب",
description:
@@ -358,10 +352,6 @@ const TRANSLATIONS = {
title: "اطلاعات فایل را دریافت کنید",
description: "اطلاعات دقیق در مورد فایلها را دریافت کنید.",
},
- "write-file": {
- title: "ایجاد فایل",
- description: "ایجاد فایلهای جدید یا جایگزینی فایلهای موجود",
- },
"edit-file": {
title: "ویرایش فایل",
description: "امکان ویرایش متون از طریق ویرایش خط به خط",
@@ -378,6 +368,44 @@ const TRANSLATIONS = {
title: "کپی فایل",
description: "فایلها و دایرکتوریها را کپی کنید.",
},
+ "write-text-file": {
+ title: "ایجاد یک فایل متنی",
+ description:
+ "ایجاد فایلهای متنی جدید یا جایگزینی فایلهای متنی موجود",
+ },
+ },
+ },
+ createFiles: {
+ title: "ایجاد مستند",
+ description:
+ "به کارگزار خود اجازه دهید فرمتهای اسناد دودویی مانند ارائه پاورپوینت، صفحات گسترده اکسل، اسناد ورد و فایلهای PDF را ایجاد کند. کاربران میتوانند فایلها را مستقیماً از پنجره چت دانلود کنند.",
+ configuration: "انواع اسناد موجود",
+ skills: {
+ "create-text-file": {
+ title: "فایلهای متنی",
+ description:
+ "ایجاد فایلهای متنی با هر نوع محتوا و پسوند (مانند .txt، .md، .json، .csv و غیره)",
+ },
+ "create-pptx": {
+ title: "ارائه های پاورپوینت",
+ description:
+ "ایجاد اسلایدها، عناوین و فهرستهای بولت برای ارائه پاورپوینتهای جدید",
+ },
+ "create-pdf": {
+ title: "اسناد به فرمت PDF",
+ description:
+ "ایجاد اسناد PDF از متن ساده یا فرمتهای Markdown با استفاده از استایلهای پایه",
+ },
+ "create-xlsx": {
+ title: "برگه های اکسل",
+ description:
+ "ایجاد فایلهای اکسل حاوی دادههای جدولی با جداول و استایلهای مختلف",
+ },
+ "create-docx": {
+ title: "اسناد و فایلهای وورد",
+ description:
+ "ایجاد فایلهای Word با استفاده از قالببندی و استایلهای ساده",
+ },
},
},
},
@@ -696,7 +724,6 @@ const TRANSLATIONS = {
select_all: "انتخاب همه",
deselect_all: "انتخاب همه را لغو کنید",
remove_selected: "حذف انتخابشده",
- costs: "*هزینه یکباره برای ایجاد مدلهای برداری",
save_embed: "ذخیره و وارد کردن",
"total-documents_one": "{{count}} سند",
"total-documents_other": "{{count}} اسناد",
diff --git a/frontend/src/locales/fr/common.js b/frontend/src/locales/fr/common.js
index 2bf80082c..6ac9611eb 100644
--- a/frontend/src/locales/fr/common.js
+++ b/frontend/src/locales/fr/common.js
@@ -16,7 +16,6 @@ const TRANSLATIONS = {
"Aidez-nous à améliorer AnythingLLM en répondant à quelques questions.",
},
home: {
- title: "Bienvenue",
getStarted: "Commencer",
welcome: "Bienvenue",
},
@@ -311,11 +310,6 @@ const TRANSLATIONS = {
description:
"Activez l'agent par défaut pour générer différents types de graphiques à partir des données fournies ou données dans le chat.",
},
- save: {
- title: "Générer et sauvegarder des fichiers dans le navigateur",
- description:
- "Activez l'agent par défaut pour générer et écrire des fichiers qui peuvent être sauvegardés et téléchargés dans votre navigateur.",
- },
web: {
title: "Recherche web en direct et navigation",
description:
@@ -361,11 +355,6 @@ const TRANSLATIONS = {
title: "Obtenir des informations sur le fichier",
description: "Obtenez des métadonnées détaillées sur les fichiers.",
},
- "write-file": {
- title: "Créer un fichier",
- description:
- "Créer de nouveaux fichiers ou remplacer des fichiers existants.",
- },
"edit-file": {
title: "Modifier le fichier",
description:
@@ -384,6 +373,44 @@ const TRANSLATIONS = {
title: "Copier le fichier",
description: "Copier des fichiers et des répertoires",
},
+ "write-text-file": {
+ title: "Créer un fichier texte",
+ description:
+ "Créer de nouveaux fichiers texte ou remplacer des fichiers texte existants.",
+ },
+ },
+ },
+ createFiles: {
+ title: "Création de documents",
+ description:
+ "Permettez à votre agent de créer des documents au format binaire, tels que des présentations PowerPoint, des feuilles de calcul Excel, des documents Word et des fichiers PDF. Les fichiers peuvent être téléchargés directement depuis la fenêtre de chat.",
+ configuration: "Types de documents disponibles",
+ skills: {
+ "create-text-file": {
+ title: "Fichiers de texte",
+ description:
+ "Créez des fichiers texte avec n'importe quel contenu et extension (par exemple, .txt, .md, .json, .csv, etc.)",
+ },
+ "create-pptx": {
+ title: "Présentations PowerPoint",
+ description:
+ "Créez de nouvelles présentations PowerPoint avec des diapositives, des titres et des puces.",
+ },
+ "create-pdf": {
+ title: "Documents au format PDF",
+ description:
+ "Créez des documents PDF à partir de fichiers Markdown ou de texte brut, avec un style de base.",
+ },
+ "create-xlsx": {
+ title: "Feuilles de calcul Excel",
+ description:
+ "Créez des documents Excel pour les données tabulaires, avec des feuilles et un style.",
+ },
+ "create-docx": {
+ title: "Documents au format Word",
+ description:
+ "Créez des documents Word avec un style et une mise en page de base.",
+ },
},
},
},
@@ -703,7 +730,6 @@ const TRANSLATIONS = {
select_all: "Tout sélectionner",
deselect_all: "Tout désélectionner",
remove_selected: "Supprimer la sélection",
- costs: "Coûts",
save_embed: "Sauvegarder et intégrer",
"total-documents_one": "{{count}}",
"total-documents_other": "{{count}} documents",
diff --git a/frontend/src/locales/he/common.js b/frontend/src/locales/he/common.js
index 41c68e9a8..83c7a9022 100644
--- a/frontend/src/locales/he/common.js
+++ b/frontend/src/locales/he/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "ברוכים הבאים ל",
getStarted: "להתחלה",
welcome: "ברוכים הבאים",
},
@@ -309,11 +308,6 @@ const TRANSLATIONS = {
description:
"אפשר לסוכן ברירת המחדל ליצור סוגים שונים של תרשימים מנתונים שסופקו או ניתנו בצ'אט.",
},
- save: {
- title: "יצירה ושמירה של קבצים לדפדפן",
- description:
- "אפשר לסוכן ברירת המחדל ליצור ולכתוב לקבצים שנשמרים וניתנים להורדה בדפדפן שלך.",
- },
web: {
title: "חיפוש וגלישה באינטרנט בזמן אמת",
description:
@@ -357,10 +351,6 @@ const TRANSLATIONS = {
title: "קבל מידע על הקובץ",
description: "קבל מידע מפורט על קבצים",
},
- "write-file": {
- title: "יצירת קובץ",
- description: "יצירת קבצים חדשים או החלפת קבצים קיימים",
- },
"edit-file": {
title: "ערוך קובץ",
description: "בצעו עריכה של קבצי טקסט על בסיס שורות.",
@@ -377,6 +367,42 @@ const TRANSLATIONS = {
title: "העתק קובץ",
description: "העתקת קבצים וספריות",
},
+ "write-text-file": {
+ title: "יצירת קובץ טקסט",
+ description: "יצירת קבצי טקסט חדשים או החלפת קבצי טקסט קיימים",
+ },
+ },
+ },
+ createFiles: {
+ title: "יצירת מסמכים",
+ description:
+ "אפשרו למתווך שלכם ליצור פורמטים של מסמכים בינאריים, כמו מצגות של פאוורPoint, גיליונות אלקטרוניים של Excel, מסמכי Word ו-PDF. ניתן להוריד את הקבצים ישירות מהחלון של השיחה.",
+ configuration: "סוגי המסמכים הזמינים",
+ skills: {
+ "create-text-file": {
+ title: "קבצי טקסט",
+ description:
+ "צרו קבצי טקסט עם כל תוכן ותוספת (כגון .txt, .md, .json, .csv וכו').",
+ },
+ "create-pptx": {
+ title: "מצגות של פאוור פוינט",
+ description:
+ "צרו מצגות חדשות בפורמט PowerPoint, הכוללות שקופיות, כותרות ונקודות עיקריות.",
+ },
+ "create-pdf": {
+ title: "מסמכים בפורמט PDF",
+ description:
+ "יצירת מסמכים בפורמט PDF ממחרוזות markdown או טקסט פשוט, עם עיצוב בסיסי.",
+ },
+ "create-xlsx": {
+ title: "גיליונות אקסל",
+ description:
+ "צור מסמכי Excel עבור נתונים טבלאיים, הכוללים גיליונות ועריכת עיצוב.",
+ },
+ "create-docx": {
+ title: "מסמכים בפורמט Word",
+ description: "צור מסמכים בפורמט Word עם עיצוב ועיצוב בסיסיים.",
+ },
},
},
},
@@ -781,7 +807,6 @@ const TRANSLATIONS = {
select_all: "בחר הכל",
deselect_all: "בטל בחירת הכל",
remove_selected: "הסר נבחרים",
- costs: "*עלות חד פעמית להטמעות",
save_embed: "שמור והטמע",
"total-documents_one": "{{count}} מסמך",
"total-documents_other": "מסמכים {{count}}",
diff --git a/frontend/src/locales/it/common.js b/frontend/src/locales/it/common.js
index 1c520332a..76f25f05f 100644
--- a/frontend/src/locales/it/common.js
+++ b/frontend/src/locales/it/common.js
@@ -17,7 +17,6 @@ const TRANSLATIONS = {
"Aiutaci a sviluppare AnythingLLM in base alle tue esigenze. Facoltativo.",
},
home: {
- title: "Benvenuti a",
getStarted: "Inizia",
welcome: "Benvenuti",
},
@@ -314,11 +313,6 @@ const TRANSLATIONS = {
description:
"Consenti all'agente predefinito di generare vari tipi di grafici dai dati forniti o forniti nella chat.",
},
- save: {
- title: "Genera e salva file nel browser",
- description:
- "Abilita l'agente predefinito per generare e scrivere su file che possono essere salvati e scaricati nel tuo browser.",
- },
web: {
title: "Ricerca e navigazione web in tempo reale",
description:
@@ -364,10 +358,6 @@ const TRANSLATIONS = {
title: "Ottieni informazioni sul file",
description: "Ottenere metadati dettagliati sui file.",
},
- "write-file": {
- title: "Creare file",
- description: "Creare nuovi file o sovrascrivere i file esistenti.",
- },
"edit-file": {
title: "Modifica file",
description: "Applica modifiche basate su righe ai file di testo.",
@@ -384,6 +374,44 @@ const TRANSLATIONS = {
title: "Copia file",
description: "Copia file e directory",
},
+ "write-text-file": {
+ title: "Crea un file di testo",
+ description:
+ "Creare nuovi file di testo o sovrascrivere file di testo esistenti.",
+ },
+ },
+ },
+ createFiles: {
+ title: "Creazione di documenti",
+ description:
+ "Permetti al tuo agente di creare file in formati binari come presentazioni PowerPoint, fogli di calcolo Excel, documenti Word e file PDF. I file possono essere scaricati direttamente dalla finestra di chat.",
+ configuration: "Tipi di documenti disponibili",
+ skills: {
+ "create-text-file": {
+ title: "File di testo",
+ description:
+ "Creare file di testo con qualsiasi contenuto ed estensione (ad esempio, .txt, .md, .json, .csv, ecc.)",
+ },
+ "create-pptx": {
+ title: "Presentazioni PowerPoint",
+ description:
+ "Crea nuove presentazioni PowerPoint con diapositive, titoli e punti elenco.",
+ },
+ "create-pdf": {
+ title: "Documenti in formato PDF",
+ description:
+ "Creare documenti PDF da file Markdown o testo semplice, con un'applicazione di formattazione di base.",
+ },
+ "create-xlsx": {
+ title: "Fogli di calcolo Excel",
+ description:
+ "Crea documenti Excel per dati tabulari, con fogli e stili.",
+ },
+ "create-docx": {
+ title: "Documenti in formato Word",
+ description:
+ "Creare documenti Word con un'impaginazione e formattazione di base.",
+ },
},
},
},
@@ -705,7 +733,6 @@ const TRANSLATIONS = {
select_all: "Seleziona tutto",
deselect_all: "Deselect All",
remove_selected: "Elimina gli elementi selezionati",
- costs: "*Costo una tantum per le embedding",
save_embed: "Salva e incorpora",
"total-documents_one": "{{count}} documento",
"total-documents_other": "{{count}} documenti",
diff --git a/frontend/src/locales/ja/common.js b/frontend/src/locales/ja/common.js
index cdd5fea92..8a812af36 100644
--- a/frontend/src/locales/ja/common.js
+++ b/frontend/src/locales/ja/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "ようこそ",
getStarted: "はじめる",
welcome: "ようこそ",
},
@@ -306,11 +305,6 @@ const TRANSLATIONS = {
description:
"デフォルトエージェントがチャットやデータからさまざまなチャートを作成できるようにします。",
},
- save: {
- title: "ファイルの生成と保存",
- description:
- "デフォルトエージェントがファイルを生成し、ブラウザからダウンロードできるようにします。",
- },
web: {
title: "ウェブ検索と閲覧",
description:
@@ -355,11 +349,6 @@ const TRANSLATIONS = {
title: "ファイルの情報を取得する",
description: "ファイルに関する詳細なメタデータを取得する",
},
- "write-file": {
- title: "ファイルを作成",
- description:
- "新しいファイルを作成するか、既存のファイルを上書きする",
- },
"edit-file": {
title: "ファイル編集",
description: "テキストファイルの行単位での編集を行う",
@@ -376,6 +365,43 @@ const TRANSLATIONS = {
title: "ファイルのコピー",
description: "ファイルとディレクトリをコピーする",
},
+ "write-text-file": {
+ title: "テキストファイルを作成する",
+ description:
+ "新しいテキストファイルを作成するか、既存のテキストファイルを上書きする。",
+ },
+ },
+ },
+ createFiles: {
+ title: "ドキュメント作成",
+ description:
+ "エージェントが、パワーポイント、Excel、Word、PDFなどのバイナリ形式のドキュメントを作成できるようにします。ファイルはチャットウィンドウから直接ダウンロードできます。",
+ configuration: "利用可能なドキュメントの種類",
+ skills: {
+ "create-text-file": {
+ title: "テキストファイル",
+ description:
+ ".txt、.md、.json、.csvなどの拡張子を持つ、任意のコンテンツのテキストファイルを作成する。",
+ },
+ "create-pptx": {
+ title: "パワーポイント形式のプレゼンテーション",
+ description:
+ "スライド、タイトル、箇条書きを含む、新しいPowerPointプレゼンテーションを作成する。",
+ },
+ "create-pdf": {
+ title: "PDFドキュメント",
+ description:
+ "マークダウンまたはプレーンテキストから、基本的な書式設定を使用してPDFドキュメントを作成する。",
+ },
+ "create-xlsx": {
+ title: "エクセル スプレッドシート",
+ description:
+ "表形式のデータをスプレッドシート形式で作成し、シートとスタイルを設定する。",
+ },
+ "create-docx": {
+ title: "Wordドキュメント",
+ description: "基本的なスタイルと書式でWordドキュメントを作成する",
+ },
},
},
},
@@ -690,7 +716,6 @@ const TRANSLATIONS = {
select_all: "すべて選択",
deselect_all: "すべて選択解除",
remove_selected: "選択したものを削除",
- costs: "※埋め込みには一度だけ費用がかかります",
save_embed: "保存して埋め込む",
"total-documents_one": "{{count}} のドキュメント",
"total-documents_other": "{{count}} に関する書類",
diff --git a/frontend/src/locales/ko/common.js b/frontend/src/locales/ko/common.js
index 5aa3fb6e7..4ea4b7766 100644
--- a/frontend/src/locales/ko/common.js
+++ b/frontend/src/locales/ko/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "방문을 환영합니다",
getStarted: "시작하기",
welcome: "환영합니다",
},
@@ -310,11 +309,6 @@ const TRANSLATIONS = {
description:
"기본 에이전트가 채팅에서 제공된 데이터를 이용하여 다양한 유형의 차트를 생성할 수 있도록 합니다.",
},
- save: {
- title: "브라우저에서 파일 생성과 저장",
- description:
- "기본 에이전트가 브라우저에서 파일을 생성하고 다운로드할 수 있도록 합니다.",
- },
web: {
title: "실시간 웹 검색 및 탐색",
description:
@@ -359,10 +353,6 @@ const TRANSLATIONS = {
title: "파일 정보 확인",
description: "파일에 대한 자세한 메타데이터를 얻으세요.",
},
- "write-file": {
- title: "파일 작성",
- description: "새로운 파일을 생성하거나 기존 파일을 덮어쓰기",
- },
"edit-file": {
title: "파일 편집",
description: "텍스트 파일에 줄 단위로 편집",
@@ -379,6 +369,44 @@ const TRANSLATIONS = {
title: "파일 복사",
description: "파일 및 디렉터리를 복사",
},
+ "write-text-file": {
+ title: "텍스트 파일 작성",
+ description:
+ "새로운 텍스트 파일을 생성하거나 기존 텍스트 파일을 덮어쓰기",
+ },
+ },
+ },
+ createFiles: {
+ title: "문서 생성",
+ description:
+ "에이전트가 파워포인트 프레젠테이션, 엑셀 스프레드시트, 워드 문서, PDF 등 이진 파일 형식의 문서를 생성할 수 있도록 지원합니다. 파일은 채팅 창에서 직접 다운로드할 수 있습니다.",
+ configuration: "사용 가능한 문서 유형",
+ skills: {
+ "create-text-file": {
+ title: "텍스트 파일",
+ description:
+ "원하는 내용과 확장자(.txt, .md, .json, .csv 등)를 사용하여 텍스트 파일을 생성합니다.",
+ },
+ "create-pptx": {
+ title: "파워포인트 프레젠테이션",
+ description:
+ "슬라이드, 제목, 마크다운 등을 포함하여 새로운 파워포인트 프레젠테이션을 만드세요.",
+ },
+ "create-pdf": {
+ title: "PDF 문서",
+ description:
+ "기본 스타일을 적용하여 마크다운 또는 일반 텍스트에서 PDF 문서를 생성합니다.",
+ },
+ "create-xlsx": {
+ title: "엑셀 스프레드시트",
+ description:
+ "표와 스타일을 포함한 표 형태의 데이터를 위한 엑셀 문서를 만드세요.",
+ },
+ "create-docx": {
+ title: "워드 문서",
+ description:
+ "기본적인 스타일과 서식을 사용하여 워드 문서를 만드세요.",
+ },
},
},
},
@@ -790,7 +818,6 @@ const TRANSLATIONS = {
select_all: "전체 선택",
deselect_all: "전체 선택 해제",
remove_selected: "선택 항목 삭제",
- costs: "*임베딩 1회 비용",
save_embed: "저장 및 임베딩",
"total-documents_one": "{{count}} 문서",
"total-documents_other": "{{count}} 관련 문서",
diff --git a/frontend/src/locales/lt/common.js b/frontend/src/locales/lt/common.js
index 06a15e9c9..5c87cb648 100644
--- a/frontend/src/locales/lt/common.js
+++ b/frontend/src/locales/lt/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "Sveiki atvykę į",
getStarted: "Pradėti",
welcome: "Sveiki",
},
@@ -323,11 +322,6 @@ const TRANSLATIONS = {
description:
"Leidžia numatytajam agentui generuoti įvairių tipų diagramas pagal pateiktus arba pokalbio metu gautus duomenis.",
},
- save: {
- title: "Generuoti ir išsaugoti failus",
- description:
- "Leidžia numatytajam agentui generuoti ir rašyti failus, kuriuos galima išsaugoti jūsų kompiuteryje.",
- },
web: {
title: "Paieška internete",
description:
@@ -372,10 +366,6 @@ const TRANSLATIONS = {
title: "Gaukite failo informaciją",
description: "Gaukite išsamią informaciją apie failus.",
},
- "write-file": {
- title: "Sukurti failą",
- description: "Sukurti naujus failus arba pakeisti esamus",
- },
"edit-file": {
title: "Redaguoti failą",
description: "Atlikite teksto failų redakciją, remdamiesi eilėmis.",
@@ -392,6 +382,44 @@ const TRANSLATIONS = {
title: "Kopijuoti failą",
description: "Kopijuoti failus ir katalogus",
},
+ "write-text-file": {
+ title: "Sukurti teksto failą",
+ description:
+ "Sukurkite naujus tekstinius failus arba pakeiskite esamus tekstinius failus.",
+ },
+ },
+ },
+ createFiles: {
+ title: "Dokumento sukūrimas",
+ description:
+ "Įgalinkite savo agentą kurti dvigubos formos dokumentų formatus, tokius kaip „PowerPoint“ prezentacijos, „Excel“ lentelės, „Word“ dokumentai ir PDF failus. Failus galima atsisiųsti tiesiai iš pokalbio lango.",
+ configuration: "Galimi dokumentų tipai",
+ skills: {
+ "create-text-file": {
+ title: "Tekstiniai failai",
+ description:
+ "Sukurkite teksto failus su bet kokiu turiniu ir failų sąlypa (.txt, .md, .json, .csv ir kt.)",
+ },
+ "create-pptx": {
+ title: "„PowerPoint“ pristatymai",
+ description:
+ "Sukurkite naujas PowerPoint prezentacijas, naudodami slaidus, pavadinimus ir punktų sąrašus.",
+ },
+ "create-pdf": {
+ title: "PDF dokumentai",
+ description:
+ "Sukurkite PDF dokumentus iš Markdown ar paprastos teksto formato, naudodami pagrindinius stiliaus elementus.",
+ },
+ "create-xlsx": {
+ title: "„Excel“ lentelės",
+ description:
+ "Sukurkite Excel dokumentus, skirtus lentelių duomenims, su lapais ir stiliaus parametrais.",
+ },
+ "create-docx": {
+ title: "Skelbimo dokumentai",
+ description:
+ "Sukurkite Word dokumentus su pagrindine stiliavimo ir formavimo funkcija.",
+ },
},
},
},
@@ -834,7 +862,6 @@ const TRANSLATIONS = {
select_all: "Žymėti viską",
deselect_all: "Atžymėti viską",
remove_selected: "Šalinti pažymėtus",
- costs: "*Vienkartinis mokestis už vektorių kūrimą",
save_embed: "Išsaugoti ir kurti vektorius",
},
upload: {
diff --git a/frontend/src/locales/lv/common.js b/frontend/src/locales/lv/common.js
index 9288a5977..c7aebd705 100644
--- a/frontend/src/locales/lv/common.js
+++ b/frontend/src/locales/lv/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "Laipni lūgti",
getStarted: "Sākt darbu",
welcome: "Laipni lūdzam",
},
@@ -315,11 +314,6 @@ const TRANSLATIONS = {
description:
"Iespējot noklusējuma aģentam ģenerēt dažāda veida diagrammas no sarunā sniegtajiem vai dotajiem datiem.",
},
- save: {
- title: "Ģenerēt un saglabāt failus pārlūkā",
- description:
- "Iespējot noklusējuma aģentam ģenerēt un rakstīt failus, kas saglabājas un var tikt lejupielādēti jūsu pārlūkā.",
- },
web: {
title: "Tiešsaistes tīmekļa meklēšana un pārlūkošana",
description:
@@ -365,10 +359,6 @@ const TRANSLATIONS = {
title: "Iegūst faila informāciju",
description: "Iesaļojiet detalizētus failu metadatus",
},
- "write-file": {
- title: "Izveidot failu",
- description: "Izveidot jaunas failus vai pārrakstīt esošus failus",
- },
"edit-file": {
title: "Rediģēt failu",
description:
@@ -386,6 +376,44 @@ const TRANSLATIONS = {
title: "Kopēt failu",
description: "Kopēt failus un direktorus",
},
+ "write-text-file": {
+ title: "Izveidot teksta failu",
+ description:
+ "Izveidot jaunas teksta failus vai pārrakstīt esošos teksta failus.",
+ },
+ },
+ },
+ createFiles: {
+ title: "Dokumentu izveide",
+ description:
+ "Ļauj savam pārstāvim izveidot binārus dokumentu formātus, piemēram, PowerPoint prezentācijas, Excel tabulas, Word dokumentus un PDF failus. Failus var lejupielādēt tieši no čata.",
+ configuration: "Pieejamās dokumentu veidas",
+ skills: {
+ "create-text-file": {
+ title: "Teksta faili",
+ description:
+ "Izveidot teksta failus ar jebkuru saturu un izplejumu (.txt, .md, .json, .csv utt.)",
+ },
+ "create-pptx": {
+ title: "PowerPoint prezentācijas",
+ description:
+ "Izveidot jaunas PowerPoint prezentācijas ar slaidiem, nosaukumiem un punktiem.",
+ },
+ "create-pdf": {
+ title: "PDF dokumenti",
+ description:
+ "Izveidot PDF dokumentus no Markdown vai vienkāršas teksta, izmantojot pamata formāciju.",
+ },
+ "create-xlsx": {
+ title: "Excel tabulas",
+ description:
+ "Izveidot Excel dokumentus ar tabulas datiem, kas ietver lapas un stila iespējas.",
+ },
+ "create-docx": {
+ title: "Vārdu dokumenti",
+ description:
+ "Izveidot Word dokumentus ar pamata stils un formātēšanu",
+ },
},
},
},
@@ -805,7 +833,6 @@ const TRANSLATIONS = {
select_all: "Atlasīt visu",
deselect_all: "Atcelt visu atlasi",
remove_selected: "Noņemt atlasītos",
- costs: "*Vienreizējas izmaksas iegulšanai",
save_embed: "Saglabāt un iegult",
"total-documents_one": "{{count}} dokumenta",
"total-documents_other": "{{count}} dokumenti",
diff --git a/frontend/src/locales/nl/common.js b/frontend/src/locales/nl/common.js
index d8b05f7b9..536b341d2 100644
--- a/frontend/src/locales/nl/common.js
+++ b/frontend/src/locales/nl/common.js
@@ -17,7 +17,6 @@ const TRANSLATIONS = {
"Help ons AnythingLLM af te stemmen op jouw behoeften. (Optioneel)",
},
home: {
- title: "Welkom bij",
getStarted: "Aan de slag",
welcome: "Welkom",
},
@@ -310,11 +309,6 @@ const TRANSLATIONS = {
description:
"Sta de standaardagent toe om verschillende soorten grafieken te genereren uit verstrekte of in de chat gegeven gegevens.",
},
- save: {
- title: "Genereren & opslaan van bestanden naar browser",
- description:
- "Sta de standaardagent toe om te genereren en te schrijven naar bestanden die worden opgeslagen en kunnen worden gedownload in je browser.",
- },
web: {
title: "Live web zoeken en browsen",
description:
@@ -361,11 +355,6 @@ const TRANSLATIONS = {
title: "Fijlsinformatie bekijken",
description: "Verkrijg gedetailleerde metadata over bestanden.",
},
- "write-file": {
- title: "Schrijf bestand",
- description:
- "Maak nieuwe bestanden aan of vervang bestaande bestanden.",
- },
"edit-file": {
title: "Bestand bewerken",
description: "Voer wijzigingen uit op tekstbestanden, per regel.",
@@ -382,6 +371,43 @@ const TRANSLATIONS = {
title: "Kopieer bestand",
description: "Kopieer bestanden en mappen",
},
+ "write-text-file": {
+ title: "Maak een tekstbestand",
+ description:
+ "Maak nieuwe tekstbestanden aan of vervang bestaande tekstbestanden.",
+ },
+ },
+ },
+ createFiles: {
+ title: "Documentcreatie",
+ description:
+ "Laat uw agent documenten in binair formaat aanmaken, zoals PowerPoint-presentaties, Excel-tabellen, Word-documenten en PDF-bestanden. Bestanden kunnen direct worden gedownload vanuit het chatvenster.",
+ configuration: "Beschikbare documenttypen",
+ skills: {
+ "create-text-file": {
+ title: "Tekstbestanden",
+ description:
+ "Maak tekstbestanden met elk gewenst inhoud en bestandsextensie (bijvoorbeeld .txt, .md, .json, .csv, enz.).",
+ },
+ "create-pptx": {
+ title: "Presentaties met PowerPoint",
+ description:
+ "Maak nieuwe PowerPoint-presentaties met dia's, titels en opsommingstekens.",
+ },
+ "create-pdf": {
+ title: "PDF-documenten",
+ description:
+ "Maak PDF-documenten aan vanuit Markdown of gewone tekst, met basisstijling.",
+ },
+ "create-xlsx": {
+ title: "Excel-tabellen",
+ description:
+ "Maak Excel-documenten voor tabelgegevens, met tabbladen en opmaak.",
+ },
+ "create-docx": {
+ title: "Word-documenten",
+ description: "Maak Word-documenten met basisstijlen en -opmaak.",
+ },
},
},
},
@@ -702,7 +728,6 @@ const TRANSLATIONS = {
select_all: "Alles selecteren",
deselect_all: "Alles deselecteren",
remove_selected: "Verwijderen Geselecteerd",
- costs: "*Eenmalige kosten voor embedden",
save_embed: "Opslaan en embedden",
"total-documents_one": "{{count}} document",
"total-documents_other": "{{count}} documenten",
diff --git a/frontend/src/locales/pl/common.js b/frontend/src/locales/pl/common.js
index fd81273d6..c0aad7832 100644
--- a/frontend/src/locales/pl/common.js
+++ b/frontend/src/locales/pl/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "Witamy w",
getStarted: "Rozpocznij",
welcome: "Witaj",
},
@@ -316,11 +315,6 @@ const TRANSLATIONS = {
description:
"Pozwól domyślnemu agentowi generować różne typy wykresów na podstawie danych dostarczonych lub podanych na czacie.",
},
- save: {
- title: "Generowanie i zapisywanie plików w przeglądarce",
- description:
- "Pozwól domyślnemu agentowi generować i zapisywać pliki, które można zapisać i pobrać w przeglądarce.",
- },
web: {
title: "Wyszukiwanie i przeglądanie stron internetowych na żywo",
description:
@@ -366,10 +360,6 @@ const TRANSLATIONS = {
title: "Pobierz informacje o pliku",
description: "Uzyskaj szczegółowe metadane dotyczące plików.",
},
- "write-file": {
- title: "Utwórz plik",
- description: "Utwórz nowe pliki lub nadpisz istniejące",
- },
"edit-file": {
title: "Edytuj plik",
description:
@@ -387,6 +377,44 @@ const TRANSLATIONS = {
title: "Skopiuj plik",
description: "Kopiuj pliki i katalogi",
},
+ "write-text-file": {
+ title: "Utwórz plik tekstowy",
+ description:
+ "Utwórz nowe pliki tekstowe lub nadpisz istniejące pliki tekstowe.",
+ },
+ },
+ },
+ createFiles: {
+ title: "Tworzenie dokumentów",
+ description:
+ "Pozwól swojemu agentowi tworzyć pliki w formatach binarnych, takich jak prezentacje PowerPoint, arkusze kalkulacyjne Excel, dokumenty Word i pliki PDF. Pliki można pobrać bezpośrednio z okna czatu.",
+ configuration: "Dostępne typy dokumentów",
+ skills: {
+ "create-text-file": {
+ title: "Pliki tekstowe",
+ description:
+ "Utwórz pliki tekstowe z dowolnym zawartością i rozszerzeniem (np. .txt, .md, .json, .csv).",
+ },
+ "create-pptx": {
+ title: "Prezentacje w formacie PowerPoint",
+ description:
+ "Stwórz nowe prezentacje w formacie PowerPoint, zawierające slajdy, nagłówki i punkty.",
+ },
+ "create-pdf": {
+ title: "Dokumenty w formacie PDF",
+ description:
+ "Tworzenie dokumentów PDF z plików w formacie Markdown lub zwykłego tekstu, z podstawowymi możliwościami stylizacji.",
+ },
+ "create-xlsx": {
+ title: "Arkusze kalkulacyjne w programie Excel",
+ description:
+ "Stwórz arkusze kalkulacyjne w programie Excel, zawierające dane w formie tabel, z różnymi arkuszami i stylami.",
+ },
+ "create-docx": {
+ title: "Dokumenty w formacie Word",
+ description:
+ "Stwórz dokumenty Word z podstawowymi stylami i formatowaniem.",
+ },
},
},
},
@@ -806,7 +834,6 @@ const TRANSLATIONS = {
select_all: "Wybierz wszystko",
deselect_all: "Odznacz wszystko",
remove_selected: "Usuń wybrane",
- costs: "*Jednorazowy koszt dodania danych",
save_embed: "Zapisz",
"total-documents_one": "{{count}} dokument",
"total-documents_other": "{{count}} dokumenty",
diff --git a/frontend/src/locales/pt_BR/common.js b/frontend/src/locales/pt_BR/common.js
index 35054992b..7a5367496 100644
--- a/frontend/src/locales/pt_BR/common.js
+++ b/frontend/src/locales/pt_BR/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "Bem-vindo ao",
getStarted: "Começar",
welcome: "Bem-vindo",
},
@@ -315,10 +314,6 @@ const TRANSLATIONS = {
description:
"Permite ao agente padrão gerar diversos tipos de gráficos a partir de dados armazenados ou informados no chat.",
},
- save: {
- title: "Gerar & salvar arquivos",
- description: "Permite ao agente gerar e salvar arquivos no navegador.",
- },
web: {
title: "Busca na web",
description:
@@ -363,11 +358,6 @@ const TRANSLATIONS = {
title: "Obter informações do arquivo",
description: "Obtenha metadados detalhados sobre os arquivos.",
},
- "write-file": {
- title: "Criar arquivo",
- description:
- "Criar novos arquivos ou substituir arquivos existentes.",
- },
"edit-file": {
title: "Editar arquivo",
description:
@@ -385,6 +375,44 @@ const TRANSLATIONS = {
title: "Copiar arquivo",
description: "Copie arquivos e diretórios",
},
+ "write-text-file": {
+ title: "Criar um arquivo de texto",
+ description:
+ "Crie novos arquivos de texto ou sobrescreva arquivos de texto existentes.",
+ },
+ },
+ },
+ createFiles: {
+ title: "Criação de documentos",
+ description:
+ "Permita que seu agente crie formatos de documentos binários, como apresentações do PowerPoint, planilhas do Excel, documentos do Word e arquivos PDF. Os arquivos podem ser baixados diretamente da janela de chat.",
+ configuration: "Tipos de documentos disponíveis",
+ skills: {
+ "create-text-file": {
+ title: "Arquivos de texto",
+ description:
+ "Crie arquivos de texto com qualquer conteúdo e extensão (por exemplo, .txt, .md, .json, .csv, etc.)",
+ },
+ "create-pptx": {
+ title: "Apresentações em PowerPoint",
+ description:
+ "Crie novas apresentações do PowerPoint com slides, títulos e marcadores.",
+ },
+ "create-pdf": {
+ title: "Documentos em formato PDF",
+ description:
+ "Crie documentos em PDF a partir de arquivos Markdown ou texto simples, com formatação básica.",
+ },
+ "create-xlsx": {
+ title: "Planilhas do Excel",
+ description:
+ "Crie documentos do Excel para dados tabulares, incluindo planilhas e estilos.",
+ },
+ "create-docx": {
+ title: "Documentos do tipo Word",
+ description:
+ "Crie documentos do Word com formatação e estilo básicos.",
+ },
},
},
},
@@ -791,7 +819,6 @@ const TRANSLATIONS = {
select_all: "Selecionar Tudo",
deselect_all: "Desmarcar Tudo",
remove_selected: "Remover Selecionados",
- costs: "*Custo único para vínculos",
save_embed: "Salvar e Inserir",
"total-documents_one": "{{count}} documento",
"total-documents_other": "{{count}} documentos",
diff --git a/frontend/src/locales/ro/common.js b/frontend/src/locales/ro/common.js
index 79fb30436..d10d998ea 100644
--- a/frontend/src/locales/ro/common.js
+++ b/frontend/src/locales/ro/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "Bine ai venit la",
getStarted: "Începe",
welcome: "Bine ați venit",
},
@@ -457,7 +456,6 @@ const TRANSLATIONS = {
select_all: "Selectează tot",
deselect_all: "Deselectează tot",
remove_selected: "Elimină selectate",
- costs: "*Cost unic pentru embeddings",
save_embed: "Salvează și încorporează",
"total-documents_one": "{{count}}",
"total-documents_other": "{{count}} documente",
@@ -767,11 +765,6 @@ const TRANSLATIONS = {
description:
"Permite agentului implicit să genereze diverse tipuri de grafice din datele furnizate sau date în chat.",
},
- save: {
- title: "Generează & salvează fișiere în browser",
- description:
- "Permite agentului implicit să genereze și să scrie fișiere care se salvează și pot fi descărcate în browserul tău.",
- },
web: {
title: "Căutare și navigare web live",
description:
@@ -817,11 +810,6 @@ const TRANSLATIONS = {
title: "Obține informații despre fișier",
description: "Obțineți metadate detaliate despre fișiere.",
},
- "write-file": {
- title: "Creați fișier",
- description:
- "Creați fișiere noi sau suprascrieți fișierele existente.",
- },
"edit-file": {
title: "Modifică fișierul",
description: "Realizați modificări pe linii în fișierele de text.",
@@ -838,6 +826,44 @@ const TRANSLATIONS = {
title: "Copiază fișier",
description: "Copiați fișiere și directoare",
},
+ "write-text-file": {
+ title: "Creați un fișier de text",
+ description:
+ "Creați fișiere de text noi sau suprascrieți fișierele de text existente.",
+ },
+ },
+ },
+ createFiles: {
+ title: "Crearea de documente",
+ description:
+ "Permite-ți agentului să creeze formate de documente binare, cum ar fi prezentări PowerPoint, fișe Excel, documente Word și fișiere PDF. Fișierele pot fi descărcate direct din fereastra de chat.",
+ configuration: "Tipuri de documente disponibile",
+ skills: {
+ "create-text-file": {
+ title: "Fișiere text",
+ description:
+ "Creați fișiere text cu orice conținut și extensie (de exemplu, .txt, .md, .json, .csv, etc.)",
+ },
+ "create-pptx": {
+ title: "Prezentări PowerPoint",
+ description:
+ "Creați prezentări noi în PowerPoint, cu diapozitive, titluri și puncte.",
+ },
+ "create-pdf": {
+ title: "Documente în format PDF",
+ description:
+ "Creați documente PDF din fișiere Markdown sau text simplu, cu un stil de formatare de bază.",
+ },
+ "create-xlsx": {
+ title: "Fișe Excel",
+ description:
+ "Creați fișiere Excel pentru date tabulare, cu foi și stilizare.",
+ },
+ "create-docx": {
+ title: "Fișiere în format Word",
+ description:
+ "Creați documente Word cu un stil și formatare de bază.",
+ },
},
},
},
diff --git a/frontend/src/locales/ru/common.js b/frontend/src/locales/ru/common.js
index 05f7a9f58..af1100dd1 100644
--- a/frontend/src/locales/ru/common.js
+++ b/frontend/src/locales/ru/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "Добро пожаловать в",
getStarted: "Начать",
welcome: "Добро пожаловать",
},
@@ -309,11 +308,6 @@ const TRANSLATIONS = {
description:
"Включите возможность создания различных типов диаграмм из предоставленных данных или данных, указанных в чате.",
},
- save: {
- title: "Создание и сохранение файлов в браузер",
- description:
- "Включите возможность создания и записи файлов, которые можно сохранить и загрузить в вашем браузере.",
- },
web: {
title: "Поиск в Интернете и просмотр в реальном времени",
description:
@@ -358,10 +352,6 @@ const TRANSLATIONS = {
title: "Получить информацию о файле",
description: "Получите подробную информацию о метаданных файлов.",
},
- "write-file": {
- title: "Создать файл",
- description: "Создать новые файлы или перезаписать существующие",
- },
"edit-file": {
title: "Редактировать файл",
description:
@@ -379,6 +369,44 @@ const TRANSLATIONS = {
title: "Скопировать файл",
description: "Копировать файлы и каталоги",
},
+ "write-text-file": {
+ title: "Создать текстовый файл",
+ description:
+ "Создайте новые текстовые файлы или перезапишите существующие текстовые файлы.",
+ },
+ },
+ },
+ createFiles: {
+ title: "Создание документа",
+ description:
+ "Предоставьте своему агенту возможность создавать файлы в двоичном формате, такие как презентации PowerPoint, электронные таблицы Excel, документы Word и PDF. Файлы можно загружать непосредственно из окна чата.",
+ configuration: "Доступные типы документов",
+ skills: {
+ "create-text-file": {
+ title: "Текстовые файлы",
+ description:
+ "Создавайте текстовые файлы с любым содержимым и расширением (.txt, .md, .json, .csv и т. д.)",
+ },
+ "create-pptx": {
+ title: "Презентации в формате PowerPoint",
+ description:
+ "Создайте новые презентации в формате PowerPoint, включая слайды, заголовки и списки с маркерами.",
+ },
+ "create-pdf": {
+ title: "Документы в формате PDF",
+ description:
+ "Создавайте документы в формате PDF из Markdown или простого текста с использованием базового оформления.",
+ },
+ "create-xlsx": {
+ title: "Электронные таблицы в программе Excel",
+ description:
+ "Создайте документы Excel для табличных данных, включающие листы и оформление.",
+ },
+ "create-docx": {
+ title: "Документы в формате Word",
+ description:
+ "Создавайте документы в формате Word с использованием базовых стилей и форматирования.",
+ },
},
},
},
@@ -698,7 +726,6 @@ const TRANSLATIONS = {
select_all: "Выбрать всё",
deselect_all: "Снять выбор со всех",
remove_selected: "Удалить выбранные",
- costs: "*Единоразовая стоимость за внедрение",
save_embed: "Сохранить и внедрить",
"total-documents_one": "{{count}} документ",
"total-documents_other": "{{count}} документы",
diff --git a/frontend/src/locales/tr/common.js b/frontend/src/locales/tr/common.js
index b3ab1c184..c84a76e8e 100644
--- a/frontend/src/locales/tr/common.js
+++ b/frontend/src/locales/tr/common.js
@@ -17,7 +17,6 @@ const TRANSLATIONS = {
"AnythingLLM'yi ihtiyaçlarınıza göre oluşturmamıza yardımcı olun. İsteğe bağlı.",
},
home: {
- title: "Hoş Geldiniz",
getStarted: "Başla",
welcome: "Hoş geldiniz",
},
@@ -309,11 +308,6 @@ const TRANSLATIONS = {
description:
"Varsayılan ajanın, sağlanan veya sohbette yer alan verilere göre çeşitli grafik türleri oluşturmasına izin verin.",
},
- save: {
- title: "Tarayıcıya dosya oluştur & kaydet",
- description:
- "Varsayılan ajanın, oluşturduğu dosyaları kaydetmesine ve tarayıcıda indirilebilir hale getirmesine izin verin.",
- },
web: {
title: "Canlı web araması ve gezinme",
description:
@@ -359,11 +353,6 @@ const TRANSLATIONS = {
title: "Dosya Hakkında Bilgi Al",
description: "Dosyalara ilişkin ayrıntılı meta verileri elde edin.",
},
- "write-file": {
- title: "Dosya Oluştur",
- description:
- "Yeni dosyalar oluşturun veya mevcut dosyaları üzerine yazın.",
- },
"edit-file": {
title: "Dosya Düzenle",
description: "Metin dosyalarında satır bazlı değişiklikler yapın.",
@@ -381,6 +370,44 @@ const TRANSLATIONS = {
title: "Dosyayı Kopyala",
description: "Dosyaları ve dizinleri kopyala",
},
+ "write-text-file": {
+ title: "Metin dosyası oluştur",
+ description:
+ "Yeni metin dosyaları oluşturun veya mevcut metin dosyalarını üzerine yazın.",
+ },
+ },
+ },
+ createFiles: {
+ title: "Belge Oluşturma",
+ description:
+ "Temsilcinizin, PowerPoint sunumları, Excel tabloları, Word belgeleri ve PDF dosyaları gibi ikili belge formatları oluşturmasına olanak tanıyın. Dosyalar doğrudan sohbet penceresinden indirilebilir.",
+ configuration: "Mevcut Belgeler Türleri",
+ skills: {
+ "create-text-file": {
+ title: "Metin dosyaları",
+ description:
+ "Herhangi bir içerik ve uzantıyla (örneğin .txt, .md, .json, .csv vb.) metin dosyaları oluşturun.",
+ },
+ "create-pptx": {
+ title: "PowerPoint sunumları",
+ description:
+ "Yeni PowerPoint sunumları oluşturun, slaytlar, başlıklar ve madde işaretleri ekleyin.",
+ },
+ "create-pdf": {
+ title: "PDF belgeleri",
+ description:
+ "Temel stillerle markdown veya düz metinlerden PDF belgeleri oluşturun.",
+ },
+ "create-xlsx": {
+ title: "Excel elektronik tabloları",
+ description:
+ "Tablo formatındaki veriler için, sayfalar ve stil özellikleriyle Excel belgeleri oluşturun.",
+ },
+ "create-docx": {
+ title: "Kelime belgeleri",
+ description:
+ "Temel stil ve biçimlendirme ile Word belgeleri oluşturun.",
+ },
},
},
},
@@ -700,7 +727,6 @@ const TRANSLATIONS = {
select_all: "Tümünü Seç",
deselect_all: "Tümünün Seçimini Kaldır",
remove_selected: "Seçilenleri Kaldır",
- costs: "*Gömmeler için tek seferlik maliyet",
save_embed: "Kaydet ve Göm",
"total-documents_one": "{{count}} belgesi",
"total-documents_other": "{{count}} belgeleri",
diff --git a/frontend/src/locales/vn/common.js b/frontend/src/locales/vn/common.js
index 9d3d0c12e..d70853f69 100644
--- a/frontend/src/locales/vn/common.js
+++ b/frontend/src/locales/vn/common.js
@@ -17,7 +17,6 @@ const TRANSLATIONS = {
"Giúp chúng tôi xây dựng AnythingLLM phù hợp với nhu cầu của bạn. Tùy chọn.",
},
home: {
- title: "Chào mừng đến",
getStarted: "Bắt đầu",
welcome: "Chào mừng",
},
@@ -308,11 +307,6 @@ const TRANSLATIONS = {
description:
"Cho phép agent mặc định tạo các loại biểu đồ khác nhau từ dữ liệu được cung cấp hoặc đưa ra trong trò chuyện.",
},
- save: {
- title: "Tạo & lưu tệp",
- description:
- "Cho phép agent mặc định tạo và ghi vào các tệp có thể lưu vào máy tính của bạn.",
- },
web: {
title: "Tìm kiếm web trực tiếp và duyệt web",
description:
@@ -357,10 +351,6 @@ const TRANSLATIONS = {
title: "Lấy thông tin tệp",
description: "Lấy thông tin chi tiết về các tệp tin.",
},
- "write-file": {
- title: "Tạo tệp",
- description: "Tạo các tệp mới hoặc ghi đè các tệp hiện có",
- },
"edit-file": {
title: "Chỉnh sửa tệp",
description:
@@ -378,6 +368,44 @@ const TRANSLATIONS = {
title: "Sao chép tệp",
description: "Sao chép các tệp tin và thư mục",
},
+ "write-text-file": {
+ title: "Tạo tệp văn bản",
+ description:
+ "Tạo các tệp văn bản mới hoặc ghi đè các tệp văn bản hiện có.",
+ },
+ },
+ },
+ createFiles: {
+ title: "Tạo tài liệu",
+ description:
+ "Cho phép đại lý của bạn tạo các định dạng tài liệu nhị phân như bài thuyết trình PowerPoint, bảng tính Excel, tài liệu Word và PDF. Các tệp có thể tải xuống trực tiếp từ cửa sổ trò chuyện.",
+ configuration: "Các loại tài liệu có sẵn",
+ skills: {
+ "create-text-file": {
+ title: "Tệp văn bản",
+ description:
+ "Tạo các tệp văn bản với bất kỳ nội dung và định dạng nào (ví dụ: .txt, .md, .json, .csv, v.v.)",
+ },
+ "create-pptx": {
+ title: "Bài trình bày bằng PowerPoint",
+ description:
+ "Tạo các bài trình chiếu PowerPoint mới với các slide, tiêu đề và dấu đầu dòng.",
+ },
+ "create-pdf": {
+ title: "Tài liệu PDF",
+ description:
+ "Tạo tài liệu PDF từ Markdown hoặc văn bản thuần túy với các định dạng cơ bản.",
+ },
+ "create-xlsx": {
+ title: "Bảng tính Excel",
+ description:
+ "Tạo các tài liệu Excel cho dữ liệu dạng bảng, bao gồm các sheet và định dạng.",
+ },
+ "create-docx": {
+ title: "Tệp Word",
+ description:
+ "Tạo các tài liệu Word với định dạng và kiểu dáng cơ bản.",
+ },
},
},
},
@@ -695,7 +723,6 @@ const TRANSLATIONS = {
select_all: "Chọn Tất cả",
deselect_all: "Bỏ chọn Tất cả",
remove_selected: "Xóa Đã chọn",
- costs: "*Chi phí một lần cho việc nhúng",
save_embed: "Lưu và Nhúng",
"total-documents_one": "{{count}}",
"total-documents_other": "{{count}}",
diff --git a/frontend/src/locales/zh/common.js b/frontend/src/locales/zh/common.js
index 5b8859e3f..088821b44 100644
--- a/frontend/src/locales/zh/common.js
+++ b/frontend/src/locales/zh/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "欢迎使用",
getStarted: "开始",
welcome: "欢迎",
},
@@ -300,11 +299,6 @@ const TRANSLATIONS = {
title: "生成图表",
description: "使默认代理能够从提供的数据或聊天中生成各种类型的图表。",
},
- save: {
- title: "生成并保存文件到浏览器",
- description:
- "使默认代理能够生成并写入文件,这些文件可以保存并在你的浏览器中下载。",
- },
web: {
title: "实时网络搜索和浏览",
description:
@@ -348,10 +342,6 @@ const TRANSLATIONS = {
title: "获取文件信息",
description: "获取有关文件的详细元数据",
},
- "write-file": {
- title: "创建文件",
- description: "创建新的文件或覆盖现有文件",
- },
"edit-file": {
title: "编辑文件",
description: "对文本文件进行基于行的编辑。",
@@ -368,6 +358,40 @@ const TRANSLATIONS = {
title: "复制文件",
description: "复制文件和目录",
},
+ "write-text-file": {
+ title: "创建文本文件",
+ description: "创建新的文本文件,或覆盖现有的文本文件。",
+ },
+ },
+ },
+ createFiles: {
+ title: "文档创建",
+ description:
+ "允许您的代理创建二进制文档格式,例如PowerPoint演示文稿、Excel电子表格、Word文档和PDF文件。文件可以直接从聊天窗口下载。",
+ configuration: "可用的文件类型",
+ skills: {
+ "create-text-file": {
+ title: "文本文件",
+ description:
+ "创建包含任何内容和扩展名的文本文件(如 .txt、.md、.json、.csv 等)。",
+ },
+ "create-pptx": {
+ title: "PowerPoint 演示文稿",
+ description: "创建新的幻灯片演示文稿,包括幻灯片、标题和项目符号。",
+ },
+ "create-pdf": {
+ title: "PDF 文档",
+ description:
+ "使用 Markdown 或纯文本,并进行基本的排版,创建 PDF 文档。",
+ },
+ "create-xlsx": {
+ title: "Excel电子表格",
+ description: "创建包含表格数据、工作表和样式的 Excel 文档。",
+ },
+ "create-docx": {
+ title: "Word 文档",
+ description: "创建包含基本样式和格式的 Word 文档",
+ },
},
},
},
@@ -744,7 +768,6 @@ const TRANSLATIONS = {
select_all: "全选",
deselect_all: "取消全选",
remove_selected: "移除所选",
- costs: "*嵌入时一次性费用",
save_embed: "保存并嵌入",
"total-documents_one": "{{count}} 文件",
"total-documents_other": "{{count}} 类型的文件",
diff --git a/frontend/src/locales/zh_TW/common.js b/frontend/src/locales/zh_TW/common.js
index 955ce2ae3..f070e3a01 100644
--- a/frontend/src/locales/zh_TW/common.js
+++ b/frontend/src/locales/zh_TW/common.js
@@ -2,7 +2,6 @@
const TRANSLATIONS = {
onboarding: {
home: {
- title: "歡迎使用",
getStarted: "開始使用",
welcome: "歡迎",
},
@@ -291,10 +290,6 @@ const TRANSLATIONS = {
description:
"讓預設智慧代理人能夠根據提供的資料或對話中給定的資料來產生各種圖表。",
},
- save: {
- title: "產生並儲存檔案",
- description: "讓預設智慧代理人產生並寫入檔案,之後可儲存到電腦。",
- },
web: {
title: "網頁搜尋",
description:
@@ -337,10 +332,6 @@ const TRANSLATIONS = {
title: "取得檔案資訊",
description: "獲取關於檔案的詳細元數據",
},
- "write-file": {
- title: "儲存檔案",
- description: "建立新的檔案或覆蓋現有檔案",
- },
"edit-file": {
title: "編輯檔案",
description: "能夠對文字檔案進行行別編輯。",
@@ -357,6 +348,40 @@ const TRANSLATIONS = {
title: "複製檔案",
description: "複製檔案和目錄",
},
+ "write-text-file": {
+ title: "撰寫文字檔案",
+ description: "建立新的文字檔,或覆蓋現有的文字檔。",
+ },
+ },
+ },
+ createFiles: {
+ title: "文件建立",
+ description:
+ "允許您的代理創建二元文件格式,例如PowerPoint簡報、Excel電子表格、Word文件和PDF文件。 文件可以直接從聊天窗口下載。",
+ configuration: "可用的文件類型",
+ skills: {
+ "create-text-file": {
+ title: "文字檔",
+ description:
+ "能夠創建包含任何內容和檔案擴展名(例如:.txt、.md、.json、.csv 等)的文字檔案。",
+ },
+ "create-pptx": {
+ title: "PowerPoint 簡報",
+ description: "創建新的 PowerPoint 簡報,包含幻燈片、標題和要點",
+ },
+ "create-pdf": {
+ title: "PDF 文件",
+ description:
+ "能夠從 Markdown 或純文字檔案中,使用基本的格式設定,創建 PDF 文件。",
+ },
+ "create-xlsx": {
+ title: "Excel 試算表",
+ description: "建立包含表格資料、工作表和樣式的 Excel 文件",
+ },
+ "create-docx": {
+ title: "Word 格式的文件",
+ description: "建立包含基本樣式和格式的 Word 文件",
+ },
},
},
},
@@ -654,7 +679,6 @@ const TRANSLATIONS = {
select_all: "全選",
deselect_all: "取消全選",
remove_selected: "移除選擇的項目",
- costs: "*嵌入僅會計費一次",
save_embed: "儲存並嵌入",
"total-documents_one": "{{count}} 文件",
"total-documents_other": "{{count}} 文件",
diff --git a/frontend/src/models/files.js b/frontend/src/models/files.js
new file mode 100644
index 000000000..c3001531c
--- /dev/null
+++ b/frontend/src/models/files.js
@@ -0,0 +1,26 @@
+import { API_BASE } from "@/utils/constants";
+import { baseHeaders } from "@/utils/request";
+
+const StorageFiles = {
+ /**
+ * Download a file from the server
+ * @param {string} filename - The filename to download
+ * @returns {Promise
}
+ */
+ download: async function (storageFilename) {
+ return await fetch(
+ `${API_BASE}/agent-skills/generated-files/${encodeURIComponent(storageFilename)}`,
+ { headers: baseHeaders() }
+ )
+ .then((res) => {
+ if (!res.ok) throw new Error("Failed to download file");
+ return res.blob();
+ })
+ .catch((e) => {
+ console.error("Download failed:", e);
+ return null;
+ });
+ },
+};
+
+export default StorageFiles;
diff --git a/frontend/src/models/system.js b/frontend/src/models/system.js
index 7ac0bc9f7..115dbd6dd 100644
--- a/frontend/src/models/system.js
+++ b/frontend/src/models/system.js
@@ -848,6 +848,21 @@ const System = {
.catch(() => false);
},
+ /**
+ * Checks if the create-files-agent skill is available.
+ * The create-files-agent skill is only available when running in a Docker container.
+ * @returns {Promise}
+ */
+ isCreateFilesAgentAvailable: async function () {
+ return fetch(`${API_BASE}/agent-skills/create-files-agent/is-available`, {
+ method: "GET",
+ headers: baseHeaders(),
+ })
+ .then((res) => res.json())
+ .then((res) => res?.available ?? false)
+ .catch(() => false);
+ },
+
experimentalFeatures: {
liveSync: LiveDocumentSync,
agentPlugins: AgentPlugins,
diff --git a/frontend/src/pages/Admin/Agents/CreateFileSkillPanel/index.jsx b/frontend/src/pages/Admin/Agents/CreateFileSkillPanel/index.jsx
new file mode 100644
index 000000000..6b5eab367
--- /dev/null
+++ b/frontend/src/pages/Admin/Agents/CreateFileSkillPanel/index.jsx
@@ -0,0 +1,187 @@
+import React, { useEffect, useState, useRef } from "react";
+import Toggle, { SimpleToggleSwitch } from "@/components/lib/Toggle";
+import { useTranslation } from "react-i18next";
+import {
+ FilePpt,
+ FileXls,
+ FileDoc,
+ FilePdf,
+ FileText,
+ CircleNotch,
+} from "@phosphor-icons/react";
+import Admin from "@/models/admin";
+
+const getCreateFileSkills = (t) => [
+ {
+ name: "create-text-file",
+ title: t("agent.skill.createFiles.skills.create-text-file.title"),
+ description: t(
+ "agent.skill.createFiles.skills.create-text-file.description"
+ ),
+ icon: FileText,
+ },
+ {
+ name: "create-pptx-presentation",
+ title: t("agent.skill.createFiles.skills.create-pptx.title"),
+ description: t("agent.skill.createFiles.skills.create-pptx.description"),
+ icon: FilePpt,
+ },
+ {
+ name: "create-pdf-file",
+ title: t("agent.skill.createFiles.skills.create-pdf.title"),
+ description: t("agent.skill.createFiles.skills.create-pdf.description"),
+ icon: FilePdf,
+ },
+ {
+ name: "create-excel-file",
+ title: t("agent.skill.createFiles.skills.create-xlsx.title"),
+ description: t("agent.skill.createFiles.skills.create-xlsx.description"),
+ icon: FileXls,
+ },
+ {
+ name: "create-docx-file",
+ title: t("agent.skill.createFiles.skills.create-docx.title"),
+ description: t("agent.skill.createFiles.skills.create-docx.description"),
+ icon: FileDoc,
+ },
+];
+
+export default function CreateFileSkillPanel({
+ title,
+ skill,
+ toggleSkill,
+ enabled = false,
+ disabled = false,
+ image,
+ icon,
+ setHasChanges,
+ hasChanges = false,
+}) {
+ const { t } = useTranslation();
+ const [disabledSkills, setDisabledSkills] = useState([]);
+ const [loading, setLoading] = useState(true);
+ const prevHasChanges = useRef(hasChanges);
+ const skills = getCreateFileSkills(t);
+
+ useEffect(() => {
+ setLoading(true);
+ Admin.systemPreferencesByFields(["disabled_create_files_skills"])
+ .then((res) =>
+ setDisabledSkills(res?.settings?.disabled_create_files_skills ?? [])
+ )
+ .catch(() => setDisabledSkills([]))
+ .finally(() => setLoading(false));
+ }, []);
+
+ useEffect(() => {
+ if (prevHasChanges.current === true && hasChanges === false) {
+ Admin.systemPreferencesByFields(["disabled_create_files_skills"])
+ .then((res) =>
+ setDisabledSkills(res?.settings?.disabled_create_files_skills ?? [])
+ )
+ .catch(() => {});
+ }
+ prevHasChanges.current = hasChanges;
+ }, [hasChanges]);
+
+ function toggleFileSkill(skillName) {
+ setHasChanges(true);
+ setDisabledSkills((prev) =>
+ prev.includes(skillName)
+ ? prev.filter((s) => s !== skillName)
+ : [...prev, skillName]
+ );
+ }
+
+ return (
+
+
+
+
+ {icon &&
+ React.createElement(icon, {
+ size: 24,
+ color: "var(--theme-text-primary)",
+ weight: "bold",
+ })}
+
+
+
toggleSkill(skill)}
+ />
+
+
+

+
+ {t("agent.skill.createFiles.description")}
+
+
+ {enabled && (
+ <>
+
+
+
+ {t("agent.skill.createFiles.configuration")}
+
+ {loading ? (
+
+
+
+ ) : (
+
+ {skills.map((fileSkill) => (
+ toggleFileSkill(fileSkill.name)}
+ />
+ ))}
+
+ )}
+
+ >
+ )}
+
+
+ );
+}
+
+function SkillRow({ skill, disabled, onToggle }) {
+ const Icon = skill.icon;
+ return (
+
+
+
+
+
+ {skill.title}
+
+ {skill.description}
+
+
+
+
+ );
+}
diff --git a/frontend/src/pages/Admin/Agents/FileSystemSkillPanel/index.jsx b/frontend/src/pages/Admin/Agents/FileSystemSkillPanel/index.jsx
index 474846ba6..20a99135e 100644
--- a/frontend/src/pages/Admin/Agents/FileSystemSkillPanel/index.jsx
+++ b/frontend/src/pages/Admin/Agents/FileSystemSkillPanel/index.jsx
@@ -62,9 +62,11 @@ const getFileSystemSubSkills = (t) => {
category: "read",
},
{
- name: "filesystem-write-file",
- title: t("agent.skill.filesystem.skills.write-file.title"),
- description: t("agent.skill.filesystem.skills.write-file.description"),
+ name: "filesystem-write-text-file",
+ title: t("agent.skill.filesystem.skills.write-text-file.title"),
+ description: t(
+ "agent.skill.filesystem.skills.write-text-file.description"
+ ),
icon: FloppyDisk,
category: "write",
},
diff --git a/frontend/src/pages/Admin/Agents/index.jsx b/frontend/src/pages/Admin/Agents/index.jsx
index 2bb8617de..a598e1eb1 100644
--- a/frontend/src/pages/Admin/Agents/index.jsx
+++ b/frontend/src/pages/Admin/Agents/index.jsx
@@ -60,10 +60,13 @@ export default function AdminAgents() {
const [fileSystemAgentAvailable, setFileSystemAgentAvailable] =
useState(false);
+ const [createFilesAgentAvailable, setCreateFilesAgentAvailable] =
+ useState(false);
const defaultSkills = getDefaultSkills(t);
const configurableSkills = getConfigurableSkills(t, {
fileSystemAgentAvailable,
+ createFilesAgentAvailable,
});
// Alert user if they try to leave the page with unsaved changes
@@ -82,18 +85,24 @@ export default function AdminAgents() {
useEffect(() => {
async function fetchSettings() {
- const [_settings, _preferences, flowsRes, fsAgentAvailable] =
- await Promise.all([
- System.keys(),
- Admin.systemPreferencesByFields([
- "disabled_agent_skills",
- "default_agent_skills",
- "imported_agent_skills",
- "active_agent_flows",
- ]),
- AgentFlows.listFlows(),
- System.isFileSystemAgentAvailable(),
- ]);
+ const [
+ _settings,
+ _preferences,
+ flowsRes,
+ fsAgentAvailable,
+ createFilesAvailable,
+ ] = await Promise.all([
+ System.keys(),
+ Admin.systemPreferencesByFields([
+ "disabled_agent_skills",
+ "default_agent_skills",
+ "imported_agent_skills",
+ "active_agent_flows",
+ ]),
+ AgentFlows.listFlows(),
+ System.isFileSystemAgentAvailable(),
+ System.isCreateFilesAgentAvailable(),
+ ]);
const { flows = [] } = flowsRes;
setSettings({ ..._settings, preferences: _preferences.settings } ?? {});
@@ -105,6 +114,7 @@ export default function AdminAgents() {
setActiveFlowIds(_preferences.settings?.active_agent_flows ?? []);
setAgentFlows(flows);
setFileSystemAgentAvailable(fsAgentAvailable);
+ setCreateFilesAgentAvailable(createFilesAvailable);
setLoading(false);
}
fetchSettings();
diff --git a/frontend/src/pages/Admin/Agents/skills.js b/frontend/src/pages/Admin/Agents/skills.js
index 555c51dc6..8c0aabed2 100644
--- a/frontend/src/pages/Admin/Agents/skills.js
+++ b/frontend/src/pages/Admin/Agents/skills.js
@@ -3,13 +3,14 @@ import AgentSQLConnectorSelection from "./SQLConnectorSelection";
import GenericSkillPanel from "./GenericSkillPanel";
import DefaultSkillPanel from "./DefaultSkillPanel";
import FileSystemSkillPanel from "./FileSystemSkillPanel";
+import CreateFileSkillPanel from "./CreateFileSkillPanel";
import {
Brain,
File,
Browser,
ChartBar,
- FileMagnifyingGlass,
FolderOpen,
+ FilePlus,
} from "@phosphor-icons/react";
import RAGImage from "@/media/agents/rag-memory.png";
import SummarizeImage from "@/media/agents/view-summarize.png";
@@ -47,7 +48,7 @@ export const getDefaultSkills = (t) => ({
export const getConfigurableSkills = (
t,
- { fileSystemAgentAvailable = true } = {}
+ { fileSystemAgentAvailable = true, createFilesAgentAvailable = true } = {}
) => ({
...(fileSystemAgentAvailable && {
"filesystem-agent": {
@@ -59,14 +60,16 @@ export const getConfigurableSkills = (
image: FileSystemImage,
},
}),
- "save-file-to-browser": {
- title: t("agent.skill.save.title"),
- description: t("agent.skill.save.description"),
- component: GenericSkillPanel,
- skill: "save-file-to-browser",
- icon: FileMagnifyingGlass,
- image: GenerateSaveImages,
- },
+ ...(createFilesAgentAvailable && {
+ "create-files-agent": {
+ title: t("agent.skill.createFiles.title"),
+ description: t("agent.skill.createFiles.description"),
+ component: CreateFileSkillPanel,
+ skill: "create-files-agent",
+ icon: FilePlus,
+ image: GenerateSaveImages,
+ },
+ }),
"create-chart": {
title: t("agent.skill.generate.title"),
description: t("agent.skill.generate.description"),
diff --git a/frontend/src/utils/chat/agent.js b/frontend/src/utils/chat/agent.js
index 858bd1f5d..4c1ae9e9b 100644
--- a/frontend/src/utils/chat/agent.js
+++ b/frontend/src/utils/chat/agent.js
@@ -1,6 +1,5 @@
import { v4 } from "uuid";
import { safeJsonParse } from "../request";
-import { saveAs } from "file-saver";
import { API_BASE } from "../constants";
import { useEffect, useState } from "react";
@@ -8,7 +7,7 @@ export const AGENT_SESSION_START = "agentSessionStart";
export const AGENT_SESSION_END = "agentSessionEnd";
const handledEvents = [
"statusResponse",
- "fileDownload",
+ "fileDownloadCard",
"awaitingFeedback",
"wssFailure",
"rechartVisualize",
@@ -91,6 +90,9 @@ export default function handleSocketResponse(socket, event, setChatHistory) {
// Providers like Gemini send large chunks and can complete in a single chunk before the update logic can convert it.
// Other providers send many small chunks so the second chunk triggers the update logic to fix the type.
if (data.content.type === "textResponseChunk") {
+ // If this first chunk is just a non-text char (like \n, \t, etc.) then we need to ignore it.
+ // Some providers like LMStudio will do this and it depends on the chat template as well.
+ if (data.content.content.trim() === "") return prev;
return [
...prev.filter((msg) => !!msg.content),
{
@@ -157,6 +159,7 @@ export default function handleSocketResponse(socket, event, setChatHistory) {
}
if (type === "textResponseChunk") {
+ console.log("textResponseChunk", data.content);
return prev
.map((msg) =>
msg.uuid === uuid
@@ -182,9 +185,24 @@ export default function handleSocketResponse(socket, event, setChatHistory) {
});
}
- if (data.type === "fileDownload") {
- saveAs(data.content.b64Content, data.content.filename ?? "unknown.txt");
- return;
+ if (data.type === "fileDownloadCard") {
+ return setChatHistory((prev) => {
+ return [
+ ...prev.filter((msg) => !!msg.content),
+ {
+ type: "fileDownloadCard",
+ uuid: v4(),
+ content: data.content,
+ role: "assistant",
+ sources: [],
+ closed: true,
+ error: null,
+ animate: false,
+ pending: false,
+ metrics: data.metrics || {},
+ },
+ ];
+ });
}
if (data.type === "rechartVisualize") {
diff --git a/server/.gitignore b/server/.gitignore
index c4147a0a1..51930d38e 100644
--- a/server/.gitignore
+++ b/server/.gitignore
@@ -4,6 +4,7 @@
server/.env
storage/assets/*
!storage/assets/anything-llm.png
+!storage/assets/anything-llm-invert.png
storage/documents/*
storage/comkey/*
storage/tmp/*
@@ -11,6 +12,7 @@ storage/vector-cache/*.json
storage/exports
storage/imports
storage/anythingllm-fs/*
+storage/generated-files/*
storage/plugins/agent-skills/*
storage/plugins/agent-flows/*
storage/plugins/office-extensions/*
diff --git a/server/endpoints/admin.js b/server/endpoints/admin.js
index 4315d03e3..430a3e320 100644
--- a/server/endpoints/admin.js
+++ b/server/endpoints/admin.js
@@ -406,6 +406,9 @@ function adminEndpoints(app) {
case "disabled_filesystem_skills":
requestedSettings[label] = safeJsonParse(setting?.value, []);
break;
+ case "disabled_create_files_skills":
+ requestedSettings[label] = safeJsonParse(setting?.value, []);
+ break;
case "imported_agent_skills":
requestedSettings[label] = ImportedPlugin.listImportedPlugins();
break;
diff --git a/server/endpoints/agentFileServer.js b/server/endpoints/agentFileServer.js
new file mode 100644
index 000000000..daaf5002a
--- /dev/null
+++ b/server/endpoints/agentFileServer.js
@@ -0,0 +1,142 @@
+const {
+ userFromSession,
+ multiUserMode,
+ safeJsonParse,
+} = require("../utils/http");
+const { validatedRequest } = require("../utils/middleware/validatedRequest");
+const {
+ flexUserRoleValid,
+ ROLES,
+} = require("../utils/middleware/multiUserProtected");
+const { WorkspaceChats } = require("../models/workspaceChats");
+const { Workspace } = require("../models/workspace");
+const createFilesLib = require("../utils/agents/aibitat/plugins/create-files/lib");
+
+/**
+ * Endpoints for serving agent-generated files (PPTX, etc.) with authentication
+ * and ownership validation.
+ */
+function agentFileServerEndpoints(app) {
+ if (!app) return;
+
+ /**
+ * Download a generated file by its storage filename.
+ * Validates that the requesting user has access to the workspace
+ * where the file was generated.
+ */
+ app.get(
+ "/agent-skills/generated-files/:filename",
+ [validatedRequest, flexUserRoleValid([ROLES.all])],
+ async (request, response) => {
+ try {
+ const user = await userFromSession(request, response);
+ const { filename } = request.params;
+ if (!filename)
+ return response.status(400).json({ error: "Filename is required" });
+
+ // Validate filename format
+ const parsed = createFilesLib.parseFilename(filename);
+ if (!parsed) {
+ return response
+ .status(400)
+ .json({ error: "Invalid filename format" });
+ }
+
+ // Find a chat record that references this file and that the user can access
+ const validChat = await findValidChatForFile(
+ filename,
+ user,
+ multiUserMode(response)
+ );
+
+ if (!validChat) {
+ return response.status(404).json({
+ error: "File not found or access denied",
+ });
+ }
+
+ // Retrieve the file from storage
+ const fileData = await createFilesLib.getGeneratedFile(filename);
+ if (!fileData) {
+ return response
+ .status(404)
+ .json({ error: "File not found in storage" });
+ }
+
+ // Get mime type and set headers for download
+ const mimeType = createFilesLib.getMimeType(`.${parsed.extension}`);
+ const safeFilename = createFilesLib.sanitizeFilenameForHeader(
+ validChat.displayFilename || filename
+ );
+ response.setHeader("Content-Type", mimeType);
+ response.setHeader(
+ "Content-Disposition",
+ `attachment; filename="${safeFilename}"`
+ );
+ response.setHeader("Content-Length", fileData.buffer.length);
+ return response.send(fileData.buffer);
+ } catch (error) {
+ console.error("[agentFileServer] Download error:", error.message);
+ return response.status(500).json({ error: "Failed to download file" });
+ }
+ }
+ );
+}
+
+/**
+ * Finds a valid chat record that references the given storage filename
+ * and that the user has access to.
+ * @param {string} storageFilename - The storage filename to search for
+ * @param {object|null} user - The user object (null in single-user mode)
+ * @param {boolean} isMultiUser - Whether multi-user mode is enabled
+ * @returns {Promise<{workspaceId: number, displayFilename: string}|null>}
+ */
+async function findValidChatForFile(storageFilename, user, isMultiUser) {
+ try {
+ // Get all workspaces the user has access to.
+ // In single-user mode, all workspaces are accessible.
+ // In multi-user mode, only workspaces assigned to the user are accessible.
+ let workspaceIds;
+ if (isMultiUser && user) {
+ const workspaces = await Workspace.whereWithUser(user);
+ workspaceIds = workspaces.map((w) => w.id);
+ } else {
+ const workspaces = await Workspace.where();
+ workspaceIds = workspaces.map((w) => w.id);
+ }
+
+ if (workspaceIds.length === 0) return null;
+
+ // Use database-level filtering to only fetch chats that contain the filename
+ // This avoids loading all chats into memory
+ const chats = await WorkspaceChats.where({
+ workspaceId: { in: workspaceIds },
+ include: true,
+ response: { contains: storageFilename },
+ });
+
+ for (const chat of chats) {
+ try {
+ const response = safeJsonParse(chat.response, { outputs: [] });
+ const output = response.outputs.find(
+ (o) => o?.payload?.storageFilename === storageFilename
+ );
+ if (!output) continue;
+ return {
+ workspaceId: chat.workspaceId,
+ displayFilename:
+ output.payload.filename || output.payload.displayFilename,
+ };
+ } catch {
+ continue;
+ }
+ }
+
+ return null;
+ } catch (error) {
+ console.error("[findValidChatForFile] Error:", error.message);
+ return null;
+ }
+}
+
+module.exports = { agentFileServerEndpoints };
diff --git a/server/endpoints/agentSkillWhitelist.js b/server/endpoints/agentSkillWhitelist.js
index 116fb9ec2..c54dcefc7 100644
--- a/server/endpoints/agentSkillWhitelist.js
+++ b/server/endpoints/agentSkillWhitelist.js
@@ -27,6 +27,24 @@ function agentSkillWhitelistEndpoints(app) {
}
);
+ app.get(
+ "/agent-skills/create-files-agent/is-available",
+ [validatedRequest],
+ async (_request, response) => {
+ try {
+ const createFilesTool = require("../utils/agents/aibitat/plugins/create-files/lib");
+ return response
+ .status(200)
+ .json({ available: createFilesTool.isToolAvailable() });
+ } catch (e) {
+ console.error(e);
+ return response
+ .status(500)
+ .json({ available: false, error: e.message });
+ }
+ }
+ );
+
app.post(
"/agent-skills/whitelist/add",
[validatedRequest, flexUserRoleValid(ROLES.all)],
diff --git a/server/endpoints/utils.js b/server/endpoints/utils.js
index e9e2f7ffc..b9331c0ab 100644
--- a/server/endpoints/utils.js
+++ b/server/endpoints/utils.js
@@ -210,4 +210,5 @@ module.exports = {
getGitVersion,
getModelTag,
getAnythingLLMUserAgent,
+ getDeploymentVersion,
};
diff --git a/server/index.js b/server/index.js
index 8924d1e61..5d6b94da6 100644
--- a/server/index.js
+++ b/server/index.js
@@ -26,6 +26,7 @@ const { agentWebsocket } = require("./endpoints/agentWebsocket");
const {
agentSkillWhitelistEndpoints,
} = require("./endpoints/agentSkillWhitelist");
+const { agentFileServerEndpoints } = require("./endpoints/agentFileServer");
const { experimentalEndpoints } = require("./endpoints/experimental");
const { browserExtensionEndpoints } = require("./endpoints/browserExtension");
const { communityHubEndpoints } = require("./endpoints/communityHub");
@@ -79,6 +80,7 @@ utilEndpoints(apiRouter);
documentEndpoints(apiRouter);
agentWebsocket(apiRouter);
agentSkillWhitelistEndpoints(apiRouter);
+agentFileServerEndpoints(apiRouter);
experimentalEndpoints(apiRouter);
developerEndpoints(app, apiRouter);
communityHubEndpoints(apiRouter);
diff --git a/server/jobs/cleanup-generated-files.js b/server/jobs/cleanup-generated-files.js
new file mode 100644
index 000000000..c8c6ee466
--- /dev/null
+++ b/server/jobs/cleanup-generated-files.js
@@ -0,0 +1,108 @@
+const { log, conclude } = require("./helpers/index.js");
+const { WorkspaceChats } = require("../models/workspaceChats.js");
+const createFilesLib = require("../utils/agents/aibitat/plugins/create-files/lib.js");
+const { safeJsonParse } = require("../utils/http/index.js");
+
+(async () => {
+ try {
+ const fs = require("fs");
+ const path = require("path");
+ const storageDirectory = await createFilesLib.getOutputDirectory();
+ if (!fs.existsSync(storageDirectory)) return;
+
+ const files = fs.readdirSync(storageDirectory);
+ if (files.length === 0) return;
+
+ // Get all storage filenames referenced in active (include: true) chats
+ const activeFileRefs = await getActiveStorageFilenames();
+ const filesToDelete = [];
+ for (const filename of files) {
+ const fullPath = path.join(storageDirectory, filename);
+ const stat = fs.statSync(fullPath);
+
+ // Skip files/folders that don't match our naming pattern and add to deletion list
+ if (!filename.match(/^[a-z]+-[a-f0-9-]{36}(\.\w+)?$/i)) {
+ filesToDelete.push({ path: fullPath, isDirectory: stat.isDirectory() });
+ continue;
+ }
+
+ // If file/folder is not referenced in any active chat, add to deletion list
+ if (!activeFileRefs.has(filename))
+ filesToDelete.push({ path: fullPath, isDirectory: stat.isDirectory() });
+ }
+
+ if (filesToDelete.length === 0) return;
+
+ log(`Found ${filesToDelete.length} orphaned files/folders to delete.`);
+ let deletedCount = 0;
+ let failedCount = 0;
+ for (const { path: itemPath, isDirectory } of filesToDelete) {
+ try {
+ if (isDirectory) fs.rmSync(itemPath, { recursive: true });
+ else fs.unlinkSync(itemPath);
+ deletedCount++;
+ } catch (error) {
+ failedCount++;
+ log(`Failed to delete ${itemPath}: ${error.message}`);
+ }
+ }
+
+ log(
+ `Cleanup complete: deleted ${deletedCount} items, ${failedCount} failures.`
+ );
+ } catch (error) {
+ console.error(error);
+ log(`Error during cleanup: ${error.message}`);
+ } finally {
+ conclude();
+ }
+})();
+
+/**
+ * Retrieves all storage filenames referenced in active (include: true) workspace chats.
+ * Searches through the outputs array in chat responses.
+ * Uses pagination to avoid loading all chats into memory at once.
+ * @param {number} batchSize - Number of chats to process per batch (default: 50)
+ * @returns {Promise>}
+ */
+async function getActiveStorageFilenames(batchSize = 50) {
+ const storageFilenames = new Set();
+
+ try {
+ let offset = 0;
+ let hasMore = true;
+
+ while (hasMore) {
+ const chats = await WorkspaceChats.where(
+ { include: true },
+ batchSize,
+ { id: "asc" },
+ offset
+ );
+
+ if (chats.length === 0) {
+ hasMore = false;
+ break;
+ }
+
+ for (const chat of chats) {
+ try {
+ const response = safeJsonParse(chat.response, { outputs: [] });
+ for (const output of response.outputs) {
+ if (output?.payload?.storageFilename)
+ storageFilenames.add(output.payload.storageFilename);
+ }
+ } catch {
+ continue;
+ }
+ }
+
+ offset += chats.length;
+ hasMore = chats.length === batchSize;
+ }
+ } catch (error) {
+ console.error("[getActiveStorageFilenames] Error:", error.message);
+ }
+
+ return storageFilenames;
+}
diff --git a/server/models/systemSettings.js b/server/models/systemSettings.js
index c9c8197d0..13ccb5cd0 100644
--- a/server/models/systemSettings.js
+++ b/server/models/systemSettings.js
@@ -34,6 +34,7 @@ const SystemSettings = {
"default_agent_skills",
"disabled_agent_skills",
"disabled_filesystem_skills",
+ "disabled_create_files_skills",
"imported_agent_skills",
"custom_app_name",
"feature_flags",
@@ -52,6 +53,7 @@ const SystemSettings = {
"default_agent_skills",
"disabled_agent_skills",
"disabled_filesystem_skills",
+ "disabled_create_files_skills",
"agent_sql_connections",
"custom_app_name",
"default_system_prompt",
@@ -163,6 +165,15 @@ const SystemSettings = {
return JSON.stringify([]);
}
},
+ disabled_create_files_skills: (updates) => {
+ try {
+ const skills = updates.split(",").filter((skill) => !!skill);
+ return JSON.stringify(skills);
+ } catch {
+ console.error(`Could not validate disabled create files skills.`);
+ return JSON.stringify([]);
+ }
+ },
agent_sql_connections: async (updates) => {
const existingConnections = safeJsonParse(
(await SystemSettings.get({ label: "agent_sql_connections" }))?.value,
diff --git a/server/package.json b/server/package.json
index 4c9a07bfc..f99339621 100644
--- a/server/package.json
+++ b/server/package.json
@@ -32,6 +32,7 @@
"@langchain/core": "0.1.61",
"@langchain/openai": "0.0.28",
"@langchain/textsplitters": "0.0.0",
+ "@mdpdf/mdpdf": "0.1.4",
"@mintplex-labs/bree": "^9.2.5",
"@mintplex-labs/express-ws": "^5.0.7",
"@modelcontextprotocol/sdk": "^1.24.3",
@@ -54,8 +55,11 @@
"cohere-ai": "^7.19.0",
"cors": "^2.8.5",
"diff": "7.0.0",
+ "docx": "9.6.1",
+ "dompurify": "3.3.3",
"dotenv": "^16.0.3",
"elevenlabs": "^0.5.0",
+ "exceljs": "4.4.0",
"express": "^4.21.2",
"extract-json-from-string": "^1.0.1",
"fast-levenshtein": "^3.0.0",
@@ -67,7 +71,9 @@
"js-tiktoken": "^1.0.8",
"jsonrepair": "^3.7.0",
"jsonwebtoken": "^9.0.0",
+ "jsdom": "26.1.0",
"langchain": "0.1.36",
+ "marked": "15.0.12",
"mime": "^3.0.0",
"moment": "^2.29.4",
"mssql": "^10.0.2",
@@ -76,10 +82,12 @@
"node-telegram-bot-api": "^0.67.0",
"ollama": "^0.6.3",
"openai": "4.95.1",
+ "pdf-lib": "1.17.1",
"pg": "^8.11.5",
"pinecone-client": "^1.1.0",
"pluralize": "^8.0.0",
"posthog-node": "^3.1.1",
+ "pptxgenjs": "4.0.1",
"prisma": "5.3.1",
"slugify": "^1.6.6",
"strip-ansi": "^7.1.2",
diff --git a/server/storage/assets/anything-llm-invert.png b/server/storage/assets/anything-llm-invert.png
new file mode 100644
index 000000000..ec14d175d
Binary files /dev/null and b/server/storage/assets/anything-llm-invert.png differ
diff --git a/server/utils/BackgroundWorkers/index.js b/server/utils/BackgroundWorkers/index.js
index 12535a52d..85062b2b8 100644
--- a/server/utils/BackgroundWorkers/index.js
+++ b/server/utils/BackgroundWorkers/index.js
@@ -15,6 +15,11 @@ class BackgroundService {
timeout: "1m",
interval: "12hr",
},
+ {
+ name: "cleanup-generated-files",
+ timeout: "5m",
+ interval: "8hr",
+ },
];
#documentSyncJobs = [
diff --git a/server/utils/agents/aibitat/plugins/chat-history.js b/server/utils/agents/aibitat/plugins/chat-history.js
index 9058d51d4..99b0ca641 100644
--- a/server/utils/agents/aibitat/plugins/chat-history.js
+++ b/server/utils/agents/aibitat/plugins/chat-history.js
@@ -53,6 +53,7 @@ const chatHistory = {
const invocation = aibitat.handlerProps.invocation;
const metrics = aibitat.provider?.getUsage?.() ?? {};
const citations = aibitat._pendingCitations ?? [];
+ const outputs = aibitat._pendingOutputs ?? [];
await WorkspaceChats.new({
workspaceId: Number(invocation.workspace_id),
prompt,
@@ -62,11 +63,13 @@ const chatHistory = {
type: "chat",
attachments,
metrics,
+ ...(outputs.length > 0 ? { outputs } : {}),
},
user: { id: invocation?.user_id || null },
threadId: invocation?.thread_id || null,
});
aibitat.clearCitations?.();
+ aibitat._pendingOutputs = [];
},
_storeSpecial: async function (
aibitat,
@@ -75,6 +78,7 @@ const chatHistory = {
const invocation = aibitat.handlerProps.invocation;
const metrics = aibitat.provider?.getUsage?.() ?? {};
const citations = aibitat._pendingCitations ?? [];
+ const outputs = aibitat._pendingOutputs ?? [];
const existingSources = options?.sources ?? [];
await WorkspaceChats.new({
workspaceId: Number(invocation.workspace_id),
@@ -89,11 +93,13 @@ const chatHistory = {
type: options?.saveAsType ?? "chat",
attachments,
metrics,
+ ...(outputs.length > 0 ? { outputs } : {}),
},
user: { id: invocation?.user_id || null },
threadId: invocation?.thread_id || null,
});
aibitat.clearCitations?.();
+ aibitat._pendingOutputs = [];
options?.postSave();
},
};
diff --git a/server/utils/agents/aibitat/plugins/create-files/docx/create-docx-file.js b/server/utils/agents/aibitat/plugins/create-files/docx/create-docx-file.js
new file mode 100644
index 000000000..dc3521762
--- /dev/null
+++ b/server/utils/agents/aibitat/plugins/create-files/docx/create-docx-file.js
@@ -0,0 +1,301 @@
+const {
+ getDeploymentVersion,
+} = require("../../../../../../endpoints/utils.js");
+const createFilesLib = require("../lib.js");
+const {
+ getTheme,
+ getMargins,
+ loadLibraries,
+ htmlToDocxElements,
+ createCoverPageSection,
+ createRunningHeader,
+ createRunningFooter,
+ DEFAULT_NUMBERING_CONFIG,
+} = require("./utils.js");
+
+module.exports.CreateDocxFile = {
+ name: "create-docx-file",
+ plugin: function () {
+ return {
+ name: "create-docx-file",
+ setup(aibitat) {
+ aibitat.function({
+ super: aibitat,
+ name: this.name,
+ description:
+ "Create a Microsoft Word document (.docx) from markdown or plain text content. Supports professional styling with color themes, title pages, and running headers/footers.",
+ examples: [
+ {
+ prompt: "Create a Word document with meeting notes",
+ call: JSON.stringify({
+ filename: "meeting-notes.docx",
+ content:
+ "# Meeting Notes - Q1 Planning\n\n## Attendees\n- John Smith\n- Sarah Johnson\n- Mike Chen\n\n## Agenda\n1. Review Q4 results\n2. Set Q1 goals\n3. Assign tasks\n\n## Action Items\n| Person | Task | Due Date |\n|--------|------|----------|\n| John | Prepare budget report | Jan 15 |\n| Sarah | Draft marketing plan | Jan 20 |\n| Mike | Schedule follow-up | Jan 10 |",
+ }),
+ },
+ {
+ prompt:
+ "Create a professional project proposal with a title page",
+ call: JSON.stringify({
+ filename: "project-proposal.docx",
+ title: "Project Alpha Proposal",
+ subtitle: "Strategic Initiative for Q2 2024",
+ author: "Product Team",
+ theme: "blue",
+ includeTitlePage: true,
+ content:
+ "## Executive Summary\nThis proposal outlines the development of **Project Alpha**, a next-generation platform.\n\n## Objectives\n- Increase efficiency by 40%\n- Reduce costs by $50,000 annually\n- Improve user satisfaction\n\n## Timeline\n| Phase | Duration | Deliverables |\n|-------|----------|-------------|\n| Phase 1 | 4 weeks | Requirements |\n| Phase 2 | 8 weeks | Development |\n| Phase 3 | 2 weeks | Testing |\n\n## Budget\nTotal estimated budget: **$150,000**",
+ }),
+ },
+ {
+ prompt: "Create technical documentation with warm theme",
+ call: JSON.stringify({
+ filename: "api-documentation.docx",
+ title: "API Documentation",
+ theme: "warm",
+ margins: "narrow",
+ content:
+ "# API Documentation\n\n## Authentication\nAll API requests require a Bearer token in the Authorization header.\n\n```javascript\nconst headers = {\n 'Authorization': 'Bearer YOUR_TOKEN',\n 'Content-Type': 'application/json'\n};\n```\n\n## Endpoints\n\n### GET /users\nReturns a list of all users.\n\n### POST /users\nCreates a new user.\n\n> **Note:** Rate limiting applies to all endpoints.",
+ }),
+ },
+ ],
+ parameters: {
+ $schema: "http://json-schema.org/draft-07/schema#",
+ type: "object",
+ properties: {
+ filename: {
+ type: "string",
+ description:
+ "The filename for the Word document. Will automatically add .docx extension if not present.",
+ },
+ title: {
+ type: "string",
+ description:
+ "Document title for metadata and title page. If not provided, will be extracted from content or use filename.",
+ },
+ subtitle: {
+ type: "string",
+ description:
+ "Optional subtitle displayed on the title page below the main title.",
+ },
+ author: {
+ type: "string",
+ description:
+ "Optional author name displayed on the title page.",
+ },
+ content: {
+ type: "string",
+ description:
+ "The content to convert to a Word document. Fully supports markdown formatting.",
+ },
+ theme: {
+ type: "string",
+ enum: ["neutral", "blue", "warm"],
+ description:
+ "Color theme for the document. 'neutral' (slate/grey), 'blue' (corporate blue), or 'warm' (earthy tones). Defaults to neutral.",
+ },
+ margins: {
+ type: "string",
+ enum: ["normal", "narrow", "wide"],
+ description:
+ "Page margin preset. 'normal' (standard), 'narrow' (data-heavy docs), or 'wide' (letters/memos). Defaults to normal.",
+ },
+ includeTitlePage: {
+ type: "boolean",
+ description:
+ "Include a professional title page with centered title, subtitle, author, and date. Content starts on page 2 with running headers/footers.",
+ },
+ },
+ required: ["filename", "content"],
+ additionalProperties: false,
+ },
+ handler: async function ({
+ filename = "document.docx",
+ title = null,
+ subtitle = null,
+ author = null,
+ content = "",
+ theme = "neutral",
+ margins = "normal",
+ includeTitlePage = false,
+ }) {
+ try {
+ this.super.handlerProps.log(`Using the create-docx-file tool.`);
+
+ const hasExtension = /\.docx$/i.test(filename);
+ if (!hasExtension) filename = `${filename}.docx`;
+ const displayFilename = filename.split("/").pop();
+
+ const documentTitle =
+ title ||
+ content.match(/^#\s+(.+)$/m)?.[1] ||
+ displayFilename.replace(/\.docx$/i, "");
+
+ if (this.super.requestToolApproval) {
+ const approval = await this.super.requestToolApproval({
+ skillName: this.name,
+ payload: { filename: displayFilename, title: documentTitle },
+ description: `Create Word document "${displayFilename}"`,
+ });
+ if (!approval.approved) {
+ this.super.introspect(
+ `${this.caller}: User rejected the ${this.name} request.`
+ );
+ return approval.message;
+ }
+ }
+
+ this.super.introspect(
+ `${this.caller}: Creating Word document "${displayFilename}"${includeTitlePage ? " with title page" : ""}`
+ );
+
+ const libs = await loadLibraries();
+ const { marked, docx } = libs;
+ const { Document, Packer, Paragraph, TextRun } = docx;
+ marked.setOptions({
+ gfm: true,
+ breaks: true,
+ });
+
+ const themeColors = getTheme(theme);
+ const marginConfig = getMargins(margins);
+
+ const html = marked.parse(content);
+ this.super.handlerProps.log(
+ `create-docx-file: Parsed markdown to HTML (${html.length} chars), theme: ${theme}, margins: ${margins}`
+ );
+
+ const logoBuffer = createFilesLib.getLogo({
+ forDarkBackground: false,
+ format: "buffer",
+ });
+
+ const docElements = await htmlToDocxElements(
+ html,
+ libs,
+ this.super.handlerProps.log,
+ themeColors
+ );
+
+ if (docElements.length === 0) {
+ docElements.push(
+ new Paragraph({
+ children: [new TextRun({ text: content })],
+ })
+ );
+ }
+
+ const sections = [];
+
+ if (includeTitlePage) {
+ const currentDate = new Date().toLocaleDateString("en-US", {
+ year: "numeric",
+ month: "long",
+ day: "numeric",
+ });
+
+ sections.push(
+ createCoverPageSection(docx, {
+ title: documentTitle,
+ subtitle,
+ author,
+ date: currentDate,
+ theme: themeColors,
+ margins: marginConfig,
+ logoBuffer,
+ })
+ );
+
+ sections.push({
+ properties: {
+ page: {
+ margin: marginConfig,
+ },
+ },
+ children: docElements,
+ headers: {
+ default: createRunningHeader(
+ docx,
+ documentTitle,
+ themeColors
+ ),
+ },
+ footers: {
+ default: createRunningFooter(docx, logoBuffer, themeColors),
+ },
+ });
+ } else {
+ sections.push({
+ properties: {
+ page: {
+ margin: marginConfig,
+ },
+ },
+ children: docElements,
+ footers: {
+ default: createRunningFooter(docx, logoBuffer, themeColors),
+ },
+ });
+ }
+
+ const doc = new Document({
+ title: documentTitle,
+ creator: `AnythingLLM ${getDeploymentVersion()}`,
+ description: `Word Document generated by AnythingLLM ${getDeploymentVersion()}`,
+ numbering: DEFAULT_NUMBERING_CONFIG,
+ sections,
+ });
+
+ const buffer = await Packer.toBuffer(doc);
+ const bufferSizeKB = (buffer.length / 1024).toFixed(2);
+
+ this.super.handlerProps.log(
+ `create-docx-file: Generated buffer - size: ${bufferSizeKB}KB, title: "${documentTitle}", theme: ${theme}`
+ );
+
+ const savedFile = await createFilesLib.saveGeneratedFile({
+ fileType: "docx",
+ extension: "docx",
+ buffer,
+ displayFilename,
+ });
+
+ this.super.socket.send("fileDownloadCard", {
+ filename: savedFile.displayFilename,
+ storageFilename: savedFile.filename,
+ fileSize: savedFile.fileSize,
+ });
+
+ createFilesLib.registerOutput(this.super, "DocxFileDownload", {
+ filename: savedFile.displayFilename,
+ storageFilename: savedFile.filename,
+ fileSize: savedFile.fileSize,
+ });
+
+ this.super.introspect(
+ `${this.caller}: Successfully created Word document "${displayFilename}"`
+ );
+
+ const styleInfo = [
+ theme !== "neutral" ? `${theme} theme` : null,
+ margins !== "normal" ? `${margins} margins` : null,
+ includeTitlePage ? "title page" : null,
+ ].filter(Boolean);
+
+ const styleDesc =
+ styleInfo.length > 0 ? ` with ${styleInfo.join(", ")}` : "";
+
+ return `Successfully created Word document "${displayFilename}" (${bufferSizeKB}KB)${styleDesc}. The document includes formatted content with tables, images, Page X of Y footer, and professional styling.`;
+ } catch (e) {
+ this.super.handlerProps.log(
+ `create-docx-file error: ${e.message}`
+ );
+ this.super.introspect(`Error: ${e.message}`);
+ return `Error creating Word document: ${e.message}`;
+ }
+ },
+ });
+ },
+ };
+ },
+};
diff --git a/server/utils/agents/aibitat/plugins/create-files/docx/test-themes.js b/server/utils/agents/aibitat/plugins/create-files/docx/test-themes.js
new file mode 100755
index 000000000..ec06ec51c
--- /dev/null
+++ b/server/utils/agents/aibitat/plugins/create-files/docx/test-themes.js
@@ -0,0 +1,298 @@
+#!/usr/bin/env node
+/**
+ * Test utility to generate sample Word documents for all themes and configurations.
+ * Run from the server directory: node utils/agents/aibitat/plugins/create-files/docx/test-themes.js
+ *
+ * Output goes to: storage/generated-files/docx-theme-previews/
+ */
+
+const path = require("path");
+const fs = require("fs/promises");
+const {
+ DOCUMENT_STYLES,
+ getTheme,
+ getMargins,
+ loadLibraries,
+ htmlToDocxElements,
+ createCoverPageSection,
+ createRunningHeader,
+ createRunningFooter,
+ DEFAULT_NUMBERING_CONFIG,
+} = require("./utils.js");
+
+const OUTPUT_DIR = path.resolve(
+ __dirname,
+ "../../../../../../storage/generated-files/docx-theme-previews"
+);
+
+const SAMPLE_CONTENT = `# Sample Document
+
+## Executive Summary
+
+This document demonstrates the **styling capabilities** of the Word document generator. It includes various content types to showcase how themes affect the visual appearance.
+
+## Key Features
+
+- Professional title pages with centered content
+- Running headers with document title
+- Page X of Y footer numbering
+- Color-coordinated themes throughout
+
+## Data Overview
+
+| Metric | Q1 | Q2 | Q3 | Q4 |
+|--------|-----|-----|-----|-----|
+| Revenue | $1.2M | $1.5M | $1.8M | $2.1M |
+| Growth | +15% | +25% | +20% | +17% |
+| Users | 10K | 15K | 22K | 30K |
+
+## Technical Details
+
+Here is an example code block:
+
+\`\`\`javascript
+const config = {
+ theme: "blue",
+ margins: "normal",
+ includeTitlePage: true
+};
+\`\`\`
+
+> **Note:** This blockquote demonstrates how accent colors are applied to the left border. Blockquotes are useful for callouts and important notes.
+
+## Conclusion
+
+The themed document system provides a consistent, professional look across all generated documents. Each theme cascades colors through:
+
+1. Heading text colors
+2. Table header backgrounds
+3. Blockquote borders
+4. Footer text styling
+
+---
+
+Thank you for reviewing this sample document.
+`;
+
+const MINIMAL_CONTENT = `# Quick Report
+
+## Summary
+
+A brief document to test minimal content rendering.
+
+- Point one
+- Point two
+- Point three
+
+| Item | Value |
+|------|-------|
+| A | 100 |
+| B | 200 |
+`;
+
+async function generateThemePreview(themeName, themeConfig, options = {}) {
+ const libs = await loadLibraries();
+ const { marked, docx } = libs;
+ const { Document, Packer, Paragraph, TextRun } = docx;
+
+ marked.setOptions({ gfm: true, breaks: true });
+
+ const {
+ margins = "normal",
+ includeTitlePage = false,
+ content = SAMPLE_CONTENT,
+ subtitle = null,
+ author = null,
+ } = options;
+
+ const marginConfig = getMargins(margins);
+ const title = `${themeConfig.name || themeName} Theme Preview`;
+
+ const html = marked.parse(content);
+ const docElements = await htmlToDocxElements(
+ html,
+ libs,
+ console.log,
+ themeConfig
+ );
+
+ if (docElements.length === 0) {
+ docElements.push(
+ new Paragraph({
+ children: [new TextRun({ text: content })],
+ })
+ );
+ }
+
+ const sections = [];
+
+ if (includeTitlePage) {
+ const currentDate = new Date().toLocaleDateString("en-US", {
+ year: "numeric",
+ month: "long",
+ day: "numeric",
+ });
+
+ sections.push(
+ createCoverPageSection(docx, {
+ title,
+ subtitle: subtitle || `Demonstrating the ${themeName} color scheme`,
+ author: author || "AnythingLLM Theme Tester",
+ date: currentDate,
+ theme: themeConfig,
+ margins: marginConfig,
+ logoBuffer: null,
+ })
+ );
+
+ sections.push({
+ properties: {
+ page: { margin: marginConfig },
+ titlePage: true,
+ },
+ children: docElements,
+ headers: {
+ default: createRunningHeader(docx, title, themeConfig),
+ },
+ footers: {
+ default: createRunningFooter(docx, null, themeConfig),
+ },
+ });
+ } else {
+ sections.push({
+ properties: {
+ page: { margin: marginConfig },
+ },
+ children: docElements,
+ footers: {
+ default: createRunningFooter(docx, null, themeConfig),
+ },
+ });
+ }
+
+ const doc = new Document({
+ title,
+ creator: "AnythingLLM Theme Tester",
+ description: `Theme preview for ${themeName}`,
+ numbering: DEFAULT_NUMBERING_CONFIG,
+ sections,
+ });
+
+ return Packer.toBuffer(doc);
+}
+
+async function main() {
+ console.log("DOCX Theme Preview Generator");
+ console.log("============================\n");
+
+ await fs.mkdir(OUTPUT_DIR, { recursive: true });
+
+ const themes = Object.keys(DOCUMENT_STYLES.themes);
+ const marginPresets = Object.keys(DOCUMENT_STYLES.margins);
+
+ console.log(`Themes: ${themes.join(", ")}`);
+ console.log(`Margins: ${marginPresets.join(", ")}\n`);
+
+ const configs = [];
+
+ for (const themeName of themes) {
+ configs.push({
+ name: `theme-${themeName}-simple`,
+ theme: themeName,
+ margins: "normal",
+ includeTitlePage: false,
+ content: SAMPLE_CONTENT,
+ });
+
+ configs.push({
+ name: `theme-${themeName}-with-title-page`,
+ theme: themeName,
+ margins: "normal",
+ includeTitlePage: true,
+ content: SAMPLE_CONTENT,
+ });
+ }
+
+ for (const marginName of marginPresets) {
+ configs.push({
+ name: `margins-${marginName}`,
+ theme: "neutral",
+ margins: marginName,
+ includeTitlePage: true,
+ content: SAMPLE_CONTENT,
+ });
+ }
+
+ configs.push({
+ name: `full-featured-blue`,
+ theme: "blue",
+ margins: "normal",
+ includeTitlePage: true,
+ content: SAMPLE_CONTENT,
+ subtitle: "A Complete Feature Demonstration",
+ author: "Documentation Team",
+ });
+
+ configs.push({
+ name: `minimal-warm`,
+ theme: "warm",
+ margins: "narrow",
+ includeTitlePage: false,
+ content: MINIMAL_CONTENT,
+ });
+
+ console.log(`Generating ${configs.length} preview documents...\n`);
+
+ for (const config of configs) {
+ const themeConfig = getTheme(config.theme);
+ try {
+ const buffer = await generateThemePreview(config.theme, themeConfig, {
+ margins: config.margins,
+ includeTitlePage: config.includeTitlePage,
+ content: config.content,
+ subtitle: config.subtitle,
+ author: config.author,
+ });
+
+ const filename = `${config.name}.docx`;
+ const filepath = path.join(OUTPUT_DIR, filename);
+ await fs.writeFile(filepath, buffer);
+
+ const sizeKB = (buffer.length / 1024).toFixed(1);
+ const titlePage = config.includeTitlePage ? "✓ title" : " - ";
+ console.log(
+ `✓ ${config.name.padEnd(30)} [${config.theme.padEnd(7)}] [${config.margins.padEnd(6)}] ${titlePage} (${sizeKB}KB)`
+ );
+ } catch (error) {
+ console.error(`✗ ${config.name.padEnd(30)} → Error: ${error.message}`);
+ console.error(error.stack);
+ }
+ }
+
+ console.log(`\n✅ Done! Files saved to: ${OUTPUT_DIR}`);
+ console.log(
+ "\nOpen the .docx files in Microsoft Word or LibreOffice to preview each configuration."
+ );
+
+ console.log("\n--- Theme Color Reference ---");
+ for (const [name, colors] of Object.entries(DOCUMENT_STYLES.themes)) {
+ console.log(`\n${name.toUpperCase()}:`);
+ console.log(` Heading: #${colors.heading}`);
+ console.log(` Accent: #${colors.accent}`);
+ console.log(` Table Header: #${colors.tableHeader}`);
+ console.log(` Border: #${colors.border}`);
+ console.log(` Cover BG: #${colors.coverBg}`);
+ console.log(` Footer Text: #${colors.footerText}`);
+ }
+
+ console.log("\n--- Margin Presets (twips) ---");
+ for (const [name, margins] of Object.entries(DOCUMENT_STYLES.margins)) {
+ const inchTop = (margins.top / 1440).toFixed(2);
+ const inchLeft = (margins.left / 1440).toFixed(2);
+ console.log(
+ `${name.padEnd(8)}: top/bottom=${inchTop}" left/right=${inchLeft}"`
+ );
+ }
+}
+
+main().catch(console.error);
diff --git a/server/utils/agents/aibitat/plugins/create-files/docx/utils.js b/server/utils/agents/aibitat/plugins/create-files/docx/utils.js
new file mode 100644
index 000000000..daebecf68
--- /dev/null
+++ b/server/utils/agents/aibitat/plugins/create-files/docx/utils.js
@@ -0,0 +1,1095 @@
+/**
+ * Utilities for converting markdown to DOCX format.
+ * Uses marked for parsing, jsdom for HTML traversal, and docx for document generation.
+ */
+
+/**
+ * Document style presets for professional-looking documents.
+ */
+const DOCUMENT_STYLES = {
+ margins: {
+ normal: { top: 1440, bottom: 1440, left: 1800, right: 1800 },
+ narrow: { top: 720, bottom: 720, left: 720, right: 720 },
+ wide: { top: 1440, bottom: 1440, left: 2880, right: 2880 },
+ },
+ themes: {
+ neutral: {
+ heading: "2E4057",
+ accent: "048A81",
+ tableHeader: "E7E6E6",
+ border: "CCCCCC",
+ coverBg: "2E4057",
+ coverText: "FFFFFF",
+ footerText: "666666",
+ },
+ blue: {
+ heading: "1B3A6B",
+ accent: "2E86AB",
+ tableHeader: "D6E8F5",
+ border: "A8C8E8",
+ coverBg: "1B3A6B",
+ coverText: "FFFFFF",
+ footerText: "2E86AB",
+ },
+ warm: {
+ heading: "5C3317",
+ accent: "C1440E",
+ tableHeader: "F5ECD7",
+ border: "D4B896",
+ coverBg: "5C3317",
+ coverText: "FFFFFF",
+ footerText: "8B6914",
+ },
+ },
+ fonts: {
+ body: "Calibri",
+ heading: "Calibri",
+ mono: "Consolas",
+ },
+ borders: {
+ none: {
+ top: { style: "none" },
+ bottom: { style: "none" },
+ left: { style: "none" },
+ right: { style: "none" },
+ },
+ },
+};
+
+/**
+ * Gets the theme colors, falling back to neutral if not found.
+ * @param {string} themeName - The theme name
+ * @returns {Object} Theme color configuration
+ */
+function getTheme(themeName) {
+ return DOCUMENT_STYLES.themes[themeName] || DOCUMENT_STYLES.themes.neutral;
+}
+
+/**
+ * Gets the margin configuration, falling back to normal if not found.
+ * @param {string} marginName - The margin preset name
+ * @returns {Object} Margin configuration
+ */
+function getMargins(marginName) {
+ return DOCUMENT_STYLES.margins[marginName] || DOCUMENT_STYLES.margins.normal;
+}
+
+/**
+ * Lazy-loads the required libraries for docx generation.
+ * @returns {Promise