Skip to content

Commit 7b8f354

Browse files
authored
Merge pull request #9 from arthw/cherry-pick-12447
Cherry pick 12447
2 parents 37a06a0 + 7e411f9 commit 7b8f354

File tree

249 files changed

+32164
-18420
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

249 files changed

+32164
-18420
lines changed

.github/workflows/build.yml

Lines changed: 35 additions & 1227 deletions
Large diffs are not rendered by default.

.github/workflows/server.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,8 @@ jobs:
161161
- name: Tests
162162
id: server_integration_tests
163163
if: ${{ matrix.sanitizer == '' }}
164+
env:
165+
GITHUB_ACTIONS: "true"
164166
run: |
165167
cd examples/server/tests
166168
./tests.sh

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,8 @@ lcov-report/
4545
tags
4646
.build/
4747
build*
48+
release
49+
debug
4850
!build-info.cmake
4951
!build-info.cpp.in
5052
!build-info.sh

AUTHORS

Lines changed: 60 additions & 1 deletion
Large diffs are not rendered by default.

CMakeLists.txt

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ else()
2929
set(LLAMA_STANDALONE OFF)
3030
endif()
3131

32+
option(LLAMA_USE_SYSTEM_GGML "Use system libggml" OFF)
33+
3234
if (EMSCRIPTEN)
3335
set(BUILD_SHARED_LIBS_DEFAULT OFF)
3436

@@ -145,7 +147,13 @@ endif()
145147
# 3rd-party
146148
#
147149

