Compare commits
163 Commits
Author | SHA1 | Date |
---|---|---|
|
3759d32049 | |
|
fc754b1b20 | |
|
519fc27f26 | |
|
6e26718f36 | |
|
7be0d1adf0 | |
|
40a2a27e20 | |
|
4fe9fb9b69 | |
|
13482b22f0 | |
|
24015aa2ec | |
|
14a3bf22d2 | |
|
861e6b5484 | |
|
f2e784cfbf | |
|
c681b2f6d0 | |
|
7d1d749977 | |
|
ad719bc561 | |
|
db8cb6ccb4 | |
|
ce09aec253 | |
|
9a7d076a8e | |
|
b0a8f42771 | |
|
011e187e3a | |
|
c23d4c1acd | |
|
9a5e7ddb89 | |
|
d670072a69 | |
|
065f92f144 | |
|
d2269f4431 | |
|
9050050e99 | |
|
1fdcfe9b80 | |
|
6824809d2a | |
|
dbe6dec4cc | |
|
e700df9724 | |
|
36a3769da2 | |
|
04dfd70f24 | |
|
0629a8c0b5 | |
|
6c84f51267 | |
|
43d085ae8e | |
|
b1c11ba21f | |
|
a816cf8f65 | |
|
b78ce302b5 | |
|
d1737ee330 | |
|
cfe9ce2bc9 | |
|
d7ce70cabb | |
|
17c276301f | |
|
1d3a5e91d9 | |
|
daff6a722f | |
|
ada795db4c | |
|
20dbce2f34 | |
|
a9fed3e36d | |
|
a69622250b | |
|
13e266a3c9 | |
|
8c122526ef | |
|
282b22f123 | |
|
ec92a0eb38 | |
|
e10062206d | |
|
efcca113c8 | |
|
8813571b65 | |
|
4d63da801c | |
|
930102ab40 | |
|
e7a1d93196 | |
|
e8820162b0 | |
|
68d2bc343f | |
|
732ad10b14 | |
|
cf92fbcabf | |
|
1f31d51e30 | |
|
33f656997c | |
|
354e82cacd | |
|
c41fb53d9c | |
|
5d68e9893d | |
|
96d7761f19 | |
|
9b6259a580 | |
|
27d45add60 | |
|
e57927524d | |
|
6a5a123026 | |
|
4667f7a69b | |
|
7f67108b93 | |
|
1ecf5d28b8 | |
|
2d659999d8 | |
|
edcbf74295 | |
|
279d3d0a1a | |
|
fcb20e7931 | |
|
0086ec63bc | |
|
9f4e27758e | |
|
fd1f39a6ea | |
|
34044e74bb | |
|
4cc9e7d4c3 | |
|
9654b1b96c | |
|
0f380f69ef | |
|
666aff0a2a | |
|
feab8d65a8 | |
|
d768294458 | |
|
4d90f8611b | |
|
df4879fe6e | |
|
07afba3a29 | |
|
443acf8a81 | |
|
36eaf42d1d | |
|
6896ce5597 | |
|
7422d235d1 | |
|
c780564129 | |
|
bd71f99a55 | |
|
a1ce8686f0 | |
|
71e71d3e96 | |
|
5db1288228 | |
|
0401145987 | |
|
09fda2b004 | |
|
1b9225fdb8 | |
|
3d7867abe3 | |
|
04ff29277d | |
|
8f00cb8989 | |
|
00b0705038 | |
|
92290d6428 | |
|
539db78749 | |
|
6697346628 | |
|
baf654be40 | |
|
93818cfbad | |
|
9fb9904bdb | |
|
ebba5b82e6 | |
|
16eed64c83 | |
|
fa3fb953e2 | |
|
f5a32a014a | |
|
5520987684 | |
|
da95e2d106 | |
|
0b04e89cc9 | |
|
fdea5bab05 | |
|
60601edce8 | |
|
edd92955e9 | |
|
db6feba198 | |
|
ec55ccde3e | |
|
2e1f8c1935 | |
|
42fa6b065a | |
|
a34e7286ee | |
|
3663fdfcc1 | |
|
84a40adb1f | |
|
86f6e2e14c | |
|
e9e7e8105b | |
|
1471cd25eb | |
|
a96550863d | |
|
00db49f3e8 | |
|
924a3613f9 | |
|
f35736378c | |
|
0a996e6ed2 | |
|
08d566e855 | |
|
755dd2301e | |
|
a3d60b5ce8 | |
|
0d508ff5e7 | |
|
ee4b5b01c9 | |
|
f4def6e97c | |
|
cb5d7593ef | |
|
9f019fa832 | |
|
cafc161aac | |
|
7f26da7954 | |
|
5a98f3eb7a | |
|
545525ab55 | |
|
2735357852 | |
|
279f35f89b | |
|
8b8295805f | |
|
367e5e2a88 | |
|
4b062e444f | |
|
3b3bc9a16d | |
|
94820a300e | |
|
8eb3dfb35e | |
|
7cee1da98b | |
|
b8967c6653 | |
|
059c97e85f | |
|
5429988cc7 |
|
@ -0,0 +1,60 @@
|
|||
name: Bug Report
|
||||
description: Report a bug in the app.
|
||||
labels: ["bug"]
|
||||
body:
|
||||
- type: checkboxes
|
||||
attributes:
|
||||
label: "Requirements"
|
||||
description: "Please check all the following requirements before submitting a bug report."
|
||||
options:
|
||||
- label: I have searched the issues of this repository and believe that this is not a duplicate
|
||||
required: true
|
||||
- label: I have confirmed this bug exists on the latest version of the app
|
||||
required: true
|
||||
- id: platforms
|
||||
type: dropdown
|
||||
attributes:
|
||||
label: "Platforms"
|
||||
description: "The platforms on which the bug occurs or had occurred. Select all that apply."
|
||||
multiple: true
|
||||
options:
|
||||
- Android
|
||||
- Windows
|
||||
- Linux
|
||||
- Web
|
||||
validations:
|
||||
required: true
|
||||
- id: description
|
||||
type: input
|
||||
attributes:
|
||||
label: "Description"
|
||||
description: "A short description of what the bug is."
|
||||
placeholder: "I was trying to do X, but Y happened instead."
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: "Steps to reproduce"
|
||||
description: "Detailed steps for reproducing the issue."
|
||||
placeholder: "1. Go to '...' 2. Click on '....' 3. Scroll down to '....' 4. See error"
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: "Expected behavior"
|
||||
description: "A clear and concise description of what you expected to happen."
|
||||
placeholder: "I expected to see..."
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: "Actual behavior"
|
||||
description: "A clear and concise description of what actually happened."
|
||||
placeholder: "Instead, I saw..."
|
||||
validations:
|
||||
required: true
|
||||
- id: context
|
||||
type: textarea
|
||||
attributes:
|
||||
label: "Screenshots or additional context"
|
||||
description: "If applicable, add screenshots to help explain your problem."
|
|
@ -0,0 +1,8 @@
|
|||
blank_issues_enabled: false
|
||||
contact_links:
|
||||
- name: Contact Author
|
||||
url: https://jhubi1.com/mailto
|
||||
about: Report security concerns or ask general questions.
|
||||
- name: Translations
|
||||
url: https://crowdin.com/project/ollama-app
|
||||
about: Help translate the app into your language.
|
|
@ -0,0 +1,31 @@
|
|||
name: Feature Request
|
||||
description: Suggest a new feature or improvement for the app.
|
||||
labels: ["enhancement"]
|
||||
body:
|
||||
- type: checkboxes
|
||||
attributes:
|
||||
label: "Requirements"
|
||||
description: "Please check all the following requirements before submitting a feature request."
|
||||
options:
|
||||
- label: I have searched the issues of this repository and believe that this is not a duplicate
|
||||
required: true
|
||||
- label: I can confirm this feature request is not already implemented in the app
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: "Description"
|
||||
description: "A description of the feature you are proposing."
|
||||
placeholder: "I would like to see..."
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: "Possible solution"
|
||||
description: "Suggestions on how to implement the feature."
|
||||
placeholder: "It would be great if..."
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: "Additional context"
|
||||
description: "Add any other context, screenshots or possible concepts about the feature request here."
|
|
@ -0,0 +1,155 @@
|
|||
name: Build app
|
||||
on:
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
obfuscate:
|
||||
description: Obfuscate
|
||||
default: false
|
||||
type: boolean
|
||||
buildAndroid:
|
||||
description: Build for Android
|
||||
required: true
|
||||
default: true
|
||||
type: boolean
|
||||
buildWindowsX64:
|
||||
description: Build for Windows x64
|
||||
required: true
|
||||
default: false
|
||||
type: boolean
|
||||
buildLinuxX64:
|
||||
description: Build for Linux x64
|
||||
required: true
|
||||
default: false
|
||||
type: boolean
|
||||
|
||||
jobs:
|
||||
analyze:
|
||||
name: Linting
|
||||
runs-on: ubuntu-latest
|
||||
outputs:
|
||||
result: ${{ steps.version.outputs.result }}
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: subosito/flutter-action@v2.18.0
|
||||
with:
|
||||
channel: stable
|
||||
flutter-version-file: pubspec.yaml
|
||||
cache: true
|
||||
- name: Get flutter version
|
||||
id: version
|
||||
uses: mikefarah/yq@master
|
||||
with:
|
||||
cmd: yq -r '.version' 'pubspec.yaml' | awk -F'+' '{print $1}'
|
||||
- name: Disabling flutter analytics
|
||||
run: flutter config --no-analytics
|
||||
- name: Analyzing project code
|
||||
run: flutter analyze --no-fatal-infos
|
||||
build-android:
|
||||
name: Building for Android
|
||||
if: ${{ github.event.inputs.buildAndroid == 'true' }}
|
||||
runs-on: ubuntu-latest
|
||||
needs: analyze
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: subosito/flutter-action@v2.18.0
|
||||
with:
|
||||
channel: stable
|
||||
flutter-version-file: pubspec.yaml
|
||||
cache: true
|
||||
- uses: actions/setup-java@v4
|
||||
with:
|
||||
distribution: "adopt"
|
||||
java-version: "17"
|
||||
- name: Copy keystore file
|
||||
run: |
|
||||
echo $'storePassword=${{ secrets.ANDROID_KEYSTORE_PASSPHRASE }}\nkeyPassword=${{ secrets.ANDROID_KEYSTORE_PASSPHRASE }}\nkeyAlias=upload\nstoreFile=upload-keystore.jks\n' > ./android/key.properties
|
||||
echo "${{ secrets.ANDROID_KEYSTORE }}" > ./android/app/upload-keystore.jks.asc
|
||||
gpg -d --passphrase "${{ secrets.ANDROID_KEYSTORE_PASSPHRASE }}" --batch ./android/app/upload-keystore.jks.asc > ./android/app/upload-keystore.jks
|
||||
- name: Disabling flutter analytics
|
||||
run: flutter config --no-analytics
|
||||
- name: Running build
|
||||
id: compile
|
||||
run: flutter build apk --split-debug-info=build/debugAndroid ${{ github.event.inputs.obfuscate == 'true' && '--obfuscate' || '' }}
|
||||
- name: Preparing files
|
||||
run: |
|
||||
cp build/app/outputs/flutter-apk/app-release.apk build/app/outputs/flutter-apk/ollama-android-v${{ needs.analyze.outputs.result }}.apk
|
||||
- name: Uploading APK
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ollama-android
|
||||
path: |
|
||||
build/app/outputs/flutter-apk/ollama-android-v${{ needs.analyze.outputs.result }}.apk
|
||||
build-windows-x64:
|
||||
name: Building for Windows x64
|
||||
if: ${{ github.event.inputs.buildWindowsX64 == 'true' }}
|
||||
runs-on: windows-latest
|
||||
needs: analyze
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: subosito/flutter-action@v2.18.0
|
||||
with:
|
||||
channel: stable
|
||||
flutter-version-file: pubspec.yaml
|
||||
cache: true
|
||||
- name: Disabling flutter analytics
|
||||
run: flutter config --no-analytics
|
||||
- name: Running build
|
||||
id: compile
|
||||
run: flutter build windows --split-debug-info=build\debugWindows ${{ github.event.inputs.obfuscate == 'true' && '--obfuscate' || '' }}
|
||||
- name: Running installer build
|
||||
uses: Minionguyjpro/Inno-Setup-Action@v1.2.2
|
||||
with:
|
||||
path: .\windows_installer\ollama.iss
|
||||
options: /O+ /dAppVersion=${{ needs.analyze.outputs.result }}
|
||||
- name: Uploading installer
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ollama-windows-x64
|
||||
path: build\windows\x64\runner\ollama-windows-x64-v${{ needs.analyze.outputs.result }}.exe
|
||||
build-linux-x64:
|
||||
name: Building for Linux x64
|
||||
if: ${{ github.event.inputs.buildLinuxX64 == 'true' }}
|
||||
runs-on: ubuntu-latest
|
||||
needs: analyze
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: subosito/flutter-action@v2.18.0
|
||||
with:
|
||||
channel: stable
|
||||
flutter-version-file: pubspec.yaml
|
||||
cache: true
|
||||
- name: Disabling flutter analytics
|
||||
run: flutter config --no-analytics
|
||||
- name: Installing linux dependencies
|
||||
run: |
|
||||
sudo apt-get update -y
|
||||
sudo apt-get install -y ninja-build libgtk-3-dev
|
||||
- name: Running build
|
||||
id: compile
|
||||
run: flutter build linux --split-debug-info=build/debugLinux ${{ github.event.inputs.obfuscate == 'true' && '--obfuscate' || '' }}
|
||||
- name: Creating archive
|
||||
run: |
|
||||
cd build/linux/x64/release/bundle
|
||||
tar -czf ollama-linux-x64-v${{ needs.analyze.outputs.result }}.tar.gz *
|
||||
- name: Uploading archive
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ollama-linux-x64
|
||||
path: build/linux/x64/release/bundle/ollama-linux-x64-v${{ needs.analyze.outputs.result }}.tar.gz
|
||||
bundle:
|
||||
name: Creating bundle
|
||||
runs-on: ubuntu-latest
|
||||
if: ${{ always() }}
|
||||
needs: [build-android, build-windows-x64, build-linux-x64]
|
||||
steps:
|
||||
- name: Adding builds
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
merge-multiple: true
|
||||
- name: Generating timestamp
|
||||
run: echo "timestamp=$EPOCHSECONDS"$'\n\norigin=${{ github.repository }}\nhost=${{ github.server_url }}\nowner=${{ github.repository_owner }}\n\nworkflow=${{ github.workflow }}\nrun_id=${{ github.run_id }}\nrun_number=${{ github.run_number }}' > manifest.yaml
|
||||
- name: Bundling files
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ollama
|
||||
path: ./
|
12
.metadata
|
@ -4,7 +4,7 @@
|
|||
# This file should be version controlled and should not be manually edited.
|
||||
|
||||
version:
|
||||
revision: "54e66469a933b60ddf175f858f82eaeb97e48c8d"
|
||||
revision: "35c388afb57ef061d06a39b537336c87e0e3d1b1"
|
||||
channel: "stable"
|
||||
|
||||
project_type: app
|
||||
|
@ -13,11 +13,11 @@ project_type: app
|
|||
migration:
|
||||
platforms:
|
||||
- platform: root
|
||||
create_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d
|
||||
base_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d
|
||||
- platform: android
|
||||
create_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d
|
||||
base_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d
|
||||
create_revision: 35c388afb57ef061d06a39b537336c87e0e3d1b1
|
||||
base_revision: 35c388afb57ef061d06a39b537336c87e0e3d1b1
|
||||
- platform: windows
|
||||
create_revision: 35c388afb57ef061d06a39b537336c87e0e3d1b1
|
||||
base_revision: 35c388afb57ef061d06a39b537336c87e0e3d1b1
|
||||
|
||||
# User provided section
|
||||
|
||||
|
|
|
@ -0,0 +1,7 @@
|
|||
{
|
||||
"recommendations": [
|
||||
"dart-code.dart-code",
|
||||
"dart-code.flutter",
|
||||
"github.vscode-github-actions"
|
||||
]
|
||||
}
|
133
README.md
|
@ -2,129 +2,74 @@
|
|||
|
||||
A modern and easy-to-use client for Ollama. Have the greatest experience while keeping everything private and in your local network.
|
||||
|
||||
|  |  |  |  |
|
||||
|  |  |  |  |
|
||||
|-|-|-|-|
|
||||
|
||||
> Important: This app does not host a Ollama server on device, but rather connects to one and uses its api endpoint.
|
||||
> Don't know what Ollama is? Learn more at [ollama.com](https://ollama.com/).
|
||||
> [!IMPORTANT]
|
||||
> This app does not host a Ollama server on device, but rather connects to one using its api endpoint.
|
||||
> You don't know what Ollama is? Learn more at [ollama.com](https://ollama.com).
|
||||
|
||||
- [Ollama App](#ollama-app)
|
||||
- [Installation](#installation)
|
||||
- [Initial Setup](#initial-setup)
|
||||
- [Side Menu](#side-menu)
|
||||
- [Model Selector](#model-selector)
|
||||
- [Multimodal Model Input](#multimodal-model-input)
|
||||
- [Multilingual Interface](#multilingual-interface)
|
||||
- [Custom Builds](#custom-builds)
|
||||
- [Actually Building](#actually-building)
|
||||
## Getting Started
|
||||
|
||||
## Installation
|
||||
Ollama App has a pretty simple and intuitive interface to be as open as possible. Everything just works out of the box, you just have to follow the next steps.
|
||||
|
||||
You'll find the latest recommended version of the Ollama App under [the releases tab](https://github.com/JHubi1/ollama-app/releases). Download the APK and install it on your Android device. That's it, now proceed to [Initial Setup](#initial-setup).
|
||||
### Installation
|
||||
|
||||
## Initial Setup
|
||||
You'll find the latest recommended version of the Ollama App under the [releases tab](https://github.com/JHubi1/ollama-app/releases). Download the correct executable onto your device and install it. If you want to install on a desktop platform, you might also have to follow the steps listed below, under [Ollama App for Desktop](#ollama-app-for-desktop).
|
||||
|
||||
After installing the app and opening it for the first time, you'll encounter this popup:
|
||||
Alternatively, you can also download the app from any of the following stores:
|
||||
|
||||

|
||||
[<img src="assets/stores/IzzyOnDroid.png" width="215" />](https://apt.izzysoft.de/fdroid/index/apk/com.freakurl.apps.ollama/)
|
||||
<!-- [<img src="assets/stores/FDroid.png" width="215" />](/com.freakurl.apps.ollama/) -->
|
||||
|
||||
Go through the welcome dialog one by one, you should read their content, but you don't have to.
|
||||
That's it, you've successfully installed Ollama App! Now just proceed to [Initial Setup](https://github.com/JHubi1/ollama-app/wiki/Getting-Started#initial-setup) or alternatively [Setup](#setup) below.
|
||||
|
||||
|  |  |  |
|
||||
|-|-|-|
|
||||
### Ollama App for Desktop
|
||||
|
||||
After going through that, you'll get a small snack bar notifying you that you have to set the host. For that, open the sidebar (swipe from the left to right or click the icon in the top left corner) and click on settings. There you'll find all app-related settings, you should go through them, but for the initial setup, only the first one is important.
|
||||
> [!WARNING]
|
||||
> This is still an experimental feature! Some functions may not work as intended. If you come across any errors, please create a new [issue report](https://github.com/JHubi1/ollama-app/issues/new/choose).
|
||||
|
||||
In the bit host text field, you have to enter the base URL of your instance. The port is required, except for the port number matching the protocol (443 for HTTPS or 80 for HTTP). After that, click the save icon right next to the text field.
|
||||
There are a few things you might have to keep in mind if you're planning to use the experimental desktop support.
|
||||
|
||||
This address will be checked, so no worry about entering the wrong one. The disadvantage of this is that your server has to be running even if you don't want to chat with it at that moment. If you set the host once, and your server is offline, the requests will fail, but the host will stay saved if you don't change it yourself. Don't worry, just go into the side menu and click the settings button to change it.
|
||||
#### Windows
|
||||
|
||||
That's it, you can now just chat. Enter a message into the box at the bottom and click the send icon.
|
||||
The Windows version is provided in the form of an installer, you can find it attached on the [latest release](https://github.com/JHubi1/ollama-app/releases). It's not signed, you might have to dismiss the Windows Defender screen by pressing "View More" > "Run Anyway".
|
||||
|
||||
## Side Menu
|
||||
Windows app data is kept at: `C:\Users\[user]\AppData\Roaming\JHubi1\Ollama App`
|
||||
|
||||
The button on the top left opens the menu. In it, you have two options: `New Chat` and `Settings`. The first option creates a new chat, and the second one opens the settings screen where you can change how everything works.
|
||||
#### Linux
|
||||
|
||||
Below that are all the chats. To delete one, swipe it from left to right. To rename the chat tab and hold it until a popup dialog appears. In it, you can change the title or tab the sparkle icon to let AI find one for you. This is not affected by the "generate title" setting.
|
||||
The Linux version is provided in the form of a portable executable, you can find it attached on the [latest release](https://github.com/JHubi1/ollama-app/releases). To start it, execute `./ollama` in the extracted folder.
|
||||
|
||||
| |  |
|
||||
|-|-|
|
||||
If a message like `error while loading shared libraries: libgtk-3.so.0: cannot open shared object file` appears when you start the app, run the following commands:
|
||||
|
||||
> Note: The button on the top right corner deletes the chat. It has the same effect as swiping the chat in the sidebar.
|
||||
- `sudo apt-get update`
|
||||
- `sudo apt-get upgrade`
|
||||
- `sudo apt-get install packagekit-gtk3-module`
|
||||
|
||||
## Model Selector
|
||||
Linux app data is kept at: `/home/[user]/.local/share/ollama`
|
||||
|
||||
You can access the model selector by tapping on the `<selector>` text in the top middle or the name of the currently selected model in the same spot. Then you'll get the following bottom sheet:
|
||||
### Setup
|
||||
|
||||

|
||||
The most difficult part is setting up the host. To learn more visit the [wiki guide on how to do so](https://github.com/JHubi1/ollama-app/wiki/Getting-Started#setting-up-the-host). After setting up, you normally don't have to enter it again.
|
||||
|
||||
This will display all the models currently installed in your Ollama server instance.
|
||||
And you're done! Just start chatting with your local AI and have fun!
|
||||
|
||||
Models with an image-like icon next to them allow multimodal input. The one shown in the image, `llava`, supports exactly that.
|
||||
> [!TIP]
|
||||
> The new Voice Mode is now avaliable as an experimental feature. Learn more about it in [the documentation](https://github.com/JHubi1/ollama-app/wiki/Components#voice).
|
||||
|
||||
The models with a star next to them are recommended models. They have been selected by me (hehe) to be listed as that. Read more under [Custom Builds](#custom-builds).
|
||||
## Documentation
|
||||
|
||||
The `Add` button does nothing at the moment, it just opens a snack bar listing steps on how to add a model to an instance. For safety reasons, I didn't add the ability to add a model directly via name in the app.
|
||||
The documentation for components, settings, functions, etc. has moved to the [Wiki Page](https://github.com/JHubi1/ollama-app/wiki) of this repository. The steps there will be updated with future versions. Still having questions? Feel free to open an issue.
|
||||
|
||||
## Multimodal Model Input
|
||||
## Translations and Contribution
|
||||
|
||||
Ollama App supports multimodal models, models with support input via an image.
|
||||
You want to help me make this project even better? Great, help is always appresheated.
|
||||
|
||||
After selecting a supported model, as describes in [Model Selector](#model-selector), a new icon appears at the bottom left of the message bar; a camera icon. Clicking on it reveals the following bottom sheet:
|
||||
Ollama App is created using [Flutter](https://flutter.dev), a modern and robust frontend framework designed to make a single codebase run on multiple target platforms. The framework itself is based on the [Dart](https://dart.dev) programming language.
|
||||
|
||||
|  |  |
|
||||
|-|-|
|
||||
Read more in the [Contribution Guide](https://github.com/JHubi1/ollama-app/wiki/Contributing).
|
||||
|
||||
Select one of them, take or select your photo and it'll get added to the chat. You can also add multiple.
|
||||
## Star History
|
||||
|
||||
Even though the images will appear in the chat already after sending, they won't be submitted to the AI until a new text message is sent.
|
||||
|
||||
## Multilingual Interface
|
||||
|
||||
I integrated support for multiple languages into the Ollama App. Currently available are:
|
||||
|
||||
- English
|
||||
- German
|
||||
|
||||
Your language isn't one of them? Reach out to me and I'll give you access to my Crowdin project.
|
||||
|
||||
## Custom Builds
|
||||
|
||||
Now comes the interesting part. I built this app in a way you can easily create custom builds. Currently, there are these values that can be customized:
|
||||
|
||||
```
|
||||
// use host or not, if false dialog is shown
|
||||
const useHost = false;
|
||||
// host of ollama, must be accessible from the client, without trailing slash, will always be accepted as valid
|
||||
const fixedHost = "http://example.com:11434";
|
||||
// use model or not, if false selector is shown
|
||||
const useModel = false;
|
||||
// model name as string, must be valid ollama model!
|
||||
const fixedModel = "gemma";
|
||||
// recommended models, shown with as star in model selector
|
||||
const recommendedModels = ["gemma", "llama3"];
|
||||
// allow opening of settings
|
||||
const allowSettings = true;
|
||||
// allow multiple chats
|
||||
const allowMultipleChats = true;
|
||||
```
|
||||
|
||||
They can be found at the top of `lib/main.dart`. `useHost` and `useModel` decide whether you want `fixedHost` and `fixedModel` to control anything. `fixedHost` and `fixedModel` decide about the value that has to be used. That can be practical in case you try to create an app specific to your instance.
|
||||
|
||||
`recommendedModels` is a list of models that will be listed as recommended in the [Model Selector](#model-selector). They are more like personal preferences. If empty, no model will be preferred.
|
||||
|
||||
`allowSettings` will disable the settings screen. But it will also disable the welcome dialog at first startup and the ability to rename chats.
|
||||
|
||||
`allowMultipleChats` simply removes the `New Chat` option in the [Side Menu](#side-menu). And will load up the only available chat on app startup.
|
||||
|
||||
### Actually Building
|
||||
|
||||
But how do you create a custom build?
|
||||
|
||||
First, follow [the Flutter installation guide](https://docs.flutter.dev/get-started/install) by selecting Android as the first app type. Then follow [these steps](https://docs.flutter.dev/deployment/android#signing-the-app) till you have your custom `key.properties`. Place it into the `android` folder at the root of the project.
|
||||
|
||||
If you're running on Windows, just double-click on `scripts/build.bat` and wait till the process is done. Don't worry, there'll be a lot of Kotlin errors in the terminal. You can safely ignore them, the build will be fine.
|
||||
|
||||
If you're not running Windows, open the file `scripts/build.bat` in a text editor and copy the command starting with `flutter` after the `call` command in a terminal window. Again, don't worry about the Kotlin errors.
|
||||
|
||||
In both cases, you'll now find your APK in `build/app/outputs/apk/release/app-release.apk` (don't blame me for that, it's a flutter thing).
|
||||

|
||||
|
|
|
@ -5,9 +5,10 @@ gradle-wrapper.jar
|
|||
/gradlew.bat
|
||||
/local.properties
|
||||
GeneratedPluginRegistrant.java
|
||||
.cxx/
|
||||
|
||||
# Remember to never publicly share your keystore.
|
||||
# See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app
|
||||
# See https://flutter.dev/to/reference-keystore
|
||||
key.properties
|
||||
**/*.keystore
|
||||
**/*.jks
|
||||
|
|
|
@ -1,80 +0,0 @@
|
|||
plugins {
|
||||
id "com.android.application"
|
||||
id "kotlin-android"
|
||||
id "dev.flutter.flutter-gradle-plugin"
|
||||
}
|
||||
|
||||
def localProperties = new Properties()
|
||||
def localPropertiesFile = rootProject.file('local.properties')
|
||||
if (localPropertiesFile.exists()) {
|
||||
localPropertiesFile.withReader('UTF-8') { reader ->
|
||||
localProperties.load(reader)
|
||||
}
|
||||
}
|
||||
|
||||
def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
|
||||
if (flutterVersionCode == null) {
|
||||
flutterVersionCode = '1'
|
||||
}
|
||||
|
||||
def flutterVersionName = localProperties.getProperty('flutter.versionName')
|
||||
if (flutterVersionName == null) {
|
||||
flutterVersionName = '1.0'
|
||||
}
|
||||
|
||||
def keystoreProperties = new Properties()
|
||||
def keystorePropertiesFile = rootProject.file('key.properties')
|
||||
if (keystorePropertiesFile.exists()) {
|
||||
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
|
||||
}
|
||||
|
||||
android {
|
||||
namespace "com.example.ollama"
|
||||
compileSdk flutter.compileSdkVersion
|
||||
ndkVersion flutter.ndkVersion
|
||||
|
||||
compileOptions {
|
||||
sourceCompatibility JavaVersion.VERSION_1_8
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
kotlinOptions {
|
||||
jvmTarget = '1.8'
|
||||
}
|
||||
|
||||
sourceSets {
|
||||
main.java.srcDirs += 'src/main/kotlin'
|
||||
}
|
||||
|
||||
defaultConfig {
|
||||
applicationId "com.freakurl.apps.ollama"
|
||||
// You can update the following values to match your application needs.
|
||||
// For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration.
|
||||
minSdkVersion flutter.minSdkVersion
|
||||
targetSdkVersion flutter.targetSdkVersion
|
||||
versionCode flutterVersionCode.toInteger()
|
||||
versionName flutterVersionName
|
||||
}
|
||||
|
||||
signingConfigs {
|
||||
release {
|
||||
keyAlias keystoreProperties['keyAlias']
|
||||
keyPassword keystoreProperties['keyPassword']
|
||||
storeFile keystoreProperties['storeFile'] ? file(keystoreProperties['storeFile']) : null
|
||||
storePassword keystoreProperties['storePassword']
|
||||
}
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
// Signing with the debug keys for now, so `flutter run --release` works.
|
||||
signingConfig signingConfigs.release
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
flutter {
|
||||
source '../..'
|
||||
}
|
||||
|
||||
dependencies {}
|
|
@ -0,0 +1,59 @@
|
|||
import java.util.Properties
|
||||
import java.io.FileInputStream
|
||||
|
||||
plugins {
|
||||
id("com.android.application")
|
||||
id("kotlin-android")
|
||||
// The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins.
|
||||
id("dev.flutter.flutter-gradle-plugin")
|
||||
}
|
||||
|
||||
val keystoreProperties = Properties()
|
||||
val keystorePropertiesFile = rootProject.file("key.properties")
|
||||
if (keystorePropertiesFile.exists()) {
|
||||
keystoreProperties.load(FileInputStream(keystorePropertiesFile))
|
||||
}
|
||||
|
||||
android {
|
||||
namespace = "com.freakurl.apps.ollama"
|
||||
compileSdk = flutter.compileSdkVersion
|
||||
ndkVersion = "27.0.12077973" // flutter.ndkVersion
|
||||
|
||||
compileOptions {
|
||||
sourceCompatibility = JavaVersion.VERSION_11
|
||||
targetCompatibility = JavaVersion.VERSION_11
|
||||
}
|
||||
|
||||
kotlinOptions {
|
||||
jvmTarget = JavaVersion.VERSION_11.toString()
|
||||
}
|
||||
|
||||
defaultConfig {
|
||||
applicationId = "com.freakurl.apps.ollama"
|
||||
// You can update the following values to match your application needs.
|
||||
// For more information, see: https://flutter.dev/to/review-gradle-config.
|
||||
minSdk = flutter.minSdkVersion
|
||||
targetSdk = flutter.targetSdkVersion
|
||||
versionCode = flutter.versionCode
|
||||
versionName = flutter.versionName
|
||||
}
|
||||
|
||||
signingConfigs {
|
||||
create("release") {
|
||||
keyAlias = keystoreProperties["keyAlias"] as String
|
||||
keyPassword = keystoreProperties["keyPassword"] as String
|
||||
storeFile = keystoreProperties["storeFile"]?.let { file(it) }
|
||||
storePassword = keystoreProperties["storePassword"] as String
|
||||
}
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
signingConfig = signingConfigs.getByName("release")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
flutter {
|
||||
source = "../.."
|
||||
}
|
|
@ -2,11 +2,13 @@
|
|||
<application
|
||||
android:label="Ollama"
|
||||
android:name="${applicationName}"
|
||||
android:icon="@mipmap/ic_launcher">
|
||||
android:icon="@mipmap/ic_launcher"
|
||||
android:enableOnBackInvokedCallback="true">
|
||||
<activity
|
||||
android:name=".MainActivity"
|
||||
android:exported="true"
|
||||
android:launchMode="singleTop"
|
||||
android:taskAffinity=""
|
||||
android:theme="@style/LaunchTheme"
|
||||
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|smallestScreenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
|
||||
android:hardwareAccelerated="true"
|
||||
|
@ -16,12 +18,12 @@
|
|||
while the Flutter UI initializes. After that, this theme continues
|
||||
to determine the Window background behind the Flutter UI. -->
|
||||
<meta-data
|
||||
android:name="io.flutter.embedding.android.NormalTheme"
|
||||
android:resource="@style/NormalTheme"
|
||||
/>
|
||||
android:name="io.flutter.embedding.android.NormalTheme"
|
||||
android:resource="@style/NormalTheme"
|
||||
/>
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
<action android:name="android.intent.action.MAIN"/>
|
||||
<category android:name="android.intent.category.LAUNCHER"/>
|
||||
</intent-filter>
|
||||
</activity>
|
||||
<!-- Don't delete the meta-data below.
|
||||
|
@ -31,25 +33,39 @@
|
|||
android:value="2" />
|
||||
</application>
|
||||
<!-- Required to query activities that can process text, see:
|
||||
https://developer.android.com/training/package-visibility?hl=en and
|
||||
https://developer.android.com/training/package-visibility and
|
||||
https://developer.android.com/reference/android/content/Intent#ACTION_PROCESS_TEXT.
|
||||
|
||||
In particular, this is used by the Flutter engine in io.flutter.plugin.text.ProcessTextPlugin. -->
|
||||
<queries>
|
||||
<intent>
|
||||
<action android:name="android.intent.action.PROCESS_TEXT" />
|
||||
<data android:mimeType="text/plain" />
|
||||
<action android:name="android.intent.action.PROCESS_TEXT"/>
|
||||
<data android:mimeType="text/plain"/>
|
||||
</intent>
|
||||
<!-- check if url is valid -->
|
||||
<intent>
|
||||
<action android:name="android.intent.action.VIEW" />
|
||||
<data android:scheme="http" />
|
||||
<action android:name="android.intent.action.VIEW"/>
|
||||
<data android:scheme="http"/>
|
||||
</intent>
|
||||
<intent>
|
||||
<action android:name="android.intent.action.VIEW" />
|
||||
<action android:name="android.intent.action.VIEW"/>
|
||||
<data android:scheme="https"/>
|
||||
</intent>
|
||||
<!-- check if url is valid end -->
|
||||
<!-- voice mode -->
|
||||
<intent>
|
||||
<action android:name="android.speech.RecognitionService"/>
|
||||
</intent>
|
||||
<intent>
|
||||
<action android:name="android.intent.action.TTS_SERVICE"/>
|
||||
</intent>
|
||||
<!-- voice mode end-->
|
||||
</queries>
|
||||
<uses-permission android:name="android.permission.INTERNET" />
|
||||
</manifest>
|
||||
<!-- voice mode -->
|
||||
<uses-permission android:name="android.permission.RECORD_AUDIO"/>
|
||||
<uses-permission android:name="android.permission.BLUETOOTH"/>
|
||||
<uses-permission android:name="android.permission.BLUETOOTH_ADMIN"/>
|
||||
<uses-permission android:name="android.permission.BLUETOOTH_CONNECT"/>
|
||||
<!-- voice mode end -->
|
||||
</manifest>
|
||||
|
|
|
@ -1,5 +0,0 @@
|
|||
package com.example.ollama
|
||||
|
||||
import io.flutter.embedding.android.FlutterActivity
|
||||
|
||||
class MainActivity: FlutterActivity()
|
|
@ -0,0 +1,5 @@
|
|||
package com.freakurl.apps.ollama
|
||||
|
||||
import io.flutter.embedding.android.FlutterActivity
|
||||
|
||||
class MainActivity : FlutterActivity()
|
|
@ -1,18 +0,0 @@
|
|||
allprojects {
|
||||
repositories {
|
||||
google()
|
||||
mavenCentral()
|
||||
}
|
||||
}
|
||||
|
||||
rootProject.buildDir = '../build'
|
||||
subprojects {
|
||||
project.buildDir = "${rootProject.buildDir}/${project.name}"
|
||||
}
|
||||
subprojects {
|
||||
project.evaluationDependsOn(':app')
|
||||
}
|
||||
|
||||
tasks.register("clean", Delete) {
|
||||
delete rootProject.buildDir
|
||||
}
|
|
@ -0,0 +1,21 @@
|
|||
allprojects {
|
||||
repositories {
|
||||
google()
|
||||
mavenCentral()
|
||||
}
|
||||
}
|
||||
|
||||
val newBuildDir: Directory = rootProject.layout.buildDirectory.dir("../../build").get()
|
||||
rootProject.layout.buildDirectory.value(newBuildDir)
|
||||
|
||||
subprojects {
|
||||
val newSubprojectBuildDir: Directory = newBuildDir.dir(project.name)
|
||||
project.layout.buildDirectory.value(newSubprojectBuildDir)
|
||||
}
|
||||
subprojects {
|
||||
project.evaluationDependsOn(":app")
|
||||
}
|
||||
|
||||
tasks.register<Delete>("clean") {
|
||||
delete(rootProject.layout.buildDirectory)
|
||||
}
|
|
@ -1,3 +1,3 @@
|
|||
org.gradle.jvmargs=-Xmx4G
|
||||
org.gradle.jvmargs=-Xmx8G -XX:MaxMetaspaceSize=4G -XX:ReservedCodeCacheSize=512m -XX:+HeapDumpOnOutOfMemoryError
|
||||
android.useAndroidX=true
|
||||
android.enableJetifier=true
|
||||
|
|
|
@ -2,4 +2,4 @@ distributionBase=GRADLE_USER_HOME
|
|||
distributionPath=wrapper/dists
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.3-all.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-all.zip
|
||||
|
|
|
@ -1,26 +0,0 @@
|
|||
pluginManagement {
|
||||
def flutterSdkPath = {
|
||||
def properties = new Properties()
|
||||
file("local.properties").withInputStream { properties.load(it) }
|
||||
def flutterSdkPath = properties.getProperty("flutter.sdk")
|
||||
assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
|
||||
return flutterSdkPath
|
||||
}
|
||||
settings.ext.flutterSdkPath = flutterSdkPath()
|
||||
|
||||
includeBuild("${settings.ext.flutterSdkPath}/packages/flutter_tools/gradle")
|
||||
|
||||
repositories {
|
||||
google()
|
||||
mavenCentral()
|
||||
gradlePluginPortal()
|
||||
}
|
||||
}
|
||||
|
||||
plugins {
|
||||
id "dev.flutter.flutter-plugin-loader" version "1.0.0"
|
||||
id "com.android.application" version "7.3.0" apply false
|
||||
id "org.jetbrains.kotlin.android" version "1.7.10" apply false
|
||||
}
|
||||
|
||||
include ":app"
|
|
@ -0,0 +1,25 @@
|
|||
pluginManagement {
|
||||
val flutterSdkPath = run {
|
||||
val properties = java.util.Properties()
|
||||
file("local.properties").inputStream().use { properties.load(it) }
|
||||
val flutterSdkPath = properties.getProperty("flutter.sdk")
|
||||
require(flutterSdkPath != null) { "flutter.sdk not set in local.properties" }
|
||||
flutterSdkPath
|
||||
}
|
||||
|
||||
includeBuild("$flutterSdkPath/packages/flutter_tools/gradle")
|
||||
|
||||
repositories {
|
||||
google()
|
||||
mavenCentral()
|
||||
gradlePluginPortal()
|
||||
}
|
||||
}
|
||||
|
||||
plugins {
|
||||
id("dev.flutter.flutter-plugin-loader") version "1.0.0"
|
||||
id("com.android.application") version "8.7.0" apply false
|
||||
id("org.jetbrains.kotlin.android") version "1.8.22" apply false
|
||||
}
|
||||
|
||||
include(":app")
|
After Width: | Height: | Size: 1.2 MiB |
After Width: | Height: | Size: 17 KiB |
After Width: | Height: | Size: 53 KiB |
After Width: | Height: | Size: 109 KiB |
After Width: | Height: | Size: 92 KiB |
After Width: | Height: | Size: 45 KiB |
After Width: | Height: | Size: 81 KiB |
After Width: | Height: | Size: 82 KiB |
After Width: | Height: | Size: 78 KiB |
After Width: | Height: | Size: 87 KiB |
After Width: | Height: | Size: 154 KiB |
After Width: | Height: | Size: 137 KiB |
After Width: | Height: | Size: 83 KiB |
After Width: | Height: | Size: 75 KiB |
After Width: | Height: | Size: 157 KiB |
After Width: | Height: | Size: 73 KiB |
After Width: | Height: | Size: 109 KiB |
After Width: | Height: | Size: 74 KiB |
After Width: | Height: | Size: 69 KiB |
After Width: | Height: | Size: 101 KiB |
After Width: | Height: | Size: 104 KiB |
After Width: | Height: | Size: 122 KiB |
After Width: | Height: | Size: 121 KiB |
After Width: | Height: | Size: 139 KiB |
After Width: | Height: | Size: 88 KiB |
After Width: | Height: | Size: 125 KiB |
After Width: | Height: | Size: 116 KiB |
After Width: | Height: | Size: 39 KiB |
After Width: | Height: | Size: 151 KiB |
After Width: | Height: | Size: 62 KiB |
After Width: | Height: | Size: 140 KiB |
After Width: | Height: | Size: 56 KiB |
After Width: | Height: | Size: 60 KiB |
After Width: | Height: | Size: 513 KiB |
After Width: | Height: | Size: 643 KiB |
After Width: | Height: | Size: 39 KiB |
After Width: | Height: | Size: 57 KiB |
After Width: | Height: | Size: 93 KiB |
After Width: | Height: | Size: 181 KiB |
After Width: | Height: | Size: 25 KiB |
After Width: | Height: | Size: 32 KiB |
After Width: | Height: | Size: 169 KiB |
After Width: | Height: | Size: 40 KiB |
After Width: | Height: | Size: 40 KiB |
After Width: | Height: | Size: 39 KiB |
After Width: | Height: | Size: 39 KiB |
Before Width: | Height: | Size: 38 KiB |
Before Width: | Height: | Size: 118 KiB |
Before Width: | Height: | Size: 59 KiB |
Before Width: | Height: | Size: 146 KiB |
Before Width: | Height: | Size: 123 KiB |
Before Width: | Height: | Size: 238 KiB |
Before Width: | Height: | Size: 37 KiB |
Before Width: | Height: | Size: 118 KiB |
Before Width: | Height: | Size: 37 KiB |
Before Width: | Height: | Size: 118 KiB |
Before Width: | Height: | Size: 57 KiB |
Before Width: | Height: | Size: 152 KiB |
Before Width: | Height: | Size: 21 KiB |
Before Width: | Height: | Size: 14 KiB |
Before Width: | Height: | Size: 18 KiB |
Before Width: | Height: | Size: 56 KiB |
Before Width: | Height: | Size: 19 KiB |
Before Width: | Height: | Size: 14 KiB |
Before Width: | Height: | Size: 40 KiB |
Before Width: | Height: | Size: 45 KiB |
Before Width: | Height: | Size: 11 KiB |
After Width: | Height: | Size: 62 KiB |
After Width: | Height: | Size: 45 KiB |
Before Width: | Height: | Size: 64 KiB After Width: | Height: | Size: 73 KiB |
Before Width: | Height: | Size: 64 KiB After Width: | Height: | Size: 69 KiB |
Before Width: | Height: | Size: 152 KiB After Width: | Height: | Size: 160 KiB |
Before Width: | Height: | Size: 160 KiB After Width: | Height: | Size: 166 KiB |
Before Width: | Height: | Size: 120 KiB After Width: | Height: | Size: 98 KiB |
Before Width: | Height: | Size: 120 KiB After Width: | Height: | Size: 98 KiB |
|
@ -0,0 +1,3 @@
|
|||
description: This file stores settings for Dart & Flutter DevTools.
|
||||
documentation: https://docs.flutter.dev/tools/devtools/extensions#configure-extension-enablement-states
|
||||
extensions:
|
|
@ -1 +0,0 @@
|
|||
Erstveröffentlichung
|
|
@ -1,9 +0,0 @@
|
|||
- Einstellungen hinzugefügt
|
||||
- Begrüßungsdialog hinzugefügt
|
||||
- Hinzugefügte benutzerdefinierte Systemnachricht
|
||||
- Markdown in Nachrichten hinzugefügt
|
||||
- Gestreamte Antworten hinzugefügt
|
||||
- Vollständig überarbeitetes UI-Konzept
|
||||
- Unterstützung für Mehrfachchats
|
||||
- Konversationstitel hinzugefügt
|
||||
- Fehler behoben, wenn die Modellversion nicht `latest` ist
|
Before Width: | Height: | Size: 69 KiB |