1. 03 Jul, 2024 1 commit
    • Daniel Hiltgen's avatar
      Fix corner cases on tmp cleaner on mac · 0e982bc1
      Daniel Hiltgen authored
      When ollama is running a long time, tmp cleaners can remove the
      runners.  This tightens up a few corner cases on arm macs where
      we failed with "server cpu not listed in available servers map[]"
      0e982bc1
  2. 01 Jul, 2024 2 commits
  3. 25 Jun, 2024 1 commit
    • Blake Mizerany's avatar
      llm: speed up gguf decoding by a lot (#5246) · cb42e607
      Blake Mizerany authored
      Previously, some costly things were causing the loading of GGUF files
      and their metadata and tensor information to be VERY slow:
      
        * Too many allocations when decoding strings
        * Hitting disk for each read of each key and value, resulting in a
          not-okay amount of syscalls/disk I/O.
      
      The show API is now down to 33ms from 800ms+ for llama3 on a macbook pro
      m3.
      
      This commit also prevents collecting large arrays of values when
      decoding GGUFs (if desired). When such keys are encountered, their
      values are null, and are encoded as such in JSON.
      
      Also, this fixes a broken test that was not encoding valid GGUF.
      cb42e607
  4. 21 Jun, 2024 1 commit
    • Daniel Hiltgen's avatar
      Enable concurrency by default · 17b7186c
      Daniel Hiltgen authored
      This adjusts our default settings to enable multiple models and parallel
      requests to a single model.  Users can still override these by the same
      env var settings as before.  Parallel has a direct impact on
      num_ctx, which in turn can have a significant impact on small VRAM GPUs
      so this change also refines the algorithm so that when parallel is not
      explicitly set by the user, we try to find a reasonable default that fits
      the model on their GPU(s).  As before, multiple models will only load
      concurrently if they fully fit in VRAM.
      17b7186c
  5. 20 Jun, 2024 1 commit
  6. 18 Jun, 2024 1 commit
    • Daniel Hiltgen's avatar
      Tighten up memory prediction logging · 7784ca33
      Daniel Hiltgen authored
      Prior to this change, we logged the memory prediction multiple times
      as the scheduler iterates to find a suitable configuration, which can be
      confusing since only the last log before the server starts is actually valid.
      This now logs once just before starting the server on the final configuration.
      It also reports what library instead of always saying "offloading to gpu" when
      using CPU.
      7784ca33
  7. 17 Jun, 2024 2 commits
    • Daniel Hiltgen's avatar
      Adjust mmap logic for cuda windows for faster model load · 17179679
      Daniel Hiltgen authored
      On Windows, recent llama.cpp changes make mmap slower in most
      cases, so default to off.  This also implements a tri-state for
      use_mmap so we can detect the difference between a user provided
      value of true/false, or unspecified.
      17179679
    • Daniel Hiltgen's avatar
      Move libraries out of users path · b2799f11
      Daniel Hiltgen authored
      We update the PATH on windows to get the CLI mapped, but this has
      an unintended side effect of causing other apps that may use our bundled
      DLLs to get terminated when we upgrade.
      b2799f11
  8. 14 Jun, 2024 4 commits
  9. 09 Jun, 2024 1 commit
  10. 04 Jun, 2024 2 commits
  11. 01 Jun, 2024 1 commit
  12. 30 May, 2024 1 commit
  13. 29 May, 2024 1 commit
  14. 28 May, 2024 2 commits
  15. 25 May, 2024 1 commit
  16. 24 May, 2024 1 commit
  17. 23 May, 2024 2 commits
  18. 20 May, 2024 1 commit
    • Sam's avatar
      feat: add support for flash_attn (#4120) · e15307fd
      Sam authored
      * feat: enable flash attention if supported
      
      * feat: enable flash attention if supported
      
      * feat: enable flash attention if supported
      
      * feat: add flash_attn support
      e15307fd
  19. 15 May, 2024 2 commits
  20. 14 May, 2024 1 commit
  21. 11 May, 2024 1 commit
  22. 10 May, 2024 2 commits
  23. 09 May, 2024 5 commits
  24. 08 May, 2024 1 commit
  25. 07 May, 2024 1 commit
  26. 06 May, 2024 1 commit
    • Daniel Hiltgen's avatar
      Use our libraries first · 380378cc
      Daniel Hiltgen authored
      Trying to live off the land for cuda libraries was not the right strategy.  We need to use the version we compiled against to ensure things work properly
      380378cc