forked from LostRuins/koboldcpp
-
Notifications
You must be signed in to change notification settings - Fork 27
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'upstream/concedo'
- Loading branch information
Showing
367 changed files
with
45,810 additions
and
40,184 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
ARG ONEAPI_VERSION=2024.1.1-devel-ubuntu22.04 | ||
|
||
FROM intel/oneapi-basekit:$ONEAPI_VERSION as build | ||
|
||
ARG LLAMA_SYCL_F16=OFF | ||
RUN apt-get update && \ | ||
apt-get install -y git | ||
|
||
WORKDIR /app | ||
|
||
COPY . . | ||
|
||
RUN if [ "${LLAMA_SYCL_F16}" = "ON" ]; then \ | ||
echo "LLAMA_SYCL_F16 is set" && \ | ||
export OPT_SYCL_F16="-DLLAMA_SYCL_F16=ON"; \ | ||
fi && \ | ||
cmake -B build -DLLAMA_SYCL=ON -DCMAKE_C_COMPILER=icx -DCMAKE_CXX_COMPILER=icpx ${OPT_SYCL_F16} && \ | ||
cmake --build build --config Release --target llama-cli | ||
|
||
FROM intel/oneapi-basekit:$ONEAPI_VERSION as runtime | ||
|
||
COPY --from=build /app/build/bin/llama-cli /llama-cli | ||
|
||
ENV LC_ALL=C.utf8 | ||
|
||
ENTRYPOINT [ "/llama-cli" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
ARG ONEAPI_VERSION=2024.1.1-devel-ubuntu22.04 | ||
|
||
FROM intel/oneapi-basekit:$ONEAPI_VERSION as build | ||
|
||
ARG LLAMA_SYCL_F16=OFF | ||
RUN apt-get update && \ | ||
apt-get install -y git libcurl4-openssl-dev | ||
|
||
WORKDIR /app | ||
|
||
COPY . . | ||
|
||
RUN if [ "${LLAMA_SYCL_F16}" = "ON" ]; then \ | ||
echo "LLAMA_SYCL_F16 is set" && \ | ||
export OPT_SYCL_F16="-DLLAMA_SYCL_F16=ON"; \ | ||
fi && \ | ||
cmake -B build -DLLAMA_SYCL=ON -DCMAKE_C_COMPILER=icx -DCMAKE_CXX_COMPILER=icpx -DLLAMA_CURL=ON ${OPT_SYCL_F16} && \ | ||
cmake --build build --config Release --target llama-server | ||
|
||
FROM intel/oneapi-basekit:$ONEAPI_VERSION as runtime | ||
|
||
RUN apt-get update && \ | ||
apt-get install -y libcurl4-openssl-dev | ||
|
||
COPY --from=build /app/build/bin/llama-server /llama-server | ||
|
||
ENV LC_ALL=C.utf8 | ||
|
||
ENTRYPOINT [ "/llama-server" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
|
||
|
||
- [x] I have read the [contributing guidelines](https://github.com/ggerganov/llama.cpp/blob/master/CONTRIBUTING.md) | ||
- Self-reported review complexity: | ||
- [ ] Low | ||
- [ ] Medium | ||
- [ ] High |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
name: Koboldcpp Builder Linux CUDA12 | ||
name: Koboldcpp Linux CUDA12 | ||
|
||
on: workflow_dispatch | ||
env: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
name: Koboldcpp Builder Linux | ||
name: Koboldcpp Linux | ||
|
||
on: workflow_dispatch | ||
env: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
name: Koboldcpp Builder Windows CUDA | ||
name: Koboldcpp Windows CUDA | ||
|
||
on: workflow_dispatch | ||
env: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
name: Koboldcpp Builder Windows CUDA12 | ||
name: Koboldcpp Windows CUDA12 | ||
|
||
on: workflow_dispatch | ||
env: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
name: Koboldcpp Builder Windows Full Binaries | ||
name: Koboldcpp Windows Full Binaries | ||
|
||
on: workflow_dispatch | ||
env: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
name: Koboldcpp Windows Full Binaries | ||
|
||
on: workflow_dispatch | ||
env: | ||
BRANCH_NAME: ${{ github.head_ref || github.ref_name }} | ||
|
||
jobs: | ||
windows: | ||
runs-on: windows-2019 | ||
steps: | ||
- name: Clone | ||
id: checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
ref: ${{ github.head_ref || github.ref_name }} | ||
|
||
- name: Get Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.8.10 | ||
|
||
- name: Install python dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install customtkinter==5.2.0 pyinstaller==5.11.0 psutil==5.9.5 | ||
- name: Download and install win64devkit | ||
run: | | ||
curl -L https://github.com/skeeto/w64devkit/releases/download/v1.22.0/w64devkit-1.22.0.zip --output w64devkit.zip | ||
Expand-Archive w64devkit.zip -DestinationPath . | ||
- name: Add w64devkit to PATH | ||
run: | | ||
echo "$(Get-Location)\w64devkit\bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8 | ||
- name: Build Non-CUDA | ||
id: make_build | ||
run: | | ||
make -j ${env:NUMBER_OF_PROCESSORS} | ||
- uses: Jimver/[email protected] | ||
id: cuda-toolkit | ||
with: | ||
cuda: '11.4.4' | ||
|
||
- name: Build CUDA | ||
id: cmake_build | ||
run: | | ||
mkdir build | ||
cd build | ||
cmake .. -DLLAMA_CUBLAS=ON -DLLAMA_AVX2=OFF -DCMAKE_SYSTEM_VERSION="10.0.19041.0" | ||
cmake --build . --config Release -j ${env:NUMBER_OF_PROCESSORS} | ||
mv bin/Release/koboldcpp_cublas.dll ../koboldcpp_cublas.dll | ||
cd .. | ||
# note: The libraries that come from the github cuda directory seem to be larger, so they are not recommended | ||
- name: Download CuBLAS Libraries | ||
run: | | ||
curl -L https://github.com/LostRuins/koboldcpp/releases/download/cuda11_cublas_libraries/cublas64_11.dll --output cublas64_11.dll | ||
curl -L https://github.com/LostRuins/koboldcpp/releases/download/cuda11_cublas_libraries/cublasLt64_11.dll --output cublasLt64_11.dll | ||
ls | ||
# - name: Copy CuBLAS Libraries | ||
# run: | | ||
# copy "C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.4\bin\cublasLt64_11.dll" . | ||
# copy "C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.4\bin\cublas64_11.dll" . | ||
# ls | ||
|
||
- name: Package PyInstallers | ||
id: make_pyinstaller | ||
run: | | ||
./make_pyinstaller.bat | ||
./make_pyinstaller_cuda.bat | ||
- name: Save artifact | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: kcpp_windows_pyinstallers | ||
path: dist/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
# Contributing Guidelines | ||
|
||
## Checklist | ||
|
||
* Make sure your PR follows the [coding guidelines](https://github.com/ggerganov/llama.cpp/blob/master/README.md#coding-guidelines) | ||
* Test your changes using the commands in the [`tests`](tests) folder. For instance, running the `./tests/test-backend-ops` command tests different backend implementations of the GGML library | ||
* Execute [the full CI locally on your machine](ci/README.md) before publishing | ||
|
||
## PR formatting | ||
|
||
* Please rate the complexity of your PR (i.e. `Review Complexity : Low`, `Review Complexity : Medium`, `Review Complexity : High`). This makes it easier for maintainers to triage the PRs. | ||
- The PR template has a series of review complexity checkboxes `[ ]` that you can mark as `[X]` for your conveience. Refer to [About task lists](https://docs.github.com/en/get-started/writing-on-github/working-with-advanced-formatting/about-task-lists) for more information. | ||
* If the pull request only contains documentation changes (e.g., updating READMEs, adding new wiki pages), please add `[no ci]` to the commit title. This will skip unnecessary CI checks and help reduce build times. | ||
* When squashing multiple commits on merge, use the following format for your commit title: `<module> : <commit title> (#<issue_number>)`. For example: `utils : Fix typo in utils.py (#1234)` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.