Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: the directory structure. #763

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
8 changes: 4 additions & 4 deletions .github/_typos.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
extend-exclude = [
"_typos.toml",
"docs/xmldocs/",
"LLama.Web/wwwroot/",
"LLama/runtimes/deps/",
"LLama.Benchmark/Assets/",
"LLama.Examples/Assets/"
"samples/LLama.Web/wwwroot/",
"src/LLama/runtimes/deps/",
"test/LLama.Benchmark/Assets/",
"samples/LLama.Examples/Assets/"
]
10 changes: 5 additions & 5 deletions .github/prepare_release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ fi

mkdir ./temp;
mkdir ./temp/runtimes;
cp ./LLama/runtimes ./temp -R;
cp ./LLama/runtimes/build/*.* ./temp/;
cp ./src/LLama/runtimes ./temp -R;
cp ./src/LLama/runtimes/build/*.* ./temp/;

# get the current version
cd temp;
Expand Down Expand Up @@ -65,9 +65,9 @@ fi

cd ..
# pack the main package
dotnet pack ./LLama/LLamaSharp.csproj -c Release -o ./temp/ /p:PackageVersion=$updated_version /p:Version=$updated_version;
dotnet pack ./LLama.SemanticKernel/LLamaSharp.SemanticKernel.csproj -c Release -o ./temp/ /p:PackageVersion=$updated_version /p:Version=$updated_version;
dotnet pack ./LLama.KernelMemory/LLamaSharp.KernelMemory.csproj -c Release -o ./temp/ /p:PackageVersion=$updated_version /p:Version=$updated_version;
dotnet pack ./src/LLama/LLamaSharp.csproj -c Release -o ./temp/ /p:PackageVersion=$updated_version /p:Version=$updated_version;
dotnet pack ./src/LLama.SemanticKernel/LLamaSharp.SemanticKernel.csproj -c Release -o ./temp/ /p:PackageVersion=$updated_version /p:Version=$updated_version;
dotnet pack ./src/LLama.KernelMemory/LLamaSharp.KernelMemory.csproj -c Release -o ./temp/ /p:PackageVersion=$updated_version /p:Version=$updated_version;

# pack the backends
cd temp
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/benchmark.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ jobs:
apt-get install -y python3.10 python3-pip
python3 --version
pip install huggingface_hub
python3 .github/download_models.py --model-dir ${{ matrix.modeldir }} --model-list LLama.Benchmark/Assets/models.txt --endpoint https://hf-mirror.com
python3 .github/download_models.py --model-dir ${{ matrix.modeldir }} --model-list test/LLama.Benchmark/Assets/models.txt --endpoint https://hf-mirror.com

- name: Clear package cache
run: dotnet clean LLamaSharp.sln && dotnet nuget locals all --clear
Expand All @@ -63,10 +63,10 @@ jobs:
- name: Build
run: |
dotnet clean
dotnet build LLama/LLamaSharp.csproj -c Release --no-restore
dotnet build LLama.Benchmark/LLama.Benchmark.csproj -c Release --no-restore
dotnet build src/LLama/LLamaSharp.csproj -c Release --no-restore
dotnet build test/LLama.Benchmark/LLama.Benchmark.csproj -c Release --no-restore
- name: Run benchmark test
run: dotnet run --project LLama.Benchmark/LLama.Benchmark.csproj -c Release --anyCategories LLama
run: dotnet run --project test/LLama.Benchmark/LLama.Benchmark.csproj -c Release --anyCategories LLama
- name: Upload artifacts
if: always()
uses: actions/upload-artifact@v3
Expand Down Expand Up @@ -105,10 +105,10 @@ jobs:
- name: Build
run: |
dotnet clean
dotnet build LLama/LLamaSharp.csproj -c Release --no-restore
dotnet build LLama.Benchmark/LLama.Benchmark.csproj -c Release --no-restore
dotnet build src/LLama/LLamaSharp.csproj -c Release --no-restore
dotnet build test/LLama.Benchmark/LLama.Benchmark.csproj -c Release --no-restore
- name: Run benchmark test
run: dotnet run --project LLama.Benchmark/LLama.Benchmark.csproj -c Release --anyCategories LLama
run: dotnet run --project test/LLama.Benchmark/LLama.Benchmark.csproj -c Release --anyCategories LLama
- name: Upload artifacts
if: always()
uses: actions/upload-artifact@v3
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
uses: actions/cache@v4
with:
key: "unit_test_models"
path: LLama.Unittest/Models
path: test/LLama.Unittest/Models
# workaround for actions/setup-dotnet#155
- name: Clear package cache
run: dotnet clean LLamaSharp.sln && dotnet nuget locals all --clear
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/release-minor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ jobs:

- name: Build solution
run: |
dotnet build ./LLama/LLamaSharp.csproj -c Release --no-restore
dotnet build ./LLama.SemanticKernel/LLamaSharp.SemanticKernel.csproj -c Release --no-restore
dotnet build ./LLama.KernelMemory/LLamaSharp.KernelMemory.csproj -c Release --no-restore
dotnet build ./src/LLama/LLamaSharp.csproj -c Release --no-restore
dotnet build ./src/LLama.SemanticKernel/LLamaSharp.SemanticKernel.csproj -c Release --no-restore
dotnet build ./src/LLama.KernelMemory/LLamaSharp.KernelMemory.csproj -c Release --no-restore

- name: Pack packages
run: |
Expand Down Expand Up @@ -79,4 +79,4 @@ jobs:
run: |
pip install huggingface_hub
llama_cpp_commit_hash=$(git submodule status llama.cpp | cut -c 2-7)
python .github/upload_to_hf.py --token ${{ secrets.HUGGINGFACE_TOKEN }} --revision $llama_cpp_commit_hash --folder LLama/runtimes
python .github/upload_to_hf.py --token ${{ secrets.HUGGINGFACE_TOKEN }} --revision $llama_cpp_commit_hash --folder src/LLama/runtimes
8 changes: 4 additions & 4 deletions .github/workflows/release-patch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ jobs:

- name: Build solution
run: |
dotnet build ./LLama/LLamaSharp.csproj -c Release --no-restore
dotnet build ./LLama.SemanticKernel/LLamaSharp.SemanticKernel.csproj -c Release --no-restore
dotnet build ./LLama.KernelMemory/LLamaSharp.KernelMemory.csproj -c Release --no-restore
dotnet build ./src/LLama/LLamaSharp.csproj -c Release --no-restore
dotnet build ./src/LLama.SemanticKernel/LLamaSharp.SemanticKernel.csproj -c Release --no-restore
dotnet build ./src/LLama.KernelMemory/LLamaSharp.KernelMemory.csproj -c Release --no-restore

- name: Pack packages
run: |
Expand Down Expand Up @@ -79,4 +79,4 @@ jobs:
run: |
pip install huggingface_hub
llama_cpp_commit_hash=$(git submodule status llama.cpp | cut -c 2-7)
python .github/upload_to_hf.py --token ${{ secrets.HUGGINGFACE_TOKEN }} --revision $llama_cpp_commit_hash --folder LLama/runtimes
python .github/upload_to_hf.py --token ${{ secrets.HUGGINGFACE_TOKEN }} --revision $llama_cpp_commit_hash --folder src/LLama/runtimes
Loading
Loading