148-
if (NOT TARGET ggml)
150+
if (LLAMA_USE_SYSTEM_GGML)
151+
message(STATUS "Using system-provided libggml, skipping ggml build")
152+
find_package(ggml REQUIRED)
153+
add_library(ggml ALIAS ggml::ggml)
154+
endif()
155+
156+
if (NOT TARGET ggml AND NOT LLAMA_USE_SYSTEM_GGML)
149157
add_subdirectory(ggml)
150158
# ... otherwise assume ggml is added by a parent CMakeLists.txt
151159
endif()

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
4040
_(NOTE: this guideline is yet to be applied to the `llama.cpp` codebase. New code should follow this guideline.)_
4141
42-
- Try to follow the existing patterns in the code (indentation, spaces, etc.). In case of doubt use `clang-format` to format the added code
42+
- Try to follow the existing patterns in the code (indentation, spaces, etc.). In case of doubt use `clang-format` (from clang-tools v15+) to format the added code
4343
- For anything not covered in the current guidelines, refer to the [C++ Core Guidelines](https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines)
4444
- Tensors store data in row-major order. We refer to dimension 0 as columns, 1 as rows, 2 as matrices
4545
- Matrix multiplication is unconventional: [`C = ggml_mul_mat(ctx, A, B)`](https://github.com/ggml-org/llama.cpp/blob/880e352277fc017df4d5794f0c21c44e1eae2b84/ggml.h#L1058-L1064) means $C^T = A B^T \Leftrightarrow C = B A^T.$

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -836,7 +836,7 @@ ifdef GGML_MUSA
836836
else
837837
MUSA_PATH ?= /opt/musa
838838
endif
839-
MUSA_ARCHITECTURES ?= 21;22
839+
MUSA_ARCHITECTURES ?= 21;22;31
840840

841841
MK_CPPFLAGS += -DGGML_USE_MUSA -DGGML_USE_CUDA
842842
MK_LDFLAGS += -L$(MUSA_PATH)/lib -Wl,-rpath=$(MUSA_PATH)/lib

Package.swift

Lines changed: 0 additions & 19 deletions
This file was deleted.

README.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ During sync the commits, I will test and update the commits impact SYCL backend.
3939
[![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](https://opensource.org/licenses/MIT)
4040
[![Server](https://github.com/ggml-org/llama.cpp/actions/workflows/server.yml/badge.svg)](https://github.com/ggml-org/llama.cpp/actions/workflows/server.yml)
4141

42-
[Roadmap](https://github.com/users/ggml-org/projects/7) / [Project status](https://github.com/ggml-org/llama.cpp/discussions/3471) / [Manifesto](https://github.com/ggml-org/llama.cpp/discussions/205) / [ggml](https://github.com/ggml-org/ggml)
42+
[Roadmap](https://github.com/users/ggerganov/projects/7) / [Project status](https://github.com/ggml-org/llama.cpp/discussions/3471) / [Manifesto](https://github.com/ggml-org/llama.cpp/discussions/205) / [ggml](https://github.com/ggml-org/ggml)
4343

4444
Inference of Meta's [LLaMA](https://arxiv.org/abs/2302.13971) model (and others) in pure C/C++
4545

@@ -59,7 +59,7 @@ Inference of Meta's [LLaMA](https://arxiv.org/abs/2302.13971) model (and others)
5959

6060
- **How to use [MTLResidencySet](https://developer.apple.com/documentation/metal/mtlresidencyset?language=objc) to keep the GPU memory active?** https://github.com/ggml-org/llama.cpp/pull/11427
6161
- **VS Code extension for FIM completions:** https://github.com/ggml-org/llama.vscode
62-
- Universal tool call support in `llama-server`: https://github.com/ggml-org/llama.cpp/pull/9639
62+
- Universal [tool call support](./docs/function-calling.md) in `llama-server` https://github.com/ggml-org/llama.cpp/pull/9639
6363
- Vim/Neovim plugin for FIM completions: https://github.com/ggml-org/llama.vim
6464
- Introducing GGUF-my-LoRA https://github.com/ggml-org/llama.cpp/discussions/10123
6565
- Hugging Face Inference Endpoints now support GGUF out of the box! https://github.com/ggml-org/llama.cpp/discussions/9669
@@ -191,6 +191,7 @@ Instructions for adding support for new models: [HOWTO-add-model.md](docs/develo
191191
- Guile Scheme: [guile_llama_cpp](https://savannah.nongnu.org/projects/guile-llama-cpp)
192192
- Swift [srgtuszy/llama-cpp-swift](https://github.com/srgtuszy/llama-cpp-swift)
193193
- Swift [ShenghaiWang/SwiftLlama](https://github.com/ShenghaiWang/SwiftLlama)
194+
- Delphi [Embarcadero/llama-cpp-delphi](https://github.com/Embarcadero/llama-cpp-delphi)
194195

195196
</details>
196197

@@ -205,6 +206,7 @@ Instructions for adding support for new models: [HOWTO-add-model.md](docs/develo
205206
- [eva](https://github.com/ylsdamxssjxxdd/eva) (MIT)
206207
- [iohub/collama](https://github.com/iohub/coLLaMA) (Apache-2.0)
207208
- [janhq/jan](https://github.com/janhq/jan) (AGPL)
209+
- [johnbean393/Sidekick](https://github.com/johnbean393/Sidekick) (MIT)
208210
- [KanTV](https://github.com/zhouwg/kantv?tab=readme-ov-file) (Apache-2.0)
209211
- [KodiBot](https://github.com/firatkiral/kodibot) (GPL)
210212
- [llama.vim](https://github.com/ggml-org/llama.vim) (MIT)
@@ -253,7 +255,7 @@ Instructions for adding support for new models: [HOWTO-add-model.md](docs/develo
253255
- [llama_cpp_canister](https://github.com/onicai/llama_cpp_canister) - llama.cpp as a smart contract on the Internet Computer, using WebAssembly
254256
- [llama-swap](https://github.com/mostlygeek/llama-swap) - transparent proxy that adds automatic model switching with llama-server
255257
- [Kalavai](https://github.com/kalavai-net/kalavai-client) - Crowdsource end to end LLM deployment at any scale
256-
258+
- [llmaz](https://github.com/InftyAI/llmaz) - ☸️ Easy, advanced inference platform for large language models on Kubernetes.
257259
</details>
258260

259261
<details>

Sources/llama/llama.h

Lines changed: 0 additions & 4 deletions
This file was deleted.

0 commit comments

Comments
 (0)