char-fork/llama.cpp

git clone https://git.t4t.associates/char-fork/llama.cpp

Someonenix: init singularity and docker images (#5056)201294ae1

char/aliceai-t5-moe
850 B37 linesraw
1{
2  lib,
3  dockerTools,
4  buildEnv,
5  llama-cpp,
6  interactive ? true,
7  coreutils,
8}:
9
10# A tar that can be fed into `docker load`:
11#
12# $ nix build .#llamaPackages.docker
13# $ docker load < result
14
15# For details and variations cf.
16# - https://nixos.org/manual/nixpkgs/unstable/#ssec-pkgs-dockerTools-buildLayeredImage
17# - https://discourse.nixos.org/t/a-faster-dockertools-buildimage-prototype/16922
18# - https://nixery.dev/
19
20# Approximate (compressed) sizes, at the time of writing, are:
21#
22# .#llamaPackages.docker: 125M;
23# .#llamaPackagesCuda.docker: 537M;
24# .#legacyPackages.aarch64-linux.llamaPackagesXavier.docker: 415M.
25
26dockerTools.buildLayeredImage {
27  name = llama-cpp.pname;
28  tag = "latest";
29
30  contents =
31    [ llama-cpp ]
32    ++ lib.optionals interactive [
33      coreutils
34      dockerTools.binSh
35      dockerTools.caCertificates
36    ];
37}