what_you_say 0.4.0-arm64-darwin → 0.4.2-arm64-darwin
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +8 -8
- data/lib/what_you_say/3.1/what_you_say.bundle +0 -0
- data/lib/what_you_say/3.2/what_you_say.bundle +0 -0
- data/lib/what_you_say/version.rb +1 -1
- data/lib/what_you_say.rb +0 -1
- metadata +1 -2
- data/lib/what_you_say/info.rb +0 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c5b3760f72a18aa0a0f46f2f8b5a3fe42822be4ef8daf54499faeb584302d8f7
|
4
|
+
data.tar.gz: e54de0603afd5957bd9f74e5ec0db1b7eb0ebddd34c2c4e845ef0d32327b8eb0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3f447cc90750acd25f657adfcdc5287bf7409f9a9d42f0f9b3aed84ba64c572abd12da0015dadd37f8a8b1182518e84cda0620f16e2f3c03d14452ce7457b327
|
7
|
+
data.tar.gz: 73187be3c935fae84ee8715d3e2d416c0bac8fa9eab77b0a909cc70e769a0fdfe5bec284096878a27ba969c9cd49950761a7e5a1c4921ddbc71af8caf3bf81cd
|
data/README.md
CHANGED
@@ -1,12 +1,14 @@
|
|
1
1
|
# WhatYouSay
|
2
2
|
|
3
|
-
Quick and easy natural language detection wrapping the [
|
3
|
+
Quick and easy natural language detection wrapping the [Whatlang Rust crate](https://github.com/greyblake/whatlang-rs). Instantly identify the source language of a piece of text.
|
4
4
|
|
5
5
|
![What you say!!](https://user-images.githubusercontent.com/64050/224237944-ceb2570c-d544-474a-8c91-41433efdee43.png)
|
6
6
|
|
7
|
-
- Supports [
|
7
|
+
- Supports [69 languages](https://github.com/greyblake/whatlang-rs/blob/master/SUPPORTED_LANGUAGES.md) (nice!)
|
8
8
|
- Core library is written in Rust; this is a Ruby wrapper to it
|
9
9
|
- Lightweight, fast, and simple
|
10
|
+
- Recognizes not only a language, but also a script (Latin, Cyrillic, etc)
|
11
|
+
- Provides reliability information
|
10
12
|
|
11
13
|
## Installation
|
12
14
|
|
@@ -20,9 +22,7 @@ If bundler is not being used to manage dependencies, install the gem by executin
|
|
20
22
|
|
21
23
|
## Usage
|
22
24
|
|
23
|
-
The method to call is `_?`. Why? Because
|
24
|
-
|
25
|
-
Pass in the text whose language you want to detect:
|
25
|
+
The method to call is `_?`. Why? Because. Pass in the text whose language you want to detect:
|
26
26
|
|
27
27
|
```ruby
|
28
28
|
require "what_you_say"
|
@@ -31,8 +31,8 @@ text = "Ĉu vi ne volas eklerni Esperanton? Bonvolu! Estas unu de la plej bonaj
|
|
31
31
|
|
32
32
|
result = WhatYouSay._?(text)
|
33
33
|
|
34
|
-
assert_equal("epo", result.
|
35
|
-
assert_equal("esperanto", result.
|
34
|
+
assert_equal("epo", result.code)
|
35
|
+
assert_equal("esperanto", result.eng_name)
|
36
36
|
```
|
37
37
|
|
38
38
|
You also have to opportunity to `inspect` some output:
|
@@ -40,7 +40,7 @@ You also have to opportunity to `inspect` some output:
|
|
40
40
|
```ruby
|
41
41
|
text = "Եվ ահա ես ստանում եմ մի զանգ պատահական տղայից"
|
42
42
|
WhatYouSay._?(text).inspect
|
43
|
-
#=> #<WhatYouSay::
|
43
|
+
#=> #<WhatYouSay::Lang code="hye" eng_name="Armenian">
|
44
44
|
```
|
45
45
|
|
46
46
|
## Development
|
Binary file
|
Binary file
|
data/lib/what_you_say/version.rb
CHANGED
data/lib/what_you_say.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: what_you_say
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.2
|
5
5
|
platform: arm64-darwin
|
6
6
|
authors:
|
7
7
|
- Garen J. Torikian
|
@@ -52,7 +52,6 @@ files:
|
|
52
52
|
- lib/what_you_say/3.1/what_you_say.bundle
|
53
53
|
- lib/what_you_say/3.2/what_you_say.bundle
|
54
54
|
- lib/what_you_say/extension.rb
|
55
|
-
- lib/what_you_say/info.rb
|
56
55
|
- lib/what_you_say/lang.rb
|
57
56
|
- lib/what_you_say/version.rb
|
58
57
|
homepage: https://github.com/gjtorikian/what_you_say
|