xref: /plugin/dokullm/doc/install.txt (revision d36001d67c06afed255578906c99236e716299ab)
1====== DokuLLM Plugin Installation Guide ======
2
3This guide will walk you through the process of installing and configuring the DokuLLM plugin for DokuWiki.
4
5===== Prerequisites =====
6
7Before installing the DokuLLM plugin, ensure you have:
8  * A working DokuWiki installation (version 2020-07-29 "Hogfather" or newer recommended)
9  * PHP 7.4 or higher with cURL support
10  * Access to your DokuWiki server's file system
11  * (Optional) Access to an Ollama server for embeddings generation
12  * (Optional) Access to a ChromaDB server for document storage and retrieval
13
14===== Installation Methods =====
15
16==== Method 1: Extension Manager (Recommended) ====
17
18The easiest way to install the DokuLLM plugin is using DokuWiki's Extension Manager:
19
201. Log in to your DokuWiki as an administrator
212. Navigate to **Admin** → **Extension Manager**
223. In the "Install from URL" field, enter the plugin's repository URL
234. Click **Install**
245. The plugin should now be installed and ready for configuration
25
26==== Method 2: Manual Installation ====
27
28If the Extension Manager is not available or you prefer manual installation:
29
301. Download the latest release from the plugin's repository
312. Extract the downloaded archive
323. Rename the extracted folder to ''dokullm''
334. Upload the ''dokullm'' folder to your DokuWiki's ''lib/plugins/'' directory
345. The final path should be ''lib/plugins/dokullm/''
35
36===== Configuration =====
37
38After installation, you need to configure the plugin:
39
401. Navigate to **Admin** → **Configuration Settings**
412. Find the "DokuLLM" section in the configuration manager
423. Configure the following required settings:
43   * **LLM API URL**: The base URL of your LLM API (e.g., Ollama API)
44   * **LLM API Key**: Your API key if authentication is required
45   * **Default LLM Model**: The model to use for text processing (e.g., llama3, mistral)
46
474. (Optional) Configure ChromaDB integration:
48   * **Enable ChromaDB**: Enable or disable ChromaDB integration
49   * **ChromaDB Host**: Hostname of your ChromaDB server
50   * **ChromaDB Port**: Port number of your ChromaDB server
51   * **ChromaDB Tenant**: Tenant name for ChromaDB
52   * **ChromaDB Database**: Database name for ChromaDB
53   * **Ollama Host**: Hostname of your Ollama server (for embeddings)
54   * **Ollama Port**: Port number of your Ollama server
55
565. Save the configuration
57
58===== Prompt and Profile Setup =====
59
60The DokuLLM plugin uses DokuWiki pages to store prompts and profiles. These are located in the ''dokullm:'' namespace:
61
62  * Default prompts are stored in ''dokullm:profiles:default:'' namespace
63  * Custom profiles can be created under ''dokullm:profiles:[PROFILE_NAME]:''
64  * System prompts are stored in pages named ''system'' within each profile
65  * Action-specific prompt extensions are stored in ''[ACTION_NAME]:system'' pages
66
67To set up the default prompts:
68  1. Create the ''dokullm:profiles:default:system'' page with your base system prompt
69  2. Create action prompt pages like ''dokullm:profiles:default:summarize'', ''dokullm:profiles:default:expand'', etc.
70  3. Create action-specific system extensions like ''dokullm:profiles:default:summarize:system'' if needed
71
72===== Verifying Installation =====
73
74To verify the plugin is correctly installed and configured:
75
761. Edit any page in your wiki
772. You should see LLM tools in the editor toolbar
783. Try using one of the LLM functions to ensure everything is working
794. Check the plugin's CLI commands if you have command-line access:
80   ''php lib/plugins/dokullm/cli.php --help''
81
82===== Troubleshooting =====
83
84If you encounter issues:
85
86  * Ensure all required PHP extensions (especially cURL) are installed and enabled
87  * Check DokuWiki's error log for any plugin-related errors
88  * Verify network connectivity to your LLM API and ChromaDB servers
89  * Confirm that file permissions allow the plugin to read its configuration files
90  * Make sure your LLM API is accessible and responding to requests
91  * Verify that your prompt pages are correctly created in the ''dokullm:'' namespace
92
93For further assistance, consult the plugin's documentation or contact the plugin maintainer.
94