mirror of
https://github.com/modelscope/FunASR
synced 2025-09-15 14:48:36 +08:00
* add hotword for deploy_tools * Support wfst decoder and contextual biasing (#1039) * Support wfst decoder and contextual biasing * Turn on fstbin compilation --------- Co-authored-by: gongbo.gb <gongbo.gb@alibaba-inc.com> * mv funasr/runtime runtime * Fix crash caused by OOV in hotwords list * funasr infer * funasr infer * funasr infer * funasr infer * funasr infer * fix some bugs about fst hotword; support wfst for websocket server and clients; mv runtime out of funasr; modify relative docs * del onnxruntime/include/gflags * update tensor.h * update run_server.sh * update deploy tools * update deploy tools * update websocket-server * update funasr-wss-server * Remove self loop propagation * Update websocket_protocol_zh.md * Update websocket_protocol_zh.md * update hotword protocol * author zhaomingwork: change hotwords for h5 and java * update hotword protocol * catch exception for json_fst_hws * update hotword on message * update onnx benchmark for ngram&hotword * update docs * update funasr-wss-serve * add NONE for LM_DIR * update docs * update run_server.sh * add whats-new * modify whats-new * update whats-new * update whats-new * Support decoder option for beam searching * update benchmark_onnx_cpp * Support decoder option for websocket * fix bug of CompileHotwordEmbedding * update html client * update docs --------- Co-authored-by: gongbo.gb <35997837+aibulamusi@users.noreply.github.com> Co-authored-by: gongbo.gb <gongbo.gb@alibaba-inc.com> Co-authored-by: 游雁 <zhifu.gzf@alibaba-inc.com>
77 lines
1.9 KiB
Makefile
77 lines
1.9 KiB
Makefile
|
|
ENTRY_POINT = ./
|
|
|
|
|
|
|
|
|
|
WEBSOCKET_DIR:= ./
|
|
WEBSOCKET_FILES = \
|
|
$(WEBSOCKET_DIR)/FunasrWsClient.java \
|
|
|
|
|
|
|
|
LIB_BUILD_DIR = ./lib
|
|
|
|
|
|
|
|
|
|
JAVAC = javac
|
|
|
|
BUILD_DIR = build
|
|
|
|
|
|
RUNJFLAGS = -Dfile.encoding=utf-8
|
|
|
|
|
|
vpath %.class $(BUILD_DIR)
|
|
vpath %.java src
|
|
|
|
|
|
|
|
|
|
rebuild: clean all
|
|
|
|
.PHONY: clean run downjar
|
|
|
|
downjar:
|
|
wget https://repo1.maven.org/maven2/org/slf4j/slf4j-api/1.7.25/slf4j-api-1.7.25.jar -P ./lib/
|
|
wget https://repo1.maven.org/maven2/org/slf4j/slf4j-simple/1.7.25/slf4j-simple-1.7.25.jar -P ./lib/
|
|
#wget https://github.com/TooTallNate/Java-WebSocket/releases/download/v1.5.3/Java-WebSocket-1.5.3.jar -P ./lib/
|
|
wget https://repo1.maven.org/maven2/org/java-websocket/Java-WebSocket/1.5.3/Java-WebSocket-1.5.3.jar -P ./lib/
|
|
wget https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/json-simple/json-simple-1.1.1.jar -P ./lib/
|
|
wget https://github.com/argparse4j/argparse4j/releases/download/argparse4j-0.9.0/argparse4j-0.9.0.jar -P ./lib/
|
|
rm -frv build
|
|
mkdir build
|
|
clean:
|
|
rm -frv $(BUILD_DIR)/*
|
|
rm -frv $(LIB_BUILD_DIR)/*
|
|
mkdir -p $(BUILD_DIR)
|
|
mkdir -p ./lib
|
|
|
|
|
|
|
|
|
|
|
|
|
|
runclient:
|
|
java -cp $(BUILD_DIR):lib/Java-WebSocket-1.5.3.jar:lib/slf4j-simple-1.7.25.jar:lib/slf4j-api-1.7.25.jar:lib/json-simple-1.1.1.jar:lib/argparse4j-0.9.0.jar $(RUNJFLAGS) websocket.FunasrWsClient --host localhost --port 8889 --audio_in ./asr_example.wav --num_threads 1 --mode 2pass
|
|
|
|
|
|
|
|
buildwebsocket: $(WEBSOCKET_FILES:.java=.class)
|
|
|
|
|
|
%.class: %.java
|
|
|
|
$(JAVAC) -cp $(BUILD_DIR):lib/slf4j-simple-1.7.25.jar:lib/slf4j-api-1.7.25.jar:lib/Java-WebSocket-1.5.3.jar:lib/json-simple-1.1.1.jar:lib/argparse4j-0.9.0.jar -d $(BUILD_DIR) -encoding UTF-8 $<
|
|
|
|
packjar:
|
|
jar cvfe lib/funasrclient.jar . -C $(BUILD_DIR) .
|
|
|
|
all: clean buildlib packjar buildfile buildmic downjar buildwebsocket
|
|
|
|
|
|
|
|
|
|
|