The purpose of this project is to create a benchmark system for bopomofo based Traditional Chinese input method
First of all, please read Code organization for golang. The layout of workspace shall look likes the following:
$GOPATH
├── src
│ └── github.com
└── zhtw
└── bopomofo-benchmark
├── scripts
│ └── build.sh
The project is cloned in $GOPATH/src/github.com/zhtw/bopomofo-benchmark
, while
$GOPATH
is where go tool invoked. You can link helper script scripts/build.sh
to $GOPATH/build.sh
so that invoking $GOPATH/build.sh
will do go fmt
, go test
, go build
at the same time. You shall use go fmt
before committing.
To run the benchmark, just run bopomofo-benchmark
after building. The result
of benchmark will be stored in report
if no -reportdir=<path>
is provided.
The following snippet is data file format used for benchmarking.
#這是註解
這是輸入|ㄓㄜˋㄕˋㄕㄨㄖㄨˋ
All strings after #
are treated as comment and ignored. Each line of data file
contains a Chinese string and bopomofo string, separated by |
. The bopomofo
string is the bopomofo input, and Chinese string is the expected output.
Please report bug or feature request in github issue
The project is licensed under MIT license.