Skip to content

Commit e3e0994

Browse files
authored
feat: Llama 3.1 support, Phi-3 support (#273)
* feat: Phi-3 support * feat: Llama 3.1 support * feat: model metadata overrides * feat: use LoRA on a context instead of on a model * fix: Gemma chat wrapper bug * fix: GGUF metadata nested key conflicts * fix: Phi-3 models memory estimation * fix: adapt to `llama.cpp` breaking changes * fix: preserve function calling chunks * fix: format JSON objects like models expect
1 parent c35ff5a commit e3e0994

File tree

74 files changed

+4238
-2317
lines changed

Some content is hidden

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

74 files changed

+4238
-2317
lines changed

.eslintrc.json

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,13 @@
55
"browser": false,
66
"es6": true
77
},
8-
"ignorePatterns": ["/dist", "/llama", "/docs-site", "/packages/create-node-llama-cpp/dist"],
8+
"ignorePatterns": [
9+
"/dist",
10+
"/llama",
11+
"/docs-site",
12+
"/packages/create-node-llama-cpp/dist",
13+
"/packages/@node-llama-cpp/*/dist"
14+
],
915
"extends": [
1016
"eslint:recommended",
1117
"plugin:jsdoc/recommended"
@@ -133,7 +139,9 @@
133139
"no-duplicate-imports": ["error", {
134140
"includeExports": true
135141
}],
136-
"camelcase": ["warn"],
142+
"camelcase": ["warn", {
143+
"allow": ["\\d+_\\d+"]
144+
}],
137145
"jsx-quotes": ["warn"],
138146
"yoda": ["error", "never", {
139147
"exceptRange": true

.github/workflows/build.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ jobs:
6060
os: windows-2022
6161
artifact: "win-arm"
6262
- name: "Ubuntu"
63-
os: ubuntu-20.04
63+
os: ubuntu-22.04
6464
artifact: "linux"
6565
- name: "macOS"
6666
os: macos-13
@@ -131,8 +131,8 @@ jobs:
131131
- name: Install Vulkan SDK on Ubuntu
132132
if: matrix.config.name == 'Ubuntu'
133133
run: |
134-
wget -qO - https://packages.lunarg.com/lunarg-signing-key-pub.asc | sudo apt-key add -
135-
sudo wget -qO /etc/apt/sources.list.d/lunarg-vulkan-focal.list https://packages.lunarg.com/vulkan/lunarg-vulkan-focal.list
134+
wget -qO- https://packages.lunarg.com/lunarg-signing-key-pub.asc | sudo tee /etc/apt/trusted.gpg.d/lunarg.asc
135+
sudo wget -qO /etc/apt/sources.list.d/lunarg-vulkan-jammy.list https://packages.lunarg.com/vulkan/lunarg-vulkan-jammy.list
136136
sudo apt update
137137
sudo apt install vulkan-sdk
138138
@@ -513,7 +513,7 @@ jobs:
513513
- name: "Windows"
514514
os: windows-2022
515515
- name: "Ubuntu"
516-
os: ubuntu-20.04
516+
os: ubuntu-22.04
517517
- name: "macOS"
518518
os: macos-13
519519

llama/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ if (GGML_METAL)
129129
)
130130
endif()
131131

132-
file(GLOB SOURCE_FILES "addon.cpp" ${GPU_INFO_SOURCES})
132+
file(GLOB SOURCE_FILES "addon/*.cpp" "addon/**/*.cpp" ${GPU_INFO_SOURCES})
133133

134134
if(APPLE)
135135
set(CMAKE_SKIP_BUILD_RPATH FALSE)

0 commit comments

Comments
 (0)