MkDocs Gemini Chat Plugin
A Material for MkDocs plugin that adds a Gemini-powered chat window to your documentation pages.
Features
- Interactive chat window powered by Google's Gemini 2.5 Pro
- Chat history and context support
- Multiple language support
- Version-specific documentation support
- File path specification
- Copy/download functionality
- Customizable UI position
Installation
pip install mkdocs-gemini-chat
Configuration
-
First, obtain a Gemini API key from Google AI Studio.
-
Add your API key to your environment:
# In your .env file or export in your shell export GEMINI_API_KEY=your_api_key_here
-
Add the plugin to your
mkdocs.yml:plugins: - gemini-chat: # Optional: Configure UI position position: bottom-right # Options: bottom-right, bottom-left, top-right, top-left # Optional: Set default language default_language: en # Optional: Set documentation version version: latest
Usage
Once configured, the chat window will appear on your documentation pages. Users can:
- Ask questions about the documentation
- Specify file paths for context
- Change language settings
- Access version-specific information
- Copy or download chat responses
Requirements
- Python 3.8 or higher
- A valid Gemini API key
- MkDocs 1.0.0 or higher
Development
To contribute or run tests:
# Clone the repository
git clone https://github.com/nolanblevins/mkdocs-gemini-chat.git
cd mkdocs-gemini-chat
# Install development dependencies
pip install -e ".[dev]"
# Run tests
pytest tests/
License
MIT License - see LICENSE file for details.
Original Requirements
Click to expand
Requirements: As a user, I can use a chat window to ask questions about the documentation on the Material for MkDocs project. UX Features:
- The chat window should be able to use the chat history.
- The chat window should be able to use the chat context.
- The chat windows should use Gemini 2.5 Pro as the LLM.
- The chat window should allow follow up questions.
- The chat window should allow the user to specify the file path to the documentation.
- The chat window should allow the user to specify the language of the documentation.
- The chat window should allow the user to specify the version of the documentation.
- The chat window should allow the user to copy the output to the clipboard.
- The chat window should allow the user to download the output as a file.
Implementation:
- The implementation should be done as a Material for MkDocs plugin.
- The plugin should be able to be added to the documentation site by adding it to the
mkdocs.ymlfile. - The plugin should allow the user to specify where the UI box should be placed in the documentation site.
References
Metadata
Release files for mkdocs-gemini-chat 0.1.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| mkdocs_gemini_chat-0.1.4.tar.gz | 21.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| mkdocs_gemini_chat-0.1.4-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 34.9 kB
Release files / mkdocs_gemini_chat-0.1.4.tar.gz
| Download URL | mkdocs_gemini_chat-0.1.4.tar.gz |
|---|---|
| Size | 21.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b9c029d58e8b0a1c1ff4c06b22dba9b1ffa154535ae018f2915539077dd53aed
|
|
BLAKE2b-256 checksum How to use checksums |
17dd5510203f1e9b7cbc077d4ef6c1bc876eb4f120b21967a7afd76837376c71
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.9.6
|
Release files / mkdocs_gemini_chat-0.1.4-py3-none-any.whl
| Download URL | mkdocs_gemini_chat-0.1.4-py3-none-any.whl |
|---|---|
| Size | 13.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3a17ee16d8d78e5aac31e42f95ea17cd4359006b864b0a0ae3e18f867efe856b
|
|
BLAKE2b-256 checksum How to use checksums |
cfdc9edbcd1032e4a8535fdcb08bccb92cb39921783a440806867c1365e46fab
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.9.6
|