Soenneker.Utils.String.CosineSimilarity 2.1.381

The ID prefix of this package has been reserved for one of the owners of this package by NuGet.org. Prefix Reserved
There is a newer version of this package available.
See the version list below for details.
dotnet add package Soenneker.Utils.String.CosineSimilarity --version 2.1.381
NuGet\Install-Package Soenneker.Utils.String.CosineSimilarity -Version 2.1.381
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Soenneker.Utils.String.CosineSimilarity" Version="2.1.381" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Soenneker.Utils.String.CosineSimilarity --version 2.1.381
#r "nuget: Soenneker.Utils.String.CosineSimilarity, 2.1.381"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Soenneker.Utils.String.CosineSimilarity as a Cake Addin
#addin nuget:?package=Soenneker.Utils.String.CosineSimilarity&version=2.1.381

// Install Soenneker.Utils.String.CosineSimilarity as a Cake Tool
#tool nuget:?package=Soenneker.Utils.String.CosineSimilarity&version=2.1.381

alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image

alternate text is missing from this package README image Soenneker.Utils.String.CosineSimilarity

A utility library for comparing strings via Cosine Similarity

Installation

dotnet add package Soenneker.Utils.String.CosineSimularity

Why?

Imagine you have two sentences or documents. Cosine similarity helps you figure out how similar they are by looking at the -words- they share. Here's why it's handy:

Easy to Understand:

Cosine similarity is easy to understand. It's a number between 0 and 1 that represents how similar two documents are. The closer to 1, the more similar they are.

Not Bothered by Length:

Whether a text is long or short doesn't throw off cosine similarity. It cares more about the words and their relationships than the total number of words.

Meaning, Not Just Frequency:

It focuses on the meaning of words, not just how often they show up. So, even if one document has a lot more words than another, they might still be considered similar if they share important terms.

Efficient for Big Tasks:

When you're dealing with lots of documents or a ton of text, cosine similarity is efficient. It doesn't get bogged down by complicated calculations, making it a practical choice for large datasets.

Usage

var text1 = "This is a test";
var text2 = "This is another test";

