{"id":18326481,"url":"https://github.com/ghosind/go-similarity","last_synced_at":"2026-06-30T23:32:17.545Z","repository":{"id":259458707,"uuid":"677626016","full_name":"ghosind/go-similarity","owner":"ghosind","description":"Similarity or distance metrics for string implemented on Golang, inspired by Sam Chapman's SimMetrics library.","archived":false,"fork":false,"pushed_at":"2024-12-30T15:01:22.000Z","size":41,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-29T03:35:30.279Z","etag":null,"topics":["distamce-metric","go","go-library","go-package","golang","similarity","similarity-metric","string-similarity","strings"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ghosind.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-08-12T05:03:37.000Z","updated_at":"2024-12-30T15:01:14.000Z","dependencies_parsed_at":null,"dependency_job_id":"6c2bcfc1-0d0c-474b-b294-a297bb85a527","html_url":"https://github.com/ghosind/go-similarity","commit_stats":null,"previous_names":["ghosind/go-similarity"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/ghosind/go-similarity","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ghosind%2Fgo-similarity","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ghosind%2Fgo-similarity/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ghosind%2Fgo-similarity/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ghosind%2Fgo-similarity/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ghosind","download_url":"https://codeload.github.com/ghosind/go-similarity/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ghosind%2Fgo-similarity/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34987610,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-30T02:00:05.919Z","response_time":92,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["distamce-metric","go","go-library","go-package","golang","similarity","similarity-metric","string-similarity","strings"],"created_at":"2024-11-05T19:07:02.984Z","updated_at":"2026-06-30T23:32:17.519Z","avatar_url":"https://github.com/ghosind.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# go-similarity\n\n![test](https://github.com/ghosind/go-similarity/workflows/test/badge.svg)\n[![Go Report Card](https://goreportcard.com/badge/github.com/ghosind/go-similarity)](https://goreportcard.com/report/github.com/ghosind/go-similarity)\n[![codecov](https://codecov.io/gh/ghosind/go-similarity/branch/main/graph/badge.svg)](https://codecov.io/gh/ghosind/go-similarity)\n![Version Badge](https://img.shields.io/github/v/release/ghosind/go-similarity)\n![License Badge](https://img.shields.io/github/license/ghosind/go-similarity)\n[![Go Reference](https://pkg.go.dev/badge/github.com/ghosind/go-similarity.svg)](https://pkg.go.dev/github.com/ghosind/go-similarity)\n\nSimilarity or distance metrics for string implemented on Golang, inspired by [Sam Chapman's SimMetrics library](https://sourceforge.net/projects/simmetrics/).\n\n## Installation\n\nRun the following command to install the package:\n\n```bash\ngo get -u github.com/ghosind/go-similarity\n```\n\n## Getting Started\n\nTo use the similarity package, you need to import it in your Go file and create a new instance of the similarity you want to use.\n\n```go\nsim := new(similarity.BlockDistance)\nsimilarity := sim.Compare(\"Hello World\", \"Hello Go\")\nfmt.Println(similarity)\n// 0.5\n```\n\n## Supported Metrics Algorithms\n\n- [Block Distance](https://en.wikipedia.org/wiki/Taxicab_geometry)\n- Chapman Length Deviation\n- Cosine Similarity\n- [Dice Coefficient](https://en.wikipedia.org/wiki/S%C3%B8rensen%E2%80%93Dice_coefficient)\n- [Euclidean Distance](https://en.wikipedia.org/wiki/Euclidean_distance)\n- [Jaccard Coefficient](https://en.wikipedia.org/wiki/Jaccard_index)\n- [Levenshtein Distance](https://en.wikipedia.org/wiki/Levenshtein_distance)\n- Matching Coefficient\n- [Needleman Wunsch](https://en.wikipedia.org/wiki/Needleman%E2%80%93Wunsch_algorithm)\n- [Overlap Coefficient](https://en.wikipedia.org/wiki/Overlap_coefficient)\n\n## Builtin Tokenizers\n\n- Whitespace Tokenizer: Tokenize the input string by whitespace.\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fghosind%2Fgo-similarity","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fghosind%2Fgo-similarity","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fghosind%2Fgo-similarity/lists"}