https://github.com/euskadi31/go-ngram
an n-gram is a contiguous sequence of n items from a given sequence of text or speech.
https://github.com/euskadi31/go-ngram
go golang golang-library machine-learning ngram ngram-analysis ngrams nlp
Last synced: 16 days ago
JSON representation
an n-gram is a contiguous sequence of n items from a given sequence of text or speech.
- Host: GitHub
- URL: https://github.com/euskadi31/go-ngram
- Owner: euskadi31
- License: mit
- Created: 2018-03-15T20:55:57.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2025-03-24T20:50:48.000Z (about 1 month ago)
- Last Synced: 2025-04-09T20:05:33.566Z (16 days ago)
- Topics: go, golang, golang-library, machine-learning, ngram, ngram-analysis, ngrams, nlp
- Language: Go
- Homepage:
- Size: 43 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
- awesome-golang-repositories - go-ngram - gram is a contiguous sequence of n items from a given sequence of text or speech. (Repositories)
README
# Ngram for Golang 
[](https://goreportcard.com/report/github.com/euskadi31/go-ngram)
| Branch | Status | Coverage |
| ------ | ------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
| master | [](https://github.com/euskadi31/go-ngram/actions/workflows/go.yml) | [](https://coveralls.io/github/euskadi31/go-ngram?branch=master) |> an **_n_-gram** is a contiguous sequence of _n_ items from a given sequence of text or speech.
```go
import (
"fmt""github.com/euskadi31/go-ngram"
)func main() {
tokens := ngram.New(ngram.Bigram).Tokenize("Hello")fmt.Printf("%v\n", tokens) // ["He", "el", "ll", "lo"]
}```
## License
go-ngram is licensed under [the MIT license](LICENSE.md).