double result = CosineSimilarityStringUtil.CalculateSimilarityPercentage(text1, text2); // 75
Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
.NET Core netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.1 is compatible. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • .NETStandard 2.1

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
2.1.386 52 7/3/2024
2.1.385 41 7/3/2024
2.1.384 48 7/3/2024
2.1.383 45 7/3/2024
2.1.382 48 7/3/2024
2.1.381 51 6/27/2024
2.1.380 59 6/27/2024
2.1.379 66 6/22/2024
2.1.378 64 6/22/2024
2.1.377 64 6/22/2024
2.1.376 77 6/16/2024
2.1.375 75 6/15/2024
2.1.374 75 6/15/2024
2.1.373 81 6/15/2024
2.1.372 83 6/15/2024
2.1.371 75 6/15/2024
2.1.370 76 6/15/2024
2.1.369 73 6/15/2024
2.1.368 78 6/15/2024
2.1.367 67 6/14/2024
2.1.366 72 6/14/2024
2.1.365 76 6/4/2024
2.1.364 86 6/4/2024
2.1.363 86 6/2/2024
2.1.362 88 6/1/2024
2.1.361 78 6/1/2024
2.1.360 77 6/1/2024
2.1.359 78 6/1/2024
2.1.358 85 6/1/2024
2.1.357 83 6/1/2024
2.1.356 79 6/1/2024
2.1.355 86 5/31/2024
2.1.354 79 5/31/2024
2.1.353 66 5/31/2024
2.1.352 80 5/31/2024
2.1.351 81 5/29/2024
2.1.350 73 5/29/2024
2.1.349 74 5/28/2024
2.1.348 75 5/28/2024
2.1.347 74 5/28/2024
2.1.346 76 5/28/2024
2.1.345 77 5/28/2024
2.1.344 75 5/27/2024
2.1.343 79 5/27/2024
2.1.342 72 5/27/2024
2.1.341 80 5/26/2024
2.1.340 81 5/26/2024
2.1.339 73 5/26/2024
2.1.338 86 5/26/2024
2.1.337 85 5/26/2024
2.1.336 82 5/26/2024
2.1.335 87 5/25/2024
2.1.334 86 5/25/2024
2.1.333 80 5/25/2024
2.1.332 84 5/25/2024
2.1.331 78 5/25/2024
2.1.330 84 5/25/2024
2.1.329 84 5/23/2024
2.1.328 83 5/23/2024
2.1.327 66 5/23/2024
2.1.326 83 5/23/2024
2.1.325 80 5/23/2024
2.1.324 90 5/23/2024
2.1.323 80 5/22/2024
2.1.322 87 5/22/2024
2.1.321 81 5/22/2024
2.1.320 75 5/22/2024
2.1.319 83 5/18/2024
2.1.318 82 5/18/2024
2.1.317 75 5/18/2024
2.1.316 79 5/18/2024
2.1.315 85 5/17/2024
2.1.314 91 5/17/2024
2.1.313 83 5/17/2024
2.1.312 79 5/16/2024
2.1.311 86 5/16/2024
2.1.310 91 5/15/2024
2.1.309 78 5/15/2024
2.1.308 93 5/15/2024
2.1.307 85 5/13/2024
2.1.306 87 5/13/2024
2.1.305 66 5/13/2024
2.1.304 95 4/30/2024
2.1.303 82 4/30/2024
2.1.302 88 4/30/2024
2.1.301 90 4/30/2024
2.1.300 74 4/29/2024
2.1.299 81 4/29/2024
2.1.298 77 4/29/2024
2.1.297 74 4/29/2024
2.1.296 80 4/28/2024
2.1.295 91 4/28/2024
2.1.294 89 4/28/2024
2.1.293 84 4/28/2024
2.1.292 78 4/28/2024
2.1.291 81 4/28/2024
2.1.290 77 4/28/2024
2.1.289 83 4/27/2024
2.1.288 100 4/27/2024
2.1.287 87 4/20/2024
2.1.286 80 4/20/2024
2.1.285 76 4/19/2024
2.1.284 75 4/19/2024
2.1.283 77 4/19/2024
2.1.282 80 4/19/2024
2.1.281 78 4/18/2024
2.1.280 85 4/13/2024
2.1.279 72 4/13/2024
2.1.278 79 4/13/2024
2.1.277 69 4/12/2024
2.1.276 66 4/12/2024
2.1.275 63 4/12/2024
2.1.274 64 4/12/2024
2.1.273 64 4/12/2024
2.1.272 64 4/12/2024
2.1.271 75 4/12/2024
2.1.270 65 4/12/2024
2.1.269 72 4/11/2024
2.1.268 80 4/10/2024
2.1.267 70 4/10/2024
2.1.266 72 4/10/2024
2.1.265 77 4/10/2024
2.1.264 70 4/10/2024
2.1.263 92 4/3/2024
2.1.262 78 4/3/2024
2.1.261 334 3/30/2024
2.1.260 80 3/29/2024
2.1.259 88 3/29/2024
2.1.258 84 3/25/2024
2.1.257 84 3/25/2024
2.1.256 84 3/25/2024
2.1.255 76 3/25/2024
2.1.254 86 3/25/2024
2.1.253 80 3/21/2024
2.1.252 81 3/21/2024
2.1.251 90 3/21/2024
2.1.250 77 3/20/2024
2.1.249 85 3/20/2024
2.1.248 90 3/19/2024
2.1.247 65 3/19/2024
2.1.246 80 3/19/2024
2.1.245 71 3/19/2024
2.1.244 79 3/19/2024
2.1.243 92 3/19/2024
2.1.242 79 3/18/2024
2.1.241 83 3/16/2024
2.1.240 80 3/16/2024
2.1.239 88 3/16/2024
2.1.238 88 3/15/2024
2.1.237 81 3/13/2024
2.1.236 87 3/13/2024
2.1.235 80 3/13/2024
2.1.234 82 3/13/2024
2.1.233 83 3/13/2024
2.1.232 87 3/13/2024
2.1.231 89 3/13/2024
2.1.230 82 3/13/2024
2.1.229 87 3/12/2024
2.1.228 90 3/12/2024
2.1.227 79 3/12/2024
2.1.226 91 3/12/2024
2.1.225 77 3/11/2024
2.1.224 79 3/11/2024
2.1.223 95 3/11/2024
2.1.222 74 3/11/2024
2.1.221 67 3/11/2024
2.1.220 90 3/10/2024
2.1.219 86 3/10/2024
2.1.218 89 3/10/2024
2.1.217 80 3/10/2024
2.1.216 101 3/9/2024
2.1.215 91 3/8/2024
2.1.214 90 3/8/2024
2.1.213 95 3/8/2024
2.1.212 83 3/8/2024
2.1.211 82 3/8/2024
2.1.210 77 3/8/2024
2.1.209 97 3/6/2024
2.1.208 90 3/6/2024
2.1.207 81 3/6/2024
2.1.206 85 3/4/2024
2.1.205 75 3/4/2024
2.1.204 82 3/4/2024
2.1.203 80 3/4/2024
2.1.202 71 3/4/2024
2.1.201 80 3/3/2024
2.1.200 87 3/3/2024
2.1.199 90 3/3/2024
2.1.198 89 3/3/2024
2.1.197 82 3/2/2024
2.1.196 82 3/2/2024
2.1.195 80 2/29/2024
2.1.194 77 2/29/2024
2.1.193 75 2/29/2024
2.1.192 70 2/29/2024
2.1.191 78 2/29/2024
2.1.190 74 2/29/2024
2.1.189 68 2/29/2024
2.1.188 88 2/29/2024
2.1.187 73 2/27/2024
2.1.186 67 2/26/2024
2.1.185 54 2/26/2024
2.1.184 78 2/25/2024
2.1.183 72 2/25/2024
2.1.182 70 2/25/2024
2.1.181 84 2/25/2024
2.1.180 82 2/25/2024
2.1.179 77 2/24/2024
2.1.178 70 2/23/2024
2.1.177 74 2/23/2024
2.1.176 77 2/22/2024
2.1.175 72 2/22/2024
2.1.174 75 2/22/2024
2.1.173 61 2/22/2024
2.1.172 75 2/22/2024
2.1.171 75 2/22/2024
2.1.170 81 2/21/2024
2.1.169 74 2/21/2024
2.1.168 69 2/21/2024
2.1.167 86 2/21/2024
2.1.166 99 2/21/2024
2.1.165 83 2/21/2024
2.1.164 71 2/21/2024
2.1.163 92 2/20/2024
2.1.162 74 2/20/2024
2.1.161 82 2/20/2024
2.1.160 85 2/20/2024
2.1.159 87 2/20/2024
2.1.158 79 2/20/2024
2.1.157 82 2/20/2024
2.1.156 69 2/20/2024
2.1.155 74 2/19/2024
2.1.154 70 2/19/2024
2.1.153 76 2/19/2024
2.1.152 63 2/19/2024
2.1.151 87 2/17/2024
2.1.150 74 2/17/2024
2.1.149 78 2/17/2024
2.1.148 75 2/17/2024
2.1.147 88 2/17/2024
2.1.146 69 2/16/2024
2.1.145 84 2/16/2024
2.1.144 61 2/16/2024
2.1.143 87 2/16/2024
2.1.142 65 2/16/2024
2.1.141 80 2/16/2024
2.1.140 72 2/16/2024
2.1.139 79 2/14/2024
2.1.138 85 2/14/2024
2.1.137 87 2/14/2024
2.1.136 86 2/14/2024
2.1.135 74 2/13/2024
2.1.134 86 2/13/2024
2.1.133 72 2/13/2024
2.1.132 91 2/13/2024
2.1.131 70 2/13/2024
2.1.130 85 2/13/2024
2.1.129 79 2/12/2024
2.1.128 82 2/12/2024
2.1.127 82 2/12/2024
2.1.126 88 2/12/2024
2.1.125 84 2/11/2024
2.1.124 85 2/11/2024
2.1.123 82 2/11/2024
2.1.122 92 2/11/2024
2.1.121 80 2/11/2024
2.1.120 80 2/11/2024
2.1.119 88 2/10/2024
2.1.118 86 2/10/2024
2.1.117 82 2/10/2024
2.1.116 86 2/10/2024
2.1.115 87 2/10/2024
2.1.114 82 2/9/2024
2.1.113 82 2/9/2024
2.1.112 86 2/9/2024
2.1.111 86 2/9/2024
2.1.110 90 2/9/2024
2.1.109 89 2/9/2024
2.1.108 82 2/9/2024
2.1.107 92 2/8/2024
2.1.106 82 2/8/2024
2.1.105 78 2/8/2024
2.1.104 82 2/8/2024
2.1.103 83 2/8/2024
2.1.102 87 2/7/2024
2.1.101 90 2/7/2024
2.1.100 82 2/7/2024
2.1.99 78 2/7/2024
2.1.98 80 2/7/2024
2.1.97 82 2/7/2024
2.1.96 82 2/7/2024
2.1.95 85 2/7/2024
2.1.94 82 2/6/2024
2.1.93 78 2/6/2024
2.1.92 81 2/6/2024
2.1.91 80 2/5/2024
2.1.90 78 2/5/2024
2.1.89 86 2/4/2024
2.1.88 76 2/4/2024
2.1.87 77 2/3/2024
2.1.86 82 2/3/2024
2.1.85 81 1/31/2024
2.1.84 79 1/31/2024
2.1.83 76 1/31/2024
2.1.82 69 1/31/2024
2.1.81 86 1/30/2024
2.1.80 84 1/30/2024
2.1.79 80 1/30/2024
2.1.78 77 1/29/2024
2.1.77 82 1/29/2024
2.1.76 80 1/29/2024
2.1.75 77 1/29/2024
2.1.74 71 1/29/2024
2.1.73 84 1/29/2024
2.1.72 82 1/28/2024
2.1.71 83 1/28/2024
2.1.70 78 1/28/2024
2.1.69 84 1/28/2024
2.1.68 80 1/28/2024
2.1.67 78 1/28/2024
2.1.66 81 1/27/2024
2.1.65 79 1/27/2024
2.1.64 80 1/27/2024
2.1.63 78 1/27/2024
2.1.62 79 1/27/2024
2.1.61 79 1/27/2024
2.1.60 67 1/27/2024
2.1.59 80 1/27/2024
2.1.58 80 1/26/2024
2.1.57 77 1/26/2024
2.1.56 79 1/26/2024
2.1.55 78 1/26/2024
2.1.54 76 1/26/2024
2.1.53 84 1/26/2024
2.1.52 80 1/25/2024
2.1.51 75 1/25/2024
2.1.50 79 1/25/2024
2.1.49 82 1/25/2024
2.1.48 75 1/25/2024
2.1.47 79 1/25/2024
2.1.46 89 1/19/2024
2.1.45 84 1/19/2024
2.1.44 74 1/19/2024
2.1.43 101 1/16/2024
2.1.42 99 1/16/2024
2.1.41 73 1/15/2024
2.1.40 95 1/15/2024
2.1.39 94 1/15/2024
2.1.38 88 1/15/2024
2.1.37 88 1/15/2024
2.1.36 85 1/15/2024
2.1.35 96 1/15/2024
2.1.34 86 1/14/2024
2.1.33 85 1/14/2024
2.1.32 90 1/13/2024
2.1.31 87 1/13/2024
2.1.30 83 1/13/2024
2.1.29 91 1/13/2024
2.1.28 89 1/12/2024
2.1.27 92 1/12/2024
2.1.26 91 1/12/2024
2.1.25 88 1/11/2024
2.1.24 94 1/11/2024
2.1.23 102 1/11/2024
2.1.22 100 1/9/2024
2.1.21 107 1/8/2024
2.1.20 94 1/8/2024
2.1.19 100 1/8/2024
2.1.18 108 1/7/2024
2.1.17 104 1/6/2024
2.1.16 108 1/5/2024
2.1.15 104 1/5/2024
2.1.14 93 1/5/2024
2.1.13 99 1/5/2024
2.1.12 103 1/5/2024
2.1.11 79 1/1/2024
2.1.10 81 1/1/2024
2.1.9 85 1/1/2024
2.1.8 80 1/1/2024
2.1.7 86 1/1/2024
2.1.6 106 12/31/2023
2.1.5 93 12/31/2023
2.1.4 102 12/31/2023
2.1.3 81 12/31/2023
2.1.2 80 12/31/2023
2.1.1 87 12/31/2023