Skip to content

Commit

Permalink
extra : sync grammar-parser
Browse files Browse the repository at this point in the history
  • Loading branch information
ggerganov committed Apr 7, 2024
1 parent 81a3c41 commit ccbe9d5
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 8 deletions.
14 changes: 10 additions & 4 deletions extra/sync-ggml-am.sh
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ while read c; do
examples/common.cpp \
examples/common-ggml.h \
examples/common-ggml.cpp \
examples/whisper/grammar-parser.h \
examples/whisper/grammar-parser.cpp \
examples/whisper/whisper.h \
examples/whisper/whisper.cpp \
examples/whisper/main.cpp \
Expand Down Expand Up @@ -121,10 +123,12 @@ if [ -f $SRC_WHISPER/ggml-src.patch ]; then
# include/ggml/ggml-alloc.h -> ggml-alloc.h
# include/ggml/ggml-backend.h -> ggml-backend.h
#
# examples/common.h -> examples/common.h
# examples/common.cpp -> examples/common.cpp
# examples/common-ggml.h -> examples/common-ggml.h
# examples/common-ggml.cpp -> examples/common-ggml.cpp
# examples/common.h -> examples/common.h
# examples/common.cpp -> examples/common.cpp
# examples/common-ggml.h -> examples/common-ggml.h
# examples/common-ggml.cpp -> examples/common-ggml.cpp
# examples/whisper/grammar-parser.h -> examples/grammar-parser.h
# examples/whisper/grammar-parser.cpp -> examples/grammar-parser.cpp
#
# examples/whisper/whisper.h -> whisper.h
# examples/whisper/whisper.cpp -> whisper.cpp
Expand Down Expand Up @@ -162,6 +166,8 @@ if [ -f $SRC_WHISPER/ggml-src.patch ]; then
-e 's/examples\/common\.cpp/examples\/common.cpp/g' \
-e 's/examples\/common-ggml\.h/examples\/common-ggml.h/g' \
-e 's/examples\/common-ggml\.cpp/examples\/common-ggml.cpp/g' \
-e 's/examples\/whisper\/grammar-parser\.h/examples\/grammar-parser.h/g' \
-e 's/examples\/whisper\/grammar-parser\.cpp/examples\/grammar-parser.cpp/g' \
-e 's/examples\/whisper\/whisper\.h/whisper.h/g' \
-e 's/examples\/whisper\/whisper\.cpp/whisper.cpp/g' \
-e 's/examples\/whisper\/main\.cpp/examples\/main\/main.cpp/g' \
Expand Down
10 changes: 6 additions & 4 deletions extra/sync-ggml.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,12 @@ cp -rpv ../ggml/include/ggml/ggml.h ./ggml.h
cp -rpv ../ggml/include/ggml/ggml-alloc.h ./ggml-alloc.h
cp -rpv ../ggml/include/ggml/ggml-backend.h ./ggml-backend.h

cp -rpv ../ggml/examples/common.h ./examples/common.h
cp -rpv ../ggml/examples/common.cpp ./examples/common.cpp
cp -rpv ../ggml/examples/common-ggml.h ./examples/common-ggml.h
cp -rpv ../ggml/examples/common-ggml.cpp ./examples/common-ggml.cpp
cp -rpv ../ggml/examples/common.h ./examples/common.h
cp -rpv ../ggml/examples/common.cpp ./examples/common.cpp
cp -rpv ../ggml/examples/common-ggml.h ./examples/common-ggml.h
cp -rpv ../ggml/examples/common-ggml.cpp ./examples/common-ggml.cpp
cp -rpv ../ggml/examples/whisper/grammar-parser.h ./examples/grammar-parser.h
cp -rpv ../ggml/examples/whisper/grammar-parser.cpp ./examples/grammar-parser.cpp

cp -rpv ../ggml/examples/whisper/whisper.h ./whisper.h
cp -rpv ../ggml/examples/whisper/whisper.cpp ./whisper.cpp
Expand Down

0 comments on commit ccbe9d5

Please sign in to comment.