From 07c118328935095a89297ed12c14d04ee8e14473 Mon Sep 17 00:00:00 2001 From: Saifeddine ALOUI Date: Sun, 27 Aug 2023 21:50:54 +0200 Subject: [PATCH] fixed errors --- app.py | 11 +++++++---- presets/build_latex_book.yaml | 10 +++++++++- ...cing_cervice.yaml => email_enhancing_service.yaml} | 0 3 files changed, 16 insertions(+), 5 deletions(-) rename presets/{email_enhancing_cervice.yaml => email_enhancing_service.yaml} (100%) diff --git a/app.py b/app.py index bbb77ec0..b42e7e35 100644 --- a/app.py +++ b/app.py @@ -939,10 +939,13 @@ class LoLLMsWebUI(LoLLMsAPPI): def get_active_model(self): if self.binding is not None: - models = self.binding.list_models(self.config) - index = models.index(self.config.model_name) - ASCIIColors.yellow("Listing models") - return jsonify({"model":models[index],"index":index}) + try: + models = self.binding.list_models(self.config) + index = models.index(self.config.model_name) + ASCIIColors.yellow("Listing models") + return jsonify({"model":models[index],"index":index}) + except Exception as ex: + return jsonify(None) else: return jsonify(None) diff --git a/presets/build_latex_book.yaml b/presets/build_latex_book.yaml index fbd7fda4..8b270805 100644 --- a/presets/build_latex_book.yaml +++ b/presets/build_latex_book.yaml @@ -13,4 +13,12 @@ content: | \chapter{Introduction} @@ \end{document} - ``` \ No newline at end of file + ``` +snippets: + - Import graphics(required to add graphics to the page) : + \usepackage[demo]{graphic} + - Add graph: | + \includegraphics[width=4in]{@@}% Replace with your own image path + +help: | + Builds a latex code for a book \ No newline at end of file diff --git a/presets/email_enhancing_cervice.yaml b/presets/email_enhancing_service.yaml similarity index 100% rename from presets/email_enhancing_cervice.yaml rename to presets/email_enhancing_service.yaml