1*993b0882SAndroid Build Coastguard Worker#!/bin/bash 2*993b0882SAndroid Build Coastguard Worker# Updates the set of model with the most recent ones. 3*993b0882SAndroid Build Coastguard Worker 4*993b0882SAndroid Build Coastguard Workerset -e 5*993b0882SAndroid Build Coastguard Worker 6*993b0882SAndroid Build Coastguard WorkerANNOTATOR_BASE_URL=https://www.gstatic.com/android/text_classifier/q/live 7*993b0882SAndroid Build Coastguard WorkerACTIONS_BASE_URL=https://www.gstatic.com/android/text_classifier/actions/q/live 8*993b0882SAndroid Build Coastguard WorkerLANGID_BASE_URL=https://www.gstatic.com/android/text_classifier/langid/q/live 9*993b0882SAndroid Build Coastguard Worker 10*993b0882SAndroid Build Coastguard Workerdownload() { 11*993b0882SAndroid Build Coastguard Worker echo "$1/FILELIST" 12*993b0882SAndroid Build Coastguard Worker for f in $(wget -O- "$1/FILELIST"); do 13*993b0882SAndroid Build Coastguard Worker destination="$(basename -- $f)" 14*993b0882SAndroid Build Coastguard Worker wget "$1/$f" -O "$destination" 15*993b0882SAndroid Build Coastguard Worker done 16*993b0882SAndroid Build Coastguard Worker} 17*993b0882SAndroid Build Coastguard Worker 18*993b0882SAndroid Build Coastguard Workercd "$(dirname "$0")" 19*993b0882SAndroid Build Coastguard Worker 20*993b0882SAndroid Build Coastguard Workerdownload $ANNOTATOR_BASE_URL 21*993b0882SAndroid Build Coastguard Workerdownload $ACTIONS_BASE_URL 22*993b0882SAndroid Build Coastguard Workerdownload $LANGID_BASE_URL 23*993b0882SAndroid Build Coastguard Worker 24*993b0882SAndroid Build Coastguard Workerecho "You may want to edit the file name of downloaded files, see external/libtextclassifier/Android.bp" 25