From a2cff69feef233f62446a3a3aa2d52ed4dba187f Mon Sep 17 00:00:00 2001 From: Jeremy Ruston Date: Thu, 18 Jul 2024 09:24:37 +0100 Subject: [PATCH] Update docs --- plugins/tiddlywiki/ai-tools/docs.tid | 25 ++++++++++++++++++++++++ plugins/tiddlywiki/ai-tools/readme.tid | 7 ------- plugins/tiddlywiki/ai-tools/settings.tid | 13 ++++++++++-- 3 files changed, 36 insertions(+), 9 deletions(-) diff --git a/plugins/tiddlywiki/ai-tools/docs.tid b/plugins/tiddlywiki/ai-tools/docs.tid index 103c1e92a..9ae9ec7a7 100644 --- a/plugins/tiddlywiki/ai-tools/docs.tid +++ b/plugins/tiddlywiki/ai-tools/docs.tid @@ -1,2 +1,27 @@ title: $:/plugins/tiddlywiki/ai-tools/docs +!! Setting Up + +See the ''settings'' tab for set up instructions. + +!! Live AI Conversations in ~TiddlyWiki + +# Click the {{||$:/plugins/tiddlywiki/ai-tools/page-menu}} icon in the sidebar to open a new conversation +# Choose the server from the dropdown: +#* ''Locally running Llamafile server'' - LLlamafile is an open source project that lets you distribute and run LLMs as a single file. The files are large, typically 4+ gigabytes but offer reasonable performance on modern hardware, and total privacy +#* ''~OpenAI Service'' - ~OpenAI is a commercial service that offers paid APIs for accessing some of the most sophisticated LLMs that are available. ~OpenAI requires tokens to be purchased for API usage (this is entirely separate from ~ChatGPT subscriptions) +# Type a prompt for the LLM in the text box +#* If using ~OpenAI it is possible to attach a single image to a prompt +# Click "Send" and wait for the output of the LLM + +!! Import ~ChatGPT Conversation Archives + +# [[Follow the instructions|https://help.openai.com/en/articles/7260999-how-do-i-export-my-chatgpt-history-and-data]] to request an export of your ~ChatGPT data +# You will receive a link to download your data as a ZIP file +# Download and unzip the file +# Locate the file `conversations.json` within the archive and import it into your TiddlyWiki +# Visit the ''tools'' tab and locate your `conversations.json` tiddler +# Click the associated ''import'' button +# See the imported conversations listed in the ''tools'' tab +# The imported tiddler `conversations.json` is no longer required and can be deleted + diff --git a/plugins/tiddlywiki/ai-tools/readme.tid b/plugins/tiddlywiki/ai-tools/readme.tid index d29b75ea9..edaa1d844 100644 --- a/plugins/tiddlywiki/ai-tools/readme.tid +++ b/plugins/tiddlywiki/ai-tools/readme.tid @@ -4,10 +4,3 @@ title: $:/plugins/tiddlywiki/ai-tools/readme This plugin adds integrated LLM conversations to the TiddlyWiki platform. -# Click the {{||$:/plugins/tiddlywiki/ai-tools/page-menu}} icon in the sidebar to open a new conversation -# Choose the server from the dropdown: -#* ''Locally running Llamafile server'' - LLlamafile is an open source project that lets you distribute and run LLMs as a single file. The files are large, typically 4+ gigabytes but offer reasonable performance on modern hardware, and total privacy -#* ''~OpenAI Service'' - ~OpenAI is a commercial service that offers paid APIs for accessing some of the most sophisticated LLMs that are available. ~OpenAI requires tokens to be purchased for API usage (this is entirely separate from ~ChatGPT subscriptions) -# Type a prompt for the LLM in the text box -#* If using ~OpenAI it is possible to attach a single image to a prompt -# Click "Send" and wait for the output of the LLM diff --git a/plugins/tiddlywiki/ai-tools/settings.tid b/plugins/tiddlywiki/ai-tools/settings.tid index ce35c72cb..fa18296c9 100644 --- a/plugins/tiddlywiki/ai-tools/settings.tid +++ b/plugins/tiddlywiki/ai-tools/settings.tid @@ -2,10 +2,10 @@ title: $:/plugins/tiddlywiki/ai-tools/settings ! AI Tools Settings -This plugin runs entirely in the browser, with no backend server component. A consequence of this design is that the API keys required to access external services must be obtained by the end user. These keys are stored in the browser and so only need to be set up once. - !! ~OpenAI API key +This plugin runs entirely in the browser, with no backend server component. A consequence of this design is that the API keys required to access external services must be obtained by the end user. These keys are stored in the browser and so only need to be set up once. + # Register for an account at https://platform.openai.com/ #* Newly registered accounts can claim a small amount of credit, thereafter payment is needed #* Note that ~OpenAI run completely different payment systems for ~ChatGPT and the API platform. Even if you are already a subscriber to ~ChatGPT you will still need to pay for API usage after the initial free service @@ -14,3 +14,12 @@ This plugin runs entirely in the browser, with no backend server component. A co ~OpenAI Secret API Key: <$password name="openai-secret-key"/> +!! Llamafile Setup + +[[Llamafile|https://github.com/Mozilla-Ocho/llamafile]] lets you download and run LLMs as a single file. See the [[announcment blog post|https://hacks.mozilla.org/2023/11/introducing-llamafile/]] for background. + +1. Download and run Llamafile as [[described in the QuickStart guide|https://github.com/Mozilla-Ocho/llamafile?tab=readme-ov-file#quickstart]] +2. Visit http://127.0.0.1:8080 in a browser and verify that you can see the Llamafile interface. You can also try it out here +3. Return to AI Tools and start a conversation, specifying Llamafile as the server + +