A modern text indexing library for go

Sreekanth Sivasankaran 81b35378b8 Merge pull request #983 from sreekanth-cb/persister_loop_tightening 1 day ago
analysis 193c43ecdd Fix another spelling for CI 2 months ago
cmd 323f83aed5 Fix spelling and typo mistakes 2 months ago
config 4d71e901e8 make new analyzers available to consumers of the config pkg 7 months ago
docs 2332455bd2 nicer formatting of license header 1 year ago
document bdd917bb12 MB-28847: Account for total documents' size within a batch 4 months ago
geo aa949f448b adding UTs and extra checks 2 weeks ago
http 00722aa299 disable http unit test which relied on debug functionality 8 months ago
index 81b35378b8 Merge pull request #983 from sreekanth-cb/persister_loop_tightening 1 day ago
mapping e4b290d350 MB-30694: reflect.Value.Type on zero Value panics 2 weeks ago
numeric 323f83aed5 Fix spelling and typo mistakes 2 months ago
registry 2a8237e8cc optimize FacetsBuilder with cached fields & avoid some allocs 1 year ago
search 3cb6fd4c12 optimize scorch fuzzy if prefix is available 2 days ago
size 06f7c58a35 Include missing initialization for size entry of integers 3 months ago
test d4c0a3e022 MB-29923 - high memory usage in scorch 4 days ago
vendor 7ec9fe0868 Update vendor/manifest to include vellum 3 days ago
.gitignore 9ec2ddd757 initial refactor of query into separate package 1 year ago
.travis.yml a009a463cf errCheck to ignore fmt pkg during checks that travis-ci performs 3 months ago
CONTRIBUTING.md 2807a2c8bd adding CONTRIBUTING.md to repo 2 years ago
LICENSE 6e7aa57b52 adding license file 4 years ago
README.md d14b290235 Fix coverage badge in README 7 months ago
config.go 94b0367e47 switch back to upsidedown as default index before merge to master 7 months ago
config_app.go 2332455bd2 nicer formatting of license header 1 year ago
config_disk.go 2332455bd2 nicer formatting of license header 1 year ago
doc.go 2332455bd2 nicer formatting of license header 1 year ago
error.go 2332455bd2 nicer formatting of license header 1 year ago
examples_test.go 2dc2130633 additional golint cleanups 1 year ago
index.go bdd917bb12 MB-28847: Account for total documents' size within a batch 4 months ago
index_alias.go 2332455bd2 nicer formatting of license header 1 year ago
index_alias_impl.go c74e08f039 BREAKING API CHANGE - use stdlib context pkg 5 months ago
index_alias_impl_test.go 323f83aed5 Fix spelling and typo mistakes 2 months ago
index_impl.go 7c996711e7 Micro optimizations while estimating mem needed for search 3 months ago
index_meta.go 96657413a7 index API & scorch uses index.Regexp instead string'ified regexp 1 week ago
index_meta_test.go 2332455bd2 nicer formatting of license header 1 year ago
index_stats.go 2332455bd2 nicer formatting of license header 1 year ago
index_test.go 323f83aed5 Fix spelling and typo mistakes 2 months ago
mapping.go a16efa5e78 add experimental support for indexing/query geo points 1 year ago
query.go 4ddc50e86d typo in documentation 8 months ago
search.go 33ef4ce35e MB-28163: Provide an API to estimate the RAM needed for SearchResult 5 months ago
search_test.go cdd8ff3d30 MB-30776: [Scorch] Merger's enumerator to not skip empty terms 2 days ago

README.md

bleve bleve

Build Status Coverage Status GoDoc codebeat Go Report Card Sourcegraph License

modern text indexing in go - blevesearch.com

Try out bleve live by searching the bleve website.

Features

  • Index any go data structure (including JSON)
  • Intelligent defaults backed up by powerful configuration
  • Supported field types:
    • Text, Numeric, Date
  • Supported query types:
    • Term, Phrase, Match, Match Phrase, Prefix
    • Conjunction, Disjunction, Boolean
    • Numeric Range, Date Range
    • Simple query syntax for human entry
  • tf-idf Scoring
  • Search result match highlighting
  • Supports Aggregating Facets:
    • Terms Facet
    • Numeric Range Facet
    • Date Range Facet

Discussion

Discuss usage and development of bleve in the google group.

Indexing

message := struct{
	Id   string
	From string
	Body string
}{
	Id:   "example",
	From: "marty.schoch@gmail.com",
	Body: "bleve indexing is easy",
}

mapping := bleve.NewIndexMapping()
index, err := bleve.New("example.bleve", mapping)
if err != nil {
	panic(err)
}
index.Index(message.Id, message)

Querying

index, _ := bleve.Open("example.bleve")
query := bleve.NewQueryStringQuery("bleve")
searchRequest := bleve.NewSearchRequest(query)
searchResult, _ := index.Search(searchRequest)

License

Apache License Version 2.0