diff --git a/flatpak/ai.jan.Jan.metainfo.xml b/flatpak/ai.jan.Jan.metainfo.xml new file mode 100644 index 0000000000..510eb5633a --- /dev/null +++ b/flatpak/ai.jan.Jan.metainfo.xml @@ -0,0 +1,47 @@ + + + ai.jan.Jan + FSFAP + AGPL-3.0-only + Menlo Research + Jan + ai.jan.Jan + Local AI Assistant that runs 100% offline on your device + + Utility + Education + Chat + Dictionary + + +

+ Jan is a ChatGPT-alternative that runs 100% offline on your device. Our goal is to make it easy for anyone to download and run LLMs and use AI with full control and privacy. +

+

Features:

+ +
+ai.jan.Jan.desktop + + + https://catalog.jan.ai/flatpak/demo.gif + + + +https://jan.ai/ +https://github.com/janhq/jan/issues + + + + + + +

Latest stable release of Jan AI

+
+
+
+
diff --git a/flatpak/ai.jan.Jan.yml b/flatpak/ai.jan.Jan.yml new file mode 100644 index 0000000000..bf27cb6ce1 --- /dev/null +++ b/flatpak/ai.jan.Jan.yml @@ -0,0 +1,118 @@ +id: ai.jan.Jan +runtime: org.gnome.Platform +runtime-version: '48' +sdk: org.gnome.Sdk +command: Jan +finish-args: + - --socket=wayland # Permission needed to show the window + - --socket=fallback-x11 # Permission needed to show the window on X11 + - --device=dri + - --share=ipc + - --share=network + - --socket=pulseaudio # for future multimodality + - --filesystem=xdg-run/dconf + - --filesystem=~/.config/dconf:ro + - --filesystem=~/.config/kioslaverc + - --env=GTK_PATH=/app/lib/gtkmodules + +modules: + - name: volk + buildsystem: cmake-ninja + builddir: true + config-opts: + - -DVOLK_INSTALL=ON + sources: + - type: archive + url: https://github.com/zeux/volk/archive/refs/tags/vulkan-sdk-1.3.280.0.zip + sha256: 178875134d36e8b90f7e3ec31171355df3b71f47eba49cca2f98158e6552b011 + + - name: vulkan-headers + buildsystem: cmake-ninja + builddir: true + sources: + - type: archive + url: https://github.com/KhronosGroup/Vulkan-Headers/archive/refs/tags/v1.3.283.zip + sha256: 2094159c87fb4b6d8f734bd4cad59564cef7ef32feb00cf6d8ca7e75a84df921 + + - name: vulkan-tools + buildsystem: cmake-ninja + builddir: true + sources: + - type: archive + url: https://github.com/KhronosGroup/Vulkan-Tools/archive/refs/tags/v1.3.283.zip + sha256: 11ec6b474e91dc8cb6e7f22891294ede549bb6ed67c19d230e293b3fc9610883 + + - name: shaderc + buildsystem: cmake-ninja + builddir: true + config-opts: + - -DSHADERC_SKIP_COPYRIGHT_CHECK=ON + - -DSHADERC_SKIP_EXAMPLES=ON + - -DSHADERC_SKIP_TESTS=ON + - -DSPIRV_SKIP_EXECUTABLES=ON + - -DENABLE_GLSLANG_BINARIES=OFF + cleanup: + - /bin + - /include + - /lib/cmake + - /lib/pkgconfig + sources: + - type: git + url: https://github.com/google/shaderc.git + tag: v2024.1 + commit: 47a9387ef5b3600d30d84c71ec77a59dc7db46fa + # https://github.com/google/shaderc/blob/known-good/known_good.json + - type: git + url: https://github.com/KhronosGroup/SPIRV-Tools.git + commit: dd4b663e13c07fea4fbb3f70c1c91c86731099f7 + dest: third_party/spirv-tools + - type: git + url: https://github.com/KhronosGroup/SPIRV-Headers.git + commit: 5e3ad389ee56fca27c9705d093ae5387ce404df4 + dest: third_party/spirv-headers + - type: git + url: https://github.com/KhronosGroup/glslang.git + commit: 142052fa30f9eca191aa9dcf65359fcaed09eeec + dest: third_party/glslang + + - name: cuda-toolkit + only-arches: + - x86_64 + cleanup: + - /cuda + buildsystem: simple + build-commands: + - mkdir /app/cuda + - sh cuda_toolkit.run --silent --toolkit --toolkitpath=/app/cuda + - mv /app/cuda/lib64/libcudart.* /app/lib/ + - mv /app/cuda/lib64/libcublas* /app/lib/ + sources: + - type: file + only-arches: + - x86_64 + url: https://developer.download.nvidia.com/compute/cuda/12.8.0/local_installers/cuda_12.8.0_570.86.10_linux.run + dest-filename: cuda_toolkit.run + md5: c71027cf1a4ce84f80b9cbf81116e767 + + - name: binary + buildsystem: simple + sources: + - type: file + url: https://catalog.jan.ai/flatpak/Jan_0.6.8_amd64.deb + sha256: 15d1368c318a3853bad4fc3646f88afdbf9f52b6416a4734f7a297741d171f28 + only-arches: [x86_64] + - type: file + path: ai.jan.Jan.metainfo.xml + build-commands: + - ar -x *.deb + - tar -xf data.tar.gz + - 'install -Dm755 usr/bin/Jan /app/bin/Jan' + - 'install -Dm755 usr/bin/bun /app/bin/bun' + - 'install -Dm755 usr/bin/uv /app/bin/uv' + - cp -rv usr/lib/* /app/lib/. + - install -Dm644 usr/share/applications/Jan.desktop /app/share/applications/ai.jan.Jan.desktop + - sed -e 's/Icon=Jan/Icon=ai.jan.Jan/g' -e 's#Exec=Jan#Exec=/app/bin/Jan#g' -i /app/share/applications/ai.jan.Jan.desktop + - install -Dm644 usr/share/icons/hicolor/128x128/apps/Jan.png /app/share/icons/hicolor/128x128/apps/ai.jan.Jan.png + - install -Dm644 usr/share/icons/hicolor/32x32/apps/Jan.png /app/share/icons/hicolor/32x32/apps/ai.jan.Jan.png + - install -Dm644 usr/share/icons/hicolor/256x256@2/apps/Jan.png /app/share/icons/hicolor/256x256@2/apps/ai.jan.Jan.png + - install -Dm644 ai.jan.Jan.metainfo.xml /app/share/metainfo/ai.jan.Jan.rosary.metainfo.xml