Ask m' AI (ask my ai -> ask m' ai) is a little Desktop-Chat-Application for LargeLanguageModels (e.g. OpenAI's GPT).
Unlike many chat applications out there, this application aims to be scriptable. Which means you can call it from you terminal and gave all necessary options as arguments. The conversations will also be printed out in the terminal, so you can use it in your scripts.
demo.mp4
ask-mai -b localai --localai-base-url=http://localhost:8080/v1 --localai-model=gpt-4
ask-mai -b openai --openai-api-key=YOUR_OPENAI_API_KEY
ask-mai -b ollama --ollama-server-url=http://localhost:11434 --ollama-model=llama3.2
ask-mai -b anthropic --anthropic-api-key=YOUR_ANTHROPIC_API_KEY
ask-mai -b mistral --mistral-api-key=YOUR_MISTRAL_API_KEY --mistral-model=mistral-small-latest
ask-mai -b deepseek --deepseek-api-key=YOUR_DEEPSEEK_API_KEY
- Support different LLM provider
- Tool Support
- You can define your own tools which can be called from the LLM
- There are some built-in tools:
- "__getSystemInformation" - Get some information about the system
- "__getEnvironment" - Read environment variables from the system
- "__getSystemTime" - Get the current system time
- "__getStats" - Get stats of a file or directory
- "__changeMode" - Changes the mode of file or directory
- "__changeOwner" - Changes the owner of file or directory
- "__changeTimes" - Changes the access and/or modification time of file or directory
- "__createFile" - Create a file on the system
- "__createTempFile" - Create a temporary file on the system
- "__appendFile" - Append content to an existing file
- "__readTextFile" - Read a text file from the system
- "__deleteFile" - Delete a file from the system
- "__createDirectory" - Creates a new directory on the system
- "__createTempDirectory" - Creates a new temporary directory on the system
- "__deleteDirectory" - Delete a directory from the system
- "__executeCommand" - Execute a command on the system
- "__callHttp" - Do a http call
- Scriptable
- All settings can be set via:
- yaml configuration file
- environment variables
- command line arguments
- The users questions and models answers will be printed out in the terminal
- All settings can be set via:
- Customizable
- Choose between two themes (light and dark)
- Choose between different languages (english, german)
- Choose between different code themes (see help for all available themes)
You can download the latest version of this application from the releases page. There are many different versions for different operating systems, architectures and feature sets.
The file names are structured as follows:
ask-mai-${OS}-${ARCH}-${FEATURE}.${EXTENSION}
Available OS:
- darwin - MacOS
- linux - Linux
- windows - Windows
Available Architectures:
- amd64 - 64bit
- 386 - 32bit
- arm64 - ARM 64bit
Available Features:
- compressed - The binary is compressed (can be problematic for some antivirus software - especially on windows)
- console - The binary is console application (only for windows)
- debug - The binary contains devtools (you can inspect the GUI-Sources)
- Install dependencies see wails documentation
- Build the application:
wails build
flatpak-builder .flatpak-build de.rainu.ask-mai.yml --repo=.flatpak-repo --install-deps-from=flathub --force-clean --default-branch=master --arch=x86_64 --ccache
flatpak build-bundle .flatpak-repo ask-mai.flatpak --runtime-repo=https://flathub.org/repo/flathub.flatpakrepo --arch=x86_64 de.rainu.ask-mai master
sudo flatpak install --reinstall ask-mai.flatpak
If the application does not start fast enough for your needs, you can get the prompt by your own and use the -ui-prompt
flag to start the application with that prompt.
Here is an example with rofi:
#!/bin/sh
PROMPT=$(rofi -dmenu -p "Ask-mAI" -l 0 -location 2)
if [ $? -ne 0 ]; then
exit 1
fi
ask-mai -ui-prompt "${PROMPT}"
If you use nix, you can use nix develop
to enter a shell with all dependencies you need for contributing. The flake also utilises treefmt to format all *.nix and *.go files. This can be done with nix fmt
and checked with nix flake check
.