From 7bf25423ffc32c509bd13d85987c8295ca3e0ed5 Mon Sep 17 00:00:00 2001 From: tbedford Date: Mon, 13 May 2024 09:46:59 +0100 Subject: [PATCH 1/9] [add] - run llm widget --- .../docs/javascripts/runllm-widget.js | 17 +++++++++++++++++ mkdocs.yml | 1 + 2 files changed, 18 insertions(+) create mode 100644 docs/javascripts/docs/javascripts/runllm-widget.js diff --git a/docs/javascripts/docs/javascripts/runllm-widget.js b/docs/javascripts/docs/javascripts/runllm-widget.js new file mode 100644 index 00000000..a9f0fef8 --- /dev/null +++ b/docs/javascripts/docs/javascripts/runllm-widget.js @@ -0,0 +1,17 @@ +document.addEventListener("DOMContentLoaded", function() { + var script = document.createElement('script'); + script.defer = true; + script.type = 'module'; + script.id = 'runllm-widget-script'; + script.src = 'https://cdn.jsdelivr.net/npm/@runllm/search-widget@stable/dist/run-llm-search-widget.es.js'; + script.setAttribute('version', 'stable'); + script.setAttribute('runllm-preset', 'mkdocs'); + script.setAttribute('runllm-server-address', 'https://api.runllm.com'); + script.setAttribute('runllm-assistant-id', '111'); + script.setAttribute('runllm-position', 'BOTTOM_RIGHT'); + script.setAttribute('runllm-keyboard-shortcut', 'Mod+j'); + script.setAttribute('runllm-slack-community-url', 'https://quix.io/slack-invite'); + script.setAttribute('runllm-name', 'RunLLM'); + + document.head.appendChild(script); +}); diff --git a/mkdocs.yml b/mkdocs.yml index 99aebf69..5aa8fcf2 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -400,6 +400,7 @@ extra_css: extra_javascript: - javascripts/quix.js - javascripts/feedback.js + - javascripts/runllm-widget.js extra: social: - icon: 'fontawesome/brands/github' From 593dd9825e64f16bcbe13e67528d53fb9227a177 Mon Sep 17 00:00:00 2001 From: Merlin Date: Mon, 13 May 2024 19:15:17 +0200 Subject: [PATCH 2/9] adding runllm to main override --- overrides/main.html | 1 + 1 file changed, 1 insertion(+) diff --git a/overrides/main.html b/overrides/main.html index 9cbff3c7..4ad5bb2c 100644 --- a/overrides/main.html +++ b/overrides/main.html @@ -154,5 +154,6 @@ {{ super() }} + {% endblock %} \ No newline at end of file From 8f3a6436987ae3f91750f5860014d07b21d846b9 Mon Sep 17 00:00:00 2001 From: Merlin Date: Mon, 13 May 2024 19:46:45 +0200 Subject: [PATCH 3/9] adding widget to correct location --- docs/javascripts/{docs/javascripts => }/runllm-widget.js | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename docs/javascripts/{docs/javascripts => }/runllm-widget.js (100%) diff --git a/docs/javascripts/docs/javascripts/runllm-widget.js b/docs/javascripts/runllm-widget.js similarity index 100% rename from docs/javascripts/docs/javascripts/runllm-widget.js rename to docs/javascripts/runllm-widget.js From 229dceb68ec80d95ae0af05b50722e9403345da5 Mon Sep 17 00:00:00 2001 From: steverosam Date: Wed, 15 May 2024 13:21:54 +0100 Subject: [PATCH 4/9] remove search? --- overrides/main.html | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/overrides/main.html b/overrides/main.html index 4ad5bb2c..faeec912 100644 --- a/overrides/main.html +++ b/overrides/main.html @@ -99,7 +99,9 @@ -